Vector3 Normal { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

The Normal property of the Vector3Int struct returns a unit vector (a vector with a length of 1) that represents the direction of the original vector. This property is useful for obtaining the direction of a vector without regard to its magnitude. It is important to note that the returned value is a Vector3, not a Vector3Int, as unit vectors typically require floating-point precision.

Usage

To use the Normal property, simply access it from an instance of Vector3Int. This will give you a Vector3 representing the normalized direction of the vector.

Example

Vector3Int vector = new Vector3Int(3, 4, 5);
Vector3 normalizedVector = vector.Normal;
// normalizedVector now holds the unit vector of the original vector