Phaser API Documentation

  Version: 
getProgress()

Description:

Returns a number between 0 and 1 representing the progress of this Timeline.

A value of 0 means the Timeline has just started, 0.5 means it's half way through, and 1 means it's complete.

If the Timeline has no events, or all events have been removed, this will return 1.

If the Timeline is paused, this will return the progress value at the time it was paused.

Note that the value returned is based on the number of events that have been completed, not the 'duration' of the events (as this is unknown to the Timeline).

Returns:
Description:

A number between 0 and 1 representing the progress of this Timeline.

Type:
  • number
Since: 3.60.0
Source: src/time/Timeline.js (Line 564)