From b34ae4fb3c01bce93f82f5d2095e1394722262e6 Mon Sep 17 00:00:00 2001 From: Warrior <50800980+Warriorrrr@users.noreply.github.com> Date: Wed, 8 Jan 2025 21:46:58 +0100 Subject: [PATCH] Fix wolves ignoring result of damage event (#11932) --- .../sources/net/minecraft/world/entity/animal/Wolf.java.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paper-server/patches/sources/net/minecraft/world/entity/animal/Wolf.java.patch b/paper-server/patches/sources/net/minecraft/world/entity/animal/Wolf.java.patch index 6bcb88fa1..6df46dcff 100644 --- a/paper-server/patches/sources/net/minecraft/world/entity/animal/Wolf.java.patch +++ b/paper-server/patches/sources/net/minecraft/world/entity/animal/Wolf.java.patch @@ -19,7 +19,7 @@ + public boolean actuallyHurt(ServerLevel level, DamageSource damageSource, float amount, org.bukkit.event.entity.EntityDamageEvent event) { // CraftBukkit - void -> boolean if (!this.canArmorAbsorb(damageSource)) { - super.actuallyHurt(level, damageSource, amount); -+ super.actuallyHurt(level, damageSource, amount, event); // CraftBukkit ++ return super.actuallyHurt(level, damageSource, amount, event); // CraftBukkit } else { + if (event.isCancelled()) return false; // CraftBukkit - SPIGOT-7815: if the damage was cancelled, no need to run the wolf armor behaviour ItemStack bodyArmorItem = this.getBodyArmorItem();