From 48294447ad78d94f3a2d2811247f879abe5e98ef Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Mon, 28 Dec 2020 08:58:51 +1100 Subject: [PATCH] SPIGOT-6273: Expose ItemFrame ItemDropChance through API By: md_5 --- .../java/org/bukkit/entity/ItemFrame.java | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/paper-api/src/main/java/org/bukkit/entity/ItemFrame.java b/paper-api/src/main/java/org/bukkit/entity/ItemFrame.java index e34d40875..1568bd662 100644 --- a/paper-api/src/main/java/org/bukkit/entity/ItemFrame.java +++ b/paper-api/src/main/java/org/bukkit/entity/ItemFrame.java @@ -33,6 +33,31 @@ public interface ItemFrame extends Hanging { */ public void setItem(@Nullable ItemStack item, boolean playSound); + /** + * Gets the chance of the item being dropped upon this frame's destruction. + * + * + * + * @return chance of the off hand item being dropped + */ + float getItemDropChance(); + + /** + * Sets the chance of the off hand item being dropped upon this frame's + * destruction. + * + * + * + * @param chance the chance of off hand item being dropped + */ + void setItemDropChance(float chance); + /** * Get the rotation of the frame's item *