Fixed rare NPEs

This commit is contained in:
xGamingDudex 2016-10-22 13:09:56 +02:00
parent 720e965d08
commit 295f1f255f
2 changed files with 6 additions and 1 deletions

View File

@ -118,6 +118,11 @@ public class KitPig extends SmashKit
return;
}
if(Manager.GetGame() == null)
{
return;
}
for (Player player : Manager.GetGame().GetPlayers(true))
{
if (!HasKit(player))

View File

@ -168,7 +168,7 @@ public class PerkWitherImage extends SmashPerk
}
}
if (_skeletons.get(event.getTarget().getUniqueId()).equals(event.getEntity()))
if (event.getTarget() != null && _skeletons.get(event.getTarget().getUniqueId()).equals(event.getEntity()))
{
event.setCancelled(true);
}