Skip to content

Commit

Permalink
Protect armor stands from all non-Player entities, not just living ones.
Browse files Browse the repository at this point in the history
Fixes WORLDGUARD-3796.
  • Loading branch information
wizjany committed Jan 26, 2017
1 parent 1c29e85 commit 85693b9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ private void onEntityDamageByEntity(EntityDamageByEntityEvent event) {
event.setCancelled(true);
return;
}
} else if (defender.getType() == Entities.armorStandType && Entities.isNonPlayerCreature(attacker)) {
} else if (defender.getType() == Entities.armorStandType && !(attacker instanceof Player)) {
if (wcfg.blockEntityArmorStandDestroy) {
event.setCancelled(true);
return;
Expand Down

0 comments on commit 85693b9

Please sign in to comment.