Ender staff causing server crash
LemADEC opened this issue ยท 1 comments
As of Reliquary-1.12.2-1.3.4.796, the Ender staff can't be disabled.
Notably, setting ender_pearl_worth to 0 results in a server crash when player tries to consumes its fuel:
java.lang.ArithmeticException: / by zero
at xreliquary.items.util.FilteredItemStackHandler.worthToUnits(FilteredItemStackHandler.java:162)
at xreliquary.items.util.FilteredItemStackHandler.updateInputOutputSlots(FilteredItemStackHandler.java:243)
at xreliquary.items.util.FilteredItemStackHandler.setTotalAmount(FilteredItemStackHandler.java:72)
at xreliquary.items.ItemEnderStaff.setPearlCount(ItemEnderStaff.java:147)
at xreliquary.items.ItemEnderStaff.func_77663_a(ItemEnderStaff.java:134)
at net.minecraft.item.ItemStack.func_77945_a(ItemStack.java:526)
at net.minecraft.entity.player.InventoryPlayer.func_70429_k(InventoryPlayer.java:363)
at net.minecraft.entity.player.EntityPlayer.func_70636_d(EntityPlayer.java:511)
at net.minecraft.entity.EntityLivingBase.func_70071_h_(EntityLivingBase.java:2179)
at net.minecraft.entity.player.EntityPlayer.func_70071_h_(EntityPlayer.java:234)
at net.minecraft.entity.player.EntityPlayerMP.func_71127_g(EntityPlayerMP.java:382)
at net.minecraft.network.NetHandlerPlayServer.func_73660_a(NetHandlerPlayServer.java:173)
at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher$1.func_73660_a(NetworkDispatcher.java:209)
at net.minecraft.network.NetworkManager.func_74428_b(NetworkManager.java:285)
at net.minecraft.network.NetworkSystem.func_151269_c(NetworkSystem.java:180)
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:790)
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:668)
at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:252)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526)
at java.lang.Thread.run(Unknown Source)
that setting was never meant to be used to disable the staff. and actually allowing 0 there is the real bug. However given that this was only reported after such a long time of that code in place and that 1.12 is no longer supported apart from critical fixes I am going to close. This is fixed in 1.14+