[PR #1177] [MERGED] Structures: Formations' fountain (its pieced structure) generates #3392

Closed
opened 2026-11-03 04:09:12 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/1177
Author: @ludovic111
Created: 10/22/2026
Status: ✅ Merged
Merged: 10/22/2026
Merged by: @ludovic111

Base: main ← Head: feat/formations-fountain


📝 Commits (1)

  • e6b92eb Structures: Formations' fountain (its pieced structure) generates

📊 Changes

5 files changed (+152 additions, -27 deletions)

View changed files

📝 crates/horizon-port-pack/src/worldgen.rs (+32 -6)
📝 crates/horizon-world/src/worldgen/structure/formations.rs (+71 -6)
📝 crates/horizon-world/src/worldgen/structure/jigsaw.rs (+40 -12)
📝 crates/horizon-world/src/worldgen/structure/start.rs (+2 -2)
📝 docs/modpacks.md (+7 -1)

📄 Description

🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself.

What

Formations' one formations:pieced structure, the fountain, now generates.

  • Game: PiecedStructure starts exactly as Formations' SimpleStructure (horizon:formations: an element of the pool at a random spot of the chunk, a random rotation, the height its placement finds), then runs the inner JigsawPlacement.addPieces from that placed piece. The jigsaw assembler's child layout is now its own function, jigsaw::add_children (assemble calls it unchanged), so a structure with its own start can reach it. horizon:formations reads horizon:pieced: {max_depth, max_distance_from_center}: the start position is the element's centre, one block above the height found (where the biome is checked), and the children stay within that distance of it, not clamped to the world's height, less the start's box, as the mod's allowedSpace. No y < min_y refusal for the pieced type, which the mod doesn't have.
  • Carry: formations:pieced becomes horizon:formations with template (its start_pool) and horizon:pieced.

Licence: Formations is All Rights Reserved. Nothing of it is in the repo. Carry rewrites the player's own copy of the fountain's data locally; the game side is the structure's observed rule (the existing simple start plus vanilla's jigsaw).

Why

modpacks-12 brief, step 3 (the fountain, which "needs the jigsaw assembler reachable from a custom start"). Formations' block ageing, the other half of step 3, is not here: its Java tables are All Rights Reserved, the same question as its biome table (see the modpacks-12 final report).

How tested

  • Re-carry of formationsoverworld: unsupported goes from {formations:pieced: 1} to {}.
  • chunkgen_bench --starts, chunks -64..63, the carried ATM10 mods with and without this: the fountain shares Formations' "uncommon" set, so where the set now picks it, it replaces the statue or house it picked before. Seed 1234: 1 start changes (a statue becomes a fountain). Seed 2: 3 change (two houses, a statue), one fountain with a jigsaw child (2 pieces). Every other start is identical.
  • Vanilla structure-start oracle, seed 1234 chunks -32..31: 45 of 45 match (the assembler refactor changes nothing).
  • Unit tests: formations_pieced_structure_keeps_its_jigsaw (carry), placements_by_name extended for horizon:pieced.
cargo fmt --all --check                                      ok
cargo clippy --workspace --all-targets -- -D warnings        ok (pipefail)
cargo test -p horizon-port-pack                              55 passed
cargo test -p horizon-world --lib                            152 passed, 1 ignored
tools/parity.py --changed origin/main                        run once on the integration commit of the modpacks-12 PRs

Needs Ludovic

Nothing for this PR.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/1177 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/22/2026 **Status:** ✅ Merged **Merged:** 10/22/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `feat/formations-fountain` --- ### 📝 Commits (1) - [`e6b92eb`](https://github.com/horizon-rust/horizon/commit/e6b92eb4ee5f3d9a2fb3e1f270fc9f520b8a1851) Structures: Formations' fountain (its pieced structure) generates ### 📊 Changes **5 files changed** (+152 additions, -27 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-port-pack/src/worldgen.rs` (+32 -6) 📝 `crates/horizon-world/src/worldgen/structure/formations.rs` (+71 -6) 📝 `crates/horizon-world/src/worldgen/structure/jigsaw.rs` (+40 -12) 📝 `crates/horizon-world/src/worldgen/structure/start.rs` (+2 -2) 📝 `docs/modpacks.md` (+7 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. ## What Formations' one `formations:pieced` structure, the fountain, now generates. - **Game:** PiecedStructure starts exactly as Formations' SimpleStructure (`horizon:formations`: an element of the pool at a random spot of the chunk, a random rotation, the height its placement finds), then runs the inner `JigsawPlacement.addPieces` from that placed piece. The jigsaw assembler's child layout is now its own function, `jigsaw::add_children` (`assemble` calls it unchanged), so a structure with its own start can reach it. `horizon:formations` reads `horizon:pieced: {max_depth, max_distance_from_center}`: the start position is the element's centre, one block above the height found (where the biome is checked), and the children stay within that distance of it, not clamped to the world's height, less the start's box, as the mod's `allowedSpace`. No `y < min_y` refusal for the pieced type, which the mod doesn't have. - **Carry:** `formations:pieced` becomes `horizon:formations` with `template` (its `start_pool`) and `horizon:pieced`. **Licence:** Formations is All Rights Reserved. Nothing of it is in the repo. Carry rewrites the player's own copy of the fountain's data locally; the game side is the structure's observed rule (the existing simple start plus vanilla's jigsaw). ## Why modpacks-12 brief, step 3 (the fountain, which "needs the jigsaw assembler reachable from a custom start"). Formations' block ageing, the other half of step 3, is not here: its Java tables are All Rights Reserved, the same question as its biome table (see the modpacks-12 final report). ## How tested - Re-carry of `formationsoverworld`: `unsupported` goes from `{formations:pieced: 1}` to `{}`. - `chunkgen_bench --starts`, chunks -64..63, the carried ATM10 mods with and without this: the fountain shares Formations' "uncommon" set, so where the set now picks it, it replaces the statue or house it picked before. Seed 1234: 1 start changes (a statue becomes a fountain). Seed 2: 3 change (two houses, a statue), one fountain with a jigsaw child (2 pieces). Every other start is identical. - Vanilla structure-start oracle, seed 1234 chunks -32..31: 45 of 45 match (the assembler refactor changes nothing). - Unit tests: `formations_pieced_structure_keeps_its_jigsaw` (carry), `placements_by_name` extended for `horizon:pieced`. ``` cargo fmt --all --check ok cargo clippy --workspace --all-targets -- -D warnings ok (pipefail) cargo test -p horizon-port-pack 55 passed cargo test -p horizon-world --lib 152 passed, 1 ignored tools/parity.py --changed origin/main run once on the integration commit of the modpacks-12 PRs ``` ## Needs Ludovic Nothing for this PR. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:09:12 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#3392
No description provided.