Class: RotationComponent
Defined in: common/components/rotation-component.ts:7
Component to represent the rotation of an entity in 2D space.
Implements
Constructors
Constructor
new RotationComponent(
degrees
):RotationComponent
Defined in: common/components/rotation-component.ts:20
Creates an instance of RotationComponent.
Parameters
degrees
number
The rotation angle in degrees.
Returns
RotationComponent
Example
const rotation = new RotationComponent(90);
console.log(rotation.radians); // 1.5708 (approximately)
Properties
name
name:
symbol
Defined in: common/components/rotation-component.ts:8
The unique name of the component.
Implementation of
radians
radians:
number
Defined in: common/components/rotation-component.ts:9
symbol
readonly
static
symbol: typeofsymbol
Defined in: common/components/rotation-component.ts:11