Since it seems rolik1997 has abandoned the Mutated Mobs Mod, and since I really like it for the variety of monsters it adds to Minecraft, I decided to decompile it to fix many bugs.
- Fix entity ID mismatches caused by differing
EnableXXXXconfiguration values between client/server by removing them entirely- These mismatches caused many
ClassCastExceptions when trying to read data from an entity'sEntityDataManageronly to find another entity's data inside. More on this below.
- These mismatches caused many
- Fix
defineIdwarnings caused by passing the wrong class toEntityDataManager.createKey - Refactor code in
EntityLoaderto not have bloated lines
On the same day I discovered the real culprit is this code for registering entities into Forge. The cause for all of the typecasting crashes is the fact that EntityLoader uses a monotonically increasing id integer when registering entities, AND allows you to disable the registering of any entity class. And if you disable just one entity on the server but not the client, the remaining to-be-registered entities will all have mismatched IDs from server to client, causing NBT data meant for one entity class to arrive at another.
Lesson: do not change any of the EnableXXXXMob configuration values!!! It is not necessary when you can set spawnrates to zero. And if you really don't want to register one of those mobs, make sure the change is done both server- and client-side.
All credit for the original mod (code, assets) goes to rolik1997.
If the original author of the mod (rolik1997) does not want the code and/or assets hosted on this repository, please leave an issue or email me at t@trustytrojan.dev.