Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Render File:
- package com.animalcraft.animal;
- import com.animalcraft.Main;
- import cpw.mods.fml.common.registry.EntityRegistry;
- import net.minecraft.entity.EntityList;
- import net.minecraft.entity.EnumCreatureType;
- import net.minecraft.world.biome.BiomeGenBase;
- public class RegRedPanda
- {
- public static void mainRegistry()
- {
- registerEntity();
- }
- public static void registerEntity()
- {
- createEntity(EntityRedPanda.class, "Red Panda", 0x854709, 0xE89643);
- }
- public static void createEntity(Class entityClass, String entityName, int solidColor, int spotColor)
- {
- int randomId = EntityRegistry.findGlobalUniqueEntityId();
- EntityRegistry.registerGlobalEntityID(entityClass, entityName, randomId);
- EntityRegistry.registerModEntity(entityClass, entityName, randomId, Main.modInstance, 64, 1, true);
- EntityRegistry.addSpawn(entityClass, 3, 0, 1, EnumCreatureType.creature, BiomeGenBase.beach);
- createEgg(randomId, solidColor, spotColor);
- }
- private static void createEgg(int randomId, int solidColor, int spotColor)
- {
- EntityList.entityEggs.put(Integer.valueOf(randomId), new EntityList.EntityEggInfo(randomId, solidColor, spotColor));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement