minecraft:repairable for you with a switch.Get GodCraftOverview
minecraft:repairable is an item component: it goes in the components object of a custom item. Lists which items can fix this one in an anvil and how much durability each repair gives back. Needs minecraft:durability.
Fields
| Field | Type | Default | Description |
|---|---|---|---|
repair_items | Repair[] | none | Entries with the repair items and an optional repair_amount (a number or Molang) of durability restored. |
Example
Inside the components object of BP/items/<name>.json (values are the defaults or placeholders):
BP/items/<name>.json
{
"minecraft:repairable": {
"repair_items": []
}
}