From f777640e48a10ae8b5be5da3dfbcbda7774e69e6 Mon Sep 17 00:00:00 2001 From: md_5 Date: Wed, 11 Dec 2019 15:49:53 +1100 Subject: [PATCH] SPIGOT-5425: Prevent empty/air loot (again?) --- nms-patches/LootTable.patch | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 nms-patches/LootTable.patch diff --git a/nms-patches/LootTable.patch b/nms-patches/LootTable.patch new file mode 100644 index 0000000000..829b5482c4 --- /dev/null +++ b/nms-patches/LootTable.patch @@ -0,0 +1,10 @@ +--- a/net/minecraft/server/LootTable.java ++++ b/net/minecraft/server/LootTable.java +@@ -39,6 +39,7 @@ + public static Consumer a(Consumer consumer) { + return (itemstack) -> { + if (itemstack.getCount() < itemstack.getMaxStackSize()) { ++ if (itemstack.isEmpty()) return; // CraftBukkit + consumer.accept(itemstack); + } else { + int i = itemstack.getCount();