[GH-ISSUE #541] [gui interactions] Item name rarity colour: enchanted items stay white, rare/epic items not coloured #162

Closed
opened 2026-11-02 15:36:54 +07:00 by bsakaguchi · 3 comments
Owner

Originally created by @ludovic111 on GitHub (Oct 16, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/541

Reported on Discord by u_patrick in #horizon-bugs (2026-10-16), r2026.10.16.05.

Steps: creative, take an iron sword, enchant it with Sharpness; look at a trident, enchanted golden apple, mace.
Horizon: the enchanted sword's name is white.
Vanilla 26.3: item names use the rarity colour (ItemStack.getStyledHoverName → Rarity): common white, uncommon yellow, rare aqua, epic light purple. Enchanting raises the rarity one step (common → rare, rare → epic), so an enchanted iron sword is aqua, a trident (rare) is aqua and turns light purple when enchanted, and the mace and the enchanted golden apple are epic. This applies to tooltips, the hotbar's selected-item name and item frames.

Originally created by @ludovic111 on GitHub (Oct 16, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/541 Reported on Discord by u_patrick in #horizon-bugs (2026-10-16), r2026.10.16.05. **Steps:** creative, take an iron sword, enchant it with Sharpness; look at a trident, enchanted golden apple, mace. **Horizon:** the enchanted sword's name is white. **Vanilla 26.3:** item names use the rarity colour (`ItemStack.getStyledHoverName` → `Rarity`): common white, uncommon yellow, rare aqua, epic light purple. Enchanting raises the rarity one step (common → rare, rare → epic), so an enchanted iron sword is aqua, a trident (rare) is aqua and turns light purple when enchanted, and the mace and the enchanted golden apple are epic. This applies to tooltips, the hotbar's selected-item name and item frames.
bsakaguchi 2026-11-02 15:36:54 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@ludovic111 commented on GitHub (Oct 17, 2026):

Checked on main (ef3cd644): this is fixed by Online5277's #547 (commit 8f86098a, shipped in v2026.10.17.04), which r2026.10.16.05 predates.

  • The Creative tab drew a plain white name for the hovered item before #547; it now uses the same stack_tooltip as every other screen, whose name colour comes from item_tooltip::rarity (ItemStack.getRarity: the item's minecraft:rarity component, then enchanted common/uncommon -> rare, rare -> epic).
  • The hotbar's selected-item name already used that rarity (covered by the hud harness's held-name cases).
  • Defaults come from vanilla's own item components: trident rare (aqua; enchanted: light purple), mace epic, iron sword common (enchanted: aqua). One correction to the report: in 26.3 the enchanted golden apple's rarity is rare (aqua), not epic.
  • Item frames show only custom names, through getHoverName without the rarity style, as in vanilla.

Please retest on v2026.10.17.04 or later; if a name is still white, say which screen.

<!-- gh-comment-id:6230610295 --> @ludovic111 commented on GitHub (Oct 17, 2026): Checked on main (ef3cd644): this is fixed by Online5277's #547 (commit 8f86098a, shipped in v2026.10.17.04), which r2026.10.16.05 predates. - The Creative tab drew a plain white name for the hovered item before #547; it now uses the same `stack_tooltip` as every other screen, whose name colour comes from `item_tooltip::rarity` (`ItemStack.getRarity`: the item's `minecraft:rarity` component, then enchanted common/uncommon -> rare, rare -> epic). - The hotbar's selected-item name already used that rarity (covered by the `hud` harness's held-name cases). - Defaults come from vanilla's own item components: trident rare (aqua; enchanted: light purple), mace epic, iron sword common (enchanted: aqua). One correction to the report: in 26.3 the enchanted golden apple's rarity is `rare` (aqua), not epic. - Item frames show only custom names, through `getHoverName` without the rarity style, as in vanilla. Please retest on v2026.10.17.04 or later; if a name is still white, say which screen.
Author
Owner

@rdbtCVS commented on GitHub (Oct 17, 2026):

Cam confirm it matches vanilla, this issue can be closed.

<!-- gh-comment-id:6236655997 --> @rdbtCVS commented on GitHub (Oct 17, 2026): Cam confirm it matches vanilla, this issue can be closed.
Author
Owner

@ludovic111 commented on GitHub (Oct 18, 2026):

🤖 Agent: closed as fixed by Online5277's #547 (v2026.10.17.04), as described above and confirmed against vanilla by rdbtCVS. Rechecked on main 24bcef42: an enchanted trident's name is light purple in the Creative tab tooltip, enchanted books are aqua (their base rarity is rare).

<!-- gh-comment-id:6255246367 --> @ludovic111 commented on GitHub (Oct 18, 2026): 🤖 Agent: closed as fixed by Online5277's #547 (v2026.10.17.04), as described above and confirmed against vanilla by rdbtCVS. Rechecked on main 24bcef42: an enchanted trident's name is light purple in the Creative tab tooltip, enchanted books are aqua (their base rarity is rare).
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#162
No description provided.