worldgen: parse structure sets and place them on the vanilla grid

Loads the 26.1.2 structure datapack: 20 structure sets, 34 structure
definitions, and the worldgen biome tags they reference. Random-spread
placement follows RandomSpreadStructurePlacement byte for byte — region
floorDiv by spacing, one Legacy stream salted per region, two
spread-type draws for the offset — and the four legacy frequency
reducers keep their exact draws, including the hardcoded buried-treasure
salt and the outpost's discarded full-range int.

Verified against the fixture: on seed 12345 the ruined_portals set
claims exactly chunk (1,0), the chunk whose captured blocks carry the
ruined portal's obsidian, gold, and crying obsidian. TestStructure-
PlacementGrid pins that plus village separation invariants.
This commit is contained in:
Daniar Mannanov 2026-08-26 10:33:10 +03:00
parent f162698302
commit c488ce274f
125 changed files with 2123 additions and 0 deletions

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 20083232,
"separation": 8,
"spacing": 24
},
"structures": [
{
"structure": "minecraft:ancient_city",
"weight": 1
}
]
}

View file

@ -0,0 +1,21 @@
{
"placement": {
"type": "minecraft:random_spread",
"frequency": 0.01,
"frequency_reduction_method": "legacy_type_2",
"locate_offset": [
9,
0,
9
],
"salt": 0,
"separation": 0,
"spacing": 1
},
"structures": [
{
"structure": "minecraft:buried_treasure",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357617,
"separation": 8,
"spacing": 32
},
"structures": [
{
"structure": "minecraft:desert_pyramid",
"weight": 1
}
]
}

View file

@ -0,0 +1,15 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 10387313,
"separation": 11,
"spacing": 20,
"spread_type": "triangular"
},
"structures": [
{
"structure": "minecraft:end_city",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357618,
"separation": 8,
"spacing": 32
},
"structures": [
{
"structure": "minecraft:igloo",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357619,
"separation": 8,
"spacing": 32
},
"structures": [
{
"structure": "minecraft:jungle_pyramid",
"weight": 1
}
]
}

View file

@ -0,0 +1,20 @@
{
"placement": {
"type": "minecraft:random_spread",
"frequency": 0.004,
"frequency_reduction_method": "legacy_type_3",
"salt": 0,
"separation": 0,
"spacing": 1
},
"structures": [
{
"structure": "minecraft:mineshaft",
"weight": 1
},
{
"structure": "minecraft:mineshaft_mesa",
"weight": 1
}
]
}

View file

@ -0,0 +1,18 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 30084232,
"separation": 4,
"spacing": 27
},
"structures": [
{
"structure": "minecraft:fortress",
"weight": 2
},
{
"structure": "minecraft:bastion_remnant",
"weight": 3
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357921,
"separation": 1,
"spacing": 2
},
"structures": [
{
"structure": "minecraft:nether_fossil",
"weight": 1
}
]
}

View file

@ -0,0 +1,15 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 10387313,
"separation": 5,
"spacing": 32,
"spread_type": "triangular"
},
"structures": [
{
"structure": "minecraft:monument",
"weight": 1
}
]
}

View file

@ -0,0 +1,18 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357621,
"separation": 8,
"spacing": 20
},
"structures": [
{
"structure": "minecraft:ocean_ruin_cold",
"weight": 1
},
{
"structure": "minecraft:ocean_ruin_warm",
"weight": 1
}
]
}

View file

@ -0,0 +1,20 @@
{
"placement": {
"type": "minecraft:random_spread",
"exclusion_zone": {
"chunk_count": 10,
"other_set": "minecraft:villages"
},
"frequency": 0.2,
"frequency_reduction_method": "legacy_type_1",
"salt": 165745296,
"separation": 8,
"spacing": 32
},
"structures": [
{
"structure": "minecraft:pillager_outpost",
"weight": 1
}
]
}

View file

@ -0,0 +1,38 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 34222645,
"separation": 15,
"spacing": 40
},
"structures": [
{
"structure": "minecraft:ruined_portal",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_desert",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_jungle",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_swamp",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_mountain",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_ocean",
"weight": 1
},
{
"structure": "minecraft:ruined_portal_nether",
"weight": 1
}
]
}

View file

@ -0,0 +1,18 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 165745295,
"separation": 4,
"spacing": 24
},
"structures": [
{
"structure": "minecraft:shipwreck",
"weight": 1
},
{
"structure": "minecraft:shipwreck_beached",
"weight": 1
}
]
}

View file

@ -0,0 +1,16 @@
{
"placement": {
"type": "minecraft:concentric_rings",
"count": 128,
"distance": 32,
"preferred_biomes": "#minecraft:stronghold_biased_to",
"salt": 0,
"spread": 3
},
"structures": [
{
"structure": "minecraft:stronghold",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 14357620,
"separation": 8,
"spacing": 32
},
"structures": [
{
"structure": "minecraft:swamp_hut",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 83469867,
"separation": 8,
"spacing": 34
},
"structures": [
{
"structure": "minecraft:trail_ruins",
"weight": 1
}
]
}

View file

@ -0,0 +1,14 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 94251327,
"separation": 12,
"spacing": 34
},
"structures": [
{
"structure": "minecraft:trial_chambers",
"weight": 1
}
]
}

View file

@ -0,0 +1,30 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 10387312,
"separation": 8,
"spacing": 34
},
"structures": [
{
"structure": "minecraft:village_plains",
"weight": 1
},
{
"structure": "minecraft:village_desert",
"weight": 1
},
{
"structure": "minecraft:village_savanna",
"weight": 1
},
{
"structure": "minecraft:village_snowy",
"weight": 1
},
{
"structure": "minecraft:village_taiga",
"weight": 1
}
]
}

View file

@ -0,0 +1,15 @@
{
"placement": {
"type": "minecraft:random_spread",
"salt": 10387319,
"separation": 20,
"spacing": 80,
"spread_type": "triangular"
},
"structures": [
{
"structure": "minecraft:mansion",
"weight": 1
}
]
}