remove the thing
This commit is contained in:
parent
21739e2f1e
commit
3da8695b2f
1 changed files with 5 additions and 6 deletions
|
@ -18,8 +18,6 @@ public class PlayersPlugin extends SessionAdapter {
|
||||||
private final Bot bot;
|
private final Bot bot;
|
||||||
@Getter private List<MutablePlayerListEntry> list = new ArrayList<>();
|
@Getter private List<MutablePlayerListEntry> list = new ArrayList<>();
|
||||||
|
|
||||||
private final Map<MutablePlayerListEntry, String> loginNames = new HashMap<>();
|
|
||||||
|
|
||||||
private final List<PlayerListener> listeners = new ArrayList<>();
|
private final List<PlayerListener> listeners = new ArrayList<>();
|
||||||
|
|
||||||
public PlayersPlugin (Bot bot) {
|
public PlayersPlugin (Bot bot) {
|
||||||
|
@ -86,10 +84,10 @@ public class PlayersPlugin extends SessionAdapter {
|
||||||
final MutablePlayerListEntry target = new MutablePlayerListEntry(newEntry);
|
final MutablePlayerListEntry target = new MutablePlayerListEntry(newEntry);
|
||||||
|
|
||||||
list.add(target);
|
list.add(target);
|
||||||
loginNames.put(target, target.profile().getIdAsString());
|
// loginNames.put(target, target.profile().getIdAsString());
|
||||||
|
|
||||||
if (duplicate == null) for (PlayerListener listener : listeners) { listener.playerJoined(target); }
|
if (duplicate == null) for (PlayerListener listener : listeners) { listener.playerJoined(target); }
|
||||||
else {
|
/* else {
|
||||||
for (Map.Entry<MutablePlayerListEntry, String> entry : loginNames.entrySet()) {
|
for (Map.Entry<MutablePlayerListEntry, String> entry : loginNames.entrySet()) {
|
||||||
if (
|
if (
|
||||||
!entry.getValue().equals(newEntry.getProfile().getIdAsString()) ||
|
!entry.getValue().equals(newEntry.getProfile().getIdAsString()) ||
|
||||||
|
@ -102,8 +100,9 @@ public class PlayersPlugin extends SessionAdapter {
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
for (PlayerListener listener : listeners) { listener.playerUnVanished(target); }
|
*/
|
||||||
}
|
else for (PlayerListener listener : listeners) { listener.playerUnVanished(target); }
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateGamemode (PlayerListEntry newEntry) {
|
private void updateGamemode (PlayerListEntry newEntry) {
|
||||||
|
|
Loading…
Reference in a new issue