Arma 3 Scripting

BIS_fnc_unitVector

  • Arma 3 v0.50
  • First in Arma 2 v1.00

Function · Markdown · JSON · original wiki page

Description

Unit Vector

Returns the unit vector for the passed vector (vector pointing in the same direction, but with magnitude == 1) This does not modify the original array. The array can have any number of elements (2, 3, etc).

Syntax

Returns:

Function header

The comment at the top of the function's file in the game; this page's description come from it.

/*
    Unit Vector

Returns the unit vector for the passed vector (vector pointing
in the same direction, but with magnitude == 1)
This does not modify the original array.
The array can have any number of elements (2, 3, etc).
*/