2020-05-06 09:48:49 +00:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2016-12-27 16:03:37 +00:00
|
|
|
From: Alfie Cleveland <alfeh@me.com>
|
|
|
|
Date: Tue, 27 Dec 2016 01:57:57 +0000
|
|
|
|
Subject: [PATCH] Properly fix item duplication bug
|
|
|
|
|
|
|
|
Credit to prplz for figuring out the real issue
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
|
2021-01-29 00:32:08 +00:00
|
|
|
index c2f3b2f72e7f025a69b89e8a52e23160c33a6cc8..ba64eb5e8e048a0bb70187efb0cdec17525a3d4a 100644
|
2016-12-27 16:03:37 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
|
2021-01-29 00:32:08 +00:00
|
|
|
@@ -1931,7 +1931,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
|
2016-12-27 16:03:37 +00:00
|
|
|
|
|
|
|
@Override
|
|
|
|
protected boolean isFrozen() {
|
|
|
|
- return super.isFrozen() || !getBukkitEntity().isOnline();
|
|
|
|
+ return super.isFrozen() || (this.playerConnection != null && this.playerConnection.isDisconnected()); // Paper
|
|
|
|
}
|
|
|
|
|
2017-08-05 03:10:30 +00:00
|
|
|
@Override
|
2016-12-27 16:03:37 +00:00
|
|
|
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
2020-11-04 08:57:07 +00:00
|
|
|
index 372b47e539b9d696f5e0dfe8255b503daaa480df..bb99e1ed16deba5b39323c5a65bf68986ff816fe 100644
|
2016-12-27 16:03:37 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
2020-11-04 08:57:07 +00:00
|
|
|
@@ -2660,7 +2660,7 @@ public class PlayerConnection implements PacketListenerPlayIn {
|
2018-07-17 20:32:05 +00:00
|
|
|
}
|
2016-12-27 16:03:37 +00:00
|
|
|
|
|
|
|
public final boolean isDisconnected() {
|
|
|
|
- return !this.player.joining && !this.networkManager.isConnected();
|
|
|
|
+ return (!this.player.joining && !this.networkManager.isConnected()) || this.processedDisconnect; // Paper
|
|
|
|
}
|
2018-07-17 20:32:05 +00:00
|
|
|
// CraftBukkit end
|
2019-04-27 06:26:04 +00:00
|
|
|
|