StaticconsumeThe player whose item durability will be consumed.
Optionaloptions: ConsumeDurabilityOptionsThe options for consuming durability.
OptionalbreakSound?: stringWhether to suppress playing a sound when item breaks. Defaults to "random.break". If set to an empty string, no sound will be played.
OptionalignoreCreative?: booleanWhether to ignore player's gamemode and consume durability anyways.
OptionalignoreEnchantments?: booleanWhether to ignore enchantments when consuming durability.
Optionalslot?: EquipmentSlotThe slot to consume durability from. Defaults to the player's main hand.
Optionalvalue?: numberThe amount of durability to consume. Defaults to 1.
True if the durability was consumed, false otherwise.
StaticgetReturns the chance to consume durability from item based on the unbreaking level.
The unbreaking level of the item.
The chance to consume durability from item based on the unbreaking level.
Consumes durability from the player's selected item.