@Override public void onPlayerRespawn(PlayerRespawnEvent event) { // Try to re-spawn at town. ChunkyResident chunkyResident = new ChunkyResident(event.getPlayer()); ChunkyTown chunkyTown = chunkyResident.getTown(); if (chunkyTown == null) return; chunkyResident.subtractPlayTime(Config.Options.DEATH_TOLL.getInt()); event.setRespawnLocation(chunkyTown.getHome().getCoord().toLocation()); }