-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
24 additions
and
0 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
patches/server/0050-Fix-tpsbar-visible-exclude-issue.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 | ||
From: wangxyper <[email protected]> | ||
Date: Sat, 9 Sep 2023 21:58:26 +0800 | ||
Subject: [PATCH] Fix tpsbar visible exclude issue | ||
|
||
|
||
diff --git a/src/main/java/me/earthme/molia/functions/GlobalServerTpsBar.java b/src/main/java/me/earthme/molia/functions/GlobalServerTpsBar.java | ||
index 71a264fa7c16946ffb8dbac0273c4a05c8827700..5c852426ef251a77396a9921ac2c2e2b3ff91ea0 100644 | ||
--- a/src/main/java/me/earthme/molia/functions/GlobalServerTpsBar.java | ||
+++ b/src/main/java/me/earthme/molia/functions/GlobalServerTpsBar.java | ||
@@ -105,7 +105,12 @@ public class GlobalServerTpsBar { | ||
|
||
private static void updateBarVisibilityForPlayers(){ | ||
for (Player player : Bukkit.getOnlinePlayers()){ | ||
- if (player instanceof Bot || visibleExclude.contains(player)){ | ||
+ if (player instanceof Bot){ | ||
+ continue; | ||
+ } | ||
+ | ||
+ if (visibleExclude.contains(player)){ | ||
+ addedPlayers.remove(player); | ||
continue; | ||
} | ||
|