Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-276732

Colors will carry over from item ID to target model

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • 24w45a
    • 24w37a
    • None
    • Community Consensus
    • Commands, Textures and models
    • Normal
    • Platform

      The bug

      If an item that Minecraft applies color to is assigned a different model via components, the colours associated with the item ID will be applied to the target model, even if the target model has its own specified colours (or, in the case of generated-type item models, no colours specified at all).

      How to reproduce

      /give @s pig_spawn_egg[item_model="minecraft:birch_leaves"]

      Expected results

      Since birch leaves usually appear green, this item would appear green as well.

      Actual results

      Pink birch leaves.

      How to fix

      Colours should be associated with the item model in question, rather than the item ID. The hardcoded colours for things like spawn eggs, as well as the item forms of grass blocks, short/tall grass, ferns, large ferns, oak/birch/spruce/jungle/acacia/dark oak/mangrove leaves, vines and lily pads, should have this colour specified in the associated item model file (via a newly implemented parameter) rather than hardcoded. This way, the colour would not carry over from the base item ID (and would be far more customizable via resource packs).

      For items such as potions, leather armor and firework stars, the color could be pointed to some built-in special cases rather than fixed color values.

        1. 2024-09-15_17.19.37.png
          237 kB
          Connor Steppie
        2. image-2024-09-15-21-58-21-979.png
          491 kB
          BugTracker

            boq [Mojang] Bartosz Bok
            Awesoman3000 Connor Steppie
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: