Posted September 4, 201411 yr The function getEntitySpawningPacket(Entity entity) calls the following function with false as second argument. However, the way it is coded that flag will be ignored. [it will search up the class tree for no reason, which is unintended behavior] Current method in cpw.mods.fml.common.registry.EntityRegistry: public EntityRegistration lookupModSpawn(Class<? extends Entity> clazz, boolean keepLooking) { Class<?> localClazz = clazz; do { EntityRegistration er = entityClassRegistrations.get(localClazz); if (er != null) { return er; } localClazz = localClazz.getSuperclass(); keepLooking = (!Object.class.equals(localClazz)); } while (keepLooking); return null; } Proposed code to make the keepLooking parameter actually useful: public EntityRegistration lookupModSpawn(Class<? extends Entity> clazz, boolean keepLooking) { Class<?> localClazz = clazz; do { EntityRegistration er = entityClassRegistrations.get(localClazz); if (er != null) { return er; } localClazz = localClazz.getSuperclass(); } while (keepLooking && (!Object.class.equals(localClazz))); return null; } This might already be changed, but I checked 1208 and it isn't. -S- (if I helped, please click Thank and applaud) http://6upnqa.dm2301.livefilestore.com/y2mtf-vG7Tqq1TiiVpIm53KWj7294NDPoHfSHHb4PzZiMAUfRCfK0UY0MwOu7Q3zTBNVTKqWjr2-xgBfFRpQT5p-QivtvknPpoABMNUw9br9WuZcBFkjePhnAbW500gVm-P/sequiturian.png[/img]
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.