TimerComp
:The timer component.
group
Component Types
maxLoopsPerFrame
: numberThe maximum number of loops per frame allowed, to keep loops with sub-frame intervals from freezing the game.
wait
(time: number, action?: () => void): TimerControllerRun the callback after n seconds.
loop
(time: number, action: () => void, maxLoops?: number, waitFirst?: boolean): TimerControllerRun the callback every n seconds. If waitFirst is false (the default), the function will be called once on the very next frame, and then loop like normal.
since
v3000.0
tween
(from: V, to: V, duration: number, setValue: (value: V) => void, easeFunc?: (t: number) => number): TweenControllerTweeeeen! Note that this doesn't specifically mean tweening on this object's property, this just registers the timer on this object, so the tween will cancel with the object gets destroyed, or paused when obj.paused is true.
since
v3000.0