Files
Purpur/patches/server/0121-Arrows-should-not-reset-despawn-counter.patch
BillyGalbreath f5c3dae3d5 Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly

Paper Changes:
aeb6e7dd2 Updated Upstream (Bukkit/CraftBukkit/Spigot) (#5601)
b0a4f353b fix cancelling block falling causing client desync (fixes #5386) (#5419)
2021-05-09 18:14:49 -05:00

22 lines
1.2 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
Date: Wed, 4 Nov 2020 13:12:50 -0600
Subject: [PATCH] Arrows should not reset despawn counter
This prevents keeping arrows alive indefinitely (such as when the block
the arrow is stuck in gets removed, like a piston head going up/down)
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java b/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
index 5775a28cb9d94b94b6e6bbc810fe31260810632e..7861b9e28b0fcc7ab931498fc7c96404456b9998 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
@@ -281,7 +281,7 @@ public abstract class EntityArrow extends IProjectile {
Vec3D vec3d = this.getMot();
this.setMot(vec3d.d((double) (this.random.nextFloat() * 0.2F), (double) (this.random.nextFloat() * 0.2F), (double) (this.random.nextFloat() * 0.2F)));
- this.despawnCounter = 0;
+ // this.despawnCounter = 0; // Purpur - do not reset despawn counter
}
@Override