-
Bug
-
Resolution: Unresolved
-
None
-
20w30a, 20w51a, 21w06a, 1.20.2
-
None
-
Confirmed
-
Entities
The bug
Falling block entities (e.g. falling sand) are not consistently considered as obstruction, e.g. when determining whether the player may place a block at that location.
A falling block entity which is created when a falling block without supporting block starts to fall down obstructs block placement.
However, a falling block entity created in other situations is not considered an obstruction:
- entity traveling through portal
- entity created using /summon
- entity created by mob spawner
- ...
Considerations
There might datapacks which rely on this behavior?
Reproduction steps
- Let a falling block (e.g. sand) fall on cobweb
- While it is slowly falling down, try placing a block with collision box (e.g. stone) intersecting with the upper half of the falling block entity
As expected the falling block entity prevents placement of the block - Summon a falling block entity
/summon falling_block ~ ~0.01 ~ {NoGravity:1b,Time:-2147483648}
- Try placing a block with collision box (e.g. stone) intersecting with it
The block can be placed even though it intersects with the falling block entity
Code analysis
Mojang names
For all other entities which count as obstruction the field blocksBuilding is assigned a value in the (EntityType, Level) constructor to which all other constructors delegate. However, for net.minecraft.world.entity.item.FallingBlockEntity it is assigned in the other constructor.
To prevent issues like this in the future it would make sense to store this information in EntityType, similar to how it was done for the entity size which fixed MC-87652.
- relates to
-
MC-87652 Falling block entities' hitbox extends past its block
- Resolved