Phaser API Documentation

  Version: 

Member of: Phaser.Math

<static> Rotate(point, angle)

Description:

Rotate a given point by a given angle around the origin (0, 0), in an anti-clockwise direction.

Parameters:

name type description
point object | Phaser.Geom.Point

The point to be rotated.

angle number

The angle to be rotated by in an anticlockwise direction.

Returns:
Description:

The given point, rotated by the given angle in an anticlockwise direction.

Examples:
Since: 3.0.0
Source: src/math/Rotate.js (Line 7)