mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2025-02-13 10:51:20 +01:00
Fixes a bug that prevented mobs to attack
Commit 85b52f4b
introduced a bug that prevented entities to target any island member. This should fix it.
This commit is contained in:
parent
d984955af3
commit
e41f5ac24f
@ -171,7 +171,7 @@ public class InvincibleVisitorsListener extends FlagListener implements ClickHan
|
||||
if (!(e.getTarget() instanceof Player p) ||
|
||||
!this.getIWM().inWorld(world) ||
|
||||
e.getTarget().hasMetadata("NPC") ||
|
||||
this.getIslands().userIsOnIsland(world, User.getInstance(e.getEntity())) ||
|
||||
this.getIslands().userIsOnIsland(world, User.getInstance(e.getTarget())) ||
|
||||
this.PVPAllowed(p.getLocation()) ||
|
||||
e.getReason() == EntityTargetEvent.TargetReason.TARGET_DIED ||
|
||||
!this.getIWM().getIvSettings(world).contains(DamageCause.ENTITY_ATTACK.name()))
|
||||
|
Loading…
Reference in New Issue
Block a user