Timer¶
文档版本:1.21.50.25
Adds a timer after which an event will fire.
架构¶
timer:
{
boolean "looping" : opt
boolean "randomInterval" : opt
array "time" : opt
{
number "0..0" : opt
number "1..1" : opt
}
number "time" : opt
event_object "time_down_event"
array "random_time_choices" : opt
{
object "<any array element>" : opt
{
integer "weight" : opt
integer "value" : opt
}
}
}
looping
:boolean- If true, the timer will restart every time after it fires.
randomInterval
:boolean- If true, the amount of time on the timer will be random between the Minimum and Maximum values specified in time.
time
:array- Amount of time in seconds for the timer. Can be specified as a number or a pair of numbers (Minimum and max). Incompatible with random_time_choices.
time
0..0
:number
1..1
:number
time
:number- Amount of time in seconds for the timer. Can be specified as a number or a pair of numbers (Minimum and max). Incompatible with random_time_choices.
time_down_event
:event_object- Event to fire when the time on the timer runs out.
random_time_choices
:array- This is a list of objects, representing one value in seconds that can be picked before firing the event and an optional weight. Incompatible with time.
random_time_choices
<any array element>
:object- representing one value in seconds that can be picked before firing the event and an optional weight. Incompatible with time.
<any array element>
weight
:integer- The weight on how likely this section is to trigger.
value
:integer- The value in seconds that would be used if this section was picked.