mirror of
https://github.com/DRE2N/DungeonsXL.git
synced 2024-11-24 19:45:43 +01:00
Fixed that end signs didn't work when the player quit the server while being in a dungeon before; resolves #594
This commit is contained in:
parent
2641fb7e5c
commit
0684e3b34a
@ -200,7 +200,7 @@ public class DGroup {
|
||||
*/
|
||||
public Set<DGlobalPlayer> getDGlobalPlayers() {
|
||||
Set<DGlobalPlayer> players = new HashSet<>();
|
||||
for (UUID uuid : this.players.getUniqueIds()) {
|
||||
for (UUID uuid : this.players) {
|
||||
players.add(dPlayers.getByUniqueId(uuid));
|
||||
}
|
||||
return players;
|
||||
@ -211,7 +211,7 @@ public class DGroup {
|
||||
*/
|
||||
public Set<DGamePlayer> getDGamePlayers() {
|
||||
Set<DGamePlayer> players = new HashSet<>();
|
||||
for (UUID uuid : this.players.getUniqueIds()) {
|
||||
for (UUID uuid : this.players) {
|
||||
DGlobalPlayer dPlayer = dPlayers.getByUniqueId(uuid);
|
||||
if (dPlayer instanceof DGamePlayer) {
|
||||
players.add((DGamePlayer) dPlayer);
|
||||
|
@ -420,7 +420,6 @@ public class DPlayerListener implements Listener {
|
||||
Game game = Game.getByWorld(player.getWorld());
|
||||
|
||||
if (!(dPlayer instanceof DInstancePlayer)) {
|
||||
dPlayers.removePlayer(dPlayer);
|
||||
if (dGroup != null) {
|
||||
dGroup.removePlayer(player);
|
||||
}
|
||||
@ -442,6 +441,8 @@ public class DPlayerListener implements Listener {
|
||||
} else if (dPlayer instanceof DEditPlayer) {
|
||||
((DEditPlayer) dPlayer).leave();
|
||||
}
|
||||
|
||||
dPlayers.removePlayer(dPlayer);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
Loading…
Reference in New Issue
Block a user