From 8e03fb8f433972ad1f6bc55b9e9e6b56ff0fbdcc Mon Sep 17 00:00:00 2001 From: direwolf20 <39863894+Direwolf20-MC@users.noreply.github.com> Date: Thu, 5 Dec 2024 15:48:52 -0500 Subject: [PATCH] Add a fluid check to Block Breakers - resolves #286 --- .../justdirethings/common/blockentities/BlockBreakerT1BE.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/com/direwolf20/justdirethings/common/blockentities/BlockBreakerT1BE.java b/src/main/java/com/direwolf20/justdirethings/common/blockentities/BlockBreakerT1BE.java index 317d9450..50dbde7c 100644 --- a/src/main/java/com/direwolf20/justdirethings/common/blockentities/BlockBreakerT1BE.java +++ b/src/main/java/com/direwolf20/justdirethings/common/blockentities/BlockBreakerT1BE.java @@ -18,6 +18,7 @@ import net.minecraft.world.item.enchantment.Enchantment; import net.minecraft.world.item.enchantment.Enchantments; import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.LiquidBlock; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.entity.BlockEntityType; import net.minecraft.world.level.block.state.BlockState; @@ -131,6 +132,8 @@ public boolean isBlockValid(FakePlayer fakePlayer, BlockPos blockPos) { BlockState blockState = level.getBlockState(blockPos); if (blockState.isAir()) return false; + if ((blockState.getBlock() instanceof LiquidBlock)) //No Liquids + return false; if (blockPos.equals(getBlockPos())) return false; if (blockBreakingTracker.containsKey(blockPos))