I hate NPCs. Fixes #244

This commit is contained in:
h31ix committed 2013-06-23 20:10:39 -04:00
1 parent 61dcbd5569
commit 1bdfa90ae9
1 file changed
+2
@@ -38,12 +38,14 @@ public class EventListener implements Listener {
public static void log(String message, Player player, CheckType type) { public static void log(String message, Player player, CheckType type) {
User user = getUserManager().getUser(player.getName()); User user = getUserManager().getUser(player.getName());
if(user != null) { // npc
logCheat(type, user); logCheat(type, user);
if (user.increaseLevel(type) && message != null) { if (user.increaseLevel(type) && message != null) {
Anticheat.getManager().log(message); Anticheat.getManager().log(message);
} }
removeDecrease(user); removeDecrease(user);
} }
}
private static void logCheat(CheckType type, User user) { private static void logCheat(CheckType type, User user) {
USAGE_LIST.put(type, getCheats(type) + 1); USAGE_LIST.put(type, getCheats(type) + 1);