Jump to content

Recommended Posts

Posted

I'm trying to render a custom entity, pretty simple really. but my rendering code never seems to get called, what am I doing wrong?

 

Entity

package opticraft.entitys;

import net.minecraft.entity.Entity;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;

public class EntityBeam extends Entity {

public String orientation;

public EntityBeam(World par1World, String orientation) {
	super(par1World);
	this.orientation = orientation;
}

@Override
protected void entityInit() {

}

@Override
protected void readEntityFromNBT(NBTTagCompound nbttagcompound) {
	// TODO Auto-generated method stub

}

@Override
protected void writeEntityToNBT(NBTTagCompound nbttagcompound) {
	// TODO Auto-generated method stub

}

}

 

Render

package opticraft.render;

import opticraft.entitys.EntityBeam;
import opticraft.lib.ModInfo;
import opticraft.lib.Names;
import opticraft.models.BeamModel;

import org.lwjgl.opengl.GL11;

import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.EntityRenderer;
import net.minecraft.client.renderer.OpenGlHelper;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.entity.Entity;
import net.minecraft.client.renderer.entity.Render;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ResourceLocation;
import net.minecraft.world.World;

public class BeamRenderer extends Render{

private final BeamModel model;
private String orientation = "LR";
    
    public BeamRenderer() {
            this.model = new BeamModel();
            System.out.println("RENDER CONSTRUCTED");
    }
    
    private void adjustRotatePivotViaMeta(World world, int x, int y, int z) {
            int meta = world.getBlockMetadata(x, y, z);
            GL11.glPushMatrix();
            GL11.glRotatef(meta * (-90), 0.0F, 0.0F, 1.0F);
            GL11.glPopMatrix();
    }

    //Set the lighting stuff, so it changes it's brightness properly.       
    private void adjustLightFixture(World world, int i, int j, int k, Block block) {
            Tessellator tess = Tessellator.instance;
            float brightness = block.getBlockBrightness(world, i, j, k);
            int skyLight = world.getLightBrightnessForSkyBlocks(i, j, k, 0);
            int modulousModifier = skyLight % 65536;
            int divModifier = skyLight / 65536;
            tess.setColorOpaque_F(brightness, brightness, brightness);
            OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit,  (float) modulousModifier,  divModifier);
    }

@Override
public void doRender(Entity entity, double x, double y, double z,
		float f, float f1) {

	System.out.println("RENDER CALLED");

	//The PushMatrix tells the renderer to "start" doing something.
        GL11.glPushMatrix();
//This is setting the initial location.
        GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
//This is the texture of your block. It's pathed to be the same place as your other blocks here.
        //Outdated bindTextureByName("/mods/roads/textures/blocks/TrafficLightPoleRed.png");
//Use in 1.6.2  this
        ResourceLocation textures = (new ResourceLocation(ModInfo.ID.toLowerCase() + ":textures/blocks/beamTile.png"));
        
//the ':' is very important
//binding the textures
        Minecraft.getMinecraft().renderEngine.bindTexture(textures);

//This rotation part is very important! Without it, your model will render upside-down! And for some reason you DO need PushMatrix again!                       
        GL11.glPushMatrix();
        GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
//A reference to your Model file. Again, very important.
        this.model.render((Entity)entity, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
//Tell it to stop rendering for both the PushMatrix's
        GL11.glPopMatrix();
        GL11.glPopMatrix();            
        
        model.LR.isHidden = true;
        model.FB.isHidden = true;
        model.TB.isHidden = true;
        
        EntityBeam ent = (EntityBeam) entity;
        orientation = ent.orientation;
        if(orientation == "LR")
        	model.LR.isHidden = false;
        else if(orientation == "FB")
        	model.FB.isHidden = false;
        else if(orientation == "UD")
        	model.TB.isHidden = false;
        else{
        	model.LR.isHidden = false;
            model.FB.isHidden = false;
            model.TB.isHidden = false;
        }

}

@Override
protected ResourceLocation getEntityTexture(Entity entity) {

	return new ResourceLocation(ModInfo.ID.toLowerCase() + ":textures/blocks/beamTile.png");
}

}

 

Client Proxy

package opticraft.proxies;

