Giveable¶
文档版本:1.21.50.25
Defines sets of items that can be used to trigger events when used on this entity. The item will also be taken and placed in the entity's inventory.
架构¶
giveable:
{
object "triggers" : opt
{
number "cooldown" : opt
array "items" : opt
{
descriptor "<any array element>"
}
event_object "on_give"
}
}
triggers:object- Defines sets of items that can be used to trigger events when used on this entity. The item will also be taken and placed in the entity's inventory.
triggerscooldown:number- An optional cool down in seconds to prevent spamming interactions.
items:array- The list of items that can be given to the entity to place in their inventory.
items<any array element>:descriptor- An items that can be given to the entity to place in their inventory.
item:identifier
item:object- An object that describes an item.
itemtags:0- [UNDOCUMENTED] A Molang expression ran against item or block to match.
item_tag:string- [UNDOCUMENTED] A tag to lookup item or block by.
on_give:event_object- Event to fire when the correct item is given.