[PR #177] [MERGED] Fix Classic singleplayer world management screens #2378

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

📋 Pull Request Information

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

Base: main ← Head: t3code/classic-singleplayer-ui-parity


📝 Commits (6)

  • 3293347 Fix classic singleplayer world management UI parity
  • b37db61 Fix world selector clipping lint on Rust 1.99
  • aa53057 Fix backup completion flow and localize world management
  • f8341dc Ignore generated world backups
  • 24d8c57 Make filtered world selection regression deterministic
  • e8efd36 Integrate world management with Classic button click sounds

📊 Changes

11 files changed (+1653 additions, -169 deletions)

View changed files

📝 .gitignore (+1 -0)
📝 Cargo.lock (+1 -0)
📝 crates/horizon-client/Cargo.toml (+1 -0)
📝 crates/horizon-client/src/front.rs (+21 -1)
📝 crates/horizon-client/src/game.rs (+19 -0)
📝 crates/horizon-client/src/game/agent.rs (+24 -1)
📝 crates/horizon-client/src/game/clipboard.rs (+7 -1)
📝 crates/horizon-client/src/hud.rs (+10 -0)
📝 crates/horizon-client/src/title.rs (+897 -166)
➕ crates/horizon-client/src/title/tests.rs (+535 -0)
➕ crates/horizon-client/src/title/world_management.rs (+137 -0)

📄 Description

The Classic singleplayer menu only exposed Play, Create, and Back, and opening Singleplayer with no saves still showed an empty selector. Add the world-management screens and route an empty saves list directly to Create New World.

  • Match the vanilla selector's search box, icon rows, metadata, scrolling, and Edit/Delete/Re-Create controls.
  • Add Edit World with rename, Reset Icon, world/backups folder shortcuts, and Make Backup. Reset Icon is disabled without an icon; Optimize World is visible and disabled because the client does not provide that operation.
  • Preserve unrelated NBT when renaming. Cancel discards name edits; Save and Enter refresh the selector.
  • Create timestamped ZIP backups on a worker thread, display the vanilla Creating Backup message and loading dots, block Escape while the operation runs, and show the backup size on completion. Exclude session.lock and clean up incomplete archives on failure.
  • Require the vanilla Delete confirmation with the world's name; Cancel and Escape preserve the save.
  • Return to the world list with the backed-up world selected after both success and failure. Show the backup-created/size toast on success and the backup-failed/exception toast on failure. Unsaved rename edits are discarded.
  • Use vanilla translation keys for world-management buttons, titles, deletion warnings, list metadata, backup messages/toasts, and the empty search hint.
  • Integrate the world-management controls with the Classic ui.button.click path on left mouse presses, including Edit/Delete/Backup navigation. Preserve silent disabled controls, list selection, and backup progress.

Validation:

  • cargo test --locked --workspace --lib --bins --tests: 879 tests passed.
  • cargo test --locked --workspace --doc: passed.
  • The default full workspace build hit the local disk quota while linking examples; strict Clippy passed for all example targets.
  • cargo test --locked -p horizon-client --lib: 512 tests passed, including 17 world-menu tests covering backup navigation, worker failures, and click sounds.
  • cargo build --locked -p horizon-client --bin horizon-client
  • In-game control/socket and screenshot checks: empty saves routing, icons, disabled buttons, rename/Cancel, real 64 MiB backup contents and progress, and Delete/Cancel. Escape behavior is covered by the regression tests; physical key injection into the offscreen test window is unreliable.
  • cargo fmt --all -- --check, git diff --check, and python tools/check_public_tree.py
  • cargo clippy --locked --workspace --all-targets -- -D warnings passed without lint exceptions.
  • All 187 offline Python tests passed.
  • The filtered-selection regression explicitly focuses the search field and fixes the input list order, so filesystem timestamp precision cannot mask an incorrect filtered index.

🔄 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/177 **Author:** [@rdbtCVS](https://github.com/rdbtCVS) **Created:** 10/14/2026 **Status:** ✅ Merged **Merged:** 10/14/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `t3code/classic-singleplayer-ui-parity` --- ### 📝 Commits (6) - [`3293347`](https://github.com/horizon-rust/horizon/commit/329334723d673c281b8641f62147547012dda158) Fix classic singleplayer world management UI parity - [`b37db61`](https://github.com/horizon-rust/horizon/commit/b37db617134d3c389dae6985562a8d2a0e3386a2) Fix world selector clipping lint on Rust 1.99 - [`aa53057`](https://github.com/horizon-rust/horizon/commit/aa5305772d11d62a6158bde800f86f18ebf984f3) Fix backup completion flow and localize world management - [`f8341dc`](https://github.com/horizon-rust/horizon/commit/f8341dc41573103859283de02e2556382d054704) Ignore generated world backups - [`24d8c57`](https://github.com/horizon-rust/horizon/commit/24d8c57932441b91eb91db4b63e451c24cb23730) Make filtered world selection regression deterministic - [`e8efd36`](https://github.com/horizon-rust/horizon/commit/e8efd36e5be8202abf8617f4e127de10e1652fc1) Integrate world management with Classic button click sounds ### 📊 Changes **11 files changed** (+1653 additions, -169 deletions) <details> <summary>View changed files</summary> 📝 `.gitignore` (+1 -0) 📝 `Cargo.lock` (+1 -0) 📝 `crates/horizon-client/Cargo.toml` (+1 -0) 📝 `crates/horizon-client/src/front.rs` (+21 -1) 📝 `crates/horizon-client/src/game.rs` (+19 -0) 📝 `crates/horizon-client/src/game/agent.rs` (+24 -1) 📝 `crates/horizon-client/src/game/clipboard.rs` (+7 -1) 📝 `crates/horizon-client/src/hud.rs` (+10 -0) 📝 `crates/horizon-client/src/title.rs` (+897 -166) ➕ `crates/horizon-client/src/title/tests.rs` (+535 -0) ➕ `crates/horizon-client/src/title/world_management.rs` (+137 -0) </details> ### 📄 Description The Classic singleplayer menu only exposed Play, Create, and Back, and opening Singleplayer with no saves still showed an empty selector. Add the world-management screens and route an empty saves list directly to Create New World. - Match the vanilla selector's search box, icon rows, metadata, scrolling, and Edit/Delete/Re-Create controls. - Add Edit World with rename, Reset Icon, world/backups folder shortcuts, and Make Backup. Reset Icon is disabled without an icon; Optimize World is visible and disabled because the client does not provide that operation. - Preserve unrelated NBT when renaming. Cancel discards name edits; Save and Enter refresh the selector. - Create timestamped ZIP backups on a worker thread, display the vanilla Creating Backup message and loading dots, block Escape while the operation runs, and show the backup size on completion. Exclude session.lock and clean up incomplete archives on failure. - Require the vanilla Delete confirmation with the world's name; Cancel and Escape preserve the save. - Return to the world list with the backed-up world selected after both success and failure. Show the backup-created/size toast on success and the backup-failed/exception toast on failure. Unsaved rename edits are discarded. - Use vanilla translation keys for world-management buttons, titles, deletion warnings, list metadata, backup messages/toasts, and the empty search hint. - Integrate the world-management controls with the Classic `ui.button.click` path on left mouse presses, including Edit/Delete/Backup navigation. Preserve silent disabled controls, list selection, and backup progress. Validation: - `cargo test --locked --workspace --lib --bins --tests`: 879 tests passed. - `cargo test --locked --workspace --doc`: passed. - The default full workspace build hit the local disk quota while linking examples; strict Clippy passed for all example targets. - `cargo test --locked -p horizon-client --lib`: 512 tests passed, including 17 world-menu tests covering backup navigation, worker failures, and click sounds. - `cargo build --locked -p horizon-client --bin horizon-client` - In-game control/socket and screenshot checks: empty saves routing, icons, disabled buttons, rename/Cancel, real 64 MiB backup contents and progress, and Delete/Cancel. Escape behavior is covered by the regression tests; physical key injection into the offscreen test window is unreliable. - `cargo fmt --all -- --check`, `git diff --check`, and `python tools/check_public_tree.py` - `cargo clippy --locked --workspace --all-targets -- -D warnings` passed without lint exceptions. - All 187 offline Python tests passed. - The filtered-selection regression explicitly focuses the search field and fixes the input list order, so filesystem timestamp precision cannot mask an incorrect filtered index. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-02 15:55:28 +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#2378
No description provided.