Phaser API Documentation

  Version: 

Member of: Phaser.Curves.Line

getPointAt(u, [out])

Description:

Gets a point at a given position on the line.

Parameters:

name type arguments description
u number

The position along the curve to return. Where 0 is the start and 1 is the end.

out Phaser.Math.Vector2 <optional>

A Vector2 object to store the result in. If not given will be created.

Returns:
Description:

The coordinates of the point on the curve. If an out object was given this will be returned.

Examples:
Since: 3.0.0
Source: src/curves/LineCurve.js (Line 160)