import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
import opticraft.Opticraft;
import opticraft.entitys.EntityBeam;
import opticraft.entitys.TileEntityItemLaser;
import opticraft.entitys.TileEntityLaserDetector;
import opticraft.entitys.TileEntitySolarCollector;
import opticraft.items.ItemLaserWrench;
import opticraft.lib.Ids;
import opticraft.render.BeamRenderer;
import opticraft.render.ItemLaserRenderer;
import opticraft.render.LaserDetectorRenderer;
import opticraft.render.LaserWrenchRenderer;
import opticraft.render.SolarCollectorRenderer;
import cpw.mods.fml.client.registry.ClientRegistry;
import cpw.mods.fml.client.registry.RenderingRegistry;
import cpw.mods.fml.common.registry.EntityRegistry;

public class ClientProxy extends CommonProxy{

@Override
public void initRenderers() {

}

@Override
public void initSounds() {

}

public void registerRenderThings() {
    	ClientRegistry.bindTileEntitySpecialRenderer(TileEntityItemLaser.class, new ItemLaserRenderer());
    	ClientRegistry.bindTileEntitySpecialRenderer(TileEntitySolarCollector.class, new SolarCollectorRenderer());
    	ClientRegistry.bindTileEntitySpecialRenderer(TileEntityLaserDetector.class, new LaserDetectorRenderer());
    	
    	RenderingRegistry.registerEntityRenderingHandler(EntityBeam.class, new BeamRenderer());
    	
    	MinecraftForgeClient.registerItemRenderer(Ids.laserWrench + 256, (IItemRenderer)new LaserWrenchRenderer());
}	
}

 

Main class

package opticraft;

import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
import opticraft.blocks.Blocks;
import opticraft.client.gui.GuiHandler;
import opticraft.entitys.EntityBeam;
import opticraft.entitys.TileEntityItemLaser;
import opticraft.entitys.TileEntityLaserDetector;
import opticraft.entitys.TileEntitySolarCollector;
import opticraft.items.Items;
import opticraft.items.ItemLaserWrench;
import opticraft.lib.Ids;
import opticraft.lib.ModInfo;
import opticraft.proxies.CommonProxy;
import opticraft.render.LaserWrenchRenderer;
import cpw.mods.fml.client.registry.ClientRegistry;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.Instance;
import cpw.mods.fml.common.SidedProxy;
import cpw.mods.fml.common.Mod.EventHandler;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
import cpw.mods.fml.common.network.NetworkMod;
import cpw.mods.fml.common.network.NetworkRegistry;
import cpw.mods.fml.common.registry.EntityRegistry;
import cpw.mods.fml.common.registry.GameRegistry;

@Mod(modid = ModInfo.ID, name = ModInfo.NAME, version = ModInfo.VERSION)
@NetworkMod (channels = {ModInfo.CHANNEL}, clientSideRequired = true, serverSideRequired = true)
public class Opticraft {

private GuiHandler guiHandler = new GuiHandler();

@Instance
public static Opticraft instance = new Opticraft();

@SidedProxy( clientSide = ModInfo.PROXY_LOCATION + ".ClientProxy", serverSide = ModInfo.PROXY_LOCATION + ".CommonProxy")
public static CommonProxy proxy;

@EventHandler
public void preInit(FMLPreInitializationEvent event) {	
	proxy.initRenderers();
	proxy.initSounds();

	Items.init();
	Items.addNames();

	Blocks.init();
	Blocks.addNames();
}

@EventHandler
public void init(FMLInitializationEvent event) {

	NetworkRegistry.instance().registerGuiHandler(this, guiHandler);

	EntityRegistry.registerModEntity(EntityBeam.class, "EntityBeam", EntityRegistry.findGlobalUniqueEntityId(), this, 128, 1, true);
	proxy.registerRenderThings();

        GameRegistry.registerTileEntity(TileEntityItemLaser.class, "tileEntityItemLaser");
        GameRegistry.registerTileEntity(TileEntitySolarCollector.class, "tileEntitySolarCollector");
        GameRegistry.registerTileEntity(TileEntityLaserDetector.class, "tileEntityLaserDetector");
              
}

@EventHandler
public void postInit(FMLPostInitializationEvent event) {

}
}

Posted

Updated the part which actually initiates the Entity:

 

