From 649f20ca9310b101ae58f1b6f05ad8c2f94bb17b Mon Sep 17 00:00:00 2001 From: Noah van der Aa Date: Sat, 14 Dec 2024 15:51:03 +0100 Subject: [PATCH] net.minecraft.util.thread --- .../minecraft/util/thread/BlockableEventLoop.java.patch | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) rename paper-server/patches/{unapplied => sources}/net/minecraft/util/thread/BlockableEventLoop.java.patch (82%) diff --git a/paper-server/patches/unapplied/net/minecraft/util/thread/BlockableEventLoop.java.patch b/paper-server/patches/sources/net/minecraft/util/thread/BlockableEventLoop.java.patch similarity index 82% rename from paper-server/patches/unapplied/net/minecraft/util/thread/BlockableEventLoop.java.patch rename to paper-server/patches/sources/net/minecraft/util/thread/BlockableEventLoop.java.patch index 9692da77b5..186d682197 100644 --- a/paper-server/patches/unapplied/net/minecraft/util/thread/BlockableEventLoop.java.patch +++ b/paper-server/patches/sources/net/minecraft/util/thread/BlockableEventLoop.java.patch @@ -1,9 +1,9 @@ --- a/net/minecraft/util/thread/BlockableEventLoop.java +++ b/net/minecraft/util/thread/BlockableEventLoop.java -@@ -82,6 +82,13 @@ - runnable.run(); +@@ -83,6 +_,14 @@ } } + + // Paper start + public void scheduleOnMain(Runnable runnable) { + // postToMainThread does not work the same as older versions of mc @@ -11,6 +11,7 @@ + this.schedule(this.wrapRunnable(runnable)); + } + // Paper end - ++ @Override - public void schedule(R runnable) { + public void schedule(R task) { + this.pendingRunnables.add(task);