[PR #816] [MERGED] Carry: write worldgen block states in 26.3's shape #2829

Closed
opened 2026-11-02 15:59:23 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

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

Base: main ← Head: fix/carry-worldgen-block-states


📝 Commits (1)

  • 7d27950 Carry: write worldgen block states in 26.3's shape

📊 Changes

1 file changed (+64 additions, -3 deletions)

View changed files

📝 crates/horizon-port-pack/src/worldgen.rs (+64 -3)

📄 Description

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

Based on main (#763 merged through #823).

What

1.21.1 writes a block or fluid state in worldgen JSON as {"Name": ..., "Properties": {...}}. 26.3's codec reads {"id": ..., "properties": {...}} (vanilla's own processor_lists and features bundles use that shape) and Horizon's decoder, like vanilla's, refuses the old one. So every carried processor list, configured feature or template pool holding a state failed to decode, and the pool that named it was dropped whole.

Carry now rewrites every object that is exactly {Name[, Properties]} in a mod's worldgen files to 26.3's shape, and counts the files in carry-report.json (worldgen_types.block_states). Structure NBT templates keep Name/Properties: the NBT format did not change.

Why

Found while measuring what the carried ATM10 structure mods actually generate: about half of the pools that failed in a 64×64-chunk region failed on this alone ("missing block identifier").

Measured (ATM10's 42 carried mods, seed 1234, chunks -32..31, chunkgen_bench --starts on a local overlay of the carried worldgen)

starts pieces pools that failed to decode
before 241 3,309 65 (35 on block states, 30 on processor types written in Java)
after 245 3,314 48 (all on processor types written in Java)

1,005 files in 17 mods are rewritten: Regions Unexplored 433, Repurposed Structures 347, Nullscape 97, CTOV 51, YUNG's 38, Explorify 11, Dungeons Arise 7, Structory 6, Moog's 12, others 5. The rest of the missing generation is the processor types and structure types written in Java (next PRs).

Self-check

  • cargo fmt --all --check: clean
  • cargo clippy -p horizon-port-pack --all-targets -- -D warnings: clean (the launcher uses the crate but not the report type changed here)
  • cargo test -p horizon-port-pack: 26 passed (new: writes_block_states_in_26_3_shape)
  • No game code changes, so no parity harness covers this; the measurement above is the check.

Nothing here needs Ludovic. Mod jars and carried files stayed in a local work folder.

🤖 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/816 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/18/2026 **Status:** ✅ Merged **Merged:** 10/18/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/carry-worldgen-block-states` --- ### 📝 Commits (1) - [`7d27950`](https://github.com/horizon-rust/horizon/commit/7d27950e31983b0b1ac7f59f0b271a4f15028338) Carry: write worldgen block states in 26.3's shape ### 📊 Changes **1 file changed** (+64 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-port-pack/src/worldgen.rs` (+64 -3) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. Based on main (#763 merged through #823). ## What 1.21.1 writes a block or fluid state in worldgen JSON as `{"Name": ..., "Properties": {...}}`. 26.3's codec reads `{"id": ..., "properties": {...}}` (vanilla's own `processor_lists` and `features` bundles use that shape) and Horizon's decoder, like vanilla's, refuses the old one. So every carried processor list, configured feature or template pool holding a state failed to decode, and the pool that named it was dropped whole. Carry now rewrites every object that is exactly `{Name[, Properties]}` in a mod's worldgen files to 26.3's shape, and counts the files in `carry-report.json` (`worldgen_types.block_states`). Structure NBT templates keep `Name`/`Properties`: the NBT format did not change. ## Why Found while measuring what the carried ATM10 structure mods actually generate: about half of the pools that failed in a 64×64-chunk region failed on this alone ("missing block identifier"). ## Measured (ATM10's 42 carried mods, seed 1234, chunks -32..31, `chunkgen_bench --starts` on a local overlay of the carried worldgen) | | starts | pieces | pools that failed to decode | |---|---:|---:|---:| | before | 241 | 3,309 | 65 (35 on block states, 30 on processor types written in Java) | | after | 245 | 3,314 | 48 (all on processor types written in Java) | 1,005 files in 17 mods are rewritten: Regions Unexplored 433, Repurposed Structures 347, Nullscape 97, CTOV 51, YUNG's 38, Explorify 11, Dungeons Arise 7, Structory 6, Moog's 12, others 5. The rest of the missing generation is the processor types and structure types written in Java (next PRs). ## Self-check - `cargo fmt --all --check`: clean - `cargo clippy -p horizon-port-pack --all-targets -- -D warnings`: clean (the launcher uses the crate but not the report type changed here) - `cargo test -p horizon-port-pack`: 26 passed (new: `writes_block_states_in_26_3_shape`) - No game code changes, so no parity harness covers this; the measurement above is the check. Nothing here needs Ludovic. Mod jars and carried files stayed in a local work folder. 🤖 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-02 15:59:23 +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#2829
No description provided.