minecraft:random_offset for you with a switch.Get GodCraftOverview
minecraft:random_offset is a block component: it goes in the components object of a custom block. Shifts the block a little from the center, by an amount picked from its position, like flowers and grass that are not lined up perfectly. The shift also moves the outline and collision, and stays inside the block space.
Fields
| Field | Type | Default | Description |
|---|---|---|---|
x | Range And Steps | {"range":{"max":0,"min":0},"steps":0} | Sideways shift along x: a min and max range plus how many steps between them. |
y | Range And Steps | {"range":{"max":0,"min":0},"steps":0} | Up and down shift: a min and max range plus how many steps between them. |
z | Range And Steps | {"range":{"max":0,"min":0},"steps":0} | Sideways shift along z: a min and max range plus how many steps between them. |
Example
Inside the components object of BP/blocks/<name>.json (values are the defaults or placeholders):
BP/blocks/<name>.json
{
"minecraft:random_offset": {
"x": {
"range": {
"max": 0,
"min": 0
},
"steps": 0
},
"y": {
"range": {
"max": 0,
"min": 0
},
"steps": 0
},
"z": {
"range": {
"max": 0,
"min": 0
},
"steps": 0
}
}
}