Fixed 'Island Respawn' not working for island members

It only worked for the island owner
This commit is contained in:
Florian CUNY 2019-08-29 14:18:14 +02:00
parent ff95450638
commit b6fa468b4a

View File

@ -36,7 +36,7 @@ public class IslandRespawnListener extends FlagListener {
if (!Flags.ISLAND_RESPAWN.isSetForWorld(e.getEntity().getWorld())) {
return; // world doesn't have the island respawn flag
}
if (!getIslands().hasIsland(e.getEntity().getWorld(), e.getEntity().getUniqueId())) {
if (!getIslands().hasIsland(e.getEntity().getWorld(), e.getEntity().getUniqueId()) || !getIslands().inTeam(e.getEntity().getWorld(), e.getEntity().getUniqueId())) {
return; // doesn't have an island in this world
}