# Angles

Euler angles. Unlike a [Rotation](/api/Rotation), Euler angles can represent multiple revolutions (rotations) around an axis,
but suffer from issues like gimbal lock and lack of a defined "up" vector. Use [Rotation](/api/Rotation) for most cases.

- Kind: struct
- Assembly: `Sandbox.System`
- Modifiers: sealed

## Constructors

- [`Angles`](/api/Angles/.ctor): Initializes the angles object with given components.

## Fields

- [`pitch`](/api/Angles/pitch): The pitch component, typically up/down.
- [`roll`](/api/Angles/roll): The roll component, basically rotation around the axis.
- [`yaw`](/api/Angles/yaw): The yaw component, typically left/right.
- [`Zero`](/api/Angles/Zero): An angle constant that has all its values set to 0. Use this instead of making a static 0,0,0 object yourself.

## Properties

- [`Forward`](/api/Angles/Forward): The forward direction vector for this angle.
- [`Normal`](/api/Angles/Normal): Returns normalized version of this object, meaning the angle on each axis is normalized to range of (-180,180].
- [`Random`](/api/Angles/Random): Returns the angles of a uniformly random rotation.

## Methods

- [`AngleVector`](/api/Angles/AngleVector): Converts an angle to a forward vector.
- [`AsVector3`](/api/Angles/AsVector3): Return as a Vector3, where x = pitch etc
- [`ClampAngle`](/api/Angles/ClampAngle): Clamps the angle to range of [0, 360)
- [`Clamped`](/api/Angles/Clamped): Returns clamped version of this object, meaning the angle on each axis is transformed to range of [0,360).
- [`IsNearlyZero`](/api/Angles/IsNearlyZero): Returns true if this angles object's components are all nearly zero with given tolerance.
- [`Lerp`](/api/Angles/Lerp): Performs linear interpolation on the two given angle objects.
- [`LerpTo`](/api/Angles/LerpTo): Performs linear interpolation on the two given angle objects.
- [`NormalizeAngle`](/api/Angles/NormalizeAngle): Normalizes the angle to range of (-180, 180]
- [`Parse`](/api/Angles/Parse): Given a string, try to convert this into an angles object. The format is "p,y,r".
- [`SnapToGrid`](/api/Angles/SnapToGrid): Snap to grid
- [`ToRotation`](/api/Angles/ToRotation): Converts these Euler angles to a rotation. The angles will be normalized.
- [`TryParse`](/api/Angles/TryParse)
- [`WithPitch`](/api/Angles/WithPitch): Returns this angles object with given pitch component.
- [`WithRoll`](/api/Angles/WithRoll): Returns this angles object with given roll component.
- [`WithYaw`](/api/Angles/WithYaw): Returns this angles object with given yaw component.
