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

Container Item Component Doesn't Work with Containers that aren't Shulker Boxes

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • None
    • 24w09a
    • None
    • Confirmed
    • (Unassigned)

      When using a give command to give yourself a chest with a container component the contents of that component are not set to the chest when placed.

      /give @s minecraft:chest[minecraft:container=[{slot:0,item:{id:"minecraft:dirt"}}]]

      gives a chest that won't have a dirt block inside it when placed

      /give @s minecraft:shulker_box[minecraft:container=[{slot:0,item:{id:"minecraft:dirt"}}]]

      gives a shulker box that will have a dirt block when placed

      Other components can be used across many items as long as it's applicable

            gegy1000 [Mojang] Gegy
            bayugoon LPT4
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: