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

modify_contents item modifier can create overstacked items

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • 24w18a
    • 1.20.5 Pre-Release 1
    • None
    • Confirmed
    • Commands, Items
    • Normal
    • Platform

      Summary
      modify_contents item modifier can create overstacked items inside a container, like a shulker box. (The overstacked item can then be spawned by burning the dropped shulker box.) Also note that overstacked items no longer crash the game.

      Steps to Reproduce

      1. Get a shulker box with one item
        /give @s minecraft:shulker_box[minecraft:container=[{item:{id:stone},slot:0}]]
        
      2. Run the following command
        /item modify entity @s hotbar.0 {function:modify_contents,modifier:{function:set_count,count:99},component:container}
        

      Expected Result
      Shulker box does not have one stack of 99 stones.

      Actual Result
      Shulker box has one stack of 99 stones.

            Dat12 [Mojang] etanaratsastaja
            apple502j apple502j
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: