public void updateCache() { for (Player player : getServer().getOnlinePlayers()) try { getCache(player) .setLastTownBlock( new WorldCoord( getTownyUniverse().getWorld(player.getWorld().getName()), Coord.parseCoord(player))); } catch (NotRegisteredException e) { deleteCache(player); } }
public void updateCache(WorldCoord worldCoord) { for (Player player : getServer().getOnlinePlayers()) if (Coord.parseCoord(player).equals(worldCoord)) getCache(player).setLastTownBlock(worldCoord); // Automatically resets permissions. }
public void loadSettings() { townyUniverse.loadSettings(); Coord.setCellSize(TownySettings.getTownBlockSize()); TownyIConomyObject.setPlugin(this); TownyCommand.setUniverse(townyUniverse); }