[PR #3359] [MERGED] Invisible armor stands: draw their equipment, and send their names to clients #4925

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

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/3359
Author: @hamza-cskn
Created: 10/28/2026
Status: ✅ Merged
Merged: 10/29/2026
Merged by: @levzzz5154

Base: main ← Head: fix/invisible-armor-stands


📝 Commits (2)

  • 835674f Draw an invisible armor stand's equipment, not just skip it
  • 0e2b244 Send an armor stand's custom name and its visibility to its clients

📊 Changes

2 files changed (+32 additions, -13 deletions)

View changed files

📝 crates/horizon-client/src/game/armor_stands.rs (+14 -13)
📝 crates/horizon-client/src/game/lan_entities.rs (+18 -0)

📄 Description

🤖 Opened by hamza-cskn's AI agent (Claude Code), not by hamza-cskn. Found and checked in game by hamza-cskn.

What and why

Invisible armor stands lose their equipment, and their hologram text doesn't reach a server's clients.

  1. Renderer (game/armor_stands.rs): an invisible stand was skipped whole. Vanilla's LivingEntityRenderer.submit gives an invisible stand no body render type but still submits its layers (shouldRenderLayers returns true and ArmorStandRenderer doesn't override it): held items, the custom head, the armour. Now only the wooden body is skipped. Players see this on any server that sends the invisible flag (vanilla, Paper, Minestom) and in-frame: floating heads, item displays and armour on invisible stands don't show at all.
  2. Server (game/lan_entities.rs): DATA_CUSTOM_NAME and DATA_CUSTOM_NAME_VISIBLE were never sent for an armor stand, so hologram text didn't show for the server thread's window, LAN guests or a dedicated server's players. Both are sent now, and go back to none / false when /data removes them.

Relation to #3131

#3131 makes the server send an armor stand's invisible flag (0x20); this PR leaves those lines alone. The two are needed together: with #3131 alone, the server-thread window gets the flag and, without fix 1, draws nothing for an invisible stand. They merge without conflicts (checked locally).

Vanilla reference

net.minecraft.client.renderer.entity.LivingEntityRenderer.submit and shouldRenderLayers, ArmorStandRenderer.getRenderType (26.3 bytecode via javap): the body render type is null for an invisible, non-glowing stand seen by a non-spectator; the layers are submitted regardless.

Checked in game

Three stands on a platform: visible with diamond armour and a sword; invisible with the same; invisible with a glowstone head and a visible CustomName. Screenshots in creative, on an M5 Mac:

