Make sure the target is online.

This ensures that the McMMOPlayer object *should* be valid.
This commit is contained in:
GJ 2013-04-18 22:17:52 -04:00
parent 8099490213
commit 4b36a11dda

View File

@ -452,7 +452,7 @@ public final class CombatUtils {
Player defender = (Player) target;
if (System.currentTimeMillis() >= UserManager.getPlayer(defender).getRespawnATS() + 5) {
if (defender.isOnline() && System.currentTimeMillis() >= UserManager.getPlayer(defender).getRespawnATS() + 5) {
baseXP = 20 * Config.getInstance().getPlayerVersusPlayerXP();
}
}