# hbmspace:chance

Surface-rule condition on a per-block random.

The condition holds when the block's positional random draw for `random_name` is below `probability`. Conditions with the same name share one draw, so stacked conditions partition it.

## Fields

| Field | Meaning and default | Range |
| - | - | - |
| `type` | `hbmspace:chance`. | |
| `random_name` | Positional random name. | |
| `probability` | Chance that the condition holds. | `[0, 1]` |

## Example

From `data/hbmspace/worldgen/noise_settings/duna.json`:

```json
{"type": "hbmspace:chance", "probability": 0.6, "random_name": "hbmspace:surface_material"}
```
