# hbmspace:experimental_cave

Noise-bent tunnels with large rooms.

Tunnels bent by noise, wider and taller below `depth_threshold`, with rooms and occasional enlarged tunnels. They cut `replaceable` blocks and fluids, skip ellipsoids whose shell holds a fluid, and fill with `lava` at and below `lava_level`. On 26.3, a `minecraft:noise` generator whose biomes list a Space carver runs its carving after the surface pass, with vanilla carvers of the same biomes; Space carvers work only in such generators.

## Fields

| Field | Meaning and default | Range |
| - | - | - |
| `probability` | Chance that a source chunk starts the carver. | `[0, 1]` |
| `y` | Vanilla height provider for start heights. | |
| `y_scale` | Vanilla float provider: vertical scale of rooms. | |
| `lava_level` | Vertical anchor at and below which cuts fill with the lava block. | |
| `replaceable` | Block ID, `#tag` or ID list: blocks the carver may cut. | |
| `carving_scale` | Accepted; unused. | `f32` |
| `depth_threshold` | Y below which tunnels widen and bend more. | `i32` |
| `large_cave_size` | Room size factor. | `f32` |
| `small_cave_size` | Size factor of one in ten tunnels. | `f32` |
| `lava` | Fill at and below `lava_level`. | |
| `lava.id` | Registered block ID. | |
| `lava.properties` (Optional) | Block-state property names and string values. | |
| `top` | Block ID, `#tag` or ID list: surface blocks. | |
| `filler` | Block ID, `#tag` or ID list: blocks re-topped when exposed. | |
| `biomes` (Optional) | Biome ID, `#tag` or ID list: positions the carver cuts; default all. | |

The top-level `type` selects this carver; the remaining fields belong beside it.

## Example

Source path: `data/hbmspace/worldgen/carver/duna/caves.json`

```json
{
  "type": "hbmspace:experimental_cave",
  "biomes": [
    "hbmspace:duna_plains",
    "hbmspace:duna_polar",
    "hbmspace:duna_hills",
    "hbmspace:duna_polar_hills"
  ],
  "carving_scale": 2.0,
  "depth_threshold": 12,
  "filler": [
    "hbmspace:duna_sands",
    "hbmspace:duna_rock",
    "minecraft:snow_block"
  ],
  "large_cave_size": 0.12,
  "lava": "hbmspace:duna_sands",
  "lava_level": {
    "absolute": 9
  },
  "probability": 0.14285715,
  "replaceable": [
    "hbmspace:duna_rock",
    "hbmspace:duna_sands",
    "minecraft:snow_block"
  ],
  "small_cave_size": 0.1,
  "top": [
    "hbmspace:duna_sands",
    "minecraft:snow_block"
  ],
  "y": {
    "type": "minecraft:biased_to_bottom",
    "inner": 8,
    "max_inclusive": {
      "absolute": 127
    },
    "min_inclusive": {
      "absolute": 0
    }
  },
  "y_scale": 0.5
}
```
