Phaser API Documentation

  Version: 

Member of: Phaser.Curves.Line

getTangent([t], [out])

Description:

Gets the slope of the line as a unit vector.

Parameters:

name type arguments description
t number <optional>

The relative position on the line, [0..1].

out Phaser.Math.Vector2 <optional>

A vector to store the result in.

Returns:
Description:

The tangent vector.

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