From f3fd09df80d65bd5e056e20264099990f684bbcf Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Mon, 22 Nov 2021 22:30:30 -0300 Subject: [PATCH] #679: Add getHideOnlinePlayers By: Doc --- paper-api/src/main/java/org/bukkit/Bukkit.java | 9 +++++++++ paper-api/src/main/java/org/bukkit/Server.java | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/paper-api/src/main/java/org/bukkit/Bukkit.java b/paper-api/src/main/java/org/bukkit/Bukkit.java index f78e6848f7..3b150b9623 100644 --- a/paper-api/src/main/java/org/bukkit/Bukkit.java +++ b/paper-api/src/main/java/org/bukkit/Bukkit.java @@ -912,6 +912,15 @@ public final class Bukkit { server.setSpawnRadius(value); } + /** + * Gets whether the Server hide online players in server status. + * + * @return true if the server hide online players, false otherwise + */ + public static boolean getHideOnlinePlayers() { + return server.getHideOnlinePlayers(); + } + /** * Gets whether the Server is in online mode or not. * diff --git a/paper-api/src/main/java/org/bukkit/Server.java b/paper-api/src/main/java/org/bukkit/Server.java index 1394f3bf38..7d2ba1f5e4 100644 --- a/paper-api/src/main/java/org/bukkit/Server.java +++ b/paper-api/src/main/java/org/bukkit/Server.java @@ -768,6 +768,13 @@ public interface Server extends PluginMessageRecipient { */ public void setSpawnRadius(int value); + /** + * Gets whether the Server hide online players in server status. + * + * @return true if the server hide online players, false otherwise + */ + public boolean getHideOnlinePlayers(); + /** * Gets whether the Server is in online mode or not. *