Because it's not just Citizens that uses NPCs.

This commit is contained in:
gmcferrin
2013-01-10 12:18:48 -05:00
parent ec6b9d4387
commit bcfec56300
6 changed files with 12 additions and 12 deletions

View File

@ -336,7 +336,7 @@ public class Combat {
for (Entity entity : target.getNearbyEntities(2.5, 2.5, 2.5)) {
if (entity instanceof Player) {
if (Misc.isCitizensNPC((Player) entity)) {
if (Misc.isNPC((Player) entity)) {
continue;
}
}

View File

@ -27,7 +27,7 @@ public class Misc {
public static final int TIME_CONVERSION_FACTOR = 1000;
public static final double SKILL_MESSAGE_MAX_SENDING_DISTANCE = 10.0;
public static boolean isCitizensNPC(Player player) {
public static boolean isNPC(Player player) {
if (player == null || Users.getProfile(player) == null || player.hasMetadata("NPC")) {
return true;
}