kicked from the server, neruina caught lithium stuff
VaporeonScripts opened this issue · 11 comments
friendsandfoes illusion totem crashing the player by loading a client-side class on the server, report to them
Caused by: java.lang.RuntimeException: Attempted to load class net/minecraft/client/multiplayer/PlayerInfo for invalid dist DEDICATED_SERVER
@Bawnorton Which class exactly is this supposed to be?
Are you running with lithium? I suspect based on the stack trace that lithium is reflectively loading your mob's class which includes client-side classes
No, i tried without lithium, also ofc it contains the client-side classes, its an entity. But i find this suspicious, totem logic is around for like multiple years already without any kind of issues.
Also i can't see in the logs, from which place it is trying to load the mentioned PlayerInfo, so i could try to identify the problem and fix it.
No, i tried without lithium, also ofc it contains the client-side classes, its an entity. But i find this suspicious, totem logic is around for like multiple years already without any kind of issues.
Not of course, no vanilla mob includes client-side classes, closest is client-bound packets which exist in the server jar.
This requires very specific circumstances to occur and its triggered by your mod using the illusion totem + lithium w/ entity collision optimizations specifically on a dedicated server
Also i can't see in the logs, from which place it is trying to load the mentioned PlayerInfo, so i could try to identify the problem and fix it.
It's at the bottom via caused by, you can strip out the transformer info that neoforge attaches to stack trace elements to make it more readable
I guess i will try to separate the client sided logic from my entity into the "util" class.
Also you are correct i combined some parts of client player and player, thus this mess.
No problem, yeah its not exactly obvious
For the sake of clarity here is the logic flow:
- PlayerIllusionEntity spawns and tries to teleport
- Minecraft starts collision checks
- Lithium intercepts collision checks
- Lithium reflectively analyses the class for its
canCollideWithmethod or parent implementation for caching and optimization - This loads your class wholly which includes methods that contain references to client side classes
- A crash is propagated up the call chain until it reaches Neruina
- Neruina intercepts the crash and takes appropriate action, given this started running on a player tick it kicks the player