Arma 3 Scripting

vectorDotProduct

  • Arma 3 v1.22

Command · Markdown · JSON · original wiki page

Description

Dot product of two 3D vectors.

Note

Since Arma 3 v2.14: Since Arma 3 v2.14 any count of numbers is valid, but both arrays must be same length.

Before Arma 3 v2.14, the first argument had to be vector 3D, or Arma 3 v2.00 2D (With z coordinate defaulted to 0)

Syntax

vector1 vectorDotProduct vector2

Parameters:

Returns: Number

Examples

Example 1

_dot = [1,0,1] vectorDotProduct [0,0,2];

See also

vectorAdd · vectorDiff · vectorCrossProduct · vectorCos · vectorMagnitude · vectorMagnitudeSqr · vectorMultiply · vectorDistance · vectorDistanceSqr · vectorDir · vectorUp · setVectorDir · setVectorUp · setVectorDirAndUp · vectorNormalized · vectorFromTo · matrixMultiply · matrixTranspose