testserver/Spigot-Server-Patches/0060-Add-methods-for-workin...

31 lines
996 B
Diff
Raw Normal View History

From 6b7551898b105a68759159e515f0f388a65cb9a5 Mon Sep 17 00:00:00 2001
From: mrapple <tony@oc.tc>
Date: Sun, 25 Nov 2012 13:43:39 -0600
Subject: [PATCH] Add methods for working with arrows stuck in living entities
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index 2ef1433a7..7e3a9eeb2 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -508,4 +508,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
public boolean isCollidable() {
return getHandle().collides;
}
+
+ // Paper start
+ @Override
+ public int getArrowsStuck() {
2017-05-14 18:05:01 +00:00
+ return getHandle().getArrowCount();
+ }
+
+ @Override
+ public void setArrowsStuck(int arrows) {
2017-05-14 18:05:01 +00:00
+ getHandle().setArrowCount(arrows);
+ }
+ // Paper end
}
--
2.18.0