Posted October 14, 201410 yr How do I Make an Entity Spawn naturally in the end? My Source Code is at https://github.com/EacMods/Eac/tree/master/src/main/java/Eac Yes my entity extends Enderman but doesn't spawn naturally (Yet) in the end (or like the enderman in the overworld) Owner of The-Eac.nl domain and Eac teamspeak server Creator of WIP-Eac mod
October 14, 201410 yr Author Nevermind just found it I had to add the following code to my mod: EntityRegistry.addSpawn(entityClass, 2, 0, 1, EnumCreatureType.monster, BiomeGenBase.sky); So it would look like this: 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, Eac.mobInstance, 64, 1, true); EntityRegistry.addSpawn(entityClass, 2, 0, 1, EnumCreatureType.monster, BiomeGenBase.sky); createEgg(randomId, solidColor, spotColor); } Owner of The-Eac.nl domain and Eac teamspeak server Creator of WIP-Eac mod
October 17, 201410 yr Author @diesieben07 I have somethings to ask and say So basically I can delete line 21 (registerGlobalEntityId) (At EacEntity.java) or do I have to delete line 22 (registerModEntity)? How would I pass the entity-egg colors to registerGlobalEntityID? With the current setup I only would have to use the following code to register an Entity createEntity(ClassNameOfEntity.class, "Name Of Entity", 0xBackgroundColor, 0xSpotColour); I dont know How I would Not use the global IDs (yet...) Owner of The-Eac.nl domain and Eac teamspeak server Creator of WIP-Eac mod
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.