minecraft:selection_box
Defines the area of the block that is selected by the player's cursor. If set to true, default values are used. If set to false, this block is not selectable by the player's cursor. If this component is omitted, default values are used.
Properties
Can be written as a single value: boolean.
| Property | Type | Default | What it does |
|---|---|---|---|
origin | List of decimal or Object | [-8, 0, -8] | Minimal position of the bounds of the collision box. |
x | Decimal | 0 | |
y | Decimal | 0 | |
z | Decimal | 0 | |
size | List of decimal or Object | [16, 16, 16] | Size of each side of the collision box. |
x | Decimal | 0 | |
y | Decimal | 0 | |
z | Decimal | 0 |
Example from the game files
This is how vanilla red_shrub uses it in Minecraft Bedrock 1.26.60.5:
{
"minecraft:selection_box": {
"origin": [
-8,
0,
-8
],
"size": [
16,
16,
16
]
}
}Used by 2
Vanilla blocks with minecraft:selection_box in their definition:
red_shrubshelf_mushroom