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

No Durability Loss on Formerly Stackable Items given Max Damage

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Works As Intended
    • None
    • 1.21 Pre-Release 4
    • None
    • Confirmed
    • (Unassigned)

      When you give the max_damage component to an item that normally stacks by removing the max_stack_size component, the durability doesn't decrease when attacking mobs.

      How to reproduce:

      1. RunĀ /give @s paper[max_damage=20,damage=1,!max_stack_size]
      2. Go into survival and attack a mob
      3. Note that the durability remains the same
      4. Run /give @s iron_pickaxe[max_damage=20,damage=1,!max_stack_size]
      5. Try attacking with the new item
      6. Durability decreases

      Right now this means that the max_damage component is somewhat useless when making custom weapons, since having to base them off already damageable weapons creates other issues (like 2x damage and special interactions when based on non-sword items and sweeping when based on swords)

            Unassigned Unassigned
            Immodial Immodial
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: