Files
minecraft-bedrock-json-schemas/source/behavior/items/format/components/on_use.json
DW623 d3a8c7a4a4 Add Item Examples (#182)
Add Examples to Item Components from MS-Learn Website
2023-08-17 20:04:39 +02:00

26 lines
799 B
JSON

{
"$id": "blockception.minecraft.behavior.items.minecraft:on_use",
"title": "On Use",
"description": "The on_use item component allows you to receive an event when the item is used.",
"type": "object",
"additionalProperties": false,
"required": ["on_use"],
"properties": {
"on_use": {
"title": "On Use",
"description": "Event trigger for when the item is used.",
"type": "object",
"additionalProperties": false,
"properties": {
"event": { "type": "string", "title": "Event", "description": "Event trigger for when the item is used."},
"target": { "type": "string", "title": "Target", "description": "Event Target.", "enum": ["self"] }
}
}
},
"examples": [
{
"on_use": "minecraft:entity_transformed"
}
]
}