Topic category: Help with Minecraft modding (Java Edition)
Hi, I want to create a grappling hook, this is my code so far:
package mod.mcreator;//based on master condiguration
import cpw.mods.fml.client.*;
import cpw.mods.fml.client.registry.*;
import cpw.mods.fml.common.*;
import cpw.mods.fml.common.asm.*;
import cpw.mods.fml.common.asm.transformers.*;
import cpw.mods.fml.common.discovery.*;
import cpw.mods.fml.common.discovery.asm.*;
import cpw.mods.fml.common.event.*;
import cpw.mods.fml.common.functions.*;
import cpw.mods.fml.common.network.*;
import cpw.mods.fml.common.registry.*;
import cpw.mods.fml.common.toposort.*;
import cpw.mods.fml.common.versioning.*;
import cpw.mods.fml.relauncher.*;
import cpw.mods.fml.server.*;
import net.minecraft.block.*;
import net.minecraft.block.material.*;
import net.minecraft.client.*;
import net.minecraft.client.audio.*;
import net.minecraft.client.entity.*;
import net.minecraft.client.gui.*;
import net.minecraft.client.gui.achievement.*;
import net.minecraft.client.gui.inventory.*;
import net.minecraft.client.model.*;
import net.minecraft.client.multiplayer.*;
import net.minecraft.client.particle.*;
import net.minecraft.client.renderer.*;
import net.minecraft.client.renderer.culling.*;
import net.minecraft.client.renderer.entity.*;
import net.minecraft.client.renderer.tileentity.*;
import net.minecraft.client.settings.*;
import net.minecraft.command.*;
import net.minecraft.crash.*;
import net.minecraft.creativetab.*;
import net.minecraft.dispenser.*;
import net.minecraft.enchantment.*;
import net.minecraft.entity.*;
import net.minecraft.entity.projectile.EntityThrowable;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.ai.*;
import net.minecraft.entity.boss.*;
import net.minecraft.entity.effect.*;
import net.minecraft.entity.item.*;
import net.minecraft.entity.monster.*;
import net.minecraft.entity.passive.*;
import net.minecraft.entity.player.*;
import net.minecraft.entity.projectile.*;
import net.minecraft.inventory.*;
import net.minecraft.item.*;
import net.minecraft.item.crafting.*;
import net.minecraft.nbt.*;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.*;
import net.minecraft.network.rcon.*;
import net.minecraft.pathfinding.*;
import net.minecraft.potion.*;
import net.minecraft.profiler.*;
import net.minecraft.server.*;
import net.minecraft.server.dedicated.*;
import net.minecraft.server.gui.*;
import net.minecraft.server.integrated.*;
import net.minecraft.server.management.*;
import net.minecraft.src.*;
import net.minecraft.stats.*;
import net.minecraft.tileentity.*;
import net.minecraft.util.*;
import net.minecraft.village.*;
import net.minecraft.world.*;
import net.minecraft.world.biome.*;
import net.minecraft.world.chunk.*;
import net.minecraft.world.chunk.storage.*;
import net.minecraft.world.demo.*;
import net.minecraft.world.gen.*;
import net.minecraft.world.gen.feature.*;
import net.minecraft.world.gen.layer.*;
import net.minecraft.world.gen.structure.*;
import net.minecraft.world.storage.*;
import net.minecraftforge.classloading.*;
import net.minecraftforge.client.*;
import net.minecraftforge.client.event.*;
import net.minecraftforge.client.event.sound.*;
import net.minecraftforge.common.*;
import net.minecraftforge.event.*;
import net.minecraftforge.event.entity.*;
import net.minecraftforge.event.entity.item.*;
import net.minecraftforge.event.entity.living.*;
import net.minecraftforge.event.entity.minecart.*;
import net.minecraftforge.event.entity.player.*;
import net.minecraftforge.event.terraingen.*;
import net.minecraftforge.event.world.*;
import net.minecraftforge.oredict.*;
import net.minecraftforge.transformers.*;
import net.minecraft.init.*;
import java.util.*;
import net.minecraft.util.DamageSource;
import net.minecraft.util.MovingObjectPosition;
import org.lwjgl.opengl.GL11;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.entity.Entity;
import net.minecraft.entity.projectile.EntityFishHook;
import net.minecraft.util.MathHelper;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.Vec3;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import io.netty.buffer.ByteBuf;
@SuppressWarnings("unchecked")
public class mcreator_yoYo {
public static int mobid = 0;
public Object instance;
public void load(){}
public void generateNether(World world, Random random, int chunkX, int chunkZ){}
public void generateSurface(World world, Random random, int chunkX, int chunkZ){}
public int addFuel(ItemStack fuel){
return 0;
}
@SideOnly(Side.CLIENT)
public void registerRenderers(){
RenderingRegistry.registerEntityRenderingHandler(mcreator_yoYo.EntityyoYo.class, new RenderFish());
}
public void serverLoad(FMLServerStartingEvent event){}
public void preInit(FMLPreInitializationEvent event){
int entityID = EntityRegistry.findGlobalUniqueEntityId();
mobid = entityID;
EntityRegistry.registerGlobalEntityID(mcreator_yoYo.EntityyoYo.class, "yoYo", entityID);
EntityRegistry.registerModEntity(mcreator_yoYo.EntityyoYo.class, "yoYo", entityID, instance, 64, 1, true);
}
public static class EntityyoYo extends EntityThrowable implements IEntityAdditionalSpawnData{
public EntityPlayer field_146042_b;
public EntityyoYo(World par1World, double par2, double par4, double par6)
{
super(par1World, par2, par4, par6);
}
public EntityyoYo(World par1World, EntityLivingBase par2EntityLivingBase)
{
super(par1World, par2EntityLivingBase);
}
public EntityyoYo(World par1World)
{
super(par1World);
}
public EntityyoYo(World par1World, EntityLivingBase par2EntityLivingBase, EntityPlayer player)
{
super(par1World, par2EntityLivingBase);
this.field_146042_b = player;
}
/**
* Called when this EntityThrowable hits a block or entity.
*/
protected void onImpact(MovingObjectPosition par1MovingObjectPosition)
{
if (par1MovingObjectPosition.entityHit != null)
{
byte b0 = 18;
par1MovingObjectPosition.entityHit.attackEntityFrom(DamageSource.causeThrownDamage(this, this.getThrower()), (float)b0);
}
if (!this.worldObj.isRemote)
{
this.setDead();
}
}
public void writeSpawnData(ByteBuf data)
{
data.writeInt(this.field_146042_b != null ? this.field_146042_b.getEntityId() : 0);
}
public void readSpawnData(ByteBuf data)
{
this.field_146042_b = (EntityPlayer)this.worldObj.getEntityByID(data.readInt());
}
public void interactEvent(EntityInteractEvent event){
if(event.target instanceof EntityCreature){
int entityID = EntityList.getEntityID(event.target);
ItemStack currentItem = event.entityPlayer.inventory.getCurrentItem();
if(currentItem != null){
if(currentItem == new ItemStack( mcreator_amethystsWhip.block, 1) && currentItem.getItemDamage() == 0){
event.target.setDead();
currentItem.setItemDamage(entityID);
}
}
}
}
}
@SideOnly(Side.CLIENT)
public static class RenderFish extends Render
{
private static final ResourceLocation field_110792_a = new ResourceLocation("textures/particle/particles.png");
private static final String __OBFID = "CL_00000996";
/**
* Actually renders the given argument. This is a synthetic bridge method, always casting down its argument and then
* handing it off to a worker function which does the actual work. In all probabilty, the class Render is generic
* (Render<T extends Entity) and this method has signature public void func_76986_a(T entity, double d, double d1,
* double d2, float f, float f1). But JAD is pre 1.5 so doesn't do that.
*/
public void doRender(Entitywhip p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_)
{
GL11.glPushMatrix();
GL11.glTranslatef((float)p_76986_2_, (float)p_76986_4_, (float)p_76986_6_);
GL11.glEnable(GL12.GL_RESCALE_NORMAL);
GL11.glScalef(0.5F, 0.5F, 0.5F);
this.bindEntityTexture(p_76986_1_);
Tessellator tessellator = Tessellator.instance;
byte b0 = 1;
byte b1 = 2;
float f2 = (float)(b0 * 8 + 0) / 128.0F;
float f3 = (float)(b0 * 8 + 8) / 128.0F;
float f4 = (float)(b1 * 8 + 0) / 128.0F;
float f5 = (float)(b1 * 8 + 8) / 128.0F;
float f6 = 1.0F;
float f7 = 0.5F;
float f8 = 0.5F;
GL11.glRotatef(180.0F - this.renderManager.playerViewY, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(-this.renderManager.playerViewX, 1.0F, 0.0F, 0.0F);
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 1.0F, 0.0F);
tessellator.addVertexWithUV((double)(0.0F - f7), (double)(0.0F - f8), 0.0D, (double)f2, (double)f5);
tessellator.addVertexWithUV((double)(f6 - f7), (double)(0.0F - f8), 0.0D, (double)f3, (double)f5);
tessellator.addVertexWithUV((double)(f6 - f7), (double)(1.0F - f8), 0.0D, (double)f3, (double)f4);
tessellator.addVertexWithUV((double)(0.0F - f7), (double)(1.0F - f8), 0.0D, (double)f2, (double)f4);
tessellator.draw();
GL11.glDisable(GL12.GL_RESCALE_NORMAL);
GL11.glPopMatrix();
if (p_76986_1_.field_146042_b != null)
{
float f9 = p_76986_1_.field_146042_b.getSwingProgress(p_76986_9_);
float f10 = MathHelper.sin(MathHelper.sqrt_float(f9) * (float)Math.PI);
Vec3 vec3 = Vec3.createVectorHelper(-0.5D, 0.03D, 0.8D);
vec3.rotateAroundX(-(p_76986_1_.field_146042_b.prevRotationPitch + (p_76986_1_.field_146042_b.rotationPitch - p_76986_1_.field_146042_b.prevRotationPitch) * p_76986_9_) * (float)Math.PI / 180.0F);
vec3.rotateAroundY(-(p_76986_1_.field_146042_b.prevRotationYaw + (p_76986_1_.field_146042_b.rotationYaw - p_76986_1_.field_146042_b.prevRotationYaw) * p_76986_9_) * (float)Math.PI / 180.0F);
vec3.rotateAroundY(f10 * 0.5F);
vec3.rotateAroundX(-f10 * 0.7F);
double d3 = p_76986_1_.field_146042_b.prevPosX + (p_76986_1_.field_146042_b.posX - p_76986_1_.field_146042_b.prevPosX) * (double)p_76986_9_ + vec3.xCoord;
double d4 = p_76986_1_.field_146042_b.prevPosY + (p_76986_1_.field_146042_b.posY - p_76986_1_.field_146042_b.prevPosY) * (double)p_76986_9_ + vec3.yCoord;
double d5 = p_76986_1_.field_146042_b.prevPosZ + (p_76986_1_.field_146042_b.posZ - p_76986_1_.field_146042_b.prevPosZ) * (double)p_76986_9_ + vec3.zCoord;
double d6 = p_76986_1_.field_146042_b == Minecraft.getMinecraft().thePlayer ? 0.0D : (double)p_76986_1_.field_146042_b.getEyeHeight();
if (this.renderManager.options.thirdPersonView > 0 || p_76986_1_.field_146042_b != Minecraft.getMinecraft().thePlayer)
{
float f11 = (p_76986_1_.field_146042_b.prevRenderYawOffset + (p_76986_1_.field_146042_b.renderYawOffset - p_76986_1_.field_146042_b.prevRenderYawOffset) * p_76986_9_) * (float)Math.PI / 180.0F;
double d7 = (double)MathHelper.sin(f11);
double d9 = (double)MathHelper.cos(f11);
d3 = p_76986_1_.field_146042_b.prevPosX + (p_76986_1_.field_146042_b.posX - p_76986_1_.field_146042_b.prevPosX) * (double)p_76986_9_ - d9 * 0.35D - d7 * 0.85D;
d4 = p_76986_1_.field_146042_b.prevPosY + d6 + (p_76986_1_.field_146042_b.posY - p_76986_1_.field_146042_b.prevPosY) * (double)p_76986_9_ - 0.45D;
d5 = p_76986_1_.field_146042_b.prevPosZ + (p_76986_1_.field_146042_b.posZ - p_76986_1_.field_146042_b.prevPosZ) * (double)p_76986_9_ - d7 * 0.35D + d9 * 0.85D;
}
double d14 = p_76986_1_.prevPosX + (p_76986_1_.posX - p_76986_1_.prevPosX) * (double)p_76986_9_;
double d8 = p_76986_1_.prevPosY + (p_76986_1_.posY - p_76986_1_.prevPosY) * (double)p_76986_9_ + 0.25D;
double d10 = p_76986_1_.prevPosZ + (p_76986_1_.posZ - p_76986_1_.prevPosZ) * (double)p_76986_9_;
double d11 = (double)((float)(d3 - d14));
double d12 = (double)((float)(d4 - d8));
double d13 = (double)((float)(d5 - d10));
GL11.glDisable(GL11.GL_TEXTURE_2D);
GL11.glDisable(GL11.GL_LIGHTING);
tessellator.startDrawing(3);
tessellator.setColorOpaque_I(0);
byte b2 = 16;
for (int i = 0; i <= b2; ++i)
{
float f12 = (float)i / (float)b2;
tessellator.addVertex(p_76986_2_ + d11 * (double)f12, p_76986_4_ + d12 * (double)(f12 * f12 + f12) * 0.5D + 0.25D, p_76986_6_ + d13 * (double)f12);
}
tessellator.draw();
GL11.glEnable(GL11.GL_LIGHTING);
GL11.glEnable(GL11.GL_TEXTURE_2D);
}
}
/**
* Returns the location of an entity's texture. Doesn't seem to be called unless you call Render.bindEntityTexture.
*/
protected ResourceLocation getEntityTexture(Entitywhip p_110775_1_)
{
return field_110792_a;
}
/**
* Returns the location of an entity's texture. Doesn't seem to be called unless you call Render.bindEntityTexture.
*/
protected ResourceLocation getEntityTexture(Entity p_110775_1_)
{
return this.getEntityTexture((Entitywhip)p_110775_1_);
}
/**
* Actually renders the given argument. This is a synthetic bridge method, always casting down its argument and then
* handing it off to a worker function which does the actual work. In all probabilty, the class Render is generic
* (Render<T extends Entity) and this method has signature public void func_76986_a(T entity, double d, double d1,
* double d2, float f, float f1). But JAD is pre 1.5 so doesn't do that.
*/
public void doRender(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_)
{
this.doRender((Entitywhip)p_76986_1_, p_76986_2_, p_76986_4_, p_76986_6_, p_76986_8_, p_76986_9_);
}
}
public static class ModelWhip extends ModelBase
{
//fields
ModelRenderer whip;
public ModelWhip()
{
textureWidth = 64;
textureHeight = 32;
whip = new ModelRenderer(this, 2, 1);
whip.addBox(0F, 0F, 0F, 1, 0, 16);
whip.setRotationPoint(-5F, 16F, -23F);
whip.setTextureSize(64, 32);
whip.mirror = true;
setRotation(whip, 0F, 0F, 0F);
}
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
{
super.render(entity, f, f1, f2, f3, f4, f5);
whip.render(f5);
}
private void setRotation(ModelRenderer model, float x, float y, float z)
{
model.rotateAngleX = x;
model.rotateAngleY = y;
model.rotateAngleZ = z;
}
}
}
So, in the impact part I want it to be so where entity hits block player is telaported there.
Can anyone help?
Is EntityHook name of your class?
@#8
I changed every name in code, and still same error.
it keeps saying things in here are wrong:
public EntityPlayer field_146042_b;
public EntityHook(World par1World, double par2, double par4, double par6)
{
super(par1World, par2, par4, par6);
}
public EntityHook(World par1World, EntityLivingBase par2EntityLivingBase)
{
super(par1World, par2EntityLivingBase);
}
public EntityHook(World par1World)
{
super(par1World);
}
public EntityHook(World par1World, EntityLivingBase par2EntityLivingBase, EntityPlayer player)
{
super(par1World, par2EntityLivingBase);
this.field_146042_b = player;
}
Do you know that by "Also do not forge change the entity name to yours" I meant change the one in the code I wrote to yours , not your to the on in the code?
@#9
like this?
@SuppressWarnings("unchecked")
public class mcreator_yoYo {
public static int mobid = 0;
public Object instance;
public void load(){}
public void generateNether(World world, Random random, int chunkX, int chunkZ){}
public void generateSurface(World world, Random random, int chunkX, int chunkZ){}
public int addFuel(ItemStack fuel){
return 0;
}
@SideOnly(Side.CLIENT)
public void registerRenderers(){
RenderingRegistry.registerEntityRenderingHandler(mcreator_yoYo.EntityyoYo.class, new RenderFish());
}
public void serverLoad(FMLServerStartingEvent event){}
public void preInit(FMLPreInitializationEvent event){
int entityID = EntityRegistry.findGlobalUniqueEntityId();
mobid = entityID;
EntityRegistry.registerGlobalEntityID(mcreator_yoYo.EntityyoYo.class, "yoYo", entityID);
EntityRegistry.registerModEntity(mcreator_yoYo.EntityyoYo.class, "yoYo", entityID, instance, 64, 1, true);
}
public static class EntityHook extends EntityThrowable{
public EntityHook(World world , Entity entity){
}
//SOME MORE STUFF
public void onUpdate()
{
super.onUpdate();
if(this.isCollided){
this.motionX = 0d;
this.motionY = 0d;
this.motionZ = 0d;
}
}
}
public EntityPlayer field_146042_b;
public EntityyoYo(World par1World, double par2, double par4, double par6)
{
super(par1World, par2, par4, par6);
}
public EntityyoYo(World par1World, EntityLivingBase par2EntityLivingBase)
{
super(par1World, par2EntityLivingBase);
}
public EntityyoYo(World par1World)
{
super(par1World);
}
public EntityyoYo(World par1World, EntityLivingBase par2EntityLivingBase, EntityPlayer player)
{
super(par1World, par2EntityLivingBase);
this.field_146042_b = player;
}
@#9
Hmm, I still get the same error as before.
@#9.2
A) change every EntityHook to EntityyoYo
B) change every EntityyoYo to EntityHook
@#9.2.1
like this?
@SuppressWarnings("unchecked")
public class mcreator_yoYo {
public static int mobid = 0;
public Object instance;
public void load(){}
public void generateNether(World world, Random random, int chunkX, int chunkZ){}
public void generateSurface(World world, Random random, int chunkX, int chunkZ){}
public int addFuel(ItemStack fuel){
return 0;
}
@SideOnly(Side.CLIENT)
public void registerRenderers(){
RenderingRegistry.registerEntityRenderingHandler(mcreator_yoYo.EntityHook.class, new RenderFish());
}
public void serverLoad(FMLServerStartingEvent event){}
public void preInit(FMLPreInitializationEvent event){
int entityID = EntityRegistry.findGlobalUniqueEntityId();
mobid = entityID;
EntityRegistry.registerGlobalEntityID(mcreator_yoYo.EntityHook.class, "yoYo", entityID);
EntityRegistry.registerModEntity(mcreator_yoYo.EntityHook.class, "yoYo", entityID, instance, 64, 1, true);
}
public static class EntityyoYo extends EntityThrowable{
public EntityyoYo(World world , Entity entity){
}
//SOME MORE STUFF
public void onUpdate()
{
super.onUpdate();
if(this.isCollided){
this.motionX = 0d;
this.motionY = 0d;
this.motionZ = 0d;
}
}
}
public EntityPlayer field_146042_b;
public EntityHook(World par1World, double par2, double par4, double par6)
{
super(par1World, par2, par4, par6);
}
public EntityHook(World par1World, EntityLivingBase par2EntityLivingBase)
{
super(par1World, par2EntityLivingBase);
}
public EntityHook(World par1World)
{
super(par1World);
}
public EntityHook(World par1World, EntityLivingBase par2EntityLivingBase, EntityPlayer player)
{
super(par1World, par2EntityLivingBase);
this.field_146042_b = player;
}
I did it in order.
But wouldn't every EntityyoYo be EntityHook?
@#9.2.1
Item Code is not working:/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:158: error: unclosed string literal
>EntityYoyo yoyo = par2World.getEntityByID(par1ItemStack.getTagCompound().getInteger("yoyo));
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:158: error: ')' expected
>EntityYoyo yoyo = par2World.getEntityByID(par1ItemStack.getTagCompound().getInteger("yoyo));
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:159: error: ';' expected
>if(yoyo == null){
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:159: error: not a statement
>if(yoyo == null){
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:159: error: ';' expected
>if(yoyo == null){
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:162: error: unclosed string literal
>par1ItemStack.getTagCompound().setInteger("yoyo,yoyo.getEntityId());
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:162: error: ';' expected
>par1ItemStack.getTagCompound().setInteger("yoyo,yoyo.getEntityId());
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:164: error: illegal start of expression
>par2World.spawnEntityInWorld(yoyo);
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:164: error: ';' expected
>par2World.spawnEntityInWorld(yoyo);
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:164: error: not a statement
>par2World.spawnEntityInWorld(yoyo);
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:164: error: ';' expected
>par2World.spawnEntityInWorld(yoyo);
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:165: error: 'else' without 'if'
>}else{
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:184: error: illegal start of type
>return par1ItemStack;
>^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:184: error: ';' expected
>return par1ItemStack;
> ^
>/Applications/MCreator 1.5.9 [1.7.10] Mac-Linux/forge/build/sources/java/mod/mcreator/mcreator_smokeyQuartzsYoYo.java:188: error: class, interface, or enum expected
>}}
>^
>15 errors
You dont even have to make it in Code! Use the Gun Section, Then make an Event saying When Bullet Hits Block, TP to I,J,K, (I J K = Exact Location)
Or make an item if you don't want far teleports