for(int i = this.yCoord; i <= linkedDetector.y - 1; i++){
						if (!worldObj.isRemote){
							EntityBeam entity = new EntityBeam(worldObj, "UD");
							entity.setPosition(xCoord, yCoord + i, zCoord);
							worldObj.spawnEntityInWorld(entity);
							//worldObj.playSoundEffect((double)xCoord + 0.5D, (double)yCoord + 0.5D, (double)zCoord + 0.5D, "random.fizz",  0.1F, worldObj.rand.nextFloat() * 0.1F + 0.9F);
						}

					}

 

It appears from my debug line the renderer is never getting called. But it is getting initiated...

 

No one got any idea?

Posted

I don't know exactly what your problem is, but here is what I have to render an entity. I was trying to copy and paste your code, but there are some classes that I needed.

 

MagicSpellsMod.java - Main Class

package codemeister88.minecraft.src;

import net.minecraft.item.Item;
import net.minecraftforge.common.Configuration;
import codemeister88.minecraft.entity.EntityEarthGolem;
import codemeister88.minecraft.item.ItemEarthSpellbook;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.EventHandler;
import cpw.mods.fml.common.Mod.Instance;
import cpw.mods.fml.common.SidedProxy;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
import cpw.mods.fml.common.network.NetworkMod;
import cpw.mods.fml.common.registry.EntityRegistry;

@Mod(modid="MagicSpellsMod", name="Magic Spells", version="1.2.1")
@NetworkMod(clientSideRequired=true, serverSideRequired=false)
public class MagicSpellsMod {

    // The instance of your mod that Forge uses.
    @Instance("MagicSpellsMod")
    public static MagicSpellsMod instance;
    
    /*
     * Items
     */
    
    //holds the ids of the items
    public static int[] itemIDs = new int[1];
    
    //Earth Spell
    public static Item earthSpellbook;
   
    // Says where the client and server 'proxy' code is loaded.
    @SidedProxy(clientSide="codemeister88.minecraft.client.ClientProxy", serverSide="codemeister88.minecraft.src.CommonProxy")
    public static CommonProxy proxy;
    
    @EventHandler
    public void preInit(FMLPreInitializationEvent event) {
    	Configuration config = new Configuration(event.getSuggestedConfigurationFile());
    	config.load();
    	
    	itemIDs[0] = config.getItem("EarthSpellbook", 5010).getInt();
    	
    	config.save();
    }
    
    @EventHandler
    public void load(FMLInitializationEvent event) {
        proxy.registerRenderers();
        
        //Earth Spell
        earthSpellbook = new ItemEarthSpellbook(itemIDs[0], 1);
        
        EntityRegistry.registerModEntity(EntityEarthGolem.class, "EarthGolem", 3, instance, 80, 1, true);
    }
    
    @EventHandler
    public void postInit(FMLPostInitializationEvent event) {
    }
}

 

CommonProxy.java

package codemeister88.minecraft.src;

import cpw.mods.fml.client.registry.RenderingRegistry;

public class CommonProxy {
public void registerRenderers() {
}
}

 

ItemSpellbook.java

package codemeister88.minecraft.item;

import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.EnumAction;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;

public abstract class ItemSpellbook extends Item {
protected String spellName;
protected int spellLevel;

public ItemSpellbook(int par1, String spellName, int spellLevel) {
	super(par1);

	this.maxStackSize = 1;
	this.setMaxDamage(256);
        this.setCreativeTab(CreativeTabs.tabCombat);
        this.setUnlocalizedName("spellbook");
        
        this.spellName = spellName;
        this.spellLevel = spellLevel;
        
        setTextureName("book_enchanted");
}

public ItemSpellbook setSpellLevel(int spellLevel) {
	if(spellLevel > 0) {
		this.spellLevel = spellLevel;
	} else {
		this.spellLevel = 1;
	}

	return this;
}

public int getSpellLevel() {
	return spellLevel;
}

    /**
     * returns the action that specifies what animation to play when the items is being used
     */
    public EnumAction getItemUseAction(ItemStack par1ItemStack)
    {
        return EnumAction.block;
    }
    
/**
     * Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer
     */
    public abstract ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer);
    
    /**
     * Returns the unlocalized name of this item. This version accepts an ItemStack so different stacks can have
     * different names based on their damage or NBT.
     */
    public String getUnlocalizedName(ItemStack par1ItemStack)
    {
    	return super.getUnlocalizedName(par1ItemStack) + "." + spellName + spellLevel;
    }
    
    public String getItemDisplayName(ItemStack par1ItemStack)
    {
    	return spellName + " Spellbook " + spellLevel;
    }
}

 

ItemEarthSpellbook.java

package codemeister88.minecraft.item;

import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import codemeister88.minecraft.entity.EntityEarthGolem;

public class ItemEarthSpellbook extends ItemSpellbook {
private boolean entitySpawned = false;

public ItemEarthSpellbook(int par1, int spellLevel) {
	super(par1, "Earth", spellLevel);
}

@Override
public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) {
    	par3EntityPlayer.setItemInUse(par1ItemStack, this.getMaxItemUseDuration(par1ItemStack));
    	
    	par2World.playSoundAtEntity(par3EntityPlayer, "random.bow", 0.5F, 0.4F / (itemRand.nextFloat() * 0.4F + 0.8F));

        if (!par2World.isRemote) {
        	EntityEarthGolem entityEarthGolem = new EntityEarthGolem(par2World);
        	entityEarthGolem.setLocationAndAngles(par3EntityPlayer.posX, par3EntityPlayer.posY, par3EntityPlayer.posZ, 0.0F, 0.0F);
        	System.out.println("Spawn Golem");
            par2World.spawnEntityInWorld(entityEarthGolem);
            entitySpawned = true;
        }

        return par1ItemStack;
}

}

 

EntityEarthGolem.java

package codemeister88.minecraft.entity;

import net.minecraft.entity.EntityAgeable;
import net.minecraft.entity.EntityCreature;
import net.minecraft.entity.EntityLiving;
import net.minecraft.entity.ai.EntityAIAttackOnCollide;
import net.minecraft.entity.ai.EntityAIFollowParent;
import net.minecraft.entity.ai.EntityAIHurtByTarget;
import net.minecraft.entity.ai.EntityAILookAtVillager;
import net.minecraft.entity.ai.EntityAILookIdle;
import net.minecraft.entity.ai.EntityAIMoveThroughVillage;
import net.minecraft.entity.ai.EntityAIMoveTowardsRestriction;
import net.minecraft.entity.ai.EntityAIMoveTowardsTarget;
import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
import net.minecraft.entity.ai.EntityAIOwnerHurtByTarget;
import net.minecraft.entity.ai.EntityAIOwnerHurtTarget;
import net.minecraft.entity.ai.EntityAIWander;
import net.minecraft.entity.ai.EntityAIWatchClosest;
import net.minecraft.entity.monster.IMob;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;

public class EntityEarthGolem extends EntityCreature {

    public EntityEarthGolem(World par1World) {
        super(par1World);
        
//        getNavigator().setEnterDoors(true);
        
//        this.tasks.addTask(1, new EntityAIAttackOnCollide(this, 1.0D, true));
//        this.tasks.addTask(2, new EntityAIFollowOwner(this, 1.0D, 10.0F, 2.0F));
//        this.tasks.addTask(3, new EntityAIWander(this, 1.0D));
//        this.tasks.addTask(4, new EntityAILookIdle(this));
        this.tasks.addTask(1, new EntityAIAttackOnCollide(this, 1.0D, true));
        this.tasks.addTask(2, new EntityAIMoveTowardsTarget(this, 0.9D, 32.0F));
        this.tasks.addTask(3, new EntityAIWander(this, 0.6D));
        this.tasks.addTask(4, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
        this.tasks.addTask(5, new EntityAILookIdle(this));
        
//        this.targetTasks.addTask(1, new EntityAIOwnerHurtByTarget(this));
//        this.targetTasks.addTask(2, new EntityAIOwnerHurtTarget(this));
//        this.targetTasks.addTask(3, new EntityAIHurtByTarget(this, true));
        
        this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
        this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, true, true, IMob.mobSelector));
    }
    
    /**
     * Plays step sound at given x, y, z for the entity
     */
    protected void playStepSound(int par1, int par2, int par3, int par4) {
        this.playSound("gravel", 0.15F, 1.0F);
    }
}

 

RenderEarthGolem.java

package codemeister88.minecraft.client.renderer.entity;

import codemeister88.minecraft.client.model.ModelEarthGolem;
import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelIronGolem;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.entity.Entity;
import net.minecraft.util.ResourceLocation;

