Jump to content

White Mob


RapidEv

Recommended Posts

I have a problem with my mob (This is my first test with mobs).

He's render as a white box and i don't know why. And he don't move...

I have search on the web to find a solution but i found nothing.

Sorry if you think my english is bad. I'm french.

 

1387631424-2013-12-21-14-08-53.png

 

I use :

Forge : 9.11.1.938

Minecraft : 1.6.4

 

Can you help me ?

 

MobTest.java :

@Mod(modid = "UltimateMod", name = "UltimateMod", version = "1.0 Alpha")

@NetworkMod(clientSideRequired = true, serverSideRequired = false)
public class UltimateMod {

@SidedProxy(clientSide = "RapidEv.MobTest.common.ClientProxy", serverSide = "RapidEv.MobTest.common.CommonProxy")
public static CommonProxy proxy;

public static int startEntityId = 500;
public static int getUniqueEntityId() {
do {
	startEntityId++;
}
while(EntityList.getStringFromID(startEntityId) != null);
return startEntityId++;
}
public static void registerEntityEgg(Class<? extends Entity> entity, int primaryColor, int secondaryColor) {
int id = getUniqueEntityId();
EntityList.IDtoClassMapping.put(id, entity);
EntityList.entityEggs.put(id, new EntityEggInfo(id, primaryColor, secondaryColor));
}
@Init
public void load(FMLInitializationEvent event) {
	EntityRegistry.registerGlobalEntityID(EntityMobTest.class, "PereNoel", EntityRegistry.findGlobalUniqueEntityId());
	EntityRegistry.addSpawn(EntityMobTest.class, 10, 2, 4, EnumCreatureType.creature, BiomeGenBase.icePlains);
	registerEntityEgg(EntityMobTest.class, 0xFFFFFF, 0x0033FF);

}

 

EntityMobTest.java :

public class EntityMobTest extends EntityMob {
public EntityMobTest(World par1World) {
	super(par1World);
}
protected void applyEntityAttributes()
    {
        super.applyEntityAttributes();
        this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setAttribute(10.0D);
        this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setAttribute(0.5D);
    }
    protected void dropFewItems(boolean par1, int par2)
    {
        int j = this.rand.nextInt(2 + par2);
        int k;

        for (k = 0; k < j; ++k)
        {
            this.dropItem(Item.ingotGold.itemID, 1);
        }

        j = this.rand.nextInt(2 + par2);

        for (k = 0; k < j; ++k)
        {
            this.dropItem(Item.ingotIron.itemID, 1);
        }
    }
    protected void dropRareDrop(int par1)
    {
        this.dropItem(Item.diamond.itemID, 4);
    }
    public boolean isAIEnabled()
    {
        return true;
    }
public boolean getCanSpawnHere() {
	return true;
}
protected String getLivingSound() {
	return "mob.wither.idle";
}
protected String getDeathSound() {
	return "mob.wither.death";
}
protected String getHurtSound() {
	return "mob.wither.hurt";
}
}

 

RenderMobTest.java :

public class RenderMobTest extends RenderLiving {

public static ResourceLocation texture = new ResourceLocation("MobTest","textures/mobs/MobTest.png");
private ModelMobTest model;

public RenderMobTest(ModelBase par1ModelBase, float par2) {
	super(par1ModelBase, par2);
	model = (ModelMobTest)mainModel;
}

public void func_110827_b(EntityMobTest entity, double par2, double par4, double par6, float par8, float par9) {
	super.doRenderLiving(entity, par2, par4, par6, par8, par9);
}
public void doRenderLiving(EntityLiving entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}
public void doRender(Entity entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}
protected ResourceLocation getMobTestTextures(EntityMobTest PereNoel) {
        return texture;

    }
public ResourceLocation getEntityTexture(Entity entity) {
	return this.getMobTestTextures((EntityMobTest)entity);
}

}

 

ModelMobTest.java :

public class ModelMobTest extends ModelBase
{
  //fields
    ModelRenderer head;
    ModelRenderer body;
    ModelRenderer rightarm;
    ModelRenderer leftarm;
    ModelRenderer rightleg;
    ModelRenderer leftleg;
  
