From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Mark Vainomaa Date: Sun, 13 Dec 2020 05:32:05 +0200 Subject: [PATCH] Expose LivingEntity hurt direction diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java index a95825e88ba31c255292451532d18a23c8d502cb..bec679a287ac26b6413b9d0b90a6758b905ecde6 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java @@ -913,5 +913,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void playPickupItemAnimation(org.bukkit.entity.Item item, int quantity) { getHandle().take(((CraftItem) item).getHandle(), quantity); } + + @Override + public float getHurtDirection() { + return getHandle().hurtDir; + } + + @Override + public void setHurtDirection(float hurtDirection) { + getHandle().hurtDir = hurtDirection; + } // Paper end }