mojira.dev
MC-278983

The "glider" Item Component ignores the Unbreaking Enchantment

The glider item component always consumes the same amount of durability from the item it's applied to when gliding even if it's enchanted with the unbreaking enchantment. I.e. it ignores the enchantment's durability consumption.

Example Item:

/give @p diamond_chestplate[glider={},enchantments={levels:{"minecraft:unbreaking":3}}] 1

Attachments

Comments 1

The Unbreaking enchantment is less likely to prevent durability reduction for armor than for other items, according to its definition: 

...
    "minecraft:item_damage": [
      {
        "effect": {
          "type": "minecraft:remove_binomial",
          "chance": {
            "type": "minecraft:fraction",
            "denominator": {
              "type": "minecraft:linear",
              "base": 10,
              "per_level_above_first": 5
            },
            "numerator": {
              "type": "minecraft:linear",
              "base": 2,
              "per_level_above_first": 2
            }
          }
        },
        "requirements": {
          "condition": "minecraft:match_tool",
          "predicate": {
            "items": "#minecraft:enchantable/armor"
          }
        }
      },
      {
        "effect": {
          "type": "minecraft:remove_binomial",
          "chance": {
            "type": "minecraft:fraction",
            "denominator": {
              "type": "minecraft:linear",
              "base": 2,
              "per_level_above_first": 1
            },
            "numerator": {
              "type": "minecraft:linear",
              "base": 1,
              "per_level_above_first": 1
            }
          }
        },
        "requirements": {
          "condition": "minecraft:inverted",
          "term": {
            "condition": "minecraft:match_tool",
            "predicate": {
              "items": "#minecraft:enchantable/armor"
            }
          }
        }
      }
    ]
...

In your video, you can see that when wearing the diamond chestplate, the enchantment did prevent durability reduction once, which shows the enchantment is working. If you try this with the elytra or any item that is not armor (you can make it equippable with the equippable component), you will notice that the enchantment prevents durability reduction much more often. This is not a bug.

E_T_31

(Unassigned)

Unconfirmed

Commands, Enchantments

1.21.4

Retrieved