Merge pull request #38 from Psithief/fake-player

Attempt to fix fake-players being invincible through superperms.
This commit is contained in:
Igor Yamolov 2012-08-21 09:56:16 -07:00
commit 3cc9b64d3f

View File

@ -52,7 +52,7 @@ public class EntityListener extends ModifyworldListener {
if (edbe.getEntity() instanceof Player) {
player = (Player) edbe.getEntity();
if (edbe.getDamager() != null) { // Prevent from taking damage by entity
if (edbe.getDamager() != null && player.isOnline()) { // Prevent from taking damage by entity
if (_permissionDenied(player, "modifyworld.damage.take", edbe.getDamager())) {
cancelDamageEvent(player, event);
}