From 96574bed6fbafb7c940a2a3f3af523bc5b016445 Mon Sep 17 00:00:00 2001 From: TheBusyBiscuit Date: Fri, 18 Jun 2021 15:09:03 +0200 Subject: [PATCH] Fixes #3116 --- CHANGELOG.md | 1 + .../implementation/items/tools/SmeltersPickaxe.java | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3dd0b35e8..0ebcf22aa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -50,6 +50,7 @@ #### Fixes * Fixed #3105 +* Fixed #3116 ## Release Candidate 24 (03 Jun 2021) https://thebusybiscuit.github.io/builds/TheBusyBiscuit/Slimefun4/stable/#24 diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/tools/SmeltersPickaxe.java b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/tools/SmeltersPickaxe.java index cd3ea1999..b0e8077b6 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/tools/SmeltersPickaxe.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/tools/SmeltersPickaxe.java @@ -39,10 +39,10 @@ public class SmeltersPickaxe extends SimpleSlimefunItem implemen Block b = e.getBlock(); if (SlimefunTag.SMELTERS_PICKAXE_BLOCKS.isTagged(b.getType()) && !BlockStorage.hasBlockInfo(b)) { - Collection blockDrops = b.getDrops(getItem()); + Collection blockDrops = b.getDrops(tool); for (ItemStack drop : blockDrops) { - if (drop != null && drop.getType() != Material.AIR) { + if (drop != null && !drop.getType().isAir()) { smelt(b, drop, fortune); drops.add(drop); } @@ -60,8 +60,10 @@ public class SmeltersPickaxe extends SimpleSlimefunItem implemen if (furnaceOutput.isPresent()) { b.getWorld().playEffect(b.getLocation(), Effect.MOBSPAWNER_FLAMES, 1); drop.setType(furnaceOutput.get().getType()); - drop.setAmount(fortune); } + + // Fixes #3116 + drop.setAmount(fortune); } @Override