From 7d56f38ed0e3816a9dba7f8a65c843bc669128b9 Mon Sep 17 00:00:00 2001 From: Shane Freeder Date: Thu, 4 Mar 2021 01:39:18 +0000 Subject: [PATCH] Do not use the bukkit singleton for the GUI (Fixes #5301) --- Spigot-Server-Patches/0684-Improve-ServerGUI.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Spigot-Server-Patches/0684-Improve-ServerGUI.patch b/Spigot-Server-Patches/0684-Improve-ServerGUI.patch index 33a54cd4d5..cec607827c 100644 --- a/Spigot-Server-Patches/0684-Improve-ServerGUI.patch +++ b/Spigot-Server-Patches/0684-Improve-ServerGUI.patch @@ -7,7 +7,7 @@ Subject: [PATCH] Improve ServerGUI - Show tps in the server stats diff --git a/src/main/java/com/destroystokyo/paper/gui/RAMDetails.java b/src/main/java/com/destroystokyo/paper/gui/RAMDetails.java -index e463a86a6ad6c4f2885f4df159411bad294e1208..93291d856b7ad4fae72b6b53149677904960d732 100644 +index e463a86a6ad6c4f2885f4df159411bad294e1208..d21d081ef3e3eee1d14ce3dfdd8c810cc8382b80 100644 --- a/src/main/java/com/destroystokyo/paper/gui/RAMDetails.java +++ b/src/main/java/com/destroystokyo/paper/gui/RAMDetails.java @@ -58,9 +58,18 @@ public class RAMDetails extends JList { @@ -15,7 +15,7 @@ index e463a86a6ad6c4f2885f4df159411bad294e1208..93291d856b7ad4fae72b6b5314967790 GraphData data = RAMGraph.DATA.peekLast(); Vector vector = new Vector<>(); + -+ double[] tps = Bukkit.getTPS(); ++ double[] tps = new double[] {server.tps1.getAverage(), server.tps5.getAverage(), server.tps15.getAverage()}; + String[] tpsAvg = new String[tps.length]; + + for ( int g = 0; g < tps.length; g++) {