float y { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

The y property of the Rotation struct represents the Y component of the quaternion rotation. This component, along with the X, Z, and W components, defines the rotation in 3D space.

Usage

Use the y property to access or modify the Y component of a Rotation instance. This is typically used when you need to directly manipulate the quaternion values for advanced rotation calculations or when interfacing with systems that require quaternion input.

Example

// Example of accessing the Y component of a Rotation
Rotation rotation = Rotation.Identity;
float yComponent = rotation.y;

// Example of setting the Y component of a Rotation
rotation.y = 0.5f;