-
Bug
-
Resolution: Unresolved
-
None
-
Minecraft 15w32a, Minecraft 15w45a, Minecraft 1.9.4, Minecraft 1.10 Pre-Release 1, Minecraft 1.10.2, Minecraft 16w32b, Minecraft 16w38a, Minecraft 16w42a, Minecraft 16w43a, Minecraft 1.11 Pre-Release 1, Minecraft 1.11, Minecraft 16w50a, Minecraft 1.11.1, Minecraft 1.11.2, Minecraft 17w06a, Minecraft 17w13b, Minecraft 17w15a, Minecraft 17w16b, Minecraft 17w17b, Minecraft 17w18b, Minecraft 1.12 Pre-Release 2, Minecraft 1.12.1, Minecraft 1.12.2, Minecraft 17w45b, Minecraft 17w46a, Minecraft 17w47a, Minecraft 17w47b, Minecraft 1.13.1, Minecraft 1.13.2, Minecraft 19w04b, Minecraft 19w05a, Minecraft 1.14 Pre-Release 2, Minecraft 1.14 Pre-Release 3, Minecraft 1.14 Pre-Release 4, Minecraft 1.14 Pre-Release 5, 1.16 Pre-release 5, 1.16.2 Pre-release 2, 1.16.2 Release Candidate 1, 1.16.2, 1.16.3, 1.16.4, 20w46a, 20w51a, 21w03a, 21w05b, 21w06a, 21w07a, 21w11a, 21w17a, 1.17 Pre-release 2, 1.17, 1.17.1, 21w41a, 21w43a, 1.18, 1.18.1, 22w03a, 22w05a, 22w06a, 22w07a, 1.18.2 Release Candidate 1, 1.18.2, 22w17a, 22w18a, 1.19, 1.19.1, 1.19.2, 22w43a, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.4, 23w51b, 1.20.6, 24w19b, 1.21, 1.21.1, 1.21.2 Pre-Release 3, 1.21.3, 1.21.4
-
None
-
Confirmed
-
Block states
-
Low
-
Gameplay
The Bug:
You cannot convert blocks into dirt paths when non-full blocks are above them.
Steps to Reproduce:
- Build the setup as shown in the attachment below. setup.png
- Obtain a shovel and attempt to turn all of the three grass blocks into dirt paths.
- Take note as to whether or not you can convert blocks into dirt paths when non-full blocks are above them.
Observed Behavior:
You cannot convert blocks into dirt paths when non-full blocks are above them.
Expected Behavior:
You would be able to convert blocks into dirt paths when non-full blocks are above them.
Code Analysis:
Code analysis by Avoma can be found below.
The following is based on a decompiled version of Minecraft 1.18 using MCP-Reborn.
public class ShovelItem extends DiggerItem { protected static final Map<Block, BlockState> FLATTENABLES = Maps.newHashMap((new Builder()).put(Blocks.GRASS_BLOCK, Blocks.DIRT_PATH.defaultBlockState()).put(Blocks.DIRT, Blocks.DIRT_PATH.defaultBlockState()).put(Blocks.PODZOL, Blocks.DIRT_PATH.defaultBlockState()).put(Blocks.COARSE_DIRT, Blocks.DIRT_PATH.defaultBlockState()).put(Blocks.MYCELIUM, Blocks.DIRT_PATH.defaultBlockState()).put(Blocks.ROOTED_DIRT, Blocks.DIRT_PATH.defaultBlockState()).build()); ... public InteractionResult useOn(UseOnContext $$0) { Level level = $$0.getLevel(); BlockPos blockpos = $$0.getClickedPos(); BlockState blockstate = level.getBlockState(blockpos); if ($$0.getClickedFace() == Direction.DOWN) { return InteractionResult.PASS; } else { Player player = $$0.getPlayer(); BlockState blockstate1 = FLATTENABLES.get(blockstate.getBlock()); BlockState blockstate2 = null; if (blockstate1 != null && level.getBlockState(blockpos.above()).isAir()) { level.playSound(player, blockpos, SoundEvents.SHOVEL_FLATTEN, SoundSource.BLOCKS, 1.0F, 1.0F); ...
If we look at the above class, we can see that you can only convert blocks into dirt paths using shovels if air is above them. This is evident through the following line of code:
if (blockstate1 != null && level.getBlockState(blockpos.above()).isAir())
- is duplicated by
-
MC-85367 cannot create grass paths under non full blocks
- Resolved
-
MC-94708 I can't create a path or till when non solid block is on top of it.
- Resolved
-
MC-107181 Unable to turn grass or dirt blocks into grass path
- Resolved
-
MC-202641 Cannot pave grass blocks under fence gates
- Resolved
-
MC-226949 cannot path dirt/grass thats under signs
- Resolved
-
MC-229651 path bug for 1.17
- Resolved
-
MC-245089 path bug
- Resolved
-
MC-262742 Dirt blocks cant be turned into "Dirt Path" when they are under a slab
- Resolved
- relates to
-
MC-84731 Dirt path and farmland turn into dirt when placing certain transparent blocks on top
- Reopened
-
MC-103899 Coarse dirt and grass block can't be tilled under torches, buttons, levers, or other non-full blocks
- Open
-
MC-221250 You cannot use hoes on blocks that are underwater
- Open
-
MC-222484 Farmland or dirt path cannot be created below a light block
- Open