[PR #863] [MERGED] Server: send a player standing up again, and draw other players' crouch #2867

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

📋 Pull Request Information

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

Base: main ← Head: fix/server-crouch-flags


📝 Commits (1)

  • dd9f8a9 Server: send a player standing up again, and draw other players' crouch

📊 Changes

2 files changed (+58 additions, -2 deletions)

View changed files

📝 crates/horizon-client/src/game/remote.rs (+14 -0)
📝 crates/horizon-client/src/lan/entity.rs (+44 -2)

📄 Description

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

One of #731's server-thread gaps, split out as a small PR: the crouch fix from #731's commit b9f3821f, ported to the current tracker (ServerEntity, #841).

What changes

  • Tracker (lan/entity.rs). An entity's state leaves out values that are at their default. So when a player stood up again, or a mob stopped burning, the tracker sent nothing, and clients (vanilla ones included) kept the old flags. sendDirtyEntityData now sends Entity's shared flags (index 0) and pose (index 6) back at 0 when they leave the state. There is a unit test for this.
  • Remote client (game/remote.rs). Another player's crouch bit (DATA_SHARED_FLAGS_ID) now reaches their model and their name tag (Entity.isDiscrete). The host window on the server thread is such a client.

Checks (Mac mini, on e508a5ce)

  • tools/lan_e2e.py --check walls:
    • --server-thread: FAIL on main ("no name tag through the wall: 0 pixels differ standing vs crouching"), PASS here (1158 pixels differ).
    • In-frame: PASS before and after.
  • Harnesses:
    • server_entities: 25 identical.
    • lan: 462 cases.
    • dedicated_server: 592 lines.
    • server_dimension_players: 22 lines.
  • cargo fmt --check: clean.
  • cargo clippy --workspace --all-targets -D warnings: clean.
  • cargo test -p horizon-client --lib lan::: 28 passed.

CI parity covers the rest.

Needs Ludovic: nothing.

🤖 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/863 **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/server-crouch-flags` --- ### 📝 Commits (1) - [`dd9f8a9`](https://github.com/horizon-rust/horizon/commit/dd9f8a908804b0fbd9c20f8dd7550476a71f245f) Server: send a player standing up again, and draw other players' crouch ### 📊 Changes **2 files changed** (+58 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/remote.rs` (+14 -0) 📝 `crates/horizon-client/src/lan/entity.rs` (+44 -2) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. One of #731's server-thread gaps, split out as a small PR: the crouch fix from #731's commit b9f3821f, ported to the current tracker (`ServerEntity`, #841). ## What changes - **Tracker** (`lan/entity.rs`). An entity's state leaves out values that are at their default. So when a player stood up again, or a mob stopped burning, the tracker sent nothing, and clients (vanilla ones included) kept the old flags. `sendDirtyEntityData` now sends Entity's shared flags (index 0) and pose (index 6) back at 0 when they leave the state. There is a unit test for this. - **Remote client** (`game/remote.rs`). Another player's crouch bit (`DATA_SHARED_FLAGS_ID`) now reaches their model and their name tag (`Entity.isDiscrete`). The host window on the server thread is such a client. ## Checks (Mac mini, on e508a5ce) - `tools/lan_e2e.py --check walls`: - `--server-thread`: FAIL on `main` ("no name tag through the wall: 0 pixels differ standing vs crouching"), PASS here (1158 pixels differ). - In-frame: PASS before and after. - Harnesses: - `server_entities`: 25 identical. - `lan`: 462 cases. - `dedicated_server`: 592 lines. - `server_dimension_players`: 22 lines. - `cargo fmt --check`: clean. - `cargo clippy --workspace --all-targets -D warnings`: clean. - `cargo test -p horizon-client --lib lan::`: 28 passed. CI parity covers the rest. Needs Ludovic: nothing. 🤖 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:43 +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#2867
No description provided.