mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-21 18:37:42 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@efd47e3 Updated Upstream (Bukkit/CraftBukkit/Spigot) (#9188) PaperMC/Paper@1edfefd Add option to flush region files on save (#9149) PaperMC/Paper@9daa019 Added wither vanilla invulnerability API (#9124)
This commit is contained in:
@@ -5,10 +5,10 @@ Subject: [PATCH] Alternative Keepalive Handling
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
index ae5f4ae4a82545a776bbff52ce98e91a4a8f5d9e..7335b3e0f7f3549e0c262ab3438f6dab9e393b82 100644
|
||||
index db737258db16ec9f61d0d601a6ea5f6b14638033..f7b3110cf30124fc4054bfcda6d5ad28a5c0a48c 100644
|
||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
@@ -262,6 +262,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
@@ -263,6 +263,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
private long keepAliveTime = Util.getMillis();
|
||||
private boolean keepAlivePending;
|
||||
private long keepAliveChallenge;
|
||||
@@ -16,7 +16,7 @@ index ae5f4ae4a82545a776bbff52ce98e91a4a8f5d9e..7335b3e0f7f3549e0c262ab3438f6dab
|
||||
// CraftBukkit start - multithreaded fields
|
||||
private final AtomicInteger chatSpamTickCount = new AtomicInteger();
|
||||
private final java.util.concurrent.atomic.AtomicInteger tabSpamLimiter = new java.util.concurrent.atomic.AtomicInteger(); // Paper - configurable tab spam limits
|
||||
@@ -414,6 +415,21 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
@@ -415,6 +416,21 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
long currentTime = Util.getMillis();
|
||||
long elapsedTime = currentTime - this.keepAliveTime;
|
||||
|
||||
@@ -38,7 +38,7 @@ index ae5f4ae4a82545a776bbff52ce98e91a4a8f5d9e..7335b3e0f7f3549e0c262ab3438f6dab
|
||||
if (this.keepAlivePending) {
|
||||
if (!this.processedDisconnect && elapsedTime >= KEEPALIVE_LIMIT) { // check keepalive limit, don't fire if already disconnected
|
||||
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked due to keepalive timeout!", this.player.getScoreboardName()); // more info
|
||||
@@ -3521,6 +3537,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
@@ -3527,6 +3543,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||
|
||||
@Override
|
||||
public void handleKeepAlive(ServerboundKeepAlivePacket packet) {
|
||||
|
||||
Reference in New Issue
Block a user