Phaser API Documentation

  Version: 
Filter
This is a beta release of our new docs system. Found an issue?
Please tell us about it in the #📖-newdocs-feedback channel on the Phaser Discord
Namespace: Elastic
Phaser.Math.Easing.Elastic

Methods

<static> In(v, [amplitude], [period])
Focus
Focus

Description:

Elastic ease-in.

Parameters:

name type arguments Default description
v number

The value to be tweened.

amplitude number <optional> 0.1

The amplitude of the elastic ease.

period number <optional> 0.1

Sets how tight the sine-wave is, where smaller values are tighter waves, which result in more cycles.

Returns:
Description:

The tweened value.

Type:
  • number
Examples:
Since: 3.0.0
Focus
Focus
<static> InOut(v, [amplitude], [period])
Focus
Focus

Description:

Elastic ease-in/out.

Parameters:

name type arguments Default description
v number

The value to be tweened.

amplitude number <optional> 0.1

The amplitude of the elastic ease.

period number <optional> 0.1

Sets how tight the sine-wave is, where smaller values are tighter waves, which result in more cycles.

Returns:
Description:

The tweened value.

Type:
  • number
Examples:
Since: 3.0.0
Focus
Focus
<static> Out(v, [amplitude], [period])
Focus
Focus

Description:

Elastic ease-out.

Parameters:

name type arguments Default description
v number

The value to be tweened.

amplitude number <optional> 0.1

The amplitude of the elastic ease.

period number <optional> 0.1

Sets how tight the sine-wave is, where smaller values are tighter waves, which result in more cycles.

Returns:
Description:

The tweened value.

Type:
  • number
Examples:
Since: 3.0.0
Focus
Focus