Biome tags
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# Tags
|
||||
|
||||
A tag is a named list of blocks, items or entities, like every kind of planks. Recipes and blocks can use a tag anywhere
|
||||
they take an id, and any mod can add to any tag, so a mod's planks can make sticks just by adding them to
|
||||
A tag is a named list of blocks, items, entities or biomes, like every kind of planks. Recipes and blocks can use a tag
|
||||
anywhere they take an id, and any mod can add to any tag, so a mod's planks can make sticks just by adding them to
|
||||
`#bworld:planks`. Tags work like [NeoForge's](https://docs.neoforged.net/docs/resources/server/tags).
|
||||
|
||||
A tag's id starts with `#` where it's used, so `#bworld:planks` is the tag of every kind of planks, and
|
||||
@@ -20,8 +20,8 @@ tags/
|
||||
my_mod/soft.json # the block tag #my_mod:soft
|
||||
```
|
||||
|
||||
`<registry>` is `blocks`, `items` or `entities`. A block tag and an item tag with the same id are two different tags, so
|
||||
a block that should be in both, like planks, needs a file for each.
|
||||
`<registry>` is `blocks`, `items`, `entities` or `biomes`. A block tag and an item tag with the same id are two
|
||||
different tags, so a block that should be in both, like planks, needs a file for each.
|
||||
|
||||
```json
|
||||
{
|
||||
|
||||
@@ -71,6 +71,20 @@ Biome ids are what features' `biome_at` gives and what spawns list. The base gam
|
||||
|
||||
`/locatebiome <id>` finds the nearest one.
|
||||
|
||||
## Biome Tags
|
||||
|
||||
Biomes have [tags](../resources/tags.md) too, in `tags/biomes/`. The base game's are like Minecraft's:
|
||||
|
||||
| Tag | Biomes |
|
||||
| --------------------- | ----------------------------------------------------------------------------------------------- |
|
||||
| `#bworld:is_ocean` | `ocean`, `deep_ocean`, `frozen_ocean`, `deep_frozen_ocean`, `warm_ocean`, `deep_lukewarm_ocean` |
|
||||
| `#bworld:is_river` | `river`, `frozen_river` |
|
||||
| `#bworld:is_mountain` | `meadow`, `frozen_peaks`, `jagged_peaks`, `stony_peaks`, `snowy_slopes` |
|
||||
| `#bworld:is_forest` | `forest`, `dark_forest` |
|
||||
|
||||
A mod's biome joins one by adding itself to the tag's file, like `tags/biomes/bworld/is_forest.json`, and a script
|
||||
checks a biome with `ctx.tags.has("biomes", "bworld:is_forest", ctx.world.biome_at(x, z))`.
|
||||
|
||||
## Seasons
|
||||
|
||||
Seasons follow the calendar, 49 days each: days 1 to 49 are spring, 50 to 98 summer, 99 to 147 autumn and 148 to 196
|
||||
|
||||
Reference in New Issue
Block a user