2020-05-06 09:48:49 +00:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2016-03-09 04:21:08 +00:00
|
|
|
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
|
2020-09-02 09:12:25 +00:00
|
|
|
index c635a5ca8961b9b6d742251e339dd46bd08b6ef0..283c65af3dedef650cf956db9aa5b582e2b6e6c3 100644
|
2016-03-09 04:21:08 +00:00
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
2020-09-02 09:12:25 +00:00
|
|
|
@@ -678,4 +678,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
2020-08-27 13:37:37 +00:00
|
|
|
|
|
|
|
throw new UnsupportedOperationException("Unsupported monster type: " + type + ". This is a bug, report this to Spigot.");
|
2016-03-09 04:21:08 +00:00
|
|
|
}
|
|
|
|
+
|
|
|
|
+ // Paper start
|
|
|
|
+ @Override
|
|
|
|
+ public int getArrowsStuck() {
|
2017-05-14 18:05:01 +00:00
|
|
|
+ return getHandle().getArrowCount();
|
2016-03-09 04:21:08 +00:00
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public void setArrowsStuck(int arrows) {
|
2017-05-14 18:05:01 +00:00
|
|
|
+ getHandle().setArrowCount(arrows);
|
2016-03-09 04:21:08 +00:00
|
|
|
+ }
|
|
|
|
+ // Paper end
|
|
|
|
}
|