mirror of
https://github.com/taoneill/war.git
synced 2024-11-14 14:25:27 +01:00
Don't notify the command sender twice if he's in the lobby or on a team while resetting zone.
This commit is contained in:
parent
31a2deef0f
commit
d4d5778175
@ -81,8 +81,9 @@ public class PartialZoneResetJob extends BukkitRunnable implements Cloneable {
|
|||||||
private void sendMessageToAllWarzonePlayers(String message) {
|
private void sendMessageToAllWarzonePlayers(String message) {
|
||||||
for (Player player : War.war.getServer().getOnlinePlayers()) {
|
for (Player player : War.war.getServer().getOnlinePlayers()) {
|
||||||
ZoneLobby lobby = ZoneLobby.getLobbyByLocation(player);
|
ZoneLobby lobby = ZoneLobby.getLobbyByLocation(player);
|
||||||
if (zone.getPlayers().contains(player)
|
if (player != PartialZoneResetJob.senderToNotify
|
||||||
|| (lobby != null && lobby.getZone() == zone)) {
|
&& (zone.getPlayers().contains(player)
|
||||||
|
|| (lobby != null && lobby.getZone() == zone))) {
|
||||||
War.war.msg(player, message);
|
War.war.msg(player, message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user