Crash with Shift-Clicking Reliquary Curios to/from Curios Inventory
P3BBL35 opened this issue ยท 4 comments
Version: 1.20.1
Mod Version: 2.0.36.1199
Curios Mod Version: 5.4.0 for 1.20.1
Issue: Currently running a custom modded server with some friends. When someone shift-clicks the Invisibility Cloak curio in/out from the Curios inventory, the server crashes. This happened consistently and was reproducible. We tried putting the Cloak on and off without shift-clicking the item into the curios inventory, and no crashes occurred.
Also tested for the Charm Belt, which caused a client-side crash, and the Twilight Cloak, which had the same results. Both crashed with the following error message on the server log:
java.lang.ClassCastException: class net.minecraft.world.item.AirItem cannot be cast to class reliquary.items.util.ICuriosItem (net.minecraft.world.item.AirItem is in module [email protected] of loader 'TRANSFORMER' @76b05c0; reliquary.items.util.ICuriosItem is in module [email protected] of loader 'TRANSFORMER' @76b05c0)
at TRANSFORMER/[email protected]/reliquary.compat.curios.CuriosBaubleItemWrapper.<init>(CuriosBaubleItemWrapper.java:15)
at TRANSFORMER/[email protected]/reliquary.compat.curios.CuriosCompat$1.lambda$getCapability$0(CuriosCompat.java:84)
at TRANSFORMER/[email protected]/net.minecraftforge.common.util.LazyOptional.getValue(LazyOptional.java:99)
at TRANSFORMER/[email protected]/net.minecraftforge.common.util.LazyOptional.getValueUnsafe(LazyOptional.java:110)
at TRANSFORMER/[email protected]/net.minecraftforge.common.util.LazyOptional.map(LazyOptional.java:180)
at TRANSFORMER/[email protected]+1.20.1/top.theillusivec4.curios.common.event.CuriosEventHandler.syncCurios(CuriosEventHandler.java:663)
at TRANSFORMER/[email protected]+1.20.1/top.theillusivec4.curios.common.event.CuriosEventHandler.lambda$tick$29(CuriosEventHandler.java:577)
at TRANSFORMER/[email protected]/net.minecraftforge.common.util.LazyOptional.ifPresent(LazyOptional.java:137)
...
Some hopefully relevant server crash logs here regarding my friends trying the shift-clicking, which caused a full server crash.
crash-2023-11-11_18.50.08-server.txt
crash-2023-11-11_18.54.28-server.txt
crash-2023-11-11_18.57.59-server.txt
I tried shift-clicking like crazy while also angering enderman because that's what I saw was happening in one of the crash logs, but I am unable to recreate. Looks like one of the ton of mods you have there is doing something funky where it allows updating stack in curios at the same time enderman's anger code is running which definitely isn't vanilla behavior where these things happen after each other. If you are able to figure out how to recreate with a specific mod or a few mods I can take another look to see if there's anything on my side to fix.
From some playing around, it seems like it's an incompatibility with the L2 Library Mod. The following crash log is with just Reliquary, Curios API, and L2 Library mods, using the latest versions of each. This is specifically concerning the L2 Library's Curios Inventory. Shift-clicking a curio from the Curios inventory causes a crash.
crash-2024-04-02_15.05.38-server.txt
I tried doing the same thing with some other Curio-supporting mods like Artifacts, and shift-clicking from the Curios Inventory does not cause a crash. It seems to only be Reliquary-related curios.
Alright, please report to them as they are doing something funky then which causes the stack to be empty despite the fact that it wasn't empty when it got curio capability initialized based on the fact it was a curio. No idea what that could be but give the fact they are actually adding whole new screen for curios I am guessing it's some improper update of the stacks in slot click code or something similar.