MrCrayfish's Gun Mod

MrCrayfish's Gun Mod

25M Downloads

Reloading - Forge update - Ticking Player

Strana opened this issue ยท 17 comments

commented

The top issue as you probably already know is the temperamental reloading bug:

Around 6/1 times I start up minecraft (just an approximate), weapon reloading does not work at all, once in a blue moon it does work.
But when it doesn't work, I close and restart minecraft, with these attempts it either:
A: The game crashes after the mojang screen with an "EXCEPTION_ACCESS_VIOLATION" message, I have not yet checked if it's related to the gun mod.
B: Crashes when loading the world, specifically at the "Loading Terrain" stage, I'll get to this later.
C: Does nothing and reloading still doesn't work.

Forge update 39.0.45 did some collateral damage lol

This Forge update has rendered the mod incompatible with newer Forge versions due to the workbench corrupting a chunk because it makes use of the BlockEntity#save(CompoundTag) method, which was removed in this Forge update. This is mentioned in issue #242. I believe this is the easiest issue to fix as of right now, but idk, I'm not a mod dev.

Ticking Player, stop freaking ticking!!!!

I mentioned this in B on the first segment, often times, when loading a world, the game crashes on the "Loading Terrain" stage, the crash log shows the description "Ticking Player", and then mentions the gun mod.

I will provide crash logs on request via Pastebin. I will also provide my modlist on request via Pastebin.

Forge version: 39.0.44 - Minecraft version: 1.18.1 - Encountered on singleplayer worlds, I never play multiplayer so idk about that.

commented

I have performed some extensive testing with my mods until I find a suspect to determine if some conflict is occuring, on all tests Optifine, Configured, Gun Mod, its core, and the additional guns mod are installed. I will test each setup three times, with every test I add a mod and its core if necessary.

Testing results:

No additional mods installed: All good
JEI and JER installed: All good
Create and its core Flywheel: All good
Consistency+ and its cores Architectury & StonecutterRecipeTags: All good
Xaero's Minimap and World Map: All good
Curios API: All good
Carry On: All good
Enchantment Descriptions: All good
Sophisticated Backpacks: All good
AmbientSounds 5 and its core CreativeCore: All good
Fixed Anvil Repair Cost and its core Collective: All good
Supplementaries and its core Selene: Test one success. Test two TICKING PLAYER crash: synced key cgm:aiming for minecraft:player not registered. Test three, same as test two.

Our suspect seems to be Supplementaries and Selene, or just Selene. NotEnoughCrashes crash reports point to Framework and the Gun Mod for causing issues, I suggest looking into Selene, and how Selene and both CGM and Framework interact.

Check other peoples' modlists for Selene if they also report reloading and/or ticking player issues.

commented

Another update on the ticking player issue:

Along with Selene, Durability101 is also possibly causing conflicts.
The crash description still seems to be the same, "The synced data key cgm:aiming for minecraft:player is not registered!"
Crash reports aren't pointing fingers at anything other than CGM and Framework, but it seems as though something is going on with other mods.

https://pastebin.com/WKt9mdTh

commented

Try using this version of the Gun Mod when testing. It's a custom version with extra logging and has some code changes that may fix the issue. Send me your game logs and crash when you encounter the crash again.
gun-mod-1.1.4-1.18.1.zip

Having that said, I have tried your combination of mods (installed every single one) and ran the game multiple times (closing completely before starting again) and no crash or issues with reloading.

commented

Here is also a custom version of Framework with extra logging. It may help with solving the issue.
framework-0.2.3-1.18.1 (2).zip

commented

Update: I just started my game again and I ran into the reloading issue. This is good, I can finally debug.

Update 2: Seems to be quite random. Can't seem to get the issue again.

commented

Try using this version of the Gun Mod when testing. It's a custom version with extra logging and has some code changes that may fix the issue. Send me your game logs and crash when you encounter the crash again. gun-mod-1.1.4-1.18.1.zip

Having that said, I have tried your combination of mods (installed every single one) and ran the game multiple times (closing completely before starting again) and no crash or issues with reloading.

Will do, I will provide my mod checklist which lists all my active mods in a readable manner:
https://pastebin.com/TDrz7wBi

Edit: after updating some mods to work on forge 39.0.59, and testing 3 times so far, no issues, reloading issue hasn't been present, no ticking player crash. I will come back here if I do experience one of these issues, but so far after three tests, no issues, you should hang on to that version, I think we are on to something.

commented

Just to clarify, I ran into the bug before I applied some code changes that could potentially fix the issue so I am not sure if the bug is present still.

commented

Got the reloading issue again, 5th session, I don't know if it was present throughout the entire session, but I do know I noticed I couldn't reload after going into the nether with a weapon equipped, and doesn't reload at all in any dimension.

Upon starting the 6th session, reloading works in a test world, which in turn means it works in all worlds, so I went to my survival world, reloading works. I went into the nether and then the reloading was broken. This may be worth looking in to.
Seems like reloading now only breaks when going into a different dimension.

Edit: I just reloaded the world without starting a new session and the reloading bug isn't present so now it seems it's isolated to a single world when the player goes to a different dimension.

Just to clarify, I ran into the bug before I applied some code changes that could potentially fix the issue so I am not sure if the bug is present still.

It seems you fixed the bug occuring on startup at the very least though ๐Ÿ‘

commented

Send your game logs! (hoping you were using the custom verison)

commented

Send your game logs! (hoping you were using the custom verison)

I am using the custom version but I have no clue where said logs are, the only logs I know about are crash logs and I know you don't mean those

commented

In the same directory as the mods folder is located, you should be able to find the logs folder.

commented

ah, the .log.gz files I assume, I will start a session and replicate the dimension issue and send

Edit: nvm there is a latest.log file, thats the one

I got the log, I'm just cleaning it up from valhesia structures stuff that flooded it with warns unrelated to our issue

commented

Log of session where I reproduce the dimension causing the reload bug
https://pastebin.com/8t6n2Xvn

commented

Thanks for actually sending messages in chat. I think I have an idea what it is now.

commented

Thanks for actually sending messages in chat. I think I have an idea what it is now.

You're welcome mate, pleasure working this out for ya

commented

I can definitely confirm that going into the Nether (with the previously mentioned mods installed) will prevent reloading. When I test it only with the Gun Mod installed it won't have the bug. Going to actually dig deep into testing code since I know where to look.

commented

Update to the latest verison. The issue should now be resolved.