Fix null position async errors
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -39,6 +39,9 @@ public class LocationCheckRunnable implements Runnable
|
|||||||
if(player != null) playersToCheck.remove(player);
|
if(player != null) playersToCheck.remove(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!Cache.playerIslands.containsKey(player.getName()))
|
||||||
|
return; //it means the player just joined and still didn't get an island (reminder that this is async)
|
||||||
|
|
||||||
Location playerLocation = player.getLocation();
|
Location playerLocation = player.getLocation();
|
||||||
|
|
||||||
Coordinates playerIslandCoordinates = Cache.playerIslands.get(player.getName());
|
Coordinates playerIslandCoordinates = Cache.playerIslands.get(player.getName());
|
||||||
|
Reference in New Issue
Block a user