public class RenderEarthGolem extends RenderLiving {

private static final ResourceLocation earthGolemTextures = new ResourceLocation("codemeister88:textures/entity/earth_golem.png");



public RenderEarthGolem() {
	super(new ModelEarthGolem(), 0.5F);
}

@Override
protected ResourceLocation getEntityTexture(Entity entity) {
	return earthGolemTextures;
}

}

 

ClientProxy.java

package codemeister88.minecraft.client;

import net.minecraft.src.ModLoader;
import codemeister88.minecraft.client.renderer.entity.RenderEarthGolem;
import codemeister88.minecraft.entity.EntityEarthGolem;
import codemeister88.minecraft.src.CommonProxy;
import cpw.mods.fml.client.registry.RenderingRegistry;
import cpw.mods.fml.common.registry.EntityRegistry;

public class ClientProxy extends CommonProxy {
@Override
public void registerRenderers() {
	super.registerRenderers();

	EntityRegistry.registerGlobalEntityID(EntityEarthGolem.class, "EarthGolem", ModLoader.getUniqueEntityId());
	RenderingRegistry.registerEntityRenderingHandler(EntityEarthGolem.class, new RenderEarthGolem());
}
}

 

ModelEarthGolem.java

package codemeister88.minecraft.client.model;

import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity;
import net.minecraft.util.MathHelper;

@SideOnly(Side.CLIENT)
public class ModelEarthGolem extends ModelBase {
/*
 * Model each part of the entity
 */
ModelRenderer body;
    ModelRenderer rightArm;
    ModelRenderer leftArm;
    ModelRenderer head;
    ModelRenderer leftLeg;
    ModelRenderer rightLeg;
    
    public ModelEarthGolem() {
        head = new ModelRenderer(this, 0, 0);
        head.addBox(-4F, -8F, -4F, 8, 8, ;
        head.setRotationPoint(0F, 0F, 0F);
        body = new ModelRenderer(this, 0, 16);
        body.addBox(-4F, 0F, -2F, 8, 12, 4);
        body.setRotationPoint(0F, 0F, 0F);
        rightArm = new ModelRenderer(this, 48, 0);
        rightArm.addBox(0F, 0F, -2F, 4, 12, 4);
        rightArm.setRotationPoint(4F, 0F, 0F);
        leftArm = new ModelRenderer(this, 32, 0);
        leftArm.addBox(-4F, 0F, -2F, 4, 12, 4);
        leftArm.setRotationPoint(-4F, 0F, 0F);
        leftLeg = new ModelRenderer(this, 24, 16);
        leftLeg.addBox(-2F, 0F, -2F, 4, 12, 4);
        leftLeg.setRotationPoint(-2F, 12F, 0F);
        rightLeg = new ModelRenderer(this, 40, 16);
        rightLeg.addBox(-2F, 0F, -2F, 4, 12, 4);
        rightLeg.setRotationPoint(2F, 12F, 0F);
    }
    
    @Override
    public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5) {
    	setRotationAngles(f, f1, f2, f3, f4, f5, entity);
    	body.render(f5);
    	rightArm.render(f5);
    	leftArm.render(f5);
    	head.render(f5);
    	leftLeg.render(f5);
    	rightLeg.render(f5);
    }
  
    @Override
public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity entity) {
    	head.rotateAngleY = par4 / (180F / (float)Math.PI);
        head.rotateAngleX = par5 / (180F / (float)Math.PI);
        rightArm.rotateAngleX = MathHelper.cos(par1 * 0.6662F + (float)Math.PI) * 2.0F * par2 * 0.5F;
        rightArm.rotateAngleZ = 0.0F;
        leftArm.rotateAngleX = MathHelper.cos(par1 * 0.6662F) * 2.0F * par2 * 0.5F;
        leftArm.rotateAngleZ = 0.0F;
        rightLeg.rotateAngleX = MathHelper.cos(par1 * 0.6662F) * 1.4F * par2;
        rightLeg.rotateAngleY = 0.0F;
        leftLeg.rotateAngleX = MathHelper.cos(par1 * 0.6662F + (float)Math.PI) * 1.4F * par2;
        leftLeg.rotateAngleY = 0.0F;
    }
}

Posted

Okay, I have taken a small look at your code.

 

From tracing, I found that it isn't entering the block to spawn the entity.

 

This doesn't work out to true:

 

if(ent.getStackInSlot(0) == null && getStackInSlot(0) != null){
}

 

