ce270e1412
Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Bukkit Changes: b2f1908c SPIGOT-5783: Add helpful info to UnknownDependencyException e4f46260 SPIGOT-2623: Add EntityEquipment methods to get/set ItemStacks by slot. 529a9a69 SPIGOT-5751: Clarify behaviour of block drop-related API methods CraftBukkit Changes: 8ea9b138 Remove outdated build delay. ffc2b251 Revert "#675: Fix redirected CommandNodes sometimes not being properly redirected" cb701f6b #675: Fix redirected CommandNodes sometimes not being properly redirected c9d7c16b SPIGOT-2623: Add EntityEquipment methods to get/set ItemStacks by slot. fad2494a #673: Fix Craftworld#isChunkLoaded 8637ec00 SPIGOT-5751: Made breakNaturally and getDrops returns the correct item if no argument is given Spigot Changes: a99063f7 Rebuild patches Fixes #3602
37 lines
1.7 KiB
Diff
37 lines
1.7 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Nesaak <52047222+Nesaak@users.noreply.github.com>
|
|
Date: Sat, 23 May 2020 10:31:11 -0400
|
|
Subject: [PATCH] Expose Arrow getItemStack
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityArrow.java b/src/main/java/net/minecraft/server/EntityArrow.java
|
|
index 9c97edf9c9e9a8cdf029264f6b563090142c686b..e66f6b30069af5b9031c7c78a2bb3d3a645034c0 100644
|
|
--- a/src/main/java/net/minecraft/server/EntityArrow.java
|
|
+++ b/src/main/java/net/minecraft/server/EntityArrow.java
|
|
@@ -556,6 +556,8 @@ public abstract class EntityArrow extends Entity implements IProjectile {
|
|
}
|
|
}
|
|
|
|
+ public ItemStack getOriginalItemStack() { return getItemStack(); } // Paper - OBFHelper
|
|
+
|
|
protected abstract ItemStack getItemStack();
|
|
|
|
@Override
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java
|
|
index 29d23db4121bf8cbd98b4d7acce90b13790df245..2e4765ba14c591f995f6ab0a6e3a16158c7ca308 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java
|
|
@@ -102,6 +102,13 @@ public class CraftArrow extends AbstractProjectile implements AbstractArrow {
|
|
getHandle().fromPlayer = EntityArrow.PickupStatus.a(status.ordinal());
|
|
}
|
|
|
|
+ // Paper start
|
|
+ @Override
|
|
+ public org.bukkit.craftbukkit.inventory.CraftItemStack getItemStack() {
|
|
+ return org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(getHandle().getOriginalItemStack());
|
|
+ }
|
|
+ //Paper end
|
|
+
|
|
@Override
|
|
public void setTicksLived(int value) {
|
|
super.setTicksLived(value);
|