float y { get; set; }

robot_2Generated
code_blocksInput

Description

The y property represents the Y component of a Rotation in the Sandbox game engine. This component is part of the quaternion representation of the rotation, which includes the X, Y, Z, and W components. The Y component is crucial for defining the orientation of an object in 3D space.

Usage

To access or modify the Y component of a Rotation object, you can use the y property directly. This property is a float and can be both read and written to.

Example

// Example of accessing and modifying the Y component of a Rotation
Rotation rotation = new Rotation();

// Access the Y component
float currentY = rotation.y;

// Modify the Y component
rotation.y = 0.5f;