ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. isVector

Function

isVector

Server and clientMath, vectors and matricesTrilogy Hub only

Checks whether a value is a vector (Vector2, Vector3 or Vector4).

Syntax

bool isVector(mixed value)

Arguments

valuemixed
The value.

Returns

true for a vector.

Example

print(isVector(getDirectionFromRotation(90)))  -- true
print(isVector({ 1, 2, 3 }))       -- false