diff --git a/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch b/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch new file mode 100644 index 0000000000..c571e45b5e --- /dev/null +++ b/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch @@ -0,0 +1,11 @@ +--- a/net/minecraft/world/entity/ai/behavior/warden/Digging.java ++++ b/net/minecraft/world/entity/ai/behavior/warden/Digging.java +@@ -39,7 +_,7 @@ + @Override + protected void stop(ServerLevel level, E entity, long gameTime) { + if (entity.getRemovalReason() == null) { +- entity.remove(Entity.RemovalReason.DISCARDED); ++ entity.remove(Entity.RemovalReason.DISCARDED, org.bukkit.event.entity.EntityRemoveEvent.Cause.DESPAWN); // CraftBukkit - Add bukkit remove cause + } + } + } diff --git a/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch b/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch new file mode 100644 index 0000000000..4289534ef3 --- /dev/null +++ b/paper-server/patches/sources/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch @@ -0,0 +1,11 @@ +--- a/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java ++++ b/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java +@@ -83,7 +_,7 @@ + if (livingEntity.hurtServer(level, level.damageSources().sonicBoom(owner), 10.0F)) { + double d = 0.5 * (1.0 - livingEntity.getAttributeValue(Attributes.KNOCKBACK_RESISTANCE)); + double d1 = 2.5 * (1.0 - livingEntity.getAttributeValue(Attributes.KNOCKBACK_RESISTANCE)); +- livingEntity.push(vec32.x() * d1, vec32.y() * d, vec32.z() * d1); ++ livingEntity.push(vec32.x() * d1, vec32.y() * d, vec32.z() * d1, owner); // Paper - Add EntityKnockbackByEntityEvent and EntityPushedByEntityAttackEvent + } + }); + } diff --git a/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch b/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch deleted file mode 100644 index 6f3b4a357c..0000000000 --- a/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/Digging.java.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/net/minecraft/world/entity/ai/behavior/warden/Digging.java -+++ b/net/minecraft/world/entity/ai/behavior/warden/Digging.java -@@ -10,6 +10,10 @@ - import net.minecraft.world.entity.ai.memory.MemoryStatus; - import net.minecraft.world.entity.monster.warden.Warden; - -+// CraftBukkit start - imports -+import org.bukkit.event.entity.EntityRemoveEvent; -+// CraftBukkit end -+ - public class Digging extends Behavior { - - public Digging(int duration) { -@@ -37,7 +41,7 @@ - - protected void stop(ServerLevel worldserver, E e0, long i) { - if (e0.getRemovalReason() == null) { -- e0.remove(Entity.RemovalReason.DISCARDED); -+ e0.remove(Entity.RemovalReason.DISCARDED, EntityRemoveEvent.Cause.DESPAWN); // CraftBukkit - Add bukkit remove cause - } - - } diff --git a/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch b/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch deleted file mode 100644 index 4fbd06f256..0000000000 --- a/paper-server/patches/unapplied/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java -+++ b/net/minecraft/world/entity/ai/behavior/warden/SonicBoom.java -@@ -83,7 +83,7 @@ - if (target.hurtServer(world, world.damageSources().sonicBoom(entity), 10.0F)) { - double d = 0.5 * (1.0 - target.getAttributeValue(Attributes.KNOCKBACK_RESISTANCE)); - double e = 2.5 * (1.0 - target.getAttributeValue(Attributes.KNOCKBACK_RESISTANCE)); -- target.push(vec33.x() * e, vec33.y() * d, vec33.z() * e); -+ target.push(vec33.x() * e, vec33.y() * d, vec33.z() * e, entity); // Paper - Add EntityKnockbackByEntityEvent and EntityPushedByEntityAttackEvent - } - }); - }