• 0

    posted a message on WizardAnimalsPlus

    Wizard´s Animals+ Mod


    Hi everybody. This is a mod i´ve been working on for 1 year, and its the third mod i make for minecraft.

    This that adds more than 70 new mobs, but only animals that exist on our world, its a realistic match to minecraft of real life species, the goal of the mod is provide a huge variation of fauna so the player´s world become more alive and richer.

    A lot of animals can be tamed, others will attack the player if provoked and others will attack at sight. Most of the mobs can be breed, so like cows, you can generate some food and raw materials.

    Since there are dozens and dozens of new models and a lot of texture variations of them, this mod will take a bit more time (not to much thou), maybe 1 month, to be Beta Release.


    [MOD MAIN PICTURE WILL COME HERE]


    List of the Mobs so far (Pictures will be upload slowly):


    Giraffe, West African

    Giraffa c. peralta


    Giraffe, Reticulated

    Giraffa c. reticulata


    Model Type: Giraffe

    Spawn Biome: Savanah Rock

    Spawn Rate: 10% (2-6)

    Hit Points: 40

    Attack Strenght: 4

    Speed: 0,25

    Common Drop: Leather

    Rare Drop: Beef

    Breeding: Yes (SugarCane)

    Tameable: No

    XP: 30

    Special: Only attacks if provoked.



    Kangaroo, Antilopine

    Macropus antilopinus

    Member of the Macropodidae family, the kangaroo diet is mainly foliage and grass, they can live up to 20 years. The Antilopine kangaroo habit in the Northern Australia fields, and its main height is 1,4m, The Red kangaroo lives mainly on the australians deserts, and its a bit taller than the antilopine, reaching 1,5m. The West Gray kangaroo is the smallest of the three, with 1,3m, and habits the australian southern parts. The conservation status is on Least Concern.



    Capuchin, White-Headed

    Cebus capucinus




    Tamarin, Golden Lion

    Leontopithecus rosalia



    Squirrel, Red

    Sciurius vulgaris



    Rhinocerus, White

    Ceratotherium simum



    Marmoset, Common

    Callithrix jacchus



    Red Panda

    Ailurus fulgens



    Gorilla, Western

    Gorilla gorilla


    My flickr:

    https://www.flickr.com/photos/121771033@N05/


    Complete Wiki Encyclopedia (updated 26/11):

    http://www.mediafire.com/file/96jyo0ofl0ot8ba/zzz_My Mod Mobs.pptx

    Posted in: WIP Mods
  • 0

    posted a message on Ocean Spawn on Mobs

    ok so i solve it, but by error/try, so i dont know how i fix it lol...


    here is the code, the part i want to understand is where i could set the Y axis high interval this mob will appear, for example, i want the starfish here to spawn on the ocean floor only, but it spawns near the surface and gentle falls to the ocean floor.. its not bad the way it is now, but i want to understand how it work . thanks!


    import net.minecraftforge.fml.common.registry.EntityRegistry;
    import net.minecraftforge.fml.common.event.FMLServerStartingEvent;
    import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
    import net.minecraftforge.fml.common.event.FMLInitializationEvent;
    import net.minecraftforge.fml.client.registry.RenderingRegistry;
    
    import net.minecraft.world.gen.structure.template.Template;
    import net.minecraft.world.biome.Biome;
    import net.minecraft.world.World;
    import net.minecraft.util.ResourceLocation;
    import net.minecraft.util.DamageSource;
    import net.minecraft.item.ItemStack;
    import net.minecraft.item.Item;
    import net.minecraft.init.Items;
    import net.minecraft.entity.passive.EntityAnimal;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.SharedMonsterAttributes;
    import net.minecraft.entity.EnumCreatureType;
    import net.minecraft.entity.EntityAgeable;
    import net.minecraft.entity.Entity;
    import net.minecraft.client.renderer.entity.RenderLiving;
    import net.minecraft.client.model.ModelRenderer;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.Minecraft;
    
    import net.minecraft.client.renderer.GlStateManager;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityMoveHelper;
    import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
    import net.minecraft.entity.ai.EntityAIHurtByTarget;
    
    import net.minecraft.entity.effect.EntityLightningBolt;
    import net.minecraft.entity.ai.EntityAIWander;
    import net.minecraft.entity.ai.EntityAITempt;
    import net.minecraft.entity.ai.EntityAISwimming;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.ai.EntityAILookIdle;
    
    import net.minecraftforge.fml.relauncher.SideOnly;
    import net.minecraftforge.fml.relauncher.Side;
    import net.minecraft.util.math.MathHelper;
    import net.minecraft.entity.ai.EntityAIEatGrass;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.player.EntityPlayer;
    import net.minecraft.entity.EntityLiving;
    import net.minecraft.entity.EntitySpawnPlacementRegistry;
    
    
    import java.util.Random;
    
    public class mcreator_starfishCommon {
    
    	public static Object instance;
    	public static int mobid = 95;
    	public static int mobid2 = 96;
    
    	public void preInit(FMLPreInitializationEvent event) {
    		EntityRegistry.registerModEntity(new ResourceLocation("testenvironmentmod:starfishcommon"), EntitystarfishCommon.class, "starfishcommon",
    				mobid, instance, 64, 1, true, -2851227, -1011647);
    		Biome[] spawnBiomes = {Biome.REGISTRY.getObject(new ResourceLocation("ocean")), Biome.REGISTRY.getObject(new ResourceLocation("deep_ocean")),};
    		EntityRegistry.addSpawn(EntitystarfishCommon.class, 25, 3, 6, EnumCreatureType.WATER_CREATURE, spawnBiomes);
    
    		EntitySpawnPlacementRegistry.setPlacementType(EntitystarfishCommon.class, EntityLiving.SpawnPlacementType.IN_WATER); // <---- is this on the right place?
    	}
    
    	public void load(FMLInitializationEvent event) {
    	}
    
    	public void serverLoad(FMLServerStartingEvent event) {
    	}
    
    	@SideOnly(Side.CLIENT)
    	public void registerRenderers() {
    		RenderLiving customRender = new RenderLiving<EntityAgeable>(Minecraft.getMinecraft().getRenderManager(), new ModelStarfish(), 0) {
    
    			protected ResourceLocation getEntityTexture(EntityAgeable par1Entity) {
    				return new ResourceLocation("Starfish_Common.png");
    			}
    
    			protected void preRenderCallback(EntityAgeable entitylivingbaseIn, float partialTickTime) {
              float f = 0.6F;
              if (entitylivingbaseIn.getGrowingAge() < 0) {
                   f = (float)((double)f * 0.5D);
                   this.shadowSize = 0.3F;
              } else {
                   this.shadowSize = 0.6F;
              }
              GlStateManager.scale(f, f, f);
         }
    
    			
    		};
    		RenderingRegistry.registerEntityRenderingHandler(EntitystarfishCommon.class, customRender);
    	}
    
    	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;
    	}
    
    	public static class EntitystarfishCommon extends EntityAnimal {
    
    		public EntitystarfishCommon(World world) {
    			super(world);
    			addRandomArmor();
    			experienceValue = 2;
    			this.isImmuneToFire = false;
    			setNoAI(!true);
    			this.tasks.addTask(4, new EntityAIWander(this, 1.0D));
    			this.tasks.addTask(3, new EntityAILookIdle(this));
    			this.tasks.addTask(2, new EntityAITempt(this, 1.1D, Items.REEDS, false));
    			this.tasks.addTask(1, new EntityAIMate(this, 1.0D));
    			this.setSize(1F, 1F);
    		}
    
    		@Override
    		protected Item getDropItem() {
    			return null;
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getAmbientSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getHurtSound(DamageSource ds) {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getDeathSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		protected float getSoundVolume() {
    			return 1.0F;
    		}
    
    		@Override
    		protected void applyEntityAttributes() {
    			super.applyEntityAttributes();
    			this.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.05D);
    			this.getEntityAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(2D);
    			if (this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE) != null)
    				this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE).setBaseValue(0D);
    		}
    
    		protected void addRandomArmor() {
    		}
    
    
    		// aquatic code
    		public boolean canBreatheUnderwater()
              {
                   return true;
              }
              
              public boolean isPushedByWater()
              {
                   return false;
              }
    
    
              public boolean isNotColliding()
        	  {
            	return this.world.checkNoEntityCollision(this.getEntityBoundingBox(), this);
        	  }
    
        	   public boolean CheckInWater() 
        	   {
            		return this.isInWater();   <--- i guess that what was missing and now it works for it
               }
    
        	  
        	   public boolean getCanSpawnHere()
        		{
        			return true;
            		//return this.posY > 45.0D && this.posY < (double)this.world.getSeaLevel() && super.getCanSpawnHere();   <--- im not using this.. should i?
        		}
    
              //aquatic code end
    
    
    
    		@Override
    		public EntitystarfishCommon createChild(EntityAgeable ageable) {
    			return new EntitystarfishCommon(world);
    		}
    
    		@Override
    		public float getEyeHeight() {
    			return this.isChild() ? this.height : 1.3F;
    		}
    
    		@Override
    		public boolean isBreedingItem(ItemStack stack) {
    			if (stack == null)
    				return false;
    			if (new ItemStack(Items.REEDS, (int) (1)).getItem() == stack.getItem())
    				return true;
    			return false;
    		}
    	}
    Posted in: Modification Development
  • 0

    posted a message on Adding a custom sound to minecraft not working

    use MCreator to add sounds, its so easy to do there

    Posted in: Modification Development
  • 0

    posted a message on Ocean Spawn on Mobs

    i just add this



    EntitySpawnPlacementRegistry.setPlacementType(EntitystarfishCommon.class, EntityLiving.SpawnPlacementType.IN_WATER);



    to my EntityRegister, still they are not spawning

    Posted in: Modification Development
  • 0

    posted a message on Ocean Spawn on Mobs

    i forgot to mention; the mod actually DO spawn on 'ocean' biome, BUT it only spawn if you cover a layer of solid block like grass, over the ocean surface, then the mob spawn on the surface, not on the liquid... i know i miss a liquid/spawn entrance here, just dont know witch, also i might have to change this part maybe?



    public void generateNether(World world, Random random, int chunkX, int chunkZ) {
    }

    public void generateSurface(World world, Random random, int chunkX, int chunkZ) {
    }

    Posted in: Modification Development
  • 0

    posted a message on Underwater Mob AI

    Jaffa could you tell me how to make the Mob spawn in the ocean in the first place? i miss that on my mod :) thanks

    Posted in: Modification Development
  • 0

    posted a message on Making Male / Female Mobs

    Mo creature mods did it.. i was trying to look the .class of that mod on a class viewer to try to learn, but all i see are those 'func_xxxx' things hehe, i wish Java did not compile/recompile codes all the time :)


    i need the part of the code that Define that mob A can breed only with mob B (not itself), so A with A is not allowed, for that i would make a second model/entity/class (a second mob), so i would have 2 mobs, would this make the code easie

    Posted in: Modification Development
  • 0

    posted a message on Ocean Spawn on Mobs

    hey guys,


    i notice setting the biome to 'ocean' is not all we need to do to spawn aquatic mobs, what else i need to do?



    Notice 'aquatic code' part i tried to add some things there...


    thanks!


    import net.minecraftforge.fml.common.registry.EntityRegistry;
    import net.minecraftforge.fml.common.event.FMLServerStartingEvent;
    import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
    import net.minecraftforge.fml.common.event.FMLInitializationEvent;
    import net.minecraftforge.fml.client.registry.RenderingRegistry;
    
    import net.minecraft.world.gen.structure.template.Template;
    import net.minecraft.world.biome.Biome;
    import net.minecraft.world.World;
    import net.minecraft.util.ResourceLocation;
    import net.minecraft.util.DamageSource;
    import net.minecraft.item.ItemStack;
    import net.minecraft.item.Item;
    import net.minecraft.init.Items;
    import net.minecraft.entity.passive.EntityAnimal;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.SharedMonsterAttributes;
    import net.minecraft.entity.EnumCreatureType;
    import net.minecraft.entity.EntityAgeable;
    import net.minecraft.entity.Entity;
    import net.minecraft.client.renderer.entity.RenderLiving;
    import net.minecraft.client.model.ModelRenderer;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.Minecraft;
    
    import net.minecraft.client.renderer.GlStateManager;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityMoveHelper;
    import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
    import net.minecraft.entity.ai.EntityAIHurtByTarget;
    
    import net.minecraft.entity.effect.EntityLightningBolt;
    import net.minecraft.entity.ai.EntityAIWander;
    import net.minecraft.entity.ai.EntityAITempt;
    import net.minecraft.entity.ai.EntityAISwimming;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.ai.EntityAILookIdle;
    
    import net.minecraftforge.fml.relauncher.SideOnly;
    import net.minecraftforge.fml.relauncher.Side;
    import net.minecraft.util.math.MathHelper;
    import net.minecraft.entity.ai.EntityAIEatGrass;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.player.EntityPlayer;
    import net.minecraft.entity.ai.EntityAIPanic;
    
    import java.util.Random;
    
    public class mcreator_starfishCommon {
    
    	public static Object instance;
    	public static int mobid = 95;
    	public static int mobid2 = 96;
    
    	public void preInit(FMLPreInitializationEvent event) {
    		EntityRegistry.registerModEntity(new ResourceLocation("testenvironmentmod:starfishcommon"), EntitystarfishCommon.class, "starfishcommon",
    				mobid, instance, 64, 1, true, -2851227, -1011647);
    		Biome[] spawnBiomes = {Biome.REGISTRY.getObject(new ResourceLocation("ocean")), Biome.REGISTRY.getObject(new ResourceLocation("deep_ocean")),};
    		EntityRegistry.addSpawn(EntitystarfishCommon.class, 99, 3, 6, EnumCreatureType.WATER_CREATURE, spawnBiomes);
    	}
    
    	public void load(FMLInitializationEvent event) {
    	}
    
    	public void serverLoad(FMLServerStartingEvent event) {
    	}
    
    	@SideOnly(Side.CLIENT)
    	public void registerRenderers() {
    		RenderLiving customRender = new RenderLiving<EntityAgeable>(Minecraft.getMinecraft().getRenderManager(), new ModelStarfish(), 0) {
    
    			protected ResourceLocation getEntityTexture(EntityAgeable par1Entity) {
    				return new ResourceLocation("Starfish_Common.png");
    			}
    
    			protected void preRenderCallback(EntityAgeable entitylivingbaseIn, float partialTickTime) {
              float f = 0.6F;
              if (entitylivingbaseIn.getGrowingAge() < 0) {
                   f = (float)((double)f * 0.5D);
                   this.shadowSize = 0.3F;
              } else {
                   this.shadowSize = 0.6F;
              }
              GlStateManager.scale(f, f, f);
         }
    
    			
    		};
    		RenderingRegistry.registerEntityRenderingHandler(EntitystarfishCommon.class, customRender);
    	}
    
    	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;
    	}
    
    	public static class EntitystarfishCommon extends EntityAnimal {
    
    		public EntitystarfishCommon(World world) {
    			super(world);
    			addRandomArmor();
    			experienceValue = 2;
    			this.isImmuneToFire = false;
    			setNoAI(!true);
    			this.tasks.addTask(4, new EntityAIWander(this, 1.0D));
    			this.tasks.addTask(3, new EntityAILookIdle(this));
    			this.tasks.addTask(2, new EntityAITempt(this, 1.1D, Items.REEDS, false));
    			this.tasks.addTask(1, new EntityAIMate(this, 1.0D));
    			this.setSize(1F, 1F);
    		}
    
    		@Override
    		protected Item getDropItem() {
    			return null;
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getAmbientSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getHurtSound(DamageSource ds) {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getDeathSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(""));
    		}
    
    		@Override
    		protected float getSoundVolume() {
    			return 1.0F;
    		}
    
    		@Override
    		protected void applyEntityAttributes() {
    			super.applyEntityAttributes();
    			this.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.05D);
    			this.getEntityAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(2D);
    			if (this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE) != null)
    				this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE).setBaseValue(0D);
    		}
    
    		protected void addRandomArmor() {
    		}
    
    		public boolean canBreatheUnderwater()
              {
                   return true;
              }
              
              public boolean isPushedByWater()
              {
                   return false;
              }
    
    
              public boolean isNotColliding()
        	  {
            	return this.world.checkNoEntityCollision(this.getEntityBoundingBox(), this);
        	  }
    
        	  
        	   public boolean getCanSpawnHere()
        		{
            		return this.posY > 45.0D && this.posY < (double)this.world.getSeaLevel() && super.getCanSpawnHere();
        		}
    
              
    
    
    
    		@Override
    		public EntitystarfishCommon createChild(EntityAgeable ageable) {
    			return new EntitystarfishCommon(world);
    		}
    
    		@Override
    		public float getEyeHeight() {
    			return this.isChild() ? this.height : 1.3F;
    		}
    
    		@Override
    		public boolean isBreedingItem(ItemStack stack) {
    			if (stack == null)
    				return false;
    			if (new ItemStack(Items.REEDS, (int) (1)).getItem() == stack.getItem())
    				return true;
    			return false;
    		}
    	}
    Posted in: Modification Development
  • 0

    posted a message on Making Male / Female Mobs

    1.12


    Hey guys, so i was wondering how i make 1 of my mobs Mate only with 1 another with my mobs, so i can make:


    1) male/female animals to breed.


    2) the child have 50% of chance to be male/female


    any help?


    i found this but dont know how to set it up true and make the child changes


    public boolean canMateWith(EntityAnimal otherAnimal)
    {
    return false;
    }

    Posted in: Modification Development
  • 0

    posted a message on Mob is Tamed but the Model wont sit?

    well i will be a son of a gun... it works.


    thank you all for the help! i will be sure of mention you when i release this mod

    Posted in: Modification Development
  • 0

    posted a message on Mob is Tamed but the Model wont sit?
    package mod.mcreator;
    
    import net.minecraftforge.fml.common.registry.EntityRegistry;
    import net.minecraftforge.fml.common.event.FMLServerStartingEvent;
    import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
    import net.minecraftforge.fml.common.event.FMLInitializationEvent;
    import net.minecraftforge.fml.client.registry.RenderingRegistry;
    
    import net.minecraft.world.gen.structure.template.Template;
    import net.minecraft.world.biome.Biome;
    import net.minecraft.world.World;
    import net.minecraft.util.ResourceLocation;
    import net.minecraft.util.DamageSource;
    import net.minecraft.item.ItemStack;
    import net.minecraft.item.Item;
    import net.minecraft.init.Items;
    import net.minecraft.entity.passive.EntityAnimal;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.SharedMonsterAttributes;
    import net.minecraft.entity.EnumCreatureType;
    import net.minecraft.entity.EntityAgeable;
    import net.minecraft.entity.Entity;
    import net.minecraft.client.renderer.entity.RenderLiving;
    import net.minecraft.client.model.ModelRenderer;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.Minecraft;
    
    import net.minecraft.client.renderer.GlStateManager;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityMoveHelper;
    import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
    import net.minecraft.entity.ai.EntityAIHurtByTarget;
    
    import net.minecraft.entity.effect.EntityLightningBolt;
    import net.minecraft.entity.ai.EntityAIWander;
    import net.minecraft.entity.ai.EntityAITempt;
    import net.minecraft.entity.ai.EntityAISwimming;
    import net.minecraft.entity.ai.EntityAIMate;
    import net.minecraft.entity.ai.EntityAILookIdle;
    
    import net.minecraftforge.fml.relauncher.SideOnly;
    import net.minecraftforge.fml.relauncher.Side;
    import net.minecraft.util.math.MathHelper;
    import net.minecraft.entity.ai.EntityAIEatGrass;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.ai.EntityAIFollowParent;
    import net.minecraft.entity.player.EntityPlayer;
    import net.minecraft.entity.ai.EntityAIPanic;
    
    import net.minecraft.entity.passive.EntityTameable;
    import net.minecraft.entity.ai.EntityAIOwnerHurtByTarget;
    import net.minecraft.entity.ai.EntityAIOwnerHurtTarget;
    import net.minecraft.entity.ai.EntityAISit;
    import net.minecraft.entity.ai.EntityAIFollowOwner;
    import net.minecraft.util.EnumHand;
    import net.minecraft.util.EnumParticleTypes;
    import net.minecraft.entity.EntityLivingBase;
    import net.minecraft.entity.EntityLiving;
    import net.minecraft.entity.ai.EntityAIWanderAvoidWater;
    
    import java.util.Random;
    
    public class mcreator_capuchinBrown {
    
    	public static Object instance;
    	public static int mobid = 57;
    	public static int mobid2 = 58;
    
    	public void preInit(FMLPreInitializationEvent event) {
    		EntityRegistry.registerModEntity(new ResourceLocation("testenvironmentmod:capuchinbrown"), EntitycapuchinBrown.class, "capuchinbrown", mobid,
    				instance, 64, 1, true, -9813724, -14145496);
    		Biome[] spawnBiomes = {Biome.REGISTRY.getObject(new ResourceLocation("jungle")),};
    		EntityRegistry.addSpawn(EntitycapuchinBrown.class, 18, 2, 8, EnumCreatureType.CREATURE, spawnBiomes);
    	}
    
    	public void load(FMLInitializationEvent event) {
    	}
    
    	public void serverLoad(FMLServerStartingEvent event) {
    	}
    
    	@SideOnly(Side.CLIENT)
    	public void registerRenderers() {
    		RenderLiving customRender = new RenderLiving<EntityAgeable>(Minecraft.getMinecraft().getRenderManager(), new ModelCapuchin(), 0) {
    
    			protected ResourceLocation getEntityTexture(EntityAgeable par1Entity) {
    				return new ResourceLocation("Capuchin_Brown.png");
    			}
    
    			protected void preRenderCallback(EntityAgeable entitylivingbaseIn, float partialTickTime) {
              float f = 0.8F;
              if (entitylivingbaseIn.getGrowingAge() < 0) {
                   f = (float)((double)f * 0.5D);
                   this.shadowSize = 0.4F;
              } else {
                   this.shadowSize = 0.8F;
              }
              GlStateManager.scale(f, f, f);
         } 
    			
    		};
    		RenderingRegistry.registerEntityRenderingHandler(EntitycapuchinBrown.class, customRender);
    	}
    
    	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;
    	}
    
    	public static class EntitycapuchinBrown extends EntityTameable {
    
    	public EntitycapuchinBrown(World world) {
    		super(world);
    		addRandomArmor();
    		experienceValue = 4;
    		this.isImmuneToFire = false;
    		setNoAI(!true);
                    this.setSize(1F, 1F);
                    this.setTamed(false);
    	}
    	
    	protected void initEntityAI() 
    	{
    	    this.tasks.addTask(1, new EntityAISwimming(this));
    	    this.aiSit = new EntityAISit(this);
    	    this.tasks.addTask(2, this.aiSit);
            this.tasks.addTask(2, new EntityAIFollowOwner(this, 1.0D, 10.0F, 2.0F));
    	    this.tasks.addTask(3, new EntityAITempt(this, 1.1D, Items.REEDS, false));
    	    this.tasks.addTask(3, new EntityAIMate(this, 1.0D));
    	    this.tasks.addTask(4, new EntityAIFollowParent(this, 0.9D));
    	    this.tasks.addTask(5, new EntityAIPanic(this, 1.2D));
    	    this.tasks.addTask(6, new EntityAIWanderAvoidWater(this, 1.0D));
    	    this.tasks.addTask(7, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
    	    this.tasks.addTask(7, new EntityAILookIdle(this));
    	}
    
    
    	//TAME CODE
        public void setTamed(boolean tamed)
        {
        	super.setTamed(tamed);
           //whatever you want your mob to do when it's tamed e.g. the wolf's class uses this to increase the mob's max health to 20 if it's tamed
    
        }
    
    	public boolean processInteract(EntityPlayer player, EnumHand hand)
    	{
    	  ItemStack itemstack = player.getHeldItem(hand);
    	  if (!this.isTamed() && itemstack.getItem() == Items.APPLE && !this.isBreedingItem(itemstack))
    	    {
    	      if (!player.capabilities.isCreativeMode)
    	        {
    	            itemstack.shrink(1);
    	        }
    	     if (!this.world.isRemote)
    	        {
    	            if (this.rand.nextInt(3) == 0 && !net.minecraftforge.event.ForgeEventFactory.onAnimalTame(this, player))
    	            {
    	                this.setTamedBy(player);
    	                this.navigator.clearPath();
    	                this.setAttackTarget((EntityLivingBase)null);
    	                this.aiSit.setSitting(true);
    	                this.setHealth(8.0F);
    	                this.playTameEffect(true);
    	                this.world.setEntityState(this, (byte)7);
    	            }
    	            else
    	            {
    	                this.playTameEffect(false);
    	                this.world.setEntityState(this, (byte)6);
    	            }
    	        }
    	        return true;
    	    }
    	
    	    else if (this.isOwner(player) && !this.world.isRemote && !this.isBreedingItem(itemstack))
    	    {
    	         this.aiSit.setSitting(!this.isSitting()); 
    	         this.isJumping = false;
    	         this.navigator.clearPath();
    	         this.setAttackTarget((EntityLivingBase)null); 
    	         return true;
    	    }
    	
    	    return super.processInteract(player, hand);
    	}
    
    		//TAME CODE END
    
    		@Override
    		protected Item getDropItem() {
    			return new ItemStack(Items.BEEF, (int) (1)).getItem();
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getAmbientSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(
    					"testenvironmentmod:wizard.capuchin.ambient"));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getHurtSound(DamageSource ds) {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(
    					"testenvironmentmod:wizard.capuchin.hurt"));
    		}
    
    		@Override
    		public net.minecraft.util.SoundEvent getDeathSound() {
    			return (net.minecraft.util.SoundEvent) net.minecraft.util.SoundEvent.REGISTRY.getObject(new ResourceLocation(
    					"testenvironmentmod:wizard.capuchin.death"));
    		}
    
    		@Override
    		protected float getSoundVolume() {
    			return 1.0F;
    		}
    
    		@Override
    		protected void applyEntityAttributes() {
    			super.applyEntityAttributes();
    			this.getEntityAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.35D);
    			this.getEntityAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(8D);
    			if (this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE) != null)
    				this.getEntityAttribute(SharedMonsterAttributes.ATTACK_DAMAGE).setBaseValue(0D);
    		}
    
    		protected void addRandomArmor() {
    		}
    
    		@Override
    		public EntitycapuchinBrown createChild(EntityAgeable ageable) {
    			return new EntitycapuchinBrown(world);
    		}
    
    		@Override
    		public float getEyeHeight() {
    			return this.isChild() ? this.height : 1.3F;
    		}
    
    		@Override
    		public boolean isBreedingItem(ItemStack stack) {
    			if (stack == null)
    				return false;
    			if (new ItemStack(Items.REEDS, (int) (1)).getItem() == stack.getItem())
    				return true;
    			return false;
    		}
    
    		protected void dropRareDrop(int par1) {
    			this.dropItem(new ItemStack(Items.LEATHER, (int) (1)).getItem(), 1);
    		}
    	}
    
    	// Date: 08/12/2017 01:22:10
    	// Template version 1.1
    	// Java generated by Techne
    	// Keep in mind that you still need to fill in some blanks
    	// - ZeuX
    	public static class ModelCapuchin extends ModelBase {
    
    		// fields
    		ModelRenderer Head;
    		ModelRenderer Body;
    		ModelRenderer ArmL;
    		ModelRenderer ArmR;
    		ModelRenderer TailBase;
    		ModelRenderer TailTip;
    		ModelRenderer UpLeg2;
    		ModelRenderer DownLeg2;
    		ModelRenderer Foot2;
    		ModelRenderer UpLeg1;
    		ModelRenderer DownLeg1;
    		ModelRenderer Foot1;
    		ModelRenderer Face;
    		ModelRenderer EarL;
    		ModelRenderer EarR;
    		ModelRenderer Nose;
    
    		public ModelCapuchin() {
    			textureWidth = 64;
    			textureHeight = 64;
    			Head = new ModelRenderer(this, 42, 2);
    			Head.addBox(-2.5F, -5F, -3.5F, 5, 5, 5);
    			Head.setRotationPoint(0.5F, 15F, -1F);
    			Head.setTextureSize(64, 64);
    			Head.mirror = true;
    			setRotation(Head, 0F, 0F, 0F);
    			Body = new ModelRenderer(this, 23, 2);
    			Body.addBox(-1.5F, -2F, -1F, 4, 8, 4);
    			Body.setRotationPoint(0F, 16.5F, -0.5F);
    			Body.setTextureSize(64, 64);
    			Body.mirror = true;
    			setRotation(Body, 1.047198F, 0F, 0F);
    			ArmL = new ModelRenderer(this, 34, 16);
    			ArmL.addBox(0F, 0F, -0.5F, 1, 9, 1);
    			ArmL.setRotationPoint(2F, 15.5F, -1F);
    			ArmL.setTextureSize(64, 64);
    			ArmL.mirror = true;
    			setRotation(ArmL, -0.3490659F, 0F, 0F);
    			ArmR = new ModelRenderer(this, 40, 16);
    			ArmR.addBox(-1F, 0F, -0.5F, 1, 9, 1);
    			ArmR.setRotationPoint(-1F, 15.5F, -1F);
    			ArmR.setTextureSize(64, 64);
    			ArmR.mirror = true;
    			setRotation(ArmR, -0.3490659F, 0F, 0F);
    			TailBase = new ModelRenderer(this, 16, 4);
    			TailBase.addBox(-0.5F, -5F, -0.5F, 1, 5, 1);
    			TailBase.setRotationPoint(0.5F, 17F, 5F);
    			TailBase.setTextureSize(64, 64);
    			TailBase.mirror = true;
    			setRotation(TailBase, -0.7853982F, 0F, 0F);
    			TailTip = new ModelRenderer(this, 11, 4);
    			TailTip.addBox(-0.5F, -7.5F, 3.5F, 1, 5, 1);
    			TailTip.setRotationPoint(0.5F, 17F, 5F);
    			TailTip.setTextureSize(64, 64);
    			TailTip.mirror = true;
    			setRotation(TailTip, 0.1745329F, 0F, 0F);
    			UpLeg2 = new ModelRenderer(this, 14, 23);
    			UpLeg2.addBox(-1F, -1F, -1F, 2, 5, 2);
    			UpLeg2.setRotationPoint(2F, 19F, 4.5F);
    			UpLeg2.setTextureSize(64, 64);
    			UpLeg2.mirror = true;
    			setRotation(UpLeg2, -0.7853982F, 0F, 0F);
    			DownLeg2 = new ModelRenderer(this, 14, 31);
    			DownLeg2.addBox(-1F, -1F, -4F, 2, 4, 1);
    			DownLeg2.setRotationPoint(2F, 19F, 4.5F);
    			DownLeg2.setTextureSize(64, 64);
    			DownLeg2.mirror = true;
    			setRotation(DownLeg2, 0.7853982F, 0F, 0F);
    			Foot2 = new ModelRenderer(this, 15, 37);
    			Foot2.addBox(-1F, 4F, -3F, 2, 1, 3);
    			Foot2.setRotationPoint(2F, 19F, 4.5F);
    			Foot2.setTextureSize(64, 64);
    			Foot2.mirror = true;
    			setRotation(Foot2, 0F, 0F, 0F);
    			UpLeg1 = new ModelRenderer(this, 2, 23);
    			UpLeg1.addBox(-1F, -1F, -1F, 2, 5, 2);
    			UpLeg1.setRotationPoint(-1F, 19F, 4.5F);
    			UpLeg1.setTextureSize(64, 64);
    			UpLeg1.mirror = true;
    			setRotation(UpLeg1, -0.7853982F, 0F, 0F);
    			DownLeg1 = new ModelRenderer(this, 4, 31);
    			DownLeg1.addBox(-1F, -1F, -4F, 2, 4, 1);
    			DownLeg1.setRotationPoint(-1F, 19F, 4.5F);
    			DownLeg1.setTextureSize(64, 64);
    			DownLeg1.mirror = true;
    			setRotation(DownLeg1, 0.7853982F, 0F, 0F);
    			Foot1 = new ModelRenderer(this, 3, 37);
    			Foot1.addBox(-1F, 4F, -3F, 2, 1, 3);
    			Foot1.setRotationPoint(-1F, 19F, 4.5F);
    			Foot1.setTextureSize(64, 64);
    			Foot1.mirror = true;
    			setRotation(Foot1, 0F, 0F, 0F);
    			Face = new ModelRenderer(this, 50, 17);
    			Face.addBox(-2F, -4.5F, -3.8F, 4, 4, 1);
    			Face.setRotationPoint(0.5F, 15F, -1F);
    			Face.setTextureSize(64, 64);
    			Face.mirror = true;
    			setRotation(Face, 0F, 0F, 0F);
    			EarL = new ModelRenderer(this, 2, 8);
    			EarL.addBox(0F, -4F, -3F, 2, 2, 2);
    			EarL.setRotationPoint(0.5F, 15F, -1F);
    			EarL.setTextureSize(64, 64);
    			EarL.mirror = true;
    			setRotation(EarL, 0F, -0.7853982F, 0F);
    			EarR = new ModelRenderer(this, 2, 2);
    			EarR.addBox(-2F, -4F, -3F, 2, 2, 2);
    			EarR.setRotationPoint(0.5F, 15F, -1F);
    			EarR.setTextureSize(64, 64);
    			EarR.mirror = true;
    			setRotation(EarR, 0F, 0.7853982F, 0F);
    			Nose = new ModelRenderer(this, 50, 24);
    			Nose.addBox(-1F, -2.8F, -4.5F, 2, 2, 2);
    			Nose.setRotationPoint(0.5F, 15F, -1F);
    			Nose.setTextureSize(64, 64);
    			Nose.mirror = true;
    			setRotation(Nose, 0.0872665F, 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);
    			setRotationAngles(f, f1, f2, f3, f4, f5, entity);
    			Head.render(f5);
    			Body.render(f5);
    			ArmL.render(f5);
    			ArmR.render(f5);
    			TailBase.render(f5);
    			TailTip.render(f5);
    			UpLeg2.render(f5);
    			DownLeg2.render(f5);
    			Foot2.render(f5);
    			UpLeg1.render(f5);
    			DownLeg1.render(f5);
    			Foot1.render(f5);
    			Face.render(f5);
    			EarL.render(f5);
    			EarR.render(f5);
    			Nose.render(f5);
    		}
    
    		private void setRotation(ModelRenderer model, float x, float y, float z) {
    			model.rotateAngleX = x;
    			model.rotateAngleY = y;
    			model.rotateAngleZ = z;
    		}
    
    
    
    
    		// SITTING ANIMATION CODE
    
    		public void setLivingAnimations(EntityLivingBase entitylivingbaseIn)
         {
            EntitycapuchinBrown entitycapuchinBrown = (EntitycapuchinBrown)entitylivingbaseIn;
    
            
            if (entitycapuchinBrown.isSitting())
            {
                this.Head.setRotationPoint(0.5F, 17F, -1F);
    			this.Body.setRotationPoint(0F, 18.5F, -0.5F);
    			this.Body.rotateAngleX = 0.5235988F;
    			this.ArmL.setRotationPoint(2F, 17.5F, -1F);
    			this.ArmL.rotateAngleX = -0.6108652F;
    			this.ArmR.setRotationPoint(-1F, 17.5F, -1F);
    			this.ArmR.rotateAngleX = -0.6108652F;
    			this.TailBase.setRotationPoint(0.5F, 21F, 4F);
    			this.TailTip.setRotationPoint(0.5F, 21F, 4F);
    			this.Face.setRotationPoint(0.5F, 17F, -1F);
    			this.EarL.setRotationPoint(0.5F, 17F, -1F);
    			this.EarR.setRotationPoint(0.5F, 17F, -1F);
    			this.Nose.setRotationPoint(0.5F, 17F, -1F);
    
    			this.UpLeg1.setRotationPoint(-1F, 21F, 2.5F);
    			this.UpLeg1.rotateAngleX = -1.396263F;
    			this.DownLeg1.setRotationPoint(-1F, 21F, 2.5F);
    			this.DownLeg1.rotateAngleX = 1.570796F;
    			this.Foot1.setRotationPoint(-1F, 21F, 2.5F);
    			this.Foot1.rotateAngleX = 1.919862F;
    			this.UpLeg2.setRotationPoint(2F, 21F, 2.5F);
    			this.UpLeg2.rotateAngleX = -1.396263F;
    			this.DownLeg2.setRotationPoint(2F, 21F, 2.5F);
    			this.DownLeg2.rotateAngleX = -1.570796F;
    			this.Foot2.setRotationPoint(2F, 21F, 2.5F);
    			this.Foot2.rotateAngleX = 1.919862F;
    
              
            }
            else
            {
    
    
    			this.Head.setRotationPoint(0.5F, 15F, -1F);
    			this.Body.setRotationPoint(0F, 16.5F, -0.5F);
    			this.Body.rotateAngleX = 1.047198F;
    			this.ArmL.setRotationPoint(2F, 15.5F, -1F);
    			this.ArmR.setRotationPoint(-1F, 15.5F, -1F);
    			this.TailBase.setRotationPoint(0.5F, 17F, 5F);
    			this.TailTip.setRotationPoint(0.5F, 17F, 5F);
    			this.Face.setRotationPoint(0.5F, 15F, -1F);
    			this.EarL.setRotationPoint(0.5F, 15F, -1F);
    			this.EarR.setRotationPoint(0.5F, 15F, -1F);
    			this.Nose.setRotationPoint(0.5F, 15F, -1F);
    
    			this.UpLeg1.setRotationPoint(-1F, 19F, 4.5F);
    			this.DownLeg1.setRotationPoint(-1F, 19F, 4.5F);
    			this.Foot1.setRotationPoint(-1F, 19F, 4.5F);
    			this.UpLeg2.setRotationPoint(2F, 19F, 4.5F);
    			this.DownLeg2.setRotationPoint(2F, 19F, 4.5F);
    			this.Foot2.setRotationPoint(2F, 19F, 4.5F);
    
    			
    
               
            }
    
            
            
        }
    
    		// ANIMATION CODE END
    
    
    		public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5, Entity entity) {
    			super.setRotationAngles(f, f1, f2, f3, f4, f5, entity);
    			   this.Head.rotateAngleY = f3 / (180F / (float) Math.PI);
                   this.Head.rotateAngleX = f4 / (180F / (float) Math.PI);
    
                   this.Face.rotateAngleY = f3 / (180F / (float) Math.PI);
                   this.Face.rotateAngleX = f4 / (180F / (float) Math.PI);
    
                   this.Nose.rotateAngleY = f3 / (180F / (float) Math.PI);
                   this.Nose.rotateAngleX = f4 / (180F / (float) Math.PI) + 0.0872665F;
    
                   this.EarL.rotateAngleY = f3 / (180F / (float) Math.PI) - 0.7853982F;
                   this.EarL.rotateAngleX = f4 / (180F / (float) Math.PI);
    
                   this.EarR.rotateAngleY = f3 / (180F / (float) Math.PI) + 0.7853982F;
                   this.EarR.rotateAngleX = f4 / (180F / (float) Math.PI);
    
                   this.TailBase.rotateAngleY = f3 / (180F / (float) Math.PI);
                   this.TailTip.rotateAngleY = f3 / (180F / (float) Math.PI);
    
                   this.UpLeg1.rotateAngleX = MathHelper.cos(f * 0.6662F) * 1.4F * f1 - 0.7853982F;
                this.DownLeg1.rotateAngleX = MathHelper.cos(f * 0.6662F) * 1.4F * f1 + 0.7853982F;
                this.Foot1.rotateAngleX = MathHelper.cos(f * 0.6662F) * 1.4F * f1;
                   
                this.UpLeg2.rotateAngleX = MathHelper.cos(f * 0.6662F + (float) Math.PI) * 1.4F * f1 - 0.7853982F;
                this.DownLeg2.rotateAngleX = MathHelper.cos(f * 0.6662F + (float) Math.PI) * 1.4F * f1 + 0.7853982F;
                this.Foot2.rotateAngleX = MathHelper.cos(f * 0.6662F + (float) Math.PI) * 1.4F * f1;
                   
                this.ArmL.rotateAngleX = MathHelper.cos(f * 0.6662F) * 2.0F * f1 * 0.5F -0.3490659F;
                this.ArmR.rotateAngleX = MathHelper.cos(f * 0.6662F + (float) Math.PI) * 2.0F * f1 * 0.5F -0.3490659F;
                  
    		}
    	}
    }

    i think might have something to do with this part here:


    public void setLivingAnimations(EntityLivingBase entitylivingbaseIn)
    {
    EntitycapuchinBrown entitycapuchinBrown = (EntitycapuchinBrown)entitylivingbaseIn;



    witch i dont understand well... the wolf one is like this:



    public void setLivingAnimations(EntityLivingBase entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTickTime)
    {
    EntityWolf entitywolf = (EntityWolf)entitylivingbaseIn;

    but i dont need those floats since it wont animate while its not moving (its animations have par2 so it only animates when the entity moves)

    Posted in: Modification Development
  • 0

    posted a message on .Java files of Mobs

    i found them on MCreator.. what model do you need?


    here is the wolf


    package net.minecraft.client.model;
    
    import net.minecraft.client.renderer.GlStateManager;
    import net.minecraft.entity.Entity;
    import net.minecraft.entity.EntityLivingBase;
    import net.minecraft.entity.passive.EntityWolf;
    import net.minecraft.util.math.MathHelper;
    import net.minecraftforge.fml.relauncher.Side;
    import net.minecraftforge.fml.relauncher.SideOnly;
    
    @SideOnly(Side.CLIENT)
    public class ModelWolf extends ModelBase
    {
        /** main box for the wolf head */
        public ModelRenderer wolfHeadMain;
        /** The wolf's body */
        public ModelRenderer wolfBody;
        /** Wolf'se first leg */
        public ModelRenderer wolfLeg1;
        /** Wolf's second leg */
        public ModelRenderer wolfLeg2;
        /** Wolf's third leg */
        public ModelRenderer wolfLeg3;
        /** Wolf's fourth leg */
        public ModelRenderer wolfLeg4;
        /** The wolf's tail */
        ModelRenderer wolfTail;
        /** The wolf's mane */
        ModelRenderer wolfMane;
    
        public ModelWolf()
        {
            float f = 0.0F;
            float f1 = 13.5F;
            this.wolfHeadMain = new ModelRenderer(this, 0, 0);
            this.wolfHeadMain.addBox(-2.0F, -3.0F, -2.0F, 6, 6, 4, 0.0F);
            this.wolfHeadMain.setRotationPoint(-1.0F, 13.5F, -7.0F);
            this.wolfBody = new ModelRenderer(this, 18, 14);
            this.wolfBody.addBox(-3.0F, -2.0F, -3.0F, 6, 9, 6, 0.0F);
            this.wolfBody.setRotationPoint(0.0F, 14.0F, 2.0F);
            this.wolfMane = new ModelRenderer(this, 21, 0);
            this.wolfMane.addBox(-3.0F, -3.0F, -3.0F, 8, 6, 7, 0.0F);
            this.wolfMane.setRotationPoint(-1.0F, 14.0F, 2.0F);
            this.wolfLeg1 = new ModelRenderer(this, 0, 18);
            this.wolfLeg1.addBox(0.0F, 0.0F, -1.0F, 2, 8, 2, 0.0F);
            this.wolfLeg1.setRotationPoint(-2.5F, 16.0F, 7.0F);
            this.wolfLeg2 = new ModelRenderer(this, 0, 18);
            this.wolfLeg2.addBox(0.0F, 0.0F, -1.0F, 2, 8, 2, 0.0F);
            this.wolfLeg2.setRotationPoint(0.5F, 16.0F, 7.0F);
            this.wolfLeg3 = new ModelRenderer(this, 0, 18);
            this.wolfLeg3.addBox(0.0F, 0.0F, -1.0F, 2, 8, 2, 0.0F);
            this.wolfLeg3.setRotationPoint(-2.5F, 16.0F, -4.0F);
            this.wolfLeg4 = new ModelRenderer(this, 0, 18);
            this.wolfLeg4.addBox(0.0F, 0.0F, -1.0F, 2, 8, 2, 0.0F);
            this.wolfLeg4.setRotationPoint(0.5F, 16.0F, -4.0F);
            this.wolfTail = new ModelRenderer(this, 9, 18);
            this.wolfTail.addBox(0.0F, 0.0F, -1.0F, 2, 8, 2, 0.0F);
            this.wolfTail.setRotationPoint(-1.0F, 12.0F, 8.0F);
            this.wolfHeadMain.setTextureOffset(16, 14).addBox(-2.0F, -5.0F, 0.0F, 2, 2, 1, 0.0F);
            this.wolfHeadMain.setTextureOffset(16, 14).addBox(2.0F, -5.0F, 0.0F, 2, 2, 1, 0.0F);
            this.wolfHeadMain.setTextureOffset(0, 10).addBox(-0.5F, 0.0F, -5.0F, 3, 3, 4, 0.0F);
        }
    
        /**
         * Sets the models various rotation angles then renders the model.
         */
        public void render(Entity entityIn, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scale)
        {
            super.render(entityIn, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale);
            this.setRotationAngles(limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale, entityIn);
    
            if (this.isChild)
            {
                float f = 2.0F;
                GlStateManager.pushMatrix();
                GlStateManager.translate(0.0F, 5.0F * scale, 2.0F * scale);
                this.wolfHeadMain.renderWithRotation(scale);
                GlStateManager.popMatrix();
                GlStateManager.pushMatrix();
                GlStateManager.scale(0.5F, 0.5F, 0.5F);
                GlStateManager.translate(0.0F, 24.0F * scale, 0.0F);
                this.wolfBody.render(scale);
                this.wolfLeg1.render(scale);
                this.wolfLeg2.render(scale);
                this.wolfLeg3.render(scale);
                this.wolfLeg4.render(scale);
                this.wolfTail.renderWithRotation(scale);
                this.wolfMane.render(scale);
                GlStateManager.popMatrix();
            }
            else
            {
                this.wolfHeadMain.renderWithRotation(scale);
                this.wolfBody.render(scale);
                this.wolfLeg1.render(scale);
                this.wolfLeg2.render(scale);
                this.wolfLeg3.render(scale);
                this.wolfLeg4.render(scale);
                this.wolfTail.renderWithRotation(scale);
                this.wolfMane.render(scale);
            }
        }
    
        /**
         * Used for easily adding entity-dependent animations. The second and third float params here are the same second
         * and third as in the setRotationAngles method.
         */
        public void setLivingAnimations(EntityLivingBase entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTickTime)
        {
            EntityWolf entitywolf = (EntityWolf)entitylivingbaseIn;
    
            if (entitywolf.isAngry())
            {
                this.wolfTail.rotateAngleY = 0.0F;
            }
            else
            {
                this.wolfTail.rotateAngleY = MathHelper.cos(limbSwing * 0.6662F) * 1.4F * limbSwingAmount;
            }
    
            if (entitywolf.isSitting())
            {
                this.wolfMane.setRotationPoint(-1.0F, 16.0F, -3.0F);
                this.wolfMane.rotateAngleX = ((float)Math.PI * 2F / 5F);
                this.wolfMane.rotateAngleY = 0.0F;
                this.wolfBody.setRotationPoint(0.0F, 18.0F, 0.0F);
                this.wolfBody.rotateAngleX = ((float)Math.PI / 4F);
                this.wolfTail.setRotationPoint(-1.0F, 21.0F, 6.0F);
                this.wolfLeg1.setRotationPoint(-2.5F, 22.0F, 2.0F);
                this.wolfLeg1.rotateAngleX = ((float)Math.PI * 3F / 2F);
                this.wolfLeg2.setRotationPoint(0.5F, 22.0F, 2.0F);
                this.wolfLeg2.rotateAngleX = ((float)Math.PI * 3F / 2F);
                this.wolfLeg3.rotateAngleX = 5.811947F;
                this.wolfLeg3.setRotationPoint(-2.49F, 17.0F, -4.0F);
                this.wolfLeg4.rotateAngleX = 5.811947F;
                this.wolfLeg4.setRotationPoint(0.51F, 17.0F, -4.0F);
            }
            else
            {
                this.wolfBody.setRotationPoint(0.0F, 14.0F, 2.0F);
                this.wolfBody.rotateAngleX = ((float)Math.PI / 2F);
                this.wolfMane.setRotationPoint(-1.0F, 14.0F, -3.0F);
                this.wolfMane.rotateAngleX = this.wolfBody.rotateAngleX;
                this.wolfTail.setRotationPoint(-1.0F, 12.0F, 8.0F);
                this.wolfLeg1.setRotationPoint(-2.5F, 16.0F, 7.0F);
                this.wolfLeg2.setRotationPoint(0.5F, 16.0F, 7.0F);
                this.wolfLeg3.setRotationPoint(-2.5F, 16.0F, -4.0F);
                this.wolfLeg4.setRotationPoint(0.5F, 16.0F, -4.0F);
                this.wolfLeg1.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F) * 1.4F * limbSwingAmount;
                this.wolfLeg2.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F + (float)Math.PI) * 1.4F * limbSwingAmount;
                this.wolfLeg3.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F + (float)Math.PI) * 1.4F * limbSwingAmount;
                this.wolfLeg4.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F) * 1.4F * limbSwingAmount;
            }
    
            this.wolfHeadMain.rotateAngleZ = entitywolf.getInterestedAngle(partialTickTime) + entitywolf.getShakeAngle(partialTickTime, 0.0F);
            this.wolfMane.rotateAngleZ = entitywolf.getShakeAngle(partialTickTime, -0.08F);
            this.wolfBody.rotateAngleZ = entitywolf.getShakeAngle(partialTickTime, -0.16F);
            this.wolfTail.rotateAngleZ = entitywolf.getShakeAngle(partialTickTime, -0.2F);
        }
    
        /**
         * Sets the model's various rotation angles. For bipeds, par1 and par2 are used for animating the movement of arms
         * and legs, where par1 represents the time(so that arms and legs swing back and forth) and par2 represents how
         * "far" arms and legs can swing at most.
         */
        public void setRotationAngles(float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scaleFactor, Entity entityIn)
        {
            super.setRotationAngles(limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scaleFactor, entityIn);
            this.wolfHeadMain.rotateAngleX = headPitch * 0.017453292F;
            this.wolfHeadMain.rotateAngleY = netHeadYaw * 0.017453292F;
            this.wolfTail.rotateAngleX = ageInTicks;
        }
    }
    Posted in: Modification Development
  • 0

    posted a message on Mob is Tamed but the Model wont sit?

    ok so i got it, i think i did everything right, but i might be put something on the wrong place or i miss something, but i made a sitting version of my techne model and i put the code in it, made a IF/Else, yet it wont sit.. what im missing here guys?

    Posted in: Modification Development
  • 0

    posted a message on Mob is Tamed but the Model wont sit?

    working on it...

    Posted in: Modification Development
  • 0

    posted a message on Mob is Tamed but the Model wont sit?

    oh i dont think i have that on my class yet... can i paste it from the wolf entity for example? then change the rotations/stuff like that?


    btw long time no see ya! how are you my friend?


    thanks

    hum i cant find that method on the wolf file nor the tameable file.. how do i set this up man?


    thanks again

    Posted in: Modification Development
  • To post a comment, please .