2020-05-22 19:56:24 +02:00
|
|
|
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 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityArrow.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityArrow.java
|
2020-06-26 03:58:00 +02:00
|
|
|
@@ -0,0 +0,0 @@ public abstract class EntityArrow extends IProjectile {
|
2020-05-22 19:56:24 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
+ 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 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftArrow.java
|
|
|
|
@@ -0,0 +0,0 @@ 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);
|