Unique Enchantments - Battle

Unique Enchantments - Battle

4M Downloads

[1.16.5 - utils addon] Null pointer exception when tool enchanted book dropped as loot and the book gets ticked anyway

Colin-J-Wood opened this issue ยท 11 comments

commented

happened whilst I was playing on dedicated server. Crashes client only, server remains up

https://pastebin.com/U0LuiurA

commented

I was killing Champion mobs which in their loot table is specified to drop a random enchanted book with levels, and it ended up dropping a util addon enchantment, which crashed the client after a few seconds of sitting there. this does not happen with any other mods' enchantments

commented

could you specify what you mean by "tool enchanted book"?

commented

could you specify what you mean by "tool enchanted book"?

any enchanted book provided by the utils addon that affects a tool such as a pickaxe, axe, shovel, but not a weapon such as a sword

commented

can you figure out which Enchantment that is?

commented

it's possible though, due to how many mobs I was battling at the time, that maybe it occured because an entity was actually generated to hold a specific item with an enchantment provided by utils, and it may have attempted to use the tool as a weapon, resulting in the crash.

I will test both scenarios and report what I find

commented

well...any attempt to reenter the same world now results in an internal server error and kicks me. server is spitting out something now. one sec whilst I pastebin it

commented

nope, that crash was caused by spartanweaponry. reporting that one to them now. resuming testing on your mod in a moment

commented

my theory is the crash occurs because your mod tries to consider the enchanted book as an ordinary tool, which returns null since the item would have no tool-inherited attributes. the fact it only crashed the client side though is weird.

commented

I am having trouble reproducing the crash (it is extremely rare) but I have belief in the indexes of the mixins involved. I believe it could be due to the Resonance enchantment since the main listeners were related to sound. Whether it be a fault where an entity attempts to fire it which causes the sound to not see a player to play the sound at, or the book itself is ticking for whatever reason, I am not sure.

commented

That bug is the keybinding bug in ueUtils which is addressed with the next patch.

commented

Rough ETA can move into either direction: By next week there should be a release until everything goes wrong in my schedule which is like a 45% likelihood.