From 57a9fc68367d7265a016bb4fa207a5c3a28f1048 Mon Sep 17 00:00:00 2001 From: Jeroen <48769316+iTwins@users.noreply.github.com> Date: Tue, 26 Sep 2023 12:26:33 +0200 Subject: [PATCH] fix breaking sf block with not unlocked item duping contents (#3976) --- .../implementation/listeners/BlockListener.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/listeners/BlockListener.java b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/listeners/BlockListener.java index 30593427e..f5cd29811 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/listeners/BlockListener.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/listeners/BlockListener.java @@ -141,16 +141,16 @@ public class BlockListener implements Listener { } } + List drops = new ArrayList<>(); + + if (!item.getType().isAir()) { + int fortune = getBonusDropsWithFortune(item, e.getBlock()); + callToolHandler(e, item, fortune, drops); + } + if (!e.isCancelled()) { checkForSensitiveBlockAbove(e.getPlayer(), e.getBlock(), item); - int fortune = getBonusDropsWithFortune(item, e.getBlock()); - List drops = new ArrayList<>(); - - if (!item.getType().isAir()) { - callToolHandler(e, item, fortune, drops); - } - callBlockHandler(e, item, drops, sfItem); dropItems(e, drops); }