Phaser API Documentation

  Version: 
stopAfterDelay(delay)

Description:

Stops the current animation from playing after the specified time delay, given in milliseconds.

It then dispatches the ANIMATION_STOP event.

If no animation is running, no events will be dispatched.

If there is another animation in the queue (set via the chain method) then it will start playing, when the current one stops.

Parameters:

name type description
delay number

The number of milliseconds to wait before stopping this animation.

Returns:
Description:

This Game Object.

Examples:
Since: 3.50.0