[PR #1407] [MERGED] Server players: breath and golden hearts follow the server, absorption is saved, Nether lava pushes harder #3495

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

📋 Pull Request Information

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

Base: main ← Head: fix/server-air-absorption


📝 Commits (2)

  • 7acebba Server players: the HUD's bubbles and golden hearts follow the server, absorption is saved, Nether lava pushes harder
  • f949f08 Merge remote-tracking branch 'origin/main' into fix/server-air-absorption

📊 Changes

12 files changed (+214 additions, -7 deletions)

View changed files

📝 crates/horizon-client/src/attribute_updates.rs (+5 -0)
📝 crates/horizon-client/src/game.rs (+1 -0)
📝 crates/horizon-client/src/game/agent.rs (+2 -0)
📝 crates/horizon-client/src/game/lan.rs (+3 -0)
📝 crates/horizon-client/src/game/lan_actions.rs (+6 -0)
📝 crates/horizon-client/src/game/remote.rs (+27 -4)
📝 crates/horizon-client/src/lan/guest.rs (+9 -0)
📝 crates/horizon-client/src/lan/hub.rs (+24 -1)
📝 crates/horizon-client/src/lan/playerdata.rs (+7 -0)
📝 crates/horizon-client/src/motion.rs (+2 -0)
📝 crates/horizon-client/src/save.rs (+9 -1)
📝 tools/lan_e2e.py (+119 -1)

📄 Description

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

What

rdbt's server-player HUD issues, on the server thread (the default single-player mode) and for LAN guests:

  • #1304 The breath meter now follows the server's air supply. The server sends Entity.DATA_AIR_SUPPLY_ID, and the connected client's tick sets the helmet's Respiration as the window's own tick does.
  • #1306 The golden hearts show: the server sends Player.DATA_PLAYER_ABSORPTION_ID and the client applies it.
  • #1307 AbsorptionAmount is written from the live body and read back on load, both for the window's world and for a server's players.
  • #1309 Nether lava pushes as hard as vanilla's: the connected client's tick sets FAST_LAVA in the Nether.

Fixes #1304, Fixes #1306, Fixes #1307, Fixes #1309

Why

The client drew the player's air and absorption from its own simulation, which a server's players don't run. The values never reached it.

How tested

tools/lan_e2e.py adds three checks: absorption, breath and lava. All three pass in both modes (default and --server-thread).

The same checks fail on main:

  • On the server thread: the HUD shows absorption 0 while the server has 5, and air -2/0 while the server has 225/238. Lava gives vx 0.00467.
  • In the in-frame mode: the guest has absorption 0 and air -2.

#1307 was tested with a probe that saves and reopens the world, in both modes. The player had absorption 5 and health 20 before saving, the same after reopening, and absorption 0 / health 19 after a 6-damage hit. Main has no absorption in the agent state, so there is no baseline number for it; the gap is the one rdbt reported.

Self-check

One integration commit: origin/main 357dceb9 with all six of this batch's branches merged (hud, contact, guest, spawn, items, knockback; tools/lan_e2e.py taken from the first side where they conflict). tools/pr_ready.py on the Mac mini:

pr_ready (tools/pr_ready.py on ludovics-mac-mini, against origin/main at 357dceb99, 70 min 26 s)

Check Result
Scope ⚠️ 27 files, +1327 −68; 1139 lines of code: over 500, split it if it can ship in parts
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ❌ 292 run, FAILED (errors=2) (14 s)
rustfmt ✅ (4 s)
clippy ✅ (25 s)
tests: horizon-client, horizon-world ✅ 1382 passed (3 min 25 s)
doc tests ✅ 0 passed (2 s)
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ❌ 313 affected, 312 passed, failed: chat_screen (66 min 10 s)
Label player-facing: feature if players get something new, no label for a fix (release-now if urgent)

chat_screen (1 of 3021 chat screens, the input cursor drawn on one frame) is unrelated to this batch, which touches no chat code: tools/test_chat_screen_parity.py passed twice when rerun on the same tree ("chat screen parity ok").

The Python test errors are the two that fail on main on macOS (test_parity_runner OracleReuse: java exit 127, test_rust_parity: /private/var vs /var paths).

Merging this batch

These PRs are now a chain: #1407 → #1408 → #1409 → #1410 → #1411 → #1412 → #1416 (#1308, beds). #1407 has main merged in, and each later branch merges the one before it (merge commits only), with the tools/lan_e2e.py conflicts resolved: both sides' checks kept, the shared helpers once, and every def checked with the AST against its source branch. Merge them in that order. Until the earlier ones merge, each PR also shows their commits.

On the top branch (#1416), every new check passes in both modes: absorption breath lava contacts shield deathmining worldspawn drops underwater beds minecarts levels. clippy is clean. #1408 also gained a test fix: the contacts sneaking case now sneaks before landing on the magma and reads the health before Shift is released.

What needs Ludovic

Nothing beyond review and merge.

🤖 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/1407 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/23/2026 **Status:** ✅ Merged **Merged:** 10/23/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/server-air-absorption` --- ### 📝 Commits (2) - [`7acebba`](https://github.com/horizon-rust/horizon/commit/7acebbae45fb84ec7c905e05f4ac4e4220914d0b) Server players: the HUD's bubbles and golden hearts follow the server, absorption is saved, Nether lava pushes harder - [`f949f08`](https://github.com/horizon-rust/horizon/commit/f949f08488fc42b3283c20f843c45f604cf09aa0) Merge remote-tracking branch 'origin/main' into fix/server-air-absorption ### 📊 Changes **12 files changed** (+214 additions, -7 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/attribute_updates.rs` (+5 -0) 📝 `crates/horizon-client/src/game.rs` (+1 -0) 📝 `crates/horizon-client/src/game/agent.rs` (+2 -0) 📝 `crates/horizon-client/src/game/lan.rs` (+3 -0) 📝 `crates/horizon-client/src/game/lan_actions.rs` (+6 -0) 📝 `crates/horizon-client/src/game/remote.rs` (+27 -4) 📝 `crates/horizon-client/src/lan/guest.rs` (+9 -0) 📝 `crates/horizon-client/src/lan/hub.rs` (+24 -1) 📝 `crates/horizon-client/src/lan/playerdata.rs` (+7 -0) 📝 `crates/horizon-client/src/motion.rs` (+2 -0) 📝 `crates/horizon-client/src/save.rs` (+9 -1) 📝 `tools/lan_e2e.py` (+119 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. ## What rdbt's server-player HUD issues, on the server thread (the default single-player mode) and for LAN guests: - **#1304** The breath meter now follows the server's air supply. The server sends `Entity.DATA_AIR_SUPPLY_ID`, and the connected client's tick sets the helmet's Respiration as the window's own tick does. - **#1306** The golden hearts show: the server sends `Player.DATA_PLAYER_ABSORPTION_ID` and the client applies it. - **#1307** `AbsorptionAmount` is written from the live body and read back on load, both for the window's world and for a server's players. - **#1309** Nether lava pushes as hard as vanilla's: the connected client's tick sets `FAST_LAVA` in the Nether. Fixes #1304, Fixes #1306, Fixes #1307, Fixes #1309 ## Why The client drew the player's air and absorption from its own simulation, which a server's players don't run. The values never reached it. ## How tested `tools/lan_e2e.py` adds three checks: `absorption`, `breath` and `lava`. All three pass in both modes (default and `--server-thread`). The same checks fail on main: - On the server thread: the HUD shows absorption 0 while the server has 5, and air -2/0 while the server has 225/238. Lava gives vx 0.00467. - In the in-frame mode: the guest has absorption 0 and air -2. #1307 was tested with a probe that saves and reopens the world, in both modes. The player had absorption 5 and health 20 before saving, the same after reopening, and absorption 0 / health 19 after a 6-damage hit. Main has no absorption in the agent state, so there is no baseline number for it; the gap is the one rdbt reported. ### Self-check One integration commit: origin/main 357dceb9 with all six of this batch's branches merged (hud, contact, guest, spawn, items, knockback; `tools/lan_e2e.py` taken from the first side where they conflict). `tools/pr_ready.py` on the Mac mini: **pr_ready** (`tools/pr_ready.py` on ludovics-mac-mini, against origin/main at 357dceb99, 70 min 26 s) | Check | Result | | --- | --- | | Scope | ⚠️ 27 files, +1327 −68; 1139 lines of code: over 500, split it if it can ship in parts | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ❌ 292 run, FAILED (errors=2) (14 s) | | rustfmt | ✅ (4 s) | | clippy | ✅ (25 s) | | tests: horizon-client, horizon-world | ✅ 1382 passed (3 min 25 s) | | doc tests | ✅ 0 passed (2 s) | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ❌ 313 affected, 312 passed, failed: chat_screen (66 min 10 s) | | Label | player-facing: `feature` if players get something new, no label for a fix (`release-now` if urgent) | `chat_screen` (1 of 3021 chat screens, the input cursor drawn on one frame) is unrelated to this batch, which touches no chat code: `tools/test_chat_screen_parity.py` passed twice when rerun on the same tree ("chat screen parity ok"). The Python test errors are the two that fail on main on macOS (`test_parity_runner` OracleReuse: java exit 127, `test_rust_parity`: /private/var vs /var paths). ### Merging this batch These PRs are now a chain: #1407 → #1408 → #1409 → #1410 → #1411 → #1412 → #1416 (#1308, beds). #1407 has main merged in, and each later branch merges the one before it (merge commits only), with the `tools/lan_e2e.py` conflicts resolved: both sides' checks kept, the shared helpers once, and every def checked with the AST against its source branch. Merge them in that order. Until the earlier ones merge, each PR also shows their commits. On the top branch (#1416), every new check passes in both modes: `absorption breath lava contacts shield deathmining worldspawn drops underwater beds minecarts levels`. clippy is clean. #1408 also gained a test fix: the `contacts` sneaking case now sneaks before landing on the magma and reads the health before Shift is released. ### What needs Ludovic Nothing beyond review and merge. 🤖 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:57 +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#3495
No description provided.