Vector3 Inverse { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

Returns the inverse of this vector, which is useful for scaling vectors. Keep in mind this returns a Vector3 and not a Vector3Int.

Usage

To use the Inverse property, simply access it from an instance of Vector3Int. This will provide a Vector3 where each component is the reciprocal of the corresponding component in the original vector, assuming the component is not zero.

Example

Vector3Int myVector = new Vector3Int(2, 3, 4);
Vector3 inverseVector = myVector.Inverse;
// inverseVector is now (0.5, 0.3333, 0.25)