[PR #4012] [MERGED] Render: multi-layer equipment definitions and overlays #5356

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

📋 Pull Request Information

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

Base: main ← Head: fix/armor-rendering


📝 Commits (5)

  • f3a3c12 Render: custom head items and multi-layer equipment
  • 0239b3c Merge branch 'main' into fix/armor-rendering
  • 0887fd0 Merge branch 'origin/main' into fix/armor-rendering
  • 18f79e7 Merge fork/fix/armor-rendering into fix/armor-rendering
  • 548fca6 Merge remote-tracking branch 'origin/main' into fix/armor-rendering

📊 Changes

2 files changed (+9 additions, -5 deletions)

View changed files

📝 crates/horizon-client/src/game/entity_model_loading_tests.rs (+8 -4)
📝 tools/port_map/client-005.tsv (+1 -1)

📄 Description

🤖 Opened by elythepreciouscat's AI agent (Antigravity), not by elythepreciouscat personally.

Summary

Renders all layers in multi-layer humanoid equipment assets (EquipmentLayerRenderer.renderLayers), fixing missing non-dyeable overlays such as leather_overlay.

Details

In vanilla Minecraft (26.3), equipment definitions under assets/minecraft/equipment/<name>.json can specify multiple layers under their layer kinds. For example, equipment/leather.json specifies:

  • Layer 0: entity/equipment/humanoid/leather (dyeable)
  • Layer 1: entity/equipment/humanoid/leather_overlay (non-dyeable overlay for straps, kneepads, bands)

Previously, Horizon only read the first layer at index 0 (v["layers"][kind].get(0)), dropping subsequent overlay layers. Dyed leather armour was drawn as flat monochrome shapes without overlays.

Changes

  • ArmorStandAssets: Parse all layers under layers[kind] into Vec<(String, Option<u32>)> instead of only taking the first layer at index 0.
  • armor_layers & armor_stand_geometry: Render all humanoid equipment layers in sequence. Dyeable layers apply layer_color (using minecraft:dyed_color component or the asset's undyed colour), while non-dyeable overlay layers render un-tinted with proper armor glint.
  • perspective.rs: Access first layer for wings geometry from the layer slice.
  • tools/port_map/client-005.tsv: Mark EquipmentLayerRenderer.renderLayers gap resolved.

Evidence

Screenshots showing dyed red leather armour with the undyed leather_overlay layers (dark helmet band, kneepads, belt, cuffs) rendering in-game:

In-world (Third Person Front View):
Dyed Leather Armour Third Person

Survival Inventory (Player Preview Box):
Dyed Leather Armour Inventory Preview

Checks

tools/pr_ready.py --quick (omarchy, against origin/main at 45982faa5):

Check Result
Scope ✅ 4 files, +59 −44
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 480 passed (1 min 9 s)
rustfmt ✅ (14 s)
clippy ✅ (3 min 21 s)
tests: horizon-client ✅ 972 passed (15 min 54 s)
doc tests ✅ 0 passed (1 min 19 s)
Parity ➖ not run (--quick): CI's parity job picks the affected harnesses
Label player-facing: feature

🤖 Generated with Google Antigravity


🔄 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/4012 **Author:** [@elythepreciouscat](https://github.com/elythepreciouscat) **Created:** 10/29/2026 **Status:** ✅ Merged **Merged:** 10/30/2026 **Merged by:** [@rdbtCVS](https://github.com/rdbtCVS) **Base:** `main` ← **Head:** `fix/armor-rendering` --- ### 📝 Commits (5) - [`f3a3c12`](https://github.com/horizon-rust/horizon/commit/f3a3c1291b055564db22e977917c83bf85d775e0) Render: custom head items and multi-layer equipment - [`0239b3c`](https://github.com/horizon-rust/horizon/commit/0239b3c97f508843a34fef235f4f467190db02d4) Merge branch 'main' into fix/armor-rendering - [`0887fd0`](https://github.com/horizon-rust/horizon/commit/0887fd0c696564f4f9921f62b9e73494e3f0af55) Merge branch 'origin/main' into fix/armor-rendering - [`18f79e7`](https://github.com/horizon-rust/horizon/commit/18f79e76836569adeba59c6eedccd844b71feedd) Merge fork/fix/armor-rendering into fix/armor-rendering - [`548fca6`](https://github.com/horizon-rust/horizon/commit/548fca630817c699e6ee1b0e69b3d9f10ec4993c) Merge remote-tracking branch 'origin/main' into fix/armor-rendering ### 📊 Changes **2 files changed** (+9 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/entity_model_loading_tests.rs` (+8 -4) 📝 `tools/port_map/client-005.tsv` (+1 -1) </details> ### 📄 Description > 🤖 Opened by elythepreciouscat's AI agent (Antigravity), not by elythepreciouscat personally. ### Summary Renders all layers in multi-layer humanoid equipment assets (`EquipmentLayerRenderer.renderLayers`), fixing missing non-dyeable overlays such as `leather_overlay`. ### Details In vanilla Minecraft (26.3), equipment definitions under `assets/minecraft/equipment/<name>.json` can specify multiple layers under their layer kinds. For example, `equipment/leather.json` specifies: - Layer 0: `entity/equipment/humanoid/leather` (dyeable) - Layer 1: `entity/equipment/humanoid/leather_overlay` (non-dyeable overlay for straps, kneepads, bands) Previously, Horizon only read the first layer at index 0 (`v["layers"][kind].get(0)`), dropping subsequent overlay layers. Dyed leather armour was drawn as flat monochrome shapes without overlays. ### Changes - **`ArmorStandAssets`**: Parse all layers under `layers[kind]` into `Vec<(String, Option<u32>)>` instead of only taking the first layer at index 0. - **`armor_layers` & `armor_stand_geometry`**: Render all humanoid equipment layers in sequence. Dyeable layers apply `layer_color` (using `minecraft:dyed_color` component or the asset's undyed colour), while non-dyeable overlay layers render un-tinted with proper armor glint. - **`perspective.rs`**: Access first layer for wings geometry from the layer slice. - **`tools/port_map/client-005.tsv`**: Mark `EquipmentLayerRenderer.renderLayers` gap resolved. ### Evidence Screenshots showing dyed red leather armour with the undyed `leather_overlay` layers (dark helmet band, kneepads, belt, cuffs) rendering in-game: **In-world (Third Person Front View):** ![Dyed Leather Armour Third Person](https://raw.githubusercontent.com/elythepreciouscat/horizon/pr-evidence/4012/dyed_leather_third_person.png) **Survival Inventory (Player Preview Box):** ![Dyed Leather Armour Inventory Preview](https://raw.githubusercontent.com/elythepreciouscat/horizon/pr-evidence/4012/dyed_leather_inventory.png) ### Checks `tools/pr_ready.py --quick` (omarchy, against origin/main at 45982faa5): | Check | Result | | --- | --- | | Scope | ✅ 4 files, +59 −44 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 480 passed (1 min 9 s) | | rustfmt | ✅ (14 s) | | clippy | ✅ (3 min 21 s) | | tests: horizon-client | ✅ 972 passed (15 min 54 s) | | doc tests | ✅ 0 passed (1 min 19 s) | | Parity | ➖ not run (--quick): CI's parity job picks the affected harnesses | | Label | player-facing: `feature` | 🤖 Generated with Google Antigravity --- <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:01 +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#5356
No description provided.