2021-06-11 14:02:28 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
|
|
|
Date: Sat, 20 Apr 2019 19:47:29 -0500
|
|
|
|
Subject: [PATCH] Expose the internal current tick
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java
|
2023-09-21 21:54:46 +02:00
|
|
|
index cb0ad65e4e30c3604d655bb75c7b26a7bf4227d7..6ae9a923d85f76bf5e6a41fb0a499196be05473e 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/org/bukkit/Bukkit.java
|
|
|
|
+++ b/src/main/java/org/bukkit/Bukkit.java
|
2023-07-04 10:22:56 +02:00
|
|
|
@@ -2363,6 +2363,10 @@ public final class Bukkit {
|
2022-04-22 20:54:08 +02:00
|
|
|
public static com.destroystokyo.paper.profile.PlayerProfile createProfileExact(@Nullable UUID uuid, @Nullable String name) {
|
|
|
|
return server.createProfileExact(uuid, name);
|
2021-06-11 14:02:28 +02:00
|
|
|
}
|
|
|
|
+
|
|
|
|
+ public static int getCurrentTick() {
|
|
|
|
+ return server.getCurrentTick();
|
|
|
|
+ }
|
|
|
|
// Paper end
|
|
|
|
|
|
|
|
@NotNull
|
|
|
|
diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java
|
2023-09-21 21:54:46 +02:00
|
|
|
index 49877944a385b22e5de66b4e33056ee3f592fcd7..86e89976618a7083d3cd5b81669c99788bc72d05 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/org/bukkit/Server.java
|
|
|
|
+++ b/src/main/java/org/bukkit/Server.java
|
2023-07-04 10:22:56 +02:00
|
|
|
@@ -2056,5 +2056,12 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi
|
2021-06-11 14:02:28 +02:00
|
|
|
*/
|
|
|
|
@NotNull
|
2022-04-22 20:54:08 +02:00
|
|
|
com.destroystokyo.paper.profile.PlayerProfile createProfileExact(@Nullable UUID uuid, @Nullable String name);
|
2021-06-11 14:02:28 +02:00
|
|
|
+
|
|
|
|
+ /**
|
|
|
|
+ * Get the current internal server tick
|
|
|
|
+ *
|
|
|
|
+ * @return Current tick
|
|
|
|
+ */
|
|
|
|
+ int getCurrentTick();
|
|
|
|
// Paper end
|
|
|
|
}
|