mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-23 09:27:45 +01:00
Report proxy onlinde mode to bstats as online (#3093)
This commit is contained in:
parent
6579ce0517
commit
57697cd515
@ -15,7 +15,7 @@ decisions on behalf of the project.
|
|||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/Metrics.java b/src/main/java/com/destroystokyo/paper/Metrics.java
|
diff --git a/src/main/java/com/destroystokyo/paper/Metrics.java b/src/main/java/com/destroystokyo/paper/Metrics.java
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 0000000000000000000000000000000000000000..e257d6b36e0e78dac5b8320017d92776171e1bb0
|
index 0000000000000000000000000000000000000000..f2a0a9f5d86820ce8098301256d2faf3d1a7c697
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/Metrics.java
|
+++ b/src/main/java/com/destroystokyo/paper/Metrics.java
|
||||||
@@ -0,0 +1,627 @@
|
@@ -0,0 +1,627 @@
|
||||||
@ -608,7 +608,7 @@ index 0000000000000000000000000000000000000000..e257d6b36e0e78dac5b8320017d92776
|
|||||||
+ }));
|
+ }));
|
||||||
+
|
+
|
||||||
+ metrics.addCustomChart(new Metrics.SingleLineChart("players", () -> Bukkit.getOnlinePlayers().size()));
|
+ metrics.addCustomChart(new Metrics.SingleLineChart("players", () -> Bukkit.getOnlinePlayers().size()));
|
||||||
+ metrics.addCustomChart(new Metrics.SimplePie("online_mode", () -> Bukkit.getOnlineMode() ? "online" : "offline"));
|
+ metrics.addCustomChart(new Metrics.SimplePie("online_mode", () -> Bukkit.getOnlineMode() || PaperConfig.isProxyOnlineMode() ? "online" : "offline"));
|
||||||
+ metrics.addCustomChart(new Metrics.SimplePie("paper_version", () -> (Metrics.class.getPackage().getImplementationVersion() != null) ? Metrics.class.getPackage().getImplementationVersion() : "unknown"));
|
+ metrics.addCustomChart(new Metrics.SimplePie("paper_version", () -> (Metrics.class.getPackage().getImplementationVersion() != null) ? Metrics.class.getPackage().getImplementationVersion() : "unknown"));
|
||||||
+
|
+
|
||||||
+ metrics.addCustomChart(new Metrics.DrilldownPie("java_version", () -> {
|
+ metrics.addCustomChart(new Metrics.DrilldownPie("java_version", () -> {
|
||||||
|
Loading…
Reference in New Issue
Block a user