Vector 
s
c
#

3D Vector class.
x: float
y: float
z: float
__add(bVector): Vector
s
c
#

Overloaded +. Adds vectors together.
__div(bVector): Vector
s
c
#

Overloaded /. Divides vectors.
__eq(bVector): bool
s
c
#

Overloaded ==. Tests for Equality.
__len(): float
s
c
#

Overloaded # returns the length of the vector.
__mul(bVector | float): Vector
s
c
#

Overloaded * returns the vectors multiplied together. Can also be used to multiply with scalars.
__sub(bVector): Vector
s
c
#

Overloaded -. Subtracts vectors.
__tostring(): string
s
c
#

Overloaded .. Converts vectors to strings.
__unm(): Vector
s
c
#

Overloaded - operator. Reverses the vector.
Cross(bVector): Vector
s
c
#

Cross product of two vectors.
Dot(bVector): float
s
c
#

Dot product of two vectors.
Length(): float
s
c
#

Length of the Vector.
Length2D(): float
s
c
#

Length of the Vector in the XY plane.
Normalized(): Vector
s
c
#

Returns the vector normalized.
Lerp(bVector, tfloat): Vector
s
c
#

  • t - Interpolant
  • Linearly interpolates between two vectors. This is most commonly used to find a point some fraction of the way along a line between two endpoints. Same as `this + (b - this) * t`.