var1 isEqualTo var2

Operand types

var1: Anything
var2: Anything

Type of returned value

Description

Performs strict comparison between var1 and var2 and returns true if equal otherwise false.

NOTE:
Can not compare objects, only values.

Used In

Arma3

Example

// compare arrays
_arr1 = [1,[2,[3]]];
_arr2 = [1,[2,[3]]];
if (_arr1 isEqualTo _arr2) then {hint "Arrays match!"};

// strings
_str1 = "Hello World!";
_str2 = "Hello World";
hint str(_str1 isEqualTo _str2); // returns false
Search OFPEC COMREF