Sets how much damage the item can take before breaking, and allows the item to be combined at an anvil, grindstone, or crafting table.
Item Components Durability Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| damage_chance | {"max":100,"min":100} | Damage Chance item | Specifies the percentage chance of this item losing durability. | My Sword Chuck: {"min":10,"max":50}, My Sword Singing: {"min":0,"max":0}, My Sword Weak: {"min":100,"max":100} |
| max_durability | not set | Integer number | Max durability is the amount of damage that this item can take before breaking. This is a required parameter and has a minimum of 0. | Chestplate: 200, My Sword Chuck: 10, My Sword Singing: 1000 |
damage_chance
Specifies the percentage chance of this item losing durability. Default is set to 100. Defined as an int range with min and max value. Check that the limits imposed on the range (minimum, maximum and maximum distance between values) are respected.
Item Components IntRange
Has minimum and maximum integer values.
Item Components IntRange Properties
JSON path: damage_chance
| Name | Default Value | Type | Description |
|---|---|---|---|
| max | 0 | Integer number | |
| min | 0 | Integer number |
Samples
"minecraft:durability": {
"damage_chance": {
"min": 10,
"max": 50
},
"max_durability": 36
}
Chestplate
"minecraft:durability": {
"max_durability": 200
}
My Sword Chuck
"minecraft:durability": {
"damage_chance": {
"min": 10,
"max": 50
},
"max_durability": 10
}
My Sword Singing
"minecraft:durability": {
"damage_chance": {
"min": 0,
"max": 0
},
"max_durability": 1000
}
My Sword Weak
"minecraft:durability": {
"damage_chance": {
"min": 100,
"max": 100
},
"max_durability": 2
}