fix paperclip bug

This commit is contained in:
Ben
2023-03-18 16:35:47 -04:00
parent d383dbb262
commit 56f5adf79a
19 changed files with 74 additions and 108 deletions

View File

@@ -69,7 +69,7 @@ index d2f0a0755317f5fa9a1ccf7db346aa77fd287d80..03852e7d21d9470a4469676367463fef
} catch (Exception exception) {
if (listener.shouldPropagateHandlingExceptions()) {
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb198ed012 100644
index f077b51d0b9a1e5f2fe6583aa7318eb0435d7e69..305934c4c2d88b87cee2ae3e956dedbca4bdc7fe 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -1405,15 +1405,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -112,40 +112,7 @@ index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb
}
private ServerStatus buildServerStatus() {
@@ -1503,25 +1503,25 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
}
public void tickChildren(BooleanSupplier shouldKeepTicking) {
- MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper
+ //MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper // Purpur
this.server.getScheduler().mainThreadHeartbeat(this.tickCount); // CraftBukkit
- MinecraftTimings.bukkitSchedulerTimer.stopTiming(); // Spigot // Paper
+ //MinecraftTimings.bukkitSchedulerTimer.stopTiming(); // Spigot // Paper // Purpur
this.profiler.push("commandFunctions");
- MinecraftTimings.commandFunctionsTimer.startTiming(); // Spigot // Paper
+ //MinecraftTimings.commandFunctionsTimer.startTiming(); // Spigot // Paper // Purpur
this.getFunctions().tick();
- MinecraftTimings.commandFunctionsTimer.stopTiming(); // Spigot // Paper
+ //MinecraftTimings.commandFunctionsTimer.stopTiming(); // Spigot // Paper // Purpur
this.profiler.popPush("levels");
//Iterator iterator = this.getAllLevels().iterator(); // Paper - moved down
// CraftBukkit start
// Run tasks that are waiting on processing
- MinecraftTimings.processQueueTimer.startTiming(); // Spigot
+ //MinecraftTimings.processQueueTimer.startTiming(); // Spigot // Purpur
while (!this.processQueue.isEmpty()) {
this.processQueue.remove().run();
}
- MinecraftTimings.processQueueTimer.stopTiming(); // Spigot
+ //MinecraftTimings.processQueueTimer.stopTiming(); // Spigot // Purpur
- MinecraftTimings.timeUpdateTimer.startTiming(); // Spigot // Paper
+ //MinecraftTimings.timeUpdateTimer.startTiming(); // Spigot // Paper // Purpur
// Send time updates to everyone, it will get the right time from the world the player is in.
// Paper start - optimize time updates
for (final ServerLevel world : this.getAllLevels()) {
@@ -1541,7 +1541,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1542,7 +1542,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
}
}
// Paper end
@@ -154,7 +121,7 @@ index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb
this.isIteratingOverLevels = true; // Paper
Iterator iterator = this.getAllLevels().iterator(); // Paper - move down
@@ -1565,14 +1565,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1567,14 +1567,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.profiler.push("tick");
try {
@@ -171,7 +138,7 @@ index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb
} catch (Throwable throwable) {
// Spigot Start
CrashReport crashreport;
@@ -1595,24 +1595,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1597,24 +1597,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.isIteratingOverLevels = false; // Paper
this.profiler.popPush("connection");
@@ -202,7 +169,7 @@ index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb
this.profiler.pop();
}
@@ -2797,7 +2797,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -2799,7 +2799,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
return;
}
@@ -211,7 +178,7 @@ index 5f8c60dbfbe5842475a6af19f44c1c89ee58cfff..bfd601a91f370915a6f422f9b486d8eb
try {
for (;;) {
boolean moreTasks = this.tickMidTickTasks();
@@ -2824,7 +2824,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -2826,7 +2826,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
}
}
} finally {
@@ -641,7 +608,7 @@ index 2d61a0c7dfeb868403d64abbf847121f60905f93..752a298e96e75580ec7eef14cc7eab96
} else if (close) { chunkproviderserver.close(false); } // Paper - rewrite chunk system
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index a66f5b8438d499c705cc4025ba31f72bd1fea3cf..2c5e15cb38c51bafe0fa773cc419543e57cb5926 100644
index 0373d0d050f89e3754d6c94946501227db0c19df..82fcf0593b4739e32d02ffc779f9fbb5f64d26f1 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2570,7 +2570,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic