Phaser API Documentation

  Version: 
setGravityX(x)

Description:

Set the gravitational force to be applied to the X axis. Value can be positive or negative. Larger values result in a stronger effect.

Parameters:

name type description
x number

The gravitational force to be applied to the X-axis.

Returns:
Description:

This Game Object.

Since: 3.0.0