Phaser API Documentation

  Version: 
setFollowOffset([x], [y])

Description:

Sets the horizontal and vertical offset of the camera from its follow target. The values are subtracted from the targets position during the Cameras update step.

Parameters:

name type arguments description
x number <optional>

The horizontal offset from the camera follow target.x position.

y number <optional>

The vertical offset from the camera follow target.y position.

Returns:
Description:

This Camera instance.

Since: 3.9.0
Source: src/cameras/2d/Camera.js (Line 637)