[1.16.5] Clients crash when joining LAN Server
FoxMcloud5655 opened this issue ยท 7 comments
Minecraft Version: 1.16.5
Forge Version: 36.0.42
Mod Version: 2.6.7.1
When clients attempt to join a single-player world that's been opened to LAN connections, they crash. I have not tested on a dedicated server, so I'm not sure if this can be replicated in that environment.
The crash is a NullPointerException on line 78 in the KeybindHandler.java file.
I assume that this has to do with not checking if mc.player.movementInput
is null (presumably upon first load before everything is synced up), but I could be wrong.
There would be no harm in adding a null pointer check and would definitely be recommended. I've just tested on a LAN setup with the same configuration and it's working as normal, no crash. I can only speculate that this is either a race condition or another mod is manipulating code. Have you tried an isolated test (just SimplyJetpacks2 and it's requried libraries)?
Running with just Simply Jetpacks 2 does not cause the crash. I double-checked to make sure that the crash is still happening with our full modpack and it does, so it must be a mod conflict issue instead.
I'm going to remove mods one at a time until I figure out which one it is and report back when I figure it out.
I forgot to mention that reverting to mod version 2.6.6.0 fixes this issue due to different methods being called.
I found the mod. DynamicSurroundings, of all the things, crashes SimplyJetpacks after the code change mentioned before.
I've looked through DynamicSurrounding's code and issues, and it seems like they are having some issues at the moment with their 1.16.5 build that I recognize; I'm pretty sure that this crash is due to said issues. That being said, it wouldn't hurt to put a check for null on mc.player.movementInput
to ensure that at least that game won't crash when another mod messes with things.
Sorry for the trouble!
That's definitely strange because I can't find any code that would be the cause. I think just adding the null check is the best solution.
I agree. OreCruncher asked me to run his new version, and as far as I can tell, they just added some extra debug statements to the version to help sort out exactly what the issue was, but now the issue is completely gone. I re-tested it both ways and ensured that the crash still happened on the old version too.
In any case, the issue seems to have been resolved on their end, so I'm glad it was at least sorted out!