mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-28 13:15:30 +01:00
Hidden players stored in lowercase.
This commit is contained in:
parent
631f06d091
commit
ab6352a17d
@ -53,12 +53,12 @@ public class PlayerList {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void hide(String playerName) {
|
public void hide(String playerName) {
|
||||||
hiddenPlayerNames.add(playerName);
|
hiddenPlayerNames.add(playerName.toLowerCase());
|
||||||
save();
|
save();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void show(String playerName) {
|
public void show(String playerName) {
|
||||||
hiddenPlayerNames.remove(playerName);
|
hiddenPlayerNames.remove(playerName.toLowerCase());
|
||||||
save();
|
save();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -75,7 +75,7 @@ public class PlayerList {
|
|||||||
Player[] onlinePlayers = server.getOnlinePlayers();
|
Player[] onlinePlayers = server.getOnlinePlayers();
|
||||||
for (int i = 0; i < onlinePlayers.length; i++) {
|
for (int i = 0; i < onlinePlayers.length; i++) {
|
||||||
Player p = onlinePlayers[i];
|
Player p = onlinePlayers[i];
|
||||||
if (p.getWorld().getName().equals(worldName) && !hiddenPlayerNames.contains(p.getName())) {
|
if (p.getWorld().getName().equals(worldName) && !hiddenPlayerNames.contains(p.getName().toLowerCase())) {
|
||||||
visiblePlayers.add(p);
|
visiblePlayers.add(p);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -89,7 +89,7 @@ public class PlayerList {
|
|||||||
Player[] onlinePlayers = server.getOnlinePlayers();
|
Player[] onlinePlayers = server.getOnlinePlayers();
|
||||||
for (int i = 0; i < onlinePlayers.length; i++) {
|
for (int i = 0; i < onlinePlayers.length; i++) {
|
||||||
Player p = onlinePlayers[i];
|
Player p = onlinePlayers[i];
|
||||||
if (!hiddenPlayerNames.contains(p.getName())) {
|
if (!hiddenPlayerNames.contains(p.getName().toLowerCase())) {
|
||||||
visiblePlayers.add(p);
|
visiblePlayers.add(p);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user