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

Inconsistent results when an item that checks for a player holder_type is in a GUI or menu screen

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Awaiting Response
    • None
    • 24w46a
    • Windows 11, Java 21
    • Confirmed
    • (Unassigned)

       
      When using an item model that changes based off the holder_type property checking for a player, the result is very inconsistent between various GUIs and screens in the game that render or hold items.  Below is a table documenting the different screens/GUIs, whether or not items within them are considered as held by a player, whether or not this seems intended or correct, and any additional notes on the behavior. 

       

      Screen/GUI Considered as held
      by a player?
      Likely to be correct? Additional notes
      Toasts No Yes  
      Advancements No Yes  
      Statistics No Yes  
      World Creation No Yes  
      Gamemode Switcher Yes No Seems likely to be incorrect based on the other non-block UI screen behaviors.  Not a tangible item, cannot be held.
      Recipe Book Tabs No Yes Intangible item, cannot be held.
      Creative Menu tabs Yes No Inconsistent with the recipe book tabs and other intangible items.
      Recipe Book recipes Sometimes Mixed results
      • Recipes with a single item displayed in the slot are not considered player held.
      • Recipe slots with 2 stacked items treat the top as not player held and the bottom as player held.  This one is the weirdest case on this list.
      • The crafting grids in the expanded recipe previews for items with many recipes are treated as player held.  This is consistent with the behavior for the full size grids, but unknown if intended, as these items are intangible.
      Crafting Table/Crafter input slots Yes Uncertain1  
      Crafting Table/Crafter output slots No Uncertain1 These are the only two cases where an output slot is not considered player held.  
      Missing ingredient recipe displays No Yes Not a tangible item, seems likely to be correct.
      All Anvil slots Yes Uncertain1  
      All Brewing Stand slots Yes Uncertain1  
      Beacon payment slot Yes Uncertain1  
      Beacon payment example items Yes No Not a tangible item, so unable to be held.
      All Furnace, Blast Furnace, and Smoker slots Yes Uncertain1  
      All Loom slots Yes Uncertain1  
      All Smithing Table slots Yes Uncertain1  
      All Cartography Table slots Yes Uncertain1  
      All Grindstone slots Yes Uncertain1  
      Stonecutter Yes Mixed Results The selectable recipes are not tangible items, but the input and output slots should follow note 1.  Currently all three are considered player held.
      Items in Container blocks, such as Chests, Barrels, and Shulker boxes Yes Uncertain2  
      Items in the equipment/storage slots of Horses, Mules, Donkeys, and Llamas Yes Uncertain2  
      Items in the Bundle tooltip/preview Yes Uncertain, likely No This one is a weird case because the item inside of the bundle isn't being held, the bundle is.  
      Villager/Wandering Trader trades list No Yes These items are unaffected by checking if the holder type is a Villager/Wandering Trader, but this may be intended depending on how note 1 is treated.
      Villager/Wandering Trader input/output slots Yes Uncertain1  

      1 - Entirely depends on if items placed in GUI slots still being considered as player held is intended behavior.  If it is, then only crafting output slots are incorrect.

      2 - Depends on if storage/container slots are intended to be treated differently from workstation GUI slots, due to the ability to close the gui and store the item permanently in the slot, unlike the ones covered by note 1.

       

      Attached are screenshots of the cases listed in the chart.  The item model being an apple means that it is considered player held, and the item model being a potato means that it is not.  The resource pack used to test this is also attached - various random items were used to test the different cases, so refer to the files at assets/minecraft/items to see which are changed.

        1. advancements.png
          advancements.png
          32 kB
        2. anvil.png
          anvil.png
          4 kB
        3. beacon.png
          beacon.png
          4 kB
        4. brewing_stand.png
          brewing_stand.png
          4 kB
        5. cartography_table.png
          cartography_table.png
          7 kB
        6. container.png
          container.png
          9 kB
        7. crafting.png
          crafting.png
          4 kB
        8. creative_tab.png
          creative_tab.png
          2 kB
        9. expanded_recipes.png
          expanded_recipes.png
          7 kB
        10. furnace.png
          furnace.png
          4 kB
        11. gamemode_switcher.png
          gamemode_switcher.png
          49 kB
        12. grindstone.png
          grindstone.png
          4 kB
        13. loom.png
          loom.png
          6 kB
        14. missing_ingredients.png
          missing_ingredients.png
          5 kB
        15. mount.png
          mount.png
          14 kB
        16. player_held_testing-1.zip
          9 kB
        17. recipe_book.png
          recipe_book.png
          30 kB
        18. smithing_table.png
          smithing_table.png
          10 kB
        19. stats.png
          stats.png
          165 kB
        20. stonecutter.png
          stonecutter.png
          15 kB
        21. toast.png
          toast.png
          13 kB
        22. trades.png
          trades.png
          16 kB
        23. world_creation.png
          world_creation.png
          156 kB

            Unassigned Unassigned
            CarterJohnson374 Carter Johnson
            Votes:
            4 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: