You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After reading the crash log coupled with this mod's source, I have isolated the cause to ItemMixin.java L38. This line does not first verify that ItemStack#hasTag() is true, causing it to call CompoundTag#contains on a null reference. (n.b. these names are declared in mojmap, so naturally the names seen in this mod's source may be slightly different, ymmv).
This error soft-locks the player's save file, requiring them to use a tool like NBTEdit to manually remove the item from their inventory before they can rejoin their world. It can be bypassed by manually giving the player the applicable item with a tag attached via the /give command. The content of the tag does not matter, just so long as NBT data exists /give @p mod:item{asdfg:0b}
The text was updated successfully, but these errors were encountered:
EtiTheSpirit
changed the title
NPE is raised by ItemMixin when a shield that has no NBT tags is in the player's inventory.
NPE is raised by ItemMixin when a sword or shield that has no NBT tags is in the player's inventory.
Jan 29, 2023
EtiTheSpirit
changed the title
NPE is raised by ItemMixin when a sword or shield that has no NBT tags is in the player's inventory.
NPE crash is caused by ItemMixin when a sword or shield that has no NBT tags is in the player's inventory
Feb 11, 2023
I've been able to replicate this issue with the Aquaculture fillet knife and the Red Matter sword in ProjectE.
Here is an example of the crash with the neptunium fillet knife. It's a similar issue, because the knife is unbreakable it doesn't have a compound tag, causing the player to be soft-locked upon placing the item in their inventory.
This issue was originally reported on my own mod's repository, see The Ori Mod :: Issue #17.
After reading the crash log coupled with this mod's source, I have isolated the cause to ItemMixin.java L38. This line does not first verify that
ItemStack#hasTag()
istrue
, causing it to callCompoundTag#contains
on anull
reference. (n.b. these names are declared in mojmap, so naturally the names seen in this mod's source may be slightly different, ymmv).This error soft-locks the player's save file, requiring them to use a tool like NBTEdit to manually remove the item from their inventory before they can rejoin their world. It can be bypassed by manually giving the player the applicable item with a tag attached via the
/give
command. The content of the tag does not matter, just so long as NBT data exists/give @p mod:item{asdfg:0b}
The text was updated successfully, but these errors were encountered: