work and compile errors
This commit is contained in:
parent
7b29d1f4c5
commit
78a003ee89
93 changed files with 305 additions and 295 deletions
22
patches/server/0356-Expose-MinecraftServer-isRunning.patch
Normal file
22
patches/server/0356-Expose-MinecraftServer-isRunning.patch
Normal file
|
@ -0,0 +1,22 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: JRoy <joshroy126@gmail.com>
|
||||
Date: Fri, 10 Apr 2020 21:24:12 -0400
|
||||
Subject: [PATCH] Expose MinecraftServer#isRunning
|
||||
|
||||
This allows for plugins to detect if the server is actually turning off in onDisable rather than just plugins reloading.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 7ac0cdf96740887b97616290b27eb63665294546..712bee34303ca3ceec4520e265f4defdc27ea8ff 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -2764,5 +2764,10 @@ public final class CraftServer implements Server {
|
||||
public int getCurrentTick() {
|
||||
return net.minecraft.server.MinecraftServer.currentTick;
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public boolean isStopping() {
|
||||
+ return net.minecraft.server.MinecraftServer.getServer().hasStopped();
|
||||
+ }
|
||||
// Paper end
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue