[PR #4098] [MERGED] Send the stored Main Hand option on join #5415

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

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/4098
Author: @DUzzL
Created: 10/30/2026
Status: ✅ Merged
Merged: 10/30/2026
Merged by: @rdbtCVS

Base: main ← Head: fix/issue-4086-main-hand


📝 Commits (1)

  • baa05a3 Send the stored Main Hand option in ClientInformation

📊 Changes

4 files changed (+48 additions, -36 deletions)

View changed files

📝 crates/horizon-client-render/src/settings.rs (+11 -0)
📝 crates/horizon-client/src/game/remote.rs (+11 -5)
📝 crates/horizon-client/src/net.rs (+11 -31)
📝 crates/horizon-protocol/src/packets/configuration.rs (+15 -0)

📄 Description

🤖 Opened by DUzzL's AI agent, not by DUzzL personally.

Fixes #4086

Cause: the Skin Customization "Main Hand" option was saved, but the join-time ClientInformation was built with ClientInformation::new, which hardcodes main_hand: 1 (right). The server always got "right".

Change: remote.rs and net.rs build the join-time ClientInformation from the stored settings (Settings::client_information, left = 0, right = 1). Two tests: a protocol round-trip for 0 and 1, and a settings mapping test.

Tested: cargo fmt --check and cargo clippy -p horizon-protocol -p horizon-client-render -p horizon-client --all-targets -- -D warnings pass. cargo test -p horizon-protocol (110 passed), cargo test -p horizon-client-render --lib client_information (the new settings test, 1 passed; the protocol round-trip is in the 110). cargo test -p horizon-client --lib: 710 passed, 1 failed (title::tests::each_world_preset_writes_its_own_generator, a Windows path error NotADirectory in a title-screen test this change does not touch).

Not tested: no in-game run, so it is not confirmed that a server shows the item in the left hand. No vanilla parity run (no .local vanilla data here). tools/pr_ready.py not run.


🔄 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/4098 **Author:** [@DUzzL](https://github.com/DUzzL) **Created:** 10/30/2026 **Status:** ✅ Merged **Merged:** 10/30/2026 **Merged by:** [@rdbtCVS](https://github.com/rdbtCVS) **Base:** `main` ← **Head:** `fix/issue-4086-main-hand` --- ### 📝 Commits (1) - [`baa05a3`](https://github.com/horizon-rust/horizon/commit/baa05a30ec74271a24a4c8e142bb897ef5bb3439) Send the stored Main Hand option in ClientInformation ### 📊 Changes **4 files changed** (+48 additions, -36 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client-render/src/settings.rs` (+11 -0) 📝 `crates/horizon-client/src/game/remote.rs` (+11 -5) 📝 `crates/horizon-client/src/net.rs` (+11 -31) 📝 `crates/horizon-protocol/src/packets/configuration.rs` (+15 -0) </details> ### 📄 Description > 🤖 Opened by DUzzL's AI agent, not by DUzzL personally. Fixes #4086 **Cause:** the Skin Customization "Main Hand" option was saved, but the join-time `ClientInformation` was built with `ClientInformation::new`, which hardcodes `main_hand: 1` (right). The server always got "right". **Change:** `remote.rs` and `net.rs` build the join-time `ClientInformation` from the stored settings (`Settings::client_information`, left = 0, right = 1). Two tests: a protocol round-trip for 0 and 1, and a settings mapping test. **Tested:** `cargo fmt --check` and `cargo clippy -p horizon-protocol -p horizon-client-render -p horizon-client --all-targets -- -D warnings` pass. `cargo test -p horizon-protocol` (110 passed), `cargo test -p horizon-client-render --lib client_information` (the new settings test, 1 passed; the protocol round-trip is in the 110). `cargo test -p horizon-client --lib`: 710 passed, 1 failed (`title::tests::each_world_preset_writes_its_own_generator`, a Windows path error `NotADirectory` in a title-screen test this change does not touch). **Not tested:** no in-game run, so it is not confirmed that a server shows the item in the left hand. No vanilla parity run (no `.local` vanilla data here). `tools/pr_ready.py` not run. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:12:27 +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#5415
No description provided.