Class LM_Vector2

Version added: before 9.5
The LM_Vector2 class is used to represent a 2D vector or point.

Methods:

Name Returns Description Ver
Cross LM_Vector3 Added in version 11.1 11.1
Dot real Computes the dot product of this vector and a second one < 9.5
GetOrthogonal LM_Vector2 Returns a vector that points 90 degrees away from the orignal vector < 9.5
Mag real Computes the magnitude of a vector < 9.5
Norm LM_Vector2 Returns a normalized copy of the vector < 9.5
NormMe void Normalizes a vector < 9.5
operator* LM_Vector2 Multiplies a vector by a number, returning the result as a new vector < 9.5
operator/ LM_Vector2 Divides a vector by a number, returning the result as a new vector < 9.5
operator‑ LM_Vector2 Subtracts one vector from another and returns the result as a new vector < 9.5
operator+ LM_Vector2 Adds two vectors and returns the result as a new vector < 9.5
Rotate void Rotates the vector by the specified angle < 9.5
Set void Set the value of a vector < 9.5
Set void Set the value of a vector < 9.5
SquaredMag real Computes the squared magnitude of a vector < 9.5

Properties:

Name Type Description Ver
x real The x (or horizontal) coordinate of the vector. < 9.5
y real The y (or vertical) coordinate of the vector. < 9.5