Phaser API Documentation

  Version: 
getRelativeOffset(value, base)

Description:

Parses the relative offset value, returning a positive or negative number.

Parameters:

name type description
value string

The relative offset, in the format of '-=500', for example. The first character determines whether it will be a positive or negative number. Spacing matters here.

base number

The value to use as the offset.

Returns:
Description:

The parsed offset value.

Type:
  • number
Examples:
Since: 3.0.0
Source: src/tweens/Timeline.js (Line 435)