  public ModelMobTest()
  {
    textureWidth = 64;
    textureHeight = 32;
    
      head = new ModelRenderer(this, 0, 0);
      head.addBox(-4F, -8F, -4F, 8, 8, ;
      head.setRotationPoint(0F, 0F, 0F);
      head.setTextureSize(64, 32);
      head.mirror = true;
      setRotation(head, 0F, 0F, 0F);
      body = new ModelRenderer(this, 16, 16);
      body.addBox(-4F, 0F, -2F, 8, 12, 4);
      body.setRotationPoint(0F, 0F, 0F);
      body.setTextureSize(64, 32);
      body.mirror = true;
      setRotation(body, 0F, 0F, 0F);
      rightarm = new ModelRenderer(this, 40, 16);
      rightarm.addBox(-3F, -2F, -2F, 4, 12, 4);
      rightarm.setRotationPoint(-5F, 2F, 0F);
      rightarm.setTextureSize(64, 32);
      rightarm.mirror = true;
      setRotation(rightarm, 0F, 0F, 0F);
      leftarm = new ModelRenderer(this, 40, 16);
      leftarm.addBox(-1F, -2F, -2F, 4, 12, 4);
      leftarm.setRotationPoint(5F, 2F, 0F);
      leftarm.setTextureSize(64, 32);
      leftarm.mirror = true;
      setRotation(leftarm, 0F, 0F, 0F);
      rightleg = new ModelRenderer(this, 0, 16);
      rightleg.addBox(-2F, 0F, -2F, 4, 12, 4);
      rightleg.setRotationPoint(-2F, 12F, 0F);
      rightleg.setTextureSize(64, 32);
      rightleg.mirror = true;
      setRotation(rightleg, 0F, 0F, 0F);
      leftleg = new ModelRenderer(this, 0, 16);
      leftleg.addBox(-2F, 0F, -2F, 4, 12, 4);
      leftleg.setRotationPoint(2F, 12F, 0F);
      leftleg.setTextureSize(64, 32);
      leftleg.mirror = true;
      setRotation(leftleg, 0F, 0F, 0F);
  }
  
  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);
    head.render(f5);
    body.render(f5);
    rightarm.render(f5);
    leftarm.render(f5);
    rightleg.render(f5);
    leftleg.render(f5);
  }
  
  private void setRotation(ModelRenderer model, float x, float y, float z)
  {
    model.rotateAngleX = x;
    model.rotateAngleY = y;
    model.rotateAngleZ = z;
  }
  
  public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5, Entity entity)
  {
  
  }

}

 

CommonProxy.java :

public class CommonProxy {

        public void registerRenderers() {

        }
}

 

ClientProxy.java :

public class ClientProxy extends CommonProxy {
        
        @Override
        public void registerRenderers() {
        	
        	RenderingRegistry.registerEntityRenderingHandler(EntityModTest.class, new RenderModTest(new ModelModTest(), 0.3F));
        }
}

 

Console Output :

