Module: time

Time API.
Source:

Summary

Methods

Detailed Description

Methods

animate(from, to, timeout, anim_cb) → {Number}

Animate value.
Parameters:
Name Type Description
from Number Value to animate from
to Number Value to animate to
timeout Number Period of time to animate the value
anim_cb anim_callback Animation callback
Returns:
Animator ID
Type
Number
Source:

clear_animation(id)

Clear the animation.
Parameters:
Name Type Description
id Number Animator ID
Source:

clear_timeout(id)

Clear the timeout.
Parameters:
Name Type Description
id Number Timeout ID
Source:

get_timeline() → {Number}

Get the engine's timeline (number of seconds after engine's initialization).
Returns:
Timeline
Type
Number
Source:

set_timeout(callback, time) → {Number}

Set a new timeout. this method has the same behavior as window.setTimeout(), except it uses engine's timeline.
Parameters:
Name Type Description
callback timeout_callback Timeout callback
time Number Timeout
Returns:
Timeout ID
Type
Number
Source: