Missing null check in LivingDropsEvent for imbuements
Nuttar2004 opened this issue ยท 2 comments
The game crashes. I don't know why my corpse mod will disappear when I create / kill mode, and the game will crash when my survival mode is killed by mob
This has happened many times and I don't know why. Only the crash report says electroblob.wizardry It feels like it did it. Can you help me out
I really like this mod and add it to the integration package I've been working on recently, let alone delete it. Please solve this problem quickly
Here is the crash report
crash-2020-06-14_21.54.22-server.txt
latest.log
These are for tonight. It's just one of them. I have a lot more
If I can, I can send more to you. I hope I can help you, and I
EBWizardry should probably guard against null here,
but also probably shouldn't have to. Corpse may be nulling the drops, rather than appropriately setting them to empty. It's hard to say, since the source code doesn't appear to be publicly visible. You may wish to file an issue with them as well.
I had a feeling I'd seen this before, and sure enough I've put a comment to that effect in the other place I use LivingDropsEvent
:
Wizardry/src/main/java/electroblob/wizardry/item/IConjuredItem.java
Lines 105 to 114 in 27d53b4
It's simple enough to guard against nulls here too so I'll add that in. As @Tora-B points out though, I shouldn't have to do that so it may also be worth filing an issue with Corpse.