diff --git a/src/main/java/net/minestom/server/listener/BlockPlacementListener.java b/src/main/java/net/minestom/server/listener/BlockPlacementListener.java index ed3811e07..8d931529e 100644 --- a/src/main/java/net/minestom/server/listener/BlockPlacementListener.java +++ b/src/main/java/net/minestom/server/listener/BlockPlacementListener.java @@ -95,8 +95,8 @@ public class BlockPlacementListener { //todo it feels like it should be possible to have better replacement rules than this, feels pretty scuffed. Point placementPosition = blockPosition; var interactedPlacementRule = BLOCK_MANAGER.getBlockPlacementRule(interactedBlock); - if (interactedPlacementRule == null || !interactedPlacementRule.isSelfReplaceable( - new BlockPlacementRule.Replacement(interactedBlock, blockFace, cursorPosition, useMaterial))) { + if (!interactedBlock.isAir() && (interactedPlacementRule == null || !interactedPlacementRule.isSelfReplaceable( + new BlockPlacementRule.Replacement(interactedBlock, blockFace, cursorPosition, useMaterial)))) { // If the block is not replaceable, try to place next to it. final int offsetX = blockFace == BlockFace.WEST ? -1 : blockFace == BlockFace.EAST ? 1 : 0; final int offsetY = blockFace == BlockFace.BOTTOM ? -1 : blockFace == BlockFace.TOP ? 1 : 0;