déc. 21, 2013 2:07:21 PM net.minecraft.launchwrapper.LogWrapper log
Infos: Loading tweak class name cpw.mods.fml.common.launcher.FMLTweaker
déc. 21, 2013 2:07:21 PM net.minecraft.launchwrapper.LogWrapper log
Infos: Using primary tweak class name cpw.mods.fml.common.launcher.FMLTweaker
déc. 21, 2013 2:07:21 PM net.minecraft.launchwrapper.LogWrapper log
Infos: Calling tweak class cpw.mods.fml.common.launcher.FMLTweaker
2013-12-21 14:07:21 [infos] [ForgeModLoader] Forge Mod Loader version 6.4.35.938 for Minecraft 1.6.4 loading
2013-12-21 14:07:21 [infos] [ForgeModLoader] Java is Java HotSpot(TM) Client VM, version 1.7.0_45, running on Windows 7:x86:6.1, installed at C:\Program Files\Java\jre7
2013-12-21 14:07:21 [infos] [ForgeModLoader] Managed to load a deobfuscated Minecraft name- we are in a deobfuscated environment. Skipping runtime deobfuscation
2013-12-21 14:07:21 [infos] [ForgeModLoader] Loading tweak class name cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker
2013-12-21 14:07:21 [infos] [ForgeModLoader] Loading tweak class name cpw.mods.fml.common.launcher.FMLDeobfTweaker
2013-12-21 14:07:21 [infos] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker
2013-12-21 14:07:21 [infos] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker
2013-12-21 14:07:21 [infos] [ForgeModLoader] Calling tweak class cpw.mods.fml.relauncher.CoreModManager$FMLPluginWrapper
2013-12-21 14:07:21 [infos] [sTDOUT] Loaded 40 rules from AccessTransformer config file fml_at.cfg
2013-12-21 14:07:22 [Grave] [ForgeModLoader] The binary patch set is missing. Either you are in a development environment, or things are not going to work!
2013-12-21 14:07:23 [infos] [ForgeModLoader] Calling tweak class cpw.mods.fml.relauncher.CoreModManager$FMLPluginWrapper
2013-12-21 14:07:23 [infos] [sTDOUT] Loaded 109 rules from AccessTransformer config file forge_at.cfg
2013-12-21 14:07:23 [infos] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLDeobfTweaker
2013-12-21 14:07:23 [infos] [ForgeModLoader] Launching wrapped minecraft {net.minecraft.client.main.Main}
2013-12-21 14:07:25 [infos] [Minecraft-Client] Setting user: Player65
2013-12-21 14:07:28 [infos] [Minecraft-Client] LWJGL Version: 2.9.0
2013-12-21 14:07:30 [infos] [Minecraft-Client] Reloading ResourceManager: Default
2013-12-21 14:07:32 [infos] [MinecraftForge] Attempting early MinecraftForge initialization
2013-12-21 14:07:32 [infos] [sTDOUT] MinecraftForge v9.11.1.938 Initialized
2013-12-21 14:07:32 [infos] [ForgeModLoader] MinecraftForge v9.11.1.938 Initialized
2013-12-21 14:07:32 [infos] [sTDOUT] Replaced 112 ore recipies
2013-12-21 14:07:32 [infos] [MinecraftForge] Completed early MinecraftForge initialization
2013-12-21 14:07:32 [infos] [ForgeModLoader] Reading custom logging properties from C:\Users\(I don't want to give you my username)\MCP Forge 1.6.4 Mods\forgeMobTest\mcp\jars\config\logging.properties
2013-12-21 14:07:32 [Désactivé] [ForgeModLoader] Logging level for ForgeModLoader logging is set to ALL
2013-12-21 14:07:32 [infos] [ForgeModLoader] Searching C:\Users\(I don't want to give you my username)\MCP Forge 1.6.4 Mods\forgeMobTest\mcp\jars\mods for mods
2013-12-21 14:07:45 [infos] [ForgeModLoader] Forge Mod Loader has identified 4 mods to load
2013-12-21 14:07:45 [infos] [mcp] Activating mod mcp
2013-12-21 14:07:45 [infos] [FML] Activating mod FML
2013-12-21 14:07:45 [infos] [Forge] Activating mod Forge
2013-12-21 14:07:45 [infos] [ModTest] Activating mod MobTest
2013-12-21 14:07:45 [Avertissement] [Forge Mod Loader] Mod Forge Mod Loader is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:45 [Avertissement] [Minecraft Forge] Mod Minecraft Forge is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:45 [Avertissement] [MobTest] Mod MobTest is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:45 [infos] [Minecraft-Client] Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:MobTest
2013-12-21 14:07:45 [infos] [ForgeModLoader] Registering Forge Packet Handler
2013-12-21 14:07:45 [infos] [ForgeModLoader] Succeeded registering Forge Packet Handler
2013-12-21 14:07:46 [infos] [ForgeModLoader] Configured a dormant chunk cache size of 0
2013-12-21 14:07:48 [infos] [ForgeModLoader] Forge Mod Loader has successfully loaded 4 mods
2013-12-21 14:07:48 [Avertissement] [Forge Mod Loader] Mod Forge Mod Loader is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:48 [Avertissement] [Minecraft Forge] Mod Minecraft Forge is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:48 [Avertissement] [MobTest] Mod MobTest is missing a pack.mcmeta file, things may not work well
2013-12-21 14:07:48 [infos] [Minecraft-Client] Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:MobTest
2013-12-21 14:07:49 [infos] [sTDOUT] 
2013-12-21 14:07:49 [infos] [sTDOUT] Starting up SoundSystem...
2013-12-21 14:07:49 [infos] [sTDOUT] Initializing LWJGL OpenAL
2013-12-21 14:07:49 [infos] [sTDOUT]     (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)
2013-12-21 14:07:50 [infos] [sTDOUT] OpenAL initialized.
2013-12-21 14:07:50 [infos] [sTDOUT] 
2013-12-21 14:07:52 [Grave] [Minecraft-Client] Realms: Invalid session id
2013-12-21 14:08:17 [infos] [Minecraft-Server] Starting integrated minecraft server version 1.6.4
2013-12-21 14:08:17 [infos] [Minecraft-Server] Generating keypair
2013-12-21 14:08:18 [infos] [ForgeModLoader] Loading dimension 0 (Narmol) (net.minecraft.server.integrated.IntegratedServer@19a5a3)
2013-12-21 14:08:18 [infos] [ForgeModLoader] Loading dimension 1 (Narmol) (net.minecraft.server.integrated.IntegratedServer@19a5a3)
2013-12-21 14:08:18 [infos] [ForgeModLoader] Loading dimension -1 (Narmol) (net.minecraft.server.integrated.IntegratedServer@19a5a3)
2013-12-21 14:08:18 [infos] [Minecraft-Server] Preparing start region for level 0
2013-12-21 14:08:19 [infos] [Minecraft-Server] Preparing spawn area: 46%
2013-12-21 14:08:20 [infos] [sTDOUT] loading single player
2013-12-21 14:08:20 [infos] [Minecraft-Server] Player65[/127.0.0.1:0] logged in with entity id 385 at (-255.69999998807907, 64.55090441068766, 1.6999999880790708)
2013-12-21 14:08:20 [infos] [Minecraft-Server] Player65 joined the game
2013-12-21 14:08:21 [infos] [sTDOUT] Setting up custom skins
2013-12-21 14:08:34 [infos] [Minecraft-Server] Saving and pausing game...
2013-12-21 14:08:34 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Overworld
2013-12-21 14:08:34 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Nether
2013-12-21 14:08:34 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/The End
2013-12-21 14:08:54 [infos] [Minecraft-Client] [CHAT] Saved screenshot as 2013-12-21_14.08.53.png
2013-12-21 14:08:56 [infos] [Minecraft-Server] Saving and pausing game...
2013-12-21 14:08:56 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Overworld
2013-12-21 14:08:56 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Nether
2013-12-21 14:08:56 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/The End
2013-12-21 14:09:07 [infos] [Minecraft-Server] Saving and pausing game...
2013-12-21 14:09:07 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Overworld
2013-12-21 14:09:07 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Nether
2013-12-21 14:09:07 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/The End
2013-12-21 14:09:09 [infos] [Minecraft-Server] Saving and pausing game...
2013-12-21 14:09:09 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Overworld
2013-12-21 14:09:09 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Nether
2013-12-21 14:09:09 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/The End
2013-12-21 14:09:10 [infos] [Minecraft-Server] Stopping server
2013-12-21 14:09:10 [infos] [Minecraft-Server] Saving players
2013-12-21 14:09:10 [infos] [Minecraft-Server] Player65 left the game
2013-12-21 14:09:10 [infos] [Minecraft-Server] Saving worlds
2013-12-21 14:09:10 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Overworld
2013-12-21 14:09:10 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/Nether
2013-12-21 14:09:10 [infos] [Minecraft-Server] Saving chunks for level 'Narmol'/The End
2013-12-21 14:09:10 [infos] [ForgeModLoader] Unloading dimension 0
2013-12-21 14:09:10 [infos] [ForgeModLoader] Unloading dimension -1
2013-12-21 14:09:10 [infos] [ForgeModLoader] Unloading dimension 1
2013-12-21 14:09:11 [infos] [Minecraft-Client] Stopping!
2013-12-21 14:09:11 [infos] [sTDOUT] 
2013-12-21 14:09:11 [infos] [sTDOUT] SoundSystem shutting down...
2013-12-21 14:09:12 [infos] [sTDOUT]     Author: Paul Lamb, www.paulscode.com
2013-12-21 14:09:12 [infos] [sTDOUT] 

Link to comment
Share on other sites

public void func_110827_b(EntityMobTest entity, double par2, double par4, double par6, float par8, float par9) {
	super.doRenderLiving(entity, par2, par4, par6, par8, par9);
}
public void doRenderLiving(EntityLiving entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}
public void doRender(Entity entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}

Remove that.

Link to comment
Share on other sites

public void func_110827_b(EntityMobTest entity, double par2, double par4, double par6, float par8, float par9) {
	super.doRenderLiving(entity, par2, par4, par6, par8, par9);
}
public void doRenderLiving(EntityLiving entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}
public void doRender(Entity entity, double par2, double par4, double par6, float par8, float par9) {
	func_110827_b((EntityMobTest)entity, par2, par4, par6, par8, par9);
}

Remove that.

 

I removed but the problem still here.

Link to comment
Share on other sites

  • 1 month later...

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.



×
×
  • Create New...

Important Information

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