Fix respawn task console errors

This commit is contained in:
Daniel Saukel 2016-05-15 18:49:20 +02:00
parent e8dfdd961a
commit 62781f9f88

View File

@ -38,9 +38,11 @@ public class RespawnTask extends BukkitRunnable {
@Override
public void run() {
if (player.getWorld() == location.getWorld()) {
if (player.getLocation().distance(location) > 2) {
PlayerUtil.secureTeleport(player, location);
}
}
DGlobalPlayer dPlayer = DungeonsXL.getInstance().getDPlayers().getByPlayer(player);