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

Item modifiers that change the count to 0 don't completely remove the item

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Fixed
    • 20w46a
    • 20w48a
    • None
    • Confirmed
    • Data Packs
    • Important

    Description

      The bug

      When subtracting from the count of an item with /item ... modify and it reaches 0, it isn't completely removed. This happens both on entities and containers.

      How to reproduce

      1. Add the data pack MC-205627.zip to the world and /reload
      2. Place any item in the first hotbar slot
      3. /item entity @s hotbar.0 modify test:remove_count
      4. /item entity @s hotbar.0 modify test:add_count
      5. Notice that the original item is back. If you had relogged between step 3 and 4 this would have failed.

      Attachments

        Activity

          People

            boq [Mojang] Bartosz Bok
            Misoloo [Helper] Misode
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              CHK: