Vector3

class Varwin.Vector3
class Varwin.Vector3(x: float, y: float, z: float)

Bases: object

Represents a three-dimensional vector.

X: float
Y: float
Z: float
static Dot(left: Vector3, right: Vector3) Vector3

Calculates the dot product of two vectors

Example:

result = Varwin.Vector3.Dot(Varwin.Vector3(1,0,0), Varwin.Vector3(1,0,0))
static Cross(left: Vector3, right: Vector3) Vector3

Calculates the cross product of two vectors.

Example:

result = Varwin.Vector3.Cross(Varwin.Vector3(1,0,0), Varwin.Vector3(1,0,0))
static Distance(left: Vector3, right: Vector3) float

Calculates the distance between two vectors.

Example:

result = Varwin.Vector3.Distance(Varwin.Vector3(1,0,0), Varwin.Vector3(1,0,0))
static Rotate(vector: Vector3, eulerAngles: Vector3) Vector3

Rotates the vector around a specified axis by a given angle (in euler angles).

Example:

result = Varwin.Vector3.Rotate(Varwin.Vector3(1,0,0), Varwin.Vector3(1,0,0))
property Normalized: Vector3

Returns a normalized version of the vector (unit vector).

Example:

result = instance.Normalized
property Magnitude: float

Gets the magnitude (length) of the vector.

Example:

result = instance.Magnitude