diff options
author | Jason Penilla <[email protected]> | 2024-04-27 13:27:01 -0700 |
---|---|---|
committer | Jason Penilla <[email protected]> | 2024-04-27 13:27:01 -0700 |
commit | e2552eea2481871c9d8445a3c5653a2329112648 (patch) | |
tree | 727c90f395576b66200f8d9e59f38859f3850562 /patches/server/0690-Fix-Entity-Position-Desync.patch | |
parent | 0b1b1fe067444c5e879313e017da0ffd5d6b826d (diff) | |
download | Paper-e2552eea2481871c9d8445a3c5653a2329112648.tar.gz Paper-e2552eea2481871c9d8445a3c5653a2329112648.zip |
Start cleaning up plugin remapping patches
Diffstat (limited to 'patches/server/0690-Fix-Entity-Position-Desync.patch')
-rw-r--r-- | patches/server/0690-Fix-Entity-Position-Desync.patch | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/patches/server/0690-Fix-Entity-Position-Desync.patch b/patches/server/0690-Fix-Entity-Position-Desync.patch new file mode 100644 index 0000000000..fb9d587df1 --- /dev/null +++ b/patches/server/0690-Fix-Entity-Position-Desync.patch @@ -0,0 +1,23 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Owen1212055 <[email protected]> +Date: Thu, 23 Dec 2021 23:59:12 -0500 +Subject: [PATCH] Fix Entity Position Desync + +If entities were teleported in the first tick it would not be send to the client. + +This excludes hanging entities, as this fix caused problematic behavior due to them having their own +position field. + +diff --git a/src/main/java/net/minecraft/server/level/ServerEntity.java b/src/main/java/net/minecraft/server/level/ServerEntity.java +index 19a7d0ab2ee5494149dfb0503b7c69784b7bee8b..f355dd986bf861da3edb90d7e05f901e19686fef 100644 +--- a/src/main/java/net/minecraft/server/level/ServerEntity.java ++++ b/src/main/java/net/minecraft/server/level/ServerEntity.java +@@ -171,7 +171,7 @@ public class ServerEntity { + boolean flag4 = false; + boolean flag5 = false; + +- if (this.tickCount > 0 || this.entity instanceof AbstractArrow) { ++ if (!(this.entity instanceof net.minecraft.world.entity.decoration.HangingEntity) || this.tickCount > 0 || this.entity instanceof AbstractArrow) { // Paper - Always update position to fix first-tick teleports + long k = this.positionCodec.encodeX(vec3d); + long l = this.positionCodec.encodeY(vec3d); + long i1 = this.positionCodec.encodeZ(vec3d); |