Skip to content

Initial Release

Choose a tag to compare

@bi0qaw bi0qaw released this 25 Oct 14:36
· 14 commits to master since this release

Creating a new vector:

[new] vector [(from|at|to)] %number%,[ ]%number%(,[ ]| and )%number%
[new] vector from yaw %number% and pitch %number%
vector (of|from|to) %location%
%location%['s] vector
vector (from|between) %location% (to|and) %location%
random vector
[new] cylindrical vector [from|with] [radius] %number%, [yaw] %number%(,| and) [height] %number%
[new] spherical vector [from|with] [radius] %number%, [yaw] %number%(,| and) [pitch] %number%

Vector arithmetic:

%vector% ++ %vector%
%vector% -- %vector%
%vector% ** %vector%
%vector% // %vector%

Note: Locations and numbers are automatically converted to vectors!
The following syntaxes are all valid:

set {_v} to vector 1, 2, 3 // 5
set {_v} to player ++ vector 1, 2, 3
set {_v} to (attacker ++ victim) // 2

Getting a vector from a location:

vector (of|from|to) %location%

Converting a vector to a location:

%vector% [to location] [in] %world%
location (from|of) %vector% [(from|in)] %world%
%vector% [to location] [in] %world% with yaw %number% and pitch %number%
location (from|of) %vector% [(in|from)] %world% with yaw %number% and pitch %number%

Properties of vectors:

(x|y|z) of %vector%
vector (yaw|pitch) of %vector%
length of %vector%
%vector%['s] length%
squared length of %vector%
%vector%['s] squared length

Rotating a vector:

rotate %vector% around %vector% by %number% [degrees]
rotate %vector% around (x|y|z)(-| )axis by %number% [degrees]

Some other expressions:

angle between %vector% and %vector%
normalize %vector%
%vector% normalized
%vector% cross %vector%
%vector% dot %vector%