Struct AnimationHelper
Helper to handle animation progress
Properties
| Name | Type | Description |
elapsed[get]
|
long | returns time elapsed since start
|
finished[get]
|
bool | Returns true if animation is finished
|
interval[get]
|
long | get current time interval
|
interval[set]
|
long | override current time interval, retaining the same progress %
|
progress[get]
|
int | Returns animation progress in interval 0..maxProgress while timeElapsed is between 0 and maxInterval; when interval exceeded, progress is maxProgress
|
Methods
| Name | Description |
animate
(time)
|
Adds elapsed time; returns animation progress in interval 0..maxProgress while timeElapsed is between 0 and maxInterval; when interval exceeded, progress is maxProgress
|
getProgress
(maxProgress)
|
Returns animation progress in interval 0..maxProgress while timeElapsed is between 0 and maxInterval; when interval exceeded, progress is maxProgress
|
restart
()
|
restart with same max interval and progress
|
start
(maxInterval, maxProgress)
|
start new animation interval
|