The z
property represents the Z component of a Vector4
structure. It is a single-precision floating-point value that can be accessed or modified to represent the third dimension in a 4D vector.
The z
property represents the Z component of a Vector4
structure. It is a single-precision floating-point value that can be accessed or modified to represent the third dimension in a 4D vector.
To access or modify the Z component of a Vector4
instance, use the z
property. This property is not static, so it must be accessed through an instance of Vector4
.
// Example of accessing and modifying the z component of a Vector4 // Create a new Vector4 instance Vector4 vector = new Vector4(); // Set the z component vector.z = 5.0f; // Access the z component float zValue = vector.z; // Output the z component // Note: Use a logging system or UI element to display the value // Example: Log.Info($"Z Component: {zValue}");