世界修改
damage只读
beta
is只读
max只读
type静态
只读
component世界修改
可选
unbreakingEnchantmentLevel: number耐久魔咒等级,在计算损坏概率时受到此参数的影响。
传入的 unbreakingEnchantmentLevel
参数必须介于 [0, 3]。
Unbreaking factor to consider in factoring the damage chance. Incoming unbreaking parameter must be within the range [0, 3].
使用时的最大损坏概率。
世界修改
表示物品耐久组件。当出现在物品上时,表示该物品可以在使用中受到损坏。 注意,只能在数驱物品上获取和使用该组件。
When present on an item, this item can take damage in the process of being used. Note that this component only applies to data-driven items.
示例: giveHurtDiamondSword.ts