Files
Purpur/patches/server/0103-Fix-the-dead-lagging-the-server.patch
William Blake Galbreath 193b218210 Updated Upstream (Paper)
Upstream has released updates that appears to apply and compile correctly

Paper Changes:
979b53a7 Do not allow bee's to load chunks for beehives
13cb8373 Remote Connections shouldn't hold up shutdown
7dac5467 Fix bug in double register fix
87829d83 Remove incorrect IO flush for save-all that doesn't have flush parameter
31e751cb Fix unregistering entities from unloading chunks
bc351f6e Ensure Entity is never double registered
2ec0274b Fix many issues with dupe uuid resolve patch
756da10d (Actually) Don't duplicate velocity entry into hidden-configs
9b3679fb Don't duplicate velocity entry into hidden-configs
28cf6540 Pillager patrol spawn settings and per player options (#2924)
6bf04cd5 Reduce entity tracker updates on move
2020-03-31 19:27:23 -05:00

40 lines
1.9 KiB
Diff

From eb48b2cb416c8d84156a17ac3851fc09273d42d4 Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
Date: Fri, 6 Mar 2020 13:37:26 -0600
Subject: [PATCH] Fix the dead lagging the server
---
src/main/java/net/minecraft/server/Entity.java | 2 +-
src/main/java/net/minecraft/server/EntityLiving.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
index f5209ec92..ff0fd8c62 100644
--- a/src/main/java/net/minecraft/server/Entity.java
+++ b/src/main/java/net/minecraft/server/Entity.java
@@ -1348,7 +1348,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
this.pitch = MathHelper.a(f1, -90.0F, 90.0F) % 360.0F;
this.lastYaw = this.yaw;
this.lastPitch = this.pitch;
- world.getChunkAt((int) Math.floor(this.locX) >> 4, (int) Math.floor(this.locZ) >> 4); // CraftBukkit
+ if (!dead) world.getChunkAt((int) Math.floor(this.locX) >> 4, (int) Math.floor(this.locZ) >> 4); // CraftBukkit // Purpur
}
public void setPositionRotation(BlockPosition blockposition, float f, float f1) {
diff --git a/src/main/java/net/minecraft/server/EntityLiving.java b/src/main/java/net/minecraft/server/EntityLiving.java
index b4d1ab191..f3aef6d13 100644
--- a/src/main/java/net/minecraft/server/EntityLiving.java
+++ b/src/main/java/net/minecraft/server/EntityLiving.java
@@ -2385,7 +2385,7 @@ public abstract class EntityLiving extends Entity {
}
}
- if (!this.isTemporarilyActive) this.movementTick(); // Paper - don't move if only temporarily active
+ if (!dead && !this.isTemporarilyActive) this.movementTick(); // Paper - don't move if only temporarily active // Purpur
double d0 = this.locX() - this.lastX;
double d1 = this.locZ() - this.lastZ;
float f = (float) (d0 * d0 + d1 * d1);
--
2.24.0