Skip to content

Commit

Permalink
Фиксы и тд
Browse files Browse the repository at this point in the history
  • Loading branch information
NazrinNya committed Sep 18, 2023
1 parent add2df8 commit a472a56
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
6 changes: 6 additions & 0 deletions src/main/java/plugin/Plugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ public void init() {
kickIfBanned(event.player);
Document user = getDoc(plr.uuid());
String joinMessage = user.getString("joinmessage");
if (joinMessage == null){
joinMessage = "@ [white]joined";
}
if (joinMessage.endsWith(" ")){
joinMessage = joinMessage.substring(0, joinMessage.length()-1);
}
Expand Down Expand Up @@ -108,6 +111,9 @@ public void init() {
});
Events.on(EventType.PlayerLeave.class, event -> {
historyPlayers.remove(event.player.uuid());
Player plr = event.player;
Document user = getDoc(plr.uuid());
Call.sendMessage(plr.name() + "[white] left " + "[grey][" + user.getInteger("id") + "]");
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/plugin/commands/MainCommands.java
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ public void run() {
}
player.sendMessage(list.toString());
} else {
player.sendMessage("лох ебаный");
player.sendMessage("[red]Invalid type!");
}
});
}
Expand Down
2 changes: 0 additions & 2 deletions src/main/java/plugin/commands/history/History.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ public static void loadHistory(){
event.player.sendMessage(list.toString());
});*/
Events.run(EventType.Trigger.update, () -> {
Threads.daemon(() -> {
for (Player plr : Groups.player){
if (historyPlayers.contains(plr.uuid())) {
Tile Eventtile = world.tileWorld(plr.mouseX, plr.mouseY);
Expand All @@ -89,7 +88,6 @@ public static void loadHistory(){
}
}
}
});
});
Events.on(EventType.GameOverEvent.class, event -> {
historyTilesSeq.clear();
Expand Down

0 comments on commit a472a56

Please sign in to comment.