mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-01 04:32:11 -07:00
Fix MCUtils and other calls to postTaskOnMain
Method changed changed it's role to providing a TickTask object which isn't automatically scheduled onto the server
This commit is contained in:
@@ -22,7 +22,7 @@ index a79cba50e..e5e41c662 100644
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index e7d3a5479..6096f309b 100644
|
||||
index 530457772..630a0271e 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -0,0 +0,0 @@ import java.util.Iterator;
|
||||
@@ -68,7 +68,7 @@ index e7d3a5479..6096f309b 100644
|
||||
+
|
||||
+ if (byteTotal > byteAllowed) {
|
||||
+ PlayerConnection.LOGGER.warn(this.player.getName() + " tried to send too large of a book. Book Size: " + byteTotal + " - Allowed: "+ byteAllowed + " - Pages: " + pageList.size());
|
||||
+ minecraftServer.postToMainThread(() -> this.disconnect("Book too large!"));
|
||||
+ minecraftServer.scheduleOnMain(() -> this.disconnect("Book too large!"));
|
||||
+ return;
|
||||
+ }
|
||||
+ }
|
||||
|
Reference in New Issue
Block a user