diff options
author | Jake Potrebic <[email protected]> | 2021-12-22 10:02:31 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2021-12-22 10:02:31 -0800 |
commit | 82eaf4ee15d77303cdd352cce9b33c2f3e5d14d7 (patch) | |
tree | 53e4a42978675fc17acc76b85dcb0c3569ab3e3b /patches/server/0377-Prevent-teleporting-dead-entities.patch | |
parent | 6e5ceb34eb2ef4d6c0a35c46d0eded9099bb2fee (diff) | |
download | Paper-82eaf4ee15d77303cdd352cce9b33c2f3e5d14d7.tar.gz Paper-82eaf4ee15d77303cdd352cce9b33c2f3e5d14d7.zip |
Fix duplicated BlockPistonRetractEvent call (#7111)
Diffstat (limited to 'patches/server/0377-Prevent-teleporting-dead-entities.patch')
-rw-r--r-- | patches/server/0377-Prevent-teleporting-dead-entities.patch | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/patches/server/0377-Prevent-teleporting-dead-entities.patch b/patches/server/0377-Prevent-teleporting-dead-entities.patch new file mode 100644 index 0000000000..f55c8fa69e --- /dev/null +++ b/patches/server/0377-Prevent-teleporting-dead-entities.patch @@ -0,0 +1,21 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Shane Freeder <[email protected]> +Date: Tue, 3 Mar 2020 05:26:40 +0000 +Subject: [PATCH] Prevent teleporting dead entities + + +diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +index a0aa9be6ee16109c68c2c75b2a150982f2ab3d62..52448f75d093a4880ce619036af00c8a1772ad80 100644 +--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java ++++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +@@ -1495,6 +1495,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser + } + + private void internalTeleport(double d0, double d1, double d2, float f, float f1, Set<ClientboundPlayerPositionPacket.RelativeArgument> set, boolean flag) { ++ if (player.isRemoved()) { ++ LOGGER.info("Attempt to teleport removed player {} restricted", player.getScoreboardName()); ++ return; ++ } + // CraftBukkit start + if (Float.isNaN(f)) { + f = 0; |