public class EntityRegistry
extends java.lang.Object
| Modifier and Type | Class and Description | 
|---|---|
| class  | EntityRegistry.EntityRegistration | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | addSpawn(java.lang.Class<? extends EntityLiving> entityClass,
        int weightedProb,
        int min,
        int max,
        EnumCreatureType typeOfCreature,
        BiomeGenBase... biomes)Add a spawn entry for the supplied entity in the supplied  BiomeGenBaselist | 
| static void | addSpawn(java.lang.String entityName,
        int weightedProb,
        int min,
        int max,
        EnumCreatureType typeOfCreature,
        BiomeGenBase... biomes)Add a spawn entry for the supplied entity in the supplied  BiomeGenBaselist | 
| static int | findGlobalUniqueEntityId()Deprecated.  | 
| static java.util.Map<java.lang.String,EntityList.EntityEggInfo> | getEggs()Returns a Unmodifiable view of the registered entity eggs list. | 
| static EntityRegistry | instance() | 
| EntityRegistry.EntityRegistration | lookupModSpawn(java.lang.Class<? extends Entity> clazz,
              boolean keepLooking) | 
| EntityRegistry.EntityRegistration | lookupModSpawn(ModContainer mc,
              int modEntityId) | 
| static void | registerEgg(java.lang.Class<? extends Entity> entityClass,
           int primary,
           int secondary)Registers a spawn egg for the specified entity class. | 
| static void | registerGlobalEntityID(java.lang.Class<? extends Entity> entityClass,
                      java.lang.String entityName,
                      int id)Deprecated.  | 
| static void | registerGlobalEntityID(java.lang.Class<? extends Entity> entityClass,
                      java.lang.String entityName,
                      int id,
                      int backgroundEggColour,
                      int foregroundEggColour)Deprecated.  | 
| static void | registerModEntity(java.lang.Class<? extends Entity> entityClass,
                 java.lang.String entityName,
                 int id,
                 java.lang.Object mod,
                 int trackingRange,
                 int updateFrequency,
                 boolean sendsVelocityUpdates)Register the mod entity type with FML | 
| static void | registerModEntity(java.lang.Class<? extends Entity> entityClass,
                 java.lang.String entityName,
                 int id,
                 java.lang.Object mod,
                 int trackingRange,
                 int updateFrequency,
                 boolean sendsVelocityUpdates,
                 int eggPrimary,
                 int eggSecondary)Register the mod entity type with FML
 This will also register a spawn egg. | 
| static void | removeSpawn(java.lang.Class<? extends EntityLiving> entityClass,
           EnumCreatureType typeOfCreature,
           BiomeGenBase... biomes)Remove the spawn entry for the supplied entity | 
| static void | removeSpawn(java.lang.String entityName,
           EnumCreatureType typeOfCreature,
           BiomeGenBase... biomes)Remove the spawn entry for the supplied entity | 
| boolean | tryTrackingEntity(EntityTracker entityTracker,
                 Entity entity) | 
public static EntityRegistry instance()
public static void registerModEntity(java.lang.Class<? extends Entity> entityClass, java.lang.String entityName, int id, java.lang.Object mod, int trackingRange, int updateFrequency, boolean sendsVelocityUpdates)
entityClass - The entity classentityName - A unique name for the entityid - A mod specific ID for the entitymod - The modtrackingRange - The range at which MC will send tracking updatesupdateFrequency - The frequency of tracking updatessendsVelocityUpdates - Whether to send velocity information packets as wellpublic static void registerModEntity(java.lang.Class<? extends Entity> entityClass, java.lang.String entityName, int id, java.lang.Object mod, int trackingRange, int updateFrequency, boolean sendsVelocityUpdates, int eggPrimary, int eggSecondary)
entityClass - The entity classentityName - A unique name for the entityid - A mod specific ID for the entitymod - The modtrackingRange - The range at which MC will send tracking updatesupdateFrequency - The frequency of tracking updatessendsVelocityUpdates - Whether to send velocity information packets as welleggPrimary - Primary egg coloreggSecondary - Secondary egg colorpublic static void registerEgg(java.lang.Class<? extends Entity> entityClass, int primary, int secondary)
entityClass - The entity classprimary - Primary egg colorsecondary - Secondary egg colorjava.lang.IllegalArgumentException - if entityClass is not registered in classToStringMapping.public static java.util.Map<java.lang.String,EntityList.EntityEggInfo> getEggs()
@Deprecated public static void registerGlobalEntityID(java.lang.Class<? extends Entity> entityClass, java.lang.String entityName, int id)
registerModEntity(Class, String, int, Object, int, int, boolean, int, int) instead.entityClass - Class of the entity being registeredentityName - Name for the entity being registeredid - A globally unique ID for the entity@Deprecated public static void registerGlobalEntityID(java.lang.Class<? extends Entity> entityClass, java.lang.String entityName, int id, int backgroundEggColour, int foregroundEggColour)
registerModEntity(Class, String, int, Object, int, int, boolean) instead.entityClass - The class of the entity being registeredentityName - The name of the entity being registeredid - The globally unique ID of the entitybackgroundEggColour - An RGB colour value for the spawn egg background colourforegroundEggColour - An RGB colour value for the spawn egg foreground colourpublic static void addSpawn(java.lang.Class<? extends EntityLiving> entityClass, int weightedProb, int min, int max, EnumCreatureType typeOfCreature, BiomeGenBase... biomes)
BiomeGenBase listentityClass - Entity class addedweightedProb - Probabilitymin - Min spawn countmax - Max spawn counttypeOfCreature - Type of spawnbiomes - List of biomespublic static void addSpawn(java.lang.String entityName,
                            int weightedProb,
                            int min,
                            int max,
                            EnumCreatureType typeOfCreature,
                            BiomeGenBase... biomes)
BiomeGenBase listentityName - The entity nameweightedProb - Probabilitymin - Min spawn countmax - Max spawn counttypeOfCreature - type of spawnbiomes - List of biomespublic static void removeSpawn(java.lang.Class<? extends EntityLiving> entityClass, EnumCreatureType typeOfCreature, BiomeGenBase... biomes)
entityClass - The entity classtypeOfCreature - type of spawnbiomes - Biomes to remove frompublic static void removeSpawn(java.lang.String entityName,
                               EnumCreatureType typeOfCreature,
                               BiomeGenBase... biomes)
entityName - Name of entity being removedtypeOfCreature - type of spawnbiomes - Biomes to remove from@Deprecated public static int findGlobalUniqueEntityId()
registerModEntity(Class, String, int, Object, int, int, boolean) instead,
 for a much better experience.public EntityRegistry.EntityRegistration lookupModSpawn(java.lang.Class<? extends Entity> clazz, boolean keepLooking)
public EntityRegistry.EntityRegistration lookupModSpawn(ModContainer mc, int modEntityId)
public boolean tryTrackingEntity(EntityTracker entityTracker, Entity entity)