Visible stand Invisible + armour + sword Invisible + glowstone + name
main, in-frame body, armour, sword nothing name only
main, server thread body, armour, sword body, armour, sword body, glowstone, no name
this PR, in-frame body, armour, sword armour, sword, no body glowstone, name, no body
this PR, server thread body, armour, sword body, armour, sword (flag: #3131) body, glowstone, name
this PR + #3131, server thread body, armour, sword armour, sword, no body glowstone, name, no body

Not in this PR: a spectator sees invisible bodies translucent in vanilla (isInvisibleToPlayer); Horizon hides them.

Self-check

pr_ready (tools/pr_ready.py --quick on hcoskun, against origin/main at 312218a47, 1 min 21 s)

Check Result
Scope ✅ 2 files, +32 −13
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 399 passed (26 s)
rustfmt ✅ (3 s)
clippy ✅ (14 s)
tests: horizon-client ✅ 1280 passed (32 s)
doc tests ✅ 0 passed (6 s)
content root tests ➖ content root untouched
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ➖ not run (--quick): CI's parity job picks the affected harnesses
Label player-facing: feature if players get something new, no label for a fix (release-now if urgent)

🤖 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/3359 **Author:** [@hamza-cskn](https://github.com/hamza-cskn) **Created:** 10/28/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@levzzz5154](https://github.com/levzzz5154) **Base:** `main` ← **Head:** `fix/invisible-armor-stands` --- ### 📝 Commits (2) - [`835674f`](https://github.com/horizon-rust/horizon/commit/835674f45dcfd4eb68648f2f06430ff196114721) Draw an invisible armor stand's equipment, not just skip it - [`0e2b244`](https://github.com/horizon-rust/horizon/commit/0e2b2441201982472c7823e476f7ad77d213921f) Send an armor stand's custom name and its visibility to its clients ### 📊 Changes **2 files changed** (+32 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/armor_stands.rs` (+14 -13) 📝 `crates/horizon-client/src/game/lan_entities.rs` (+18 -0) </details> ### 📄 Description > 🤖 Opened by hamza-cskn's AI agent (Claude Code), not by hamza-cskn. Found and checked in game by hamza-cskn. ## What and why Invisible armor stands lose their equipment, and their hologram text doesn't reach a server's clients. 1. **Renderer** (`game/armor_stands.rs`): an invisible stand was skipped whole. Vanilla's `LivingEntityRenderer.submit` gives an invisible stand no body render type but still submits its layers (`shouldRenderLayers` returns true and `ArmorStandRenderer` doesn't override it): held items, the custom head, the armour. Now only the wooden body is skipped. Players see this on any server that sends the invisible flag (vanilla, Paper, Minestom) and in-frame: floating heads, item displays and armour on invisible stands don't show at all. 2. **Server** (`game/lan_entities.rs`): `DATA_CUSTOM_NAME` and `DATA_CUSTOM_NAME_VISIBLE` were never sent for an armor stand, so hologram text didn't show for the server thread's window, LAN guests or a dedicated server's players. Both are sent now, and go back to none / false when `/data` removes them. ## Relation to #3131 #3131 makes the server send an armor stand's invisible flag (`0x20`); this PR leaves those lines alone. The two are needed together: with #3131 alone, the server-thread window gets the flag and, without fix 1, draws nothing for an invisible stand. They merge without conflicts (checked locally). ## Vanilla reference `net.minecraft.client.renderer.entity.LivingEntityRenderer.submit` and `shouldRenderLayers`, `ArmorStandRenderer.getRenderType` (26.3 bytecode via `javap`): the body render type is null for an invisible, non-glowing stand seen by a non-spectator; the layers are submitted regardless. ## Checked in game Three stands on a platform: visible with diamond armour and a sword; invisible with the same; invisible with a glowstone head and a visible `CustomName`. Screenshots in creative, on an M5 Mac: | | Visible stand | Invisible + armour + sword | Invisible + glowstone + name | |---|---|---|---| | main, in-frame | body, armour, sword | nothing | name only | | main, server thread | body, armour, sword | body, armour, sword | body, glowstone, no name | | this PR, in-frame | body, armour, sword | armour, sword, no body | glowstone, name, no body | | this PR, server thread | body, armour, sword | body, armour, sword (flag: #3131) | body, glowstone, name | | this PR + #3131, server thread | body, armour, sword | armour, sword, no body | glowstone, name, no body | Not in this PR: a spectator sees invisible bodies translucent in vanilla (`isInvisibleToPlayer`); Horizon hides them. ## Self-check **pr_ready** (`tools/pr_ready.py --quick` on hcoskun, against origin/main at 312218a47, 1 min 21 s) | Check | Result | | --- | --- | | Scope | ✅ 2 files, +32 −13 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 399 passed (26 s) | | rustfmt | ✅ (3 s) | | clippy | ✅ (14 s) | | tests: horizon-client | ✅ 1280 passed (32 s) | | doc tests | ✅ 0 passed (6 s) | | content root tests | ➖ content root untouched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ➖ not run (--quick): CI's parity job picks the affected harnesses | | Label | player-facing: `feature` if players get something new, no label for a fix (`release-now` if urgent) | 🤖 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 05:08:58 +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#4925
No description provided.