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-06-13 01:51:45 +02:00
|
|
|
index ef7445fc5c169e64a73dce4f71a2885fb976caf3..d39c6b5d3fef5fe9727868175cf266fd68c2efa4 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-06-13 01:51:45 +02:00
|
|
|
@@ -2336,6 +2336,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-06-13 01:51:45 +02:00
|
|
|
index 5edef1114f1c94e921656972141d62a9d6338105..e02bd7323e117e9977275b3a5d3e070ff891fdbd 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-06-13 01:51:45 +02:00
|
|
|
@@ -2033,5 +2033,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
|
|
|
|
}
|