1.5.0 Release Canidate 4.2b
This commit is contained in:
parent
23401507e4
commit
15dedc90a4
1 changed files with 4 additions and 3 deletions
|
@ -61,12 +61,13 @@ public class DamageHandler implements Listener {
|
|||
event.setCancelled(true);
|
||||
return;
|
||||
}
|
||||
// If there is no attacker, it must of been by natural causes. If pvp is disabled, and config doesn't allow natural causes, cancel event.
|
||||
} else if (!pvpEnabled && !allowNaturalCauses && board.contains(player)) {
|
||||
// If there is no attacker, it most of been by natural causes. If pvp is disabled, and config doesn't allow natural causes, cancel event.
|
||||
// Also, if there was no attacker, if the damaged is not a player, ignore them.
|
||||
} else if (!board.contains(player) || !pvpEnabled && !allowNaturalCauses && board.contains(player)) {
|
||||
event.setCancelled(true);
|
||||
return;
|
||||
}
|
||||
// Spectators cannot take damage
|
||||
// Spectators and cannot take damage
|
||||
if (board.isSpectator(player)) {
|
||||
event.setCancelled(true);
|
||||
if (Main.getInstance().supports(18) && player.getLocation().getBlockY() < -64) {
|
||||
|
|
Loading…
Reference in a new issue