mirror of
https://github.com/PaperMC/Paper.git
synced 2026-11-25 10:29:41 -05:00
Made the movement speed check more reliable on high load servers.
This commit is contained in:
1 parent
98633a9f16
commit
0faaf5af8a
2 files changed
+9
-2
No files matched your search
@@ -55,6 +55,7 @@ public class MinecraftServer implements Runnable, ICommandListener {
|
||||
public OptionSet options;
|
||||
public ColouredConsoleSender console;
|
||||
public ConsoleReader reader;
|
||||
public static int currentTick;
|
||||
// Craftbukkit end
|
||||
|
||||
public MinecraftServer(OptionSet options) { // CraftBukkit - adds argument OptionSet
|
||||
@@ -281,6 +282,7 @@ public class MinecraftServer implements Runnable, ICommandListener {
|
||||
j = 0L;
|
||||
} else {
|
||||
while (j > 50L) {
|
||||
MinecraftServer.currentTick = (int) (System.currentTimeMillis() / 50); // CraftBukkit
|
||||
j -= 50L;
|
||||
this.h();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user