Skip to content

Commit

Permalink
Fix: NPE in CorpseLocator (#2268)
Browse files Browse the repository at this point in the history
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
  • Loading branch information
hannibal002 and hannibal002 authored Jul 30, 2024
1 parent 14adb67 commit bacc6a3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ object CorpseLocator {
entity.showArms && entity.hasNoBasePlate() && !entity.isInvisible
}
.forEach { entity ->
val helmetName = entity.getCurrentArmor(3).getInternalName()
val helmetName = entity.getCurrentArmor(3)?.getInternalName() ?: return
val corpseType = MineshaftWaypointType.getByHelmetOrNull(helmetName) ?: return

val canSee = entity.getLorenzVec().canBeSeen(-1..3)
Expand Down

0 comments on commit bacc6a3

Please sign in to comment.