VectorLength
int VectorLength (int x, int y)
Usage
Returns the length of the vector (x,y).
Parameters
- x, y: Coordinates of the end point of the vector.
Return value
Length of the vector (x,y).
Examples
Here is a quick example to use it with three dimensions:
function int VLength3d(int x, int y, int z) { int len = VectorLength(x, y); len = VectorLength(z, len); return len; }
See Also
- distance (Similar function for versions older than r3883.)
This article is issued from Zdoom. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.