Phaser API Documentation

scrollX: number


The horizontal scroll position of this Camera.

Change this value to cause the Camera to scroll around your Scene.

Alternatively, setting the Camera to follow a Game Object, via the startFollow method, will automatically adjust the Camera scroll values accordingly.

You can set the bounds within which the Camera can scroll via the setBounds method.

Default: 0
Since: 3.0.0