[1.18.1 Forge] Guns won't reload on server, server crashing, singleplayer crashes
de-vo-id opened this issue ยท 8 comments
Hello, I'm coming here after reviewing some of the other issue requests posted. I run a small server for my friends and I to play on, and we seem to be having either one issue or multiple with this mod.
When we join the server, sometimes it gets stuck on encrypting and throws "Received unknown synced keys: [(minecraft:player,cgm:aiming)]" on the server. During the times that we can get on the server, we see the same issue that I notice has been mentioned multiple times on this GitHub. Weapons do not reload, no sound plays, and no evidence of any errors are given, even with your custom debug version of Framework on both the server and the client. On singleplayer, I receive multiple game breaking errors on the client and the game crashes as the world is loading. Some of the errors include "net.minecraft.ReportedException: Ticking player", "[Server thread/ERROR]: Couldn't place player in world", and "class com.mrcrayfish.framework.common.data.SyncedEntityData$DataHolder cannot be cast to class."
I have attached my client log, which represents the issues as they stand when joining a singleplayer world. I have also attached a list of the mods that are enabled on the client and the server. I have tried downgrading my Forge on both the client and the server, to no avail. I have also tried both public versions of Framework posted on CurseForge. If I could receive help with this issue, I would greatly appreciate it. Thank you!
Sorry for the issue. This has been a bug in Framework for a while and it's been difficult to resolve since there is no explaination why a synced key is becoming unknown when logs clearly state that it has been registered. I've looked over all my code and nothing would unregister a key.
I will point out that the custom version of Framework I uploaded did have bug that caused the "cast to class" issue. This won't happen if you download the normal public version. However it seems you are interested in resolving this issue, I've unfortuantely not been able to replicate the problem which has been a big reason why I can't fix the issue, would you be willing to try using another custom version? It's again just another version with extra logging but this time I am actually dumping lots more of the internal data and code calls.
Here is the new custom version. You'll likely need everyone to use this version since you'll need to match the version installed on the server. If you anyone happens to run into the crash regarding "Recieved unknown synced keys" (shown in game) or "The synced data key X for X is not registered!" (shown in logs), then can you send me the game logs? I'd recommend sending the debug.log that Forge generates, turn it on if you can. There is a setting in CurseForge app that allows you to do that, not sure about MultiMC.
framework-0.2.4-1.18.1.zip
Hey,
Here are the logs that I could gather. Lots of debug info & errors shown from other mods, but that's just forge's messy reporting for ya I guess. I added the custom Framework version to the server and our clients. The only thing that appeared to show up on the logs was the "Registered keys before throwing exception: [(minecraft:player,cgm:reloading),(minecraft:player,cgm:shooting)]" part at the end. Although it's not much, I hope it helps!
Thank you. These new reports have seem to help point to a possible cause for the issue however I am still can't find the offending code. Here is a new version which has more logging directed at the potentially bugged code. I appreciate you helping me.
framework-0.2.4-1.18.1.zip
New logs incoming! These seem to show more, at least on the client side.
Turns out the issue might be coming from the Gun Mod. Here is custom version that has altered when synced keys are registered. This is actually a patch that is already in the 1.18.2 version of the mod, not 1.18.1. Keep the custom version of Framework to confirm if this fixed the issue. If you have no crashes after a while, send the logs regardless.
gun-mod-1.1.3-1.18.1.zip
.
Looks like the keys are registered properly now! Tested for around 5-10 minutes with no issues at all. Weapons reload, audio plays, and damage is taken. I hope these latest logs can confirm for you that everything is working as intended, and hopefully we can see a public release soon?
My friends and I appreciate your hard work. Thank you!