[1.18.2] Crash upon killing mobs with no affinity using Forbidden Sword runescribing
FoxMcloud5655 opened this issue ยท 2 comments
I runescribed my existing sword with the Forbidden Sword runescribe recipe. Upon killing another modded entity that had no affinity (a mana burst from Mythic Botany's Alf Shatterer), the server crashes immediately with the following relevant part of the crash report:
java.lang.NullPointerException: Cannot invoke "com.verdantartifice.primalmagick.common.sources.SourceList.isEmpty()" because "affinities" is null
at com.verdantartifice.primalmagick.common.events.CombatEvents.onDeath(CombatEvents.java:201) ~[primalmagick-2.1.2.jar%23235!/:2.1.2] {re:classloading}
at net.minecraftforge.eventbus.ASMEventHandler_853_CombatEvents_onDeath_LivingDeathEvent.invoke(.dynamic) ~[?:?] {}
at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:85) ~[eventbus-5.0.3.jar%232!/:?] {}
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:302) ~[eventbus-5.0.3.jar%232!/:?] {}
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) ~[eventbus-5.0.3.jar%232!/:?] {}
at net.minecraftforge.common.ForgeHooks.onLivingDeath(ForgeHooks.java:335) ~[forge-1.18.2-40.1.80-universal.jar%23308!/:?] {re:classloading}
at net.minecraft.world.entity.LivingEntity.m_6667_(LivingEntity.java:1254) ~[server-1.18.2-20220404.173914-srg.jar%23303!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:maxhealthfix.common.mixins.json:MixinLivingEntity,pl:mixin:APP:immersive_armors.mixin.json:MixinLivingEntity,pl:mixin:APP:mixins.shetiphiancore.json:SPC_ThinBlockHandler$_LivingEntity,pl:mixin:APP:supplementaries.mixins.json:LivingEntityMixin,pl:mixin:APP:botania_xplat.mixins.json:AccessorLivingEntity,pl:mixin:APP:curios.mixins.json:MixinLivingEntity,pl:mixin:APP:pehkui.mixins.json:LivingEntityMixin,pl:mixin:APP:pehkui.mixins.json:compat116plus.LivingEntityMixin,pl:mixin:APP:pehkui.mixins.json:compat117plus.LivingEntityMixin,pl:mixin:APP:caelus.mixins.json:MixinLivingEntity,pl:mixin:APP:curioofundying.mixins.json:LivingEntityMixin,pl:mixin:APP:werewolves.mixins.json:LivingEntityAccessor,pl:mixin:APP:personality.mixins.json:LivingEntityMixin,pl:mixin:APP:mna.mixins.json:LivingEntityFireWalkerMixin,pl:mixin:APP:vampirism.mixins.json:LivingEntityAccessor,pl:mixin:APP:vampirism.mixins.json:MixinLivingEntity,pl:mixin:APP:druidcraftrg.mixins.json:LivingEntityMixin,pl:mixin:APP:blue_skies.mixins.json:LivingEntityMixin,pl:mixin:APP:netherportalfix.mixins.json:LivingEntityAccessor,pl:mixin:APP:citadel.mixins.json:LivingEntityMixin,pl:mixin:APP:bookshelf.common.mixins.json:entity.AccessorLivingEntity,pl:mixin:APP:beyond_earth.mixin.json:LivingEntityTickEnd,pl:mixin:APP:betterdeserttemples.mixins.json:PharaohKilledMixin,pl:mixin:APP:quark.mixins.json:accessor.AccessorLivingEntity,pl:mixin:APP:malum.mixins.json:LivingEntityMixin,pl:mixin:APP:enhancedcelestials.mixins.json:MixinLivingEntity,pl:mixin:APP:lodestone.mixins.json:LivingEntityMixin,pl:mixin:APP:expandability.mixins.json:swimming.LivingEntityMixin,pl:mixin:APP:chiselsandbits.mixins.json:platform.common.LivingEntityEquipmentSlotMixin,pl:mixin:APP:create.mixins.json:CustomItemUseEffectsMixin,pl:mixin:APP:create.mixins.json:accessor.LivingEntityAccessor,pl:mixin:APP:pehkui.mixins.json:compat115plus.LivingEntityMixin,pl:mixin:A}
at net.minecraft.world.entity.raid.Raider.m_6667_(Raider.java:178) ~[server-1.18.2-20220404.173914-srg.jar%23303!/:?] {re:mixin,re:classloading,pl:mixin:APP:savage_and_ravage.mixins.json:RaiderMixin,pl:mixin:APP:savage_and_ravage.mixins.json:RaiderAccessor,pl:mixin:A}
at net.minecraft.world.entity.LivingEntity.m_6469_(LivingEntity.java:1131) ~[server-1.18.2-20220404.173914-srg.jar%23303!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:maxhealthfix.common.mixins.json:MixinLivingEntity,pl:mixin:APP:immersive_armors.mixin.json:MixinLivingEntity,pl:mixin:APP:mixins.shetiphiancore.json:SPC_ThinBlockHandler$_LivingEntity,pl:mixin:APP:supplementaries.mixins.json:LivingEntityMixin,pl:mixin:APP:botania_xplat.mixins.json:AccessorLivingEntity,pl:mixin:APP:curios.mixins.json:MixinLivingEntity,pl:mixin:APP:pehkui.mixins.json:LivingEntityMixin,pl:mixin:APP:pehkui.mixins.json:compat116plus.LivingEntityMixin,pl:mixin:APP:pehkui.mixins.json:compat117plus.LivingEntityMixin,pl:mixin:APP:caelus.mixins.json:MixinLivingEntity,pl:mixin:APP:curioofundying.mixins.json:LivingEntityMixin,pl:mixin:APP:werewolves.mixins.json:LivingEntityAccessor,pl:mixin:APP:personality.mixins.json:LivingEntityMixin,pl:mixin:APP:mna.mixins.json:LivingEntityFireWalkerMixin,pl:mixin:APP:vampirism.mixins.json:LivingEntityAccessor,pl:mixin:APP:vampirism.mixins.json:MixinLivingEntity,pl:mixin:APP:druidcraftrg.mixins.json:LivingEntityMixin,pl:mixin:APP:blue_skies.mixins.json:LivingEntityMixin,pl:mixin:APP:netherportalfix.mixins.json:LivingEntityAccessor,pl:mixin:APP:citadel.mixins.json:LivingEntityMixin,pl:mixin:APP:bookshelf.common.mixins.json:entity.AccessorLivingEntity,pl:mixin:APP:beyond_earth.mixin.json:LivingEntityTickEnd,pl:mixin:APP:betterdeserttemples.mixins.json:PharaohKilledMixin,pl:mixin:APP:quark.mixins.json:accessor.AccessorLivingEntity,pl:mixin:APP:malum.mixins.json:LivingEntityMixin,pl:mixin:APP:enhancedcelestials.mixins.json:MixinLivingEntity,pl:mixin:APP:lodestone.mixins.json:LivingEntityMixin,pl:mixin:APP:expandability.mixins.json:swimming.LivingEntityMixin,pl:mixin:APP:chiselsandbits.mixins.json:platform.common.LivingEntityEquipmentSlotMixin,pl:mixin:APP:create.mixins.json:CustomItemUseEffectsMixin,pl:mixin:APP:create.mixins.json:accessor.LivingEntityAccessor,pl:mixin:APP:pehkui.mixins.json:compat115plus.LivingEntityMixin,pl:mixin:A}
at net.minecraft.world.entity.raid.Raider.m_6469_(Raider.java:295) ~[server-1.18.2-20220404.173914-srg.jar%23303!/:?] {re:mixin,re:classloading,pl:mixin:APP:savage_and_ravage.mixins.json:RaiderMixin,pl:mixin:APP:savage_and_ravage.mixins.json:RaiderAccessor,pl:mixin:A}
at mythicbotany.alftools.AlfsteelSword.updateBurst(AlfsteelSword.java:137) ~[MythicBotany-1.18.2-2.1.13.jar%23208!/:1.18.2-2.1.13] {re:classloading}
at vazkii.botania.common.entity.EntityManaBurst.m_8119_(EntityManaBurst.java:172) ~[Botania-1.18.2-435.jar%2372!/:1.18.2-435] {re:mixin,re:classloading}
Should be a very simple fix by checking if the affinities is null before using its' methods.
Thank you for the bug report! This issue has actually already been fixed in v3.2.0 of Primal Magick, for Minecraft 1.19.2. Please file a new ticket if you encounter the issue again in the current version.