World shape for dimension
This commit is contained in:
@@ -256,15 +256,40 @@ base game's is `worldgen/dimension/overworld.json`:
|
||||
"dimension": {
|
||||
"id": "bworld:overworld",
|
||||
"generator": "bworld:overworld",
|
||||
"default": true
|
||||
"default": true,
|
||||
"min_y": 0,
|
||||
"max_y": 256,
|
||||
"sky_light": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
| Field | Meaning |
|
||||
| ----------- | --------------------------------------------------------- |
|
||||
| `generator` | The [noise settings](#noise-settings) that generate it. |
|
||||
| `default` | `true` for the dimension the world plays. False if unset. |
|
||||
| Field | Meaning |
|
||||
| ----------- | ------------------------------------------------------------------------------------------------------- |
|
||||
| `generator` | The [noise settings](#noise-settings) that generate it. |
|
||||
| `default` | `true` for the dimension the world plays. False if unset. |
|
||||
| `min_y` | The lowest y that has blocks. 0 if unset. |
|
||||
| `max_y` | The first y above the world: blocks go up to `max_y - 1`. 256 if unset. |
|
||||
| `sky_light` | Whether light comes from the sky. `false` for a dimension that's underground everywhere. True if unset. |
|
||||
|
||||
### Height
|
||||
|
||||
A dimension's blocks go from `min_y` up to `max_y - 1`, so `"min_y": -64, "max_y": 320` is 384 blocks tall. Both have to
|
||||
be multiples of 16, `max_y` at least 16 above `min_y`, and the world has to fit in -2048 to 2048. They also have to be
|
||||
multiples of the generator's `terrain` and `caves` `cell_height`, since the density is sampled every `cell_height`
|
||||
blocks up from `min_y`. `check-mods` reports any of these, and the server doesn't start with them.
|
||||
|
||||
Outside the height there are no blocks: reading one gives air and placing one does nothing. Things that fall 64 blocks
|
||||
below `min_y` are out of the world. Scripts read the height as `ctx.world.min_y` and `ctx.world.max_y`, on the server
|
||||
and the client, and features as `chunk.min_y` and `chunk.max_y`.
|
||||
|
||||
Chunks are saved with the height they were made with. For now a chunk saved before a dimension's height changed can't be
|
||||
read, and is generated again.
|
||||
|
||||
### Sky Light
|
||||
|
||||
Without sky light, there's none anywhere, in the open and above the world too: only blocks that give off light, like
|
||||
torches, light it, and day and night don't change how bright it is. The sky is still drawn as it is in the overworld.
|
||||
|
||||
The world plays the dimension with `"default": true`. Exactly one dimension in the loaded mods can be the default: with
|
||||
none, or more than one, the server doesn't start, and the error names them. A mod can have dimensions that aren't the
|
||||
@@ -274,7 +299,8 @@ its own, like a flat world, can't be loaded with the base game's for now.
|
||||
There's one dimension per world for now, there's no travelling between them yet.
|
||||
|
||||
New players spawn in the middle of the world, on the first column, in rings of chunks around 0, 0, whose top block has
|
||||
collision. Water has none, so they never spawn in the sea, and neither do plants without collision.
|
||||
collision, looking down from `max_y`. Water has none, so they never spawn in the sea, and neither do plants without
|
||||
collision.
|
||||
|
||||
## Changing the Base Game's Terrain
|
||||
|
||||
|
||||
Reference in New Issue
Block a user