Magneticraft

Magneticraft

8M Downloads

NoClassDefFoundError when reflecting into BlockBase and subclasses

codewarrior0 opened this issue ยท 1 comments

commented

With CharsetImmersion installed and playing on an MP server, right-clicking an ingot onto the Crushing Table appears to place the ingot on the table, but on the server this action fails due to a caught exception:

https://pastebin.com/e7cABu6g

The player can attempt to smash the ingot into the plate and pick it up, but as soon as the player's inventory is synced it will reveal that no ingots have been smashed and no hammer durability has been consumed.

The resolution is probably to add @SideOnly(Side.CLIENT) to BlockBase.getCustomStateMapper()

Charset-Immersion-0.5.0.248e.jar
Magneticraft_1.12-2.4.0-dev.jar
forge-1.12.2-14.23.4.2726

VanillaFix is also installed on the server. I'm not sure whether this error would crash the server if VanillaFix were not installed.

commented

Ok, you are right, adding @SideOnly(Side.CLIENT) will fix the problem.

I didn't know that Class.getDeclaredMethod() checked every method in the class.