diff --git a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/BlockBreak.java b/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/BlockBreak.java index 332960b6..13ef8377 100644 --- a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/BlockBreak.java +++ b/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/BlockBreak.java @@ -11,7 +11,7 @@ public final class BlockBreak implements BlockBreakProxy { @Override public void breakBlock(@NotNull final Player player, @NotNull final Block block) { - if (block.getY() > 255) { + if (block.getY() > 255 || block.getY() < 0) { return; } ((CraftPlayer) player).getHandle().playerInteractManager.breakBlock(new BlockPosition(block.getX(), block.getY(), block.getZ())); diff --git a/eco-core/core-nms/v1_16_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R1/BlockBreak.java b/eco-core/core-nms/v1_16_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R1/BlockBreak.java index 49c263f7..ffeb9b36 100644 --- a/eco-core/core-nms/v1_16_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R1/BlockBreak.java +++ b/eco-core/core-nms/v1_16_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R1/BlockBreak.java @@ -11,7 +11,7 @@ public final class BlockBreak implements BlockBreakProxy { @Override public void breakBlock(@NotNull final Player player, @NotNull final Block block) { - if (block.getY() > 255) { + if (block.getY() > 255 || block.getY() < 0) { return; } ((CraftPlayer) player).getHandle().playerInteractManager.breakBlock(new BlockPosition(block.getX(), block.getY(), block.getZ())); diff --git a/eco-core/core-nms/v1_16_R2/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R2/BlockBreak.java b/eco-core/core-nms/v1_16_R2/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R2/BlockBreak.java index 3f821271..8467e11c 100644 --- a/eco-core/core-nms/v1_16_R2/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R2/BlockBreak.java +++ b/eco-core/core-nms/v1_16_R2/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R2/BlockBreak.java @@ -11,7 +11,7 @@ public final class BlockBreak implements BlockBreakProxy { @Override public void breakBlock(@NotNull final Player player, @NotNull final Block block) { - if (block.getY() > 255) { + if (block.getY() > 255 || block.getY() < 0) { return; } ((CraftPlayer) player).getHandle().playerInteractManager.breakBlock(new BlockPosition(block.getX(), block.getY(), block.getZ())); diff --git a/eco-core/core-nms/v1_16_R3/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R3/BlockBreak.java b/eco-core/core-nms/v1_16_R3/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R3/BlockBreak.java index bae25c6c..26824b09 100644 --- a/eco-core/core-nms/v1_16_R3/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R3/BlockBreak.java +++ b/eco-core/core-nms/v1_16_R3/src/main/java/com/willfp/ecoenchants/proxy/v1_16_R3/BlockBreak.java @@ -11,7 +11,7 @@ public final class BlockBreak implements BlockBreakProxy { @Override public void breakBlock(@NotNull final Player player, @NotNull final Block block) { - if (block.getY() > 255) { + if (block.getY() > 255 || block.getY() < 0) { return; } ((CraftPlayer) player).getHandle().playerInteractManager.breakBlock(new BlockPosition(block.getX(), block.getY(), block.getZ()));