I ent.getStackInSlot(0) returns true, but getStackInSlot(0) returns false.

 

I'm going to continue to take a look and see where you are adding them into the array.

Posted

Yeah...sorry I was having issues getting it to work, but I have gotten past that point.

 

Now I see where it is you are having issues, but my thought would be to use a block as the beam instead of an entity? I would make try to mimic how the redstone works when it is placed. Or is there a specific reason for using an entity?

Posted

So you know where the problem lies with the entity?

 

I was originally going to use a tileentity for this, but then i also want it to go through transparent surfaces, e.g glass.. so an entity seemed like a better solution. If i cant get it to work ill go back to a tileentity and just make it only go through air.

Posted

So actually it appears that it is working...it spawns the entity; however the spawn location is clear up in the clouds.

 

Inside TileEntityItemLaster.java:

 

Change:

entity.setPosition(xCoord, yCoord + i, zCoord);

 

To:

entity.setPosition(xCoord, i, zCoord);

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I fall into the void if I fly the rocket to the earth, and dying or respawning just brings me back to the moon.   Error Code:  Found matching world (0) for name: Overworld [00:22:40] [Client thread/INFO]:Adding world access to world net.minecraft.client.multiplayer.WorldClient@73fa708 [00:22:41] [CraftPresence/ERROR]:Asset name "overworld" does not exist, attempting to use an alternative icon "galacticscience"... [00:22:41] [CraftPresence/INFO]:To add support for this icon, please request for this icon to be added to the default Client ID or add the icon under the following name: "overworld". [00:22:41] [CraftPresence/INFO]:Fallback icon for "overworld" found! Using a fallback icon with the name "galacticscience"! [00:22:42] [Server thread/INFO]:Server attempting to transfer player IcyBlues9 to dimension 0 [00:22:42] [Server thread/ERROR]:"Silently" catching entity tracking error.   How can i fix it?      
    • If you remove armorchroma does it still crash?
    • Hello everyone!   I’ve launched a Christian Minecraft server today called “Acolyte”. Although it’s a Christian server, it’s open to anyone, but the main goal of me pursuing this was to combine two things that I love and make an area where people can talk about faith and build some cool castles. The server is meant for Java edition, 1.21.5, and has plugins such as land claiming, economy, shops, terrain generation, etc. It’s a survival / smp world, and the server address is: acolyte.mcsrv.pro   There’s a Discord server linked to it as well. It’s a place to hangout, talk about the game, have theological discussions, and hopefully meet some pretty cool people. The invite is available on the Minecraft server. I’m still new to a lot of this, and so please forgive any downtime or tweaks that I make to the server, and please give any feedback or criticism if you come up with some ideas. I truly hope you all enjoy it if you get the chance to join.   - ChedduhCheese   acolyte.mcsrv.pro
    • My Crazy Craft Updated pack for 1.16.5 crashes whenever I use items from Mowzie's Mobs that have animations. Specifically the ones that I have tried are the Ice Crystal and the Axe of a Thousand Metals. The crash only happens when I use the ability of it, aka right click, which triggers the animation. I should note that I added around 50 other mods to the pack, two of which are the Female Gender mod and More Player Models. Could they be the source of the crash? Here is the crash log: https://mclo.gs/ZhsC793
    • Hello, i've tried to make a minecraft server for my friends on old laptop. But im getting this error   ---- Minecraft Crash Report ---- WARNING: coremods are present:   DCLoadingPlugin (DummyCoreUnofficial-2.4.112.3.jar)   HCASM (HammerLib-1.12.2-2.0.6.23.jar) Contact their authors BEFORE contacting forge // I feel sad now Time: 19.06.25 22:26 Description: Exception in server tick loop java.lang.NoClassDefFoundError: net/minecraft/client/Minecraft     at nukeduck.armorchroma.ArmorChroma.<clinit>(ArmorChroma.java:23)     at java.lang.Class.forName0(Native Method)     at java.lang.Class.forName(Class.java:348)     at net.minecraftforge.fml.common.FMLModContainer.constructMod(FMLModContainer.java:539)     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)     at java.lang.reflect.Method.invoke(Method.java:498)     at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)     at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)     at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)     at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)     at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)     at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)     at com.google.common.eventbus.EventBus.post(EventBus.java:217)     at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:219)     at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:197)     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)     at java.lang.reflect.Method.invoke(Method.java:498)     at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)     at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)     at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)     at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)     at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)     at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)     at com.google.common.eventbus.EventBus.post(EventBus.java:217)     at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:136)     at net.minecraftforge.fml.common.Loader.loadMods(Loader.java:595)     at net.minecraftforge.fml.server.FMLServerHandler.beginServerLoading(FMLServerHandler.java:98)     at net.minecraftforge.fml.common.FMLCommonHandler.onServerStart(FMLCommonHandler.java:333)     at net.minecraft.server.dedicated.DedicatedServer.func_71197_b(DedicatedServer.java:125)     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:486)     at java.lang.Thread.run(Thread.java:750) Caused by: java.lang.ClassNotFoundException: net.minecraft.client.Minecraft     at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:191)     at java.lang.ClassLoader.loadClass(ClassLoader.java:418)     at java.lang.ClassLoader.loadClass(ClassLoader.java:351)     ... 35 more Caused by: net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerException: Exception in class transformer net.minecraftforge.fml.common.asm.transformers.SideTransformer@57fae983 from coremod FMLCorePlugin     at net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerWrapper.transform(ASMTransformerWrapper.java:260)     at net.minecraft.launchwrapper.LaunchClassLoader.runTransformers(LaunchClassLoader.java:279)     at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:176)     ... 37 more Caused by: java.lang.RuntimeException: Attempted to load class bib for invalid side SERVER     at net.minecraftforge.fml.common.asm.transformers.SideTransformer.transform(SideTransformer.java:62)     at net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerWrapper.transform(ASMTransformerWrapper.java:256)     ... 39 more A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- System Details -- Details:     Minecraft Version: 1.12.2     Operating System: Linux (amd64) version 6.8.0-51-generic     Java Version: 1.8.0_452, Private Build     Java VM Version: OpenJDK 64-Bit Server VM (mixed mode), Private Build     Memory: 1088926088 bytes (1038 MB) / 1634205696 bytes (1558 MB) up to 4194304000 bytes (4000 MB)     JVM Flags: 2 total; -Xms1024M -Xmx4500M     IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0     FML: MCP 9.42 Powered by Forge 14.23.5.2859 44 mods loaded, 44 mods active     States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored     | State | ID                       | Version            | Source                                        | Signature                                |     |:----- |:------------------------ |:------------------ |:--------------------------------------------- |:---------------------------------------- |     | LC    | minecraft                | 1.12.2             | minecraft.jar                                 | None                                     |     | LC    | mcp                      | 9.42               | minecraft.jar                                 | None                                     |     | LC    | FML                      | 8.0.99.99          | forge-1.12.2-14.23.5.2859.jar                 | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | LC    | forge                    | 14.23.5.2859       | forge-1.12.2-14.23.5.2859.jar                 | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | LC    | codechickenlib           | 3.2.3.358          | CodeChickenLib-1.12.2-3.2.3.358-universal.jar | f1850c39b2516232a2108a7bd84d1cb5df93b261 |     | LC    | ancientwarfare           | 1.12.2-2.7.0.1032  | ancientwarfare-1.12.2-2.7.0.1032.jar          | None                                     |     | LC    | ancientwarfareautomation | 1.12.2-2.7.0.1032  | ancientwarfare-1.12.2-2.7.0.1032.jar          | None                                     |     | LC    | ancientwarfarenpc        | 1.12.2-2.7.0.1032  | ancientwarfare-1.12.2-2.7.0.1032.jar          | None                                     |     | LC    | ancientwarfarestructure  | 1.12.2-2.7.0.1032  | ancientwarfare-1.12.2-2.7.0.1032.jar          | None                                     |     | LC    | ancientwarfarevehicle    | 1.12.2-2.7.0.1032  | ancientwarfare-1.12.2-2.7.0.1032.jar          | None                                     |     | L     | armorchroma              | 1.4-beta           | armorchroma-1.12.2-1.4.jar                    | None                                     |     | L     | baubles                  | 1.5.2              | Baubles-1.12-1.5.2.jar                        | None                                     |     | L     | betterburning            | 0.9.2              | BetterBurning-1.12.2-0.9.2.jar                | None                                     |     | L     | bettercaves              | 1.12.2             | bettercaves-1.12.2-2.0.4.jar                  | None                                     |     | L     | betterinvisibility       | 1.0.1              | betterinvisibility-1.0.1.jar                  | None                                     |     | L     | bettermineshafts         | 1.12.2-2.2         | BetterMineshaftsForge-1.12.2-2.2.jar          | None                                     |     | L     | bookshelf                | 2.3.590            | Bookshelf-1.12.2-2.3.590.jar                  | None                                     |     | L     | collective               | 2.11               | collective-1.12.2-2.11.jar                    | None                                     |     | L     | extendedrenderer         | v1.0               | coroutil-1.12.1-1.2.37.jar                    | None                                     |     | L     | coroutil                 | 1.12.1-1.2.37      | coroutil-1.12.1-1.2.37.jar                    | None                                     |     | L     | configmod                | v1.0               | coroutil-1.12.1-1.2.37.jar                    | None                                     |     | L     | dummycore                | 2.4.112.3.         | DummyCoreUnofficial-2.4.112.3.jar             | None                                     |     | L     | dynamictrees             | 1.12.2-0.9.22      | DynamicTrees-1.12.2-0.9.22.jar                | None                                     |     | L     | thaumcraft               | 6.1.BETA26         | Thaumcraft_1.12.2_6.1.BETA26.jar              | None                                     |     | L     | dynamictreestc           | 1.12.2-1.4.2       | DynamicTreesTC-1.12.2-1.4.2.jar               | None                                     |     | L     | hammercore               | 2.0.6.23           | HammerLib-1.12.2-2.0.6.23.jar                 | None                                     |     | L     | waila                    | 1.8.26             | Hwyla-1.8.26-B41_1.12.2.jar                   | None                                     |     | L     | jei                      | 4.16.1.302         | jei_1.12.2-4.16.1.302.jar                     | None                                     |     | L     | keepinginventory         | 2.4                | KeepingInventory-1.12.2-2.4.jar               | None                                     |     | L     | libraryex                | 1.2.1              | LibraryEx-1.12.2-1.2.1.jar                    | None                                     |     | L     | netherex                 | 2.2.4              | NetherEx-1.12.2-2.2.4.jar                     | None                                     |     | L     | recipehandler            | 0.13               | NoMoreRecipeConflict-0.13(1.12.2).jar         | None                                     |     | L     | nei                      | 2.4.3              | NotEnoughItems-1.12.2-2.4.3.245-universal.jar | None                                     |     | L     | thaumadditions           | 12.6.6             | ThaumicAdditions-1.12.2-12.6.6.jar            | None                                     |     | L     | thaumicbases             | 3.3.500.6r         | thaumicbases-3.3.500.6r.jar                   | None                                     |     | L     | thaumictinkerer          | 1.12.2-5.0-620a0c5 | thaumictinkerer-1.12.2-5.0-620a0c5.jar        | None                                     |     | L     | thaumicwaila             | 1.12.2-0.0.2       | ThaumicWaila-1.12.2-0.0.2.jar                 | None                                     |     | L     | tumbleweed               | 1.12-0.4.7         | tumbleweed-1.12-0.4.7.jar                     | None                                     |     | L     | villagespawnpoint        | 1.5                | villagespawnpoint_1.12.2-1.5.jar              | None                                     |     | L     | wawla                    | 2.6.275            | Wawla-1.12.2-2.6.275.jar                      | None                                     |     | L     | wooltostring             | 1.12.2             | WoolToString-1.12.2-1.0.0.jar                 | None                                     |     | L     | zombieawareness          | 1.12.1-1.11.16     | zombieawareness-1.12.1-1.11.16.jar            | None                                     |     | L     | betteranimalsplus        | 9.0.1              | betteranimalsplus-1.12.2-9.0.1.jar            | None                                     |     | L     | orelib                   | 3.6.0.1            | OreLib-1.12.2-3.6.0.1.jar                     | None                                     |     Loaded coremods (and transformers):  DCLoadingPlugin (DummyCoreUnofficial-2.4.112.3.jar)   DummyCore.ASM.DCASMManager HCASM (HammerLib-1.12.2-2.0.6.23.jar)   com.zeitheron.hammercore.asm.HammerCoreTransformer     Profiler Position: N/A (disabled)     Is Modded: Definitely; Server brand changed to 'fml,forge'     Type: Dedicated Server (map_server.txt)
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.