From e4f56d693a4c6cebb43006bfa507444d614072ca Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal002@users.noreply.github.com> Date: Tue, 3 Sep 2024 09:34:00 +0200 Subject: Fix: Pity Counter (#2436) Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com> --- src/main/java/at/hannibal2/skyhanni/data/MiningAPI.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/main/java/at/hannibal2') diff --git a/src/main/java/at/hannibal2/skyhanni/data/MiningAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/MiningAPI.kt index e97d25c52..ecf90172d 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/MiningAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/MiningAPI.kt @@ -164,7 +164,8 @@ object MiningAPI { @SubscribeEvent fun onBlockChange(event: ServerBlockChangeEvent) { if (!inCustomMiningIsland()) return - if (event.newState.block != Blocks.air) return + if (event.newState.block.let { it != Blocks.air && it != Blocks.bedrock }) return + if (event.oldState.block.let { it == Blocks.air || it == Blocks.bedrock }) return if (event.oldState.block == Blocks.air) return val pos = event.location if (pos.distanceToPlayer() > 7) return -- cgit