{"updated":"2026-10-12T14:41:15Z","source":"https://community.bistudio.com/wiki/Category:Arma_3:_Scripting_Commands","count":2656,"items":[{"name":"! a","operator":"!","title":"! a","type":"command","url":"https://community.bistudio.com/wiki/!_a","revid":369088,"updated":"2024-09-02T20:37:47Z","groups":["Variables","Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the negation of a Boolean expression. This means `true` becomes `false` and vice versa.","syntaxes":[{"syntax":"! a","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"a: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":"!","left":null,"right":{"text":"a","types":["Boolean"]}}],"examples":[{"text":"The code\n\n```sqf\nprivate _isAlive = alive player;\nif (!_isAlive) then\n{\n    hint \"The player is dead!\";\n};\n```\n\nis the same as\n\n```sqf\nprivate _isAlive = alive player;\nif (not _isAlive) then\n{\n    hint \"The player is dead!\";\n};\n```","code":["private _isAlive = alive player;\nif (!_isAlive) then\n{\n\thint \"The player is dead!\";\n};","private _isAlive = alive player;\nif (not _isAlive) then\n{\n\thint \"The player is dead!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["not"],"see_also":["not","Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"+","operator":"+","title":"+","type":"command","url":"https://community.bistudio.com/wiki/%2B","revid":377977,"updated":"2026-01-19T18:47:06Z","groups":["Math","Arrays","HashMap","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add two Numbers, concatenate two Arrays or two Strings, or create a copy of an Array or HashMap.\n\n> [!WARNING]\n> Array copy methods `ARRAY + []` and `+ ARRAY` have different behaviours:\n> - `ARRAY + []` creates copy of the 1st dimension, but preserves references in other dimensions ([shallow copy](https://en.wikipedia.org/wiki/Object_copying#Shallow_copy)).\n> - `+ ARRAY` clones every element, so if the array is multi-dimensional, the created copy contains no references ([deep copy](https://en.wikipedia.org/wiki/Object_copying#Deep_copy)).\n> See Example 6.","syntaxes":[{"syntax":"numberA + numberB","since":null,"effect":null,"exec":null,"params":[{"name":"numberA","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"numberA: Number"},{"name":"numberB","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"numberB: Number"}],"returns":{"type":"Number","types":["Number"],"description":"the sum of numberA and numberB","text":"Number - the sum of *numberA* and *numberB*"},"form":"binary","operator":"+","left":{"text":"numberA","types":["Number"]},"right":{"text":"numberB","types":["Number"]}},{"syntax":"+ number","since":null,"effect":null,"exec":null,"params":[{"name":"number","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"number: Number"}],"returns":{"type":"Number","types":["Number"],"description":"the value of the parameter number","text":"Number - the value of the parameter *number*"},"form":"unary","operator":"+","left":null,"right":{"text":"number","types":["Number"]}},{"syntax":"arrayA + arrayB","since":null,"effect":null,"exec":null,"params":[{"name":"arrayA","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"arrayA: Array of Anything"},{"name":"arrayB","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"arrayB: Array of Anything"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"a new array filled with arrayA and arrayB elements, in that order","text":"Array of Anything - a new array filled with *arrayA* and *arrayB* elements, in that order"},"form":"binary","operator":"+","left":{"text":"arrayA","types":["Array","Anything"]},"right":{"text":"arrayB","types":["Array","Anything"]}},{"syntax":"stringA + stringB","since":null,"effect":null,"exec":null,"params":[{"name":"stringA","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"stringA: String"},{"name":"stringB","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"stringB: String"}],"returns":{"type":"String","types":["String"],"description":"a string concatenating stringA and stringB","text":"String - a string concatenating *stringA* and *stringB*"},"form":"binary","operator":"+","left":{"text":"stringA","types":["String"]},"right":{"text":"stringB","types":["String"]}},{"syntax":"+ array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"a new instance of the provided array filled with same elements ([deep copy](https://en.wikipedia.org/wiki/Object_copying#Deep_copy))","text":"Array of Anything - a new instance of the provided array filled with same elements ([deep copy](https://en.wikipedia.org/wiki/Object_copying#Deep_copy))"},"form":"unary","operator":"+","left":null,"right":{"text":"array","types":["Array","Anything"]}},{"syntax":"+ hashMap","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"}],"returns":{"type":"HashMap","types":["HashMap"],"description":"a new instance of the provided HashMap filled with the same key-value pairs ([deep copy](https://en.wikipedia.org/wiki/Object_copying#Deep_copy))","text":"HashMap - a new instance of the provided HashMap filled with the same key-value pairs ([deep copy](https://en.wikipedia.org/wiki/Object_copying#Deep_copy))"},"form":"unary","operator":"+","left":null,"right":{"text":"hashMap","types":["HashMap"]}}],"examples":[{"text":"```sqf\n 5 +  3    // returns  8\n-5 + -3    // returns -8\n```","code":[" 5 +  3\t// returns  8\n-5 + -3\t// returns -8"]},{"text":"```sqf\n+  2    // returns  2\n+ -7    // returns -7\n```","code":["+  2\t// returns  2\n+ -7\t// returns -7"]},{"text":"```sqf\n_arrayA = [1,2,3];\n_arrayB = [3,4,5];\n_arrayAB = _arrayA + _arrayB; // _arrayAB = [1,2,3,3,4,5]\n// _arrayA and _arrayB remain unchanged\n```","code":["_arrayA = [1,2,3];\n_arrayB = [3,4,5];\n_arrayAB = _arrayA + _arrayB; // _arrayAB = [1,2,3,3,4,5]\n// _arrayA and _arrayB remain unchanged"]},{"text":"```sqf\n_result = \"Hello\" + \" \" + \"there\"; // \"Hello there\"\n```","code":["_result = \"Hello\" + \" \" + \"there\"; // \"Hello there\""]},{"text":"```sqf\n_arrayA = [1,2,3];\n_arrayB = + _arrayA;\n_arrayB set [0, 99]; // _arrayA = [1,2,3], _arrayB = [99,2,3]\n```","code":["_arrayA = [1,2,3];\n_arrayB = + _arrayA;\n_arrayB set [0, 99]; // _arrayA = [1,2,3], _arrayB = [99,2,3]"]},{"text":"Shallow copy with `ARRAY + []`:\n\n```sqf\nprivate _subArray = [1, 2, 3];\nprivate _array1 = [_subArray, 1, 2, 3];\nprivate _array2 = _array1 + [];\n_array2 select 0 set [0, \"oops\"];\nhint str _subArray; // [\"oops\", 2, 3]\n```\n\nDeep copy with `+ ARRAY`:\n\n```sqf\nprivate _subArray = [1, 2, 3];\nprivate _array1 = [_subArray, 1, 2, 3];\nprivate _array2 = + _array1;\n_array2 select 0 set [0, \"oops\"];\nhint str _subArray; // [1, 2, 3]\n```","code":["private _subArray = [1, 2, 3];\nprivate _array1 = [_subArray, 1, 2, 3];\nprivate _array2 = _array1 + [];\n_array2 select 0 set [0, \"oops\"];\nhint str _subArray; // [\"oops\", 2, 3]","private _subArray = [1, 2, 3];\nprivate _array1 = [_subArray, 1, 2, 3];\nprivate _array2 = + _array1;\n_array2 select 0 set [0, \"oops\"];\nhint str _subArray; // [1, 2, 3]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators","pushBack","append","merge"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Command Group: Math","Command Group: Strings","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"-","operator":"-","title":"-","type":"command","url":"https://community.bistudio.com/wiki/-","revid":377197,"updated":"2026-01-01T11:31:15Z","groups":["Math","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Subtracts numbers or arrays from each another, negates a number. For arrays also see deleteAt and deleteRange.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3 it is possible to subtract nested arrays.","syntaxes":[{"syntax":"numberA - numberB","since":null,"effect":null,"exec":null,"params":[{"name":"numberA","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"numberA: Number"},{"name":"numberB","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"numberB: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":"-","left":{"text":"numberA","types":["Number"]},"right":{"text":"numberB","types":["Number"]}},{"syntax":"- numberA","since":null,"effect":null,"exec":null,"params":[{"name":"numberA","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"numberA: Number"}],"returns":{"type":"Number","types":["Number"],"description":"the negative of numberA","text":"Number - the negative of *numberA*"},"form":"unary","operator":"-","left":null,"right":{"text":"numberA","types":["Number"]}},{"syntax":"arrayA - arrayB","since":null,"effect":null,"exec":null,"params":[{"name":"arrayA","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"arrayA: Array of Anything"},{"name":"arrayB","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"arrayB: Array of Anything"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":null,"text":"Array of Anything"},"form":"binary","operator":"-","left":{"text":"arrayA","types":["Array","Anything"]},"right":{"text":"arrayB","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_result = 10 - 7; // result is 3\n```","code":["_result = 10 - 7; // result is 3"]},{"text":"```sqf\n_numA = 4;\n_numB = -_numA; // result is -4\n_numB = -_numB; // result is  4\n```","code":["_numA = 4;\n_numB = -_numA; // result is -4\n_numB = -_numB; // result is  4"]},{"text":"```sqf\n_result = [1, 2, 2, player, \"String\"] - [2, player, player, \"String\"]; // _result is [1]\n```","code":["_result = [1, 2, 2, player, \"String\"] - [2, player, player, \"String\"]; // _result is [1]"]},{"text":"```sqf\n_result = [0, [0], [[0]]] - [0]; // [[0], [[0]]]\n```","code":["_result = [0, [0], [[0]]] - [0]; // [[0], [[0]]]"]},{"text":"```sqf\n_result = [0, [0], [[0]]] - [[0]];        // [0, [[0]]]    - Since Arma 3\n_result = [0, [0], [[0]]] - [[[0]]];    // [0, [0]]        - Since Arma 3\n```","code":["_result = [0, [0], [[0]]] - [[0]];\t\t// [0, [[0]]]\t- Since Arma 3\n_result = [0, [0], [[0]]] - [[[0]]];\t// [0, [0]]\t\t- Since Arma 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Array","Operators","deleteAt","deleteRange"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a != b","operator":"!=","title":"a != b","type":"command","url":"https://community.bistudio.com/wiki/a_!%3D_b","revid":376993,"updated":"2026-01-01T08:00:36Z","groups":["Variables","Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether one value is **not** equal to another. String comparison is case-**in**sensitive (e.g `\"STRINGtext\" != \"stringTEXT\" // returns false - strings are equivalent`).\n\n> [!IMPORTANT]\n> *a* and *b* types **must** match: comparing e.g String with Number is invalid.","syntaxes":[{"syntax":"a != b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":null,"optional":false,"default":null,"description":"| Introduced in | Possible Type |\n|---|---|\n| Operation Flashpoint v1.00 | Number |\n| Side |  |\n| String |  |\n| Object |  |\n| Group |  |\n| Armed Assault v1.00 | Structured Text |\n| Config |  |\n| Display |  |\n| Control |  |\n| Armed Assault v1.08 | Location |\n| Arma 3 v2.00 | Diary Record |\n| Namespace |  |\n| Boolean |  |","types":[],"since":null,"text":"a:\n\n| Introduced in | Possible Type |\n|---|---|\n| Operation Flashpoint v1.00 | Number |\n| Side |  |\n| String |  |\n| Object |  |\n| Group |  |\n| Armed Assault v1.00 | Structured Text |\n| Config |  |\n| Display |  |\n| Control |  |\n| Armed Assault v1.08 | Location |\n| Arma 3 v2.00 | Diary Record |\n| Namespace |  |\n| Boolean |  |"},{"name":"b","type":"identical to a's type","optional":false,"default":null,"description":null,"types":[],"since":null,"text":"b: identical to *a*'s type"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if a is different from b, false otherwise","text":"Boolean - true if *a* is different from *b*, false otherwise"},"form":"binary","operator":"!=","left":{"text":"a","types":[]},"right":{"text":"b","types":[]}}],"examples":[{"text":"```sqf\nif (_counter != 4) then\n{\n    hint \"The counter is not equal to the number 4\";\n};\n```","code":["if (_counter != 4) then\n{\n\thint \"The counter is not equal to the number 4\";\n};"]},{"text":"```sqf\nif (vehicle player != player) then\n{\n    hint \"you are in a vehicle\";\n}\nelse\n{\n    hint \"you are on foot\";\n};\n```","code":["if (vehicle player != player) then\n{\n\thint \"you are in a vehicle\";\n}\nelse\n{\n\thint \"you are on foot\";\n};"]},{"text":"```sqf\nif (fuel truck1 != 1) then\n{\n    hint \"Truck1 has less than a full tank of fuel.\";\n};\n```","code":["if (fuel truck1 != 1) then\n{\n\thint \"Truck1 has less than a full tank of fuel.\";\n};"]},{"text":"```sqf\nif (alive _unit1 != alive _unit2) then { hint \"One of the units is dead while another is alive\" };\n```","code":["if (alive _unit1 != alive _unit2) then { hint \"One of the units is dead while another is alive\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["==","Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a % b","operator":"%","title":"a % b","type":"command","url":"https://community.bistudio.com/wiki/a_%25_b","revid":318435,"updated":"2022-05-13T07:44:52Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remainder of *a* divided by *b*.","syntaxes":[{"syntax":"a % b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":"%","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n4.5 % 3 // result is 1.5\n```","code":["4.5 % 3 // result is 1.5"]}],"multiplayer":null,"problems":null,"aliases":["mod"],"see_also":["mod","Operators"],"notes":[{"user":"Hoz","date":"2006-04-16T01:34:00Z","text":"- Remainder is calculated in real domain.\n- a % b is identical to mod\nYou can use % to round a decimal number down to the nearest whole number. For example: If you wanted to use the command random to generate a whole number between 0 and 5, you could put this in a script:\n\n```sqf\n_rand = random 6;\n_num = _rand - (_rand % 1);\n```\n\nIn A1, the new commands round, floor or ceil would be the easier way to round."},{"user":"SilentSpike","date":"2015-07-21T14:55:00Z","text":"Be careful when dealing with negative numbers. The way a modulo operation treats negatives differs between languages. In SQF truncated division is used, hence:\n\n```sqf\n-12 % -10 = -2\n-12 %  10 = -2\n 12 % -10 =  2\n 12 %  10 =  2\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a && b","operator":"&&","title":"a && b","type":"command","url":"https://community.bistudio.com/wiki/a_%26%26_b","revid":369259,"updated":"2024-09-03T18:42:01Z","groups":["Variables","Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true only if both conditions are true.\nIn case of the alternative syntax, [lazy evaluation](https://en.wikipedia.org/wiki/Lazy_evaluation#Control_structures) is used - if left operand is false, evaluation of the right side is ignored.","syntaxes":[{"syntax":"booleanA && booleanB","since":null,"effect":null,"exec":null,"params":[{"name":"booleanA","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"booleanA: Boolean - test condition or variable"},{"name":"booleanB","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"booleanB: Boolean - test condition or variable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"&&","left":{"text":"booleanA","types":["Boolean"]},"right":{"text":"booleanB","types":["Boolean"]}},{"syntax":"boolean && code","since":"arma2oa 1.62","effect":null,"exec":null,"params":[{"name":"boolean","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"boolean: Boolean - test condition or variable"},{"name":"code","type":"Code","optional":false,"default":null,"description":"code that once executed returns a Boolean. The code is not evaluated if **boolean** is false.","types":["Code"],"since":null,"text":"code: Code - code that once executed returns a Boolean. The code is not evaluated if **boolean** is false."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"&&","left":{"text":"boolean","types":["Boolean"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nprivate _allEnemiesKilled = true;\nif (alive player && _allEnemiesKilled) then\n{\n    hint \"you win !\";\n};\n```","code":["private _allEnemiesKilled = true;\nif (alive player && _allEnemiesKilled) then\n{\n\thint \"you win !\";\n};"]},{"text":"```sqf\nif ((count _array > 0) && { (_array select 0) == player }) then // an error would be thrown without lazy evaluation\n{\n    hint \"It works!\";\n};\n```","code":["if ((count _array > 0) && { (_array select 0) == player }) then // an error would be thrown without lazy evaluation\n{\n\thint \"It works!\";\n};"]},{"text":"```sqf\nif ((alive player) && { player setDamage 0.5; true }) then // valid AS LONG AS the code block returns a Boolean\n{\n    hint \"It works!\";\n};\n```","code":["if ((alive player) && { player setDamage 0.5; true }) then // valid AS LONG AS the code block returns a Boolean\n{\n\thint \"It works!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["a and b"],"see_also":["and","or","Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a * b","operator":"*","title":"a * b","type":"command","url":"https://community.bistudio.com/wiki/a_*_b","revid":322990,"updated":"2022-06-28T21:42:57Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the value of *a* multiplied by *b*.","syntaxes":[{"syntax":"a * b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":"*","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n_percentage = 0.5 * 100;\n```","code":["_percentage = 0.5 * 100;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators"],"notes":[],"categories":[]},{"name":"a / b","operator":"/","title":"a / b","type":"command","url":"https://community.bistudio.com/wiki/a_/_b","revid":363979,"updated":"2024-04-29T22:53:36Z","groups":["Math","Config"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the quotient of two numbers. If the divisor is 0 a *Division by zero* error is shown but the script does not stop and the result of such division is assumed to be 0.\n\nAlternative syntax returns the Config entry with the given name (alias for >>, slightly slower but with higher precedence).","syntaxes":[{"syntax":"a / b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":"dividend","types":["Number"],"since":null,"text":"a: Number - dividend"},{"name":"b","type":"Number","optional":false,"default":null,"description":"divisor","types":["Number"],"since":null,"text":"b: Number - divisor"}],"returns":{"type":"Number","types":["Number"],"description":"quotient","text":"Number - quotient"},"form":"binary","operator":"/","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}},{"syntax":"config / name","since":"arma1 1.00","effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":null,"form":"binary","operator":"/","left":{"text":"config","types":["Config"]},"right":{"text":"name","types":["String"]}},{"syntax":"","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Config","types":["Config"],"description":"config entry","text":"Config - config entry"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_result = 15 / 3; // result is 5\n```","code":["_result = 15 / 3; // result is 5"]},{"text":"```sqf\n_cfgVehicles = configFile / \"CfgVehicles\"; // identical to configFile >> \"CfgVehicles\" (but the order of precedence)\n```","code":["_cfgVehicles = configFile / \"CfgVehicles\"; // identical to configFile >> \"CfgVehicles\" (but the order of precedence)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators","configFile","missionConfigFile","campaignConfigFile","configName","config greater greater name","count"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-01T00:02:00Z","text":"(Arma 3 1.14) config / name can be composed to config >> name String or Array format via BIS_fnc_configPath. E.g.\n\n```sqf\n[configFile / \"ATMineCrater\" / \"MissileCircleDust\", \"\"] call BIS_fnc_configPath; // return: \"configfile >> \"ATMineCrater\" >> \"MissileCircleDust\"\"\n[configFile / \"ATMineCrater\" / \"MissileCircleDust\", []] call BIS_fnc_configPath; // return: [\"configfile\",\"ATMineCrater\",\"MissileCircleDust\"]\n```"}],"categories":[]},{"name":"a : b","operator":":","title":"a : b","type":"command","url":"https://community.bistudio.com/wiki/a_:_b","revid":329506,"updated":"2022-07-29T13:38:09Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"See switch","syntaxes":[{"syntax":"a : b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Switch Type","optional":false,"default":null,"description":null,"types":["Switch Type"],"since":null,"text":"a: Switch Type"},{"name":"b","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"b: Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":":","left":{"text":"a","types":["Switch Type"]},"right":{"text":"b","types":["Code"]}}],"examples":[{"text":"```sqs\n? (_var == _test) : hint \"_var is equal to _test!\";\n```","code":["? (_var == _test) : hint \"_var is equal to _test!\";"]},{"text":"```sqf\nswitch (_condition) do\n{\n    case 1: { hint \"1\" };\n    case 2: { hint \"2\" };\n    default { hint \"default\" }; // note: NO colon for the default case\n};\n```","code":["switch (_condition) do\n{\n\tcase 1: { hint \"1\" };\n\tcase 2: { hint \"2\" };\n\tdefault { hint \"default\" }; // note: NO colon for the default case\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","switch"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a = b","operator":"=","title":"a = b","type":"command","url":"https://community.bistudio.com/wiki/a_%3D_b","revid":348661,"updated":"2023-11-08T13:49:04Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns the result of expression on the right to the variable on the left. Technically this is not a command and it is not listed in supportInfo; this is more of a compiler instruction.\n\n> [!IMPORTANT]\n> The following structure is invalid: `a = b = c = 4;`.","syntaxes":[{"syntax":"variable = value","since":null,"effect":null,"exec":null,"params":[{"name":"variable","type":"Anything","optional":false,"default":null,"description":"see Identifier","types":["Anything"],"since":null,"text":"variable: Anything - see Identifier"},{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"}],"returns":{"type":null,"types":["Nothing","nil"],"description":null,"text":"Nothing \n\n> [!IMPORTANT]\n> The returned value is not equivalent to nil. See #Notes below for additional information."},"form":"binary","operator":"=","left":{"text":"variable","types":["Anything"]},"right":{"text":"value","types":["Anything"]}}],"examples":[{"text":"```sqf\n_value = 5;\n```","code":["_value = 5;"]},{"text":"```sqf\n_mygroup = group player;\n```","code":["_mygroup = group player;"]},{"text":"```sqf\n_greeting = \"Hello!\";\n```","code":["_greeting = \"Hello!\";"]},{"text":"```sqf\nprivate _enemyTank = myTank1;\n```","code":["private _enemyTank = myTank1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators"],"notes":[{"user":"Kronzky","date":"2006-12-15T05:27:00Z","text":"A conditional assignment can be done via the following syntax:\n\n```sqf\n_msg = if (alive player) then {\"you're alive\"} else {\"you're dead\"}\n```"},{"user":"Alef","date":"2009-06-22T16:27:00Z","text":"It's possible to assign to Numbers. Numbers values are not changed. Useful instead of assigning to *nul* or *nil* when a result is of no use.\n\n```sqf\n[player] execVM \"myScript.sqf\"\n```"},{"user":"Dedmen","date":"2016-11-09T00:29:00Z","text":"This operator actually does not return a Nil. It really returns pure Nothing. Not Nil Nothing.\n\nThis can cause problems. For example:\n\n```sqf\n_var1 = call {\n    _var2 = \"\";\n};\n```\n\nThe return value of the \"call\" is the return value of the \"=\" operator.\n\nIf it were a nil then of cause \"_var = nil;\" would work just fine.\n\nBut in reality this causes a \"Generic Error in expression\" because you can't assign pure Nothing to anything"}],"categories":[]},{"name":"a == b","operator":"==","title":"a == b","type":"command","url":"https://community.bistudio.com/wiki/a_%3D%3D_b","revid":369426,"updated":"2024-09-03T18:48:52Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if *a* is equal to *b*. String comparison is case-**in**sensitive  - use isEqualTo if case sensitivity is needed.\n\n> [!IMPORTANT]\n> *a* and *b* types **must** match: comparing e.g String with Number is invalid.","syntaxes":[{"syntax":"a == b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":null,"optional":false,"default":null,"description":"| Introduced in | Operation Flashpoint v1.00 | Armed Assault v1.00 | Armed Assault v1.08 | Arma 3 v2.00 |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| Possible Type | Number | Side | String | Object | Group | Structured Text | Config | Display | Control | Location | Diary Record | Namespace | Boolean |","types":[],"since":null,"text":"a:\n\n| Introduced in | Operation Flashpoint v1.00 | Armed Assault v1.00 | Armed Assault v1.08 | Arma 3 v2.00 |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| Possible Type | Number | Side | String | Object | Group | Structured Text | Config | Display | Control | Location | Diary Record | Namespace | Boolean |"},{"name":"b","type":"identical to a's type","optional":false,"default":null,"description":null,"types":[],"since":null,"text":"b: identical to *a*'s type"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"==","left":{"text":"a","types":[]},"right":{"text":"b","types":[]}}],"examples":[{"text":"```sqf\nif (player == leader group player) then\n{\n    hint \"You are the leader of your group.\";\n}\nelse\n{\n    hint \"Someone else is the boss\";\n};\n```","code":["if (player == leader group player) then\n{\n\thint \"You are the leader of your group.\";\n}\nelse\n{\n\thint \"Someone else is the boss\";\n};"]},{"text":"```sqf\n\"MyRabbit\" == \"MYRABBIT\"; // returns true\n```","code":["\"MyRabbit\" == \"MYRABBIT\"; // returns true"]},{"text":"```sqf\nif (alive _unit1 == alive _unit2) then { hint \"Both units are either dead or both alive\" };\n```","code":["if (alive _unit1 == alive _unit2) then { hint \"Both units are either dead or both alive\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["a != b","Operators","isEqualTo"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-15T10:13:00Z","text":"For script comparison we need to detect whether scripts are running in advance, then compose both into string:\n\n```sqf\nif (scriptDone _var0) then [{false},{(str _var0) == (str _var1)}];\n```\n\nIt is recommended to use isEqualTo for all types comparison, which is more functional and as fast as operator.\nFor multiple comparisons:\n\n```sqf\nfnc_areEqual = {\n    private [\"_b\", \"_var1\", \"_var2\"];\n    _b = true;\n    for [{ _i = 1 }, { _i < (count _this) && _b }, { _i=_i + 1 }] do {\n        _var1 = _this select (_i-1);\n        _var2 = _this select _i;\n        if (!(_var1 isEqualTo _var2)) then { _b = false; };\n    };\n    _b\n};\n[\"A\",\"a\",\"a\"] call fnc_areEqual; // false\n```\n\nAnd we can use such workaround instead of using BIS_fnc_arrayCompare or BIS_fnc_areEqual"}],"categories":[]},{"name":"a ^ b","operator":"^","title":"a ^ b","type":"command","url":"https://community.bistudio.com/wiki/a_%5E_b","revid":321222,"updated":"2022-05-13T15:37:49Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"*a* raised to the power of *b*","syntaxes":[{"syntax":"a ^ b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":"^","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n5 ^ 2 // 5², result is 25\n```","code":["5 ^ 2 // 5², result is 25"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands","Operators"],"notes":[],"categories":[]},{"name":"a greater b","operator":">","title":"a greater b","type":"command","url":"https://community.bistudio.com/wiki/a_greater_b","revid":318547,"updated":"2022-05-13T09:21:04Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if **a** is greater than **b**, else returns false.","syntaxes":[{"syntax":"a > b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":">","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nif (fuel truck1 > 0) then { hint \"Truck1 has some fuel left.\"; };\n```","code":["if (fuel truck1 > 0) then { hint \"Truck1 has some fuel left.\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a greater= b","operator":">=","title":"a greater= b","type":"command","url":"https://community.bistudio.com/wiki/a_greater%3D_b","revid":318474,"updated":"2022-05-13T08:25:43Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if *a* is greater than or equal to *b*.","syntaxes":[{"syntax":"a >= b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":">=","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nif (fuel truck1 >= 0.5) then { hint \"Truck1 has at least half a tank of fuel left.\" };\n```","code":["if (fuel truck1 >= 0.5) then { hint \"Truck1 has at least half a tank of fuel left.\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators","a less= b","a greater b","a == b","a != b"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a hash b","operator":"#","title":"a hash b","type":"command","url":"https://community.bistudio.com/wiki/a_hash_b","revid":377195,"updated":"2026-01-01T10:56:03Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects an element from an Array, same as select command for arrays, but has higher precedence.\n\n> [!NOTE]\n> **#** has higher precedence than all binary operators, but it has lower precedence than unary operators (see #Example 3).","syntaxes":[{"syntax":"array # index","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":"#","left":{"text":"array","types":["Array","Anything"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n[1, 2, 3, 4] # 2;            // result is 3\n```","code":["[1, 2, 3, 4] # 2;\t\t\t// result is 3"]},{"text":"```sqf\ngetPosASL player # 2;        // result is Z component of player's position\n```","code":["getPosASL player # 2;\t\t// result is Z component of player's position"]},{"text":"```sqf\n// 'getPosASL' is unary; '#' and '+' are binary; precedence is: 'getPosASL' > '#' > '+'\ngetPosASL player # 2 + 1; // equivalent to (getPosASL player # 2) + 1, not (getPosASL player)#(2+1)\n```","code":["// 'getPosASL' is unary; '#' and '+' are binary; precedence is: 'getPosASL' > '#' > '+'\ngetPosASL player # 2 + 1; // equivalent to (getPosASL player # 2) + 1, not (getPosASL player)#(2+1)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["select","selectRandom","selectRandomWeighted","set","resize","reverse","in","find","toArray","toString","forEach","count","deleteAt","deleteRange","append","sort","param","params","splitString","joinString","pushBack","pushBackUnique","apply"],"notes":[{"user":"KC Grimes","date":"2018-04-25T00:51:00Z","text":"Although not alternative syntax, the below notations work as expected:\n\n```sqf\n[\"A\", \"B\", \"C\"] # 1;        // B\n[\"A\", \"B\", \"C\"] #1;            // B\n[\"A\", \"B\", \"C\"]#1;            // B\n[\"A\", \"B\", [\"C\", \"D\"]]#2#0;    // C\n```"},{"user":"7erra","date":"2019-05-03T15:41:00Z","text":"Here is an example of what higher precedence means:\n\n```sqf\n[1, 2, 3, 4] select 2 / 2;        // divides 2 with 2, therefore selects the second element at index 1, result = 2\n[1, 2, 3, 4] select (2 / 2);    // same result with brackets\n[1, 2, 3, 4] # 2 / 2;            // selects third element, then divides by 2 = 1.5\n([1, 2, 3, 4] # 2) / 2;            // same result with brackets\n```\n\nThis operator can not be used in conjunction with the #define preprocessor.\n\n```sqf\n#define SEL_ERR [0,1,2]#0;            // error\n#define SEL_NOERR [0,1,2] select 0;    // works\n```"},{"user":"Fett_li","date":"2021-04-02T16:18:00Z","text":"Beware new-lines when using this operator. I suspect the preprocessor to fail. The following code will not compile without throwing an error:\n\n```sqf\n[0]\n# 0;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"a less b","operator":"<","title":"a less b","type":"command","url":"https://community.bistudio.com/wiki/a_less_b","revid":321224,"updated":"2022-05-13T15:38:27Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if *a* is lesser than *b*.","syntaxes":[{"syntax":"a < b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"<","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n_test = 1 < 2; // true\n```","code":["_test = 1 < 2; // true"]},{"text":"```sqf\n_test = 2 < 1; // false\n```","code":["_test = 2 < 1; // false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"a less= b","operator":"<=","title":"a less= b","type":"command","url":"https://community.bistudio.com/wiki/a_less%3D_b","revid":321223,"updated":"2022-05-13T15:38:11Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if **a** is less than or equal to **b**, else returns false.","syntaxes":[{"syntax":"a <= b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"<=","left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nif (fuel truck1 <= 0) then { hint \"Truck1 has no fuel left.\" };\n```","code":["if (fuel truck1 <= 0) then { hint \"Truck1 has no fuel left.\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands"]},{"name":"a or b","operator":"||","title":"a or b","type":"command","url":"https://community.bistudio.com/wiki/a_or_b","revid":349256,"updated":"2023-11-08T14:51:04Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if one or both conditions are true. In case of the alternative syntax, [lazy evaluation](https://en.wikipedia.org/wiki/Lazy_evaluation#Control_structures) is used. That means that if left operand is true, evaluation of the right side is skipped completely.","syntaxes":[{"syntax":"a || b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"b: Boolean - test condition or variable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"||","left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Boolean"]}},{"syntax":"a || b","since":"arma2oa 1.62","effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Code","optional":false,"default":null,"description":"code that returns Boolean. It is not evaluated if *a* returns true","types":["Code"],"since":null,"text":"b: Code - code that returns Boolean. It is not evaluated if *a* returns true"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":"||","left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Code"]}}],"examples":[{"text":"```sqf\nif (OBJ1 || _enemycount == 0) then { hint \"you win !\" };\n```","code":["if (OBJ1 || _enemycount == 0) then { hint \"you win !\" };"]},{"text":"```sqf\nif (count _array == 0 || { (_array select 0) != player }) then\n{\n    hint \"It works! Without lazy evaluation it would throw an error if array was empty.\";\n};\n```","code":["if (count _array == 0 || { (_array select 0) != player }) then\n{\n\thint \"It works! Without lazy evaluation it would throw an error if array was empty.\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["or"],"see_also":["or","and","Operators"],"notes":[],"categories":[]},{"name":"abs","operator":null,"title":"abs","type":"command","url":"https://community.bistudio.com/wiki/abs","revid":311169,"updated":"2022-05-12T09:59:18Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns absolute (positive) value of a real number.","syntaxes":[{"syntax":"abs x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_n = abs -3; // Returns 3\n```","code":["_n = abs -3; // Returns 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["+","-"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"accTime","operator":null,"title":"accTime","type":"command","url":"https://community.bistudio.com/wiki/accTime","revid":341223,"updated":"2023-05-13T23:19:52Z","groups":["Time"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current simulation acceleration factor.","syntaxes":[{"syntax":"accTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_acc = accTime;\n```","code":["_acc = accTime;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAccTime","setTimeMultiplier","timeMultiplier","useAudioTimeForMoves"],"notes":[{"user":"Hoz","date":"2006-08-02T03:10:00Z","text":"Use setAccTime to change the time acceleration factor. Not to be confused with skipTime."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Time","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"acos","operator":null,"title":"acos","type":"command","url":"https://community.bistudio.com/wiki/acos","revid":378425,"updated":"2026-04-06T21:06:04Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"ArcCosine of a number, result in Degrees","syntaxes":[{"syntax":"acos x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number in range -1..+1","optional":false,"default":null,"description":"any other value returns NaN","types":["Number"],"since":null,"text":"x: Number in range -1..+1 - any other value returns NaN"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_degrees = acos 0.5; // Returns 60\n```","code":["_degrees = acos 0.5; // Returns 60"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["atan","asin","sin","cos","tan"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"action","operator":null,"title":"action","type":"command","url":"https://community.bistudio.com/wiki/action","revid":378568,"updated":"2026-05-08T21:16:17Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Make a unit perform an action. See Category:Actions for action names and syntaxes.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 2.18 it is possible to use actionNow to perform some actions immediately without any animation.\n> However, note that some actions do require animations (for example, opening inventory while on foot), otherwise they will get cancelled.\n\n> [!NOTE]\n> - in singleplayer, when user Alt-Tabs the simulation is paused and so the action will also halt until user returns to the game. For example, `player action [\"GetInDriver\", car];` executed while user is Alt-Tabbed will result in the user seeing the action happening when he returns to the game screen. This does not happen in Multiplayer.\n> - the alternative syntax creates a temporary Logic entity in place of *unit*.","syntaxes":[{"syntax":"unit action actionArray","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"actionArray","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"actionArray: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"actionArray","types":["Array"]}},{"syntax":"action actionArray","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"actionArray","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"actionArray: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"actionArray","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer action [\"SitDown\", player];\n```","code":["player action [\"SitDown\", player];"]},{"text":"```sqf\n_soldier action [\"Eject\", vehicle _soldier];\n```","code":["_soldier action [\"Eject\", vehicle _soldier];"]},{"text":"```sqf\nplayer action [\"UseWeapon\", player, player, 7]; // plays pick up animation before throwing grenade\naction [\"UseWeapon\", player, player, 7]; // normal grenade throw\n```","code":["player action [\"UseWeapon\", player, player, 7]; // plays pick up animation before throwing grenade\naction [\"UseWeapon\", player, player, 7]; // normal grenade throw"]}],"multiplayer":"> [!IMPORTANT]\n> The argument's locality is **usually** local, but some actions can take a global argument (e.g \"Eject\", \"GetOut\", \"GetInXXXX\", \"MoveToXXXX\").\n> See Category:Actions for more details.","problems":null,"aliases":[],"see_also":["actionNow","actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","weaponsInfo","shownAction"],"notes":[{"user":"Tom_48_97","date":"2009-08-28T09:26:00Z","text":"In Arma 2, you can place a unique unit (for example a boat, far of all combats) and use it for all command lines with action."},{"user":"DreadedEntity","date":"2015-03-27T17:57:00Z","text":"This command has no effect when a dead unit is used as input."},{"user":"DrSova","date":"2017-06-27T02:15:00Z","text":"```sqf\nplayer action [\"SWITCHWEAPON\", player, player, -1]\n```\n\nSwitching weapon to the back."},{"user":"Yuval","date":"2017-07-20T12:22:00Z","text":"Some of the actions (such as \"DropWeapon\") do not always execute, and there should be a set of conditions for them to run.\nThe unit must be able to perform the dropping animation in order for the action to properly execute.\nSo, if for example we spawn a unit at [0,0,0] and make it perform a \"DropWeapon\" action - it won't work if [0,0,0] is water (which it is, if the current map is an island) because the unit will be swimming.\n\nAlso, you cannot stack up actions right after the other. If you run a \"DropWeapon\" action when the current action animation is still going - it will not perform.\nThere are a few more conditions for an action to perform, but relying on a hundred percent success of the action is not a good practice."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"actionIDs","operator":null,"title":"actionIDs","type":"command","url":"https://community.bistudio.com/wiki/actionIDs","revid":377718,"updated":"2026-01-02T09:15:47Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"","syntaxes":[{"syntax":"actionIDs entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity with added user actions","types":["Object"],"since":null,"text":"entity: Object - entity with added user actions"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"IDs of all user actions added to given entity with addAction command","text":"Array of Numbers - IDs of all user actions added to given entity with addAction command"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\n_actions = actionIDs player;\n```","code":["_actions = actionIDs player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.64","Scripting Commands","Scripting Commands: Local Effect","Stubs"]},{"name":"actionKeys","operator":null,"title":"actionKeys","type":"command","url":"https://community.bistudio.com/wiki/actionKeys","revid":330779,"updated":"2022-11-01T16:06:07Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Array containing dikCodes of keys, buttons and combos assigned to the given user action. Action names could be found in config class ControllerSchemes or user action names or user profile, for example:\n\n```cpp\nkeyWatch[] = { 24 };\n```\n\nTo retrieve the value, use the property name without 'key':\n\n```sqf\nactionKeys \"Watch\"; // 24\n```\n\nIn addition, some of the actions are also listed in here: inputAction/actions","syntaxes":[{"syntax":"actionKeys userAction","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"userAction","types":["String"]}},{"syntax":"actionKeys [userAction]","since":"Arma3 2.08","effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[userAction]","types":["Array"]}}],"examples":[{"text":"```sqf\n_arrayOfNumbers = actionKeys \"ReloadMagazine\";\n```","code":["_arrayOfNumbers = actionKeys \"ReloadMagazine\";"]},{"text":"From Arma 3 v2.08: \n\n```sqf\n_arrayOfStrings = actionKeys [\"ReloadMagazine\"];\n```","code":["_arrayOfStrings = actionKeys [\"ReloadMagazine\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionKeysNames","actionKeysNamesArray","actionKeysImages","actionName","inputAction","addUserActionEventHandler"],"notes":[{"user":"AgentRev","date":"2016-05-11T02:36:00Z","text":"If an action key is configured with a modifier (e.g. \"Right Ctrl + M\" for \"MiniMapToggle\"), the DIK code returned by this command has a weird value, equivalent to the following:\n\nLeft Ctrl + Key = 486539264 + DIK\nLeft Shift + Key = 704643072 + DIK\nLeft Alt + Key = 939524096 + DIK\nRight Ctrl + Key = -1660944384 + DIK\nRight Shift + Key = 905969664 + DIK\nRight Alt + Key = -1207959552 + DIK</sqf>\n\nThis increases the difficulty of accurately comparing key codes to actionKeys in UI event handlers. Those strange numbers are probably due to bit flags being added to the DIK value by the game engine for easier storage in the ArmaProfile.\n\nIn case of mouse buttons, actionKeys will also return values that are different from those in \"MouseButton\" UI events:\n\nLMB: MouseButton 0 = actionKeys 65536\nRMB: MouseButton 1 = actionKeys 65665 (65536 + 1 + 128)\nMMB: MouseButton 2 = actionKeys 65538 (65536 + 2)\n4MB: MouseButton 3 = actionKeys 65539 (65536 + 3)\n5MB: MouseButton 4 = actionKeys 65540 (65536 + 4)\nThe values above are valid for a right-handed mouse configuration, and may or may not differ for a left-handed config.\n\n*Note edited by R3vo (talk) 13:04, 19 March 2021 (CET)*"},{"user":"Commy2","date":"2016-08-06T12:24:00Z","text":"**The values described by AgentRev cannot be compared reliably.** All numbers in SQF are floats and those are only precise up to 7 digits.\n\n```sqf\n486539264 + 19 == 486539264 + 20 // returns true\n```\n\nThe DIK codes for `LCtrl + R` and `LCtrl + T` are indistinguishable.\n\n*Note edited by R3vo (talk) 13:04, 19 March 2021 (CET)*"}],"categories":[]},{"name":"actionKeysEx","operator":null,"title":"actionKeysEx","type":"command","url":"https://community.bistudio.com/wiki/actionKeysEx","revid":377679,"updated":"2026-01-02T09:02:44Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gives a broken down version of actionKeys return. Returns an Array containing the breakdowns of the dikCodes of keys, buttons and combos assigned to the given user action.\n\nAction names can be found in config class ControllerSchemes or user action names or user profile (see #Example 1).\n\nIn addition, some of the actions are also listed here: inputAction/actions\n\nThe Key Device can be one of several types:\n- `\"KEYBOARD\"`\n- `\"MOUSE_BUTTON\"`\n- `\"MOUSE_AXIS\"`\n- `\"JOYSTICK_BUTTON\"`\n- `\"JOYSTICK_AXIS\"`\n- `\"JOYSTICK_POV\"`\n- `\"XINPUT\"` - (Xbox) Controller Input\n- `\"TRACKER\"` - Motion Tracking (TrackIR, Tobii etc)","syntaxes":[{"syntax":"actionKeysEx userAction","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":"user action name (see inputAction/actions)","types":["String"],"since":null,"text":"userAction: String - user action name (see inputAction/actions)"}],"returns":{"type":"Array of Arrays in format [mainKeyArray, comboKeyArray, isDoubleTap]:","types":["Array"],"description":"mainKeyArray: Array with [dikCode, device, deviceId] - dikCode: Number - device: String - deviceId: Number - only given if the device is a Joystick type - comboKeyArray: Array identical to mainKeyArray - filled only if the action key is a key combination - dikCode: Number - device: String - deviceId: Number - identical to mainKeyArray's deviceId as it is impossible to use two different Joystick devices in a key combination - isDoubleTap: Boolean - is the action key a double-tap. In case of a combination key this applies to the main key.","text":"Array of Arrays in format [mainKeyArray, comboKeyArray, isDoubleTap]:\n- mainKeyArray: Array with [dikCode, device, deviceId]\n  - dikCode: Number\n  - device: String\n  - deviceId: Number - only given if the device is a Joystick type\n- comboKeyArray: Array identical to *mainKeyArray* - filled only if the action key is a key combination\n  - dikCode: Number\n  - device: String\n  - deviceId: Number - identical to *mainKeyArray*'s *deviceId* as it is impossible to use two different Joystick devices in a key combination\n- isDoubleTap: Boolean - is the action key a double-tap. In case of a combination key this applies to the main key."},"form":"unary","operator":null,"left":null,"right":{"text":"userAction","types":["String"]}}],"examples":[{"text":"To retrieve the following key's data, use the property name without 'key':\n\n```cpp\nkeyWatch[] = { 24 };\n```\n\n```sqf\nactionKeysEx \"Watch\"; // [[[24, \"KEYBOARD\"], [], false]]\n```","code":["actionKeysEx \"Watch\"; // [[[24, \"KEYBOARD\"], [], false]]"]},{"text":"```sqf\nprivate _result = actionKeysEx \"OpticsMode\"; // [[[129,\"MOUSE_BUTTON\"],[29,\"KEYBOARD\"],false],[[181,\"KEYBOARD\"],[],false]]\n```","code":["private _result = actionKeysEx \"OpticsMode\"; // [[[129,\"MOUSE_BUTTON\"],[29,\"KEYBOARD\"],false],[[181,\"KEYBOARD\"],[],false]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionKeys","actionKeysNames","actionKeysNamesArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"actionKeysImages","operator":null,"title":"actionKeysImages","type":"command","url":"https://community.bistudio.com/wiki/actionKeysImages","revid":369623,"updated":"2024-09-27T22:13:10Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of button images or names assigned to the given user action.\nA maximum of *maxKeys* keys is listed.\nYou can find the action names in the ControllerSchemes config class or user action names.","syntaxes":[{"syntax":"actionKeysImages userAction","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"userAction","types":["String"]}},{"syntax":"actionKeysImages [userAction, maxKeys]","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"},{"name":"maxKeys","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"maxKeys: Number"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"[userAction, maxKeys]","types":["Array"]}}],"examples":[{"text":"```sqf\n_text = actionKeysImages \"ReloadMagazine\";\n```","code":["_text = actionKeysImages \"ReloadMagazine\";"]},{"text":"```sqf\n_reload = actionKeysImages [\"ReloadMagazine\", 1] // returns \"R\" (including the quotation marks!)\n```","code":["_reload = actionKeysImages [\"ReloadMagazine\", 1] // returns \"R\" (including the quotation marks!)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionKeys","actionKeysNames","actionKeysNamesArray","actionName","inputAction"],"notes":[],"categories":[]},{"name":"actionKeysNames","operator":null,"title":"actionKeysNames","type":"command","url":"https://community.bistudio.com/wiki/actionKeysNames","revid":364173,"updated":"2024-05-05T10:46:45Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of button names assigned to the given user action.\nAction names can be found in config class `ControllerSchemes` or user action names.","syntaxes":[{"syntax":"actionKeysNames userAction","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"userAction","types":["String"]}},{"syntax":"actionKeysNames [userAction, maxKeys, inputDevicePriority]","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"userAction: String"},{"name":"maxKeys","type":"Number","optional":false,"default":null,"description":"maximum number of keys to return","types":["Number"],"since":null,"text":"maxKeys: Number - maximum number of keys to return"},{"name":"inputDevicePriority","type":"String","optional":false,"default":null,"description":"result sorted by inputDevicePriority with values:\n- `\"Mouse\"`\n- `\"Keyboard\"`\n- `\"Stick\"`\n- `\"Gamepad\"`\n- `\"Tracker\"`\n- `\"Combo\"` (mouse and keyboard combinations)\n- `\"Controler\"` [sic] (any controller other than mouse or keyboard)\nOther values are considered as:\n- `\"Unsorted\"`","types":["String"],"since":"arma3 1.36","text":"inputDevicePriority: String - result sorted by inputDevicePriority with values:\n- `\"Mouse\"`\n- `\"Keyboard\"`\n- `\"Stick\"`\n- `\"Gamepad\"`\n- `\"Tracker\"`\n- `\"Combo\"` (mouse and keyboard combinations)\n- `\"Controler\"` [sic] (any controller other than mouse or keyboard)\nOther values are considered as:\n- `\"Unsorted\"`"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[userAction, maxKeys, inputDevicePriority]","types":["Array"]}}],"examples":[{"text":"```sqf\n_list = actionKeysNames \"ReloadMagazine\"; // \"\"\"R\"\" or \"\"XBox X\"\"\"\n```","code":["_list = actionKeysNames \"ReloadMagazine\"; // \"\"\"R\"\" or \"\"XBox X\"\"\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionKeys","actionKeysImages","actionKeysNamesArray","actionName","inputAction"],"notes":[{"user":"WGL.Q","date":"2010-01-20T20:14:00Z","text":"The return type is a stacked string. A string inside a string. To compare use first single and inside double quotes:\n\n```sqf\nif (actionKeysNames \"User1\" == '\"W\"') then { /* ... */ };\n```"}],"categories":[]},{"name":"actionKeysNamesArray","operator":null,"title":"actionKeysNamesArray","type":"command","url":"https://community.bistudio.com/wiki/actionKeysNamesArray","revid":376357,"updated":"2025-10-07T21:38:14Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of button names assigned to the given user action. You can find the action names in config class ControllerSchemes or user action names.","syntaxes":[{"syntax":"actionKeysNamesArray userAction","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":"name of the action","types":["String"],"since":null,"text":"userAction: String - name of the action"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"userAction","types":["String"]}},{"syntax":"actionKeysNamesArray [userAction, maxKeys, inputDevicePriority]","since":null,"effect":null,"exec":null,"params":[{"name":"userAction","type":"String","optional":false,"default":null,"description":"name of the action","types":["String"],"since":null,"text":"userAction: String - name of the action"},{"name":"maxKeys","type":"Number","optional":false,"default":null,"description":"maximum number of keys to return","types":["Number"],"since":null,"text":"maxKeys: Number - maximum number of keys to return"},{"name":"inputDevicePriority","type":"String","optional":true,"default":null,"description":"result sorted by `inputDevicePriority` with values:\n- `\"Mouse\"`\n- `\"Keyboard\"`\n- `\"Stick\"`\n- `\"Gamepad\"`\n- `\"Tracker\"`\n- `\"Combo\"` (mouse and keyboard combinations)\n- `\"Controler\"` [sic] (any controller other than mouse or keyboard)\nOther values are considered as:\n- `\"Unsorted\"`","types":["String"],"since":"arma3 1.36","text":"inputDevicePriority: String - (Optional) result sorted by `inputDevicePriority` with values:\n- `\"Mouse\"`\n- `\"Keyboard\"`\n- `\"Stick\"`\n- `\"Gamepad\"`\n- `\"Tracker\"`\n- `\"Combo\"` (mouse and keyboard combinations)\n- `\"Controler\"` [sic] (any controller other than mouse or keyboard)\nOther values are considered as:\n- `\"Unsorted\"`"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[userAction, maxKeys, inputDevicePriority]","types":["Array"]}}],"examples":[{"text":"```sqf\n_actionList = actionKeysNamesArray \"ReloadMagazine\";\n```","code":["_actionList = actionKeysNamesArray \"ReloadMagazine\";"]},{"text":"```sqf\n_actionList = actionKeysNamesArray [\"ReloadMagazine\", 1];\n```","code":["_actionList = actionKeysNamesArray [\"ReloadMagazine\", 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionKeys","actionKeysImages","actionKeysNames","actionName","inputAction"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"actionName","operator":null,"title":"actionName","type":"command","url":"https://community.bistudio.com/wiki/actionName","revid":321154,"updated":"2022-05-13T15:05:12Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns localized name of action.","syntaxes":[{"syntax":"actionName action","since":null,"effect":null,"exec":null,"params":[{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nactionName \"ReloadMagazine\"; // returns \"Reload\"\n```","code":["actionName \"ReloadMagazine\"; // returns \"Reload\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inputAction/actions","playAction","playActionNow"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"actionNow","operator":null,"title":"actionNow","type":"command","url":"https://community.bistudio.com/wiki/actionNow","revid":378711,"updated":"2026-06-01T07:27:35Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Make a unit perform an action immediately (without any animation/pre-processing). See the action command for more information.","syntaxes":[{"syntax":"unit actionNow actionArray","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"actionArray","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"actionArray: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"actionArray","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer actionNow [\"TakeBag\", _backpack]; // pick up a backpack without any animation\n```","code":["player actionNow [\"TakeBag\", _backpack]; // pick up a backpack without any animation"]},{"text":"```sqf\nplayer actionNow [\"Gear\", vehicle player]; // open inventory while in vehicle\n```","code":["player actionNow [\"Gear\", vehicle player]; // open inventory while in vehicle"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["action","actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","weaponsInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"actionParams","operator":null,"title":"actionParams","type":"command","url":"https://community.bistudio.com/wiki/actionParams","revid":377675,"updated":"2026-01-02T09:02:37Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Array with params for given user action id (similar to addAction param array).","syntaxes":[{"syntax":"entity actionParams id","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity with added user actions","types":["Object"],"since":null,"text":"entity: Object - entity with added user actions"},{"name":"id","type":"Number","optional":false,"default":null,"description":"id of existing user action (returned by addAction or actionIDs)","types":["Number"],"since":null,"text":"id: Number - id of existing user action (returned by addAction or actionIDs)"}],"returns":{"type":"Array with [title, script, arguments, priority, showWindow, hideOnUse, shortcut, condition, radius, unconscious, textWindowBackground, textWindowForeground, selection, memoryPoint]","types":["Array"],"description":"title: String - action title text - script: String - script file or script expression assigned to the action - arguments: Anything or nil - arguments passed to the action - priority: Number - action priority on the action menu - showWindow: Boolean - whether the action is shown in the center of the screen too - hideOnUse: Boolean - whether the action menu should close after selecting the action - shortcut: String - action bindings to some existing engine action if any - condition: String - expression returning true or nil for action to appear on the action menu - radius: Number - max distance to entity at which action becomes available. -1 means it is engine default (~15m) - unconscious: Boolean - whether the action is available to unconscious person - textWindowBackground: String - same as textWindowBackground in setUserActionText - textWindowForeground: String - same as textWindowForeground in setUserActionText - selection: String - named selection in Geometry LOD to which the action is attached - memoryPoint: String - memory point on the object to which the action is attached If entity is objNull, the following array is returned: ```sqf [\"\", \"\", nil, 1.5, true, true, \"\", \"\", 50, false, \"\", \"\", \"\", \"\"] ``` (returned Nothing until Arma 3 v1.94)","text":"Array with [title, script, arguments, priority, showWindow, hideOnUse, shortcut, condition, radius, unconscious, textWindowBackground, textWindowForeground, selection, memoryPoint]\n- title: String - action title text\n- script: String - script file or script expression assigned to the action\n- arguments: Anything or nil - arguments passed to the action\n- priority: Number - action priority on the action menu\n- showWindow: Boolean - whether the action is shown in the center of the screen too\n- hideOnUse: Boolean - whether the action menu should close after selecting the action\n- shortcut: String - action bindings to some existing engine action if any\n- condition: String - expression returning true or nil for action to appear on the action menu\n- radius: Number - max distance to entity at which action becomes available. -1 means it is engine default (~15m)\n- unconscious: Boolean - whether the action is available to unconscious person\n- textWindowBackground: String - same as textWindowBackground in setUserActionText\n- textWindowForeground: String - same as textWindowForeground in setUserActionText\n- selection: String - named selection in Geometry LOD to which the action is attached\n- memoryPoint: String - memory point on the object to which the action is attached\nIf *entity* is objNull, the following array is returned:\n\n```sqf\n[\"\", \"\", nil, 1.5, true, true, \"\", \"\", 50, false, \"\", \"\", \"\", \"\"]\n```\n\n(returned Nothing until Arma 3 v1.94)"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"id","types":["Number"]}}],"examples":[{"text":"```sqf\n_params = player actionParams 0;\n```","code":["_params = player actionParams 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionIDs","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"activateAddons","operator":null,"title":"activateAddons","type":"command","url":"https://community.bistudio.com/wiki/activateAddons","revid":370473,"updated":"2024-12-16T18:10:00Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Activates the listed addons.","syntaxes":[{"syntax":"activateAddons addonsList","since":null,"effect":null,"exec":null,"params":[{"name":"addonsList","type":"Array of Strings","optional":false,"default":null,"description":null,"types":["Array","String"],"since":null,"text":"addonsList: Array of Strings"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"addonsList","types":["Array","String"]}}],"examples":[{"text":"```sqf\nactivateAddons [\"BISOFP\"];\n```","code":["activateAddons [\"BISOFP\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitAddons","activatedAddons"],"notes":[{"user":"WGL.Q","date":"2009-01-21T12:37:00Z","text":"Be aware that addon's string is the `CfgPatches` class of the desired addon to preload."},{"user":"UNN","date":"2009-05-10T11:17:00Z","text":"This command will activate addons that are referenced via scripts but not included in a missions required addons section. If executed from a configs init event with the call command, it will effectively override a missions required addons, preventing them from being activated (Appears to only happen in multi player).\nTo activate the passed addons along with those defined in the mission.sqm, execute the command from a configs init event using spawn or execVM."},{"user":"Sa-Matra","date":"2022-07-03T08:43:05Z","text":"Here is a handy function to call before you do createVehicle or other create* command during missing init scripts, which should activate missing addons without having to worry about re-adding previously added addons.\n\n```sqf\nfnc_prepareClassAddons = {\n    private _class = toLower _this;\n\n    // To avoid double checks\n    if(isNil\"var_addonCheckedClasses\") then {var_addonCheckedClasses = createHashMap;};\n    if(_class in var_addonCheckedClasses) exitWith {};\n\n    // Finding missing addons\n    private _needed = unitAddons _class apply {toLower _x};\n    private _active = activatedAddons;\n    private _missing = _needed - (_needed arrayIntersect _active);\n    if(count _missing > 0) then {\n        // Adding everything again, engine will figure it out itself\n        _active append _missing;\n        activateAddons _active;\n    };\n\n    var_addonCheckedClasses set [_class, _needed];\n};\n```\n\nUsage would be `\"Land_BurntGarbage_01_F\" call fnc_prepareClassAddons`."}],"categories":[]},{"name":"activatedAddons","operator":null,"title":"activatedAddons","type":"command","url":"https://community.bistudio.com/wiki/activatedAddons","revid":376992,"updated":"2026-01-01T07:35:07Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.14"}],"since":{"game":"arma3","name":"Arma 3","version":"1.14"},"arma3_since":"1.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all activated addons.","syntaxes":[{"syntax":"activatedAddons","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_addons = activatedAddons;\n```","code":["_addons = activatedAddons;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["activateAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 1.14","Scripting Commands"]},{"name":"activateKey","operator":null,"title":"activateKey","type":"command","url":"https://community.bistudio.com/wiki/activateKey","revid":341303,"updated":"2023-05-20T20:40:03Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Activates the given keyname for the current user profile. The keys are used to unlock missions or campaigns.\nSee `keys`, `keysLimit` and `doneKeys` in the Description.ext#Mission Keys chapter.","syntaxes":[{"syntax":"activateKey keyname","since":null,"effect":null,"exec":null,"params":[{"name":"keyname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"keyname: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"keyname","types":["String"]}}],"examples":[{"text":"```sqf\nactivateKey \"Mission04Key\";\n```","code":["activateKey \"Mission04Key\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deActivateKey","isKeyActive"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"activeTitleEffectParams","operator":null,"title":"activeTitleEffectParams","type":"command","url":"https://community.bistudio.com/wiki/activeTitleEffectParams","revid":377608,"updated":"2026-01-02T08:51:23Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns type, effect, speed and map visibility of the given active title effect (see allActiveTitleEffects)","syntaxes":[{"syntax":"activeTitleEffectParams layer","since":null,"effect":null,"exec":null,"params":[{"name":"layer","type":"Number","optional":false,"default":null,"description":"layer number or -1 (see allActiveTitleEffects)","types":["Number"],"since":null,"text":"layer: Number - layer number or -1 (see allActiveTitleEffects)"}],"returns":{"type":"Array with [type, effect, speed, showInMap] or [], where:","types":["Array"],"description":"type: String - type of effect, can be `\"OBJ\"`, `\"RSC\"` or `\"TXT\"` - effect: String - Title Effect Type (`\"PLAIN\"`, `\"BLACK OUT\"` etc) - speed: Number - effect speed multiplier - showInMap: Boolean - true if effect is available over map","text":"Array with [type, effect, speed, showInMap] or [], where:\n- type: String - type of effect, can be `\"OBJ\"`, `\"RSC\"` or `\"TXT\"`\n- effect: String - Title Effect Type (`\"PLAIN\"`, `\"BLACK OUT\"` etc)\n- speed: Number - effect speed multiplier\n- showInMap: Boolean - true if effect is available over map"},"form":"unary","operator":null,"left":null,"right":{"text":"layer","types":["Number"]}}],"examples":[{"text":"```sqf\n21 cutText [\"Hello World!\", \"PLAIN\", 2];\nhint str activeTitleEffectParams 21; // [\"TXT\", \"PLAIN\", 2, true]\n```","code":["21 cutText [\"Hello World!\", \"PLAIN\", 2];\nhint str activeTitleEffectParams 21; // [\"TXT\", \"PLAIN\", 2, true]"]},{"text":"```sqf\ntitleText [\"Hello World!\", \"BLACK\"];\nhint str activeTitleEffectParams -1; // [\"TXT\", \"BLACK\", 1, true]\n```","code":["titleText [\"Hello World!\", \"BLACK\"];\nhint str activeTitleEffectParams -1; // [\"TXT\", \"BLACK\", 1, true]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","cutText","cutRsc","cutObj","cutFadeOut","titleText","titleRsc","titleObj","titleFadeOut","allActiveTitleEffects","Title Effect Type"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"add3DENConnection","operator":null,"title":"add3DENConnection","type":"command","url":"https://community.bistudio.com/wiki/add3DENConnection","revid":378561,"updated":"2026-05-08T15:48:16Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Connect entities together. Be aware to select the correct type of Eden Entities for the connection type.","syntaxes":[{"syntax":"add3DENConnection [type, from, to]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"connection class from `\"Cfg3DEN\" >> \"Connections\"`:\n- `Group`\n- `RandomStart`\n- `Sync`\n- `TriggerOwner`\n- `WaypointActivation`","types":["String"],"since":null,"text":"type: String - connection class from `\"Cfg3DEN\" >> \"Connections\"`:\n- `Group`\n- `RandomStart`\n- `Sync`\n- `TriggerOwner`\n- `WaypointActivation`"},{"name":"from","type":"Array of Eden Entities","optional":false,"default":null,"description":"entities which are being connected","types":["Array","Eden Entity"],"since":null,"text":"from: Array of Eden Entities - entities which are being connected"},{"name":"to","type":"Eden Entity","optional":false,"default":null,"description":"entity to which entities will be connected to","types":["Eden Entity"],"since":null,"text":"to: Eden Entity - entity to which entities will be connected to"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true If the connection was made","text":"Boolean - true If the connection was made"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, from, to]","types":["Array"]}}],"examples":[{"text":"```sqf\nadd3DENConnection [\"RandomStart\", get3DENSelected \"Object\", \"marker_0\"];// Set random start on marker \"marker_0\" for all selected objects.\n```","code":["add3DENConnection [\"RandomStart\", get3DENSelected \"Object\", \"marker_0\"];// Set random start on marker \"marker_0\" for all selected objects."]},{"text":"```sqf\n// Group all selected units to the first selected group\nprivate _group = get3DENSelected \"Group\" param [0, grpNull];\nprivate _units = get3DENSelected \"Objects\";\n\nadd3DENConnection [\"Group\", _units, _group];\n```","code":["// Group all selected units to the first selected group\nprivate _group = get3DENSelected \"Group\" param [0, grpNull];\nprivate _units = get3DENSelected \"Objects\";\n\nadd3DENConnection [\"Group\", _units, _group];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remove3DENConnection","get3DENConnections"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"add3DENEventHandler","operator":null,"title":"add3DENEventHandler","type":"command","url":"https://community.bistudio.com/wiki/add3DENEventHandler","revid":364159,"updated":"2024-05-05T10:46:40Z","groups":["Eden Editor","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds an Eden Editor Event Handler.","syntaxes":[{"syntax":"add3DENEventHandler [type, code]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"see Eden Editor Event Handler","types":["String"],"since":null,"text":"type: String - see Eden Editor Event Handler"},{"name":"code","type":"Code","optional":false,"default":null,"description":"Code\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`","types":["Code"],"since":null,"text":"code: Code\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, code]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _ehID = add3DENEventHandler [\"onUndo\", { systemChat \"Zip...\" }];\n```","code":["private _ehID = add3DENEventHandler [\"onUndo\", { systemChat \"Zip...\" }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remove3DENEventHandler","removeAll3DENEventHandlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Command Group: Event Handlers","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"add3DENLayer","operator":null,"title":"add3DENLayer","type":"command","url":"https://community.bistudio.com/wiki/add3DENLayer","revid":369092,"updated":"2024-09-02T20:37:48Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds an editing layer in Eden Editor.","syntaxes":[{"syntax":"parentLayerID add3DENLayer name","since":null,"effect":null,"exec":null,"params":[{"name":"parentLayerID","type":"Number","optional":false,"default":null,"description":"ID of the parent layer. No layer will be created when the ID does not point to a layer. Use `-1` to create the layer to root.","types":["Number"],"since":null,"text":"parentLayerID : Number - ID of the parent layer. No layer will be created when the ID does not point to a layer. Use `-1` to create the layer to root."},{"name":"name","type":"String","optional":false,"default":null,"description":"layer display name","types":["String"],"since":null,"text":"name: String - layer display name"}],"returns":{"type":"Number","types":["Number"],"description":"layer ID","text":"Number - layer ID"},"form":"binary","operator":null,"left":{"text":"parentLayerID","types":["Number"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_myLayer = -1 add3DENLayer \"Enemy Base\";\n_myLayerFort = _myLayer add3DENLayer \"Fortifications\";\n_myLayerPatrol = _myLayer add3DENLayer \"Patrols\";\n```","code":["_myLayer = -1 add3DENLayer \"Enemy Base\";\n_myLayerFort = _myLayer add3DENLayer \"Fortifications\";\n_myLayerPatrol = _myLayer add3DENLayer \"Patrols\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remove3DENLayer","set3DENLayer","get3DENLayerEntities"],"notes":[{"user":"Leopard20","date":"2023-04-04T17:28:00Z","text":"To get the list of all 3DEN layers, use all3DENEntities."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"addAction","operator":null,"title":"addAction","type":"command","url":"https://community.bistudio.com/wiki/addAction","revid":378569,"updated":"2026-05-08T21:16:48Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Adds an entry to the action menu of an object. The action can only be activated when in proximity to the object **and** looking at it. Adding an action to the player makes that action available to the player at all times. For event handling of user interaction see inGameUISetEventHandler.","syntaxes":[{"syntax":"object addAction [title, script, arguments, priority, showWindow, hideOnUse, shortcut, condition, radius, unconscious, selection, memoryPoint]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit, vehicle or static object. **No agents and simple objects!**","types":["Object"],"since":null,"text":"**object**: Object - unit, vehicle or static object. **No agents and simple objects!**"},{"name":"title","type":"String","optional":false,"default":null,"description":"the action name displayed in the action menu, may contain Structured Text. Because of that **<** and **>** symbols will be interpreted as opening and closing XML tags. To avoid this use `<` for **<** and `>` for **>**. The title text appearance can be changed with setUserActionText","types":["String"],"since":null,"text":"**title**: String - the action name displayed in the action menu, may contain Structured Text. Because of that **<** and **>** symbols will be interpreted as opening and closing XML tags. To avoid this use `<` for **<** and `>` for **>**. The title text appearance can be changed with setUserActionText"},{"name":"script","type":"String or Code","optional":false,"default":null,"description":"either path to the script file, relative to the mission folder or string with code or the actual script code. If the string is a path to script file, the script file **must** have extension .SQS or .SQF. The script, whether it is a file or a code, will run in scheduled environment, i.e. it is ok to use sleep. Parameters array passed to the script upon activation in *_this* variable is:\n\n```sqf\nparams [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"];\n```\n\n- **target**: Object - the object which the action is assigned to\n- **caller**: Object - the unit that activated the action\n- **actionID**: Number - activated action's ID (same as addAction's return value)\n- **arguments**: Anything - arguments given to the script if you are using the extended syntax","types":["String","Code"],"since":null,"text":"**script**: String or Code - either path to the script file, relative to the mission folder or string with code or the actual script code. If the string is a path to script file, the script file **must** have extension .SQS or .SQF. The script, whether it is a file or a code, will run in scheduled environment, i.e. it is ok to use sleep. Parameters array passed to the script upon activation in *_this* variable is:\n\n```sqf\nparams [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"];\n```\n\n- **target**: Object - the object which the action is assigned to\n- **caller**: Object - the unit that activated the action\n- **actionID**: Number - activated action's ID (same as addAction's return value)\n- **arguments**: Anything - arguments given to the script if you are using the extended syntax"},{"name":"arguments","type":"Anything","optional":true,"default":"nil","description":"arguments to pass to the script. Accessible with `_this select 3` inside the script. If Array is used as an argument for example, its first element reference would be `_this select 3 select 0`","types":["Anything"],"since":null,"text":"**arguments**: Anything - (Optional, default nil) arguments to pass to the script. Accessible with `_this select 3` inside the script. If Array is used as an argument for example, its first element reference would be `_this select 3 select 0`"},{"name":"priority","type":"Number","optional":true,"default":"1.5","description":"priority value of the action. Actions will be arranged in descending order according to this value. Every game action has a preset priority value. Value can be negative or decimal fraction. Actions with same values will be arranged in order which they were made, newest at the bottom. The bigger the number the higher the action will be positioned on the menu. Typical range is 0 to 6","types":["Number"],"since":null,"text":"**priority**: Number - (Optional, default 1.5) priority value of the action. Actions will be arranged in descending order according to this value. Every game action has a preset priority value. Value can be negative or decimal fraction. Actions with same values will be arranged in order which they were made, newest at the bottom. The bigger the number the higher the action will be positioned on the menu. Typical range is 0 to 6"},{"name":"showWindow","type":"Boolean","optional":true,"default":"true","description":"if set to true, players see \"Titletext\" at mid-lower screen, as they approach the object. Only the title text for the action with highest priority and *showWindow* set to true will be shown","types":["Boolean"],"since":null,"text":"**showWindow**: Boolean - (Optional, default true) if set to true, players see \"Titletext\" at mid-lower screen, as they approach the object. Only the title text for the action with highest priority and *showWindow* set to true will be shown"},{"name":"hideOnUse","type":"Boolean","optional":true,"default":"true","description":"if set to true, it will hide the action menu after selecting it. If set to false, it will leave the action menu open and visible after selecting the action, leaving the same action highlighted, for the purpose of allowing you to re-select that same action quickly, or to select another action","types":["Boolean"],"since":null,"text":"**hideOnUse**: Boolean - (Optional, default true) if set to true, it will hide the action menu after selecting it. If set to false, it will leave the action menu open and visible after selecting the action, leaving the same action highlighted, for the purpose of allowing you to re-select that same action quickly, or to select another action"},{"name":"shortcut","type":"String","optional":true,"default":"\"\"","description":"one of the key names defined in bin.pbo (e.g. \"moveForward\"). Adding available shortcut will bind corresponding keyboard key to this action. Shortcut availability can be tested with inputAction command","types":["String"],"since":null,"text":"**shortcut**: String - (Optional, default \"\") one of the key names defined in bin.pbo (e.g. \"moveForward\"). Adding available shortcut will bind corresponding keyboard key to this action. Shortcut availability can be tested with inputAction command"},{"name":"condition","type":"String","optional":true,"default":"\"true\"","description":"expression that must return true for the action to be shown. **Special variables** passed to the script code are:\n- *_target*: Object - The object to which action is attached or, if the object is a unit inside of vehicle, the vehicle\n- *_this*: Object - Caller person to whom the action is shown (or not shown if *condition* returns false)\n- *_originalTarget*: Object - The original object to which the action is attached, regardless if the object/unit is in a vehicle or not\n- *_actionId*: Number - checked action's ID (same as addAction's return value)\n\n> [!WARNING]\n> If the player is the group leader, has an action added to them, and selects a subordinate, `*_this*` alternatively switches between the player and this selected unit - RPT logging `Unknown attribute itemsCmd` in the process.\n\n> [!IMPORTANT]\n> - *condition* is evaluated on each frame in unscheduled environment.\n> - *condition* is **not** evaluated if a dialog is open.\n> - If action is added to an object and not to the player, *condition* will only get evaluated if the player is closer than ~50m to the object surface and is looking at the object.\n> - If action is added to player, *condition* is evaluated all the time.","types":["String"],"since":null,"text":"**condition**: String - (Optional, default \"true\") expression that must return true for the action to be shown. **Special variables** passed to the script code are:\n- *_target*: Object - The object to which action is attached or, if the object is a unit inside of vehicle, the vehicle\n- *_this*: Object - Caller person to whom the action is shown (or not shown if *condition* returns false)\n- *_originalTarget*: Object - The original object to which the action is attached, regardless if the object/unit is in a vehicle or not\n- *_actionId*: Number - checked action's ID (same as addAction's return value)\n\n> [!WARNING]\n> If the player is the group leader, has an action added to them, and selects a subordinate, `*_this*` alternatively switches between the player and this selected unit - RPT logging `Unknown attribute itemsCmd` in the process.\n\n> [!IMPORTANT]\n> - *condition* is evaluated on each frame in unscheduled environment.\n> - *condition* is **not** evaluated if a dialog is open.\n> - If action is added to an object and not to the player, *condition* will only get evaluated if the player is closer than ~50m to the object surface and is looking at the object.\n> - If action is added to player, *condition* is evaluated all the time."},{"name":"radius","type":"Number","optional":true,"default":"50","description":"maximum 3D distance in meters between the activating unit's eyePos and *object**s* memoryPoint*,* selection *or position. -1 disables the radius; hardcoded limit is** 50*'","types":["Number"],"since":"arma3 1.64","text":"**radius**: Number - (Optional, default 50) maximum 3D distance in meters between the activating unit's eyePos and *object**s* memoryPoint*,* selection *or position. -1 disables the radius; hardcoded limit is** 50*'"},{"name":"unconscious","type":"Boolean","optional":true,"default":"false","description":"if true will be shown to incapacitated player. See also setUnconscious and lifeState","types":["Boolean"],"since":"arma3 1.64","text":"**unconscious**: Boolean - (Optional, default false) if true will be shown to incapacitated player. See also setUnconscious and lifeState"},{"name":"selection","type":"String","optional":true,"default":"\"\"","description":"*object*'s geometry LOD's named selection","types":["String"],"since":"arma3 1.70","text":"**selection**: String - (Optional, default \"\") *object*'s geometry LOD's named selection"},{"name":"memoryPoint","type":"String","optional":true,"default":"\"\"","description":"*object*'s memory point. If *selection* is supplied, *memoryPoint* is not used","types":["String"],"since":"arma3 1.82","text":"**memoryPoint**: String - (Optional, default \"\") *object*'s memory point. If *selection* is supplied, *memoryPoint* is not used"}],"returns":{"type":"Number","types":["Number"],"description":"the added action's ID. Action can be removed with removeAction (see also removeAllActions). IDs are incrementing, the first given action to each unit has the ID 0, the second the ID 1, etc. IDs are also passed to the called script (see the script parameter)","text":"Number - the added action's ID. Action can be removed with removeAction (see also removeAllActions). IDs are incrementing, the first given action to each unit has the ID 0, the second the ID 1, etc. IDs are also passed to the called script (see the *script* parameter)"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[title, script, arguments, priority, showWindow, hideOnUse, shortcut, condition, radius, unconscious, selection, memoryPoint]","types":["Array"]}}],"examples":[{"text":"```sqf\n// short and sweet\nplayer addAction [\"a useless action that does nothing\", {}];\nplayer addAction [\"<t color='#FF0000'>This Useless Action Is RED</t>\", { hint \"RED\" }];\nplayer addAction [\"Hint Hello!\", { hint format [\"Hello %1!\", name player] }];\nplayer addAction [\"String Exec\", \"hint 'this is also compiled'\"];\n```","code":["// short and sweet\nplayer addAction [\"a useless action that does nothing\", {}];\nplayer addAction [\"<t color='#FF0000'>This Useless Action Is RED</t>\", { hint \"RED\" }];\nplayer addAction [\"Hint Hello!\", { hint format [\"Hello %1!\", name player] }];\nplayer addAction [\"String Exec\", \"hint 'this is also compiled'\"];"]},{"text":"```sqf\n_actionID = player addAction [\"Exec the file\", \"scriptFile.sqf\"];\n```\n\n**scriptFile.sqf:**\n\n```sqf\nhint str _this;\n```","code":["_actionID = player addAction [\"Exec the file\", \"scriptFile.sqf\"];","hint str _this;"]},{"text":"```sqf\n// create object on the server and add action to the object on every client\nif (isServer) then\n{\n    private _object = \"some_obj_class\" createVehicle [1234, 1234, 0];\n    [_object, [\"Greetings!\", { hint \"Hello!\"; }]] remoteExec [\"addAction\"]; // Note: does not return action id\n};\n```","code":["// create object on the server and add action to the object on every client\nif (isServer) then\n{\n\tprivate _object = \"some_obj_class\" createVehicle [1234, 1234, 0];\n\t[_object, [\"Greetings!\", { hint \"Hello!\"; }]] remoteExec [\"addAction\"]; // Note: does not return action id\n};"]},{"text":"Default parameters:\n\n```sqf\nthis addAction\n[\n    \"title\",\n    {\n        params [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"];\n    },\n    nil,\n    1.5,\n    true,\n    true,\n    \"\",\n    \"true\",\n    50,\n    false,\n    \"\",\n    \"\"\n];\n```","code":["this addAction\n[\n\t\"title\",\n\t{\n\t\tparams [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"];\n\t},\n\tnil,\n\t1.5,\n\ttrue,\n\ttrue,\n\t\"\",\n\t\"true\",\n\t50,\n\tfalse,\n\t\"\",\n\t\"\"\n];"]},{"text":"Default parameters with comments:\n\n```sqf\nthis addAction\n[\n    \"title\",    // title\n    {\n        params [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"]; // script\n    },\n    nil,        // arguments\n    1.5,        // priority\n    true,        // showWindow\n    true,        // hideOnUse\n    \"\",            // shortcut\n    \"true\",        // condition\n    50,            // radius\n    false,        // unconscious\n    \"\",            // selection\n    \"\"            // memoryPoint\n];\n```","code":["this addAction\n[\n\t\"title\",\t// title\n\t{\n\t\tparams [\"_target\", \"_caller\", \"_actionId\", \"_arguments\"]; // script\n\t},\n\tnil,\t\t// arguments\n\t1.5,\t\t// priority\n\ttrue,\t\t// showWindow\n\ttrue,\t\t// hideOnUse\n\t\"\",\t\t\t// shortcut\n\t\"true\",\t\t// condition\n\t50,\t\t\t// radius\n\tfalse,\t\t// unconscious\n\t\"\",\t\t\t// selection\n\t\"\"\t\t\t// memoryPoint\n];"]}],"multiplayer":"The command will be ignored on dedicated servers, probably because no UI exists.","problems":null,"aliases":[],"see_also":["actionIDs","actionParams","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","action","shownAction","BIS_fnc_holdActionAdd"],"notes":[{"user":"Dedmen","date":"2018-05-02T13:44:00Z","text":"If you want to replicate vanilla Actions like \"Treat yourself\" where the scroll menu only shows text and it displays the icon mid-screen you can use\n\n```sqf\nprivate _actionId = player addAction [\"Heal\", {}];\nplayer setUserActionText [_actionId, \"Heal\", \"<img size='2' image='\\a3\\ui_f\\data\\IGUI\\Cfg\\Actions\\heal_ca'/>\"];\n```"},{"user":"PierreMGI","date":"2020-05-12T10:42:00Z","text":"addAction on unit or player stays on corpse after kill. So this action is lost for the new body after respawn. If you want a persistent addAction, you need to add it in the respawn script (onPlayerRespawn.sqf or addMissionEventHandler \"entityRespawned\" or addMPEventHandler \"MPrespawn\"...\nYou can use removeAllActions on corpse."},{"user":"Leopard20","date":"2022-08-28T21:52:00Z","text":"If the server blocks execVM in CfgRemoteExec, you can't use path to script:\n\n```sqf\n_obj addAction [\"Test\", \"path\\script.sqf\"]; // \"path\\script.sqf\" won't execute\n```\n\nYou can, however, do this:\n\n```sqf\n_obj addAction [\"Test\", { _this spawn compile preprocessFileLineNumbers \"path\\script.sqf\" }];\n```\n\nBut it's recommended to use functions if the script is called frequently."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Introduced with Operation Flashpoint version 1.10","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addBackpack","operator":null,"title":"addBackpack","type":"command","url":"https://community.bistudio.com/wiki/addBackpack","revid":364226,"updated":"2024-05-06T09:38:13Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds a backpack for a unit. If a unit already has a backpack, the old backpack will be placed on the ground under the unit. Items defined in the backpack's config will be added as well.\n\n> [!NOTE]\n> Classname list of available backpacks:\n> - Arma 2 OA backpacks\n> - Arma 3 backpacks - objects starting with \"B_\", starts with \"*B_AssaultPack_khk*\"","syntaxes":[{"syntax":"unit addBackpack backpackClassName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"backpackClassName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"backpackClassName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"backpackClassName","types":["String"]}}],"examples":[{"text":"```sqf\nthis addBackpack \"TK_RPG_Backpack_EP1\";\n```","code":["this addBackpack \"TK_RPG_Backpack_EP1\";"]},{"text":"```sqf\n_mySoldierDude addBackpack \"US_Patrol_Pack_EP1\";\n```","code":["_mySoldierDude addBackpack \"US_Patrol_Pack_EP1\";"]},{"text":"```sqf\n_mySoldierDude addBackpack \"B_AssaultPack_mcamo_Ammo\";// Adds backpack prefilled with items defined in its config\n```","code":["_mySoldierDude addBackpack \"B_AssaultPack_mcamo_Ammo\";// Adds backpack prefilled with items defined in its config"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addBackpackGlobal","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addBackpackCargo","operator":null,"title":"addBackpackCargo","type":"command","url":"https://community.bistudio.com/wiki/addBackpackCargo","revid":376385,"updated":"2025-10-09T02:14:45Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Add backpack(s) to the cargo space of vehicle. Classname list of available backpacks is here.\nFor a list of possible backpacks, see:\n- Arma 2 v1.50 Arma 2: Operation Arrowhead: Backpacks\n- Arma 3 v1.00 Arma 3: CfgVehicles Equipment (starting with `B_`)\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, arguments for this command are local Local Argument. For the global variant, see addBackpackCargoGlobal.","syntaxes":[{"syntax":"vehicle addBackpackCargo [backpackClassName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to add the backpack to","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to add the backpack to"},{"name":"backpackClassName","type":"String","optional":false,"default":null,"description":"backpack classname","types":["String"],"since":null,"text":"backpackClassName: String - backpack classname"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of backpacks to add. Arma 3 v2.14 negative count will remove backpacks.","types":["Number"],"since":null,"text":"count: Number - number of backpacks to add. Arma 3 v2.14 negative count will remove backpacks."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[backpackClassName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\nthis addBackpackCargo [\"TK_RPG_Backpack_EP1\", 2];\n```","code":["this addBackpackCargo [\"TK_RPG_Backpack_EP1\", 2];"]},{"text":"```sqf\n_apc addBackpackCargo [\"US_Patrol_Pack_EP1\", 4];\n```","code":["_apc addBackpackCargo [\"US_Patrol_Pack_EP1\", 4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addBackpackCargoGlobal","operator":null,"title":"addBackpackCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/addBackpackCargoGlobal","revid":341861,"updated":"2023-07-01T14:05:59Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Add backpack(s) to the cargo space of vehicle.\n\n> [!NOTE]\n> Classname list of available backpacks:\n> - Arma 2:OA backpacks\n> - Arma 3 backpacks - objects starting with \"B_\", starts near \"B_AssaultPack_khk\"","syntaxes":[{"syntax":"vehicle addBackpackCargoGlobal [packClassName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"object to add the Backpack to","types":["Object"],"since":null,"text":"vehicle: Object - object to add the Backpack to"},{"name":"packClassName","type":"String","optional":false,"default":null,"description":"see the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"packClassName: String - see the topic Category:Weapons for reference about possible values."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of backpacks to add; Arma 3 v2.14 a negative value will remove backpacks.","types":["Number"],"since":null,"text":"count: Number - number of backpacks to add; Arma 3 v2.14 a negative value will remove backpacks."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[packClassName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\nthis addBackpackCargoGlobal [\"TK_RPG_Backpack_EP1\", 2];\n```","code":["this addBackpackCargoGlobal [\"TK_RPG_Backpack_EP1\", 2];"]},{"text":"```sqf\n_apc addBackpackCargoGlobal [\"US_Patrol_Pack_EP1\", 4];\n```","code":["_apc addBackpackCargoGlobal [\"US_Patrol_Pack_EP1\", 4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","addMagazineCargo","clearMagazineCargo","clearWeaponCargo","addMagazineCargoGlobal","addWeaponCargo","addWeaponCargoGlobal","addItemCargo","addItemCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addBackpackGlobal","operator":null,"title":"addBackpackGlobal","type":"command","url":"https://community.bistudio.com/wiki/addBackpackGlobal","revid":369079,"updated":"2024-09-02T20:35:57Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds a backpack to a unit - global variant of addBackpack.\n\n> [!WARNING]\n> The backpack added with this command will be created on the PC local to the unit you are adding it to, even if executed on the server.\n> Because of this, if non-local unit is the target and one tries to immediately access added backpack, the backpack returned will be null.\n> When adding backpack dynamically to a remote unit, wait until the backpack is added (See #Example 2).","syntaxes":[{"syntax":"unit addBackpackGlobal backpack","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"soldier","types":["Object"],"since":null,"text":"unit: Object - soldier"},{"name":"backpack","type":"String","optional":false,"default":null,"description":"backpack class name","types":["String"],"since":null,"text":"backpack: String - backpack class name"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"backpack","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addBackpackGlobal \"B_AssaultPack_khk\";\n```","code":["player addBackpackGlobal \"B_AssaultPack_khk\";"]},{"text":"```sqf\n_unit spawn \n{\n    if (not isNull backpackContainer _this) then\n    {\n        removeBackpackGlobal _this;\n        waitUntil { sleep 0.01; isNull backpackContainer _this };\n    };\n\n    _this addBackpackGlobal \"B_AssaultPack_khk\";\n    waitUntil { sleep 0.01; not isNull backpackContainer _this };\n    backpackContainer _this addMagazineCargoGlobal [\"30Rnd_556x45_Stanag\", 5];\n};\n```","code":["_unit spawn \n{\n\tif (not isNull backpackContainer _this) then\n\t{\n\t\tremoveBackpackGlobal _this;\n\t\twaitUntil { sleep 0.01; isNull backpackContainer _this };\n\t};\n\n\t_this addBackpackGlobal \"B_AssaultPack_khk\";\n\twaitUntil { sleep 0.01; not isNull backpackContainer _this };\n\tbackpackContainer _this addMagazineCargoGlobal [\"30Rnd_556x45_Stanag\", 5];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addBackpack","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addBinocularItem","operator":null,"title":"addBinocularItem","type":"command","url":"https://community.bistudio.com/wiki/addBinocularItem","revid":309278,"updated":"2022-05-04T15:19:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds weapon item, including magazine, directly to the binocular weapon. This is used for infantry weapons.","syntaxes":[{"syntax":"unit addBinocularItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addBinocularItem \"Laserbatteries\";\n```","code":["player addBinocularItem \"Laserbatteries\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponItem","removeBinocularItem","removeAllBinocularItems","addPrimaryWeaponItem","addSecondaryWeaponItem","addHandgunItem","weaponsItems","binocularItems","primaryWeaponItems","secondaryWeaponItems","handgunItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addCamShake","operator":null,"title":"addCamShake","type":"command","url":"https://community.bistudio.com/wiki/addCamShake","revid":369087,"updated":"2024-09-02T20:37:47Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Creates the camera shaking effect, like when you are near an explosion","syntaxes":[{"syntax":"addCamShake [power, duration, frequency]","since":null,"effect":null,"exec":null,"params":[{"name":"power","type":"Number","optional":false,"default":null,"description":"strength of shake (camera movement), practical range is 0 to 20","types":["Number"],"since":null,"text":"power: Number - strength of shake (camera movement), practical range is 0 to 20"},{"name":"duration","type":"Number","optional":false,"default":null,"description":"duration in seconds divided by 2","types":["Number"],"since":null,"text":"duration: Number - duration in seconds divided by 2"},{"name":"frequency","type":"Number","optional":false,"default":null,"description":"frequency of shake, practical range is 0 to 100","types":["Number"],"since":null,"text":"frequency: Number - frequency of shake, practical range is 0 to 100"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[power, duration, frequency]","types":["Array"]}}],"examples":[{"text":"```sqf\naddCamShake [10, 2, 25]; // Shakes the camera for 1 second\n```","code":["addCamShake [10, 2, 25]; // Shakes the camera for 1 second"]},{"text":"```sqf\nenableCamShake true;\naddCamShake [5, 5, 25];\n```","code":["enableCamShake true;\naddCamShake [5, 5, 25];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableCamShake","setCamShakeDefParams","setCamShakeParams","resetCamShake"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addCuratorAddons","operator":null,"title":"addCuratorAddons","type":"command","url":"https://community.bistudio.com/wiki/addCuratorAddons","revid":378390,"updated":"2026-04-04T07:50:38Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Allow curator use of given addon.","syntaxes":[{"syntax":"curatorObj addCuratorAddons addons","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"addons","type":"Array of Strings","optional":false,"default":null,"description":"CfgPatches class names","types":["Array","String"],"since":null,"text":"addons: Array of Strings - CfgPatches class names"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"addons","types":["Array","String"]}}],"examples":[{"text":"```sqf\ncuratorObj addCuratorAddons [\"A3_Armor_F_AMV\",\"A3_Armor_F_Panther\"];\n```","code":["curatorObj addCuratorAddons [\"A3_Armor_F_AMV\",\"A3_Armor_F_Panther\"];"]},{"text":"```sqf\ncuratorObj addCuratorAddons [\"A3_Modules_F_Curator_Lightning\"];\n```","code":["curatorObj addCuratorAddons [\"A3_Modules_F_Curator_Lightning\"];"]},{"text":"Addons can be stacked:\n\n```sqf\ncuratorObj addCuratorAddons [\"A3_Armor_F_AMV\",\"A3_Armor_F_Panther\"];\ncuratorObj addCuratorAddons [\"A3_Modules_F_Curator_Lightning\"];\ndiag_log curatorAddons curatorObj;\n```\n\n```sqf\n[\n    \"A3_Armor_F_AMV\",\n    \"A3_Armor_F_Panther\",\n    \"A3_Modules_F_Curator_Lightning\"\n]\n```","code":["curatorObj addCuratorAddons [\"A3_Armor_F_AMV\",\"A3_Armor_F_Panther\"];\ncuratorObj addCuratorAddons [\"A3_Modules_F_Curator_Lightning\"];\ndiag_log curatorAddons curatorObj;","[\n\t\"A3_Armor_F_AMV\",\n\t\"A3_Armor_F_Panther\",\n\t\"A3_Modules_F_Curator_Lightning\"\n]"]}],"multiplayer":"Can be executed only on server","problems":null,"aliases":[],"see_also":["Arma 3: Curator","removeCuratorAddons","removeAllCuratorAddons","curatorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addCuratorCameraArea","operator":null,"title":"addCuratorCameraArea","type":"command","url":"https://community.bistudio.com/wiki/addCuratorCameraArea","revid":378612,"updated":"2026-05-13T17:01:55Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Adds or changes curator camera area (depends on if ID is already used).","syntaxes":[{"syntax":"curatorObj addCuratorCameraArea [cameraAreaID, position, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"cameraAreaID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"cameraAreaID: Number"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"[cameraAreaID, position, radius]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyCurator addCuratorCameraArea [3, position mySoldier, 300];\n```","code":["myCurator addCuratorCameraArea [3, position mySoldier, 300];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","removeCuratorCameraArea","removeAllCuratorCameraAreas","curatorCameraArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addCuratorEditableObjects","operator":null,"title":"addCuratorEditableObjects","type":"command","url":"https://community.bistudio.com/wiki/addCuratorEditableObjects","revid":377067,"updated":"2026-01-01T09:24:50Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Register objects which can be edited by a curator.","syntaxes":[{"syntax":"curatorObj addCuratorEditableObjects [objects, addCrew]","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"},{"name":"addCrew","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"addCrew: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"[objects, addCrew]","types":["Array"]}}],"examples":[{"text":"```sqf\nMyCuratorModule addCuratorEditableObjects [[MyCar], true];\n```","code":["MyCuratorModule addCuratorEditableObjects [[MyCar], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","allCurators","removeCuratorEditableObjects","curatorEditableObjects"],"notes":[{"user":"R3vo","date":"2020-07-23T10:29:00Z","text":"To continuously make all created objects editable for all Zeus use the following code:\n\n```sqf\nif (isServer) then\n{\n    0 spawn\n    {\n        while { true } do\n        {\n            {\n                _x addCuratorEditableObjects\n                [\n                    entities [[], [\"Logic\"], true /* include vehicle crew */, true /* exclude dead bodies */],\n                    true\n                ];\n            } count allCurators;\n            sleep 60; // change to whatever fits your needs\n        };\n    };\n};\n```"},{"user":"POLPOX","date":"2025-06-12T11:05:49Z","text":"Modernized script of R3vo's concept for efficient solution.\n\n```sqf\nif (isServer) then {\n    addMissionEventHandler [\"EntityCreated\",{\n        { \n            _x addCuratorEditableObjects [ \n                [_this], true \n            ]; \n        } forEach allCurators; \n    }]; \n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addCuratorEditingArea","operator":null,"title":"addCuratorEditingArea","type":"command","url":"https://community.bistudio.com/wiki/addCuratorEditingArea","revid":348372,"updated":"2023-11-08T12:59:56Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Adds or changes curator edit area (depends on if ID is already used).","syntaxes":[{"syntax":"curatorObj addCuratorEditingArea [editAreaID, position, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"editAreaID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"editAreaID: Number"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"[editAreaID, position, radius]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyCurator addCuratorEditingArea [4, position player, 1000];\n```","code":["myCurator addCuratorEditingArea [4, position player, 1000];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","removeCuratorEditingArea","removeAllCuratorEditingAreas","curatorEditingArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addCuratorPoints","operator":null,"title":"addCuratorPoints","type":"command","url":"https://community.bistudio.com/wiki/addCuratorPoints","revid":376978,"updated":"2026-01-01T06:07:36Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Adds or removes curator points.","syntaxes":[{"syntax":"curatorObj addCuratorPoints points","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"points","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"points: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"points","types":["Number"]}}],"examples":[{"text":"```sqf\ncuratorModule addCuratorPoints 0.5;\n```","code":["curatorModule addCuratorPoints 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","curatorPoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addCuratorSelected","operator":null,"title":"addCuratorSelected","type":"command","url":"https://community.bistudio.com/wiki/addCuratorSelected","revid":377569,"updated":"2026-01-02T06:56:16Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add items to the selected curator items.","syntaxes":[{"syntax":"addCuratorSelected items","since":null,"effect":null,"exec":null,"params":[{"name":"items","type":"Array","optional":false,"default":null,"description":"items to add; items can be an Object, Group, Waypoint, or String (marker)","types":["Array"],"since":null,"text":"items: Array - items to add; items can be an Object, Group, Waypoint, or String (marker)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"items","types":["Array"]}}],"examples":[{"text":"```sqf\naddCuratorSelected [unit1, group1, [group1, waypointIndex], markerName1];\n```","code":["addCuratorSelected [unit1, group1, [group1, waypointIndex], markerName1];"]},{"text":"```sqf\naddCuratorSelected [vehicle1, unit1, unit2, unit3, unit4, group1];\n```","code":["addCuratorSelected [vehicle1, unit1, unit2, unit3, unit4, group1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["curatorMouseOver","curatorSelected","setCuratorSelected","curatorEditableObjects","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"addEditorObject","operator":null,"title":"addEditorObject","type":"command","url":"https://community.bistudio.com/wiki/addEditorObject","revid":353335,"updated":"2024-03-15T17:11:50Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add an object to the editor and assign arguments. Create script is,called with _new equal to true. Returns the ID of the new EditorObject.,Subtype class is optional.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map addEditorObject [type,[name1,value1,...],subtype class]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[type,[name1,value1,...],subtype class]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[type,[name1,value1,...],subtype class]: Array"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[type,[name1,value1,...],subtype class]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Game 2 Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addEventHandler","operator":null,"title":"addEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addEventHandler","revid":363476,"updated":"2024-03-31T14:58:59Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Adds an Event Handler to the given object.\n- As many Event Handlers of any type can be added - existing Event Handlers do not get overwritten\n- Use removeEventHandler to remove an Event Handler\nRead Event Handlers for more information and a list of all available Event Handlers.","syntaxes":[{"syntax":"target addEventHandler [type, code]","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Arma 3 v2.10 Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"target: Object or Arma 3 v2.10 Group"},{"name":"type","type":"String","optional":false,"default":null,"description":"see Event Handlers for the full list of available options","types":["String"],"since":null,"text":"type: String - see Event Handlers for the full list of available options"},{"name":"code","type":"Code or String","optional":false,"default":null,"description":"code that should be executed when the Event Handler fires; executed in missionNamespace by default. Several Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`","types":["Code","String"],"since":null,"text":"code: Code or String - code that should be executed when the Event Handler fires; executed in missionNamespace by default. Several Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`"}],"returns":{"type":"Number","types":["Number"],"description":"the index of the added Event Handler. Indices start at 0 for each unit and increment with each added Event Handler.","text":"Number - the index of the added Event Handler. Indices start at 0 for each unit and increment with each added Event Handler."},"form":"binary","operator":null,"left":{"text":"target","types":["Object","Group"]},"right":{"text":"[type, code]","types":["Array"]}}],"examples":[{"text":"```sqf\nthis addEventHandler [\"Killed\", {\n    params [\"_unit\", \"_killer\"];\n    systemChat format [\"%1 has been killed by %2.\", _unit, _killer];\n}];\n```","code":["this addEventHandler [\"Killed\", {\n\tparams [\"_unit\", \"_killer\"];\n\tsystemChat format [\"%1 has been killed by %2.\", _unit, _killer];\n}];"]},{"text":"```sqs\n_index = player addEventHandler [\"Killed\", { _this exec \"playerKilled.sqs\" }]\n```","code":["_index = player addEventHandler [\"Killed\", { _this exec \"playerKilled.sqs\" }]"]}],"multiplayer":"Some event handlers are persistent (i.e they stay attached to the unit, even after it dies and respawns).","problems":null,"aliases":[],"see_also":["removeEventHandler","removeAllEventHandlers","addMPEventHandler","addMissionEventHandler","BIS_fnc_addScriptedEventHandler","getEventHandlerInfo"],"notes":[{"user":"Killzone_Kid","date":"2015-06-07T21:06:00Z","text":"When using overridable EH, such as \"InventoryOpened\" and similar, where returning true allows to override default action, exitWith cannot be used to return value. So:\n\n```sqf\nif (whatever) exitWith {true}; false;\n```\n\nForget about it, will not work. Instead use:\n\n```sqf\nif (whatever) then {true} else {false};\n```\n\n100% satisfaction guaranteed!"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addForce","operator":null,"title":"addForce","type":"command","url":"https://community.bistudio.com/wiki/addForce","revid":377384,"updated":"2026-01-02T06:43:53Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Applies given force for one frame (essentially an impulse) to unit or given PhysX object at given position.\n\n> [!NOTE]\n> For more information see [NVIDIA docs](http://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/classPxRigidBody.html).","syntaxes":[{"syntax":"object addForce [force, position, setUnconscious]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"PhysX object or Arma 3 v2.04Local Argument unit, in which case the unit must be local and will be set unconscious","types":["Object"],"since":null,"text":"object: Object - PhysX object or Arma 3 v2.04Local Argument unit, in which case the unit must be local and will be set unconscious"},{"name":"force","type":"Vector3D","optional":false,"default":null,"description":"force vector in **world** space; force is expressed in\n[newton-seconds](https://en.wikipedia.org/wiki/Newton-second) (used by [PxForceMode::eIMPULSE](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/structPxForceMode.html))","types":["Vector3D"],"since":null,"text":"force: Vector3D - force vector in **world** space; force is expressed in\n[newton-seconds](https://en.wikipedia.org/wiki/Newton-second) (used by [PxForceMode::eIMPULSE](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/structPxForceMode.html))"},{"name":"position","type":"PositionRelative","optional":false,"default":null,"description":"relative to object","types":["PositionRelative"],"since":null,"text":"position: PositionRelative - relative to object"},{"name":"setUnconscious","type":"Boolean","optional":true,"default":"true","description":"only applies to \"CAManBase\" *object*; set to false to keep the person conscious","types":["Boolean"],"since":"arma3 2.18","text":"setUnconscious: Boolean - (Optional, default true) only applies to \"CAManBase\" *object*; set to false to keep the person conscious"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[force, position, setUnconscious]","types":["Array"]}}],"examples":[{"text":"Apply force [0,1000,0] defined in world space (not factoring object actual positioning) to object position [1,0,0]:\n\n```sqf\n_object addForce [[0,1000,0], [1,0,0]];\n```","code":["_object addForce [[0,1000,0], [1,0,0]];"]},{"text":"Apply force [0,1000,0] defined in model space (relative to object) to object position [1,0,0]:\n\n```sqf\n_object addForce [_object vectorModelToWorld [0,1000,0], [1,0,0]];\n```","code":["_object addForce [_object vectorModelToWorld [0,1000,0], [1,0,0]];"]},{"text":"Can be used on units since Arma 3 v2.04:\n\n```sqf\nif (local bob) then\n{\n    0 spawn \n    {\n        bob addForce [bob vectorModelToWorld [0,-200,0], bob selectionPosition \"rightfoot\"];\n        sleep 5;\n        bob setUnconscious false;\n    };\n};\n```","code":["if (local bob) then\n{\n\t0 spawn \n\t{\n\t\tbob addForce [bob vectorModelToWorld [0,-200,0], bob selectionPosition \"rightfoot\"];\n\t\tsleep 5;\n\t\tbob setUnconscious false;\n\t};\n};"]},{"text":"```sqf\nplayer addForce [player vectorModelToWorld [0, -1, 0], [0, 1, 0], false]; // not unconscious\n```","code":["player addForce [player vectorModelToWorld [0, -1, 0], [0, 1, 0], false]; // not unconscious"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTorque","awake","isAwake","vectorModelToWorld","vectorModelToWorldVisual","selectionPosition","disableBrakes","brakesDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.72","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addForceGeneratorRTD","operator":null,"title":"addForceGeneratorRTD","type":"command","url":"https://community.bistudio.com/wiki/addForceGeneratorRTD","revid":351294,"updated":"2023-11-27T03:19:37Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds force generator to world. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"addForceGeneratorRTD parameters","since":null,"effect":null,"exec":null,"params":[{"name":"parameters","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"parameters: Array"}],"returns":{"type":"Number","types":["Number"],"description":"force index","text":"Number - force index"},"form":"unary","operator":null,"left":null,"right":{"text":"parameters","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceAtPositionRTD","clearForcesRTD","forceGeneratorRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addGoggles","operator":null,"title":"addGoggles","type":"command","url":"https://community.bistudio.com/wiki/addGoggles","revid":318656,"updated":"2022-05-13T09:21:15Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a new item and try to link it into goggles (glasses) slot.\n\n> [!NOTE]\n> This command does **not** add NVGs, which are hmd slot items (see linkItem instead).","syntaxes":[{"syntax":"unit addGoggles type","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addGoggles \"G_Tactical_Clear\";\n```","code":["player addGoggles \"G_Tactical_Clear\";"]},{"text":"```sqf\ndiver addGoggles \"G_Diving\";\n```","code":["diver addGoggles \"G_Diving\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["goggles","removeGoggles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"addGroupIcon","operator":null,"title":"addGroupIcon","type":"command","url":"https://community.bistudio.com/wiki/addGroupIcon","revid":376587,"updated":"2025-10-29T23:12:14Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Adds icon to a group leader. Returns icon ID, Control icons visibility with setGroupIconsVisible. Since Arma 3 v2.22 the offset can be set separately for 2d and 3d.","syntaxes":[{"syntax":"group addGroupIcon [iconClass, offset]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"group to which add the icon","types":["Group"],"since":null,"text":"group: Group - group to which add the icon"},{"name":"iconClass","type":"String","optional":false,"default":null,"description":"class name of an icon from `CfgGroupIcons`","types":["String"],"since":null,"text":"iconClass: String - class name of an icon from `CfgGroupIcons`"},{"name":"offset","type":"Array of Numbers","optional":true,"default":"[0,0]","description":"X and Y offsets of the icon in format [offsetX, offsetY, (offsetX3d), (offsetY3d)]","types":["Array","Number"],"since":null,"text":"offset: Array of Numbers - (Optional, default [0,0]) X and Y offsets of the icon in format [offsetX, offsetY, (offsetX3d), (offsetY3d)]"}],"returns":{"type":"Number","types":["Number"],"description":"icon ID","text":"Number - icon ID"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"[iconClass, offset]","types":["Array"]}}],"examples":[{"text":"```sqf\ngroupName addGroupIcon [\"b_inf\", [offsetX, offsetY]];\n```","code":["groupName addGroupIcon [\"b_inf\", [offsetX, offsetY]];"]},{"text":"```sqf\n// enable icons in 2D and 3D\nsetGroupIconsVisible [true, true];\nsetGroupIconsSelectable true;\n\n// add the icon for all existing groups\nallGroups apply\n{\n    private _icon = [\"o_inf\", \"b_inf\", \"n_inf\", \"c_unknown\"] select (side _x call BIS_fnc_sideID);\n    private _color = [side _x, false] call BIS_fnc_sideColor;\n    _x addGroupIcon [_icon, [0, 0]];\n    _x setGroupIconParams [_color, groupID _x, linearConversion [1, 15, count units _x, 0.5, 3, false], true];\n};\n\n// add group event handler to all existing groups to handle to icon sizing\nallGroups apply\n{\n    _x addEventHandler [\"UnitLeft\",\n    {\n        params [\"_group\"];\n        getGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n        _group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n    }];\n};\n\n// add the icons whenever a group gets created\naddMissionEventHandler [\"GroupCreated\",\n{\n    params [\"_group\"];\n    _group spawn\n    {\n        params [\"_group\"];\n        private _start = diag_tickTime;\n        waitUntil {sleep 1; units _group isNotEqualTo [] || diag_tickTime - _start > 5};\n        if (units _group isEqualTo []) exitWith {};\n\n        private _icon = [\"o_inf\", \"b_inf\", \"n_inf\", \"c_unknown\"] select (side _group call BIS_fnc_sideID);\n        private _color = [side _group, false] call BIS_fnc_sideColor;\n\n        _group addGroupIcon [_icon, [0, 0]];\n\n        // scale icon depending on group size\n        _group setGroupIconParams [_color, groupID _group, linearConversion [1, 15, count units _group, 0.5, 2, true], true];\n\n        _group addEventHandler [\"UnitLeft\",\n        {\n            params [\"_group\"];\n            getGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n            _group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n        }];\n    };\n}];\n\n// show group info when hovering over an icon (2D/3D)\naddMissionEventHandler [\"GroupIconOverEnter\",\n{\n    params\n    [\n        \"_is3D\", \"_group\", \"_waypointId\",\n        \"_posX\", \"_posY\",\n        \"_shift\", \"_control\", \"_alt\"\n    ];\n    hintSilent parseText format\n    [\n        \"<t align='left' font='EtelkaMonospacePro'><br/><t size='1.2'>General Information:</t><br/>Callsign: %1<br/>Leader: %2<br/>No. of Units: %3<br/>Delete when Empty: %4<br/><br/><t size='1.2'>Group Status:</t><br/>Health: %5<br/>Fleeing: %6<br/>Attack Enabled: %7<br/>Combat Behaviour: %8<br/>Combat Mode: %9<br/>Formation: %10<br/>Speed: %11<br/><br/><t size='1.2'>Waypoints:</t><br/>No. of Waypoints: %12<br/>Current Waypoint: %13<br/>Speed: %14</t>\",\n        format [\"%1 (%2)\",groupID _group, if (vehicle leader _group isNotEqualTo leader _group) then {[configFile >> \"CfgVehicles\" >> typeOf vehicle leader _group] call BIS_fnc_displayName} else {\"-\"}],\n        name leader _group,\n        count units _group,\n        isGroupDeletedWhenEmpty _group,\n        units _group apply {str round ((1 - damage _x)* 100) + \" %\"},\n        fleeing leader _x,\n        attackEnabled _group,\n        combatBehaviour _group,\n        combatMode _group,\n        formation _group,\n        speedMode _group,\n        count waypoints _group,\n        waypointType [_group, currentWaypoint _group],\n        units _group apply {str round speed _x + \" km/h\"}\n    ];\n\n    if !(_group getVariable [\"IconEnlarged\", false]) then\n    {\n        _group setVariable [\"IconEnlarged\", true];\n\n        getGroupIconParams _group params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n        _group setGroupIconParams [_color, _text, _scale * 1.25, _visibility];\n    };\n}];\n\n// remove the hint whenever the mouse is leaving the icon area (2D/3D)\naddMissionEventHandler [\"GroupIconOverLeave\",\n{\n    params\n    [\n        \"_is3D\", \"_group\", \"_waypointId\",\n        \"_posX\", \"_posY\",\n        \"_shift\", \"_control\", \"_alt\"\n    ];\n    hintSilent \"\";\n\n    if (_group getVariable [\"IconEnlarged\", false]) then\n    {\n        _group setVariable [\"IconEnlarged\", false];\n\n        getGroupIconParams _group params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n        _group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n    };\n}];\n\n// delete group and its units when clicking on the icon\naddMissionEventHandler [\"GroupIconClick\",\n{\n    params\n    [\n        \"_is3D\", \"_group\", \"_waypointId\",\n        \"_mouseButton\", \"_posX\", \"_posY\",\n        \"_shift\", \"_control\", \"_alt\"\n    ];\n\n    if (!_shift && _control && !_alt) then\n    {\n        units _group apply {deleteVehicle _x};\n        deleteGroup _group;\n    };\n}];\n```","code":["// enable icons in 2D and 3D\nsetGroupIconsVisible [true, true];\nsetGroupIconsSelectable true;\n\n// add the icon for all existing groups\nallGroups apply\n{\n\tprivate _icon = [\"o_inf\", \"b_inf\", \"n_inf\", \"c_unknown\"] select (side _x call BIS_fnc_sideID);\n\tprivate _color = [side _x, false] call BIS_fnc_sideColor;\n\t_x addGroupIcon [_icon, [0, 0]];\n\t_x setGroupIconParams [_color, groupID _x, linearConversion [1, 15, count units _x, 0.5, 3, false], true];\n};\n\n// add group event handler to all existing groups to handle to icon sizing\nallGroups apply\n{\n\t_x addEventHandler [\"UnitLeft\",\n\t{\n\t\tparams [\"_group\"];\n\t\tgetGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n\t\t_group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n\t}];\n};\n\n// add the icons whenever a group gets created\naddMissionEventHandler [\"GroupCreated\",\n{\n\tparams [\"_group\"];\n\t_group spawn\n\t{\n\t\tparams [\"_group\"];\n\t\tprivate _start = diag_tickTime;\n\t\twaitUntil {sleep 1; units _group isNotEqualTo [] || diag_tickTime - _start > 5};\n\t\tif (units _group isEqualTo []) exitWith {};\n\n\t\tprivate _icon = [\"o_inf\", \"b_inf\", \"n_inf\", \"c_unknown\"] select (side _group call BIS_fnc_sideID);\n\t\tprivate _color = [side _group, false] call BIS_fnc_sideColor;\n\n\t\t_group addGroupIcon [_icon, [0, 0]];\n\n\t\t// scale icon depending on group size\n\t\t_group setGroupIconParams [_color, groupID _group, linearConversion [1, 15, count units _group, 0.5, 2, true], true];\n\n\t\t_group addEventHandler [\"UnitLeft\",\n\t\t{\n\t\t\tparams [\"_group\"];\n\t\t\tgetGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n\t\t\t_group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n\t\t}];\n\t};\n}];\n\n// show group info when hovering over an icon (2D/3D)\naddMissionEventHandler [\"GroupIconOverEnter\",\n{\n\tparams\n\t[\n\t\t\"_is3D\", \"_group\", \"_waypointId\",\n\t\t\"_posX\", \"_posY\",\n\t\t\"_shift\", \"_control\", \"_alt\"\n\t];\n\thintSilent parseText format\n\t[\n\t\t\"<t align='left' font='EtelkaMonospacePro'><br/><t size='1.2'>General Information:</t><br/>Callsign: %1<br/>Leader: %2<br/>No. of Units: %3<br/>Delete when Empty: %4<br/><br/><t size='1.2'>Group Status:</t><br/>Health: %5<br/>Fleeing: %6<br/>Attack Enabled: %7<br/>Combat Behaviour: %8<br/>Combat Mode: %9<br/>Formation: %10<br/>Speed: %11<br/><br/><t size='1.2'>Waypoints:</t><br/>No. of Waypoints: %12<br/>Current Waypoint: %13<br/>Speed: %14</t>\",\n\t\tformat [\"%1 (%2)\",groupID _group, if (vehicle leader _group isNotEqualTo leader _group) then {[configFile >> \"CfgVehicles\" >> typeOf vehicle leader _group] call BIS_fnc_displayName} else {\"-\"}],\n\t\tname leader _group,\n\t\tcount units _group,\n\t\tisGroupDeletedWhenEmpty _group,\n\t\tunits _group apply {str round ((1 - damage _x)* 100) + \" %\"},\n\t\tfleeing leader _x,\n\t\tattackEnabled _group,\n\t\tcombatBehaviour _group,\n\t\tcombatMode _group,\n\t\tformation _group,\n\t\tspeedMode _group,\n\t\tcount waypoints _group,\n\t\twaypointType [_group, currentWaypoint _group],\n\t\tunits _group apply {str round speed _x + \" km/h\"}\n\t];\n\n\tif !(_group getVariable [\"IconEnlarged\", false]) then\n\t{\n\t\t_group setVariable [\"IconEnlarged\", true];\n\n\t\tgetGroupIconParams _group params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n\t\t_group setGroupIconParams [_color, _text, _scale * 1.25, _visibility];\n\t};\n}];\n\n// remove the hint whenever the mouse is leaving the icon area (2D/3D)\naddMissionEventHandler [\"GroupIconOverLeave\",\n{\n\tparams\n\t[\n\t\t\"_is3D\", \"_group\", \"_waypointId\",\n\t\t\"_posX\", \"_posY\",\n\t\t\"_shift\", \"_control\", \"_alt\"\n\t];\n\thintSilent \"\";\n\n\tif (_group getVariable [\"IconEnlarged\", false]) then\n\t{\n\t\t_group setVariable [\"IconEnlarged\", false];\n\n\t\tgetGroupIconParams _group params [\"_color\", \"_text\", \"_scale\", \"_visibility\"];\n\t\t_group setGroupIconParams [_color, _text, linearConversion [1, 15, count units _group, 0.5, 2, true], _visibility];\n\t};\n}];\n\n// delete group and its units when clicking on the icon\naddMissionEventHandler [\"GroupIconClick\",\n{\n\tparams\n\t[\n\t\t\"_is3D\", \"_group\", \"_waypointId\",\n\t\t\"_mouseButton\", \"_posX\", \"_posY\",\n\t\t\"_shift\", \"_control\", \"_alt\"\n\t];\n\n\tif (!_shift && _control && !_alt) then\n\t{\n\t\tunits _group apply {deleteVehicle _x};\n\t\tdeleteGroup _group;\n\t};\n}];"]}],"multiplayer":null,"problems":"The icons will be hidden again after switching to a different unit via teamSwitch. Execute `setGroupIconsVisible [true, true]; setGroupIconsSelectable true;` to make them visible again.","aliases":[],"see_also":["clearGroupIcons","getGroupIcon","getGroupIcons","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addHandgunItem","operator":null,"title":"addHandgunItem","type":"command","url":"https://community.bistudio.com/wiki/addHandgunItem","revid":320941,"updated":"2022-05-13T10:04:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds weapon item, including magazine, directly to the handgunWeapon. This is used for infantry weapons.","syntaxes":[{"syntax":"unit addHandgunItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addHandgunItem \"muzzle_snds_L\";\n```","code":["player addHandgunItem \"muzzle_snds_L\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponItem","removeHandgunItem","removeAllHandgunItems","addPrimaryWeaponItem","addSecondaryWeaponItem","addBinocularItem","weaponsItems","handgunItems","primaryWeaponItems","secondaryWeaponItems","binocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addHeadgear","operator":null,"title":"addHeadgear","type":"command","url":"https://community.bistudio.com/wiki/addHeadgear","revid":318581,"updated":"2022-05-13T09:21:08Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Creates a headgear item and tries to link it to headgear slot. If slot is occupied with another item, the item in the slot will be replaced.","syntaxes":[{"syntax":"unit addHeadgear item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addHeadgear \"H_HelmetB\";\n```","code":["player addHeadgear \"H_HelmetB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["headgear","removeHeadgear"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addItem","operator":null,"title":"addItem","type":"command","url":"https://community.bistudio.com/wiki/addItem","revid":369269,"updated":"2024-09-03T18:42:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Creates new item and tries to add it into inventory. Inventory must have enough space to accomodate new item or command will fail.The item can also be a weapon or a magazine.","syntaxes":[{"syntax":"unit addItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\n// identical to bluforUnit linkItem \"NVGoggles\"\n// addItem then assignItem makes the item go through through inventory storage and fail if storage space was missing\nbluforUnit addItem \"NVGoggles\";\nbluforUnit assignItem \"NVGoggles\";\n\nopforUnit addItem \"NVGoggles_OPFOR\";\nopforUnit assignItem \"NVGoggles_OPFOR\";\n\nindependentUnit addItem \"NVGoggles_INDEP\";\nindependentUnit assignItem \"NVGoggles_INDEP\";\n```","code":["// identical to bluforUnit linkItem \"NVGoggles\"\n// addItem then assignItem makes the item go through through inventory storage and fail if storage space was missing\nbluforUnit addItem \"NVGoggles\";\nbluforUnit assignItem \"NVGoggles\";\n\nopforUnit addItem \"NVGoggles_OPFOR\";\nopforUnit assignItem \"NVGoggles_OPFOR\";\n\nindependentUnit addItem \"NVGoggles_INDEP\";\nindependentUnit assignItem \"NVGoggles_INDEP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItem","assignItem","unassignItem","assignedItems","linkItem","unlinkItem","removeAllAssignedItems","addItemToUniform","addItemToVest","addItemToBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addItemCargo","operator":null,"title":"addItemCargo","type":"command","url":"https://community.bistudio.com/wiki/addItemCargo","revid":341379,"updated":"2023-05-25T12:43:57Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Creates new items and stores them in given container.\nWorks with items, weapons, magazines, equipment and glasses but not backpacks.\nIn the latter case use addBackpackCargo instead. For the global variant, see addItemCargoGlobal.","syntaxes":[{"syntax":"box addItemCargo [item, count]","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of items to add; Arma 3 v2.14 a negative value removes items","types":["Number"],"since":null,"text":"count: Number - number of items to add; Arma 3 v2.14 a negative value removes items"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"box","types":["Object"]},"right":{"text":"[item, count]","types":["Array"]}}],"examples":[{"text":"```sqf\nsupplyBox addItemCargo [\"optic_ARCO\", 10];\n```","code":["supplyBox addItemCargo [\"optic_ARCO\", 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemCargoGlobal","clearItemCargo","addMagazineCargo","addMagazineCargoGlobal","addWeaponCargo","addWeaponCargoGlobal","addBackpackCargo","addBackpackCargoGlobal"],"notes":[{"user":"7erra","date":"2021-11-20T12:27:55Z","text":"Make sure that you are using the classname from CfgWeapons, CfgMagazines or CfgGlasses! Placing an item in Eden Editor places the container of the item, not the item itself.\nTo get the item classname you can open the config of the placed container in the Config Viewer and look for a subclass called \"TransportItems\".\nThe correct classname is stored under `configFile >> \"CfgVehicles\" >> _containerClass >> \"TransportItems\" >> \"some_classname\" >> \"name\"`."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addItemCargoGlobal","operator":null,"title":"addItemCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/addItemCargoGlobal","revid":376380,"updated":"2025-10-09T02:13:10Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Global variant of addItemCargo.","syntaxes":[{"syntax":"box addItemCargoGlobal [item, count]","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of items to add. Arma 3 v2.14 negative count will remove items.","types":["Number"],"since":null,"text":"count: Number - number of items to add. Arma 3 v2.14 negative count will remove items."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"box","types":["Object"]},"right":{"text":"[item, count]","types":["Array"]}}],"examples":[{"text":"```sqf\nsupplyBox addItemCargoGlobal [\"optic_Arco\", 10];\n```","code":["supplyBox addItemCargoGlobal [\"optic_Arco\", 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemCargo","clearItemCargoGlobal","addMagazineCargo","addMagazineCargoGlobal","addWeaponCargo","addWeaponCargoGlobal","addBackpackCargo","addBackpackCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addItemPool","operator":null,"title":"addItemPool","type":"command","url":"https://community.bistudio.com/wiki/addItemPool","revid":318565,"updated":"2022-05-13T09:21:06Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds count items of type name into the weapon pool (used in the campaign to transfer items to the next mission)","syntaxes":[{"syntax":"addItemPool [itemName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"itemName","type":"String","optional":false,"default":null,"description":"item name","types":["String"],"since":null,"text":"itemName: String - item name"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of items to add","types":["Number"],"since":null,"text":"count: Number - number of items to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[itemName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\naddItemPool [\"ItemGPS\", 5];\n```","code":["addItemPool [\"ItemGPS\", 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearItemPool"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"addItemToBackpack","operator":null,"title":"addItemToBackpack","type":"command","url":"https://community.bistudio.com/wiki/addItemToBackpack","revid":318688,"updated":"2022-05-13T09:21:19Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create new item and store it to soldier's backpack. The item can also be a weapon or a magazine.","syntaxes":[{"syntax":"unit addItemToBackpack item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addItemToBackpack \"arifle_MXM_Hamr_pointer_F\";\n```","code":["player addItemToBackpack \"arifle_MXM_Hamr_pointer_F\";"]},{"text":"```sqf\nplayer addItemToBackpack \"itemGPS\";\n```","code":["player addItemToBackpack \"itemGPS\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemToUniform","addItemToVest","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addItemToUniform","operator":null,"title":"addItemToUniform","type":"command","url":"https://community.bistudio.com/wiki/addItemToUniform","revid":318719,"updated":"2022-05-13T09:21:22Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create new item and store it to soldier's uniform. The item can also be a weapon or a magazine.","syntaxes":[{"syntax":"unit addItemToUniform item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addItemToUniform \"itemGPS\";\n```","code":["player addItemToUniform \"itemGPS\";"]},{"text":"```sqf\nplayer addItemToUniform \"hgun_Rook40_F\";\n```","code":["player addItemToUniform \"hgun_Rook40_F\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItemFromUniform","addItemToBackpack","addItemToVest"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addItemToVest","operator":null,"title":"addItemToVest","type":"command","url":"https://community.bistudio.com/wiki/addItemToVest","revid":320961,"updated":"2022-05-13T10:04:50Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create new item and store it to soldier's vest. The item can also be a weapon or a magazine.","syntaxes":[{"syntax":"unit addItemToVest item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addItemToVest \"itemGPS\";\n```","code":["player addItemToVest \"itemGPS\";"]},{"text":"```sqf\nplayer addItemToVest \"hgun_Rook40_F\";\n```","code":["player addItemToVest \"hgun_Rook40_F\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItemFromVest","addItemToBackpack","addItemToUniform"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addLiveStats","operator":null,"title":"addLiveStats","type":"command","url":"https://community.bistudio.com/wiki/addLiveStats","revid":318778,"updated":"2022-05-13T09:21:29Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds score to the Xbox Live Statistics score for the given unit (or the commander unit of the given vehicle).","syntaxes":[{"syntax":"unit addLiveStats score","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"score","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"score: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"score","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer addLiveStats 10;\n```","code":["player addLiveStats 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setArmoryPoints","unlockAchievement","setStatValue"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addMagazine","operator":null,"title":"addMagazine","type":"command","url":"https://community.bistudio.com/wiki/addMagazine","revid":369393,"updated":"2024-09-03T18:43:18Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds a magazine to a person. Infantry units can only carry a specific number of magazines, once the magazine slots are filled (or uniform/vest/bagpack are full in Arma 3), any further addMagazine commands are ignored.\nIf class of magazine does not exist, an error message is printed in .rpt:\n\n```sqf\nplayer addMagazine \"dasdsa\"; // .rpt: Given magazine[dasdsa] not found\n```\n\n> [!NOTE]\n> Use addMagazine *before* addWeapon for the weapon to be loaded with the magazine automatically.","syntaxes":[{"syntax":"unitName addMagazine magazineName Local ArgumentGlobal Effect","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":"person to add the magazines to","types":["Object"],"since":null,"text":"unitName: Object - person to add the magazines to"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":"magazine name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"magazineName: String - magazine name. See the topic Category:Weapons for reference about possible values."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"magazineName Local ArgumentGlobal Effect","types":[]}},{"syntax":"unitName addMagazine [magazineName, ammoCount] Arma 2: Operation Arrowhead v1.62 Local ArgumentGlobal Effect Arma 3 v1.00 Global ArgumentGlobal Effect","since":"arma2oa 1.62","effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":"person to add the magazines to","types":["Object"],"since":null,"text":"unitName: Object - person to add the magazines to"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":"magazine name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"magazineName: String - magazine name. See the topic Category:Weapons for reference about possible values."},{"name":"ammoCount","type":"Number","optional":false,"default":null,"description":"ammo quantity to be added to magazine. If it goes beyond maximum magazine capacity, the magazine will be given full and not overloaded.","types":["Number"],"since":null,"text":"ammoCount: Number - ammo quantity to be added to magazine. If it goes beyond maximum magazine capacity, the magazine will be given full and not overloaded."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"[magazineName, ammoCount] Arma 2: Operation Arrowhead v1.62 Local ArgumentGlobal Effect Arma 3 v1.00 Global ArgumentGlobal Effect","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer addMagazine \"30Rnd_556x45_STANAG\";\n```","code":["player addMagazine \"30Rnd_556x45_STANAG\";"]},{"text":"```sqf\nplayer addMagazine [\"30Rnd_556x45_STANAG\", 15];            // since Arma 2:OA 1.62\n```","code":["player addMagazine [\"30Rnd_556x45_STANAG\", 15];\t\t\t// since Arma 2:OA 1.62"]},{"text":"```sqf\nnonLocalUnit addMagazine [\"30Rnd_556x45_STANAG\", 15];    // global argument since Arma 3\n```","code":["nonLocalUnit addMagazine [\"30Rnd_556x45_STANAG\", 15];\t// global argument since Arma 3"]},{"text":"```sqf\nplayer addMagazine [\"30Rnd_556x45_STANAG\", 9999];        // will give a 30 rounds magazine anyway\n```","code":["player addMagazine [\"30Rnd_556x45_STANAG\", 9999];\t\t// will give a 30 rounds magazine anyway"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineGlobal","addMagazines","addMagazineCargo","addMagazineCargoGlobal","addMagazinePool","addMagazineTurret","removeMagazine","removeMagazines","addWeapon","loadMagazine"],"notes":[{"user":"Hoz","date":"2006-08-02T06:59:00Z","text":"If the unit has magazines already, you may need to use the commands removeMagazine or removeMagazines to make space for the mags you want to add."},{"user":"PhilippRauch","date":"2010-02-21T20:13:00Z","text":"In turreted vehicles the magazine is added to the first turret with >> primaryGunner = 1; << set in the Vehicles turret config part (and the magazine is ONLY added to the very first turret if more than one is configged with >> primaryGunner = 1; << )."},{"user":"Inkompetent","date":"2010-05-12T20:09:00Z","text":"When wanting to add many magazines to an object's init-line it can be easier to use loops than to just repeat the addMagazine command.\n\nIf you want to add N magazines to an object either of the two below ways are handy, the first for fewer magazines, and the latter when you want to add many since it then is the easiest of the two to read.\n\n```sqf\n{ this addMagazine \"magazineClassName\" } forEach [1,2,3, /*..., */ N];\nfor \"_i\" from 1 to N do { this addMagazine \"magazineClassName\" };\n```"},{"user":"Pisces_72","date":"2017-11-28T13:10:00Z","text":"If adding a magazine to an empty artillery support with this command in Arma 3, use reload. If you do not reload, Artillery calls will not fire rounds, because the AI won't reload automatically (tested with 82mm mortar)"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addMagazineAmmoCargo","operator":null,"title":"addMagazineAmmoCargo","type":"command","url":"https://community.bistudio.com/wiki/addMagazineAmmoCargo","revid":364935,"updated":"2024-07-01T19:04:37Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds magazines with specified ammo count to the cargo space of a vehicle or a container.","syntaxes":[{"syntax":"cargospace addMagazineAmmoCargo [magazine, quantity, ammocount]","since":null,"effect":null,"exec":null,"params":[{"name":"cargospace","type":"Object","optional":false,"default":null,"description":"vehicle or container or weaponholder","types":["Object"],"since":null,"text":"cargospace: Object - vehicle or container or weaponholder"},{"name":"magazine","type":"String","optional":false,"default":null,"description":"magazine class name","types":["String"],"since":null,"text":"magazine: String - magazine class name"},{"name":"quantity","type":"Number","optional":false,"default":null,"description":"number of magazines to add. Arma 3 v2.14 a negative value remove magazines","types":["Number"],"since":null,"text":"quantity: Number - number of magazines to add. Arma 3 v2.14 a negative value remove magazines"},{"name":"ammocount","type":"Number","optional":false,"default":null,"description":"ammo count in each magazine","types":["Number"],"since":null,"text":"ammocount: Number - ammo count in each magazine"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"cargospace","types":["Object"]},"right":{"text":"[magazine, quantity, ammocount]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ammobox addMagazineAmmoCargo [\"30Rnd_65x39_caseless_mag\", 2, 5];\n```","code":["_ammobox addMagazineAmmoCargo [\"30Rnd_65x39_caseless_mag\", 2, 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmoCargo","addMagazineCargo","addMagazineGlobal","addMagazine","addMagazines","addMagazinePool","addMagazineTurret","clearMagazineCargo","addWeaponCargo","clearWeaponCargo","addWeaponCargoGlobal","addBackpackCargoGlobal","addItemCargo","addItemCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addMagazineCargo","operator":null,"title":"addMagazineCargo","type":"command","url":"https://community.bistudio.com/wiki/addMagazineCargo","revid":376381,"updated":"2025-10-09T02:13:28Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Add magazines to the cargo space of vehicles, which can be taken out by infantry units. Once the magazine cargo space is filled up, any further addMagazineCargo commands are ignored.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, arguments for this command must be local (Local Argument). For the global variant see addMagazineCargoGlobal.","syntaxes":[{"syntax":"vehicleName addMagazineCargo [magazineName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":"vehicle to add the magazines to","types":["Object"],"since":null,"text":"vehicleName: Object - vehicle to add the magazines to"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":"magazine name. See Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"magazineName: String - magazine name. See Category:Weapons for reference about possible values."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of magazines to add. Arma 3 v2.14 negative count will remove magazines.","types":["Number"],"since":null,"text":"count: Number - number of magazines to add. Arma 3 v2.14 negative count will remove magazines."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"[magazineName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\n_truck addMagazineCargo [\"M16\", 5];\n```","code":["_truck addMagazineCargo [\"M16\", 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineCargoGlobal","addMagazine","addMagazineGlobal","addMagazines","addMagazinePool","addMagazineTurret","clearMagazineCargo","addWeaponCargo","clearWeaponCargo","getMagazineCargo","addItemCargo","addItemCargoGlobal","addMagazineAmmoCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addMagazineCargoGlobal","operator":null,"title":"addMagazineCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/addMagazineCargoGlobal","revid":376382,"updated":"2025-10-09T02:13:45Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Add magazines to the cargo space of vehicles, which can be taken out by infantry units.\n\nMP Synchronized","syntaxes":[{"syntax":"vehicleName addMagazineCargoGlobal [magazineName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":"vehicle to add the magazines to","types":["Object"],"since":null,"text":"vehicleName: Object - vehicle to add the magazines to"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":"magazine name. See Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"magazineName: String - magazine name. See Category:Weapons for reference about possible values."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of magazines to add. Arma 3 v2.14 negative count will remove magazines.","types":["Number"],"since":null,"text":"count: Number - number of magazines to add. Arma 3 v2.14 negative count will remove magazines."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"[magazineName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\n_truck addMagazineCargoGlobal [\"M16\", 5];\n```","code":["_truck addMagazineCargoGlobal [\"M16\", 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineCargo","addMagazineGlobal","addMagazine","addMagazines","addMagazinePool","addMagazineTurret","clearMagazineCargo","addWeaponCargo","clearWeaponCargo","addWeaponCargoGlobal","addBackpackCargoGlobal","addItemCargo","addItemCargoGlobal","addMagazineAmmoCargo"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addMagazineGlobal","operator":null,"title":"addMagazineGlobal","type":"command","url":"https://community.bistudio.com/wiki/addMagazineGlobal","revid":318776,"updated":"2022-05-13T09:21:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds magazine to a unit regardless of locality. This command can also be used to add magazine to a vehicle, like a static gun, for example.","syntaxes":[{"syntax":"unit addMagazineGlobal magazineName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"magazineName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addMagazineGlobal \"30Rnd_65x39_caseless_mag\";\n```","code":["player addMagazineGlobal \"30Rnd_65x39_caseless_mag\";"]}],"multiplayer":"Before Arma 3 v2.00 this command was broken in MP and duplicated items per the number of clients.","problems":null,"aliases":[],"see_also":["addMagazine","addMagazines","addMagazineCargo","addMagazineCargoGlobal","addMagazinePool","addMagazineTurret","addMagazineAmmoCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addMagazinePool","operator":null,"title":"addMagazinePool","type":"command","url":"https://community.bistudio.com/wiki/addMagazinePool","revid":364168,"updated":"2024-05-05T10:46:43Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds magazines to the magazine pool, of which the player may choose in the following mission. Available in campaigns only.","syntaxes":[{"syntax":"addMagazinePool [magazineName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"magazineName","type":"String","optional":false,"default":null,"description":"magazine class name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"magazineName: String - magazine class name. See the topic Category:Weapons for reference about possible values."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of magazines to add","types":["Number"],"since":null,"text":"count: Number - number of magazines to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[magazineName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\naddMagazinePool [\"M16\", 20];\n```","code":["addMagazinePool [\"M16\", 20];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearMagazinePool","queryMagazinePool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addMagazines","operator":null,"title":"addMagazines","type":"command","url":"https://community.bistudio.com/wiki/addMagazines","revid":343753,"updated":"2023-07-16T17:29:01Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds multiple magazines to the unit. For cargo containers use addMagazineCargoGlobal command.\n\n> [!NOTE]\n> This command is meant to be used on human units. If used on vehicles, this command is Local Argument Global Effect.","syntaxes":[{"syntax":"unit addMagazines [magazineName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"a soldier","types":["Object"],"since":null,"text":"unit: Object - a soldier"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of magazines","types":["Number"],"since":null,"text":"count: Number - number of magazines"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[magazineName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer addMagazines [\"30Rnd_65x39_caseless_mag\", 3];\n```","code":["player addMagazines [\"30Rnd_65x39_caseless_mag\", 3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineGlobal","addMagazine","addMagazineCargo","addMagazineCargoGlobal","addMagazinePool","addMagazineTurret","addMagazineAmmoCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addMagazinesTurret","operator":null,"title":"addMagazinesTurret","type":"command","url":"https://community.bistudio.com/wiki/addMagazinesTurret","revid":377487,"updated":"2026-01-02T06:49:07Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds given number of a magazine to the given turret. Use turret path `[-1]` for driver's turret.","syntaxes":[{"syntax":"vehicle addMagazinesTurret [magazineName, turretPath, quantity]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"quantity","type":"Number","optional":false,"default":null,"description":"desired number of the magazines","types":["Number"],"since":null,"text":"quantity: Number - desired number of the magazines"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineName, turretPath, quantity]","types":["Array"]}}],"examples":[{"text":"```sqf\n_tank addMagazinesTurret [\"20Rnd_120mmSABOT_M1A2\", [0], 10];\n```","code":["_tank addMagazinesTurret [\"20Rnd_120mmSABOT_M1A2\", [0], 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineTurret","addMagazineGlobal","addMagazine","loadMagazine","addMagazines","addMagazineCargo","addMagazineCargoGlobal","addMagazinePool","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","addMagazineAmmoCargo","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.20","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addMagazineTurret","operator":null,"title":"addMagazineTurret","type":"command","url":"https://community.bistudio.com/wiki/addMagazineTurret","revid":377495,"updated":"2026-01-02T06:49:20Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds a magazine to the turret. Use turret path `[-1]` for driver's turret.\n\n> [!IMPORTANT]\n> Invalid combinations may be created by using this command, for example by adding 20 grenades. In these cases, behaviour is undefined.","syntaxes":[{"syntax":"vehicle addMagazineTurret [magazineName, turretPath, ammoCount]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"ammoCount","type":"Number","optional":true,"default":"0","description":"desired ammo count","types":["Number"],"since":"arma3 1.56","text":"ammoCount: Number - (Optional, default 0) desired ammo count"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineName, turretPath, ammoCount]","types":["Array"]}}],"examples":[{"text":"```sqf\n_tank addMagazineTurret [\"SmokeLauncherMag\", [0,0]];\n```","code":["_tank addMagazineTurret [\"SmokeLauncherMag\", [0,0]];"]},{"text":"```sqf\n_tank addMagazineTurret [\"20Rnd_120mmSABOT_M1A2\", [0]];\n```","code":["_tank addMagazineTurret [\"20Rnd_120mmSABOT_M1A2\", [0]];"]},{"text":"```sqf\n_tank addMagazineTurret [\"20Rnd_120mmSABOT_M1A2\", [0], 10]; // add magazine with 10 rounds\n```","code":["_tank addMagazineTurret [\"20Rnd_120mmSABOT_M1A2\", [0], 10]; // add magazine with 10 rounds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazinesTurret","addMagazineGlobal","addMagazine","loadMagazine","addMagazines","addMagazineCargo","addMagazineCargoGlobal","addMagazinePool","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","addMagazineAmmoCargo","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2: Operation Arrowhead version 1.52","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addMenu","operator":null,"title":"addMenu","type":"command","url":"https://community.bistudio.com/wiki/addMenu","revid":363584,"updated":"2024-04-07T14:55:34Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds a new menu button. Priority is optional.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map addMenu [text, priority]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"},{"name":"priority","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"priority: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[text, priority]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addMenuItem","operator":null,"title":"addMenuItem","type":"command","url":"https://community.bistudio.com/wiki/addMenuItem","revid":363254,"updated":"2024-03-26T10:51:30Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a new menu item. Menu can be \"file\" or \"view\",index is index,as returned from addMenu command. priority is optional and determines,where in the menu the item will reside (higher priority items first).\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map addMenuItem [menu or index,text,command,priority]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[menu or index,text,command,priority]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[menu or index,text,command,priority]: Array"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[menu or index,text,command,priority]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Game 2 Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addMissionEventHandler","operator":null,"title":"addMissionEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addMissionEventHandler","revid":377813,"updated":"2026-01-03T04:12:00Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Adds event handler attached to the current mission and returns event handler handle. For the list of available mission event handlers see: Arma 3: Mission Event Handlers","syntaxes":[{"syntax":"addMissionEventHandler [event, expression, arguments]","since":null,"effect":null,"exec":null,"params":[{"name":"event","type":"String","optional":false,"default":null,"description":"event name","types":["String"],"since":null,"text":"event: String - event name"},{"name":"expression","type":"Code or String","optional":false,"default":null,"description":"expression that will be executed in missionNamespace when event handler fires.\n- If the event handler has some data to return upon activation they are stored in the `_this` variable\n- Arma 3 v1.64 the event handler's handle is stored in `_thisEventHandler` variable and is available during event handler code execution\n- Arma 3 v2.04 it is possible to pass additional arguments to the EH code via optional param. The *args* are stored in `_thisArgs` variable\n\n> [!IMPORTANT]\n> Only arguments of simple types get proper serialization. Objects, Groups etc will not serialize and appear as NULLs on game load.\n\n- Arma 3 v2.06 the event's name is available from `_thisEvent` variable","types":["Code","String"],"since":null,"text":"expression: Code or String - expression that will be executed in missionNamespace when event handler fires.\n- If the event handler has some data to return upon activation they are stored in the `_this` variable\n- Arma 3 v1.64 the event handler's handle is stored in `_thisEventHandler` variable and is available during event handler code execution\n- Arma 3 v2.04 it is possible to pass additional arguments to the EH code via optional param. The *args* are stored in `_thisArgs` variable\n\n> [!IMPORTANT]\n> Only arguments of simple types get proper serialization. Objects, Groups etc will not serialize and appear as NULLs on game load.\n\n- Arma 3 v2.06 the event's name is available from `_thisEvent` variable"},{"name":"arguments","type":"Array of Anything","optional":true,"default":"`[]`","description":"additional arguments to be passed to the EH code. Available during code execution via `_thisArgs` variable.","types":["Array","Anything"],"since":"arma3 2.04","text":"arguments: Array of Anything - (Optional, default `[]`) additional arguments to be passed to the EH code. Available during code execution via `_thisArgs` variable."}],"returns":{"type":"Number","types":["Number"],"description":"the index of the currently added mission event handler is returned","text":"Number - the index of the currently added mission event handler is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"[event, expression, arguments]","types":["Array"]}}],"examples":[{"text":"```sqf\n_id = addMissionEventHandler [\"PlayerDisconnected\", { systemChat str _this }];\n```","code":["_id = addMissionEventHandler [\"PlayerDisconnected\", { systemChat str _this }];"]},{"text":"```sqf\n_id = addMissionEventHandler [\"EachFrame\", { systemChat str [_thisArgs, time] }, [time]];\n```","code":["_id = addMissionEventHandler [\"EachFrame\", { systemChat str [_thisArgs, time] }, [time]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMissionEventHandler","removeAllMissionEventHandlers","getEventHandlerInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addMPEventHandler","operator":null,"title":"addMPEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addMPEventHandler","revid":369855,"updated":"2024-10-16T13:52:05Z","groups":["Multiplayer","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds a multiplayer event handler (EH) to the given object and returns EH handle. See Event Handlers.\n\n> [!IMPORTANT]\n> A Multiplayer Event Handler is **not** saved in a save file and therefore will not be restored on load - use it accordingly.","syntaxes":[{"syntax":"object addMPEventHandler [type, expression]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to monitor","types":["Object"],"since":null,"text":"object: Object - object to monitor"},{"name":"type","type":"String","optional":false,"default":null,"description":"event handler name","types":["String"],"since":null,"text":"type: String - event handler name"},{"name":"expression","type":"String or Code","optional":false,"default":null,"description":"expression to execute.\n\nIf EH has some data to return upon event (e.g. the \"MPKilled\" EH will return an array with 2 elements: the killed unit, and the killer), it is passed in `_this` variable.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v.1.64 the EH handle is also stored in `_thisEventHandler` variable and is available during EH code execution.\n\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`","types":["String","Code"],"since":null,"text":"expression: String or Code - expression to execute.\n\nIf EH has some data to return upon event (e.g. the \"MPKilled\" EH will return an array with 2 elements: the killed unit, and the killer), it is passed in `_this` variable.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v.1.64 the EH handle is also stored in `_thisEventHandler` variable and is available during EH code execution.\n\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`"}],"returns":{"type":"Number","types":["Number"],"description":"event handler index","text":"Number - event handler index"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[type, expression]","types":["Array"]}}],"examples":[{"text":"```sqf\n_index = player addMPEventHandler [\"MPKilled\", { _this execVM \"playerKilled.sqf\"; }];\n```","code":["_index = player addMPEventHandler [\"MPKilled\", { _this execVM \"playerKilled.sqf\"; }];"]}],"multiplayer":"Multiplayer EHs are added globally to every client and the server will fire on itself and every client upon event.\nThe only exception is the **MPRespawn** EH that one only fires where the respawned unit is local. Make sure to check the EHs' locality in Event Handlers pages.","problems":null,"aliases":[],"see_also":["removeMPEventHandler","removeAllMPEventHandlers","getEventHandlerInfo"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addMusicEventHandler","operator":null,"title":"addMusicEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addMusicEventHandler","revid":370195,"updated":"2024-11-06T12:01:24Z","groups":["Event Handlers","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Adds playMusic event handler. Returns id of the handler or -1 when failed. Like addMissionEventHandler, the music event handler is attached to the mission.\nSee Arma 3: Event Handlers#Music Event Handlers.","syntaxes":[{"syntax":"addMusicEventHandler [type, function]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"\"MusicStart\" or \"MusicStop\"","types":["String"],"since":null,"text":"type: String - \"MusicStart\" or \"MusicStop\""},{"name":"function","type":"String or Code","optional":false,"default":null,"description":"passed params array is [musicClassname, eventHandlerId] where:\n\n```sqf\nparams [\"_musicClassname\", \"_eventHandlerId\", \"_currentPosition\", \"_totalLength\"];\n```\n\n- musicClassName: String - CfgMusic class name of the music that started\n- eventHandlerId: Number - event handler id (same as returned by addMusicEventHandler usage)\n- Arma 3 v2.18 currentPosition: Number - current playback position in 0..1 range (see getMusicPlayedTime)\n- Arma 3 v2.18 totalLength: Number - track total length in seconds","types":["String","Code"],"since":null,"text":"function: String or Code - passed params array is [musicClassname, eventHandlerId] where:\n\n```sqf\nparams [\"_musicClassname\", \"_eventHandlerId\", \"_currentPosition\", \"_totalLength\"];\n```\n\n- musicClassName: String - CfgMusic class name of the music that started\n- eventHandlerId: Number - event handler id (same as returned by addMusicEventHandler usage)\n- Arma 3 v2.18 currentPosition: Number - current playback position in 0..1 range (see getMusicPlayedTime)\n- Arma 3 v2.18 totalLength: Number - track total length in seconds"}],"returns":{"type":"Number","types":["Number"],"description":"event handler id","text":"Number - event handler id"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, function]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _ehID = addMusicEventHandler [\"MusicStart\", { hint str _this }];\n```","code":["private _ehID = addMusicEventHandler [\"MusicStart\", { hint str _this }];"]},{"text":"```sqf\nprivate _ehID = addMusicEventHandler [\"MusicStop\", { hint str _this }];\n```","code":["private _ehID = addMusicEventHandler [\"MusicStop\", { hint str _this }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMusicEventHandler","playMusic","removeAllMusicEventHandlers","getEventHandlerInfo"],"notes":[{"user":"Druid","date":"2013-03-04T13:30:00Z","text":"There are these two types at this time:\n- **MusicStart** - It is triggered when the music is started (command playMusic). In variable _this is stored class name from CfgMusic.\n- **MusicStop** - It is triggered when the music is ended (command playMusic). In variable _this is stored class name from CfgMusic."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Sounds","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addonFiles","operator":null,"title":"addonFiles","type":"command","url":"https://community.bistudio.com/wiki/addonFiles","revid":378237,"updated":"2026-03-20T14:02:49Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of files present in the addon.\n\n> [!NOTE]\n> Querying protected `.ebo` addons will return an empty array `[]`.","syntaxes":[{"syntax":"addonFiles [prefix, fileExtension]","since":null,"effect":null,"exec":null,"params":[{"name":"prefix","type":"String","optional":false,"default":null,"description":"addon prefix available from allAddonsInfo. Since Arma 3 v2.22 it is possible to also return all files present in a scenario folder from within Eden Editor or Eden preview with the special prefix `$mission`","types":["String"],"since":null,"text":"prefix: String - addon prefix available from allAddonsInfo. Since Arma 3 v2.22 it is possible to also return all files present in a scenario folder from within Eden Editor or Eden preview with the special prefix `$mission`"},{"name":"fileExtension","type":"String","optional":true,"default":null,"description":"file extension to filter results, for example `\".paa\"`","types":["String"],"since":null,"text":"fileExtension: String - (Optional) file extension to filter results, for example `\".paa\"`"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[prefix, fileExtension]","types":["Array"]}}],"examples":[{"text":"```sqf\naddonFiles [\"a3\\3den\\\", \".paa\"];\n/*\n    [\n        \"a3\\3den\\data\\attributes\\formation\\ech_left_ca.paa\",\n        \"a3\\3den\\data\\attributes\\formation\\stag_column_ca.paa\",\n        \"a3\\3den\\data\\attributes\\stance\\down_ca.paa\",\n        \"a3\\3den\\data\\cfg3den\\layer\\icondisabled_ca.paa\",\n        \"a3\\3den\\data\\controlsgroups\\diagmousecontrol\\mouse_ca.paa\",\n        ...\n    ]\n*/\n```","code":["addonFiles [\"a3\\3den\\\", \".paa\"];\n/*\n\t[\n\t\t\"a3\\3den\\data\\attributes\\formation\\ech_left_ca.paa\",\n\t\t\"a3\\3den\\data\\attributes\\formation\\stag_column_ca.paa\",\n\t\t\"a3\\3den\\data\\attributes\\stance\\down_ca.paa\",\n\t\t\"a3\\3den\\data\\cfg3den\\layer\\icondisabled_ca.paa\",\n\t\t\"a3\\3den\\data\\controlsgroups\\diagmousecontrol\\mouse_ca.paa\",\n\t\t...\n\t]\n*/"]},{"text":"```sqf\n// Since Arma 3 2.22\naddonFiles [\"$mission\", \".sqf\"];\n```","code":["// Since Arma 3 2.22\naddonFiles [\"$mission\", \".sqf\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allAddonsInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"addOwnedMine","operator":null,"title":"addOwnedMine","type":"command","url":"https://community.bistudio.com/wiki/addOwnedMine","revid":376880,"updated":"2025-12-15T16:39:34Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets ownership of a remotely detonatable mine to a unit. If the unit is a player, an action that allows the player to detonate the mine is added to the action menu.","syntaxes":[{"syntax":"unit addOwnedMine mine","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mine","type":"Object","optional":false,"default":null,"description":"the mine object","types":["Object"],"since":null,"text":"mine: Object - the mine object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mine","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer addOwnedMine _superMine;\n```","code":["player addOwnedMine _superMine;"]}],"multiplayer":"Multiple players can own the same mine.","problems":null,"aliases":[],"see_also":["allMines","createMine","detectedMines","mineActive","getAllOwnedMines","removeOwnedMine","removeAllOwnedMines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addPlayerScores","operator":null,"title":"addPlayerScores","type":"command","url":"https://community.bistudio.com/wiki/addPlayerScores","revid":376997,"updated":"2026-01-01T08:05:12Z","groups":["Object Manipulation","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"MP server only: Adds player score.\n\n|  |  |  |  |  |  |\n|---|---|---|---|---|---|\n| Kill Type | infantry | soft | armor | air | killed |\n| Score Points | 1 | 2 | 3 | 5 | -1 |","syntaxes":[{"syntax":"unit addPlayerScores values","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"values","type":"Array with [killsInfantry, killsSoft, killsArmor, killsAir, score]","optional":false,"default":null,"description":"Array with [killsInfantry, killsSoft, killsArmor, killsAir, score]\n- killsInfantry: Number - number of infantry units killed\n- killsSoft: Number - number of soft vehicles killed\n- killsArmor: Number - number of armored vehicles killed\n- killsAir: Number - number of air vehicles killed\n- score: Number - total score","types":["Array"],"since":null,"text":"values: Array with [killsInfantry, killsSoft, killsArmor, killsAir, score]\n- killsInfantry: Number - number of infantry units killed\n- killsSoft: Number - number of soft vehicles killed\n- killsArmor: Number - number of armored vehicles killed\n- killsAir: Number - number of air vehicles killed\n- score: Number - total score"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"values","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer addPlayerScores [0, 1, 0, 0, 1];\n```","code":["player addPlayerScores [0, 1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addScore","addScoreSide","getPlayerScores","score","scoreSide"],"notes":[{"user":"Beno 83au","date":"2017-05-02T01:48:00Z","text":"As this command will add the given number to a player's score, a little bit of thought needs to be given to friendly-fire if it is for something like a deathmatch or a FFA, due to friendly-fire incurring negative points.\nSo to counter this just add 2 points every time a player kills a unit from the same side:\n\n```sqf\nplayer addPlayerScores [2, 0, 0, 0, 0];\n```\n\nThe 2 points will add 1 point to counter the negative friendly-fire point and 1 point to add correctly to the score."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Manipulation","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"addPrimaryWeaponItem","operator":null,"title":"addPrimaryWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/addPrimaryWeaponItem","revid":347500,"updated":"2023-09-24T01:03:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds weapon item, including magazine, directly to the primaryWeapon. This is used for infantry weapons.","syntaxes":[{"syntax":"unit addPrimaryWeaponItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing or Boolean","types":["Nothing","Boolean"],"description":"false is returned if item can not be added","text":"Nothing or Boolean - **false** is returned if **item** can not be added"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addPrimaryWeaponItem \"muzzle_snds_H\";\n```","code":["player addPrimaryWeaponItem \"muzzle_snds_H\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponItem","removePrimaryWeaponItem","removeAllPrimaryWeaponItems","addSecondaryWeaponItem","addHandgunItem","addBinocularItem","weaponsItems","handgunItems","primaryWeaponItems","secondaryWeaponItems","binocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addPublicVariableEventHandler","operator":null,"title":"addPublicVariableEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addPublicVariableEventHandler","revid":376526,"updated":"2025-10-24T10:02:40Z","groups":["Broken Commands","Event Handlers","Multiplayer","Variables"],"status":"broken","replaced_by":["remoteExec","remoteExecCall"],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"> [!NOTE]\n> This command is deprecated since Arma 3 v1.52 and the introduction of remoteExec and remoteExecCall.\n\nThis event handler will detect if a missionNamespace variable (it is attached to) has been broadcast over network with publicVariable, publicVariableClient or publicVariableServer commands and will execute EH code upon detection.\n\n> [!NOTE]\n> - This EH works **only** in Multiplayer environment\n> - There is **no way** to remove this EH\n> - This EH will not fire on the machine that executed broadcast with publicVariable command, only on the machines that receive the broadcast\n> - The value of broadcast variable can be exactly the same, it is the actual broadcast that triggers EH not the change in variable","syntaxes":[{"syntax":"varName addPublicVariableEventHandler code","since":null,"effect":null,"exec":null,"params":[{"name":"varName","type":"String","optional":false,"default":null,"description":"missionNamespace variable name","types":["String"],"since":null,"text":"varName: String - missionNamespace variable name"},{"name":"code","type":"Code","optional":false,"default":null,"description":"by default, the code is executed in missionNamespace. `_this` arguments array is in format [varName, value, target]:\n- varName: String - broadcast variable name (same variable name EH is attached to)\n- value: Anything - broadcast variable value\n- target: Object or Group - target the variable got set on with setVariable (see #Alternative Syntax)","types":["Code"],"since":null,"text":"code: Code - by default, the code is executed in missionNamespace. `_this` arguments array is in format [varName, value, target]:\n- varName: String - broadcast variable name (same variable name EH is attached to)\n- value: Anything - broadcast variable value\n- target: Object or Group - target the variable got set on with setVariable (see #Alternative Syntax)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"varName","types":["String"]},"right":{"text":"code","types":["Code"]}},{"syntax":"varName addPublicVariableEventHandler [target, code]","since":"arma3 1.46","effect":null,"exec":null,"params":[{"name":"varName","type":"String","optional":false,"default":null,"description":"name of the variable set on target with setVariable","types":["String"],"since":null,"text":"varName: String - name of the variable set on target with setVariable"},{"name":"target","type":"Object, Group or Team Member","optional":false,"default":null,"description":null,"types":["Object","Group","Team Member"],"since":null,"text":"target: Object, Group or Team Member"},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"varName","types":["String"]},"right":{"text":"[target, code]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"publicThis\" addPublicVariableEventHandler {\n    _varName = _this select 0;\n    _value = _this select 1;\n    _target = _this select 2;\n    hint format [\"%1 has been updated to %2 for %3\", _varName, _value, target];\n};\n```","code":["\"publicThis\" addPublicVariableEventHandler {\n\t_varName = _this select 0;\n\t_value = _this select 1;\n\t_target = _this select 2;\n\thint format [\"%1 has been updated to %2 for %3\", _varName, _value, target];\n};"]},{"text":"Client:\n\n```sqf\n\"'^:)123BURP,+=lol\" addPublicVariableEventHandler {hint (\"NUTS are \" + (_this select 1))};\n```\n\nServer:\n\n```sqf\nmissionNamespace setVariable [\"'^:)123BURP,+=lol\", \"craZZZZy\"];\npublicVariable \"'^:)123BURP,+=lol\";\n```","code":["\"'^:)123BURP,+=lol\" addPublicVariableEventHandler {hint (\"NUTS are \" + (_this select 1))};","missionNamespace setVariable [\"'^:)123BURP,+=lol\", \"craZZZZy\"];\npublicVariable \"'^:)123BURP,+=lol\";"]}],"multiplayer":null,"problems":"> [!WARNING]\n> The #Alternative Syntax does not work as intended.","aliases":[],"see_also":["publicVariable","publicVariableClient","publicVariableServer"],"notes":[{"user":"TeRp","date":"2007-12-22T13:30:00Z","text":"Please note that varName indicates which variable you want to monitor with this eventhandler.\n\nAs a result, the example eventhandler on this page will only fire when the variable publicThis has been changed,\nbut not if any other variable was changed by any other client via the publicVariable command."},{"user":"MulleDK13","date":"2014-02-27T00:57:00Z","text":"Note on using addPublicVariableEventHandler during initialization: If you need a function to call addPublicVariableEventHandler during initialization, you must use postInit. addPublicVariableEventHandler does not work during preInit."},{"user":"Killzone_Kid","date":"2014-02-27T08:40:00Z","text":"MulleDK13's note above needs some clarification. You don't \"must\" use postInit and you absolutely can use preInit function to initialise addPublicVariableEventHandler if you start scheduled script from it.\n\n```sqf\n// script with preInit = 1; in CfgFunctions\n0 spawn {\n    \"someVar\" addPublicVariableEventHandler {\n        // yourcode\n    };\n};\n```"},{"user":"SilentSpike","date":"2015-11-23T21:36:00Z","text":"While it is true that the event handler will only fire on the machine receiving the broadcast value, please note that this machine can actually be the same machine broadcasting it in the cases of publicVariableClient and publicVariableServer.\n\nExamples:\n\n```sqf\nif (isServer) then\n{\n    \"OnServer\" addPublicVariableEventHandler { hint \"This event handler still fired!\"; };\n    publicVariableServer \"OnServer\";\n};\n```\n\n```sqf\n// This example assumes the client knows their own client ID\n// It does also work on the server (when the server ID is used) irrespective of the command name\n\n\"OnClient\" addPublicVariableEventHandler { hint \"This event handler still fired!\"; };\nclientID publicVariableClient \"OnClient\";\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Event Handlers","Command Group: Multiplayer","Command Group: Variables","Introduced with Armed Assault version 1.09","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addRating","operator":null,"title":"addRating","type":"command","url":"https://community.bistudio.com/wiki/addRating","revid":353042,"updated":"2024-03-12T12:07:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Add a number to the rating of a unit - negative values can be used to reduce the rating.\n\nThis command is usually used to reward for completed mission objectives.The rating is given at the end of the mission and is automatically adjusted when killing enemies or friendlies.\n\nWhen the rating gets below -2000, the unit's side switches to sideEnemy and the unit is attacked by everyone.\n\n> [!NOTE]\n> See also ArmA: Armed Assault: Rating Values and Arma 3: Event Handlers#HandleRating.","syntaxes":[{"syntax":"unitName addRating rating","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"rating","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rating: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"rating","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer addRating 2000;\n```","code":["player addRating 2000;"]},{"text":"Set the rating to a specific value:\n\n```sqf\nprivate _wantedRating = 9001;\nplayer addRating (_wantedRating - rating player);\n```","code":["private _wantedRating = 9001;\nplayer addRating (_wantedRating - rating player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side Relations","ArmA: Rating Values","rating","rank","setUnitRank","sideEnemy"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addResources","operator":null,"title":"addResources","type":"command","url":"https://community.bistudio.com/wiki/addResources","revid":351337,"updated":"2023-11-27T10:06:14Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Adds resources to a team member.","syntaxes":[{"syntax":"teamMember addResources [resource1, resource2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"},{"name":"resourceN","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"resourceN: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"[resource1, resource2, ...]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["resources","deleteResources"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addScore","operator":null,"title":"addScore","type":"command","url":"https://community.bistudio.com/wiki/addScore","revid":310138,"updated":"2022-05-05T12:27:54Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Adds a number to the score of a unit. Negative values will remove from the score.","syntaxes":[{"syntax":"unit addScore score","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"score","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"score: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"score","types":["Number"]}}],"examples":[{"text":"```sqf\nunit addScore 10;\n```","code":["unit addScore 10;"]},{"text":"```sqf\nunit addScore -1337; // reduce the unit's score by 1337 points\n```","code":["unit addScore -1337; // reduce the unit's score by 1337 points"]}],"multiplayer":"Server execution only","problems":null,"aliases":[],"see_also":["score","scoreSide","addScoreSide","getPlayerScores","Arma 3: Event Handlers"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"addScoreSide","operator":null,"title":"addScoreSide","type":"command","url":"https://community.bistudio.com/wiki/addScoreSide","revid":318736,"updated":"2022-05-13T09:21:24Z","groups":["Sides","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Adds side score. This is shown in the MP score tab as the total score. **MP only**.","syntaxes":[{"syntax":"side addScoreSide value","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"side","types":["Side"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nwest addScoreSide 10;\n```","code":["west addScoreSide 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["score","addScore","scoreSide","getPlayerScores"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Sides","Introduced with Arma 3 version 1.12","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"addSecondaryWeaponItem","operator":null,"title":"addSecondaryWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/addSecondaryWeaponItem","revid":318671,"updated":"2022-05-13T09:21:17Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds weapon item, including magazine, directly to the secondaryWeapon. This is used for infantry weapons.","syntaxes":[{"syntax":"unit addSecondaryWeaponItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addSecondaryWeaponItem \"muzzle_snds_L\";\n```","code":["player addSecondaryWeaponItem \"muzzle_snds_L\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponItem","addPrimaryWeaponItem","addHandgunItem","addBinocularItem","weaponsItems","handgunItems","primaryWeaponItems","secondaryWeaponItems","binocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addSwitchableUnit","operator":null,"title":"addSwitchableUnit","type":"command","url":"https://community.bistudio.com/wiki/addSwitchableUnit","revid":325232,"updated":"2022-07-04T10:32:04Z","groups":["Team Switch"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds a unit to the list of units available for Team Switch. Units marked as playable in editor are automatically switchable.\nThis command adds non-playable unit into array of switchableUnits and makes them available for teamSwitch. **Singleplayer only!**","syntaxes":[{"syntax":"addSwitchableUnit unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\naddSwitchableUnit bob;\n```","code":["addSwitchableUnit bob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["teamSwitch","removeSwitchableUnit","switchableUnits"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addTeamMember","operator":null,"title":"addTeamMember","type":"command","url":"https://community.bistudio.com/wiki/addTeamMember","revid":310084,"updated":"2022-05-05T12:25:11Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Add given member to given team. Effect is local, unless both member and team are local to PC on which command is executed, then effect is global.\n\n The same Team Member can be member of several different teams at the same time.","syntaxes":[{"syntax":"team addTeamMember member","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"},{"name":"member","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"member: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"team","types":["Team Member"]},"right":{"text":"member","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_team addTeamMember _teamMember;\n```","code":["_team addTeamMember _teamMember;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addToRemainsCollector","operator":null,"title":"addToRemainsCollector","type":"command","url":"https://community.bistudio.com/wiki/addToRemainsCollector","revid":353431,"updated":"2024-03-18T11:57:19Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds an array of vehicles/units to disposal manager for automatic wreck/body removal. The disposal manager follows wreck/body removal values set in description.ext","syntaxes":[{"syntax":"addToRemainsCollector remains","since":null,"effect":null,"exec":null,"params":[{"name":"remains","type":"Array of Objects","optional":false,"default":null,"description":"array of vehicles/units","types":["Array","Object"],"since":null,"text":"remains: Array of Objects - array of vehicles/units"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"remains","types":["Array","Object"]}}],"examples":[{"text":"```sqf\naddToRemainsCollector [unit1, unit2, vehicle1];\n```","code":["addToRemainsCollector [unit1, unit2, vehicle1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeFromRemainsCollector","isInRemainsCollector","diag_remainsCollector"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addTorque","operator":null,"title":"addTorque","type":"command","url":"https://community.bistudio.com/wiki/addTorque","revid":377433,"updated":"2026-01-02T06:46:20Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Applies torque (rotation momentum) to the center of mass of the given object. Torque force is defined as vector [x, y, z] applied in world space. If you need to define torque in model space, convert the torque vector first by vectorModelToWorld or vectorModelToWorldVisual command. The torque applied as impulse. Diagram below explain which way the object would rotate.  For more information see [NVIDIA docs](http://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/classPxRigidBody.html#acb04ffc816d45afff2d04e93d7446e79)\n\n> [!NOTE]\n> A single application of torque would produce one impulse, which may not be enough. In this case consider applying a series of continuous impulses, for example to make a quad bike to roll forward:\n>\n> ```sqf\n> onEachFrame { quad addTorque (quad vectorModelToWorld [100,0,0]) };\n> ```\n\n> [!IMPORTANT]\n> This command doesn't follow convention for torque direction, which obeys right-hand rule. To comply, negate all values in the vector.","syntaxes":[{"syntax":"object addTorque torque","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"PhysX object","types":["Object"],"since":null,"text":"object: Object - PhysX object"},{"name":"torque","type":"Vector3D","optional":false,"default":null,"description":"world vector in format [x,y,z]","types":["Vector3D"],"since":null,"text":"torque: Vector3D - world vector in format [x,y,z]"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"torque","types":["Vector3D"]}}],"examples":[{"text":"Apply torque [1000,0,0] to object not factoring object positioning:\n\n```sqf\n_wheel addTorque [1000,0,0];\n```","code":["_wheel addTorque [1000,0,0];"]},{"text":"Apply torque [1000,0,0] relative to object:\n\n```sqf\n_wheel addTorque (_wheel vectorModelToWorld [1000,0,0]);\n```","code":["_wheel addTorque (_wheel vectorModelToWorld [1000,0,0]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addForce","awake","isAwake","vectorModelToWorld","vectorModelToWorldVisual","disableBrakes","brakesDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.72","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addUniform","operator":null,"title":"addUniform","type":"command","url":"https://community.bistudio.com/wiki/addUniform","revid":318775,"updated":"2022-05-13T09:21:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create a new uniform and try to link it into uniform slot (given uniform has to be supported by allowedUniforms list of target soldier).\n\n> [!NOTE]\n> To check if a uniform is allowed use isUniformAllowed, and to force an incompatible uniform use forceAddUniform.","syntaxes":[{"syntax":"unit addUniform type","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_unit addUniform \"U_B_CombatUniform_mcam\";\n```","code":["_unit addUniform \"U_B_CombatUniform_mcam\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceAddUniform","isUniformAllowed","removeUniform","uniform"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addUserActionEventHandler","operator":null,"title":"addUserActionEventHandler","type":"command","url":"https://community.bistudio.com/wiki/addUserActionEventHandler","revid":378187,"updated":"2026-03-10T13:05:46Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Adds a user action event handler to the current mission and returns its event handler index.","syntaxes":[{"syntax":"addUserActionEventHandler [keyName, event, expression]","since":null,"effect":null,"exec":null,"params":[{"name":"keyName","type":"String","optional":false,"default":null,"description":"action key name - see inputAction/actions","types":["String"],"since":null,"text":"keyName: String - action key name - see inputAction/actions"},{"name":"event","type":"String","optional":false,"default":null,"description":"event name - see UserAction Event Handlers. Can be one of:\n- `\"Activate\"`\n- `\"Deactivate\"`\n- `\"Analog\"`","types":["String"],"since":null,"text":"event: String - event name - see UserAction Event Handlers. Can be one of:\n- `\"Activate\"`\n- `\"Deactivate\"`\n- `\"Analog\"`"},{"name":"expression","type":"Code","optional":false,"default":null,"description":"expression that will be executed in missionNamespace when event handler fires.\n- `_thisEventHandler` returns the event handler index\n- `_thisEvent` returns the event type (the *event* parameter, either `\"Activate\"`, `\"Deactivate\"` or `\"Analog\"`)","types":["Code"],"since":null,"text":"expression: Code - expression that will be executed in missionNamespace when event handler fires.\n- `_thisEventHandler` returns the event handler index\n- `_thisEvent` returns the event type (the *event* parameter, either `\"Activate\"`, `\"Deactivate\"` or `\"Analog\"`)"}],"returns":{"type":"Number","types":["Number"],"description":"the index of the currently added UserAction event handler is returned","text":"Number - the index of the currently added UserAction event handler is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"[keyName, event, expression]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _ehId = addUserActionEventHandler [\"ReloadMagazine\", \"Activate\", { systemChat \"reloading!\"; }];\n```","code":["private _ehId = addUserActionEventHandler [\"ReloadMagazine\", \"Activate\", { systemChat \"reloading!\"; }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeUserActionEventHandler","removeAllUserActionEventHandlers","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addVehicle","operator":null,"title":"addVehicle","type":"command","url":"https://community.bistudio.com/wiki/addVehicle","revid":330327,"updated":"2022-08-31T15:18:42Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Adds a specified vehicle for use by a specified AI led group.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"groupName addVehicle vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"groupName: Group"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Group"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_grp addVehicle _vehicle;\n```","code":["_grp addVehicle _vehicle;"]},{"text":"Using on crewed vehicle:\n\n```sqf\ngroup tank addVehicle tank;\n```","code":["group tank addVehicle tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaveVehicle","unassignVehicle","createVehicleCrew","assignedVehicles","assignedGroup","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addVest","operator":null,"title":"addVest","type":"command","url":"https://community.bistudio.com/wiki/addVest","revid":318741,"updated":"2022-05-13T09:21:24Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create a new vest and try to link it into vest slot.","syntaxes":[{"syntax":"unit addVest type","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nplayer addVest \"V_TacVest_blk_POLICE\";\n```","code":["player addVest \"V_TacVest_blk_POLICE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeVest","vest"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addWaypoint","operator":null,"title":"addWaypoint","type":"command","url":"https://community.bistudio.com/wiki/addWaypoint","revid":377574,"updated":"2026-01-02T06:56:28Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds (or inserts when index is given) a new waypoint to a group.\n\nThe waypoint is placed randomly within a circle with the given center and radius.\n\n> [!NOTE]\n> For older titles and prior to Arma 3 v1.90, use setWaypointPosition if you need exact waypoint placement.","syntaxes":[{"syntax":"groupName addWaypoint [center, radius, index, name]","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"groupName: Group"},{"name":"center","type":null,"optional":false,"default":null,"description":"PositionAGL (PositionASL if *radius* is negative!) or Object","types":["PositionAGL","PositionASL","Object"],"since":null,"text":"center: PositionAGL (PositionASL if *radius* is negative!) or Object"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"random waypoint placement within *radius* from *center*; Arma 3 v1.90 -1 can be used for exact waypoint placement","types":["Number"],"since":null,"text":"radius: Number - random waypoint placement within *radius* from *center*; Arma 3 v1.90 -1 can be used for exact waypoint placement"},{"name":"index","type":"Number","optional":true,"default":"-1","description":"can be used to insert a waypoint in between existing waypoints; if it is invalid, the waypoint will be added at the end","types":["Number"],"since":null,"text":"index: Number - (Optional, default -1) can be used to insert a waypoint in between existing waypoints; if it is invalid, the waypoint will be added at the end"},{"name":"name","type":"String","optional":true,"default":"\"\"","description":"waypointName","types":["String"],"since":null,"text":"name: String - (Optional, default \"\") waypointName"}],"returns":{"type":"Waypoint","types":["Waypoint"],"description":null,"text":"Waypoint"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Group"]},"right":{"text":"[center, radius, index, name]","types":["Array"]}}],"examples":[{"text":"```sqf\n_wp = _grp addWaypoint [position player, 0];\n```","code":["_wp = _grp addWaypoint [position player, 0];"]},{"text":"```sqf\n_wp = _grp addWaypoint [position player, 0];            // imprecise, placed like [[setVehiclePosition]]'s \"NONE\" placement\n_wp setWaypointPosition [getPosASL player, -1];            // from Operation Flashpoint: Elite to Arma 3 v1.88\n\nprivate _wp = _grp addWaypoint [getPosASL player, -1];    // Arma 3 v1.90+: precise placement\n```","code":["_wp = _grp addWaypoint [position player, 0];\t\t\t// imprecise, placed like [[setVehiclePosition]]'s \"NONE\" placement\n_wp setWaypointPosition [getPosASL player, -1];\t\t\t// from Operation Flashpoint: Elite to Arma 3 v1.88\n\nprivate _wp = _grp addWaypoint [getPosASL player, -1];\t// Arma 3 v1.90+: precise placement"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","createGuardedPoint","deleteWaypoint","copyWaypoints","move","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointHousePosition","setWaypointPosition","currentWaypoint","waypointName","waypointSpeed","setWPPos"],"notes":[{"user":"Tijmenjoppe","date":"2009-11-26T18:07:00Z","text":"In game versions prior to Arma 3 v1.22:\nIf you add a waypoint to your group and then want them to start moving to that waypoint, make sure to call setWaypointType \"MOVE\" on your waypoint."},{"user":"Giova","date":"2014-06-21T22:38:00Z","text":"if you want to create a waypoint of type \"MOVE\" and set it as actual waypoint, you can use the move command that does everything for you with only one line of code !\n\nBe aware that move command intercepts multiple waypoints and it will not line up in waypoints queue.\nIn other word it is a quick solution if you want your group to get only one waypoint, but for several waypoints you'll have to use addwaypoint and all setwaypointXXXXXX commands around.\nsee move command."},{"user":"OdinViking","date":"2014-08-05T01:49:00Z","text":"The waypoint may not be created exactly at the center position even if radius is zero. The position will be moved away if there are e.g. rocks at the center position or if it is placed at the edge of water on a shore."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addWeapon","operator":null,"title":"addWeapon","type":"command","url":"https://community.bistudio.com/wiki/addWeapon","revid":373145,"updated":"2025-04-04T06:14:28Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Add a weapon to a unit. For a global version of this command see addWeaponGlobal.\n\nInfantry units can only carry a specific number of weapons, once the weapon slots are filled, any further addWeapon commands are ignored.\n\n> [!NOTE]\n> a **magazine** must be added first for the added weapon to be loaded.\n\n> [!WARNING]\n> In Arma 3 this command can also link items to the inventory slots, the functionality is identical to linkItem command, which it global and thus differ in how it should be used.","syntaxes":[{"syntax":"object addWeapon weapon","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle to add the weapon to","types":["Object"],"since":null,"text":"object: Object - unit or vehicle to add the weapon to"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"weapon: String - weapon class name. See the topic Category:Weapons for reference about possible values."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"weapon","types":["String"]}},{"syntax":"object addWeapon [weapon, autoselect]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle to add the weapon to","types":["Object"],"since":null,"text":"object: Object - unit or vehicle to add the weapon to"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"weapon: String - weapon class name. See the topic Category:Weapons for reference about possible values."},{"name":"autoselect","type":"String","optional":true,"default":"true","description":"false to abort weapon autoselection if no weapon was selected.","types":["String"],"since":null,"text":"autoselect: String - (Optional, default true) false to abort weapon autoselection if no weapon was selected."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weapon, autoselect]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer addMagazine \"30Rnd_556x45_Stanag\";\nplayer addWeapon \"BAF_L85A2_RIS_SUSAT\";\n```","code":["player addMagazine \"30Rnd_556x45_Stanag\";\nplayer addWeapon \"BAF_L85A2_RIS_SUSAT\";"]},{"text":"```sqf\nAn_2 addMagazine \"100Rnd_762x51_M240\";\nAn_2 addWeapon \"M240_veh\";\n```","code":["An_2 addMagazine \"100Rnd_762x51_M240\";\nAn_2 addWeapon \"M240_veh\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponGlobal","addWeaponTurret","removeWeapon","removeAllWeapons","addMagazine"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addWeaponCargo","operator":null,"title":"addWeaponCargo","type":"command","url":"https://community.bistudio.com/wiki/addWeaponCargo","revid":376383,"updated":"2025-10-09T02:14:03Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Add weapons to the cargo space of vehicles, which can be taken out by infantry units. Ignores available cargo space.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, arguments for this command must be local (Local Argument). For global variant see addWeaponCargoGlobal.","syntaxes":[{"syntax":"vehicleName addWeaponCargo [weaponName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":"vehicle to which add the weapons","types":["Object"],"since":null,"text":"vehicleName: Object - vehicle to which add the weapons"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":"weapon name. See Category:Weapons for reference about possible values","types":["String"],"since":null,"text":"weaponName: String - weapon name. See Category:Weapons for reference about possible values"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of weapons to add. Arma 3 v2.14 negative count will remove weapons.","types":["Number"],"since":null,"text":"count: Number - number of weapons to add. Arma 3 v2.14 negative count will remove weapons."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"[weaponName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\n_truck addWeaponCargo [\"M16\", 5];\n```","code":["_truck addWeaponCargo [\"M16\", 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponCargoGlobal","addMagazineCargo","addMagazineCargoGlobal","clearMagazineCargo","clearWeaponCargo","getWeaponCargo","addItemCargo","addItemCargoGlobal","addBackpackCargo","addBackpackCargoGlobal","addWeaponWithAttachmentsCargo"],"notes":[{"user":"Galzohar","date":"2010-07-10T11:02:00Z","text":"When players add/remove gear directly via the gear menu that gear is synchronized across the network. Since this command is local only, using it during a mission can cause all sorts of weird issues. To get proper synchronization use this command in the object's init line or in a script called from its init line with a **call compile preprocessFile** command (and *not* **execVM**)."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"addWeaponCargoGlobal","operator":null,"title":"addWeaponCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/addWeaponCargoGlobal","revid":376384,"updated":"2025-10-09T02:14:17Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Add weapons to the cargo space of vehicles, which can be taken out by infantry units.","syntaxes":[{"syntax":"vehicleName addWeaponCargoGlobal [weaponName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":"vehicle to which add the weapons","types":["Object"],"since":null,"text":"vehicleName: Object - vehicle to which add the weapons"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":"weapon name. See the topic Category:Weapons for reference about possible values","types":["String"],"since":null,"text":"weaponName: String - weapon name. See the topic Category:Weapons for reference about possible values"},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of weapons to add. Arma 3 v2.14 negative count will remove weapons.","types":["Number"],"since":null,"text":"count: Number - number of weapons to add. Arma 3 v2.14 negative count will remove weapons."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"[weaponName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\n_truck addWeaponCargoGlobal [\"M16\", 5];\n```","code":["_truck addWeaponCargoGlobal [\"M16\", 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineCargo","clearMagazineCargo","clearWeaponCargo","addMagazineCargoGlobal","addBackpackCargo","addBackpackCargoGlobal","addItemCargo","addItemCargoGlobal","addWeaponWithAttachmentsCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"addWeaponGlobal","operator":null,"title":"addWeaponGlobal","type":"command","url":"https://community.bistudio.com/wiki/addWeaponGlobal","revid":373148,"updated":"2025-04-04T06:15:52Z","groups":["Vehicle Inventory","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Add a weapon to a unit. Infantry units can only carry weapons in their respective slots (primary, secondary and handgun),\nthe addWeaponGlobal command will replace the weapon currently in a slot with the added weapon if it shares the same slot.\nThis command can link items to respective slots as well, in which case the functionality is identical to linkItem.\n\nTo make sure the added weapon is loaded and ready, add the magazine first.\n\n> [!NOTE]\n> This command was broken when used on dedicated server and fixed on Arma 3 v2.00.","syntaxes":[{"syntax":"object addWeaponGlobal weapon","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle to add the weapon to","types":["Object"],"since":null,"text":"object : Object - unit or vehicle to add the weapon to"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"weapon","types":["String"]}},{"syntax":"object addWeaponGlobal [weapon, autoselect]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle to add the weapon to","types":["Object"],"since":null,"text":"object: Object - unit or vehicle to add the weapon to"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"weapon: String - weapon class name. See the topic Category:Weapons for reference about possible values."},{"name":"autoselect","type":"String","optional":true,"default":"true","description":"false to abort weapon autoselection if no weapon was selected.","types":["String"],"since":null,"text":"autoselect: String - (Optional, default true) false to abort weapon autoselection if no weapon was selected."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weapon, autoselect]","types":["Array"]}}],"examples":[{"text":"```sqf\n{\n    _x addMagazineGlobal \"Laserbatteries\";\n    _x addWeaponGlobal \"Laserdesignator\";\n} forEach allUnits;\n```","code":["{\n\t_x addMagazineGlobal \"Laserbatteries\";\n\t_x addWeaponGlobal \"Laserdesignator\";\n} forEach allUnits;"]},{"text":"```sqf\n{\n    if (typeOf _x == \"O_Heli_Attack_02_black_F\") then\n    {\n        _x addMagazineGlobal \"38Rnd_80mm_rockets\";\n        _x addWeaponGlobal \"rockets_Skyfire\";\n    };\n} forEach vehicles;\n```","code":["{\n\tif (typeOf _x == \"O_Heli_Attack_02_black_F\") then\n\t{\n\t\t_x addMagazineGlobal \"38Rnd_80mm_rockets\";\n\t\t_x addWeaponGlobal \"rockets_Skyfire\";\n\t};\n} forEach vehicles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponGlobal","addWeapon","addMagazine","addMagazineGlobal"],"notes":[{"user":"Killzone_Kid","date":"2015-07-07T18:42:00Z","text":"If you do not remove weapon first, using this command from dedicated server will duplicate weapon."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addWeaponItem","operator":null,"title":"addWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/addWeaponItem","revid":376456,"updated":"2025-10-14T21:27:36Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds a weapon item to the specified weapon. The item can be weapon magazine, in which case the amount of ammo and target muzzle could also be specified. Since Arma 3 2.22 it is possible to add a magazine directly into a 'Throw' muzzle provided it is configured with `keepInInventory = 0;`. To remove such magazine see removeWeaponItem.","syntaxes":[{"syntax":"unit addWeaponItem [weaponName, itemName, instant]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":"name of the weapon to add magazine to","types":["String"],"since":null,"text":"weaponName: String - name of the weapon to add magazine to"},{"name":"itemName","type":"String","optional":false,"default":null,"description":"class name of the item to add (if magazine, muzzle will be autodetected)","types":["String"],"since":null,"text":"itemName: String - class name of the item to add (if magazine, muzzle will be autodetected)"},{"name":"instant","type":"Boolean","optional":true,"default":"false","description":"true to skip animation","types":["Boolean"],"since":"arma3 1.96","text":"instant: Boolean - (Optional, default false) true to skip animation"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[weaponName, itemName, instant]","types":["Array"]}},{"syntax":"unit addWeaponItem [weaponName, [itemName, ammoCount, muzzleName], instant]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":"name of the weapon to add magazine to","types":["String"],"since":null,"text":"weaponName: String - name of the weapon to add magazine to"},{"name":"itemName","type":"String","optional":false,"default":null,"description":"class name of the item to add (if magazine, muzzle will be autodetected unless specified)","types":["String"],"since":null,"text":"itemName: String - class name of the item to add (if magazine, muzzle will be autodetected unless specified)"},{"name":"ammoCount","type":"Number","optional":true,"default":null,"description":"optional amount of ammo in magazine","types":["Number"],"since":null,"text":"ammoCount: Number - (Optional) optional amount of ammo in magazine"},{"name":"muzzleName","type":"String","optional":true,"default":null,"description":"optional target muzzle to add magazine to","types":["String"],"since":null,"text":"muzzleName: String - (Optional) optional target muzzle to add magazine to"},{"name":"instant","type":"Boolean","optional":true,"default":"false","description":"true to skip animation","types":["Boolean"],"since":"arma3 1.96","text":"instant: Boolean - (Optional, default false) true to skip animation"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[weaponName, [itemName, ammoCount, muzzleName], instant]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer addWeaponItem [\"arifle_MX_GL_ACO_F\", \"1Rnd_HE_Grenade_shell\"];\n```","code":["player addWeaponItem [\"arifle_MX_GL_ACO_F\", \"1Rnd_HE_Grenade_shell\"];"]},{"text":"```sqf\nplayer addWeaponItem [\"arifle_MX_GL_ACO_F\", [\"1Rnd_HE_Grenade_shell\", 1, \"GL_3GL_F\"]];\n```","code":["player addWeaponItem [\"arifle_MX_GL_ACO_F\", [\"1Rnd_HE_Grenade_shell\", 1, \"GL_3GL_F\"]];"]},{"text":"```sqf\nplayer addWeaponItem [\"LaserDesignator\", \"LaserBatteries\"];\n```","code":["player addWeaponItem [\"LaserDesignator\", \"LaserBatteries\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponItem","addPrimaryWeaponItem","addSecondaryWeaponItem","addHandgunItem","addBinocularItem","weaponsItems","handgunItems","primaryWeaponItems","secondaryWeaponItems","binocularItems","removePrimaryWeaponItem","removeSecondaryWeaponItem","removeHandgunItem","removeBinocularItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.38","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addWeaponPool","operator":null,"title":"addWeaponPool","type":"command","url":"https://community.bistudio.com/wiki/addWeaponPool","revid":364177,"updated":"2024-05-05T10:46:45Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add weapons to the weapon pool, of which the player may choose in the following mission. Available in campaigns only.","syntaxes":[{"syntax":"addWeaponPool [weaponName, count]","since":null,"effect":null,"exec":null,"params":[{"name":"weaponName","type":"String","optional":false,"default":null,"description":"weapon name. See the topic Category:Weapons for reference about possible values.","types":["String"],"since":null,"text":"weaponName: String - weapon name. See the topic Category:Weapons for reference about possible values."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of weapons to add","types":["Number"],"since":null,"text":"count: Number - number of weapons to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[weaponName, count]","types":["Array"]}}],"examples":[{"text":"```sqf\naddWeaponPool [\"M16\",5];\n```","code":["addWeaponPool [\"M16\",5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazinePool","clearWeaponPool","queryWeaponPool","addMagazineAmmoCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"addWeaponTurret","operator":null,"title":"addWeaponTurret","type":"command","url":"https://community.bistudio.com/wiki/addWeaponTurret","revid":377484,"updated":"2026-01-02T06:49:02Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Adds a weapon to the turret. Use turret path [-1] for driver's turret.","syntaxes":[{"syntax":"vehicle addWeaponTurret [weaponName, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[weaponName, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\n_tank addWeaponTurret [\"LMG_M200\", [0,0]];\n```","code":["_tank addWeaponTurret [\"LMG_M200\", [0,0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponTurret","turretLocal","addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","currentMagazineDetailTurret","currentMagazineTurret","currentWeaponTurret","selectWeaponTurret"],"notes":[{"user":"7erra","date":"2021-06-03T12:05:00Z","text":"You can find out the turret path by entering the turret and checking with\n\n```sqf\nassignedVehicleRole player;\n```"}],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"addWeaponWithAttachmentsCargo","operator":null,"title":"addWeaponWithAttachmentsCargo","type":"command","url":"https://community.bistudio.com/wiki/addWeaponWithAttachmentsCargo","revid":377612,"updated":"2026-01-02T08:51:35Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Adds a weapon into the cargo space of a vehicle / box with given attachments / magazines. Ignores available cargo space. If the weapon class has any pre-attached items (LinkedItems), they are removed and new items, supplied via command arguments, are added.","syntaxes":[{"syntax":"container addWeaponWithAttachmentsCargo [weaponConfiguration, weaponsCount]","since":null,"effect":null,"exec":null,"params":[{"name":"container","type":"Object","optional":false,"default":null,"description":"container to add the weapon to. Might be a backpack, ammobox or vehicle.","types":["Object"],"since":null,"text":"container: Object - container to add the weapon to. Might be a backpack, ammobox or vehicle."},{"name":"weaponConfiguration","type":null,"optional":false,"default":null,"description":"Array with [weapon, muzzle, flashlight, optics, primaryMuzzle, secondaryMuzzle, bipod]\n- weapon: String - Weapon class name from CfgWeapons\n- muzzle: String - Muzzle attachment class name. Use \"\" if not needed.\n- flashlight: String - Side rail attachment class name. Use \"\" if not needed.\n- optics: String - Top rail attachment class name. Use \"\" if not needed.\n- primaryMuzzle: Array with [primaryMuzzleMagazine, primaryAmmoCount] - Use [] if not needed\n  - primaryMuzzleMagazine: String - Magazine class name\n  - primaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- secondaryMuzzle: Array with [secondaryMuzzleMagazine, secondaryAmmoCount] - Use [] if not needed\n  - secondaryMuzzleMagazine: String - Magazine class name\n  - secondaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- bipod: String - Underbarrel rail attachment class name. Use \"\" if not needed.\nThis array has the same format as the array returned by the weaponsItems command.","types":["Array"],"since":null,"text":"weaponConfiguration: Array with [weapon, muzzle, flashlight, optics, primaryMuzzle, secondaryMuzzle, bipod]\n- weapon: String - Weapon class name from CfgWeapons\n- muzzle: String - Muzzle attachment class name. Use \"\" if not needed.\n- flashlight: String - Side rail attachment class name. Use \"\" if not needed.\n- optics: String - Top rail attachment class name. Use \"\" if not needed.\n- primaryMuzzle: Array with [primaryMuzzleMagazine, primaryAmmoCount] - Use [] if not needed\n  - primaryMuzzleMagazine: String - Magazine class name\n  - primaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- secondaryMuzzle: Array with [secondaryMuzzleMagazine, secondaryAmmoCount] - Use [] if not needed\n  - secondaryMuzzleMagazine: String - Magazine class name\n  - secondaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- bipod: String - Underbarrel rail attachment class name. Use \"\" if not needed.\nThis array has the same format as the array returned by the weaponsItems command."},{"name":"weaponsCount","type":"Number","optional":false,"default":null,"description":"number of weapons to add","types":["Number"],"since":null,"text":"weaponsCount: Number - number of weapons to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"container","types":["Object"]},"right":{"text":"[weaponConfiguration, weaponsCount]","types":["Array"]}}],"examples":[{"text":"```sqf\ncursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"\", \"optic_aco\", [\"30Rnd_65x39_caseless_mag\", 15], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 2];\n```","code":["cursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"\", \"optic_aco\", [\"30Rnd_65x39_caseless_mag\", 15], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 2];"]},{"text":"Add five MX GL rifles, each with flashlight side attachment, a full 30 rounds magazine loaded into the gun and a full 3Rnd HE grenade magazine loaded into the grenade launcher:\n\n```sqf\ncursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_GL_F\", \"\", \"acc_flashlight\", \"\", [\"30Rnd_65x39_caseless_mag\", 30], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 5];\n```","code":["cursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_GL_F\", \"\", \"acc_flashlight\", \"\", [\"30Rnd_65x39_caseless_mag\", 30], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 5];"]},{"text":"Add one MX rifle without any attachments or magazines event though the class has linked items:\n\n```sqf\ncursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_Holo_pointer_F\", \"\", \"\", \"\", [], [], \"\"], 1];\n```","code":["cursorObject addWeaponWithAttachmentsCargo [[\"arifle_MX_Holo_pointer_F\", \"\", \"\", \"\", [], [], \"\"], 1];"]},{"text":"Add all weapons on player with attachments:\n\n```sqf\n{ cursorObject addWeaponWithAttachmentsCargo [_x, 1] } forEach weaponsItems player;\n```","code":["{ cursorObject addWeaponWithAttachmentsCargo [_x, 1] } forEach weaponsItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponWithAttachmentsCargoGlobal","weaponsItems","addWeaponCargo","addWeaponCargoGlobal","clearWeaponCargo","getWeaponCargo"],"notes":[{"user":"Andrew_S90","date":"2020-10-28T21:03:00Z","text":"This command also allows you to add a weapon with attachments directly to the players backpack.\n\n```sqf\n(backpackContainer player) addWeaponWithAttachmentsCargo [[\"arifle_MX_F\",\"muzzle_snds_H\",\"acc_pointer_IR\",\"optic_Hamr\",[\"30Rnd_65x39_caseless_mag\",30],[],\"bipod_03_F_blk\"], 1];\n```"},{"user":"DreadedEntity","date":"2022-04-02T02:52:00Z","text":"This command will let you add millions of weapons across multiple vehicles, but be warned, weird things start happening in-game:\n\n```sqf\n(vehicle player) addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_F\",\"\",\"\",\"\",[],[],\"\"],1000000];\n```\n\nI don't recommend running the above too many times in the console"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.94","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"addWeaponWithAttachmentsCargoGlobal","operator":null,"title":"addWeaponWithAttachmentsCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/addWeaponWithAttachmentsCargoGlobal","revid":377640,"updated":"2026-01-02T08:52:38Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Adds a weapon into the cargo space of a vehicle / box with given attachments / magazines. Ignores available cargo space. If the weapon class has any pre-attached items (LinkedItems), they are removed and new items, supplied via command arguments, are added.","syntaxes":[{"syntax":"container addWeaponWithAttachmentsCargoGlobal [weaponConfiguration, weaponsCount]","since":null,"effect":null,"exec":null,"params":[{"name":"container","type":"Object","optional":false,"default":null,"description":"container to add the weapon to. Might be a backpack, ammobox or vehicle.","types":["Object"],"since":null,"text":"container: Object - container to add the weapon to. Might be a backpack, ammobox or vehicle."},{"name":"weaponConfiguration","type":null,"optional":false,"default":null,"description":"Array with [weapon, muzzle, flashlight, optics, primaryMuzzle, secondaryMuzzle, bipod]\n- weapon: String - Weapon class name from CfgWeapons\n- muzzle: String - Muzzle attachment class name. Use \"\" if not needed.\n- flashlight: String - Side rail attachment class name. Use \"\" if not needed.\n- optics: String - Top rail attachment class name. Use \"\" if not needed.\n- primaryMuzzle: Array with [primaryMuzzleMagazine, primaryAmmoCount] - Use [] if not needed\n  - primaryMuzzleMagazine: String - Magazine class name\n  - primaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- secondaryMuzzle: Array with [secondaryMuzzleMagazine, secondaryAmmoCount] - Use [] if not needed\n  - secondaryMuzzleMagazine: String - Magazine class name\n  - secondaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- bipod: String - Underbarrel rail attachment class name. Use \"\" if not needed.\nThis array has the same format as the array returned by the weaponsItems command.","types":["Array"],"since":null,"text":"weaponConfiguration: Array with [weapon, muzzle, flashlight, optics, primaryMuzzle, secondaryMuzzle, bipod]\n- weapon: String - Weapon class name from CfgWeapons\n- muzzle: String - Muzzle attachment class name. Use \"\" if not needed.\n- flashlight: String - Side rail attachment class name. Use \"\" if not needed.\n- optics: String - Top rail attachment class name. Use \"\" if not needed.\n- primaryMuzzle: Array with [primaryMuzzleMagazine, primaryAmmoCount] - Use [] if not needed\n  - primaryMuzzleMagazine: String - Magazine class name\n  - primaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- secondaryMuzzle: Array with [secondaryMuzzleMagazine, secondaryAmmoCount] - Use [] if not needed\n  - secondaryMuzzleMagazine: String - Magazine class name\n  - secondaryAmmoCount: Number - Ammo count in magazine (will be clipped to values between 0 and the maximum capacity of the magazine class)\n- bipod: String - Underbarrel rail attachment class name. Use \"\" if not needed.\nThis array has the same format as the array returned by the weaponsItems command."},{"name":"weaponsCount","type":"Number","optional":false,"default":null,"description":"number of weapons to add","types":["Number"],"since":null,"text":"weaponsCount: Number - number of weapons to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"container","types":["Object"]},"right":{"text":"[weaponConfiguration, weaponsCount]","types":["Array"]}}],"examples":[{"text":"```sqf\ncursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"\", \"optic_aco\", [\"30Rnd_65x39_caseless_mag\", 15], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 2];\n```","code":["cursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"\", \"optic_aco\", [\"30Rnd_65x39_caseless_mag\", 15], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 2];"]},{"text":"Add five MX GL rifles, each with flashlight side attachment, a full 30 rounds magazine loaded into the gun and a full 3Rnd HE grenade magazine loaded into the grenade launcher:\n\n```sqf\ncursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_GL_F\", \"\", \"acc_flashlight\", \"\", [\"30Rnd_65x39_caseless_mag\", 30], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 5];\n```","code":["cursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_GL_F\", \"\", \"acc_flashlight\", \"\", [\"30Rnd_65x39_caseless_mag\", 30], [\"3Rnd_HE_Grenade_shell\", 2], \"\"], 5];"]},{"text":"Add one MX rifle without any attachments or magazines event though the class has linked items:\n\n```sqf\ncursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_Holo_pointer_F\", \"\", \"\", \"\", [], [], \"\"], 1];\n```","code":["cursorObject addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_Holo_pointer_F\", \"\", \"\", \"\", [], [], \"\"], 1];"]},{"text":"Add all weapons on player with attachments:\n\n```sqf\n{ cursorObject addWeaponWithAttachmentsCargoGlobal [_x, 1] } forEach weaponsItems player;\n```","code":["{ cursorObject addWeaponWithAttachmentsCargoGlobal [_x, 1] } forEach weaponsItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponWithAttachmentsCargo","weaponsItems","addWeaponCargo","addWeaponCargoGlobal","clearWeaponCargo","getWeaponCargo"],"notes":[{"user":"Andrew_S90","date":"2020-10-28T20:57:00Z","text":"This command also allows you to add a weapon with attachments directly to the players backpack.\n\n```sqf\n(backpackContainer player) addWeaponWithAttachmentsCargoGlobal [[\"arifle_MX_F\",\"muzzle_snds_H\",\"acc_pointer_IR\",\"optic_Hamr\",[\"30Rnd_65x39_caseless_mag\",30],[],\"bipod_03_F_blk\"], 1];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.94","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"admin","operator":null,"title":"admin","type":"command","url":"https://community.bistudio.com/wiki/admin","revid":364587,"updated":"2024-05-17T12:40:33Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"This is dedicated server command, which queries the admin state of any client on the network by their client (owner) id.\n\n> [!NOTE]\n> To self-check the admin state of a local client, use BIS_fnc_admin.","syntaxes":[{"syntax":"admin ownerID","since":null,"effect":null,"exec":null,"params":[{"name":"ownerID","type":"Number","optional":false,"default":null,"description":"clientOwner id","types":["Number"],"since":null,"text":"ownerID: Number - clientOwner id"}],"returns":{"type":"Number","types":["Number"],"description":"admin state of given client: - 0 - client is not an admin - 1 - client is admin that is voted in - 2 - client is admin that is logged in","text":"Number - admin state of given client:\n- 0 - client is not an admin\n- 1 - client is admin that is voted in\n- 2 - client is admin that is logged in"},"form":"unary","operator":null,"left":null,"right":{"text":"ownerID","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _isLoggedInAdmin = admin 3 == 2;\n```","code":["private _isLoggedInAdmin = admin 3 == 2;"]},{"text":"```sqf\nprivate _adminState = admin owner unit1;\n```","code":["private _adminState = admin owner unit1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["serverCommand","serverCommandAvailable","owner","clientOwner","remoteExecutedOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"agent","operator":null,"title":"agent","type":"command","url":"https://community.bistudio.com/wiki/agent","revid":318629,"updated":"2022-05-13T09:21:13Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a person for a given agent.","syntaxes":[{"syntax":"agent teamMember","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"teamMember","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_obj = agent teamMember _unit;\n```","code":["_obj = agent teamMember _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["agents","createAgent","forEachMemberAgent","isAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"agents","operator":null,"title":"agents","type":"command","url":"https://community.bistudio.com/wiki/agents","revid":378915,"updated":"2026-08-12T19:46:48Z","groups":["Teams","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of agents in the current mission.","syntaxes":[{"syntax":"agents","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Team Members","types":["Array","Team Member"],"description":null,"text":"Array of Team Members"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ agent _x moveTo position player } forEach agents;\n```","code":["{ agent _x moveTo position player } forEach agents;"]},{"text":"```sqf\nagents apply {typeOf agent _x}; // [\"Snake_random_F\",\"Snake_random_F\",\"Snake_random_F\",\"Rabbit_F\"]\n```","code":["agents apply {typeOf agent _x}; // [\"Snake_random_F\",\"Snake_random_F\",\"Snake_random_F\",\"Rabbit_F\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["teams","agent","createAgent","isAgent","forEachMemberAgent","entities","allCurators","allGroups","allDead","playableUnits","switchableUnits","vehicles","allUnitsUAV","allDeadMen"],"notes":[{"user":"Rocket","date":"2012-04-04T10:48:00Z","text":"Note that agents returns a reference to the agent itself, not the object. For example: \n\n```sqf\n{ alive _x } count agents;\n```\n\n would return an error\n But you can assign the agent a reference using setVariable, and then reference it, for example: \n\n```sqf\n{ alive (_x getVariable [\"agentObject\", objNull]) } count agents;\n```\n\n would return the number of agents still alive - BUT you would need to define \"agentObject\" after you create the agent, for example:\n\n```sqf\n_agent = createAgent [_type, _position, [], _radius, \"NONE\"];_agent setVariable[\"agentObject\",_agent,true];\n```"},{"user":"Killzone_Kid","date":"2013-08-01T21:55:00Z","text":"Alternatively, to get object from agent reference use agent command."},{"user":"PierreMGI","date":"2020-05-26T14:10:00Z","text":"In debug console, pointing at an agent:\n\n```sqf\ncursorObject;                                            // seems to refer to an agent (ex.: Agent 0xcbce41c0), but it is an object\nteamMember cursorObject;                                // returns the same value Agent 0xcbce41c0, but now it is the agent\ncursorObject in agents;                                    // will return false (even if you can read the value Agent 0xcbce41c0 in the agents array)\nteamMember cursorObject in agents;                        // returns true. TeamMember allows to refer to the agent under the cursorObject\nagent teamMember cursorObject isEqualTo cursorObject;    // true, same object.\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"AGLToASL","operator":null,"title":"AGLToASL","type":"command","url":"https://community.bistudio.com/wiki/AGLToASL","revid":377450,"updated":"2026-01-02T06:47:08Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position from PositionAGL to PositionASL.","syntaxes":[{"syntax":"AGLToASL posAGL","since":null,"effect":null,"exec":null,"params":[{"name":"posAGL","type":"PositionAGL","optional":false,"default":null,"description":"position to convert","types":["PositionAGL"],"since":null,"text":"posAGL: PositionAGL - position to convert"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"posAGL","types":["PositionAGL"]}}],"examples":[{"text":"```sqf\n_playerPosASL = AGLToASL (player modelToWorld [0,0,0]);\n```","code":["_playerPosASL = AGLToASL (player modelToWorld [0,0,0]);"]},{"text":"```sqf\n_camPosASL = AGLToASL positionCameraToWorld [0,0,0];\n```","code":["_camPosASL = AGLToASL positionCameraToWorld [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ASLToAGL","ASLToATL","ATLToASL","getPos","getPosATL","getPosASL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"aimedAtTarget","operator":null,"title":"aimedAtTarget","type":"command","url":"https://community.bistudio.com/wiki/aimedAtTarget","revid":363498,"updated":"2024-04-01T11:17:25Z","groups":["Object Manipulation","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how good a vehicle's weapon is aimed at the target.","syntaxes":[{"syntax":"vehicle aimedAtTarget [target, weapon]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle only, not unit","types":["Object"],"since":null,"text":"vehicle: Object - vehicle only, not unit"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"},{"name":"weapon","type":"String","optional":true,"default":null,"description":"if not provided, checks all weapons; if provided, checks that weapon only","types":["String"],"since":null,"text":"weapon: String - (Optional) if not provided, checks all weapons; if provided, checks that weapon only"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":"0 if no weapons or if weapon was provided and not found","text":"Number in range 0..1 - 0 if no weapons or if *weapon* was provided and not found"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[target, weapon]","types":["Array"]}}],"examples":[{"text":"```sqf\n_aimingQuality = heli aimedAtTarget [target];\n```","code":["_aimingQuality = heli aimedAtTarget [target];"]},{"text":"```sqf\n_aimingQuality = heli aimedAtTarget [target, \"M197\"];\n```","code":["_aimingQuality = heli aimedAtTarget [target, \"M197\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fireAtTarget"],"notes":[{"user":"Killzone_Kid","date":"2013-11-19T15:02:00Z","text":"The command doesn't work with soldier weapons, only vehicle weapons (in Arma 3 at least). The return value is either 1 or 0, very rarely the value falls in between.\n1 doesn't mean you are going to hit the target, while 0 means you're definitely off."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"aimPos","operator":null,"title":"aimPos","type":"command","url":"https://community.bistudio.com/wiki/aimPos","revid":378158,"updated":"2026-02-26T16:15:24Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the position of the object other units can aim to.","syntaxes":[{"syntax":"aimPos unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_aimPos = aimPos player;\n```","code":["_aimPos = aimPos player;"]},{"text":"***aimPosVisual*** equivalent:\n\n```sqf\nprivate _aimPosVisual = AGLToASL unitAimPositionVisual player;\n```","code":["private _aimPosVisual = AGLToASL unitAimPositionVisual player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["eyePos","getPosASL","weaponDirection","unitAimPosition","unitAimPositionVisual"],"notes":[{"user":"Waffle SS.","date":"2015-07-07T21:19:00Z","text":"Generally returns the center position of the object (middle of the geometry, not the model's [0,0,0])."},{"user":"Sa-Matra","date":"2023-03-27T12:33:11Z","text":"This command uses \"zamerny\" memory point which is hardcoded name in the engine. If memory point is not present then geometry LOD bounding center is used (according to dedmen)"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"airDensityCurveRTD","operator":null,"title":"airDensityCurveRTD","type":"command","url":"https://community.bistudio.com/wiki/airDensityCurveRTD","revid":377671,"updated":"2026-01-02T09:02:30Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with air density data.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"airDensityCurveRTD","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with arrays Returns air density graph Each array consists of:","types":["Array"],"description":"0: Altitude (-60000 metres to 10^7 metres) - 1: Air density","text":"Array with arrays Returns air density graph\n\nEach array consists of:\n- 0: Altitude (-60000 metres to 10^7 metres)\n- 1: Air density"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _densityArray = airDensityCurveRTD;\n```","code":["private _densityArray = airDensityCurveRTD;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Advanced Helicopter Flight Model in Arma3"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"airDensityRTD","operator":null,"title":"airDensityRTD","type":"command","url":"https://community.bistudio.com/wiki/airDensityRTD","revid":318555,"updated":"2022-05-13T09:21:05Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns air density in given altitude. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"airDensityRTD altitude","since":null,"effect":null,"exec":null,"params":[{"name":"altitude","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"altitude: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"altitude","types":["Number"]}}],"examples":[{"text":"```sqf\n_density = airDensityRTD 0; // returns 1.22406\n```","code":["_density = airDensityRTD 0; // returns 1.22406"]},{"text":"```sqf\n_density = airDensityRTD 1000; // Returns 1.11096\n```","code":["_density = airDensityRTD 1000; // Returns 1.11096"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rotorsForcesRTD","rotorsRpmRTD","weightRTD","wingsForcesRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"airplaneThrottle","operator":null,"title":"airplaneThrottle","type":"command","url":"https://community.bistudio.com/wiki/airplaneThrottle","revid":310739,"updated":"2022-05-07T20:12:21Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns throttle position. Works only on player's vehicle.","syntaxes":[{"syntax":"airplaneThrottle airplane","since":null,"effect":null,"exec":null,"params":[{"name":"airplane","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"airplane: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"airplane","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _throttle = airplaneThrottle objectParent player;\n```","code":["private _throttle = airplaneThrottle objectParent player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAirplaneThrottle"],"notes":[{"user":"POLPOX","date":"2020-01-04T10:18:00Z","text":"The value that set by setAirplaneThrottle =/= the value that can be get by airplaneThrottle when the plane's config *throttleToThrustLogFactor* isn't 1.\n\nThere're two planes in Vanilla Arma 3 that the value isn't 1, which are V-44 Blackfish and Y-32 Xi'an.\n\n```sqf\nvehicle player setAirplaneThrottle 0.5;\nairplaneThrottle vehicle player;    // 0.793701 if the value is 3\nairplaneThrottle vehicle player^(getNumber (configFile >> \"CfgVehicles\" >> typeOf vehicle player >> \"throttleToThrustLogFactor\"));    // 0.5\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"airportSide","operator":null,"title":"airportSide","type":"command","url":"https://community.bistudio.com/wiki/airportSide","revid":353294,"updated":"2024-03-15T17:11:42Z","groups":["Sides","Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the side of an airport, set by setAirportSide. Default side is sideUnknown.\n\n> [!NOTE]\n> See Arma: Airport IDs for a list of airport ids.","syntaxes":[{"syntax":"airportSide id","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"}],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"unary","operator":null,"left":null,"right":{"text":"id","types":["Number"]}},{"syntax":"airportSide target","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _airportSide = airportSide 0;\n```","code":["private _airportSide = airportSide 0;"]}],"multiplayer":null,"problems":"When used on a non-existent airport id:\n- negative numbers will always return sideUnknown\n- positive numbers may return east, west, resistance, sideEmpty, sideUnknown, sideAmbientLife, or 'ERROR' (see Notes).","aliases":[],"see_also":["Arma: Airport IDs","setAirportSide","land","landAt","assignToAirport","allAirports"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Command Group: Sides","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"AISFinishHeal","operator":null,"title":"AISFinishHeal","type":"command","url":"https://community.bistudio.com/wiki/AISFinishHeal","revid":377976,"updated":"2026-01-19T18:45:43Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Alternative Injury Simulation (AIS) end state. Used to tell engine that script side healing is done when using \"HandleHeal\" event handler.","syntaxes":[{"syntax":"AISFinishHeal [unit, healer, healerCanHeal]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"wounded","types":["Object"],"since":null,"text":"unit: Object - wounded"},{"name":"healer","type":"Object","optional":false,"default":null,"description":"medic","types":["Object"],"since":null,"text":"healer: Object - medic"},{"name":"healerCanHeal","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"healerCanHeal: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, healer, healerCanHeal]","types":["Array"]}}],"examples":[{"text":"```sqf\nAISFinishHeal [_wounded, _medic, true];\n```","code":["AISFinishHeal [_wounded, _medic, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"alive","operator":null,"title":"alive","type":"command","url":"https://community.bistudio.com/wiki/alive","revid":337581,"updated":"2023-02-12T15:50:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if given vehicle/person/building is alive (i.e. not dead or destroyed).","syntaxes":[{"syntax":"alive object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if alive, false if dead/destroyed","text":"Boolean - true if alive, false if dead/destroyed"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"SQS:\n\n```sqs\n? not alive player : exit\n```","code":["? not alive player : exit"]},{"text":"SQF:\n\n```sqf\nif (!alive player) exitWith {};\n```","code":["if (!alive player) exitWith {};"]},{"text":"```sqf\nalive objNull; // returns false\n```","code":["alive objNull; // returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDamage","damage","waterDamaged"],"notes":[{"user":"Pierre MGI","date":"2015-10-19T23:48:00Z","text":"Alive or not could be the question! in multi-player, missions come with respawn module(s). When a player is dead shot, `alive player` will return false, then almost immediately true if the \"revive\" respawn template is enabled, then could turn to false again if time for assistance is elapsed or if the player activates the respawn menu before; and finally true after player respawns.\nJust be aware that in that case (respawn + revive enabled), the status of the player is toggling: true → false → true → false → true. Then, alive status while player is waiting for being rescued could lead to some script errors as player is supposed to be alive but is in limbo and the dead entity \"player\" gets passed to server."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"all3DENEntities","operator":null,"title":"all3DENEntities","type":"command","url":"https://community.bistudio.com/wiki/all3DENEntities","revid":377599,"updated":"2026-01-02T07:01:24Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all currently placed Eden Editor entities.\n\n> [!NOTE]\n> This information is only available in Eden Editor. If used during mission, it will return `[[],[],[],[],[],[],[],[-999]]`.","syntaxes":[{"syntax":"all3DENEntities","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Eden Entities","types":["Array of Eden Entities"],"description":null,"text":"Array of Eden Entities"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsystemChat str all3DENEntities;\n```","code":["systemChat str all3DENEntities;"]},{"text":"```sqf\nall3DENEntities params [\"_objects\", \"_groups\", \"_triggers\", \"_systems\", \"_waypoints\", \"_markers\", \"_layers\", \"_comments\"];\n```","code":["all3DENEntities params [\"_objects\", \"_groups\", \"_triggers\", \"_systems\", \"_waypoints\", \"_markers\", \"_layers\", \"_comments\"];"]},{"text":"```sqf\n// select all Eden entities\nset3DENSelected all3DENEntities;\n```","code":["// select all Eden entities\nset3DENSelected all3DENEntities;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENMouseOver","delete3DENEntities","get3DENEntityID","get3DENSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"allActiveTitleEffects","operator":null,"title":"allActiveTitleEffects","type":"command","url":"https://community.bistudio.com/wiki/allActiveTitleEffects","revid":377719,"updated":"2026-01-02T09:16:16Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.98"}],"since":{"game":"arma3","name":"Arma 3","version":"1.98"},"arma3_since":"1.98","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all layers that have currently active title effect. Numbers equal to or greater than 0 represent cut layers, where as -1 represents title layer (see Title Effect Type). Named layers are represented by their respective index.\n\n> [!NOTE]\n> Effects created with titleText, titleRsc and titleObj commands do not have a numbered layer, so they are represented as -1 layer in the result. Effects created with cutText, cutRsc and cutObj are created either on layer 0, if no layer is specified, or on the given layer, if the layer index is specified, so they are represented by the layer index.","syntaxes":[{"syntax":"allActiveTitleEffects","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"indexes of currently active effect layer","text":"Array of Numbers - indexes of currently active effect layer"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ncutText [\"Hello World!\" ,\"PLAIN\", 2];\nhint str allActiveTitleEffects; // [0]\n```","code":["cutText [\"Hello World!\" ,\"PLAIN\", 2];\nhint str allActiveTitleEffects; // [0]"]},{"text":"```sqf\n21 cutText [\"Hello World!\", \"PLAIN\", 2];\nhint str allActiveTitleEffects; // [21]\n```","code":["21 cutText [\"Hello World!\", \"PLAIN\", 2];\nhint str allActiveTitleEffects; // [21]"]},{"text":"```sqf\ncutText [\"Hello World!\", \"PLAIN\", 2];\ntitleText [\"Hello World!\", \"PLAIN\", 2];\nhint str allActiveTitleEffects; // [-1, 0]\n```","code":["cutText [\"Hello World!\", \"PLAIN\", 2];\ntitleText [\"Hello World!\", \"PLAIN\", 2];\nhint str allActiveTitleEffects; // [-1, 0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","cutText","cutRsc","cutObj","cutFadeOut","titleText","titleRsc","titleObj","titleFadeOut","activeTitleEffectParams","Title Effect Type"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.98","Scripting Commands"]},{"name":"allAddonsInfo","operator":null,"title":"allAddonsInfo","type":"command","url":"https://community.bistudio.com/wiki/allAddonsInfo","revid":377669,"updated":"2026-01-02T09:02:27Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of all loaded addons.","syntaxes":[{"syntax":"allAddonsInfo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Arrays with [prefix, version, isPatched, modIndex, hash]","types":["Array"],"description":"prefix: String - addon prefix - version: String - addon revision version - isPatched: Boolean - true if patching is enabled and this addon is being patched - Arma 3 v2.14 modIndex: Number - index of mod in getLoadedModsInfo array. -1 if not found. - Arma 3 v2.14 hash: String - hash of the addon PBO file. \"\" if hashing fails.","text":"Array of Arrays with [prefix, version, isPatched, modIndex, hash]\n- prefix: String - addon prefix\n- version: String - addon revision version\n- isPatched: Boolean - true if patching is enabled and this addon is being patched\n- Arma 3 v2.14 modIndex: Number - index of mod in getLoadedModsInfo array. -1 if not found.\n- Arma 3 v2.14 hash: String - hash of the addon PBO file. \"\" if hashing fails."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nallAddonsInfo\n/*\n    [\n        [\"bin\\\",\"150301\",false,-1,\"66b6d1a87da30e0386fec881504c14a0a6025cb1\"],\n        [\"core\\\",\"129618\",false,-1,\"49e1b8da67de848c8ea058fd8512c222ccb6d919\"],\n        [\"Languagecore_F\\\",\"150376\",false,-1,\"2ee7b09d60f916d7e56934632f55683a14a636b7\"],\n        [\"a3\\anims_f_aow\\\",\"149768\",false,0,\"59df21ad1fc6939c460a555b3af662f725564b37\"],\n        [\"a3\\dubbing_radio_f_enoch\\\",\"150070\",false,1,\"5ca436c61a634fcbd28ca9480a4c8249c5b0e4bd\"],\n        [\"a3\\armor_f_tank\\\",\"150292\",false,2,\"6d0ea8b45ff4cd316b3d6c5575def9dd048e198e\"],\n        [\"a3\\music_f_tacops\\\",\"124064\",false,3,\"435c2b0338fe6bec7685002dca7c47778abf44ee\"],\n        ...\n    ]\n*/\n```","code":["allAddonsInfo\n/*\n\t[\n\t\t[\"bin\\\",\"150301\",false,-1,\"66b6d1a87da30e0386fec881504c14a0a6025cb1\"],\n\t\t[\"core\\\",\"129618\",false,-1,\"49e1b8da67de848c8ea058fd8512c222ccb6d919\"],\n\t\t[\"Languagecore_F\\\",\"150376\",false,-1,\"2ee7b09d60f916d7e56934632f55683a14a636b7\"],\n\t\t[\"a3\\anims_f_aow\\\",\"149768\",false,0,\"59df21ad1fc6939c460a555b3af662f725564b37\"],\n\t\t[\"a3\\dubbing_radio_f_enoch\\\",\"150070\",false,1,\"5ca436c61a634fcbd28ca9480a4c8249c5b0e4bd\"],\n\t\t[\"a3\\armor_f_tank\\\",\"150292\",false,2,\"6d0ea8b45ff4cd316b3d6c5575def9dd048e198e\"],\n\t\t[\"a3\\music_f_tacops\\\",\"124064\",false,3,\"435c2b0338fe6bec7685002dca7c47778abf44ee\"],\n\t\t...\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addonFiles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"allAirports","operator":null,"title":"allAirports","type":"command","url":"https://community.bistudio.com/wiki/allAirports","revid":377737,"updated":"2026-01-03T00:52:41Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.76"}],"since":{"game":"arma3","name":"Arma 3","version":"1.76"},"arma3_since":"1.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all map airports, both static and dynamic.","syntaxes":[{"syntax":"allAirports","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [staticAirports, dynamicAirports]","types":["Array"],"description":"staticAirports: Array of Numbers - static airports IDs - dynamicAirports: Array of Objects - dynamic airports objects (such as \"DynamicAirport_01_F\" found on aircraft carrier)","text":"Array with [staticAirports, dynamicAirports]\n- staticAirports: Array of Numbers - static airports IDs\n- dynamicAirports: Array of Objects - dynamic airports objects (such as \"DynamicAirport_01_F\" found on aircraft carrier)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_airplane landAt selectRandom (allAirports select 0);\n```","code":["_airplane landAt selectRandom (allAirports select 0);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["airportSide","setAirportSide","land","landAt","assignToAirport","Arma: Airport IDs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Arma 3 version 1.76","Scripting Commands"]},{"name":"allCameras","operator":null,"title":"allCameras","type":"command","url":"https://community.bistudio.com/wiki/allCameras","revid":376999,"updated":"2026-01-01T08:07:12Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of all existing cameras.","syntaxes":[{"syntax":"allCameras","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Arrays with [camera, r2tInfos, isPrimary, effectName, viewMode, TIindex]","types":["Array"],"description":"camera: Object - the camera itself (see camCreate) - r2tInfos: Array of Arrays with [r2tName, r2tEffectName, ppEffectType, TIindex] - r2tName: String - the camera's RTT name (see cameraEffect) - r2tEffectName: String - see cameraEffect for possible values - ppEffectType: String - one of `Normal`, `NightVision`, `Thermal`, `Colors`, `Mirror`, `ChromAber` or `FilmGrain` - TIIndex: Number - see setCamUseTI for possible values - isPrimary: Boolean - whether or not this camera is the current main one - effectName: String - (Optional, only available if isPrimary is true) see cameraEffect for possible values - viewMode: Number - (Optional, only available if isPrimary is true) 0 = normal, 1 = NVG, 2 = TI, 3 = NVG + TI - TIIndex: Number - (Optional, only available if isPrimary is true) see setCamUseTI for possible values","text":"Array of Arrays with [camera, r2tInfos, isPrimary, effectName, viewMode, TIindex]\n- camera: Object - the camera itself (see camCreate)\n- r2tInfos: Array of Arrays with [r2tName, r2tEffectName, ppEffectType, TIindex]\n  - r2tName: String - the camera's RTT name (see cameraEffect)\n  - r2tEffectName: String - see cameraEffect for possible values\n  - ppEffectType: String - one of `Normal`, `NightVision`, `Thermal`, `Colors`, `Mirror`, `ChromAber` or `FilmGrain`\n  - TIIndex: Number - see setCamUseTI for possible values\n- isPrimary: Boolean - whether or not this camera is the current main one\n- effectName: String - (Optional, only available if *isPrimary* is true) see cameraEffect for possible values\n- viewMode: Number - (Optional, only available if *isPrimary* is true) 0 = normal, 1 = NVG, 2 = TI, 3 = NVG + TI\n- TIIndex: Number - (Optional, only available if *isPrimary* is true) see setCamUseTI for possible values"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{\n    params [\"_camera\", \"_r2tInfos\", \"_isPrimary\", \"_ppEffectName\", \"_viewMode\", \"_TIindex\"];\n    {\n        params[\"_r2tName\", \"_ppEffectName\", \"_ppEffectType\", \"_TIindex\"];\n    } forEach _r2tInfos;\n} forEach allCameras;\n```","code":["{\n\tparams [\"_camera\", \"_r2tInfos\", \"_isPrimary\", \"_ppEffectName\", \"_viewMode\", \"_TIindex\"];\n\t{\n\t\tparams[\"_r2tName\", \"_ppEffectName\", \"_ppEffectType\", \"_TIindex\"];\n\t} forEach _r2tInfos;\n} forEach allCameras;"]},{"text":"```sqf\nprivate _allCamerasInfo = allCameras;\n{\n    params [\"_camera\", \"\", \"_isPrimary\"];\n    if (!_isPrimary) then { camDestroy _camera };\n} forEach _allCamerasInfo;\n```","code":["private _allCamerasInfo = allCameras;\n{\n\tparams [\"_camera\", \"\", \"_isPrimary\"];\n\tif (!_isPrimary) then { camDestroy _camera };\n} forEach _allCamerasInfo;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","camDestroy"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"allControls","operator":null,"title":"allControls","type":"command","url":"https://community.bistudio.com/wiki/allControls","revid":352271,"updated":"2024-02-04T22:03:55Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all controls in the provided display or controls group, including \"sub\"-controls from other CT_CONTROLS_GROUPs.","syntaxes":[{"syntax":"allControls display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"Array of Controls","types":["Array","Control"],"description":null,"text":"Array of Controls"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}},{"syntax":"allControls controlsGroup","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"controlsGroup","type":"Control","optional":false,"default":null,"description":"CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"controlsGroup: Control - CT_CONTROLS_GROUP"}],"returns":{"type":"Array of Controls","types":["Array","Control"],"description":null,"text":"Array of Controls"},"form":"unary","operator":null,"left":null,"right":{"text":"controlsGroup","types":["Control"]}}],"examples":[{"text":"```sqf\n_allCtrls = allControls findDisplay 46;\n```","code":["_allCtrls = allControls findDisplay 46;"]},{"text":"```sqf\n_allSubCtrls = allControls _myControlsGroup;\n```","code":["_allSubCtrls = allControls _myControlsGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDisplays","controlsGroupCtrl","ctrlCreate","allVariables","allCurators","allGroups","allDead","allDeadMen"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"allCurators","operator":null,"title":"allCurators","type":"command","url":"https://community.bistudio.com/wiki/allCurators","revid":377003,"updated":"2026-01-01T08:15:18Z","groups":["Curator","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of all curator logic units, not the units assigned to the logic.","syntaxes":[{"syntax":"allCurators","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_allCuratorLogics = allCurators;\n```","code":["_allCuratorLogics = allCurators;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allGroups","allDead","playableUnits","switchableUnits","vehicles","allUnitsUAV","allSites"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Command Group: Object Detection","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"allCutLayers","operator":null,"title":"allCutLayers","type":"command","url":"https://community.bistudio.com/wiki/allCutLayers","revid":377004,"updated":"2026-01-01T08:15:37Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all named layers used by cutRsc, cutText, cutObj or cutFadeOut.\nThe layer normally would be added on the first use of any of the aforementioned commands, however if a layer needs to be reserved it could be done like so:\n\n```sqf\nprivate _layerNum = \"TAG_myLayerName\" cutFadeOut 0;\n```","syntaxes":[{"syntax":"allCutLayers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"The index of the layer name in the array corresponds to the layer number the cut effect will be displayed on. If no layers were defined, the return is `[\"\"]`, because layer 0 is reserved for usage in cut commands without layer param or when the provided layer name is empty `\"\"`.","text":"Array of Strings - The index of the layer name in the array corresponds to the layer number the cut effect will be displayed on. If no layers were defined, the return is `[\"\"]`, because layer 0 is reserved for usage in cut commands without layer param or when the provided layer name is empty `\"\"`."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _allLayers = allCutLayers;\n```","code":["private _allLayers = allCutLayers;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cutRsc","cutText","cutObj","cutFadeOut","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"allDead","operator":null,"title":"allDead","type":"command","url":"https://community.bistudio.com/wiki/allDead","revid":377005,"updated":"2026-01-01T08:15:58Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of all dead units including agents and destroyed vehicles. Dead units may be in vehicles.","syntaxes":[{"syntax":"allDead","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ deleteVehicle _x } forEach allDead;\n```","code":["{ deleteVehicle _x } forEach allDead;"]},{"text":"allAlive:\n\n```sqf\n_all = allUnits + vehicles;\n{\n    _all pushBack agent _x;\n} forEach (agents - [teamMemberNull]);\nallAlive = _all - allDead;\n```","code":["_all = allUnits + vehicles;\n{\n\t_all pushBack agent _x;\n} forEach (agents - [teamMemberNull]);\nallAlive = _all - allDead;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDeadMen","allUnits","allGroups","playableUnits","switchableUnits","units","vehicles","allCurators"],"notes":[{"user":"Ebay","date":"2017-04-06T15:40:00Z","text":"This also returns bodies hidden with hideBody until they are deleted. Tested in A2OA 1.63.131129"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2: Operation Arrowhead version 1.57","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allDeadMen","operator":null,"title":"allDeadMen","type":"command","url":"https://community.bistudio.com/wiki/allDeadMen","revid":378914,"updated":"2026-08-12T19:45:30Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of dead units including agents. Dead unit might be inside vehicle.","syntaxes":[{"syntax":"allDeadMen","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ deleteVehicle _x } forEach allDeadMen;\n```","code":["{ deleteVehicle _x } forEach allDeadMen;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDead","allUnits","allGroups","playableUnits","switchableUnits","units","vehicles","allCurators","getCorpse"],"notes":[{"user":"Pierre MGI","date":"2015-10-15T04:08:00Z","text":"As dead men are civilian side, don't try to count them with `{ side _x isEqualTo east } count allDeadMen;` result will always be 0.\n\nUse the configfile \"side\" instead:\n\n```sqf\n0 spawn\n{\n    while { true } do\n    {\n        sleep 0.1;\n        _westScore =\n        {\n            getNumber (configFile >> \"CfgVehicles\" >> typeOf _x >> \"side\") == 0\n        } count allDeadMen;\n        hintSilent format [\"East killed: %1\", _westScore];\n    };\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"allDiaryRecords","operator":null,"title":"allDiaryRecords","type":"command","url":"https://community.bistudio.com/wiki/allDiaryRecords","revid":377644,"updated":"2026-01-02T09:01:43Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns array with all Diary Records for the given subject available to the given person. See Diary for the explanation on the available subjects and their structure.","syntaxes":[{"syntax":"person allDiaryRecords subject","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"person: Object - unit"},{"name":"subject","type":"String","optional":false,"default":null,"description":"subject","types":["String"],"since":null,"text":"subject: String - subject"}],"returns":{"type":"Array with [id, title, text, icon, task, taskState, showTitle, date, record]","types":["Array"],"description":"id: Number - record id - title: String - record title - text: String - record text - icon: String - record icon - task: Task - record task - taskState: String - record task state - showTitle: Boolean - true if tile is shown - date: Date - record: Diary Record - record reference","text":"Array with [id, title, text, icon, task, taskState, showTitle, date, record]\n- id: Number - record id\n- title: String - record title\n- text: String - record text\n- icon: String - record icon\n- task: Task - record task\n- taskState: String - record task state\n- showTitle: Boolean - true if tile is shown\n- date: Date\n- record: Diary Record - record reference"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"subject","types":["String"]}}],"examples":[{"text":"```sqf\nplayer allDiaryRecords \"Diary\";\n```","code":["player allDiaryRecords \"Diary\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDiarySubjects","createDiaryRecord","setDiaryRecordText","Diary"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"allDiarySubjects","operator":null,"title":"allDiarySubjects","type":"command","url":"https://community.bistudio.com/wiki/allDiarySubjects","revid":377670,"updated":"2026-01-02T09:02:28Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns array with all Diary subjects available to the given person. See Diary for the explanation on the available subjects and their structure.","syntaxes":[{"syntax":"allDiarySubjects person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"person: Object - unit"}],"returns":{"type":"Array with [name, displayName, picture, countRecords, isReadOnly, isSelected]","types":["Array"],"description":"name: String - internal subject reference - displayName: String - visible name - picture: String - subject icon - countRecords: Number - number of records in this subject - isReadOnly: Boolean - whether or not the records could be added - isSelected: Boolean - true if subject is currently selected","text":"Array with [name, displayName, picture, countRecords, isReadOnly, isSelected]\n- name: String - internal subject reference\n- displayName: String - visible name\n- picture: String - subject icon\n- countRecords: Number - number of records in this subject\n- isReadOnly: Boolean - whether or not the records could be added\n- isSelected: Boolean - true if subject is currently selected"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nallDiarySubjects player;\n```","code":["allDiarySubjects player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDiarySubject","removeDiarySubject","diarySubjectExists","selectDiarySubject","setDiarySubjectPicture","allDiaryRecords","Diary"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"allDisplays","operator":null,"title":"allDisplays","type":"command","url":"https://community.bistudio.com/wiki/allDisplays","revid":377009,"updated":"2026-01-01T08:17:31Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all opened GUI displays.\n\n> [!NOTE]\n> Other displays could be accessed via uiNamespace variable which is updated every time a display is opened or closed.\n> For example, to access IGUI displays:\n>\n> ```sqf\n> private _iguiDisplays = uiNamespace getVariable [\"IGUI_displays\", []];\n> ```\n>\n> Other display variables:\n> - `\"3DENDisplaysTemp_displays\"`\n> - `\"3DENDisplays_displays\"`\n> - `\"BootcampDisplays_displays\"`\n> - `\"BootcampTitles_displays\"`\n> - `\"CuratorDisplays_displays\"`\n> - `\"CuratorTitles_displays\"`\n> - `\"GUI_displays\"`\n> - `\"IGUI_displays\"`\n> - `\"KartDisplays_displays\"`\n> - `\"Loading_displays\"`","syntaxes":[{"syntax":"allDisplays","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Displays","types":["Array","Display"],"description":null,"text":"Array of Displays"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _allDisps = allDisplays;\n```","code":["private _allDisps = allDisplays;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","findDisplay","controlsGroupCtrl","ctrlCreate","allVariables","allCurators","allGroups","allDead","allDeadMen"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"allEnv3DSoundSources","operator":null,"title":"allEnv3DSoundSources","type":"command","url":"https://community.bistudio.com/wiki/allEnv3DSoundSources","revid":309140,"updated":"2022-05-03T11:50:33Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all environmental 3D sound sources (Objects) like trees and houses in camera vicinity.","syntaxes":[{"syntax":"allEnv3DSoundSources","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _sources = allEnv3DSoundSources;\n```","code":["private _sources = allEnv3DSoundSources;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllEnv3DSoundControllers","getAllEnvSoundControllers","getEnv3DSoundController","getEnvSoundController","selectBestPlaces","getSoundController","getSoundControllerResult","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount","Arma 3: Sound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"allExtensions","operator":null,"title":"allExtensions","type":"command","url":"https://community.bistudio.com/wiki/allExtensions","revid":378520,"updated":"2026-05-04T01:49:51Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns information about all loaded Extensions","syntaxes":[{"syntax":"allExtensions","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of HashMaps","types":["Array","HashMap"],"description":"one for each extension, containing the following keys - name: String - hash: String - sha1 - hasRVExtensionVersion: Boolean - hasRVExtensionRequestUI: Boolean - hasRVExtensionArgs: Boolean - hasRVExtensionContext: Boolean - hasRVExtensionRegisterCallback: Boolean - hasRVExtension: Boolean - hasRVExtensionFeatureFlags: Array of Strings - signatures: Array of Strings - productVersion: String - dllVersion: Boolean - fileVersion: Boolean - dllVersion: Boolean - mod: String","text":"Array of HashMaps - one for each extension, containing the following keys\n- name: String\n- hash: String - sha1\n- hasRVExtensionVersion: Boolean\n- hasRVExtensionRequestUI: Boolean\n- hasRVExtensionArgs: Boolean\n- hasRVExtensionContext: Boolean\n- hasRVExtensionRegisterCallback: Boolean\n- hasRVExtension: Boolean\n- hasRVExtensionFeatureFlags: Array of Strings\n- signatures: Array of Strings\n- productVersion: String\n- dllVersion: Boolean\n- fileVersion: Boolean\n- dllVersion: Boolean\n- mod: String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// Get hash for extension emm_api\nprivate _extensionHash = \"\"; \n{ \n    if ((_x getOrDefault [\"name\", \"\"]) == \"emm_api\") exitWith { \n        _extensionHash = _x getOrDefault [\"hash\", \"\"]; \n    }; \n} forEach allExtensions;\n_extensionHash // \"4CD820DBDBCAEBE6FF654762DA41AF6C97D013B4\"\n```","code":["// Get hash for extension emm_api\nprivate _extensionHash = \"\"; \n{ \n    if ((_x getOrDefault [\"name\", \"\"]) == \"emm_api\") exitWith { \n        _extensionHash = _x getOrDefault [\"hash\", \"\"]; \n    }; \n} forEach allExtensions;\n_extensionHash // \"4CD820DBDBCAEBE6FF654762DA41AF6C97D013B4\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["callExtension"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"allGroups","operator":null,"title":"allGroups","type":"command","url":"https://community.bistudio.com/wiki/allGroups","revid":377010,"updated":"2026-01-01T08:18:18Z","groups":["Groups","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of all groups created on the following sides east, west, resistance/independent and civilian only. Does not contain groups of sideLogic.","syntaxes":[{"syntax":"allGroups","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Groups","types":["Array","Group"],"description":null,"text":"Array of Groups"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ leader _x sideChat \"Go ! Go ! Go !\" } forEach allGroups;\n```","code":["{ leader _x sideChat \"Go ! Go ! Go !\" } forEach allGroups;"]},{"text":"All groups with players:\n\n```sqf\nprivate _allGroupsWithPlayers = [];\n{ _allGroupsWithPlayers pushBackUnique group _x } forEach allPlayers;\n```","code":["private _allGroupsWithPlayers = [];\n{ _allGroupsWithPlayers pushBackUnique group _x } forEach allPlayers;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["group","groups","units","allCurators","allDead","playableUnits","switchableUnits","vehicles","allUnitsUAV"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allLODs","operator":null,"title":"allLODs","type":"command","url":"https://community.bistudio.com/wiki/allLODs","revid":377653,"updated":"2026-01-02T09:02:00Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of object or model LODs.","syntaxes":[{"syntax":"allLODs objectOrModel","since":null,"effect":null,"exec":null,"params":[{"name":"objectOrModel","type":"Object or String","optional":false,"default":null,"description":"Object or String\n- Object - object\n- String - model path (see getModelInfo)","types":["Object","String"],"since":null,"text":"objectOrModel: Object or String\n- Object - object\n- String - model path (see getModelInfo)"}],"returns":{"type":"Array with [LODindex, LODname, LODresolution, countNamedSelections]","types":["Array"],"description":"LODindex: Number - direct index of the LOD for fast access - LODname: String - LOD description name for LOD identification - LODresolution: Number - the actual LOD resolution, could be used to select LOD in selectionNames and selectionPosition - countNamedSelections: Number - number of named selections in this LOD, could be returned with selectionNames command","text":"Array with [LODindex, LODname, LODresolution, countNamedSelections]\n- LODindex: Number - direct index of the LOD for fast access\n- LODname: String - LOD description name for LOD identification\n- LODresolution: Number - the actual LOD resolution, could be used to select LOD in selectionNames and selectionPosition\n- countNamedSelections: Number - number of named selections in this LOD, could be returned with selectionNames command"},"form":"unary","operator":null,"left":null,"right":{"text":"objectOrModel","types":["Object","String"]}}],"examples":[{"text":"```sqf\nallLODs player;\n/*\n    [\n        [0,\"1\",1,91],\n        [1,\"2\",2,91],\n        [2,\"3\",3,84],\n        [3,\"4\",4,43],\n        [4,\"5\",5,34],\n        [5,\"VIEW_PILOT\",1100,89],\n        [6,\"shadow(0)\",10000,80],\n        [7,\"shadow(10)\",10010,33],\n        [8,\"geometry\",1e+013,42],\n        [9,\"memory\",1e+015,55],\n        [10,\"landContact\",2e+015,0],\n        [11,\"hitpoints\",5e+015,33],\n        [12,\"geometryView\",6e+015,19],\n        [13,\"geometryFire\",7e+015,57],\n        [14,\"shadow(1000)\",11000,80],\n        [15,\"shadow(1010)\",11010,33]\n    ]\n*/\n```","code":["allLODs player;\n/*\n\t[\n\t\t[0,\"1\",1,91],\n\t\t[1,\"2\",2,91],\n\t\t[2,\"3\",3,84],\n\t\t[3,\"4\",4,43],\n\t\t[4,\"5\",5,34],\n\t\t[5,\"VIEW_PILOT\",1100,89],\n\t\t[6,\"shadow(0)\",10000,80],\n\t\t[7,\"shadow(10)\",10010,33],\n\t\t[8,\"geometry\",1e+013,42],\n\t\t[9,\"memory\",1e+015,55],\n\t\t[10,\"landContact\",2e+015,0],\n\t\t[11,\"hitpoints\",5e+015,33],\n\t\t[12,\"geometryView\",6e+015,19],\n\t\t[13,\"geometryFire\",7e+015,57],\n\t\t[14,\"shadow(1000)\",11000,80],\n\t\t[15,\"shadow(1010)\",11010,33]\n\t]\n*/"]},{"text":"```sqf\nallLODs getText (configFile >> \"CfgWeapons\" >> \"arifle_MX_F\" >> \"model\");\n/*\n    [\n        [0,\"1\",1,17],\n        [1,\"2\",2,17],\n        [2,\"3\",3,16],\n        [3,\"4\",4,14],\n        [4,\"5\",5,12],\n        [5,\"6\",6,9],\n        [6,\"VIEW_PILOT\",1100,16],\n        [7,\"shadow(0)\",10000,2],\n        [8,\"shadow(10)\",10010,0],\n        [9,\"geometry\",1e+013,0],\n        [10,\"geometrySimple\",2e+013,0],\n        [11,\"memory\",1e+015,13],\n        [12,\"geometryView\",6e+015,2],\n        [13,\"shadow(1000)\",11000,2],\n        [14,\"shadow(1010)\",11010,0]\n    ]\n*/\n```","code":["allLODs getText (configFile >> \"CfgWeapons\" >> \"arifle_MX_F\" >> \"model\");\n/*\n\t[\n\t\t[0,\"1\",1,17],\n\t\t[1,\"2\",2,17],\n\t\t[2,\"3\",3,16],\n\t\t[3,\"4\",4,14],\n\t\t[4,\"5\",5,12],\n\t\t[5,\"6\",6,9],\n\t\t[6,\"VIEW_PILOT\",1100,16],\n\t\t[7,\"shadow(0)\",10000,2],\n\t\t[8,\"shadow(10)\",10010,0],\n\t\t[9,\"geometry\",1e+013,0],\n\t\t[10,\"geometrySimple\",2e+013,0],\n\t\t[11,\"memory\",1e+015,13],\n\t\t[12,\"geometryView\",6e+015,2],\n\t\t[13,\"shadow(1000)\",11000,2],\n\t\t[14,\"shadow(1010)\",11010,0]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleObject","hideSelection","selectionNames","selectionPosition","namedProperties","animationNames","LOD resolutions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"allMapMarkers","operator":null,"title":"allMapMarkers","type":"command","url":"https://community.bistudio.com/wiki/allMapMarkers","revid":352645,"updated":"2024-02-17T18:05:11Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all map marker names, including user-placed markers.\n\n> [!NOTE]\n> - Arma 3 v1.58 User-defined markers have the following name format: `_USER_DEFINED #<PlayerID>/<MarkerID>/<ChannelID>`, where:\n>   - <PlayerID> - unique network id of the player in String format, also available as String in the 6th param in \"PlayerConnected\" and \"PlayerDisconnected\" Event Handlers\n>   - <MarkerID> - an incrementing marker counter id\n>   - <ChannelID> - id of the chat channel in which the marker was placed (see currentChannel)\n> - To obtain the custom waypoint's (set with <kbd>LShift</kbd>+<kbd>LMB</kbd>) position, see customWaypointPosition.","syntaxes":[{"syntax":"allMapMarkers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_markers = allMapMarkers; // returns e.g [\"marker1\", \"_USER_DEFINED #2/0\"]\n```","code":["_markers = allMapMarkers; // returns e.g [\"marker1\", \"_USER_DEFINED #2/0\"]"]},{"text":"```sqf\n{\n    private \"_a\";\n    _a = toArray _x;\n    _a resize 15;\n    if (toString _a == \"_USER_DEFINED #\") then\n    // or if (_x select [0, 15] == \"_USER_DEFINED #\") since Arma 3 v1.28\n    {\n        deleteMarker _x;\n    };\n} forEach allMapMarkers;\n```","code":["{\n\tprivate \"_a\";\n\t_a = toArray _x;\n\t_a resize 15;\n\tif (toString _a == \"_USER_DEFINED #\") then\n\t// or if (_x select [0, 15] == \"_USER_DEFINED #\") since Arma 3 v1.28\n\t{\n\t\tdeleteMarker _x;\n\t};\n} forEach allMapMarkers;"]},{"text":"```sqf\nif (_someString in allMapMarkers) then\n{\n    hint (_someString + \" is an existing marker\");\n};\n```","code":["if (_someString in allMapMarkers) then\n{\n\thint (_someString + \" is an existing marker\");\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMarker","deleteMarker","customWaypointPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"allMines","operator":null,"title":"allMines","type":"command","url":"https://community.bistudio.com/wiki/allMines","revid":377194,"updated":"2026-01-01T10:55:10Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all mines in the mission","syntaxes":[{"syntax":"allMines","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"there are %1 mines total\", count allMines];\n```","code":["hint format [\"there are %1 mines total\", count allMines];"]},{"text":"```sqf\nprivate _isFirstMineDetected = (allMines select 0) mineDetectedBy blufor;\n```","code":["private _isFirstMineDetected = (allMines select 0) mineDetectedBy blufor;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["detectedMines","mineDetectedBy","createMine","mineActive","revealMine","allMissionObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"allMissionObjects","operator":null,"title":"allMissionObjects","type":"command","url":"https://community.bistudio.com/wiki/allMissionObjects","revid":369567,"updated":"2024-09-24T07:52:15Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all objects of the given type that are currently present in the mission. In some cases, the entities and allObjects commands are much faster alternatives to this command.\n\nSome of the special types that can be detected with this command (and with nearestObject):\n- `\"\"` - returns everything, e.g. agents, bees, mosquitoes, footprints, armed mines, ...\n- `\"all\"` - more restrictive than `\"\"`: no ambient insects, only agents such as rabbits and snakes, no footprints, tracks, no armed mines\n- `\"#slop\"` - blood drops\n- `\"#mark\"` - unit footprints\n- `\"#track\"` - vehicle tracks\n- `\"#crater\"` - explosion craters on the ground\n- `\"#crateronvehicle\"` - bullet marks on vehicles\n- `\"#explosion\"` - explosions\n- `\"#objectdestructed\"` - building, tree or bush destruction\n- `\"#soundonvehicle\"` - sounds created with say3D for example\n- `\"#dynamicsound\"` - sound sources created using createSoundSource\n- `\"EmptyDetector\"` - all Triggers\n- `\"Logic\"` - all game logics\n\n> [!IMPORTANT]\n> This command is quite performance heavy. Use with caution!","syntaxes":[{"syntax":"allMissionObjects type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_airObjects = allMissionObjects \"Air\";\n```","code":["_airObjects = allMissionObjects \"Air\";"]},{"text":"```sqf\n{ deleteVehicle _x; } forEach (allMissionObjects \"\");\n```","code":["{ deleteVehicle _x; } forEach (allMissionObjects \"\");"]},{"text":"```sqf\n_allMObjects = allMissionObjects \"All\";\n```","code":["_allMObjects = allMissionObjects \"All\";"]}],"multiplayer":"> [!NOTE]\n> This command is ~5 times faster on a dedicated server than on a client. Reason unknown.","problems":null,"aliases":[],"see_also":["allObjects","allDead","allGroups","allUnits","entities","vehicles","allMines","allSimpleObjects"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2: Operation Arrowhead version 1.57","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allObjects","operator":null,"title":"allObjects","type":"command","url":"https://community.bistudio.com/wiki/allObjects","revid":377077,"updated":"2026-01-01T09:39:24Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of requested objects as fast as the engine allows it. The objects can be requested by object type and simulation kind.\n\n> [!NOTE]\n> This command does not return terrain placed objects (except for terrain objects with lights, such as lamp posts, etc. which can be found in the slow entities collection). To get all terrain objects, use nearestTerrainObjects instead.","syntaxes":[{"syntax":"objectType allObjects objectCollection","since":null,"effect":null,"exec":null,"params":[{"name":"objectType","type":"Number","optional":false,"default":null,"description":"type can be a combination of types according to bit flag operation (see getObjectType):\n- -1 - Arma 3 v2.12 All types incl. nulls (nulls exist with 'objectCollection' 7 and 8)\n- 1 - Primary - normal object placed in Terrain Builder, part of landscape\n- 2 - Network - road placed in Terrain Builder, part of landscape\n- 4 - Temporary - temporary object (like vehicle tracks)\n- 8 - TypeVehicle - entity added by game\n- 16 - TypeTempVehicle - temporary entity\n- 32 - LandDecal - land decal\nFor example if required objects are both TerrainBuilder-placed (**1**) and dynamically placed (**8**) the combination type will be  8 + 1 = **9**\n\n> [!NOTE]\n> Use **63** (1 + 2 + 4 + 8 + 16 + 32) to return objects of all types (excl. nulls).","types":["Number"],"since":null,"text":"objectType: Number - type can be a combination of types according to bit flag operation (see getObjectType):\n- -1 - Arma 3 v2.12 All types incl. nulls (nulls exist with 'objectCollection' 7 and 8)\n- 1 - Primary - normal object placed in Terrain Builder, part of landscape\n- 2 - Network - road placed in Terrain Builder, part of landscape\n- 4 - Temporary - temporary object (like vehicle tracks)\n- 8 - TypeVehicle - entity added by game\n- 16 - TypeTempVehicle - temporary entity\n- 32 - LandDecal - land decal\nFor example if required objects are both TerrainBuilder-placed (**1**) and dynamically placed (**8**) the combination type will be  8 + 1 = **9**\n\n> [!NOTE]\n> Use **63** (1 + 2 + 4 + 8 + 16 + 32) to return objects of all types (excl. nulls)."},{"name":"objectCollection","type":"Number","optional":false,"default":null,"description":"supported values:\n- 0 - Slow (and very slow) entities: some houses, rubbles, street lamps, churches, etc\n- 1 - Normal entities: vehicles etc\n- 2 - Fast entities: shots and other high precision entities\n- 3 - Cloudlets: smokes, dust, etc\n- 4 - Out vehicles: objects that are not listed anywhere else, holders, etc\n- 5 - Animals: animals, birds, insects, etc\n- 6 - Mines: mines\n- 7 - Arma 3 v2.12 Sensor map: ordered triggers. When trigger is created it is added to this collection in the order of creation. When deleted it becomes null. Use 'objectType' -1 to include nulls\n- 8 - Arma 3 v2.12 Vehicle map: ordered vehicles. When vehicle is created it is added to this collection in the order of creation. When deleted it becomes null. Use 'objectType' -1 to include nulls\n- 9 - Arma 3 v2.18 Vehicles and crew: normal entities as in 1 as well as crew if an entity is a vehcile with crew.\n- 10 - Arma 3 v2.22 Windlets: all objects of the type '#windlet'.\n- 11 - Arma 3 v2.22 Active windlets: all objects of the type '#windlet' which are enabled.","types":["Number"],"since":null,"text":"objectCollection: Number - supported values:\n- 0 - Slow (and very slow) entities: some houses, rubbles, street lamps, churches, etc\n- 1 - Normal entities: vehicles etc\n- 2 - Fast entities: shots and other high precision entities\n- 3 - Cloudlets: smokes, dust, etc\n- 4 - Out vehicles: objects that are not listed anywhere else, holders, etc\n- 5 - Animals: animals, birds, insects, etc\n- 6 - Mines: mines\n- 7 - Arma 3 v2.12 Sensor map: ordered triggers. When trigger is created it is added to this collection in the order of creation. When deleted it becomes null. Use 'objectType' -1 to include nulls\n- 8 - Arma 3 v2.12 Vehicle map: ordered vehicles. When vehicle is created it is added to this collection in the order of creation. When deleted it becomes null. Use 'objectType' -1 to include nulls\n- 9 - Arma 3 v2.18 Vehicles and crew: normal entities as in 1 as well as crew if an entity is a vehcile with crew.\n- 10 - Arma 3 v2.22 Windlets: all objects of the type '#windlet'.\n- 11 - Arma 3 v2.22 Active windlets: all objects of the type '#windlet' which are enabled."}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"objectType","types":["Number"]},"right":{"text":"objectCollection","types":["Number"]}},{"syntax":"objectType allObjects objectCollection","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"objectType","type":"String","optional":false,"default":null,"description":"type of the objects (will exact match return of typeOf)","types":["String"],"since":null,"text":"objectType: String - type of the objects (will exact match return of typeOf)"},{"name":"objectCollection","type":"Number","optional":false,"default":null,"description":"see main syntax above","types":["Number"],"since":null,"text":"objectCollection: Number - see main syntax above"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"objectType","types":["String"]},"right":{"text":"objectCollection","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _visitorBuildings = 1 allObjects 0;\n```","code":["private _visitorBuildings = 1 allObjects 0;"]},{"text":"```sqf\nprivate _userPlacedBuildings = 8 allObjects 0;\n```","code":["private _userPlacedBuildings = 8 allObjects 0;"]},{"text":"```sqf\nonEachFrame\n{\n    hintSilent str\n    [\n        count (63 allObjects 0),\n        count (63 allObjects 1),\n        count (63 allObjects 2),\n        count (63 allObjects 3),\n        count (63 allObjects 4),\n        count (63 allObjects 5),\n        count (63 allObjects 6)\n    ];\n};\n```","code":["onEachFrame\n{\n\thintSilent str\n\t[\n\t\tcount (63 allObjects 0),\n\t\tcount (63 allObjects 1),\n\t\tcount (63 allObjects 2),\n\t\tcount (63 allObjects 3),\n\t\tcount (63 allObjects 4),\n\t\tcount (63 allObjects 5),\n\t\tcount (63 allObjects 6)\n\t];\n};"]},{"text":"```sqf\nprivate _allGroundWeaponHolders = \"GroundWeaponHolder\" allObjects 0;\nprivate _allSimulatedWeaponHolders = \"WeaponHolderSimulated\" allObjects 1;\n```","code":["private _allGroundWeaponHolders = \"GroundWeaponHolder\" allObjects 0;\nprivate _allSimulatedWeaponHolders = \"WeaponHolderSimulated\" allObjects 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectFOV","cursorObject","cursorTarget","createSimpleObject","allMissionObjects","setObjectViewDistance","getObjectViewDistance","objectParent","object","getObjectType","allPlayers","allGroups","allDead","playableUnits","switchableUnits","units","vehicles","allUnitsUAV","allCurators","playersNumber"],"notes":[{"user":"PierreMGI","date":"2022-11-30T17:32:09Z","text":"This command (`63 allObjects 0`) will return lamps or poles but not houses. Use nearestTerrainObjects instead."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"allow3DMode","operator":null,"title":"allow3DMode","type":"command","url":"https://community.bistudio.com/wiki/allow3DMode","revid":363291,"updated":"2024-03-26T10:51:58Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Allow/dissallow 3D mode.,\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map allow3DMode bool","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allowCrewInImmobile","operator":null,"title":"allowCrewInImmobile","type":"command","url":"https://community.bistudio.com/wiki/allowCrewInImmobile","revid":322540,"updated":"2022-06-15T14:00:23Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"If true, units will remain in a vehicle with broken tracks/wheels; they will still eject if the vehicle is drowning, about to explode or upside down for a while.\nThe alternative syntax provides the ability to keep the crew in vehicle when it is upside down.","syntaxes":[{"syntax":"vehicle allowCrewInImmobile allow","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"allow","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allow: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"allow","types":["Boolean"]}},{"syntax":"vehicle allowCrewInImmobile [brokenWheels, upsideDown]","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"brokenWheels","type":"Boolean","optional":false,"default":null,"description":"do not auto eject when vehicle has broken wheels","types":["Boolean"],"since":null,"text":"brokenWheels: Boolean - do not auto eject when vehicle has broken wheels"},{"name":"upsideDown","type":"Boolean","optional":false,"default":null,"description":"do not auto eject when vehicle is upside down","types":["Boolean"],"since":null,"text":"upsideDown: Boolean - do not auto eject when vehicle is upside down"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[brokenWheels, upsideDown]","types":["Array"]}}],"examples":[{"text":"```sqf\n_vehicle allowCrewInImmobile true;\n```","code":["_vehicle allowCrewInImmobile true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAllowedCrewInImmobile","setUnloadInCombat","canMove"],"notes":[{"user":"Killzone_Kid","date":"2015-04-27T19:52:00Z","text":"This will stop AI disembarking when immobile\n\n```sqf\nKK_fnc_allowCrewInImmobile = {\n    _this allowCrewInImmobile true;\n    {\n        _x disableAI \"FSM\";\n        _x setBehaviour \"CARELESS\";\n    } forEach crew _this;\n};\n//example\ncar call KK_fnc_allowCrewInImmobile;\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"allowCuratorLogicIgnoreAreas","operator":null,"title":"allowCuratorLogicIgnoreAreas","type":"command","url":"https://community.bistudio.com/wiki/allowCuratorLogicIgnoreAreas","revid":348345,"updated":"2023-11-08T12:59:49Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Allows curator placing and working with modules outside of edit areas.","syntaxes":[{"syntax":"curatorObj allowCuratorLogicIgnoreAreas allow","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"allow","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allow: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"allow","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncuratorModule allowCuratorLogicIgnoreAreas true;\n```","code":["curatorModule allowCuratorLogicIgnoreAreas true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorEditingArea","removeCuratorEditingArea","removeAllCuratorEditingAreas","curatorEditingArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"allowDamage","operator":null,"title":"allowDamage","type":"command","url":"https://community.bistudio.com/wiki/allowDamage","revid":378125,"updated":"2026-02-21T14:29:34Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enables / disables an entity's ability to receive damage.\nThis command does not prevent the entity from taking scripted damage from commands such as setDamage, setHit, setHitIndex or setHitPointDamage.\n\n> [!NOTE]\n> This command only supports entities (`Entity` is a child class of `Object`, i.e. all entities are objects, but not all objects are entities).\n> Consequently, there are objects that are not affected by this command, for example terrain vegetation such as trees.","syntaxes":[{"syntax":"entity allowDamage allow","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"allow","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allow: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"allow","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer allowDamage false;\n```","code":["player allowDamage false;"]}],"multiplayer":"> [!IMPORTANT]\n> This command has to be executed where the object is local.\n> Its effect will only last as long as the object does not change locality.\n> If the object changes locality, the command needs to be executed again on the new owner's machine to maintain the effect.","problems":null,"aliases":["allowDammage"],"see_also":["isDamageAllowed","setDamage","setHit","setHitIndex","setHitPointDamage","damage"],"notes":[{"user":"AgentRev01","date":"2013-09-02T18:26:00Z","text":"```sqf\n_object allowDamage false;\n```\n\nhas the same effect as\n\n```sqf\n_object addEventHandler [\"HandleDamage\", { 0 }];\n```\n\n**except for buildings that are native to the map**; for those, the effects of HandleDamage will not sync properly across all clients, even if added to the building on every client and the server."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"allowDammage","operator":null,"title":"allowDammage","type":"command","url":"https://community.bistudio.com/wiki/allowDammage","revid":310281,"updated":"2022-05-05T13:11:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Allow or prevent an object being damaged (or injured, or killed). The command does not prevent object from taking scripted damage such as setDamage or setHit.","syntaxes":[{"syntax":"object allowDammage allow","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"allow","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allow: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"allow","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer allowDammage false;\n```","code":["player allowDammage false;"]}],"multiplayer":"> [!IMPORTANT]\n> The command has to be executed where the object is local and will be effective as long as the object does not change locality.\n> If the object changes locality, the command needs to be executed again on the new owner's machine to maintain the effect.","problems":"This command did nothing until Arma 2.","aliases":["allowDamage"],"see_also":["setDamage","damage","allowDamage"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"allowedService","operator":null,"title":"allowedService","type":"command","url":"https://community.bistudio.com/wiki/allowedService","revid":338348,"updated":"2023-02-28T14:43:47Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns which types of repair/refuel/rearm service are allowed. The two available types are manual, where the action is displayed to the user, and auto, where the service happens within distance.\nThe engine default is both (manual and auto) for historic reasons.","syntaxes":[{"syntax":"allowedService vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"supply vehicle, i.e. ammo truck","types":["Object"],"since":null,"text":"vehicle: Object - supply vehicle, i.e. ammo truck"}],"returns":{"type":"Number","types":["Number"],"description":"0: none, 1: auto, 2: manual, 3: both, -1: unsupported","text":"Number - 0: none, 1: auto, 2: manual, 3: both, -1: unsupported"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (allowedService _vehicle == -1) then { hint \"this is not a service vehicle!\" };\n```","code":["if (allowedService _vehicle == -1) then { hint \"this is not a service vehicle!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowService","needService"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"allowFileOperations","operator":null,"title":"allowFileOperations","type":"command","url":"https://community.bistudio.com/wiki/allowFileOperations","revid":363287,"updated":"2024-03-26T10:51:56Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Allow/dissallow file ops (load/save etc).\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map allowFileOperations bool","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allowFleeing","operator":null,"title":"allowFleeing","type":"command","url":"https://community.bistudio.com/wiki/allowFleeing","revid":310112,"updated":"2022-05-05T12:25:24Z","groups":["Object Manipulation","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the cowardice level (the lack of courage or bravery) of a group or unit.\n\nNotes:\n- Fleeing only affects AI led groups.\n- Only the group as a whole can flee (or not).\n- The courage of the AI group is based on the group's leader courage subskill.\n- Each group has a max strength (summed \"armor\" of all infantry units - plus armor when inside vehicles).\n- If the group losses by injury/damage or death/destruction are higher than the max strength, multiplied by leader's courage or allowFleeing level , then the group will start fleeing.\n- As result primarily the AI flees to a nearby \"supply point\" (some friendly units - preferably with medic or engineer, or a vehicle with repair/ammo/fuel cargo). Alternatively it will try to find a safe position within a 600m radius from the initial waypoint (danger, distance, amount of cover positions are taken into account).\n- After the fleeing has been finished the group's initial strength is reset.\n- Fleeing units in combatMode red, will be set to yellow when fleeing to avoid engaging enemies while doing so.\n- While fleeing, the group leader will be set to green, to avoid giving engage or fire orders, unless in combatMode blue already. Also speedMode is set to full.\n- When reaching their flee point/destination, they will change to combatMode yellow and speedMode normal.\n- With allowFleeing one can make unit's flee earlier (or essentially never flee). Apply it, overrides the courage subskill influence.","syntaxes":[{"syntax":"unitOrGroup allowFleeing cowardice","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrGroup","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"unitOrGroup: Object or Group"},{"name":"cowardice","type":"Number","optional":false,"default":null,"description":"1 is maximum cowardice and 0 minimum. A value of 0 will disable fleeing all together","types":["Number"],"since":null,"text":"cowardice: Number - 1 is maximum cowardice and 0 minimum. A value of 0 will disable fleeing all together"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitOrGroup","types":["Object","Group"]},"right":{"text":"cowardice","types":["Number"]}}],"examples":[{"text":"```sqf\n_group1 allowFleeing 0;\n```","code":["_group1 allowFleeing 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fleeing"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"allowGetIn","operator":null,"title":"allowGetIn","type":"command","url":"https://community.bistudio.com/wiki/allowGetIn","revid":318643,"updated":"2022-05-13T09:21:14Z","groups":["Object Manipulation","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Set if the units given in the list are allowed to enter vehicles.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitArray allowGetIn allow","since":null,"effect":null,"exec":null,"params":[{"name":"unitArray","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"unitArray: Array of Objects"},{"name":"allow","type":"Boolean","optional":false,"default":null,"description":"true allows the units to enter, false denies them","types":["Boolean"],"since":null,"text":"allow: Boolean - true allows the units to enter, false denies them"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitArray","types":["Array","Object"]},"right":{"text":"allow","types":["Boolean"]}}],"examples":[{"text":"```sqf\n[_soldier1, _soldier2] allowGetIn true;\n```","code":["[_soldier1, _soldier2] allowGetIn true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["orderGetIn"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"allowService","operator":null,"title":"allowService","type":"command","url":"https://community.bistudio.com/wiki/allowService","revid":338347,"updated":"2023-02-28T14:43:36Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets which type of repair/refuel/rearm service is allowed. The two available types are manual, where the action is displayed to the user, and auto, where the service happens within distance.\nThe engine default is both (manual and auto) for historic reasons.","syntaxes":[{"syntax":"vehicle allowService type","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"supply vehicle, i.e. ammo truck","types":["Object"],"since":null,"text":"vehicle: Object - supply vehicle, i.e. ammo truck"},{"name":"type","type":"Number","optional":false,"default":null,"description":"0: none, 1: auto, 2: manual, 3: both","types":["Number"],"since":null,"text":"type: Number - 0: none, 1: auto, 2: manual, 3: both"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"type","types":["Number"]}}],"examples":[{"text":"```sqf\nammoTruck allowService 0;\n```","code":["ammoTruck allowService 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowedService","needService"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"allowSprint","operator":null,"title":"allowSprint","type":"command","url":"https://community.bistudio.com/wiki/allowSprint","revid":341801,"updated":"2023-06-24T08:22:32Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Force player to run/jog if set to false.","syntaxes":[{"syntax":"unit allowSprint state","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"state: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer allowSprint false;\n```","code":["player allowSprint false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","isSprintAllowed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"allPlayers","operator":null,"title":"allPlayers","type":"command","url":"https://community.bistudio.com/wiki/allPlayers","revid":370218,"updated":"2024-11-10T14:50:49Z","groups":["Multiplayer","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all units controlled by connected clients. This includes:\n- Normal human players (including dead players)\n- Virtual Entities (see *Systems* → *Logic Entities* → *Virtual Entities* in the Eden Editor)\n  - Headless Clients (`HeadlessClient_F`)\n  - Virtual Curators (`VirtualCurator_F`, `- _VirtualCurator_F`)\n  - Virtual Spectators (`VirtualSpectator_F`)\n\nUse BIS_fnc_listPlayers or see #Example 1 to only get human players.","syntaxes":[{"syntax":"allPlayers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Get human players (i.e. all players excluding Headless Clients):\n\n```sqf\nprivate _players = allPlayers - entities \"HeadlessClient_F\";\n```","code":["private _players = allPlayers - entities \"HeadlessClient_F\";"]},{"text":"Get non-virtual players (i.e. all players excluding Virtual Entities):\n\n```sqf\nprivate _players = allPlayers select {!(_x isKindOf \"VirtualMan_F\")};\n```","code":["private _players = allPlayers select {!(_x isKindOf \"VirtualMan_F\")};"]},{"text":"```sqf\n{\n    systemChat format [\n        \"Player %1 is %2\", \n        name _x, \n        [\"dead\", \"alive\"] select alive _x\n    ];\n} forEach allPlayers;\n```","code":["{\n\tsystemChat format [\n\t\t\"Player %1 is %2\", \n\t\tname _x, \n\t\t[\"dead\", \"alive\"] select alive _x\n\t];\n} forEach allPlayers;"]},{"text":"```sqf\nprivate _bluforPlayers = blufor countSide allPlayers;\n```","code":["private _bluforPlayers = blufor countSide allPlayers;"]}],"multiplayer":"- The complete array of allPlayers may get delayed on mission start in multiplayer. Use BIS_fnc_listPlayers to obtain it earlier.\n- The order of the returned array may differ from server to clients.","problems":null,"aliases":[],"see_also":["allCurators","allGroups","allDead","allUnits","switchableUnits","playableUnits","vehicles","allUnitsUAV","allDeadMen","isPlayer","playersNumber","allUsers","getUserInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Detection","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"allSimpleObjects","operator":null,"title":"allSimpleObjects","type":"command","url":"https://community.bistudio.com/wiki/allSimpleObjects","revid":377075,"updated":"2026-01-01T09:37:55Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of all simple objects that belong to the listed class names. If the array of types is empty [], all simple objects are returned including those without class name.\n\n> [!NOTE]\n> - There is no inheritance in simple objects, so only exact class match is allowed.\n> - *className* is not case sensitive.","syntaxes":[{"syntax":"allSimpleObjects classes","since":null,"effect":null,"exec":null,"params":[{"name":"classes","type":"Array of Strings","optional":false,"default":null,"description":"classnames array. Use `[]` to return all simple objects","types":["Array","String"],"since":null,"text":"classes: Array of Strings - classnames array. Use `[]` to return all simple objects"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"all simple objects","text":"Array of Objects - all simple objects"},"form":"unary","operator":null,"left":null,"right":{"text":"classes","types":["Array","String"]}}],"examples":[{"text":"```sqf\nprivate _boxesAndChairs = allSimpleObjects [\"Box_NATO_Equip_F\", \"Land_CampingChair_V2_F\"];\n```","code":["private _boxesAndChairs = allSimpleObjects [\"Box_NATO_Equip_F\", \"Land_CampingChair_V2_F\"];"]},{"text":"```sqf\nprivate _allSimpleObjects = allSimpleObjects [];\n```","code":["private _allSimpleObjects = allSimpleObjects [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleObject","isSimpleObject","nearestObjects","nearObjectsReady","nearObjects","nearestObject","createVehicle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"allSites","operator":null,"title":"allSites","type":"command","url":"https://community.bistudio.com/wiki/allSites","revid":378477,"updated":"2026-04-24T11:33:54Z","groups":["Broken Commands","Sides"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return all sites in map.\n\n> [!WARNING]\n> This command is considered deprecated and is no longer supported","syntaxes":[{"syntax":"allSites","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_allSites = allSites;\n```","code":["_allSites = allSites;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteSite","createSite","allGroups","allDead","playableUnits","switchableUnits","vehicles","allUnitsUAV","allCurators","allDeadMen"],"notes":[{"user":"Killzone_Kid","date":"2022-08-29T21:48:02Z","text":"Well, this command is not broken, it just doesn't have anything to return."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Sides","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"allTurrets","operator":null,"title":"allTurrets","type":"command","url":"https://community.bistudio.com/wiki/allTurrets","revid":378481,"updated":"2026-04-24T12:20:34Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of available turret paths from vehicle object.\n\n> [!NOTE]\n> - to look up turrets from config, use BIS_fnc_allTurrets\n> - to get config from turret path, use BIS_fnc_turretConfig","syntaxes":[{"syntax":"allTurrets vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array of Turret Paths","types":["Array","Turret Path"],"description":null,"text":"Array of Turret Paths"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"allTurrets [vehicle, includeFFV]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"includeFFV","type":"Boolean","optional":false,"default":null,"description":"true to include FFV (Firing From Vehicle) positions, false to exclude them","types":["Boolean"],"since":null,"text":"includeFFV: Boolean - true to include FFV (Firing From Vehicle) positions, false to exclude them"}],"returns":{"type":"Array of Turret Paths","types":["Array","Turret Path"],"description":null,"text":"Array of Turret Paths"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, includeFFV]","types":["Array"]}}],"examples":[{"text":"```sqf\n_turretPaths = allTurrets _mySlammerUP;                // [[0],[0,0]]\n_turretPaths = allTurrets [_mySlammerUP, true];        // [[0],[0,0]] <- commander turret is also an FFV turret\n_turretPaths = allTurrets [_mySlammerUP, false];    // [[0]]\n```","code":["_turretPaths = allTurrets _mySlammerUP;\t\t\t\t// [[0],[0,0]]\n_turretPaths = allTurrets [_mySlammerUP, true];\t\t// [[0],[0,0]] <- commander turret is also an FFV turret\n_turretPaths = allTurrets [_mySlammerUP, false];\t// [[0]]"]},{"text":"Return FFV turrets only:\n\n```sqf\n_FFVTurrets = allTurrets [tank, true] - allTurrets [tank, false];\n```","code":["_FFVTurrets = allTurrets [tank, true] - allTurrets [tank, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInTurret","enablePersonTurret","assignedVehicleRole","fullCrew","turretUnit","turretLocal","turretOwner","BIS_fnc_allTurrets","BIS_fnc_turretConfig"],"notes":[{"user":"AgentRev","date":"2016-04-13T19:13:00Z","text":"The first syntax (vehicle only without boolean) will include commander turrets like in the example, and does not include actual FFV turrets like offroad back seats, as expected.\n\nAlso, the driver turret [-1] is never included in the results, which can be solved as follows:\n\n```sqf\n_paths = [[-1]] + allTurrets _vehicle;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"allUnits","operator":null,"title":"allUnits","type":"command","url":"https://community.bistudio.com/wiki/allUnits","revid":377076,"updated":"2026-01-01T09:38:35Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all units, **except agents, dead units or units waiting for respawn**, outside and inside vehicles that were created on the following sides east, west, independent and civilian.\n\n> [!NOTE]\n> **Arma 3:** To get all units of given side, use `units Side`.","syntaxes":[{"syntax":"allUnits","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of objects","types":["Array","Object"],"description":null,"text":"Array of objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ _x setDamage 0.5; _x groupChat \"Braaains\"; } forEach allUnits;\n```","code":["{ _x setDamage 0.5; _x groupChat \"Braaains\"; } forEach allUnits;"]},{"text":"```sqf\nallUnits apply { diag_log _x; };\n```","code":["allUnits apply { diag_log _x; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allGroups","groups","units","vehicles","entities","agents","playableUnits","switchableUnits","allPlayers","allDead","allDeadMen","allUnitsUAV","allCurators","allObjects","allMissionObjects","allSimpleObjects","allMines"],"notes":[{"user":"Pierre MGI","date":"2018-09-06T16:43:00Z","text":"It returns also BIS_SUPP_HQ created by support modules and headquarters Entity from HQ modules."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"allUnitsUAV","operator":null,"title":"allUnitsUAV","type":"command","url":"https://community.bistudio.com/wiki/allUnitsUAV","revid":364114,"updated":"2024-05-04T22:05:25Z","groups":["Remote Control","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of all UAV vehicles.","syntaxes":[{"syntax":"allUnitsUAV","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"array of UAV vehicles","text":"Array of Objects - array of UAV vehicles"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"Number of UAV(s) on the map: %1\", count allUnitsUAV];\n```","code":["hint format [\"Number of UAV(s) on the map: %1\", count allUnitsUAV];"]},{"text":"```sqf\n{ _x setDamage 1 } forEach allUnitsUAV;\n```","code":["{ _x setDamage 1 } forEach allUnitsUAV;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitIsUAV","allCurators","allGroups","allDead","playableUnits","switchableUnits","vehicles","allDeadMen","agents","showUAVFeed","shownUAVFeed","getConnectedUAV","UAVControl","connectTerminalToUAV","isUAVConnected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Remote Control","Introduced with Arma 3 version 0.76","Scripting Commands"]},{"name":"allUsers","operator":null,"title":"allUsers","type":"command","url":"https://community.bistudio.com/wiki/allUsers","revid":378526,"updated":"2026-05-04T01:56:35Z","groups":["Multiplayer","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Returns a list of player ids of all the users on an MP server.\n\n> [!NOTE]\n> This also lists Headless Clients.","syntaxes":[{"syntax":"allUsers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"user network IDs (see getPlayerID, getUserInfo)","text":"Array of Strings - user network IDs (see getPlayerID, getUserInfo)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isServer) then\n{\n    private _allUserIDs = allUsers;\n    for \"_i\" from 0 to (count _allUserIds - 1) do\n    {\n        diag_log format [\"User #%1 ID: %2\", _i + 1, _allUserIds select _i];\n    };\n};\n```","code":["if (isServer) then\n{\n\tprivate _allUserIDs = allUsers;\n\tfor \"_i\" from 0 to (count _allUserIds - 1) do\n\t{\n\t\tdiag_log format [\"User #%1 ID: %2\", _i + 1, _allUserIds select _i];\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUserInfo","getPlayerID","allPlayers","allCurators","allGroups","allDead","allUnits","switchableUnits","playableUnits","vehicles","allUnitsUAV","allDeadMen","isPlayer","playersNumber"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Detection","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"allVariables","operator":null,"title":"allVariables","type":"command","url":"https://community.bistudio.com/wiki/allVariables","revid":338534,"updated":"2023-03-15T15:11:36Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all variables from the desired namespace.","syntaxes":[{"syntax":"allVariables namespace","since":null,"effect":null,"exec":null,"params":[{"name":"namespace","type":null,"optional":false,"default":null,"description":"Namespace, Object, Group, Task, Location, Team Member, Arma 3 v2.02 Control, Arma 3 v2.02 Display","types":["Namespace","Object","Group","Task","Location","Team Member","Control","Display"],"since":null,"text":"namespace: Namespace, Object, Group, Task, Location, Team Member, Arma 3 v2.02 Control, Arma 3 v2.02 Display"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of variable names. All names are in lower case (see toLower)","text":"Array of Strings - array of variable names. All names are in lower case (see toLower)"},"form":"unary","operator":null,"left":null,"right":{"text":"namespace","types":["Namespace","Object","Group","Task","Location","Team Member","Control","Display"]}}],"examples":[{"text":"```sqf\n_allVarsUINamespace = allVariables uiNamespace;\n```","code":["_allVarsUINamespace = allVariables uiNamespace;"]},{"text":"```sqf\n_allVarsTrigger = allVariables trigger1;\n```","code":["_allVarsTrigger = allVariables trigger1;"]}],"multiplayer":"> [!IMPORTANT]\n> Using profileNamespace and uiNamespace with this command has been disabled in multiplayer in Arma 3 v1.40 - see [Changelog](https://forums.bohemia.net/forums/topic/140837-development-branch-changelog/?do=findComment&comment=2869646).","problems":null,"aliases":[],"see_also":["allControls","allDisplays","allCurators","allGroups","allDead","allDeadMen"],"notes":[{"user":"longbow","date":"2016-10-01T23:54:00Z","text":"One still can use allVariables in Multiplayer against profileNamespace and uiNamespace using config parser. In Description.ext\n\n```sqf\n_EXEC(someVar = allVariables profileNamespace)\n```\n\nin code\n\n```sqf\n_allProfileVars = parsingNamespace getVariable \"someVar\"\n```\n\nbut this list will be valid only at the moment of config parsing."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"ambientTemperature","operator":null,"title":"ambientTemperature","type":"command","url":"https://community.bistudio.com/wiki/ambientTemperature","revid":347561,"updated":"2023-09-28T09:49:53Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ambient temperature on the current terrain in Celsius in format: [airTemperature, blackSurfaceTemperature, whiteSurfaceTemperature]","syntaxes":[{"syntax":"ambientTemperature","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Array","Number"],"description":null,"text":"Array of Numbers in format [airTemperature, blackSurfaceTemperature, whiteSurfaceTemperature]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _airTemp = ambientTemperature select 0;\n```","code":["private _airTemp = ambientTemperature select 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWeatherChange"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"ammo","operator":null,"title":"ammo","type":"command","url":"https://community.bistudio.com/wiki/ammo","revid":364083,"updated":"2024-05-03T19:33:29Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check how many rounds are left in the currently loaded magazine in the given muzzle.\n\n> [!NOTE]\n> In older titles and before Arma 3 v1.56, the command did not return ammo for units in vehicles.","syntaxes":[{"syntax":"unit ammo muzzle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"weapon's muzzle - see the Weapons topic for reference about possible values","types":["String"],"since":null,"text":"muzzle: String - weapon's muzzle - see the Weapons topic for reference about possible values"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"muzzle","types":["String"]}}],"examples":[{"text":"```sqf\n_count = player ammo \"M16\"; // returns 30 in case of a full magazine\n```","code":["_count = player ammo \"M16\"; // returns 30 in case of a full magazine"]},{"text":"```sqf\n_count = player ammo \"M203Muzzle\";\n```","code":["_count = player ammo \"M203Muzzle\";"]},{"text":"```sqf\n_count = player ammo primaryWeapon player;\n```","code":["_count = player ammo primaryWeapon player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAmmo","someAmmo","magazines"],"notes":[{"user":".kju","date":"2012-02-17T22:38:00Z","text":"The command works (now?) also for units in vehicles. However only for the vehicle's gunners' weapons - aka those returned by \"weapons vehicle\"."},{"user":".kju","date":"2018-08-30T17:42:00Z","text":"Actually the command wants the `currentMuzzle (gunner _vehicle)` as parameter - not the weapon class.\nMost of the time both are the same. However when you have custom modes[] for the weapons, this is likely not true."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ammoOnPylon","operator":null,"title":"ammoOnPylon","type":"command","url":"https://community.bistudio.com/wiki/ammoOnPylon","revid":347947,"updated":"2023-11-07T05:27:04Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ammo count on given pylon (or false on failure).","syntaxes":[{"syntax":"vehicle ammoOnPylon pylon","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"pylon","type":"String or Number","optional":false,"default":null,"description":"pylon's name or index","types":["String","Number"],"since":null,"text":"pylon: String or Number - pylon's name or index"}],"returns":{"type":"Number or Boolean","types":["Number","Boolean"],"description":"false on failure","text":"Number or Boolean - false on failure"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"pylon","types":["String","Number"]}}],"examples":[{"text":"```sqf\nprivate _ammoCount = (vehicle player) ammoOnPylon \"pylon1\";\n```","code":["private _ammoCount = (vehicle player) ammoOnPylon \"pylon1\";"]},{"text":"```sqf\nhint str (vehicle player ammoOnPylon \"pylonCenter\");\n```","code":["hint str (vehicle player ammoOnPylon \"pylonCenter\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","setAmmoOnPylon","getCompatiblePylonMagazines","getPylonMagazines","animatePylon","animateBay","setPylonsPriority","setPylonLoadout"],"notes":[{"user":"Commy2","date":"2017-08-18T14:21:00Z","text":"The pylon indices start at 1 and not at 0."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"and","operator":null,"title":"and","type":"command","url":"https://community.bistudio.com/wiki/and","revid":349274,"updated":"2023-11-08T14:51:11Z","groups":["Variables","Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true only if both conditions are true.\nIn case of the alternative syntax, [lazy evaluation](https://en.wikipedia.org/wiki/Lazy_evaluation#Control_structures) is used - if left operand is false, evaluation of the right side is ignored.","syntaxes":[{"syntax":"a and b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"b: Boolean - test condition or variable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Boolean"]}},{"syntax":"a and b","since":"arma2oa 1.62","effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Code","optional":false,"default":null,"description":"code that returns Boolean. It is **not** evaluated if *a* is false","types":["Code"],"since":null,"text":"b: Code - code that returns Boolean. It is **not** evaluated if *a* is false"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Code"]}}],"examples":[{"text":"```sqf\nif ((not isNull player) and (alive player) and (_enemycount == 0)) then\n{\n    hint \"you win !\";\n};\n```","code":["if ((not isNull player) and (alive player) and (_enemycount == 0)) then\n{\n\thint \"you win !\";\n};"]},{"text":"```sqf\nif ((count _array > 0) and { (_array select 0) == player }) then    // works as expected\n{\n    hint \"It works!\";\n};\n\nif ((count _array > 0) and (_array select 0) == player) then        // Error: _array select 0 is evaluated\n{\n    hint \"It... works?\";\n};\n```","code":["if ((count _array > 0) and { (_array select 0) == player }) then\t// works as expected\n{\n\thint \"It works!\";\n};\n\nif ((count _array > 0) and (_array select 0) == player) then\t\t// Error: _array select 0 is evaluated\n{\n\thint \"It... works?\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["a && b"],"see_also":["a && b","or","Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"angularVelocity","operator":null,"title":"angularVelocity","type":"command","url":"https://community.bistudio.com/wiki/angularVelocity","revid":377246,"updated":"2026-01-02T05:26:22Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets the angular velocity of the object in world space as a 3D vector. The units are in Rad/s (radians per second) and rotations are clockwise.","syntaxes":[{"syntax":"angularVelocity obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"angular velocity of the object in world space ([0,0,0] if angular velocity is not supported by the object)","text":"Vector3D - angular velocity of the object in world space ([0,0,0] if angular velocity is not supported by the object)"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nangularVelocity myHeli; // [0.01, 0.03, 0.95]\n```","code":["angularVelocity myHeli; // [0.01, 0.03, 0.95]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocity","setAngularVelocity","angularVelocityModelSpace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"angularVelocityModelSpace","operator":null,"title":"angularVelocityModelSpace","type":"command","url":"https://community.bistudio.com/wiki/angularVelocityModelSpace","revid":377253,"updated":"2026-01-02T06:32:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets the angular velocity of the object in model space as a 3D vector. The units are in Rad/s (radians per second) and rotations are clockwise.","syntaxes":[{"syntax":"angularVelocityModelSpace obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"angular velocity of the object in model space ([0,0,0] if angular velocity is not supported by the object)","text":"Vector3D - angular velocity of the object in model space ([0,0,0] if angular velocity is not supported by the object)"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str angularVelocityModelSpace myHeli; // [0.01, 0.03, 0.95]\n```","code":["hint str angularVelocityModelSpace myHeli; // [0.01, 0.03, 0.95]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocityModelSpace","setAngularVelocityModelSpace","angularVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"animate","operator":null,"title":"animate","type":"command","url":"https://community.bistudio.com/wiki/animate","revid":379104,"updated":"2026-10-03T12:13:48Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Activates given object animation. Animation is defined in CfgModels animations class. Class names listed in CfgVehicles AnimationSources bound to \"Proxy\" controller can also be animated with animate command (see Arma 3: createVehicle/vehicles).\n\n> [!NOTE]\n> Since Arma 3 v2.24 parachutes are supported. The phases for a parachute animation are: 0...1 - pulling of the parachute from the bag, 1...2 - opening of the canopy, 2...3 packing of the canopy. The animation name is \"\". You can only skip forward the animation of the parachute. For example: \n>\n> ```sqf\n> _para animate [\"\", 1]; // skips parachute animation forward to the canopy opening\n> ```\n>\n>  Giving negative phase would delay the whole parachute opening animation until the phase rolls up to 0. See also animationPhase\n\n> [!NOTE]\n> **Arma 3:** - It is recommended that animateSource command is used instead of animate whenever is possible, as it is more efficient and optimised for multiplayer\n> - Since Arma 3 v1.58 animation names can be obtained with animationNames\n\n> [!WARNING]\n> Mixing animateSource command with animate command to animate the same part may produce some undefined behaviour.","syntaxes":[{"syntax":"object animate [animationName, phase, speed]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"animationName","type":"String","optional":false,"default":null,"description":"name of the animation. This is the class-name of the animation defined in the config","types":["String"],"since":null,"text":"animationName: String - name of the animation. This is the class-name of the animation defined in the config"},{"name":"phase","type":"Number","optional":false,"default":null,"description":"range 0 (start point of the animation) to 1 (end point of the animation). The speed, in which the animation is processed, is defined in the addon's config.cpp and cannot be changed during running missions","types":["Number"],"since":null,"text":"phase: Number - range 0 (start point of the animation) to 1 (end point of the animation). The speed, in which the animation is processed, is defined in the addon's config.cpp and cannot be changed during running missions"},{"name":"speed","type":"Boolean or (since Arma 3 v1.66) Number","optional":true,"default":"false","description":"when true animation is instant; Number > 0 is treated as config speed value multiplier","types":["Boolean","Number"],"since":null,"text":"speed: Boolean or (since Arma 3 v1.66) Number - (Optional, default false) when true animation is instant; Number > 0 is treated as config speed value multiplier"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[animationName, phase, speed]","types":["Array"]}}],"examples":[{"text":"```sqf\n_building animate [\"maindoor\", 1];\n```","code":["_building animate [\"maindoor\", 1];"]},{"text":"```sqf\n_building animate [\"Door_1_rot\", 1, true];\n```","code":["_building animate [\"Door_1_rot\", 1, true];"]},{"text":"Create Offroad and add flashing police light bar:\n\n```sqf\noffroad = \"C_Offroad_01_F\" createVehicle (player getRelPos [5, 0]);\noffroad animate [\"HidePolice\", 0];\noffroad animate [\"BeaconsStart\", 1];\n```","code":["offroad = \"C_Offroad_01_F\" createVehicle (player getRelPos [5, 0]);\noffroad animate [\"HidePolice\", 0];\noffroad animate [\"BeaconsStart\", 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationPhase","setFaceAnimation","animateSource","animationSourcePhase","animateDoor","doorPhase","animationNames"],"notes":[{"user":"Mikero","date":"2007-08-23T22:50:00Z","text":"Animations can be used on existing game models such as houses that have doors eg. The general syntax is\n\n```sqf\nhouse animate [\"dvere1\", 1]\n```\n\nto 'open' the door and \n\n```sqf\nhouse animate [\"dvere1\", 0]\n```\n\n to 'close' it. Whether used on Oem addons, or official ones, an internal working knowledge (via config.cpp) of the model's animated name(s) is required.\n\n'open' and 'close' are visual perceptions of the state of the model, and are a design decision of the p3d. Open does not, necessarily mean, 1, and close does not mean 0.\n\n'0' and '1' are better seen as FULLY_OFF and FULLY_ON\n\nIf a door is initially closed in the model, FULLY_ON, will open it. If it is initialy OPEN visually, in the model, FULLY_ON will close it.\n\n (in config cpp) does not alter open and close meanings, all it does is set the model to the 'on' (rather than 'off') state to begin with. Whether on means open or close visually is a p3d design decision."},{"user":"Tyger","date":"2008-12-06T08:23:00Z","text":"Also, to animate the object called \"Bar Gate\" in ArmA, use the following: \n\n```sqf\nmyGate animate [\"Bargate\",1]\n```\n\n to close it, and \n\n```sqf\nmyGate animate [\"Bargate\", 0]\n```\n\n to open it."},{"user":"RageBone","date":"2016-02-16T21:33:00Z","text":"\"Bargate\" was exchanged with \"Door_1_rot\" at one point:\n\n```sqf\nobject animate [\"Bargate\", 0]; // doesn't work\n```\n\n```sqf\nobject animate [\"Door_1_rot\", 0]; // works\n```"},{"user":"Killzone_Kid","date":"2016-03-14T00:34:00Z","text":"To animate bargate use animateSource:\n\n```sqf\nbargate animateSource [\"Door_1_source\", 1];\n```"},{"user":"SteveStevenson","date":"2017-11-25T20:55:00Z","text":"For pop-up targets, you can keep the target down (until you tell it to pop up) with:\n\n```sqf\ntarget1 animate [\"terc\", 1];\n```\n\nWhen you're ready for the target to pop up, you can use:\n\n```sqf\ntarget1 animate [\"terc\", 0];\n```\n\nWith this setting, the target will return to its usual behavior of going down when hit and automatically popping back up again. To make the target stay down after being hit, add the following line:\n\n```sqf\ntarget1 addEventHandler [\"HitPart\", { target1 animate [\"terc\", 1]; }];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"animateBay","operator":null,"title":"animateBay","type":"command","url":"https://community.bistudio.com/wiki/animateBay","revid":347988,"updated":"2023-11-08T10:17:14Z","groups":["Animations","Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Forces animation of bay to given state, -1 for reset to engine handling, can cause weapon inoperative, because weapon is released when bay state == 1.\n\n> [!NOTE]\n> While there is no getter to read the animation phase of the given bay, the animationPhase command can be used with the individual bay door name from animationNames as a workaround (See #Example 3).","syntaxes":[{"syntax":"vehicle animateBay [bay, animphase, instant]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"bay","type":"Number","optional":false,"default":null,"description":"bay index (index starts from 1 and different from pylon index)","types":["Number"],"since":null,"text":"bay: Number - bay index (index starts from 1 and different from pylon index)"},{"name":"animphase","type":"Number","optional":false,"default":null,"description":"animation phase in range 0..1","types":["Number"],"since":null,"text":"animphase: Number - animation phase in range 0..1"},{"name":"instant","type":"Boolean","optional":true,"default":"false","description":"animate immediately","types":["Boolean"],"since":null,"text":"instant: Boolean - (Optional, default false) animate immediately"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[bay, animphase, instant]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player animateBay [1, 0.5];\n```","code":["vehicle player animateBay [1, 0.5];"]},{"text":"```sqf\nvehicle player animateBay [1, 1, true];\n```","code":["vehicle player animateBay [1, 1, true];"]},{"text":"Getter example, here for the UCAV Sentinel:\n\n```sqf\nucav animateBay [1, 1];\n// can be checked with\nucav animationPhase \"weapons_bay_l_1\";\n// or\nucav animationPhase \"weapons_bay_l_2\";\n```","code":["ucav animateBay [1, 1];\n// can be checked with\nucav animationPhase \"weapons_bay_l_1\";\n// or\nucav animationPhase \"weapons_bay_l_2\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","getPylonMagazines","setAmmoOnPylon","ammoOnPylon","animatePylon","setPylonsPriority","setPylonLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"animateDoor","operator":null,"title":"animateDoor","type":"command","url":"https://community.bistudio.com/wiki/animateDoor","revid":347589,"updated":"2023-09-28T20:03:54Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Animates a door on a vehicle. Animation is defined in config file in CfgVehicles -> AnimationSources. Wanted animation phase is set with phase param. This command works only on animation sources with \"door\" controller. Door_L in the example below can be animated with animateDoor but not CargoRamp_Open: `heli animateDoor [\"Door_L\", 1];`\n\n> [!IMPORTANT]\n> animateDoor `phase` param will be rounded: anything >0.5 will be rounded to 1 and <=0.5 will be rounded to 0. Therefore it is not possible to open a door half way with this command\n\n```cpp\nclass AnimationSources\n{\n    class CargoRamp_Open\n    {\n        source = \"user\";\n        animPeriod = 5;\n        initPhase = 0;\n    };\n    class Door_L\n    {\n        source = \"door\";\n        animPeriod = 1.6;\n    };\n};\n```\n\nTo animate doors or other sources that have \"user\" controller, use animate command, or even better, animateSource (recommended). Sources with \"hit\" controller can be animated with setHitPointDamage command applied to the name contained in hitpoint property. For availability of animation sources and their controller types see: Arma 3: createVehicle/vehicles","syntaxes":[{"syntax":"object animateDoor [doorname, phase, instant]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"doorname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"doorname: String"},{"name":"phase","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"phase: Number"},{"name":"instant","type":"Boolean","optional":true,"default":"false","description":"when true and phase is either 0 or 1, door will change phase instantaneously","types":["Boolean"],"since":null,"text":"instant: Boolean - (Optional, default false) when true and phase is either 0 or 1, door will change phase instantaneously"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[doorname, phase, instant]","types":["Array"]}}],"examples":[{"text":"```sqf\nTaru animateDoor [\"Door_1_source\", 1];\n```","code":["Taru animateDoor [\"Door_1_source\", 1];"]},{"text":"Open left front door on Ifrit instantly:\n\n```sqf\nIfrit animateDoor [\"Door_LF\", 1, true];\n```","code":["Ifrit animateDoor [\"Door_LF\", 1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doorPhase","setFaceAnimation","animate","animationPhase","animateSource","animationSourcePhase","animationNames"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"animatePylon","operator":null,"title":"animatePylon","type":"command","url":"https://community.bistudio.com/wiki/animatePylon","revid":336888,"updated":"2023-01-04T16:43:53Z","groups":["Animations","Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Force animation of pylon to given state, -1 for reset to engine handling, can cause weapon inoperative, because weapon is released  when pylon state == 1.","syntaxes":[{"syntax":"vehicle animatePylon [pylon, animphase, instant]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"pylon","type":"Number or Arma 3 v1.94 String","optional":false,"default":null,"description":"pylon index (index starts from 1) or pylon name (see getCompatiblePylonMagazines#Example 3)","types":["Number","String"],"since":null,"text":"pylon: Number or Arma 3 v1.94 String - pylon index (index starts from 1) or pylon name (see getCompatiblePylonMagazines#Example 3)"},{"name":"animphase","type":"Number","optional":false,"default":null,"description":"animation phase in range 0..1","types":["Number"],"since":null,"text":"animphase: Number - animation phase in range 0..1"},{"name":"instant","type":"Boolean","optional":true,"default":null,"description":"animate immediately","types":["Boolean"],"since":null,"text":"instant: Boolean - (Optional) animate immediately"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[pylon, animphase, instant]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player animatePylon [1, 0.5];\n```","code":["vehicle player animatePylon [1, 0.5];"]},{"text":"```sqf\nvehicle player animatePylon [\"pylon1\", 0.5];\n```","code":["vehicle player animatePylon [\"pylon1\", 0.5];"]},{"text":"```sqf\nvehicle player animatePylon [\"pylon1\", 1, true];\n```","code":["vehicle player animatePylon [\"pylon1\", 1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","getPylonMagazines","setAmmoOnPylon","animateBay","setPylonsPriority","setPylonLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"animateSource","operator":null,"title":"animateSource","type":"command","url":"https://community.bistudio.com/wiki/animateSource","revid":353025,"updated":"2024-03-12T11:30:02Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Process an animation of the object. If animate uses class name from CfgModels *Animations*, animateSource uses name defined by the *source* property. AnimationSources can animate multiple animate Animations. AnimationSource is defined in CfgVehicles' AnimationSources (see Arma 3: createVehicle/vehicles).\n\n> [!NOTE]\n> **Arma 3:** It is recommended that animateSource command is used instead of animate whenever is possible, as it is more efficient and optimized for MP\n\n> [!WARNING]\n> Mixing animateSource command with animate command to animate the same part may produce some undefined behaviour.","syntaxes":[{"syntax":"object animateSource [source, phase, speed]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"source","type":"String","optional":false,"default":null,"description":"common source","types":["String"],"since":null,"text":"source: String - common source"},{"name":"phase","type":"Number","optional":false,"default":null,"description":"wanted animation phase","types":["Number"],"since":null,"text":"phase: Number - wanted animation phase"},{"name":"speed","type":"Boolean or Number","optional":true,"default":"false","description":"Boolean - when set to true, animation is instant\n- Arma 3 v1.66 Number > 0 is treated as config speed value multiplier. Since Arma 3 v2.10 values <= 0 will instantly reset animation to initPhase.","types":["Boolean","Number"],"since":null,"text":"speed: Boolean or Number - (Optional, default false)\n- Boolean - when set to true, animation is instant\n- Arma 3 v1.66 Number > 0 is treated as config speed value multiplier. Since Arma 3 v2.10 values <= 0 will instantly reset animation to initPhase."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[source, phase, speed]","types":["Array"]}}],"examples":[{"text":"```sqf\nhouse animateSource [\"Door_1_source\", 1, true];\n```","code":["house animateSource [\"Door_1_source\", 1, true];"]},{"text":"Create UGV and manipulate its turret (Not possible to do with animate command. See Arma 3: createVehicle/vehicles for reference)\n\n```sqf\nugv = \"B_UGV_01_F\" createVehicle (player getRelPos [5, 0]);\nugv addAction [\"Show Turret\",\n{\n    ugv animateSource [\"Turret\", 0];\n    ugv animateSource [\"MainTurret\", rad 0, true];\n    ugv animateSource [\"MainGun\", rad 0, true];\n}];\nugv addAction [\"Hide Turret\",    { ugv animateSource [\"Turret\", 1] }];\nugv addAction [\"Turret Left\",    { ugv animateSource [\"MainTurret\",     rad 90] }];\nugv addAction [\"Turret Right\",    { ugv animateSource [\"MainTurret\",    -rad 90] }];\nugv addAction [\"Turret Up\",        { ugv animateSource [\"MainGun\",         rad 30] }];\nugv addAction [\"Turret Down\",    { ugv animateSource [\"MainGun\",        -rad 20] }];\n```","code":["ugv = \"B_UGV_01_F\" createVehicle (player getRelPos [5, 0]);\nugv addAction [\"Show Turret\",\n{\n\tugv animateSource [\"Turret\", 0];\n\tugv animateSource [\"MainTurret\", rad 0, true];\n\tugv animateSource [\"MainGun\", rad 0, true];\n}];\nugv addAction [\"Hide Turret\",\t{ ugv animateSource [\"Turret\", 1] }];\nugv addAction [\"Turret Left\",\t{ ugv animateSource [\"MainTurret\",\t rad 90] }];\nugv addAction [\"Turret Right\",\t{ ugv animateSource [\"MainTurret\",\t-rad 90] }];\nugv addAction [\"Turret Up\",\t\t{ ugv animateSource [\"MainGun\",\t\t rad 30] }];\nugv addAction [\"Turret Down\",\t{ ugv animateSource [\"MainGun\",\t\t-rad 20] }];"]},{"text":"```sqf\nbarGate animateSource [\"Door_1_sound_source\", 1]; // Open\nbarGate animateSource [\"Door_1_sound_source\", 0]; // Close\n```","code":["barGate animateSource [\"Door_1_sound_source\", 1]; // Open\nbarGate animateSource [\"Door_1_sound_source\", 0]; // Close"]},{"text":"Open/close Bar Gate automatically:\n\n```sqf\n// Bar Gate init\nif (isServer) then\n{    \n    private _gateTrigger = createTrigger [\"EmptyDetector\", getPosWorld this, false];\n    _gateTrigger setVariable [\"BarGateObj\", this];\n    _gateTrigger setTriggerActivation [\"ANYPLAYER\", \"PRESENT\", true];\n    _gateTrigger setTriggerArea [5, 25, getDir this, true];\n    _gateTrigger setTriggerStatements \n    [\n        \"this\",\n        \"thisTrigger getVariable 'BarGateObj' animateSource ['Door_1_sound_source', 1]\",\n        \"thisTrigger getVariable 'BarGateObj' animateSource ['Door_1_sound_source', 0]\"\n    ];\n};\n```","code":["// Bar Gate init\nif (isServer) then\n{\t\n\tprivate _gateTrigger = createTrigger [\"EmptyDetector\", getPosWorld this, false];\n\t_gateTrigger setVariable [\"BarGateObj\", this];\n\t_gateTrigger setTriggerActivation [\"ANYPLAYER\", \"PRESENT\", true];\n\t_gateTrigger setTriggerArea [5, 25, getDir this, true];\n\t_gateTrigger setTriggerStatements \n\t[\n\t\t\"this\",\n\t\t\"thisTrigger getVariable 'BarGateObj' animateSource ['Door_1_sound_source', 1]\",\n\t\t\"thisTrigger getVariable 'BarGateObj' animateSource ['Door_1_sound_source', 0]\"\n\t];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationSourcePhase","setFaceAnimation","animate","animationPhase","animateDoor","doorPhase","animationNames"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"animationNames","operator":null,"title":"animationNames","type":"command","url":"https://community.bistudio.com/wiki/animationNames","revid":352617,"updated":"2024-02-16T20:51:49Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Array of Strings where elements are the names of model animations, which should theoretically be available for use with animate command. However in practice this depends on whether animation is also made available for use in scripts via config.","syntaxes":[{"syntax":"animationNames object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_names = animationNames static_AT;\n```\n\n Returns: [\"MainTurret\", \"MainGun\", \"MainTurret_destructX\", \"MainTurret_destructY\", \"MainTurret_destructZ\", \"MainGun_destructX\", \"MainGun_destructY\", \"MainGun_destructZ\", \"magazine_destruct\", \"ammo_belt_destruct\", \"bolt_destruct\", \"charging_handle_destruct\", \"damagehideVez_destruct\", \"damagehideHlaven_destruct\", \"damagehideRecoil_destruct\", \"Turret_shake\", \"Turret_shake_aside\", \"Magazine_hide\", \"Ammo_belt_hide\", \"muzzleFlash\", \"AddAutonomous_unhide\", \"bullet001_reload_hide\", \"bullet002_reload_hide\", \"bullet003_reload_hide\", \"bullet004_reload_hide\", \"bullet005_reload_hide\", \"bullet006_reload_hide\", \"bullet007_reload_hide\", \"bullet008_reload_hide\"]","code":["_names = animationNames static_AT;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animate","animationPhase","animateDoor","doorPhase","animateSource","animationSourcePhase","namedProperties","allLODs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"animationPhase","operator":null,"title":"animationPhase","type":"command","url":"https://community.bistudio.com/wiki/animationPhase","revid":379102,"updated":"2026-10-03T12:06:54Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the phase of the given animation on the given object. Animation can be scripted (animate, animateSource, animateDoor) or engine driven. Animation names for an object could be found out with animationNames command. When animation is rotation, like with \"MainTurret\" for example, the output is in radians, to convert to degrees use deg command.\n\n> [!NOTE]\n> Since Arma 3 v2.24 parachutes are supported. The phases for a parachute animation are: 0...1 - pulling of the parachute from the bag, 1...2 - opening of the canopy, 2...3 packing of the canopy. The animation name is \"\". \n>\n> ```sqf\n> _para animationPhase \"\"; // current animation phase\n> ```\n>\n>  See also animate","syntaxes":[{"syntax":"object animationPhase animationName","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"animationName","type":"String","optional":false,"default":null,"description":"name of the animation. This is the class-name of the animation defined in the addon's config.cpp","types":["String"],"since":null,"text":"animationName: String - name of the animation. This is the class-name of the animation defined in the addon's config.cpp"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":"where 0 is the start point of the animation and 0 is the end point","text":"Number in range 0..1 - where 0 is the start point of the animation and 0 is the end point"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"animationName","types":["String"]}}],"examples":[{"text":"```sqf\n_building animate [\"maindoor\",1];\nsleep 1;\n_p = _building animationPhase \"maindoor\";// Returns 1, if the animation speed is two seconds\n```","code":["_building animate [\"maindoor\",1];\nsleep 1;\n_p = _building animationPhase \"maindoor\";// Returns 1, if the animation speed is two seconds"]},{"text":"```sqf\n_flagPole animationPhase \"flag\";\n```","code":["_flagPole animationPhase \"flag\";"]},{"text":"```sqf\n_tank animationPhase \"MainTurret\";\n```","code":["_tank animationPhase \"MainTurret\";"]}],"multiplayer":"In Operation Flashpoint, on dedicated servers, *animationPhase* will always return 0, no matter what the actual phase is.","problems":null,"aliases":[],"see_also":["animate","moveTime","setFaceAnimation","animateDoor","doorPhase","animateSource","animationSourcePhase","animationNames"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"animationSourcePhase","operator":null,"title":"animationSourcePhase","type":"command","url":"https://community.bistudio.com/wiki/animationSourcePhase","revid":336879,"updated":"2023-01-04T16:43:50Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current animation phase of given source. Similar to animationPhase or doorPhase but designed to complement animateSource. This command could be used to obtain relative turret direction and gun elevation on a vehicle (see #Example 2).","syntaxes":[{"syntax":"object animationSourcePhase source","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"source","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"source: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"source","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _phase = house animationSourcePhase \"Door_1_source\";\n```","code":["private _phase = house animationSourcePhase \"Door_1_source\";"]},{"text":"```sqf\nprivate _mainturretDirection =    deg (_marshall animationSourcePhase \"mainturret\"); // relative to Marshall direction\nprivate _maingunElevation =        deg (_marshall animationSourcePhase \"maingun\");\nprivate _obsturretDirection =    deg (_marshall animationSourcePhase \"obsturret\"); // relative to main turret direction\nprivate _obsgunElevation =        deg (_marshall animationSourcePhase \"obsgun\");\n```","code":["private _mainturretDirection =\tdeg (_marshall animationSourcePhase \"mainturret\"); // relative to Marshall direction\nprivate _maingunElevation =\t\tdeg (_marshall animationSourcePhase \"maingun\");\nprivate _obsturretDirection =\tdeg (_marshall animationSourcePhase \"obsturret\"); // relative to main turret direction\nprivate _obsgunElevation =\t\tdeg (_marshall animationSourcePhase \"obsgun\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animateSource","animationNames","animate","animationPhase","animateDoor","doorPhase"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"animationState","operator":null,"title":"animationState","type":"command","url":"https://community.bistudio.com/wiki/animationState","revid":378280,"updated":"2026-03-31T10:06:31Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the name of a unit's current primary animation. Seems to be forced to lower case in Arma 3.\n\n> [!NOTE]\n> Up until Arma 3 v2.20 this command only worked for a man unit, and other units such as animals couldn't use this command. As of Arma 3 v2.22 animals are supported as well.","syntaxes":[{"syntax":"animationState unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_state = animationState player;\n```","code":["_state = animationState player;"]}],"multiplayer":"When executed on a client, this command only returns accurate results when the target unit is within sight of the client. When executed on a dedicated server, the returned value is accurate.","problems":null,"aliases":[],"see_also":["gestureState","switchMove","playMove","pose","BIS_fnc_ambientAnimGetParams","getUnitMovesInfo"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"apertureParams","operator":null,"title":"apertureParams","type":"command","url":"https://community.bistudio.com/wiki/apertureParams","revid":377662,"updated":"2026-01-02T09:02:15Z","groups":["Camera Control","Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns current aperture parameters.","syntaxes":[{"syntax":"apertureParams","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [aperture, isForced, estimatedAperture, estimatedLuminance, minCustom, stdCustom, maxCustom, customLuminance, isCustomForced, blinding]","types":["Array"],"description":"aperture: Number - current aperture - isForced: Boolean - whether aperture was forced by setAperture - estimatedAperture: Number - engine-estimated scene aperture - estimatedLuminance: Number - engine-estimated luminance - minCustom: Number - minimal custom aperture, see setApertureNew - stdCustom: Number - standard custom aperture, see setApertureNew - maxCustom: Number - maximal custom aperture, see setApertureNew - customLuminance: Number - custom luminance, see setApertureNew - isCustomForced: Boolean - whether custom values were forced - blinding: Number - blinding intensity of the light","text":"Array with [aperture, isForced, estimatedAperture, estimatedLuminance, minCustom, stdCustom, maxCustom, customLuminance, isCustomForced, blinding]\n- aperture: Number - current aperture\n- isForced: Boolean - whether aperture was forced by setAperture\n- estimatedAperture: Number - engine-estimated scene aperture\n- estimatedLuminance: Number - engine-estimated luminance\n- minCustom: Number - minimal custom aperture, see setApertureNew\n- stdCustom: Number - standard custom aperture, see setApertureNew\n- maxCustom: Number - maximal custom aperture, see setApertureNew\n- customLuminance: Number - custom luminance, see setApertureNew\n- isCustomForced: Boolean - whether custom values were forced\n- blinding: Number - blinding intensity of the light"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _apertureParams = apertureParams;\n```","code":["private _apertureParams = apertureParams;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setApertureNew","setAperture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Lights","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"append","operator":null,"title":"append","type":"command","url":"https://community.bistudio.com/wiki/append","revid":377193,"updated":"2026-01-01T10:54:49Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Appends array2 to the back of array1 modifying array1. See insert for an \"appendUnique\" equivalent.\n\n> [!NOTE]\n> append does not return array, it modifies the existing array. If you need to return a copy, use \"+\": \n>\n> ```sqf\n> array3 = array1 + array2;\n> ```","syntaxes":[{"syntax":"array1 append array2","since":null,"effect":null,"exec":null,"params":[{"name":"array1","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array1: Array of Anything"},{"name":"array2","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array2: Array of Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array1","types":["Array","Anything"]},"right":{"text":"array2","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3];\n_arr append [4,5,6];\nhint str _arr; // [1,2,3,4,5,6]\n```","code":["_arr = [1,2,3];\n_arr append [4,5,6];\nhint str _arr; // [1,2,3,4,5,6]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","pushBack","pushBackUnique","insert","+","apply","select","resize","reverse","count","deleteAt","deleteRange"],"notes":[{"user":"Heeeere's Johnny!","date":"2015-03-09T00:41:00Z","text":"```sqf\n_array1 append _array2;\n```\n\nis roughly 1.2× faster (depending on array size) than\n\n```sqf\n_array1 = _array1 + _array2\n```\n\n(Averaged over 10.000 iterations with two identical arrays containing the numbers 0 through 9)\n\nThe larger the arrays to append, the faster append is as it does not create a new array, which happens with array addition."},{"user":"Killzone_Kid","date":"2015-05-21T10:27:00Z","text":"Array \"unshift\" implementation using append, a faster alternative to BIS_fnc_arrayUnShift:\n\n```sqf\nKK_fnc_unshift = {\n    private [\"_arr\", \"_tmp\"];\n    _arr = _this select 0;\n    _tmp = [_this select 1];\n    _tmp append _arr;\n    _arr resize 0;\n    _arr append _tmp;\n    _arr\n};\n\n// Example\narr = [1,2,3];\n[arr, 0] call KK_fnc_unshift; // both arr and return of function are [0,1,2,3]\n```"},{"user":"Killzone_Kid","date":"2015-05-21T15:21:00Z","text":"Array \"insert\" implementation using append, much faster alternative to BIS_fnc_arrayInsert:\n\n```sqf\nKK_fnc_insert = {\n    private [\"_arr\", \"_i\", \"_res\"];\n    _arr = _this select 0;\n    _i = _this select 2;\n    _res = [];\n    _res append (_arr select [0, _i]);\n    _res append (_this select 1);\n    _res append (_arr select [_i, count _arr - _i]);\n    _res;\n};\n\n// Example\narr = [1,2,3,4];\n[arr, [\"a\",\"b\"], 2] call KK_fnc_insert; // [1,2,\"a\",\"b\",3,4]\n```"},{"user":"Killzone_Kid","date":"2015-05-21T15:52:00Z","text":"A faster alternative to BIS_fnc_arrayPushStack using append:\n\n```sqf\nKK_fnc_pushStack = {\n    _this select 0 append (_this select 1);\n    _this select 0\n};\n\n// Example\narr = [1,2,3];\n[arr, [4,5,6]] call KK_fnc_pushStack; // both arr and function return are [1,2,3,4,5,6]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.40","Scripting Commands"]},{"name":"apply","operator":null,"title":"apply","type":"command","url":"https://community.bistudio.com/wiki/apply","revid":377840,"updated":"2026-01-03T04:33:29Z","groups":["Arrays","HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Applies the given code to each element of the given data structure and collects the results in an array.","syntaxes":[{"syntax":"array apply code","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"code","type":"Code","optional":false,"default":null,"description":"code to be executed on each element of the array. The current element value is stored in the magic variable _x.","types":["Code"],"since":null,"text":"code: Code - code to be executed on each element of the array. The current element value is stored in the magic variable _x."}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"resulting array","text":"Array of Anything - resulting array"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"code","types":["Code"]}},{"syntax":"hashmap apply code","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashmap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashmap: HashMap"},{"name":"code","type":"Code","optional":false,"default":null,"description":"code to be executed on each key-value pair of the hashmap. The current key is stored in the magic variable _x, the corresponding value is stored in _y.","types":["Code"],"since":null,"text":"code: Code - code to be executed on each key-value pair of the hashmap. The current key is stored in the magic variable _x, the corresponding value is stored in _y."}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"resulting array","text":"Array of Anything - resulting array"},"form":"binary","operator":null,"left":{"text":"hashmap","types":["HashMap"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nprivate _arr = [1,2,3,4,5,6,7,8,9,0] apply { [1,0] select (_x % 2 == 0) }; // [1,0,1,0,1,0,1,0,1,0]\n```","code":["private _arr = [1,2,3,4,5,6,7,8,9,0] apply { [1,0] select (_x % 2 == 0) }; // [1,0,1,0,1,0,1,0,1,0]"]},{"text":"```sqf\nprivate _arr = [1,2,3,4,5,6,7,8,9,0] apply { _x ^ _x }; // [1,4,27,256,3125,46656,823543,16777216,387420480,1]\n```","code":["private _arr = [1,2,3,4,5,6,7,8,9,0] apply { _x ^ _x }; // [1,4,27,256,3125,46656,823543,16777216,387420480,1]"]},{"text":"```sqf\nprivate _arr1 = [];\n_arr1 resize 20;\n_arr2 = _arr1 apply { 0 }; // [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]\n```","code":["private _arr1 = [];\n_arr1 resize 20;\n_arr2 = _arr1 apply { 0 }; // [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]"]},{"text":"```sqf\n[0,1,2,3,4] apply { str _x }; // [\"0\",\"1\",\"2\",\"3\",\"4\"]\n```","code":["[0,1,2,3,4] apply { str _x }; // [\"0\",\"1\",\"2\",\"3\",\"4\"]"]},{"text":"```sqf\nprivate _hashmap = createHashMapFromArray [[\"Key 1\", \"Value 1\"], [\"Key 2\", \"Value 2\"]];\nprivate _array = _hashmap apply { _y + \" Test\" }; // [\"Value 2 Test\",\"Value 1 Test\"]\n```","code":["private _hashmap = createHashMapFromArray [[\"Key 1\", \"Value 1\"], [\"Key 2\", \"Value 2\"]];\nprivate _array = _hashmap apply { _y + \" Test\" }; // [\"Value 2 Test\",\"Value 1 Test\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","resize","pushBack","pushBackUnique","select","reverse","count","find","in","forEach","deleteAt","deleteRange","append","sort","arrayIntersect"],"notes":[{"user":"Fusselwurm","date":"2016-02-18T11:03:00Z","text":"(to anyone else wondering, I took a minute to get it) this is [Array.map()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map) in JavaScript"},{"user":"Lou Montana","date":"2018-02-11T23:02:00Z","text":"if performance really is an issue, apply seems to be (very) slightly faster than forEach (by more or less one percent, 0.7-1.5% in my tests to be precise)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"armoryPoints","operator":null,"title":"armoryPoints","type":"command","url":"https://community.bistudio.com/wiki/armoryPoints","revid":310774,"updated":"2022-05-07T20:21:44Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns, stored in [USERNAME].ArmaXProfile, value of *armoryPoints* entry. If the entry doesn't exist, it returns 0.","syntaxes":[{"syntax":"armoryPoints","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_points = armoryPoints;\n```","code":["_points = armoryPoints;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setArmoryPoints"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"arrayIntersect","operator":null,"title":"arrayIntersect","type":"command","url":"https://community.bistudio.com/wiki/arrayIntersect","revid":377192,"updated":"2026-01-01T10:54:34Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Intersects two arrays returning an array of unique common elements, avoiding nil values.\nUsing the same array as both parameters will return unique elements of that array.\nIntersects only the first dimension of said arrays.\n\n> [!NOTE]\n> From Arma 3 v 2.14 the order of the intersected elements would follow 'array1' order","syntaxes":[{"syntax":"array1 arrayIntersect array2","since":null,"effect":null,"exec":null,"params":[{"name":"array1","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array1: Array of Anything"},{"name":"array2","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array2: Array of Anything"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":null,"text":"Array of Anything"},"form":"binary","operator":null,"left":{"text":"array1","types":["Array","Anything"]},"right":{"text":"array2","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_arr1 = [1,2,3,4,5,2,3,4];\n_arr2 = [4,5,6,1,2,3,5,6];\nhint str (_arr1 arrayIntersect _arr2); // [4,5,1,2,3]\n```","code":["_arr1 = [1,2,3,4,5,2,3,4];\n_arr2 = [4,5,6,1,2,3,5,6];\nhint str (_arr1 arrayIntersect _arr2); // [4,5,1,2,3]"]},{"text":"```sqf\n_arr = [1,2,3,1,2,3,1,2,3,4,5];\nhint str (_arr arrayIntersect _arr); // [1,2,3,4,5]\n```","code":["_arr = [1,2,3,1,2,3,1,2,3,4,5];\nhint str (_arr arrayIntersect _arr); // [1,2,3,4,5]"]},{"text":"Remove nils:\n\n```sqf\nhint str ([1,2,nil,3] arrayIntersect [1,2,nil,3]); // [1,2,3]\n```","code":["hint str ([1,2,nil,3] arrayIntersect [1,2,nil,3]); // [1,2,3]"]},{"text":"Also works with array elements which are equal:\n\n```sqf\nhint str ([[1],[2],[3]] arrayIntersect [[2],[3],[4]]); // [[2],[3]]\n```","code":["hint str ([[1],[2],[3]] arrayIntersect [[2],[3],[4]]); // [[2],[3]]"]},{"text":"This command is case-sensitive:\n\n```sqf\n[\"cAse\"] arrayIntersect [\"cAse\"]; // [\"cAse\"]\n[\"cAse\"] arrayIntersect [\"casE\"]; // []\n```","code":["[\"cAse\"] arrayIntersect [\"cAse\"]; // [\"cAse\"]\n[\"cAse\"] arrayIntersect [\"casE\"]; // []"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["append","set","pushBack","pushBackUnique","apply","select","resize","reverse","count","find","in","forEach","deleteAt","deleteRange","sort","param","params","toArray","toString","splitString","joinString","BIS_fnc_arrayPushStack","BIS_fnc_arrayPush"],"notes":[{"user":"Hypoxic125","date":"2024-05-26T16:50:02Z","text":"Selectively filter out elements from _arrayA based on _arrayB.\n- Designed to remove the first occurrence of each element found in _arrayB from _arrayA.\n- Useful in removing elements where duplicates may exist.\n\n```sqf\nprivate _arrayA = [1, 2, 3, 2, 4, 5, 4];\nprivate _arrayB = [2, 2, 4];\n\n{\n    private _index = _arrayA find _x;\n    if (_index != -1) then\n    {\n        _arrayA deleteAt _index;\n    };\n} forEach _arrayB;\n\n_arrayA; // is now [1, 3, 5, 4]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"asin","operator":null,"title":"asin","type":"command","url":"https://community.bistudio.com/wiki/asin","revid":376955,"updated":"2026-01-01T05:40:47Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Arcsine of a number, result in Degrees.","syntaxes":[{"syntax":"asin x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number in range -1..+1","optional":false,"default":null,"description":"any other value returns NaN","types":["Number"],"since":null,"text":"x: Number in range -1..+1 - any other value returns NaN"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_degrees = asin 0.5; // Returns 30\n```","code":["_degrees = asin 0.5; // Returns 30"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ASLToAGL","operator":null,"title":"ASLToAGL","type":"command","url":"https://community.bistudio.com/wiki/ASLToAGL","revid":377463,"updated":"2026-01-02T06:47:34Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position from PositionASL to PositionAGL","syntaxes":[{"syntax":"ASLToAGL posASL","since":null,"effect":null,"exec":null,"params":[{"name":"posASL","type":"PositionASL","optional":false,"default":null,"description":"position to convert","types":["PositionASL"],"since":null,"text":"posASL: PositionASL - position to convert"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":null,"text":"PositionAGL"},"form":"unary","operator":null,"left":null,"right":{"text":"posASL","types":["PositionASL"]}}],"examples":[{"text":"```sqf\n_playerPosAGL = ASLToAGL getPosASL player;\n```","code":["_playerPosAGL = ASLToAGL getPosASL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["AGLToASL","ASLToATL","ATLToASL","getPos","getPosATL","getPosASL","setUnitFreefallHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"ASLToATL","operator":null,"title":"ASLToATL","type":"command","url":"https://community.bistudio.com/wiki/ASLToATL","revid":377532,"updated":"2026-01-02T06:53:16Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts a position from PositionASL to PositionATL","syntaxes":[{"syntax":"ASLToATL pos","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"PositionASL","optional":false,"default":null,"description":"position to convert","types":["PositionASL"],"since":null,"text":"pos: PositionASL - position to convert"}],"returns":{"type":"PositionATL","types":["PositionATL"],"description":null,"text":"PositionATL"},"form":"unary","operator":null,"left":null,"right":{"text":"pos","types":["PositionASL"]}}],"examples":[{"text":"```sqf\nASLToATL getPosASL player isEqualTo getPosATL player;\n```","code":["ASLToATL getPosASL player isEqualTo getPosATL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ATLToASL","AGLToASL","ASLToAGL","getPos","getPosATL","getPosASL","visiblePosition","visiblePositionASL"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assert","operator":null,"title":"assert","type":"command","url":"https://community.bistudio.com/wiki/assert","revid":363603,"updated":"2024-04-08T09:49:06Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Tests a condition and if the condition is false, displays error on screen (if -showscripterrors enabled) and logs error into .rpt file. It does not interrupt the script execution.\n\nIf script was pre-processed with preprocessFileLineNumbers, it will also show/log the error line number and the file name.","syntaxes":[{"syntax":"assert condition","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"condition: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"mirrors condition","text":"Boolean - mirrors condition"},"form":"unary","operator":null,"left":null,"right":{"text":"condition","types":["Boolean"]}}],"examples":[{"text":"```sqf\nassert (1 > 2);\n```","code":["assert (1 > 2);"]},{"text":"Check function params (Faster alternative to BIS_fnc_param)\n\n```sqf\nsome_func = {\n    _0 = _this select 0;\n    _1 = _this select 1;\n    _2 = _this select 2;\n    if (!assert (\n        typeName _0 == \"ARRAY\" && \n        typeName _1 == \"STRING\" &&\n        typeName _2 == \"SCALAR\"\n    )) exitWith { /* optional error logging */ };\n    hint \"Alright!\";\n};\n[1,2,3] call some_func; // assert error\n[[1],\"2\",3] call some_func; // Alright!\n```","code":["some_func = {\n\t_0 = _this select 0;\n\t_1 = _this select 1;\n\t_2 = _this select 2;\n\tif (!assert (\n\t\ttypeName _0 == \"ARRAY\" && \n\t\ttypeName _1 == \"STRING\" &&\n\t\ttypeName _2 == \"SCALAR\"\n\t)) exitWith { /* optional error logging */ };\n\thint \"Alright!\";\n};\n[1,2,3] call some_func; // assert error\n[[1],\"2\",3] call some_func; // Alright!"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["try","catch","throw","halt","diag_captureFrame","diag_captureSlowFrame","diag logSlowFrame"],"notes":[{"user":"RoehrenRadio","date":"2010-05-15T00:01:00Z","text":"Returns false, if condition is false, and returns true, if condition is true."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignAsCargo","operator":null,"title":"assignAsCargo","type":"command","url":"https://community.bistudio.com/wiki/assignAsCargo","revid":369104,"updated":"2024-09-03T10:25:28Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Assign a unit as cargo of a vehicle. Used together with orderGetIn to order a unit to get in as cargo into a specific vehicle. Before usage of this command a subordinate unit has not got the option to get into the cargo space of the vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitName assignAsCargo vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 assignAsCargo _truck;\n[_soldier1] orderGetIn true;\n```","code":["_soldier1 assignAsCargo _truck;\n[_soldier1] orderGetIn true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsDriver","assignAsGunner","assignAsCommander","assignAsTurret","assignAsCargoIndex","moveInCargo","moveInCommander","moveInDriver","moveInGunner","moveInTurret","assignedVehicleRole","assignedVehicle","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"assignAsCargoIndex","operator":null,"title":"assignAsCargoIndex","type":"command","url":"https://community.bistudio.com/wiki/assignAsCargoIndex","revid":330322,"updated":"2022-08-31T15:06:34Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns the character to a specific cargo / passenger index of the given vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"character assignAsCargoIndex [vehicle, index]","since":null,"effect":null,"exec":null,"params":[{"name":"character","type":"Object","optional":false,"default":null,"description":"character to assign","types":["Object"],"since":null,"text":"character: Object - character to assign"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to assign to","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to assign to"},{"name":"index","type":"Number","optional":false,"default":null,"description":"cargo / passenger index","types":["Number"],"since":null,"text":"index: Number - cargo / passenger index"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"character","types":["Object"]},"right":{"text":"[vehicle, index]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer assignAsCargoIndex [myHelicopter, 1];\n```","code":["player assignAsCargoIndex [myHelicopter, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCargo","assignAsDriver","assignAsCommander","assignAsGunner","assignAsTurret","getCargoIndex","assignedVehicleRole","unassignVehicle","fullCrew"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignAsCommander","operator":null,"title":"assignAsCommander","type":"command","url":"https://community.bistudio.com/wiki/assignAsCommander","revid":369099,"updated":"2024-09-03T10:25:27Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Assign a unit as commander of a vehicle. Used together with orderGetIn to order subordinate units to get in as commander of a specific vehicle.\nBefore usage of this command a subordinate unit has not got the option to get into the commander place of the vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitName assignAsCommander vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 assignAsCommander _tank;\n[_soldier1] orderGetIn true;\n```","code":["_soldier1 assignAsCommander _tank;\n[_soldier1] orderGetIn true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsDriver","assignAsGunner","assignAsCargo","assignAsTurret","assignAsCargoIndex","moveInCargo","moveInCommander","moveInDriver","moveInGunner","moveInTurret","assignedVehicleRole","assignedVehicle","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"assignAsDriver","operator":null,"title":"assignAsDriver","type":"command","url":"https://community.bistudio.com/wiki/assignAsDriver","revid":369098,"updated":"2024-09-03T10:25:27Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Assign a unit as driver of a vehicle. Used together with orderGetIn to order subordinate units to get in as driver of a specific vehicle. Before usage of this command a subordinate unit has not got the option to get into the driver place of the vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitName assignAsDriver vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 assignAsDriver _tank;\n[_soldier1] orderGetIn true;\n```","code":["_soldier1 assignAsDriver _tank;\n[_soldier1] orderGetIn true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCommander","assignAsGunner","assignAsCargo","assignAsTurret","assignAsCargoIndex","moveInCargo","moveInCommander","moveInDriver","moveInGunner","moveInTurret","assignedVehicleRole","assignedVehicle","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"assignAsGunner","operator":null,"title":"assignAsGunner","type":"command","url":"https://community.bistudio.com/wiki/assignAsGunner","revid":369102,"updated":"2024-09-03T10:25:27Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Assign a unit as gunner of a vehicle. Used together with orderGetIn to order subordinate units to get in as gunner of a specific vehicle. Before usage of this command a subordinate unit has not got the option to get into the gunner place of the vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitName assignAsGunner vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 assignAsGunner _tank;\n[_soldier1] orderGetIn true;\n```","code":["_soldier1 assignAsGunner _tank;\n[_soldier1] orderGetIn true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCommander","assignAsDriver","assignAsCargo","assignAsTurret","assignAsCargoIndex","moveInCargo","moveInCommander","moveInDriver","moveInGunner","moveInTurret","assignedVehicleRole","assignedVehicle","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"assignAsTurret","operator":null,"title":"assignAsTurret","type":"command","url":"https://community.bistudio.com/wiki/assignAsTurret","revid":377474,"updated":"2026-01-02T06:48:45Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns the soldier to turret.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unit assignAsTurret [vehicle, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[vehicle, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer assignAsTurret [BIS_vehicle, [0,1]];\n```","code":["player assignAsTurret [BIS_vehicle, [0,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCargo","assignAsDriver","assignAsCommander","assignAsGunner","assignAsCargoIndex","assignedVehicleRole","unassignVehicle","turretUnit","moveInTurret","fullCrew"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"assignCurator","operator":null,"title":"assignCurator","type":"command","url":"https://community.bistudio.com/wiki/assignCurator","revid":348458,"updated":"2023-11-08T13:00:18Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Assign player as curator. Two players cannot act as one curator.","syntaxes":[{"syntax":"player assignCurator curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer assignCurator myCurator;\n```","code":["player assignCurator myCurator;"]}],"multiplayer":"Can be executed only on server","problems":null,"aliases":[],"see_also":["Arma 3: Curator","unassignCurator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"assignedCargo","operator":null,"title":"assignedCargo","type":"command","url":"https://community.bistudio.com/wiki/assignedCargo","revid":323004,"updated":"2022-06-28T21:43:04Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of soldiers assigned to the given vehicle as a cargo.","syntaxes":[{"syntax":"assignedCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_list = assignedCargo _vehicleName;\n```","code":["_list = assignedCargo _vehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCargo","assignAsGunner","assignAsCommander","assignAsDriver","moveInCargo","moveInGunner","moveInCommander","moveInDriver","assignAsTurret","gunner","commander","driver","moveInTurret","assignedGunner","assignedCommander","assignedDriver"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedCommander","operator":null,"title":"assignedCommander","type":"command","url":"https://community.bistudio.com/wiki/assignedCommander","revid":318788,"updated":"2022-05-13T09:21:30Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the soldier assigned to the given vehicle as a commander.","syntaxes":[{"syntax":"assignedCommander vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_commander = assignedCommander vehicleName;\n```","code":["_commander = assignedCommander vehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCommander","assignAsGunner","assignAsTurret","assignAsDriver","moveInCommander","moveInGunner","moveInTurret","moveInDriver","commander","gunner","assignAsCargo","driver","moveInCargo","assignedGunner","assignedCargo","assignedDriver"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedDriver","operator":null,"title":"assignedDriver","type":"command","url":"https://community.bistudio.com/wiki/assignedDriver","revid":363250,"updated":"2024-03-26T10:51:23Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the soldier assigned to the given vehicle as a driver.","syntaxes":[{"syntax":"assignedDriver vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_driver = assignedDriver vehicleName;\n```","code":["_driver = assignedDriver vehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsDriver","assignAsGunner","assignAsTurret","assignAsCommander","moveInDriver","moveInGunner","moveInTurret","moveInCommander","driver","gunner","moveInCargo","commander","assignAsCargo","assignedGunner","assignedCargo","assignedCommander"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedGroup","operator":null,"title":"assignedGroup","type":"command","url":"https://community.bistudio.com/wiki/assignedGroup","revid":338335,"updated":"2023-02-28T14:34:19Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Group to which the given vehicle was added last with addVehicle. To update assignedGroup to the current group, run addVehicle to the current group again.","syntaxes":[{"syntax":"assignedGroup vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"}],"returns":{"type":"Group","types":["Group"],"description":null,"text":"Group"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_group = assignedGroup vehicle player;\n```","code":["_group = assignedGroup vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedVehicle","assignedVehicles","addVehicle","assignAsDriver","assignAsCargo","assignAsCommander","assignAsGunner","assignAsTurret","assignAsCargoIndex","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"assignedGunner","operator":null,"title":"assignedGunner","type":"command","url":"https://community.bistudio.com/wiki/assignedGunner","revid":363272,"updated":"2024-03-26T10:51:42Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the soldier assigned to the given vehicle as a gunner.","syntaxes":[{"syntax":"assignedGunner vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_gunner = assignedGunner vehicle player;\n```","code":["_gunner = assignedGunner vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsGunner","assignAsTurret","assignAsCommander","assignAsDriver","moveInGunner","moveInTurret","moveInCommander","moveInDriver","gunner","ArmA: Actions","commander","driver","assignAsCargo","moveInCargo","assignedCommander","assignedDriver"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedItems","operator":null,"title":"assignedItems","type":"command","url":"https://community.bistudio.com/wiki/assignedItems","revid":378170,"updated":"2026-03-03T07:06:02Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with assigned items. The resulting Array order is not guaranteed.\nTo check availability of a particular slot item use getSlotItemName.\nTo return stored items see items and itemsWithMagazines.","syntaxes":[{"syntax":"assignedItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"assignedItems [unit, allItems, includeBinocs]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"soldier","types":["Object"],"since":null,"text":"unit: Object - soldier"},{"name":"allItems","type":"Boolean","optional":false,"default":null,"description":"true to include all slot items, false exclude goggles and headgear","types":["Boolean"],"since":null,"text":"allItems: Boolean - true to include all slot items, false exclude goggles and headgear"},{"name":"includeBinocs","type":"Boolean","optional":false,"default":null,"description":"true to include binoculars (which is a weapon), false to exclude it","types":["Boolean"],"since":null,"text":"includeBinocs: Boolean - true to include binoculars (which is a weapon), false to exclude it"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, allItems, includeBinocs]","types":["Array"]}}],"examples":[{"text":"```sqf\nhint str assignedItems player;\n```","code":["hint str assignedItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSlotItemName","assignItem","unassignItem","linkItem","unlinkItem","addItem","removeItem","removeAllAssignedItems","items","itemsWithMagazines","backpacks"],"notes":[{"user":"Druid","date":"2013-06-18T14:26:00Z","text":"Arma 3, version 0.70 - headgear and goggles are not present in returned array now."},{"user":"Killzone_Kid","date":"2013-08-22T17:52:00Z","text":"For head gear use headgear, addHeadgear and removeHeadgear. For goggles use goggles, addGoggles and removeGoggles"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"assignedTarget","operator":null,"title":"assignedTarget","type":"command","url":"https://community.bistudio.com/wiki/assignedTarget","revid":364219,"updated":"2024-05-06T09:38:11Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the target assigned to an unit or the vehicle's effectiveCommander. The target can be assigned by the group/vehicle/formation leader (as player via quick command menu or \"target\" complex command menu).\n\nTo unassign the target use doWatch objNull or commandWatch objNull or as player and group leader order \"no target\" in the \"target\" complex command menu.\n\n> [!NOTE]\n> - This command does not return the target a unit is actually engaging (\"attack unit\"). For this information, see getAttackTarget.\n> - If a player is inside a vehicle as the effectiveCommander, the vehicle's crew assignedTarget will always be objNull.","syntaxes":[{"syntax":"assignedTarget vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_target = assignedTarget _T72;\n```","code":["_target = assignedTarget _T72;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAttackTarget","commandTarget","doTarget","commandWatch","doWatch","effectiveCommander","setEffectiveCommander"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedTeam","operator":null,"title":"assignedTeam","type":"command","url":"https://community.bistudio.com/wiki/assignedTeam","revid":341182,"updated":"2023-05-13T22:13:46Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the team the unit belongs to. Possible values:\n\n- `\"MAIN\"` (default and white)\n- `\"RED\"`\n- `\"GREEN\"`\n- `\"BLUE\"`\n- `\"YELLOW\"`\n- Arma 3 v1.94 `\"\"` if given unit is objNull or remoteControlling another unit","syntaxes":[{"syntax":"assignedTeam unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":null,"types":["String","Nothing","objNull","remoteControl"],"description":null,"text":"String (or, prior to Arma 3 v1.94, Nothing if given unit is objNull or remoteControlling another unit)"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_team = assignedTeam player;\n```","code":["_team = assignedTeam player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignTeam"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedVehicle","operator":null,"title":"assignedVehicle","type":"command","url":"https://community.bistudio.com/wiki/assignedVehicle","revid":330331,"updated":"2022-08-31T15:20:27Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the vehicle to which a unit is assigned, usually with *assignAsXXX* command. If no vehicle is assigned objNull is returned.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"assignedVehicle unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_vehicle = assignedVehicle player;\n```","code":["_vehicle = assignedVehicle player;"]},{"text":"```sqf\n_units apply { _x leaveVehicle (assignedVehicle _x) };\n```","code":["_units apply { _x leaveVehicle (assignedVehicle _x) };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedVehicleRole","addVehicle","assignAsDriver","assignAsCargo","assignAsCommander","assignAsGunner","assignAsTurret","assignAsCargoIndex","unassignVehicle","leaveVehicle","assignedVehicles","assignedGroup","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedVehicleRole","operator":null,"title":"assignedVehicleRole","type":"command","url":"https://community.bistudio.com/wiki/assignedVehicleRole","revid":338904,"updated":"2023-04-17T14:28:10Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the role a unit is assigned to within its assigned vehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"assignedVehicleRole unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Array","types":["Array"],"description":"the array which is returned contains: - [] - not assigned to any vehicle - [\"driver\"] - Assigned as driver - [\"cargo\"] or Arma 3 v1.32 [\"cargo\", [turret path]] - assigned as cargo - [\"turret\", turretPath] - assigned to a turret (turretPath format Turret Path)","text":"Array - the array which is returned contains:\n\n- [] - not assigned to any vehicle\n- [\"driver\"] - Assigned as driver\n- [\"cargo\"] or Arma 3 v1.32 [\"cargo\", [turret path]] - assigned as cargo\n- [\"turret\", turretPath] - assigned to a turret (turretPath format Turret Path)"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_RoleArray = assignedVehicleRole player;\n```","code":["_RoleArray = assignedVehicleRole player;"]},{"text":"Get weapons available to player at player occupied turret:\n\n```sqf\n_weaponsTurret = vehicle player weaponsTurret (assignedVehicleRole player select 1);\n```","code":["_weaponsTurret = vehicle player weaponsTurret (assignedVehicleRole player select 1);"]}],"multiplayer":"On a client the command will return empty arrays for every unit that is not local. On the server the command correctly returns the role, regardless of the units locality.","problems":null,"aliases":[],"see_also":["addVehicle","assignedVehicle","unassignVehicle","leaveVehicle","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","assignAsTurret","crew","assignedVehicles","assignedGroup","fullCrew"],"notes":[{"user":"Killzone_Kid","date":"2013-08-31T16:18:00Z","text":"When player is in a group of AIs and is not the leader, assignedVehicleRole of the player could be unpredictable and absolutely not related to the position player occupies.\nIn short, forget about this command for the player, it is unreliable and has been broken too many times in the past."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"assignedVehicles","operator":null,"title":"assignedVehicles","type":"command","url":"https://community.bistudio.com/wiki/assignedVehicles","revid":338334,"updated":"2023-02-28T14:33:58Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all vehicles added to the given Group with addVehicle.","syntaxes":[{"syntax":"assignedVehicles group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_vehicles = assignedVehicles group player;\n```","code":["_vehicles = assignedVehicles group player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedVehicle","assignedGroup","addVehicle","assignAsDriver","assignAsCargo","assignAsCommander","assignAsGunner","assignAsTurret","assignAsCargoIndex","unassignVehicle","leaveVehicle","fullCrew"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"assignItem","operator":null,"title":"assignItem","type":"command","url":"https://community.bistudio.com/wiki/assignItem","revid":369096,"updated":"2024-09-03T10:25:27Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Assigns existing item from inventory (uniform, vest, backpack) to a correct slot. If the slot is occupied by another item, it gets replaced. See also linkItem.","syntaxes":[{"syntax":"unit assignItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nbluforUnit addItem \"NVGoggles\";\nbluforUnit assignItem \"NVGoggles\";\nopforUnit addItem \"NVGoggles_OPFOR\";\nopforUnit assignItem \"NVGoggles_OPFOR\";\nindependentUnit addItem \"NVGoggles_INDEP\";\nindependentUnit assignItem \"NVGoggles_INDEP\";\n```","code":["bluforUnit addItem \"NVGoggles\";\nbluforUnit assignItem \"NVGoggles\";\nopforUnit addItem \"NVGoggles_OPFOR\";\nopforUnit assignItem \"NVGoggles_OPFOR\";\nindependentUnit addItem \"NVGoggles_INDEP\";\nindependentUnit assignItem \"NVGoggles_INDEP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unassignItem","addItem","removeItem","linkItem","unlinkItem","assignedItems","removeAllAssignedItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"assignTeam","operator":null,"title":"assignTeam","type":"command","url":"https://community.bistudio.com/wiki/assignTeam","revid":340282,"updated":"2023-04-28T17:04:36Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"| Team | Value |\n|---|---|\n| White | \"MAIN\" |\n| Red | \"RED\" |\n| Green | \"GREEN\" |\n| Blue | \"BLUE\" |\n| Yellow | \"YELLOW\" |\n\nAssigns the unit (in case of a vehicle, its commander) to the given team. Team is an option in group control (unit management) menu that allows to split player group in teams and then give bulk order to separate teams.\nIn order to operate properly, the command requires specific conditions:\n- the command requires player to be fully initialised\n- the unit getting assigned must be either player himself or a unit in player's group\nThe colour of the assigned team for a unit is seen on the group management UI as well as squad radar.\n\n> [!IMPORTANT]\n> In older versions of the game (Arma 2?) the effect of this command is **local** Local Effect.","syntaxes":[{"syntax":"unit assignTeam team","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"team","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"team: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"team","types":["String"]}}],"examples":[{"text":"```sqf\n_soldier2 assignTeam \"RED\";\n```","code":["_soldier2 assignTeam \"RED\";"]},{"text":"In a unit's init script in the editor spawn should be used, otherwise a [race condition](https://en.wikipedia.org/wiki/Race_condition) may be experienced:\n\n```sqf\nthis spawn { _this assignTeam \"RED\" };\n```","code":["this spawn { _this assignTeam \"RED\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedTeam","dissolveTeam","unassignTeam"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"assignToAirport","operator":null,"title":"assignToAirport","type":"command","url":"https://community.bistudio.com/wiki/assignToAirport","revid":352096,"updated":"2024-02-01T23:24:49Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns a plane to an airport ID or object.","syntaxes":[{"syntax":"plane assignToAirport id","since":null,"effect":null,"exec":null,"params":[{"name":"plane","type":"Object","optional":false,"default":null,"description":"plane","types":["Object"],"since":null,"text":"plane: Object - plane"},{"name":"id","type":"Number","optional":false,"default":null,"description":"airport id","types":["Number"],"since":null,"text":"id: Number - airport id"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"plane","types":["Object"]},"right":{"text":"id","types":["Number"]}},{"syntax":"plane assignToAirport target","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"plane","type":"Object","optional":false,"default":null,"description":"plane","types":["Object"],"since":null,"text":"plane: Object - plane"},{"name":"target","type":"Object","optional":false,"default":null,"description":"airport object. For example an aircraft carrier, see Arma 3: Dynamic Airport Configuration","types":["Object"],"since":null,"text":"target: Object - airport object. For example an aircraft carrier, see Arma 3: Dynamic Airport Configuration"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"plane","types":["Object"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\nplane1 assignToAirport 0;\n```","code":["plane1 assignToAirport 0;"]},{"text":"```sqf\nplane1 assignToAirport carrier1;\n```","code":["plane1 assignToAirport carrier1;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command is not implemented in **Armed Assault**, use landAt instead.","aliases":[],"see_also":["airportSide","setAirportSide","land","landAt","allAirports","Arma: Airport IDs"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"atan","operator":null,"title":"atan","type":"command","url":"https://community.bistudio.com/wiki/atan","revid":349989,"updated":"2023-11-20T22:11:41Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the **arcus tangens**.","syntaxes":[{"syntax":"atan x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":"result is in degrees","text":"Number - result is in degrees"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_degrees = atan 1; // 45\n```","code":["_degrees = atan 1; // 45"]}],"multiplayer":null,"problems":null,"aliases":["atg"],"see_also":["atg","atan2"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"atan2","operator":null,"title":"atan2","type":"command","url":"https://community.bistudio.com/wiki/atan2","revid":363173,"updated":"2024-03-25T08:38:17Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"ArcTangent of *y/x*. Used to determine the angle of a vector *[y,x]*. Result in Degrees between -180 and 180.\n\n> [!NOTE]\n> This command can handle *x* being 0, unlike when using atan, and will return 90\n\n> [!IMPORTANT]\n> This command has higher precedence than the select command, therefore beware of the case below:\n>\n> ```sqf\n>  _pos select 0  atan2 (_pos select 1) // error\n> (_pos select 0) atan2 (_pos select 1) // OK\n> ```\n>\n> Alternatively, consider using the # operator: `_pos # 0 atan2 _pos # 1`","syntaxes":[{"syntax":"y atan2 x","since":null,"effect":null,"exec":null,"params":[{"name":"y","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"y: Number"},{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"y","types":["Number"]},"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_yx = [5,3];\n_degrees = (_yx select 0) atan2 (_yx select 1); // 59.0362\n```","code":["_yx = [5,3];\n_degrees = (_yx select 0) atan2 (_yx select 1); // 59.0362"]},{"text":"Get direction from _obj1 to _obj2:\n\n```sqf\n_vd = getPosASL _obj2 vectorDiff getPosASL _obj1;\n_dir = (_vd select 0) atan2 (_vd select 1); // _dir range from -180 to +180\n_dir = (_dir + 360) % 360; // _dir range from 0 to 360\n```","code":["_vd = getPosASL _obj2 vectorDiff getPosASL _obj1;\n_dir = (_vd select 0) atan2 (_vd select 1); // _dir range from -180 to +180\n_dir = (_dir + 360) % 360; // _dir range from 0 to 360"]},{"text":"Get relative direction from _obj1 to _obj2:\n\n```sqf\n_yx = _obj1 worldToModel getPosASL _obj2;\n_dir = (_yx select 0) atan2 (_yx select 1); // _dir range from -180 to +180\n_dir = (_dir + 360) % 360; // _dir range from 0 to 360\n```","code":["_yx = _obj1 worldToModel getPosASL _obj2;\n_dir = (_yx select 0) atan2 (_yx select 1); // _dir range from -180 to +180\n_dir = (_dir + 360) % 360; // _dir range from 0 to 360"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["atan","tan","sin","cos","asin","acos","rad","pi","vectorCos","BIS_fnc_dirTo","getRelPos","getRelDir"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"atg","operator":null,"title":"atg","type":"command","url":"https://community.bistudio.com/wiki/atg","revid":349988,"updated":"2023-11-20T22:11:41Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the **arcus tangens**.","syntaxes":[{"syntax":"atg x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":"result in degrees","text":"Number - result in degrees"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_atanThreeFifth = atg 3/5;\n```","code":["_atanThreeFifth = atg 3/5;"]}],"multiplayer":null,"problems":null,"aliases":["atan"],"see_also":["atan"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ATLToASL","operator":null,"title":"ATLToASL","type":"command","url":"https://community.bistudio.com/wiki/ATLToASL","revid":377536,"updated":"2026-01-02T06:53:28Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts a position from PositionATL to PositionASL","syntaxes":[{"syntax":"ATLToASL pos","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"PositionATL","optional":false,"default":null,"description":"position to convert","types":["PositionATL"],"since":null,"text":"pos: PositionATL - position to convert"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"pos","types":["PositionATL"]}}],"examples":[{"text":"```sqf\nATLToASL (getPosATL player) isEqualTo getPosASL player;\n```","code":["ATLToASL (getPosATL player) isEqualTo getPosASL player;"]},{"text":"```sqf\n_camPosASL = ATLToASL positionCameraToWorld [0,0,0];\n```","code":["_camPosASL = ATLToASL positionCameraToWorld [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ASLToATL","AGLToASL","ASLToAGL","getPos","getPosATL","getPosASL"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"attachChild","operator":null,"title":"attachChild","type":"command","url":"https://community.bistudio.com/wiki/attachChild","revid":378902,"updated":"2026-08-11T14:56:33Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Attaches a child object to a parent, similar to attachTo but instead of a rigid/forced attachment its using a PhysX joint.\n\n> [!NOTE]\n> For more information see [NVIDIA docs](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/guide/Manual/Joints.html).\n\nNote that the joint parameters XYZ orientations, are according to the localFrame of the joint. swingZ/swingY/twist being Yaw/Roll/Pitch, can be changed if the joint itself is rotated, because the joint rotation moves the whole axis.","syntaxes":[{"syntax":"[parent, child] attachChild [jointType, localFrameParent, localFrameChild, miscFlags, jointDescription]","since":null,"effect":null,"exec":null,"params":[{"name":"parent","type":"Object","optional":false,"default":null,"description":"the parent object that another object is attached to. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?).","types":["Object"],"since":null,"text":"parent: Object - the parent object that another object is attached to. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?)."},{"name":"child","type":"Object","optional":false,"default":null,"description":"the object being attached onto the parent. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?).","types":["Object"],"since":null,"text":"child: Object - the object being attached onto the parent. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?)."},{"name":"jointType","type":"String","optional":false,"default":null,"description":"currently only \"6DOFJoint\" and \"RevoluteJoint\" and \"FixedJoint\"\n\n**6DOFJoint**\nAllows to configure all axis (XYZ translation, Pitch/Yaw/Roll rotation) limits and drives.\n**RevoluteJoint**\nOnly allows rotation around the X axis, a Revolute joint can also be implemented with a 6DOFJoint and the appropriate limits (internally it is implemented exactly like that)\n**FixedJoint**\nLimited in all axis, it essentially works like a PhysX based attachTo.","types":["String"],"since":null,"text":"jointType: String - currently only \"6DOFJoint\" and \"RevoluteJoint\" and \"FixedJoint\"\n\n**6DOFJoint**\nAllows to configure all axis (XYZ translation, Pitch/Yaw/Roll rotation) limits and drives.\n**RevoluteJoint**\nOnly allows rotation around the X axis, a Revolute joint can also be implemented with a 6DOFJoint and the appropriate limits (internally it is implemented exactly like that)\n**FixedJoint**\nLimited in all axis, it essentially works like a PhysX based attachTo."},{"name":"localFrameParent","type":"Array","optional":false,"default":null,"description":"the Position and orientation, in parent's model-space of where the joint will be placed.\n\nAn Array of 3 elements [position, upPos, dirPos]\n\nEach element can either be a Vector (3-element array of Number) or a Memory point name (String).\n\nAn important Caveat when using Vectors is that dir and up are not direction vectors, but positions.\n\nEssentially, upPos/dirPos would be the model-space coordinates of where the memory point would be.\n\nFor example:\n\n```sqf\nprivate _jointPos = [0, 0, 0];\nprivate _vectorDir = [0, 1, 0];\nprivate _vectorUp = [0, 0, 1];\n[_jointPos, _jointPos vectorAdd _vectorDir, _jointPos vectorAdd _vectorUp];\n```","types":["Array"],"since":null,"text":"localFrameParent: Array - the Position and orientation, in parent's model-space of where the joint will be placed.\n\nAn Array of 3 elements [position, upPos, dirPos]\n\nEach element can either be a Vector (3-element array of Number) or a Memory point name (String).\n\nAn important Caveat when using Vectors is that dir and up are not direction vectors, but positions.\n\nEssentially, upPos/dirPos would be the model-space coordinates of where the memory point would be.\n\nFor example:\n\n```sqf\nprivate _jointPos = [0, 0, 0];\nprivate _vectorDir = [0, 1, 0];\nprivate _vectorUp = [0, 0, 1];\n[_jointPos, _jointPos vectorAdd _vectorDir, _jointPos vectorAdd _vectorUp];\n```"},{"name":"localFrameChild","type":"Array","optional":false,"default":null,"description":"the position and orientation, in child's model-space of where the joint will be placed.","types":["Array"],"since":null,"text":"localFrameChild: Array - the position and orientation, in child's model-space of where the joint will be placed."},{"name":"miscFlags","type":"Array","optional":true,"default":"false","description":"[(collisionEnabled, breakForce)]\n\n****\ncollisionEnabled: Boolean  - When false, disables collision between the two joint-ed objects\n****\nbreakForce: Number (Optional, Default: -1)\n****\nlimitsAreForces?","types":["Array"],"since":null,"text":"miscFlags: Array - [(collisionEnabled, breakForce)]\n\n****\ncollisionEnabled: Boolean (Optional, Default: false) - When false, disables collision between the two joint-ed objects\n****\nbreakForce: Number (Optional, Default: -1)\n****\nlimitsAreForces?"},{"name":"jointDescription","type":"Array","optional":true,"default":"0","description":"this specifies the behavior/limits of the joint.\n\n[(linearLimit, swingLimit, twistLimit, drives)]\n\nNote that all are optional. Passing an empty array is equivalent to using a \"FixedJoint\" type\n\n<div class=\"_description\">\n**linearLimit**\nArray - Linear limit specifies the joints permitted translation along the XYZ axis.\nThere are three types of linear limits, fully locked, per-axis limit and distance limit.\n\n<div class=\"_description\">\n**Fully Locked:**\n[]\nEmpty array, will completely lock the XYZ translational axes, only allowing rotational movement (If allowed in the swing/twist limits)\n**Per axis:**\n[limitX, limitY, limitZ]\n<div class=\"_description\">\n**limit*:**\nArray - [lowerLimit, upperLimit, springParameters] <div class=\"_description\">\n**lowerLimit:**\nNumber - The minimum permitted offset on the axis\n**upperLimit:**\nNumber - The maximum permitted offset on the axis\n upperLimit must be larger than lowerLimit\n**springParameters:**\nArray - [(restitution, spring, damping)]\nAll spring parameters are optional, but for the linear limits, atleast an empty array must be provided.\n**restitiution:**\nNumber  - Must be between 0-1.\n Controls the amount of bounce when the joint hits a limit.\n A restitution value of 1.0 causes the joint to bounce back with the velocity which it hit the limit.\n A value of zero causes the joint to stop dead.\n [NVIDIA docs](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/classPxJointLimitParameters.html#cf208a0f1e54fb8e9219af1e0357d4a9)\n**spring:**\nNumber (Optional, Default: 0) - Must be 0 or greater.\n if greater than zero, the limit is soft, i.e. a spring pulls the joint back to the limit\n**damping:**\nNumber (Optional, Default: 0) - Must be 0 or greater. if spring is greater than zero, this is the damping of the limit spring\n**Distance Limit**\n[xLocked, yLocked, zLocked, distanceLimit, springParameters]\n <div class=\"_description\">\n***Locked:**\nBoolean - Whether the axis is completely locked and no translation is allowed along it\n**distanceLimit:**\nNumber - Distance on meters, as a radius/sphere around the joint.\n**swingLimit:**\nArray - [(swingX, swingZ, springParameters)]\nAll parameters are optional, the default is both swing axis being locked\nSwing limit comes in two types, cone and pyramid. Which variant is used depends on the datatype inside the swing parameter\nNote that cone cannot be combined with pyramid, either both are cone or both are pyramid.\nIf the swing limit is pi, the rotation around that axis is fully unlocked/free.<div class=\"_description\">\n**Cone limit:**\nswingZ: Number (Optional, Default 0/locked) - The rotation around the Z (up) axis, thus the yaw. Rotation in radians, between pi and pi.\n****\nswingY: Number (Optional, Default 0/locked) - The rotation around the Y (front/dir) axis, thus the roll. Rotation in radians, between pi and pi.\n**Pyramid limit:**\nswingZ: Array - [(min, max)] - Same rotation in radians as the cone limit, but it can be asymmetrical.\n****\nswingY:  Array - [(min, max)] - Same rotation in radians as the cone limit, but it can be asymmetrical.\n**twistLimit:**\nArray - [(twistLower, twistUpper, springParameters)]\nTwist is rotation about the X (right) axis, thus the pitch.\nLeft and right twist limits can be configured independently.\n<div class=\"_description\">\n**twist*:**\nNumber (Optional, Default: 0) - Rotation limit in radians, between -2pi and 2pi\n 0 means twist is locked, and 2*pi means its completely unlocked\n**drives:**\nArray - [(angularSwingDrive, angularTwistDrive, angularSlerpDrive, linearXDrive, linearYDrive, linearZDrive, limitsAreForces)]\nDrives allow to apply force into the joint on any of the axes.\nEach drive is a spring, one end being on the joint, and the other end being on the target specified by the commands:\nsetJointDrivePosition setJointDriveOrientation setJointDriveLinearVelocity setJointDriveAngularVelocity\nFor rotational drives there are two variants, Swing+Twist or SLERP (Spherical Linear Interpolation)\nSee [NVIDIA docs](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/guide/Manual/Joints.html#drives)<div class=\"_description\">\n***Drive:**\nArray - [type, spring, damping, forceLimit]\n**type:**\nNumber - MUST be 0 (#TODO acceleration drive implementation?)\n\n**spring:**\nNumber - Same as springParameters above\n**damping:**\nNumber - Same as springParameters above\n**forceLimit:**\nNumber - The maximum force this drive c an apply to the joint\n**limitsAreForces:**\nBoolean (Optional, Default: true) - NOT IMPLEMENTED #TODO?","types":["Array"],"since":null,"text":"jointDescription: Array - this specifies the behavior/limits of the joint.\n\n[(linearLimit, swingLimit, twistLimit, drives)]\n\nNote that all are optional. Passing an empty array is equivalent to using a \"FixedJoint\" type\n\n<div class=\"_description\">\n**linearLimit**\nArray - Linear limit specifies the joints permitted translation along the XYZ axis.\nThere are three types of linear limits, fully locked, per-axis limit and distance limit.\n\n<div class=\"_description\">\n**Fully Locked:**\n[]\nEmpty array, will completely lock the XYZ translational axes, only allowing rotational movement (If allowed in the swing/twist limits)\n**Per axis:**\n[limitX, limitY, limitZ]\n<div class=\"_description\">\n**limit*:**\nArray - [lowerLimit, upperLimit, springParameters] <div class=\"_description\">\n**lowerLimit:**\nNumber - The minimum permitted offset on the axis\n**upperLimit:**\nNumber - The maximum permitted offset on the axis\n upperLimit must be larger than lowerLimit\n**springParameters:**\nArray - [(restitution, spring, damping)]\nAll spring parameters are optional, but for the linear limits, atleast an empty array must be provided.\n**restitiution:**\nNumber (Optional, Default: 0) - Must be between 0-1.\n Controls the amount of bounce when the joint hits a limit.\n A restitution value of 1.0 causes the joint to bounce back with the velocity which it hit the limit.\n A value of zero causes the joint to stop dead.\n [NVIDIA docs](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/apireference/files/classPxJointLimitParameters.html#cf208a0f1e54fb8e9219af1e0357d4a9)\n**spring:**\nNumber (Optional, Default: 0) - Must be 0 or greater.\n if greater than zero, the limit is soft, i.e. a spring pulls the joint back to the limit\n**damping:**\nNumber (Optional, Default: 0) - Must be 0 or greater. if spring is greater than zero, this is the damping of the limit spring\n**Distance Limit**\n[xLocked, yLocked, zLocked, distanceLimit, springParameters]\n <div class=\"_description\">\n***Locked:**\nBoolean - Whether the axis is completely locked and no translation is allowed along it\n**distanceLimit:**\nNumber - Distance on meters, as a radius/sphere around the joint.\n**swingLimit:**\nArray - [(swingX, swingZ, springParameters)]\nAll parameters are optional, the default is both swing axis being locked\nSwing limit comes in two types, cone and pyramid. Which variant is used depends on the datatype inside the swing parameter\nNote that cone cannot be combined with pyramid, either both are cone or both are pyramid.\nIf the swing limit is pi, the rotation around that axis is fully unlocked/free.<div class=\"_description\">\n**Cone limit:**\nswingZ: Number (Optional, Default 0/locked) - The rotation around the Z (up) axis, thus the yaw. Rotation in radians, between pi and pi.\n****\nswingY: Number (Optional, Default 0/locked) - The rotation around the Y (front/dir) axis, thus the roll. Rotation in radians, between pi and pi.\n**Pyramid limit:**\nswingZ: Array - [(min, max)] - Same rotation in radians as the cone limit, but it can be asymmetrical.\n****\nswingY:  Array - [(min, max)] - Same rotation in radians as the cone limit, but it can be asymmetrical.\n**twistLimit:**\nArray - [(twistLower, twistUpper, springParameters)]\nTwist is rotation about the X (right) axis, thus the pitch.\nLeft and right twist limits can be configured independently.\n<div class=\"_description\">\n**twist*:**\nNumber (Optional, Default: 0) - Rotation limit in radians, between -2pi and 2pi\n 0 means twist is locked, and 2*pi means its completely unlocked\n**drives:**\nArray - [(angularSwingDrive, angularTwistDrive, angularSlerpDrive, linearXDrive, linearYDrive, linearZDrive, limitsAreForces)]\nDrives allow to apply force into the joint on any of the axes.\nEach drive is a spring, one end being on the joint, and the other end being on the target specified by the commands:\nsetJointDrivePosition setJointDriveOrientation setJointDriveLinearVelocity setJointDriveAngularVelocity\nFor rotational drives there are two variants, Swing+Twist or SLERP (Spherical Linear Interpolation)\nSee [NVIDIA docs](https://docs.nvidia.com/gameworks/content/gameworkslibrary/physx/guide/Manual/Joints.html#drives)<div class=\"_description\">\n***Drive:**\nArray - [type, spring, damping, forceLimit]\n**type:**\nNumber - MUST be 0 (#TODO acceleration drive implementation?)\n\n**spring:**\nNumber - Same as springParameters above\n**damping:**\nNumber - Same as springParameters above\n**forceLimit:**\nNumber - The maximum force this drive c an apply to the joint\n**limitsAreForces:**\nBoolean (Optional, Default: true) - NOT IMPLEMENTED #TODO?"}],"returns":{"type":"Nothing","types":["Nothing"],"description":"Do NOT depend on this staying nothing, it might change to be something.","text":"Nothing - Do NOT depend on this staying nothing, it might change to be something."},"form":"binary","operator":null,"left":{"text":"[parent, child]","types":["Array"]},"right":{"text":"[jointType, localFrameParent, localFrameChild, miscFlags, jointDescription]","types":["Array"]}}],"examples":[{"text":"Attach a Quad (varname towbar) to a HEMTT (varName vParent) and another HEMTT (varName vChild) to the Quad.\nEssentially using the Quad as a \"towbar\":\n\n```sqf\n_parentPos = [0, -5, 0]; // position on the hemtt\n_childPos = [0, 1, -0.2]; // position on the quad\n\n_jointDescription =\n[\n// Limits\n    // Linear\n    [], // Default is locked\n\n    // Swing\n    // [swing1 yaw, swing2 roll, springParams]\n    [\n        rad 45, // yaw\n        0 // roll\n    ],\n    // Twist pitch\n    // [twistLower, twistUpper, springParams]\n    [rad -20, rad 20], // Default is locked\n\n// Drives\n    [] // Default are none\n];\n\n_params = [\n    \"6DOFJoint\",\n    // From [pos,dir,up]\n    [_parentPos, _parentPos vectorAdd [0, 1, 0], _parentPos vectorAdd [0, 0, 1]],\n    // To [pos,dir,up]\n    [_childPos, _childPos vectorAdd [0, 1, 0], _childPos vectorAdd [0, 0, 1]],\n    // misc [collisions enabled]\n    [false],\n    _jointDescription\n];\n\n[vParent, towBar] attachChild _params;\n\n_parentPos = [0, -1, -0.2]; // Position on the quad\n_childPos = [0, 5, 0]; // Position on the hemtt\n\n_params = [\n    \"6DOFJoint\",\n    // From [pos,dir,up]\n    [_parentPos, _parentPos vectorAdd [0, 1, 0], _parentPos vectorAdd[0, 0, 1]],\n    // To [pos,dir,up]\n    [_childPos, _childPos vectorAdd [0, 1, 0], _childPos vectorAdd [0, 0, 1]],\n    // misc [collisions enabled]\n    [false],\n    _jointDescription\n];\n\n[towBar, vChild] attachChild _params;\n```","code":["_parentPos = [0, -5, 0]; // position on the hemtt\n_childPos = [0, 1, -0.2]; // position on the quad\n\n_jointDescription =\n[\n// Limits\n\t// Linear\n\t[], // Default is locked\n\n\t// Swing\n\t// [swing1 yaw, swing2 roll, springParams]\n\t[\n\t\trad 45, // yaw\n\t\t0 // roll\n\t],\n\t// Twist pitch\n\t// [twistLower, twistUpper, springParams]\n\t[rad -20, rad 20], // Default is locked\n\n// Drives\n\t[] // Default are none\n];\n\n_params = [\n\t\"6DOFJoint\",\n\t// From [pos,dir,up]\n\t[_parentPos, _parentPos vectorAdd [0, 1, 0], _parentPos vectorAdd [0, 0, 1]],\n\t// To [pos,dir,up]\n\t[_childPos, _childPos vectorAdd [0, 1, 0], _childPos vectorAdd [0, 0, 1]],\n\t// misc [collisions enabled]\n\t[false],\n\t_jointDescription\n];\n\n[vParent, towBar] attachChild _params;\n\n_parentPos = [0, -1, -0.2]; // Position on the quad\n_childPos = [0, 5, 0]; // Position on the hemtt\n\n_params = [\n\t\"6DOFJoint\",\n\t// From [pos,dir,up]\n\t[_parentPos, _parentPos vectorAdd [0, 1, 0], _parentPos vectorAdd[0, 0, 1]],\n\t// To [pos,dir,up]\n\t[_childPos, _childPos vectorAdd [0, 1, 0], _childPos vectorAdd [0, 0, 1]],\n\t// misc [collisions enabled]\n\t[false],\n\t_jointDescription\n];\n\n[towBar, vChild] attachChild _params;"]},{"text":"Attach a Quad (varname towbar) to a HEMTT (varName vParent) and another HEMTT (varName vChild) to the Quad.\nBut we rotate the axis so that Swing's are Pitch/Yaw and Twist is roll\n\n```sqf\n_parentPos = [0, -5, 0]; // position on the hemtt\n_childPos = [0, 1, -0.2]; // position on the quad\n\n_jointDescription =\n[\n// Limits\n    // Linear\n    [], // Default is locked\n\n    // Swing\n    // [swing1 pitch, swing2 yaw, springParams]\n    [\n        rad 20, // pitch\n        rad 45 // yaw\n    ],\n    // Twist roll\n    // [twistLower, twistUpper, springParams]\n    [], // Default is locked\n\n// Drives\n    [] // Default are none\n];\n\n_params = [\n    \"6DOFJoint\",\n    // From [pos,dir,up]\n    [_parentPos, _parentPos vectorAdd [0, 0, 1], _parentPos vectorAdd [1, 0, 0]], // Note how the up is pointing right and forward is pointing down, we are rotating the whole joint\n    // To [pos,dir,up]\n    [_childPos, _childPos vectorAdd [0, 0, 1], _childPos vectorAdd [1, 0, 0]],\n    // misc [collisions enabled]\n    [false],\n    _jointDescription\n];\n\n[vParent, towBar] attachChild _params;\n\n_parentPos = [0, -1, -0.2]; // Position on the quad\n_childPos = [0, 5, 0]; // Position on the hemtt\n\n_params = [\n    \"6DOFJoint\",\n    // From [pos,dir,up]\n    [_parentPos, _parentPos vectorAdd [0, 0, 1], _parentPos vectorAdd [1, 0, 0]],\n    // To [pos,dir,up]\n    [_childPos, _childPos vectorAdd [0, 0, 1], _childPos vectorAdd [1, 0, 0]],\n    // misc [collisions enabled]\n    [false],\n    _jointDescription\n];\n\n[towBar, vChild] attachChild _params;\n```","code":["_parentPos = [0, -5, 0]; // position on the hemtt\n_childPos = [0, 1, -0.2]; // position on the quad\n\n_jointDescription =\n[\n// Limits\n\t// Linear\n\t[], // Default is locked\n\n\t// Swing\n\t// [swing1 pitch, swing2 yaw, springParams]\n\t[\n\t\trad 20, // pitch\n\t\trad 45 // yaw\n\t],\n\t// Twist roll\n\t// [twistLower, twistUpper, springParams]\n\t[], // Default is locked\n\n// Drives\n\t[] // Default are none\n];\n\n_params = [\n\t\"6DOFJoint\",\n\t// From [pos,dir,up]\n\t[_parentPos, _parentPos vectorAdd [0, 0, 1], _parentPos vectorAdd [1, 0, 0]], // Note how the up is pointing right and forward is pointing down, we are rotating the whole joint\n\t// To [pos,dir,up]\n\t[_childPos, _childPos vectorAdd [0, 0, 1], _childPos vectorAdd [1, 0, 0]],\n\t// misc [collisions enabled]\n\t[false],\n\t_jointDescription\n];\n\n[vParent, towBar] attachChild _params;\n\n_parentPos = [0, -1, -0.2]; // Position on the quad\n_childPos = [0, 5, 0]; // Position on the hemtt\n\n_params = [\n\t\"6DOFJoint\",\n\t// From [pos,dir,up]\n\t[_parentPos, _parentPos vectorAdd [0, 0, 1], _parentPos vectorAdd [1, 0, 0]],\n\t// To [pos,dir,up]\n\t[_childPos, _childPos vectorAdd [0, 0, 1], _childPos vectorAdd [1, 0, 0]],\n\t// misc [collisions enabled]\n\t[false],\n\t_jointDescription\n];\n\n[towBar, vChild] attachChild _params;"]}],"multiplayer":"> [!IMPORTANT]\n> This command does NOT behave well in Multiplayer.","problems":null,"aliases":[],"see_also":["detachChild","setJointDrivePosition","setJointDriveOrientation","setJointDriveLinearVelocity","setJointDriveAngularVelocity","childAttached","parentAttached"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Global Effect","WIP"]},{"name":"attachedObject","operator":null,"title":"attachedObject","type":"command","url":"https://community.bistudio.com/wiki/attachedObject","revid":318758,"updated":"2022-05-13T09:21:27Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the object a location is attached to. If the location is unattached, then objNull is returned.","syntaxes":[{"syntax":"attachedObject location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_locAttachedObj = attachedObject myLocation;\n```","code":["_locAttachedObj = attachedObject myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"attachedObjects","operator":null,"title":"attachedObjects","type":"command","url":"https://community.bistudio.com/wiki/attachedObjects","revid":369106,"updated":"2024-09-03T10:27:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.14"}],"since":{"game":"arma3","name":"Arma 3","version":"1.14"},"arma3_since":"1.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of objects attached to the given object.","syntaxes":[{"syntax":"attachedObjects obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"given object","types":["Object"],"since":null,"text":"obj: Object - given object"}],"returns":{"type":"Array of Objects attached to the given object","types":["Array","Object"],"description":null,"text":"Array of Objects attached to the given object"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\n{ detach _x } forEach attachedObjects player;\n```","code":["{ detach _x } forEach attachedObjects player;"]},{"text":"```sqf\nif (count attachedObjects player == 0) then\n{\n    hint \"There are no objects attached to player\";\n};\n```","code":["if (count attachedObjects player == 0) then\n{\n\thint \"There are no objects attached to player\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle","attachedObject","detach"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.14","Scripting Commands"]},{"name":"attachedTo","operator":null,"title":"attachedTo","type":"command","url":"https://community.bistudio.com/wiki/attachedTo","revid":369107,"updated":"2024-09-03T10:27:31Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.14"}],"since":{"game":"arma3","name":"Arma 3","version":"1.14"},"arma3_since":"1.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns object the given object is attached to or objNull if the given object is not attached to anything.","syntaxes":[{"syntax":"attachedTo obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"given object","types":["Object"],"since":null,"text":"obj: Object - given object"}],"returns":{"type":"Object","types":["Object"],"description":"object the given object is attached to","text":"Object - object the given object is attached to"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isNull attachedTo _obj1) then\n{\n    hint \"_obj1 is not attached to anything.\";\n};\n```","code":["if (isNull attachedTo _obj1) then\n{\n\thint \"_obj1 is not attached to anything.\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle","attachedObject","detach"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.14","Scripting Commands"]},{"name":"attachObject","operator":null,"title":"attachObject","type":"command","url":"https://community.bistudio.com/wiki/attachObject","revid":318700,"updated":"2022-05-13T09:21:20Z","groups":["Object Manipulation","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attaches a location to the specified object. To detach a location, attach it to objNull.","syntaxes":[{"syntax":"location attachObject object","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nmyLocation attachObject player;\n```","code":["myLocation attachObject player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachedObject","createLocation"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Object Manipulation","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"attachTo","operator":null,"title":"attachTo","type":"command","url":"https://community.bistudio.com/wiki/attachTo","revid":378853,"updated":"2026-07-20T13:40:14Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Attaches an object to another object.\n- The offset is applied to the object center unless a memory point is provided, in which case the offset will be applied to the memory point position.\n- If no offset is specified, the current offset between the two objects will be used.\n\n> [!NOTE]\n> - All direction commands, such as setDir, setVectorDirAndUp, etc. for an attached object should be used **relative** to the reference object's direction (i.e. in model space), e.g `_attachedObj setDir 0` will make it face the same direction as the reference object, **90** face to the right, **180** face to the back, etc.\n> - Attached triggers only follow the direction of the object to which they are attached, not pitch or roll.","syntaxes":[{"syntax":"object1 attachTo [object2, offset, memPoint, followBoneRotation]","since":null,"effect":null,"exec":null,"params":[{"name":"object1","type":"Object","optional":false,"default":null,"description":"object to attach","types":["Object"],"since":null,"text":"object1: Object - object to attach"},{"name":"object2","type":"Object or Group","optional":false,"default":null,"description":"object to attach to; if a group is provided, its leader is used","types":["Object","Group"],"since":null,"text":"object2: Object or Group - object to attach to; if a group is provided, its leader is used"},{"name":"offset","type":"PositionRelative","optional":true,"default":null,"description":"the position relative to *object2*'s position","types":["PositionRelative"],"since":null,"text":"offset: PositionRelative - (Optional) the position relative to *object2*'s position"},{"name":"memPoint","type":"String","optional":true,"default":null,"description":"see Selection Translations for czech selections names","types":["String"],"since":null,"text":"memPoint: String - (Optional) see Selection Translations for czech selections names"},{"name":"followBoneRotation","type":"Boolean","optional":true,"default":null,"description":"follows the memory point's rotation (if attached to one)","types":["Boolean"],"since":"arma3 2.02","text":"followBoneRotation: Boolean - (Optional) follows the memory point's rotation (if attached to one)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object1","types":["Object"]},"right":{"text":"[object2, offset, memPoint, followBoneRotation]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer attachTo [car, [0, 0, 1]];\n```","code":["player attachTo [car, [0, 0, 1]];"]},{"text":"```sqf\nplayer attachTo [tank, [0, -1, 0], \"Usti hlavne\"];\n```","code":["player attachTo [tank, [0, -1, 0], \"Usti hlavne\"];"]},{"text":"Automatic offset:\n\n```sqf\nammoCrate attachTo [player];\n```","code":["ammoCrate attachTo [player];"]},{"text":"To set orientation of attached object use setVectorDirAndUp command:\n\n```sqf\n_expl1 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl1 attachTo [player, [-0.1, 0.1, 0.15], \"Pelvis\"];\n_expl1 setVectorDirAndUp [[0.5, 0.5, 0], [-0.5, 0.5, 0]];\n_expl2 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl2 attachTo [player, [0, 0.15, 0.15], \"Pelvis\"];\n_expl2 setVectorDirAndUp [[1, 0, 0], [0, 1, 0]];\n_expl3 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl3 attachTo [player, [0.1, 0.1, 0.15], \"Pelvis\"];\n_expl3 setVectorDirAndUp [[0.5, -0.5, 0], [0.5, 0.5, 0]];\n```","code":["_expl1 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl1 attachTo [player, [-0.1, 0.1, 0.15], \"Pelvis\"];\n_expl1 setVectorDirAndUp [[0.5, 0.5, 0], [-0.5, 0.5, 0]];\n_expl2 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl2 attachTo [player, [0, 0.15, 0.15], \"Pelvis\"];\n_expl2 setVectorDirAndUp [[1, 0, 0], [0, 1, 0]];\n_expl3 = \"DemoCharge_Remote_Ammo\" createVehicle position player;\n_expl3 attachTo [player, [0.1, 0.1, 0.15], \"Pelvis\"];\n_expl3 setVectorDirAndUp [[0.5, -0.5, 0], [0.5, 0.5, 0]];"]},{"text":"```sqf\n_drill attachTo [_worker, [0.0595885,-0.00950365,-0.13495], \"RightForeArmRoll\", true];\n_drill setVectorDirAndUp [[0.536966,-0.00438141,-0.843605],[0.345872,0.913231,0.215406]];\n_radio attachTo [_worker, [-0.100003,0.069064,0.153719], \"Spine3\", true];\n_radio setVectorDirAndUp [[-0.144569,-0.48725,0.861354],[0.039712,0.866938,0.497072]];\n```","code":["_drill attachTo [_worker, [0.0595885,-0.00950365,-0.13495], \"RightForeArmRoll\", true];\n_drill setVectorDirAndUp [[0.536966,-0.00438141,-0.843605],[0.345872,0.913231,0.215406]];\n_radio attachTo [_worker, [-0.100003,0.069064,0.153719], \"Spine3\", true];\n_radio setVectorDirAndUp [[-0.144569,-0.48725,0.861354],[0.039712,0.866938,0.497072]];"]}],"multiplayer":"Use `_attachedObj setPosWorld getPosWorld _attachedObj` *after* setDir to synchronise direction properly over the network (see setDir's page for its MP behaviour).","problems":null,"aliases":[],"see_also":["attachedTo","attachedObjects","detach","getRelPos","attachObject","attachedObject","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle","setVectorDir","setVectorUp","setVectorDirAndUp","modelToWorld","BIS_fnc_transformVectorDirAndUp","BIS_fnc_attachToRelative"],"notes":[{"user":"TeaCup","date":"2011-09-17T19:20:00Z","text":"Some objects you cannot attach anything to. To be more precise, you can attach objects to them, but the behaviour is unexpected. For instance:\n\n```sqf\nSuitcaseObject attachTo [FoldingTableObject, [0,0,0]];\n```\n\nYou would expect the suitcase to jump to the pivot point of the table, and stick to it.\n\nInstead, the suitcase will freeze in it is original position. Even if the table is moved, the suitcase will be unaffected: it will not follow the table, it will not even respond to actions it reacted to prior to being attached: pushing, being shot at, etc.. It's just an object frozen in space. In MP it is even weirder, the suitcase would turn invisible.\n\nDodgy objects when it comes to attaching things to them: most in Objects (small), Objects (signs), all of Objects (helpers) categories, etc."},{"user":"Pixinger","date":"2014-03-28T16:22:00Z","text":"If you attach an explosive charge to an object (e.g. ammobox), the charge will not detonate when you simply set the damage to 1. You must detach it before.\n\n```sqf\nprivate _target = myAmmoBox;\n// create and attach charge\nprivate _charge = \"DemoCharge_Remote_Ammo_Scripted\" createVehicle position player;\n_charge attachTo [_target, [0, 0, 0.2]];\n_charge setVectorDirAndUp [[0.5,0.5,0], [-0.5,0.5,0]];\n// now detonate charge\ndetach _charge; // Important!\n_charge setDamage 1;\n```"},{"user":"ffur2007slx2_5","date":"2014-06-01T23:00:00Z","text":"attachTo overwrites setVectorDirAndUp if attached obj was changed to attach another one.\n\n```sqf\n_obj attachTo [_logic,[0, 0, 0]];\n_obj setVectorDirAndUp [[0, 1, 0], [0, 0, -1]];\n_obj attachTo [_logic, [0, 0, 2]];        // vector no changes\n_obj attachTo [_anotherOne, [0, 0, 0]];    // vector changes to default\n```"},{"user":"ondrejkuzel","date":"2014-09-25T10:00:00Z","text":"Attaching an object does not update the accessibility of a place for the AI. The command **should not** be used for positioning large static objects - the AI will simply walk through such objects."},{"user":"Demellion","date":"2016-09-01T17:54:00Z","text":"Using attachTo with objects that have ragdoll physics (such as ammo boxes, containers, etc.) may cause unexpected behaviour.\nWhen you do so, if the attached object intersect origin object, origin object may gain some **enormous collision properties** even if the collision model for the attached object is not present localy to origin object, until detached.\nVehicles may start flipping with no mass calculation (ie tank might fly), player object might gain infinite Z-vector velocity on any interaction with terrain relief and other objects."},{"user":"R3vo","date":"2019-08-13T12:55:00Z","text":"When attaching a unit which is playing an animation to a static object, the animation becomes laggy. Presumably because the update frequency of the static object is used."},{"user":"Leopard20","date":"2024-05-10T09:22:48Z","text":"To find all selection names of vehicle turrets for attachTo, you can use this script:\n\n```sqf\nparams [\"_veh\"];\nprivate _turretSels = [];\n\nisNil { // make sure the code runs unscheduled\n    private _cfg = configOf _veh;\n    _veh = createSimpleObject [getModelInfo _veh # 1, [0,0,0]]; // create a simple object instead of the actual vehicle\n    deleteVehicle _veh; // mark it for deletion in the next frame\n\n    private _turrets = configProperties [_cfg >> \"Turrets\", \"isClass _x\", true];\n\n    private _getSelections = {_veh selectionNames \"memory\" apply {[_x, _veh selectionPosition [_x, \"memory\"], _veh selectionVectorDirAndUp [_x, \"memory\"]]}};\n    private _allSelections = call _getSelections;\n\n    {\n        private _gun = getText (_x >> \"gun\");\n        _veh animate [_gun, 0.4, true];\n        private _newSels = call _getSelections;\n        _turretSels append (_newSels - _allSelections);\n        _veh animate [_gun, 0, true];\n    } forEach _turrets;\n};\n\n_turretSels = _turretSels apply { _x # 0 };\n_turretSels arrayIntersect _turretSels\n```\n\nJust pass your vehicle to this code, for example, like this:\n\n```sqf\n[myVehicle] call MY_fnc_getTurretSelections; // MY_fnc_getTurretSelections is the above function\n```\n\nIf you simply need the end point of the gun(s), use this code instead:\n\n```sqf\nparams [\"_veh\"];\nconfigProperties [configOf _veh >> \"Turrets\", \"isClass _x\", true] apply { getText (_x >> \"gunBeg\") };\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"attackEnabled","operator":null,"title":"attackEnabled","type":"command","url":"https://community.bistudio.com/wiki/attackEnabled","revid":321158,"updated":"2022-05-13T15:07:49Z","groups":["Groups","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return whether a group's leader can issue attack commands to soldiers under his command.","syntaxes":[{"syntax":"attackEnabled name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"name: Object or Group"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["Object","Group"]}}],"examples":[{"text":"```sqf\nif (not attackEnabled _soldier) then { _soldier setCombatMode \"Careless\" };\n```","code":["if (not attackEnabled _soldier) then { _soldier setCombatMode \"Careless\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableAttack"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"awake","operator":null,"title":"awake","type":"command","url":"https://community.bistudio.com/wiki/awake","revid":373886,"updated":"2025-06-26T10:58:51Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Wakes up sleeping PhysX object or puts a PhysX object to sleep. In 2.10 this command can be used on corpses of type `Man` and has no effect on alive units. When unit gets killed it goes into ragdoll state for a short while, then the units get frozen and any simulation and collision is removed to save system resources. As a result, corpses do not react to their surrounding any more. Using this command will temporarily re-enable ragdoll state of a corpse to the same state it was when unit died. If this command is used in \"enable/disable\" sequence on a dead body, it gives the corpse a visible nudge (See example 3).\n\n> [!NOTE]\n> This command won't have lasting effect on vehicles as vehicles are actively simulated, but it works rather well on smaller PhysX enabled objects.","syntaxes":[{"syntax":"object awake awake","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"PhysX object or dead unit","types":["Object"],"since":null,"text":"object: Object - PhysX object or dead unit"},{"name":"awake","type":"Boolean","optional":false,"default":null,"description":"true to awake the object, false - to put it to sleep","types":["Boolean"],"since":null,"text":"awake: Boolean - true to awake the object, false - to put it to sleep"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"awake","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_object awake false;\n```","code":["_object awake false;"]},{"text":"Since 2.10: \n\n```sqf\n_deadUnit awake true;\n```","code":["_deadUnit awake true;"]},{"text":"Make corpse react to explosion (since 2.10): \n\n```sqf\n_deadUnit addEventHandler [\"Explosion\", \n{\n    params [\"_unit\", \"_damage\"];\n    if (_damage < 0.01) exitWith {};\n    _unit awake true;\n    _unit awake false;\n}];\n```","code":["_deadUnit addEventHandler [\"Explosion\", \n{\n\tparams [\"_unit\", \"_damage\"];\n\tif (_damage < 0.01) exitWith {};\n\t_unit awake true;\n\t_unit awake false;\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAwake","addTorque","addForce","vectorModelToWorld","vectorModelToWorldVisual","selectionPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"backpack","operator":null,"title":"backpack","type":"command","url":"https://community.bistudio.com/wiki/backpack","revid":337483,"updated":"2023-01-31T22:44:52Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a class of a backpack.","syntaxes":[{"syntax":"backpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_classname = backpack player;\n```","code":["_classname = backpack player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","backpacks"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"backpackCargo","operator":null,"title":"backpackCargo","type":"command","url":"https://community.bistudio.com/wiki/backpackCargo","revid":378396,"updated":"2026-04-04T07:57:43Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with backpacks from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"backpackCargo box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"class names [\"BackpackType1\", \"BackpackType1\", \"BackpackType2\", ...]","text":"Array of Strings - class names [\"BackpackType1\", \"BackpackType1\", \"BackpackType2\", ...]"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str backpackCargo vehicle player;\n```","code":["hint str backpackCargo vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"backpackContainer","operator":null,"title":"backpackContainer","type":"command","url":"https://community.bistudio.com/wiki/backpackContainer","revid":321069,"updated":"2022-05-13T13:06:42Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a cargo container of a unit's backpack.","syntaxes":[{"syntax":"backpackContainer unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"a soldier","types":["Object"],"since":null,"text":"unit: Object - a soldier"}],"returns":{"type":"Object","types":["Object"],"description":"cargo container or objNull","text":"Object - cargo container or objNull"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str backpackContainer player; // 1a5f7900# 163944: backpack_fast.p3d\n```","code":["hint str backpackContainer player; // 1a5f7900# 163944: backpack_fast.p3d"]},{"text":"```sqf\nhint str getMagazineCargo backpackContainer player;\n/*\n    returns e.g\n    [\n        [\n            \"APERSBoundingMine_Range_Mag\",\n            \"ClaymoreDirectionalMine_Remote_Mag\",\n            \"SLAMDirectionalMine_Wire_Mag\",\n            \"DemoCharge_Remote_Mag\"\n        ],[\n            3,\n            2,\n            2,\n            1\n        ]\n    ]\n*/\n```","code":["hint str getMagazineCargo backpackContainer player;\n/*\n\treturns e.g\n\t[\n\t\t[\n\t\t\t\"APERSBoundingMine_Range_Mag\",\n\t\t\t\"ClaymoreDirectionalMine_Remote_Mag\",\n\t\t\t\"SLAMDirectionalMine_Wire_Mag\",\n\t\t\t\"DemoCharge_Remote_Mag\"\n\t\t],[\n\t\t\t3,\n\t\t\t2,\n\t\t\t2,\n\t\t\t1\n\t\t]\n\t]\n*/"]},{"text":"```sqf\n(backpackContainer player) addWeaponCargoGlobal [weapons player select 0, 1];\n```","code":["(backpackContainer player) addWeaponCargoGlobal [weapons player select 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","uniformContainer","vestContainer","everyContainer"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-29T15:19:00Z","text":"In Arma 3 ver 1.16, we can use either backpackContainer or unitBackpack at present since both of them enjoy same operand type and return value."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"backpackItems","operator":null,"title":"backpackItems","type":"command","url":"https://community.bistudio.com/wiki/backpackItems","revid":377191,"updated":"2026-01-01T10:54:17Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all items (of any kind, even weapons) in backpack of the given unit.","syntaxes":[{"syntax":"backpackItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nbackpackItems player; // returns e.g [\"hgun_P07_F\", \"Titan_AT\"]\n```","code":["backpackItems player; // returns e.g [\"hgun_P07_F\", \"Titan_AT\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformItems","vestItems","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"backpackMagazines","operator":null,"title":"backpackMagazines","type":"command","url":"https://community.bistudio.com/wiki/backpackMagazines","revid":321381,"updated":"2022-05-14T11:03:57Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all magazines from backpack of the given unit.","syntaxes":[{"syntax":"backpackMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of String","types":["Array","String"],"description":null,"text":"Array of String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nbackpackMagazines player;\n// returns e.g\n/*\n[\n    \"Titan AT Missile(1/1)[id/cr:16/0](2x)\"\n]\n*/\n```","code":["backpackMagazines player;\n// returns e.g\n/*\n[\n\t\"Titan AT Missile(1/1)[id/cr:16/0](2x)\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformMagazines","vestMagazines","soldierMagazines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"backpacks","operator":null,"title":"backpacks","type":"command","url":"https://community.bistudio.com/wiki/backpacks","revid":377190,"updated":"2026-01-01T10:53:56Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all backpack names a unit has in its inventory, excluding the one it carries on the back.","syntaxes":[{"syntax":"backpacks unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _allCarriedBackpackTypes = backpacks player + [backpack player];\n```","code":["private _allCarriedBackpackTypes = backpacks player + [backpack player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpack","itemsWithMagazines","assignedItems","items","magazines","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"backpackSpaceFor","operator":null,"title":"backpackSpaceFor","type":"command","url":"https://community.bistudio.com/wiki/backpackSpaceFor","revid":378506,"updated":"2026-05-03T16:57:31Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how much space is in backpack for given weapon or magazine","syntaxes":[{"syntax":"backpack backpackSpaceFor weaponName","since":null,"effect":null,"exec":null,"params":[{"name":"backpack","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"backpack: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponName: String"}],"returns":{"type":"Array with [weapons, magazines]","types":["Array"],"description":"weapons: Number - magazines: Number","text":"Array with [weapons, magazines]\n- weapons: Number\n- magazines: Number"},"form":"binary","operator":null,"left":{"text":"backpack","types":["Object"]},"right":{"text":"weaponName","types":["String"]}}],"examples":[{"text":"```sqf\n(backpackContainer player) backpackSpaceFor \"m16\"; // [weapons, magazines]\n```","code":["(backpackContainer player) backpackSpaceFor \"m16\"; // [weapons, magazines]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"behaviour","operator":null,"title":"behaviour","type":"command","url":"https://community.bistudio.com/wiki/behaviour","revid":369334,"updated":"2024-09-03T18:43:00Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the behaviour of the individual unit, this is why it only accepts Object as the argument. For Arma 3 behaviour explanation see Arma_3_AI_Behavior","syntaxes":[{"syntax":"behaviour unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"one of: - \"CARELESS\" - \"SAFE\" - \"AWARE\" - \"COMBAT\" - \"STEALTH\" - \"ERROR\" (Since Arma 3 v1.78 when used on empty vehicles and such)","text":"String - one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"\n- \"ERROR\" (Since Arma 3 v1.78 when used on empty vehicles and such)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier setBehaviour \"CARELESS\";\n_b = behaviour _soldier; // returns \"CARELESS\"\n```","code":["_soldier setBehaviour \"CARELESS\";\n_b = behaviour _soldier; // returns \"CARELESS\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["AIBehaviour","setBehaviour","setWaypointBehaviour","combatMode","setCombatMode","skill","setSkill","Arma 3: AI Skill","setCombatBehaviour","combatBehaviour"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"benchmark","operator":null,"title":"benchmark","type":"command","url":"https://community.bistudio.com/wiki/benchmark","revid":329496,"updated":"2022-07-29T13:29:47Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the value of \"3D Performance\" in OFP Preferences (flashpoint.cfg). This can be used to estimate the computer performance to adapt CPU and GPU demanding settings like view distance dynamically in missions.","syntaxes":[{"syntax":"benchmark","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqs\n? (benchmark > 2000) : setViewDistance 2000\n```","code":["? (benchmark > 2000) : setViewDistance 2000"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["viewDistance","setDetailMapBlendPars","setTerrainGrid","getObjectViewDistance","setObjectViewDistance"],"notes":[{"user":"Killzone_Kid","date":"2014-03-14T13:57:00Z","text":"The command is obsolete, it was used in Operation Flashpoint to measure PC performance. In Arma 3 it returns 2000."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"bezierInterpolation","operator":null,"title":"bezierInterpolation","type":"command","url":"https://community.bistudio.com/wiki/bezierInterpolation","revid":377844,"updated":"2026-01-03T04:36:03Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets interpolated value based on [Bézier curve](https://en.wikipedia.org/wiki/Bézier_curve) with given control points (progress value is 0...1 for a curve that starts at pos0 and finishes at posN)","syntaxes":[{"syntax":"progress bezierInterpolation positions","since":null,"effect":null,"exec":null,"params":[{"name":"progress","type":"Number","optional":false,"default":null,"description":"interpolation value","types":["Number"],"since":null,"text":"progress: Number - interpolation value"},{"name":"positions","type":"Array of Position3D","optional":false,"default":null,"description":null,"types":["Array","Position3D"],"since":null,"text":"positions: Array of Position3D"}],"returns":{"type":"Position3D","types":["Position3D"],"description":"based on progress value","text":"Position3D - based on progress value"},"form":"binary","operator":null,"left":{"text":"progress","types":["Number"]},"right":{"text":"positions","types":["Array","Position3D"]}}],"examples":[{"text":"Quick demonstration that spawns some spheres around player object:\n\n```sqf\nfor \"_i\" from 0 to 1 step 0.05 do {\n    createVehicle [\"Sign_Sphere10cm_F\", (_i bezierInterpolation [\n        player modelToWorld [0,0,0],\n        player modelToWorld [0,2,2],\n        player modelToWorld [2,0,2],\n        player modelToWorld [0,0,4]\n    ]), [], 0, \"CAN_COLLIDE\"];\n};\n```","code":["for \"_i\" from 0 to 1 step 0.05 do {\n\tcreateVehicle [\"Sign_Sphere10cm_F\", (_i bezierInterpolation [\n\t\tplayer modelToWorld [0,0,0],\n\t\tplayer modelToWorld [0,2,2],\n\t\tplayer modelToWorld [2,0,2],\n\t\tplayer modelToWorld [0,0,4]\n\t]), [], 0, \"CAN_COLLIDE\"];\n};"]},{"text":"Create a map marker curve from 4 control points with overlap (progress is -0.5...1.5 instead of 0...1):\n\n```sqf\nprivate _controlPoints = [[100,-90], [200,-30], [150,60], [100,90]] apply { player getRelPos _x };\n{\n    private _marker = createMarkerLocal [str _x, _x];\n    _marker setMarkerTypeLocal \"mil_objective\";\n    _marker setMarkerTextLocal (\"P\" + str _forEachIndex);\n}\nforEach _controlPoints;\n\nfor \"_i\" from -0.5 to 1.5 step 0.01 do\n{\n    private _marker = createMarkerLocal [str _i, _i bezierInterpolation _controlPoints];\n    _marker setMarkerTypeLocal \"mil_dot\";\n};\nopenMap true;\n```","code":["private _controlPoints = [[100,-90], [200,-30], [150,60], [100,90]] apply { player getRelPos _x };\n{\n\tprivate _marker = createMarkerLocal [str _x, _x];\n\t_marker setMarkerTypeLocal \"mil_objective\";\n\t_marker setMarkerTextLocal (\"P\" + str _forEachIndex);\n}\nforEach _controlPoints;\n\nfor \"_i\" from -0.5 to 1.5 step 0.01 do\n{\n\tprivate _marker = createMarkerLocal [str _i, _i bezierInterpolation _controlPoints];\n\t_marker setMarkerTypeLocal \"mil_dot\";\n};\nopenMap true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["linearConversion","vectorLinearConversion"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"binocular","operator":null,"title":"binocular","type":"command","url":"https://community.bistudio.com/wiki/binocular","revid":318568,"updated":"2022-05-13T09:21:07Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns class name of currently used binocular weapon.","syntaxes":[{"syntax":"binocular unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_binocs = binocular player; //Rangefinder\n```","code":["_binocs = binocular player; //Rangefinder"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["binocularMagazine","binocularItems","addBinocularItem","removeBinocularItem","removeAllBinocularItems","headgear","goggles","hmd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"binocularItems","operator":null,"title":"binocularItems","type":"command","url":"https://community.bistudio.com/wiki/binocularItems","revid":369611,"updated":"2024-09-26T20:58:03Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns array with all items assigned to the binocular weapon except magazines. Use binocularMagazine command for the latter. This command is used for infantry weapons only.","syntaxes":[{"syntax":"binocularItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [silencer, pointer, optic, bipod]","types":["Array"],"description":"silencer: String - pointer: String - laserpointer or flashlight - optic: String - bipod: String","text":"Array with [silencer, pointer, optic, bipod]\n- silencer: String\n- pointer: String - laserpointer or flashlight\n- optic: String\n- bipod: String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nbinocularItems player;\n```","code":["binocularItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addBinocularItem","removeBinocularItem","removeAllBinocularItems","binocularMagazine","weaponAccessories","weaponAccessoriesCargo","primaryWeaponItems","secondaryWeaponItems","handgunItems","weaponsItems","weaponsItemsCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"binocularMagazine","operator":null,"title":"binocularMagazine","type":"command","url":"https://community.bistudio.com/wiki/binocularMagazine","revid":377189,"updated":"2026-01-01T10:53:24Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Collects all loaded magazines from all binocular muzzles and returns them in Array, otherwise it returns []. This command is used for infantry weapons only.","syntaxes":[{"syntax":"binocularMagazine unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str binocularMagazine player; // [\"Laserbatteries\"]\n```","code":["hint str binocularMagazine player; // [\"Laserbatteries\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["binocularItems","addBinocularItem","removeBinocularItem","removeAllBinocularItems","primaryWeaponMagazine","secondaryWeaponMagazine","handgunMagazine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"blufor","operator":null,"title":"blufor","type":"command","url":"https://community.bistudio.com/wiki/blufor","revid":329284,"updated":"2022-07-27T09:50:34Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the blufor side.","syntaxes":[{"syntax":"blufor","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side player == blufor) then\n{\n    hint \"BLUFOR\";\n};\n```","code":["if (side player == blufor) then\n{\n\thint \"BLUFOR\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["west"],"see_also":["side","civilian","east","independent","opfor","resistance","west"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"boundingBox","operator":null,"title":"boundingBox","type":"command","url":"https://community.bistudio.com/wiki/boundingBox","revid":377835,"updated":"2026-01-03T04:32:05Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a bounding box of given object in model coordinate space, adjusted according to destruction/animation of an object. This command is rather generous on the size estimation, for more precise coordinates use boundingBoxReal.\n\n> [!NOTE]\n> In Arma 3 v1.92 The output of both syntaxes got extended to include bounding sphere diameter. See also sizeOf.","syntaxes":[{"syntax":"boundingBox object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"an array with the extreme points of the model, as well as bounding box sphere diameter. Format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereDiameter].","text":"PositionRelative - an array with the extreme points of the model, as well as bounding box sphere diameter.\nFormat [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereDiameter]."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"clippingType boundingBox object","since":"arma3 1.92","effect":null,"exec":null,"params":[{"name":"clippingType","type":"Number","optional":false,"default":null,"description":"clipping type could be:\n- 0 - ClipVisual (could significantly reduce the size of bounding boxes on buildings)\n- 1 - ClipShadow\n- 2 - ClipGeometry\n- 3 - ClipGeneral (Default, the same type that is used in main syntax)","types":["Number"],"since":null,"text":"clippingType: Number - clipping type could be:\n- 0 - ClipVisual (could significantly reduce the size of bounding boxes on buildings)\n- 1 - ClipShadow\n- 2 - ClipGeometry\n- 3 - ClipGeneral (Default, the same type that is used in main syntax)"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"an array with the extreme points of the model bounding box, as well as bounding box sphere diameter. Format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereDiameter].","text":"PositionRelative - an array with the extreme points of the model bounding box, as well as bounding box sphere diameter.\nFormat [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereDiameter]."},"form":"binary","operator":null,"left":{"text":"clippingType","types":["Number"]},"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _box = boundingBox _abrams;\n```","code":["private _box = boundingBox _abrams;"]},{"text":"```sqf\nhint str (0 boundingBox cursorObject);\n```","code":["hint str (0 boundingBox cursorObject);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sizeOf","boundingBoxReal","boundingCenter","BIS_fnc_boundingBoxDimensions"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"boundingBoxReal","operator":null,"title":"boundingBoxReal","type":"command","url":"https://community.bistudio.com/wiki/boundingBoxReal","revid":378436,"updated":"2026-04-07T21:33:52Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a raw bounding box of given object in model coordinates space. This command is similar to boundingBox but gives more precise measurements.\n\nThe alternative syntax allows to specify clipping type to be used, which in some cases could make the result even more precise.","syntaxes":[{"syntax":"boundingBoxReal object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"the extreme points of the model along Arma 3 v1.92 the bounding box sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]","text":"PositionRelative - the extreme points of the model along Arma 3 v1.92 the bounding box sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"clippingType boundingBoxReal object","since":"arma3 1.92","effect":null,"exec":null,"params":[{"name":"clippingType","type":"Number","optional":false,"default":null,"description":"can be one of:\n- 0 - ClipVisual (can significantly reduce bounding box's size on buildings)\n- 1 - ClipShadow\n- 2 - ClipGeometry\n- 3 - ClipGeneral (same type that is used in the main syntax)","types":["Number"],"since":null,"text":"clippingType: Number - can be one of:\n- 0 - ClipVisual (can significantly reduce bounding box's size on buildings)\n- 1 - ClipShadow\n- 2 - ClipGeometry\n- 3 - ClipGeneral (same type that is used in the main syntax)"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"the extreme points of the model, as well as bounding sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]","text":"PositionRelative - the extreme points of the model, as well as bounding sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]"},"form":"binary","operator":null,"left":{"text":"clippingType","types":["Number"]},"right":{"text":"object","types":["Object"]}},{"syntax":"boundingBoxReal [object, LOD]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution","types":["String","Number"],"since":null,"text":"LOD: String or Number - can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"the extreme points of the model, as well as bounding box sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]","text":"PositionRelative - the extreme points of the model, as well as bounding box sphere radius, in format [[xmin, ymin, zmin], [xmax, ymax, zmax], boundingSphereRadius]"},"form":"unary","operator":null,"left":null,"right":{"text":"[object, LOD]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _bbr = boundingBoxReal vehicle player;\nprivate _p1 = _bbr select 0;\nprivate _p2 = _bbr select 1;\nprivate _maxWidth = abs ((_p2 select 0) - (_p1 select 0));\nprivate _maxLength = abs ((_p2 select 1) - (_p1 select 1));\nprivate _maxHeight = abs ((_p2 select 2) - (_p1 select 2));\n```","code":["private _bbr = boundingBoxReal vehicle player;\nprivate _p1 = _bbr select 0;\nprivate _p2 = _bbr select 1;\nprivate _maxWidth = abs ((_p2 select 0) - (_p1 select 0));\nprivate _maxLength = abs ((_p2 select 1) - (_p1 select 1));\nprivate _maxHeight = abs ((_p2 select 2) - (_p1 select 2));"]},{"text":"```sqf\nhint str (0 boundingBoxReal cursorObject);\n```","code":["hint str (0 boundingBoxReal cursorObject);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["boundingBox","sizeOf","boundingCenter"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"boundingCenter","operator":null,"title":"boundingCenter","type":"command","url":"https://community.bistudio.com/wiki/boundingCenter","revid":377382,"updated":"2026-01-02T06:43:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the position of the original (loaded) center of an object in model coordinates. Despite its name, it has nothing to do with boundingBox or boundingBoxReal, it returns offset where `[0, 0, 0]` was Object Builder / Oxygen 2 when model was created.","syntaxes":[{"syntax":"boundingCenter object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":null,"text":"PositionRelative"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_center = boundingCenter TruckOne;\n```","code":["_center = boundingCenter TruckOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["boundingBox","sizeOf","boundingBoxReal","getPosWorld","setPosWorld","aimPos"],"notes":[{"user":"Sa-Matra","date":"2023-04-20T06:33:26Z","text":"Some objects have boundingCenter in really weird positions. In general this command is borderline useless."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"brakesDisabled","operator":null,"title":"brakesDisabled","type":"command","url":"https://community.bistudio.com/wiki/brakesDisabled","revid":376404,"updated":"2025-10-11T00:55:54Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the status of autobrake (see disableBrakes).","syntaxes":[{"syntax":"brakesDisabled transport","since":null,"effect":null,"exec":null,"params":[{"name":"transport","type":"Object","optional":false,"default":null,"description":"PhysX car or tank","types":["Object"],"since":null,"text":"transport: Object - PhysX car or tank"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if autobrake is disabled","text":"Boolean - true if autobrake is disabled"},"form":"unary","operator":null,"left":null,"right":{"text":"transport","types":["Object"]}}],"examples":[{"text":"```sqf\nif !(brakesDisabled _vehicle) then\n{\n    _vehicle disableBrakes true;\n};\n```","code":["if !(brakesDisabled _vehicle) then\n{\n\t_vehicle disableBrakes true;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableBrakes","awake","isAwake","addTorque","addForce","vectorModelToWorld","vectorModelToWorldVisual","selectionPosition","setVelocityTransformation","setVelocityModelSpace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"break","operator":null,"title":"break","type":"command","url":"https://community.bistudio.com/wiki/break","revid":370194,"updated":"2024-11-06T11:55:55Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Skips all loop iterations (for, forEach, while, findIf etc).","syntaxes":[{"syntax":"break","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// prints 0, 1 and then exits\nfor \"_i\" from 0 to 3 do\n{\n    if (_i == 2) then { break };\n    systemChat str _i;\n};\n```","code":["// prints 0, 1 and then exits\nfor \"_i\" from 0 to 3 do\n{\n\tif (_i == 2) then { break };\n\tsystemChat str _i;\n};"]},{"text":"```sqf\nprivate _moneyHolder = objNull;\n{\n    if (\"Money_roll\" in items _x) then\n    {\n        _moneyHolder = _x;\n        break;\n    };\n} forEach units group player;\n\nif (isNull _moneyHolder) then\n{\n    hint \"We have to find this money.\";\n}\nelse\n{\n    hint format [\"%1 has the money!\", name _moneyHolder];\n};\n```","code":["private _moneyHolder = objNull;\n{\n\tif (\"Money_roll\" in items _x) then\n\t{\n\t\t_moneyHolder = _x;\n\t\tbreak;\n\t};\n} forEach units group player;\n\nif (isNull _moneyHolder) then\n{\n\thint \"We have to find this money.\";\n}\nelse\n{\n\thint format [\"%1 has the money!\", name _moneyHolder];\n};"]},{"text":"```sqf\n0 spawn\n{\n    private _value = 0;\n\n    while { _value < 10 } do\n    {\n        if (_value == 8) then\n        {\n            break; // 8 and 9 will never be printed\n        };\n\n        systemChat str _value ;\n        _value = _value + 1;\n    };\n};\n```","code":["0 spawn\n{\n\tprivate _value = 0;\n\n\twhile { _value < 10 } do\n\t{\n\t\tif (_value == 8) then\n\t\t{\n\t\t\tbreak; // 8 and 9 will never be printed\n\t\t};\n\n\t\tsystemChat str _value ;\n\t\t_value = _value + 1;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["continueWith","continue","breakWith","breakOut"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"breakOut","operator":null,"title":"breakOut","type":"command","url":"https://community.bistudio.com/wiki/breakOut","revid":369282,"updated":"2024-09-03T18:42:47Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Breaks out of the scope with given **name**.\n- An unknown scopeName name will cause the script error `Generic error in expression`\n- If multiple scopes with the same **name** exist, the command will break out the nearest scope. See #Example 3.","syntaxes":[{"syntax":"breakOut name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"name of the scope which was previously set with scopeName. `\"\"` will exit the current scope (see also exitWith)","types":["String"],"since":null,"text":"name: String - name of the scope which was previously set with scopeName. `\"\"` will exit the current scope (see also exitWith)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}},{"syntax":"value breakOut name","since":"arma3 1.48","effect":null,"exec":null,"params":[{"name":"value","type":"Anything","optional":false,"default":null,"description":"a value to return","types":["Anything"],"since":null,"text":"value: Anything - a value to return"},{"name":"name","type":"String","optional":false,"default":null,"description":"name of the scope which was previously set with scopeName. `\"\"` will exit the current scope (see also exitWith)","types":["String"],"since":null,"text":"name: String - name of the scope which was previously set with scopeName. `\"\"` will exit the current scope (see also exitWith)"}],"returns":{"type":"Anything","types":["Anything"],"description":"will return value","text":"Anything - will return **value**"},"form":"binary","operator":null,"left":{"text":"value","types":["Anything"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nscopeName \"main\";\nwhile { true } do {\n    scopeName \"loop1\";\n    while {true} do {\n        scopeName \"loop2\";\n        if (condition1) then {breakTo \"main\"}; // Breaks all scopes and return to \"main\"\n        if (condition2) then {breakOut \"loop2\"}; // Breaks scope named \"loop2\"\n        sleep 1;\n    };\n    sleep 1;\n};\n```","code":["scopeName \"main\";\nwhile { true } do {\n\tscopeName \"loop1\";\n\twhile {true} do {\n\t\tscopeName \"loop2\";\n\t\tif (condition1) then {breakTo \"main\"}; // Breaks all scopes and return to \"main\"\n\t\tif (condition2) then {breakOut \"loop2\"}; // Breaks scope named \"loop2\"\n\t\tsleep 1;\n\t};\n\tsleep 1;\n};"]},{"text":"```sqf\ncall {\n    scopeName \"main\";\n    call {\n        123 breakOut \"main\"\n    };\n    345\n}; // call returns 123\n```","code":["call {\n\tscopeName \"main\";\n\tcall {\n\t\t123 breakOut \"main\"\n\t};\n\t345\n}; // call returns 123"]},{"text":"```sqf\ncall {\n    scopeName \"Main\"; // Parent Main\n    call {\n        scopeName \"Main\"; // Child Main\n        \"String\" breakOut \"Main\"; // Will break out of child main and return \"String\" to parent main\n    };\n};\n```","code":["call {\n\tscopeName \"Main\"; // Parent Main\n\tcall {\n\t\tscopeName \"Main\"; // Child Main\n\t\t\"String\" breakOut \"Main\"; // Will break out of child main and return \"String\" to parent main\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["scopeName","breakTo","exitWith"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"breakTo","operator":null,"title":"breakTo","type":"command","url":"https://community.bistudio.com/wiki/breakTo","revid":364900,"updated":"2024-06-29T14:38:35Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Breaks block to scope named *name*.\n\nScope name can be assigned using the scopeName command.","syntaxes":[{"syntax":"breakTo name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nscopeName \"main\";\nwhile { true } do\n{\n    scopeName \"loop1\";\n    while { true } do\n    {\n        scopeName \"loop2\";\n        if (condition1) then { breakTo \"main\" };    // breaks all scopes and return to \"main\"\n        if (condition2) then { breakOut \"loop2\" };    // breaks scope named \"loop2\"\n        sleep 1;\n    };\n    sleep 1;\n};\n```","code":["scopeName \"main\";\nwhile { true } do\n{\n\tscopeName \"loop1\";\n\twhile { true } do\n\t{\n\t\tscopeName \"loop2\";\n\t\tif (condition1) then { breakTo \"main\" };\t// breaks all scopes and return to \"main\"\n\t\tif (condition2) then { breakOut \"loop2\" };\t// breaks scope named \"loop2\"\n\t\tsleep 1;\n\t};\n\tsleep 1;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["scopeName","breakOut","exitWith"],"notes":[{"user":"Nelis75733126","date":"2017-05-18T18:19:00Z","text":"I wish to clarify the behaviour of this command by saying that the `breakTo` command will literally break the scope in which it has been placed, and continue reading whatever is after and outside of that scope.\n\nExample:\n\n```sqf\nscopeName \"something\";\nif true then\n{\n    breakTo \"something\";\n    _v = 0;    // this line will be skipped\n};\n\n_a = 0;        // this is where script execution will jump to.\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"breakWith","operator":null,"title":"breakWith","type":"command","url":"https://community.bistudio.com/wiki/breakWith","revid":349341,"updated":"2023-11-08T14:53:30Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Skips all loop iterations and immediately returns the given value.","syntaxes":[{"syntax":"breakWith return","since":null,"effect":null,"exec":null,"params":[{"name":"return","type":"Anything","optional":false,"default":null,"description":"value to be returned when iterations are skipped","types":["Anything"],"since":null,"text":"return: Anything - value to be returned when iterations are skipped"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"unary","operator":null,"left":null,"right":{"text":"return","types":["Anything"]}}],"examples":[{"text":"```sqf\n// stops once _i reaches 5 and outputs 0, 1, 2, 3, 4, END\nsystemChat call {\n    for \"_i\" from 0 to 10 do {\n        if (_i == 5) then { breakWith \"END\"; };\n        systemChat str _i;\n    };\n};\n```","code":["// stops once _i reaches 5 and outputs 0, 1, 2, 3, 4, END\nsystemChat call {\n\tfor \"_i\" from 0 to 10 do {\n\t\tif (_i == 5) then { breakWith \"END\"; };\n\t\tsystemChat str _i;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["continueWith","break","continue","breakOut"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"briefingName","operator":null,"title":"briefingName","type":"command","url":"https://community.bistudio.com/wiki/briefingName","revid":310777,"updated":"2022-05-07T20:21:45Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of the current briefing/scenario name.","syntaxes":[{"syntax":"briefingName","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_name = briefingName;\n```","code":["_name = briefingName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionName","worldName","serverName","worldSize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"buildingExit","operator":null,"title":"buildingExit","type":"command","url":"https://community.bistudio.com/wiki/buildingExit","revid":377513,"updated":"2026-01-02T06:50:20Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the given indexed exit in a building. The returned value is in format Position.","syntaxes":[{"syntax":"building buildingExit index","since":null,"effect":null,"exec":null,"params":[{"name":"building","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"building: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Position","types":["Position"],"description":null,"text":"Position"},"form":"binary","operator":null,"left":{"text":"building","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_building buildingExit 0;\n```","code":["_building buildingExit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buildingPos","insideBuilding","BIS_fnc_buildingPositions"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"buildingPos","operator":null,"title":"buildingPos","type":"command","url":"https://community.bistudio.com/wiki/buildingPos","revid":377392,"updated":"2026-01-02T06:44:35Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns position of a given indexed position in a building.","syntaxes":[{"syntax":"building buildingPos index","since":null,"effect":null,"exec":null,"params":[{"name":"building","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"building: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index of a specific position \n\n> [!NOTE]\n> **Arma 3:** Since v1.56 index `-1` will return all available building positions.","types":["Number"],"since":null,"text":"index: Number - index of a specific position \n\n> [!NOTE]\n> **Arma 3:** Since v1.56 index `-1` will return all available building positions."}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"a single building position. If building position with given index does not exist, `[0, 0, 0]` is returned > [!NOTE] > Arma 3: Since v1.56 it can also return an array of all building positions in format PositionAGL if index that was given is `-1`.","text":"PositionAGL - a single building position. If building position with given index does not exist, `[0, 0, 0]` is returned\n\n> [!NOTE]\n> **Arma 3:** Since v1.56 it can also return an array of all building positions in format PositionAGL if index that was given is `-1`."},"form":"binary","operator":null,"left":{"text":"building","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_soldier setPosATL (_house1 buildingPos 2);\n```","code":["_soldier setPosATL (_house1 buildingPos 2);"]},{"text":"```sqf\n_allpositions = nearestBuilding player buildingPos -1;\n```","code":["_allpositions = nearestBuilding player buildingPos -1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestBuilding","nearestObject","nearestObjects","nearObjects","insideBuilding","buildingExit","position","setPos","setWaypointHousePosition","waypointHousePosition","BIS_fnc_buildingPositions"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"buldozer_enableRoadDiag","operator":null,"title":"buldozer enableRoadDiag","type":"command","url":"https://community.bistudio.com/wiki/buldozer_enableRoadDiag","revid":310178,"updated":"2022-05-05T13:10:30Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables road diagnostics in buldozer.","syntaxes":[{"syntax":"buldozer_enableRoadDiag enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nbuldozer_enableRoadDiag true;\n```","code":["buldozer_enableRoadDiag true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buldozer_loadNewRoads","buldozer_isEnabledRoadDiag"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"buldozer_isEnabledRoadDiag","operator":null,"title":"buldozer isEnabledRoadDiag","type":"command","url":"https://community.bistudio.com/wiki/buldozer_isEnabledRoadDiag","revid":310886,"updated":"2022-05-07T20:28:58Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if road diagnostics are enabled in buldozer.","syntaxes":[{"syntax":"buldozer_isEnabledRoadDiag","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if enabled, otherwise false","text":"Boolean - true if enabled, otherwise false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_isEnabled = buldozer_isEnabledRoadDiag;\n```","code":["_isEnabled = buldozer_isEnabledRoadDiag;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buldozer_loadNewRoads","buldozer_enableRoadDiag"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"buldozer_loadNewRoads","operator":null,"title":"buldozer loadNewRoads","type":"command","url":"https://community.bistudio.com/wiki/buldozer_loadNewRoads","revid":318691,"updated":"2022-05-13T09:21:20Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Generates new roads. Working only in buldozer.","syntaxes":[{"syntax":"buldozer_loadNewRoads path","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"path: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"path","types":["String"]}}],"examples":[{"text":"```sqf\n_loaded = buldozer_loadNewRoads \"C:/A3/Map_Stratis/data/roads/\"\n```","code":["_loaded = buldozer_loadNewRoads \"C:/A3/Map_Stratis/data/roads/\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buldozer_reloadOperMap"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"buldozer_reloadOperMap","operator":null,"title":"buldozer reloadOperMap","type":"command","url":"https://community.bistudio.com/wiki/buldozer_reloadOperMap","revid":318695,"updated":"2022-05-13T09:21:20Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Reload oper map visible in costMap diag tool. Working only in buldozer.","syntaxes":[{"syntax":"buldozer_reloadOperMap","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nbuldozer_reloadOperMap;\n```","code":["buldozer_reloadOperMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buldozer_loadNewRoads"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"buttonAction","operator":null,"title":"buttonAction","type":"command","url":"https://community.bistudio.com/wiki/buttonAction","revid":376407,"updated":"2025-10-11T00:59:12Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the action assigned to a control of the currently active user dialog. Can be used for buttons and active texts. Read Arma: GUI Configuration for more information about user dialogs and controls.","syntaxes":[{"syntax":"buttonAction idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"button IDC","types":["Number"],"since":null,"text":"idc: Number - button IDC"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"buttonAction control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nbuttonSetAction [100, { player exec \"reply.sqs\" }];\n_action = buttonAction 100; // Returns { player exec \"reply.sqs\" };\n```","code":["buttonSetAction [100, { player exec \"reply.sqs\" }];\n_action = buttonAction 100; // Returns { player exec \"reply.sqs\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buttonSetAction"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"buttonSetAction","operator":null,"title":"buttonSetAction","type":"command","url":"https://community.bistudio.com/wiki/buttonSetAction","revid":364179,"updated":"2024-05-05T10:46:46Z","groups":["GUI Control"],"status":"deprecated","replaced_by":["ctrlAddEventHandler"],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"> [!CAUTION]\n> This information is **obsolete**. Use ctrlAddEventHandler instead.\n\nSet the action of a control of the currently active user dialog. The script statement is executed on button release and `_this` is available, but contains \"\"; See Arma: GUI Configuration for more information about user dialogs. Works with:\n- CT_BUTTON\n- CT_XBUTTON\n- CT_ACTIVETEXT\n- CT_SHORTCUTBUTTON","syntaxes":[{"syntax":"buttonSetAction [idc, action]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"button IDC","types":["Number"],"since":null,"text":"idc: Number - button IDC"},{"name":"action","type":"String","optional":false,"default":null,"description":"**SQS** code body that should be executed when the button/active text is clicked","types":["String"],"since":null,"text":"action: String - **SQS** code body that should be executed when the button/active text is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, action]","types":["Array"]}},{"syntax":"control buttonSetAction action","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"button control","types":["Control"],"since":null,"text":"control:  Control - button control"},{"name":"action","type":"String","optional":false,"default":null,"description":"**SQS** code body that should be executed when the button/active text is clicked","types":["String"],"since":null,"text":"action:  String - **SQS** code body that should be executed when the button/active text is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nbuttonSetAction [100, \"player exec \"\"reply.sqs\"\"\"];\n```","code":["buttonSetAction [100, \"player exec \"\"reply.sqs\"\"\"];"]},{"text":"```sqf\n_ctrl buttonSetAction \"if (alive bob) then {hint 'alive'} else {hint 'dead'}\"; // SQF but SQS compatible, see SQS\n```","code":["_ctrl buttonSetAction \"if (alive bob) then {hint 'alive'} else {hint 'dead'}\"; // SQF but SQS compatible, see SQS"]},{"text":"Script is SQS:\n\n```sqs\n_control buttonSetAction \"hint format ['Is SQS: %1', !isNil '_time']\"\n```","code":["_control buttonSetAction \"hint format ['Is SQS: %1', !isNil '_time']\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buttonAction"],"notes":[{"user":"Kungtotte","date":"2009-10-05T16:23:00Z","text":"When using buttonSetAction for an ActiveText control from a script, you cannot use any variables local to the script in it.\n\n```sqf\n/* This will print 'any bar' in the hint box,\n since _foo has no value according to buttonSetAction */\n\n_foo = \"foo\";\nbuttonSetAction [100, \"hint format [\"\"%1 bar\"\", _foo];\"];\n```"},{"user":"Molaron","date":"2016-02-15T10:15:00Z","text":"This command does not overwrite the button's action that was set via \"action\" in the `.hpp` of the dialog."},{"user":"Nomisum","date":"2016-06-11T19:24:00Z","text":"To use variables local to the defining script, a syntax like the one below needs to be used:\n\n```sqf\n_foo = \"foo\";\nbuttonSetAction [100, format [\"hint '%1 bar'\", _foo]];\n```\n\nworks! thanks to Kronzky for commenting this workaround in the VBS wiki"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"cadetMode","operator":null,"title":"cadetMode","type":"command","url":"https://community.bistudio.com/wiki/cadetMode","revid":325302,"updated":"2022-07-10T22:51:20Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"**Prior to Arma 3** it returns if the player is currently playing in cadet or veteran mode.","syntaxes":[{"syntax":"cadetMode","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when playing in cadet mode, false when playing in veteran mode","text":"Boolean - true when playing in cadet mode, false when playing in veteran mode"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"SQS Syntax: \n\n```sqs\n? (cadetMode) : _AIsoldier setSkill 0.1\n```","code":["? (cadetMode) : _AIsoldier setSkill 0.1"]},{"text":"SQF Syntax: \n\n```sqf\nif (cadetMode) then { _AIsoldier setSkill 0.1 };\n```","code":["if (cadetMode) then { _AIsoldier setSkill 0.1 };"]}],"multiplayer":null,"problems":"> [!NOTE]\n> This command returns the status of the global difficulty `showCadetHints`.\n>\n> Use `difficulty in [0, 1]` to achieve the **original intended** functionality!","aliases":[],"see_also":["hintCadet","difficulty"],"notes":[{"user":"Killswitch","date":"2009-12-01T17:49:00Z","text":"In Arma 2, this command will return true if the difficulty level is set to \"Recruit\" or \"Regular\". It returns false for the \"Veteran\" and \"Expert\" difficulty levels."}],"categories":[]},{"name":"calculatePath","operator":null,"title":"calculatePath","type":"command","url":"https://community.bistudio.com/wiki/calculatePath","revid":376951,"updated":"2026-01-01T04:02:40Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Spawns an agent that will execute an AI path calculation and fire the `\"PathCalculated\"` event handler.\nThe vehicle type to simulate could be one of the following presets:\n- `\"man\"`: C_man_1\n- `\"car\"`: C_Offroad_01_F\n- `\"tank\"`: B_MBT_01_cannon_F\n- `\"wheeled_APC\"`: B_APC_Tracked_01_rcws_F\n- `\"boat\"`: C_Rubberboat\n- `\"plane\"`: B_Plane_CAS_01_dynamicLoadout_F\n- `\"helicopter\"`: B_Heli_Light_01_F\n\nIf the given vehicle type is not one of the above presets, the exact given type is used.\n\n> [!IMPORTANT]\n> In order to guarantee that the event handler is added to the result of this command before the path is calculated, use isNil to run the code in an Unscheduled Environment:\n>\n> ```sqf\n> isNil { calculatePath [\"man\", \"safe\", _startPos, _endPos] addEventHandler [\"PathCalculated\", { hint str _this }] };\n> ```\n\n> [!NOTE]\n> If an exact path is desired, it is recommended to avoid this command and simply use the PathCalculated event handler.\n> Paths to long distances are typically calculated in segments. This command only gives the first calculated segment.","syntaxes":[{"syntax":"calculatePath [type, behaviour, from, to]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"vehicle type to simulate (see description)","types":["String"],"since":null,"text":"type: String - vehicle type to simulate (see description)"},{"name":"behaviour","type":"String","optional":false,"default":null,"description":"AI behaviour, one of \"CARELESS\", \"SAFE\", \"AWARE\", \"COMBAT\" or \"STEALTH\"","types":["String"],"since":null,"text":"behaviour: String - AI behaviour, one of \"CARELESS\", \"SAFE\", \"AWARE\", \"COMBAT\" or \"STEALTH\""},{"name":"from","type":"Array","optional":false,"default":null,"description":"start position in format [x,y,z]","types":["Array"],"since":null,"text":"from: Array - start position in format [x,y,z]"},{"name":"to","type":"Array","optional":false,"default":null,"description":"end position in format [x,y,z]","types":["Array"],"since":null,"text":"to: Array - end position in format [x,y,z]"}],"returns":{"type":"Object","types":["Object"],"description":"the agent to add the `\"PathCalculated\"` Event Handler to.","text":"Object - the agent to add the `\"PathCalculated\"` Event Handler to."},"form":"unary","operator":null,"left":null,"right":{"text":"[type, behaviour, from, to]","types":["Array"]}}],"examples":[{"text":"```sqf\ncalculatePath [\"car\", \"safe\", [2150.67,5778.19,0], [2184.11,5802.28,0]];\n```","code":["calculatePath [\"car\", \"safe\", [2150.67,5778.19,0], [2184.11,5802.28,0]];"]},{"text":"Draws the path from South West to North East of Agia Marina:\n\n```sqf\n(calculatePath [\"man\", \"safe\", [2832.9,5927.79,0], [3107.46,6036.61,0]]) addEventHandler [\"PathCalculated\", {\n    {\n        private _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n        _marker setMarkerType \"mil_dot\";\n        _marker setMarkerText str _forEachIndex;\n    } forEach (_this select 1);\n}];\n```","code":["(calculatePath [\"man\", \"safe\", [2832.9,5927.79,0], [3107.46,6036.61,0]]) addEventHandler [\"PathCalculated\", {\n\t{\n\t\tprivate _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n\t\t_marker setMarkerType \"mil_dot\";\n\t\t_marker setMarkerText str _forEachIndex;\n\t} forEach (_this select 1);\n}];"]},{"text":"Alternative usage of calculatePath functionality that is free of the double execution bug (and calculatePath command):\n\n```sqf\nprivate _agent = createAgent [typeOf player, position player, [], 0, \"NONE\"];\n_agent addEventHandler [\"PathCalculated\",\n{ \n    { \n        private _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n        _marker setMarkerType \"mil_dot\";\n        _marker setMarkerText str _forEachIndex;\n    } \n    forEach (_this select 1);\n}];\n_agent setDestination [player getRelPos [500, 0], \"LEADER PLANNED\", true];\n```","code":["private _agent = createAgent [typeOf player, position player, [], 0, \"NONE\"];\n_agent addEventHandler [\"PathCalculated\",\n{ \n\t{ \n\t\tprivate _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n\t\t_marker setMarkerType \"mil_dot\";\n\t\t_marker setMarkerText str _forEachIndex;\n\t} \n\tforEach (_this select 1);\n}];\n_agent setDestination [player getRelPos [500, 0], \"LEADER PLANNED\", true];"]},{"text":"Same as above but for a vehicle:\n\n```sqf\nprivate _agent = createAgent [typeOf player, position player, [], 0, \"NONE\"];\nprivate _car = \"B_Quadbike_01_F\" createVehicle position player;\n_agent moveInDriver _car;\n_agent addEventHandler [\"PathCalculated\",\n{ \n    { \n        private _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n        _marker setMarkerType \"mil_dot\";\n        _marker setMarkerText str _forEachIndex;\n    } \n    forEach (_this select 1);\n}];\n_agent setDestination [player getRelPos [500, 0], \"LEADER PLANNED\", true];\n```","code":["private _agent = createAgent [typeOf player, position player, [], 0, \"NONE\"];\nprivate _car = \"B_Quadbike_01_F\" createVehicle position player;\n_agent moveInDriver _car;\n_agent addEventHandler [\"PathCalculated\",\n{ \n\t{ \n\t\tprivate _marker = createMarker [\"marker\" + str _forEachIndex, _x];\n\t\t_marker setMarkerType \"mil_dot\";\n\t\t_marker setMarkerText str _forEachIndex;\n\t} \n\tforEach (_this select 1);\n}];\n_agent setDestination [player getRelPos [500, 0], \"LEADER PLANNED\", true];"]}],"multiplayer":null,"problems":"For some unknown reason, the \"PathCalculated\" Event Handler is fired twice, first with the calculated path and second with an array consisting of 2 elements, which are identical and are equal to the end point.\nSee **Example 3 & 4** for a workaround.","aliases":[],"see_also":["setDriveOnPath","setDestination"],"notes":[{"user":"Tankbuster","date":"2019-06-06T10:28:00Z","text":"When using this command to get the predicted path of vehicles driving and having them stay on roads (not go cross country) is important,\nthe best vehicle to use is \"wheeled_APC\" and careless behaviour."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.94","Scripting Commands"]},{"name":"calculatePlayerVisibilityByFriendly","operator":null,"title":"calculatePlayerVisibilityByFriendly","type":"command","url":"https://community.bistudio.com/wiki/calculatePlayerVisibilityByFriendly","revid":309210,"updated":"2022-05-03T22:23:29Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.84"}],"since":{"game":"arma3","name":"Arma 3","version":"1.84"},"arma3_since":"1.84","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets if friendly units will calculate player's visibility or not. Default value is false.","syntaxes":[{"syntax":"calculatePlayerVisibilityByFriendly calculate","since":null,"effect":null,"exec":null,"params":[{"name":"calculate","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"calculate: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"calculate","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncalculatePlayerVisibilityByFriendly true;\n```","code":["calculatePlayerVisibilityByFriendly true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCalculatePlayerVisibilityByFriendly","knowsAbout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.84","Scripting Commands"]},{"name":"call","operator":null,"title":"call","type":"command","url":"https://community.bistudio.com/wiki/call","revid":373729,"updated":"2025-06-23T13:37:41Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds given set of compiled instructions to the current stack and waits for it to finish and return, provides an option to pass arguments to the executed Code.\nSee Scheduler to learn more about how the code is executed and behaves.","syntaxes":[{"syntax":"call code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"compiled instructions\n\n> [!NOTE]\n> **Operation Flashpoint:** Operation Flashpoint takes String.\n\n> [!NOTE]\n> This way of calling has access to its parent scope's `_this`, as all it does is creating a scope.","types":["Code"],"since":null,"text":"code: Code - compiled instructions\n\n> [!NOTE]\n> **Operation Flashpoint:** Operation Flashpoint takes String.\n\n> [!NOTE]\n> This way of calling has access to its parent scope's `_this`, as all it does is creating a scope."}],"returns":{"type":"Anything","types":["Anything"],"description":"the last value given in the function is returned - see the topic Function for more information","text":"Anything - the last value given in the function is returned - see the topic Function for more information"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}},{"syntax":"args call code","since":null,"effect":null,"exec":null,"params":[{"name":"args","type":"Anything","optional":false,"default":null,"description":"arguments that are passed to the function in the `_this` variable.","types":["Anything"],"since":null,"text":"args: Anything - arguments that are passed to the function in the `_this` variable."},{"name":"code","type":"Code","optional":false,"default":null,"description":"compiled instructions\n\n> [!NOTE]\n> **Operation Flashpoint:** Operation Flashpoint takes String.","types":["Code"],"since":null,"text":"code: Code - compiled instructions\n\n> [!NOTE]\n> **Operation Flashpoint:** Operation Flashpoint takes String."}],"returns":{"type":"Anything","types":["Anything"],"description":"the last value given in the function is returned. See the topic Function for more information.","text":"Anything - the last value given in the function is returned. See the topic Function for more information."},"form":"binary","operator":null,"left":{"text":"args","types":["Anything"]},"right":{"text":"code","types":["Code"]}},{"syntax":"hashMapObj call [methodName, arguments]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"hashMapObj","type":"HashMap","optional":false,"default":null,"description":"the HashMap (not necessarily created through createHashMapObject) to call the method on","types":["HashMap"],"since":null,"text":"hashMapObj: HashMap - the HashMap (not necessarily created through createHashMapObject) to call the method on"},{"name":"methodName","type":"String","optional":false,"default":null,"description":"the name of the method to call (the method must be defined in *hashMapObj*; see createHashMapObject)","types":["String"],"since":null,"text":"methodName: String - the name of the method to call (the method must be defined in *hashMapObj*; see createHashMapObject)"},{"name":"arguments","type":"Anything","optional":true,"default":"parent scope's `_this`","description":"arguments passed to the method in the `_this` variable","types":["Anything"],"since":null,"text":"arguments: Anything - (Optional, default parent scope's `_this`) arguments passed to the method in the `_this` variable"}],"returns":{"type":"Anything","types":["Anything"],"description":"the value returned by the methodName method","text":"Anything - the value returned by the *methodName* method"},"form":"binary","operator":null,"left":{"text":"hashMapObj","types":["HashMap"]},"right":{"text":"[methodName, arguments]","types":["Array"]}}],"examples":[{"text":"```sqf\ncall { hint str 123; };\n```","code":["call { hint str 123; };"]},{"text":"```sqf\n123 call { hint str _this; };\n```","code":["123 call { hint str _this; };"]},{"text":"```sqf\n_sum = [1, 2] call { (_this select 0) + (_this select 1); };\nhint str _sum; // displays 3\n```","code":["_sum = [1, 2] call { (_this select 0) + (_this select 1); };\nhint str _sum; // displays 3"]},{"text":"```sqf\n123 call compile \"hint str _this;\";\n```","code":["123 call compile \"hint str _this;\";"]},{"text":"```sqf\n_result = 123 call compile preprocessFileLineNumbers \"myFile.sqf\";\n```","code":["_result = 123 call compile preprocessFileLineNumbers \"myFile.sqf\";"]},{"text":"```sqf\nprivate _hashMapObj = createHashMapObject [[\n    [\"MyMethod\", { systemChat (\"MyMethod arguments: \" + str _this); }]\n]];\n\n_hashMapObj call [\"MyMethod\", [\"Hello there\", player, 123]]; // hints 'MyMethod arguments: [\"Hello there\", player, 123]'\n```","code":["private _hashMapObj = createHashMapObject [[\n\t[\"MyMethod\", { systemChat (\"MyMethod arguments: \" + str _this); }]\n]];\n\n_hashMapObj call [\"MyMethod\", [\"Hello there\", player, 123]]; // hints 'MyMethod arguments: [\"Hello there\", player, 123]'"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["spawn","execVM","canSuspend","compile","compileScript","preprocessFile","remoteExec","remoteExecCall"],"notes":[{"user":"Leopard20","date":"2021-11-05T10:52:49Z","text":"Contrary to a widespread misconception in the community, call doesn't necessarily execute the code in the Unscheduled Environment. Call simply means: \"execute the code here\", just like how you execute a code using then (`if (true) then _code`) or do. Therefore it does not change the environment:\n\n| *call* executed in environment: | Resulting environment of the code: |\n|---|---|\n| Scheduled | Scheduled |\n| Unscheduled | Unscheduled |\n\nThis means that doing something like this (which is misused very often):\n\n```sqf\nprivate _handle = _params spawn MY_fnc_Function;\nwaitUntil { scriptDone _handle };\n```\n\nis not needed, because a lot of performance would be wasted compared to simply doing this:\n\n```sqf\n_params call MY_fnc_Function;\n```\n\nwhich does the exact same thing as the previous code, except no new *\"scheduler thread\"* is created and the function executes seamlessly, plus the added performance benefit as mentioned before.\n\nIf it is necessary to execute a code in the Unscheduled Environment, one can use isNil instead:\n\n```sqf\nisNil {_params call MY_fnc_Function}; // MY_fnc_Function is always executed unscheduled, regardless of the current environment\n```\n\nor if there are no parameters, one can simply do this:\n\n```sqf\nisNil MY_fnc_Function\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"callExtension","operator":null,"title":"callExtension","type":"command","url":"https://community.bistudio.com/wiki/callExtension","revid":378445,"updated":"2026-04-14T14:09:53Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Calls custom .dll also known as Extension. The name of the extension is the name of the extension .dll without \".dll\" part (or without \"_x64.dll\" part on 64-bit Arma). For example if the file is 'myExtension.dll' the name of the extension will be \"myExtension\". For 64-bit extensions, the name of the extension doesn't need to change and is still \"myExtension\". The game will automatically look for 'myExtension_x64.dll' when you use 64-bit Arma exe.\n\nThis command is blocking, meaning that the game will wait for the extension to return before continuing. This may cause FPS drop if extension is not optimised. If extension takes too long, consider making asynchronous extension, where the result of the work of the extension is collected in a separate call.\n\nCurrently there is no limit how much data you can send to the extension. However there is a limit on how much data you can return from extension in one call. The limit is known to the extension and is passed in `int outputSize`. The limit may or may not change in the future and is currently 10240 bytes. It is up to extension designer to handle multipart results if returned data exceeds output limit.\n\nSince Arma 3 v1.68 it is possible to pass array of arguments to extensions. The array of arguments could be anything and all elements will be converted to strings, however you might want to only send simple types like Booleans, Strings, Numbers and Arrays of all of the above. There is currently a limit on how many arguments can be sent and it is 2048 (since Arma 3 v1.92; previous limit: 1024). However an argument could be an Array itself, in this case extension maker will have to provide additional methods for parsing such arguments.\n\nPossible error codes:\n- 101: SYNTAX_ERROR_WRONG_PARAMS_SIZE\n- 102: SYNTAX_ERROR_WRONG_PARAMS_TYPE\n- 201: PARAMS_ERROR_TOO_MANY_ARGS\n- 301: EXECUTION_WARNING_TAKES_TOO_LONG\n- Arma 3 v2.22 400: EXTENSION_LOAD_FAILED\n- Arma 3 v2.22 403: EXTENSION_BLOCKED_BY_BATTLEYE\n- Arma 3 v2.22 404: EXTENSION_NOT_FOUND\n- Arma 3 v2.22 412: EXTENSION_BLOCKED_BY_SCRIPT\n- Arma 3 v2.22 415: EXTENSION_WRONG_ARCHITECTURE\nEach error will have entry in .rpt file with more details.\n\nThe extension execution timeout, after which `301: EXECUTION_WARNING_TAKES_TOO_LONG` warning is issued, is hardcoded on clients and is 1000.0 milliseconds (1 second). On the server the default limit is also 1 second, however it is possible to set custom limit with `callExtReportLimit` param (see Server Options).\n\nIf an extension with the given name cannot be found (or it is found but doesn't implement the required interface properly / at all) the following error will be written into the RPT (In this example the given dll-name was \"MyExtension\"):\n`14:27:07 CallExtension 'MyExtension' could not be found`\n\nIf an extension is not whitelisted with BattlEye (see Extensions for more info) it will be blocked on clients running with enabled BattlEye protection. RPT message outputted however is a little obscure:\n`21:35:04 Call extension 'MyExtension' could not be loaded: Insufficient system resources exist to complete the requested service`\n\nSince Arma 3 v1.70, `RVExtensionVersion` interface (see source code example below) has been added, which is called by the engine on extension load and expects extension version. This interface is designed to work with both, Linux and Windows. The max buffer size is 32 bytes. The version information will then appear in .rpt file like so:\n`19:06:36 CallExtension loaded: test_extension (.\\test_extension.dll) [1.0.0.1]`\n\nFor more information see Extensions.\n\nLinux specific\n\nWhile on Windows the extension name is case-insensitive, on Linux the extension name is case-sensitive and should match the name of the .so file exactly (minus \".so\" part).\n\n> [!IMPORTANT]\n> If a user has **anti-virus software real time protection running**, this could cause brand new extension to stutter the game and return with `EXECUTION_WARNING_TAKES_TOO_LONG` when executed for the first time, because of the AV software scanning.\n> After the extension is whitelisted by AV this should go away until a new version of the extension is installed.\n> Perhaps a dummy call to the extension on init should be considered as a feature of implementation to account for that.\n\n**Extension Context**\n\nSince Arma 3 v2.12 the engine will call the `RVExtensionContext` method (if it exists, see #Example 4) and pass the following data:\n- `steamID` of the client calling extension getPlayerUID or \"0\"\n- `fileSource` from which the extension was executed or \"\" if done on the fly\n- `missionName` missionNameSource\n- `serverName` serverName","syntaxes":[{"syntax":"extension callExtension function","since":null,"effect":null,"exec":null,"params":[{"name":"extension","type":"String","optional":false,"default":null,"description":"extension name","types":["String"],"since":null,"text":"extension: String - extension name"},{"name":"function","type":"String","optional":false,"default":null,"description":"data sent to the extension","types":["String"],"since":null,"text":"function: String - data sent to the extension"}],"returns":{"type":"String","types":["String"],"description":"data sent back from extension; If the extensiion was not found an empty String will be returned","text":"String - data sent back from extension; If the extensiion was not found an empty String will be returned"},"form":"binary","operator":null,"left":{"text":"extension","types":["String"]},"right":{"text":"function","types":["String"]}},{"syntax":"extension callExtension [function, arguments]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"extension","type":"String","optional":false,"default":null,"description":"extension name","types":["String"],"since":null,"text":"extension: String - extension name"},{"name":"function","type":"String","optional":false,"default":null,"description":"extension function identifier","types":["String"],"since":null,"text":"function: String - extension function identifier"},{"name":"arguments","type":"Array of Anything","optional":false,"default":null,"description":"function arguments. Each element will be converted to String automatically. Current allowed max length of this array is 2048 (since Arma 3 v1.92; previous limit: 1024)","types":["Array","Anything"],"since":null,"text":"arguments: Array of Anything - function arguments. Each element will be converted to String automatically. Current allowed max length of this array is 2048 (since Arma 3 v1.92; previous limit: 1024)"}],"returns":{"type":"Array with [result, returnCode, errorCode]","types":["Array"],"description":"result: String - data sent back from extension. It is up to extension maker what it is. - returnCode: Number - integer return from extension method. It is up to extension maker to define it. - errorCode: Number - error code in case of command error (see description). 0 means no errors.","text":"Array with [result, returnCode, errorCode]\n- result: String - data sent back from extension. It is up to extension maker what it is.\n- returnCode: Number - integer return from extension method. It is up to extension maker to define it.\n- errorCode: Number - error code in case of command error (see description). 0 means no errors."},"form":"binary","operator":null,"left":{"text":"extension","types":["String"]},"right":{"text":"[function, arguments]","types":["Array"]}}],"examples":[{"text":"```sqf\n_return = \"myExtension\" callExtension \"stringToBeParsed\";\n```","code":["_return = \"myExtension\" callExtension \"stringToBeParsed\";"]},{"text":"```sqf\n_result = \"test_extension\" callExtension str weapons player;\n_result = \"test_extension\" callExtension [\"fnc1\", getUnitLoadout player];\n_result = \"test_extension\" callExtension [\"fnc2\", magazinesAmmoFull player];\n_result = \"test_extension\" callExtension [\"fnc1\", [weapons player, magazines player]];\n```","code":["_result = \"test_extension\" callExtension str weapons player;\n_result = \"test_extension\" callExtension [\"fnc1\", getUnitLoadout player];\n_result = \"test_extension\" callExtension [\"fnc2\", magazinesAmmoFull player];\n_result = \"test_extension\" callExtension [\"fnc1\", [weapons player, magazines player]];"]},{"text":"```sqf\n_result = \"test_extension\" callExtension [\"fnc1\", [1, \"two\", true, [4, \"five\", false]]];\nparseSimpleArray (_result select 0) params [\"_number\",\"_string\",\"_boolean\",\"_array\"];\nsystemChat str [_number,_string,_boolean,_array];\n```\n\nSource Code ()\n\nThis is an example of an extension compatible with both syntaxes. When using 1st syntax, the data is just copied from input to output. When using alt syntax, the arguments are parsed and then assembled back into string array in 2 ways: fnc1 and fnc2. fnc1 is a fraction faster.\n\n```cpp\n#include <string>\n#include <vector>\n#include <iterator>\n#include <sstream>\n\n#define CURRENT_VERSION \"1.0.0.1\"\n\nextern \"C\"\n{\n    //--- Engine called on extension load\n    __declspec (dllexport) void __stdcall RVExtensionVersion(char *output, int outputSize);\n    //--- STRING callExtension STRING\n    __declspec (dllexport) void __stdcall RVExtension(char *output, int outputSize, const char *function);\n    //--- STRING callExtension ARRAY\n    __declspec (dllexport) int __stdcall RVExtensionArgs(char *output, int outputSize, const char *function, const char **args, int argsCnt);\n}\n\n//--- Extension version information shown in .rpt file\nvoid __stdcall RVExtensionVersion(char *output, int outputSize)\n{\n    //--- max outputSize is 32 bytes\n    strncpy_s(output, outputSize, CURRENT_VERSION, _TRUNCATE);\n}\n\n//--- name callExtension function\nvoid __stdcall RVExtension(char *output, int outputSize, const char *function)\n{\n    std::string str = function;\n    strncpy_s(output, outputSize, (\"Input Was: \" + str).c_str(), _TRUNCATE);\n}\n\n//--- name callExtension [function, args]\nint __stdcall RVExtensionArgs(char *output, int outputSize, const char *function, const char **args, int argsCnt)\n{\n    if (strcmp(function, \"fnc1\") == 0)\n    {\n        //--- Manually assemble output array\n        int i = 0;\n        std::string str = \"[\";\n\n        //--- Each argument can be accessed via args[n]\n        if (argsCnt > 0)\n            str += args[i++];\n\n        while (i < argsCnt)\n        {\n            str += \",\";\n            str += args[i++];\n        }\n\n        str += \"]\";\n\n        //--- Extension result\n        strncpy_s(output, outputSize, str.c_str(), _TRUNCATE);\n\n        //--- Extension return code\n        return 100;\n    }\n\n    else if (strcmp(function, \"fnc2\") == 0)\n    {\n        //--- Parse args into vector\n        std::vector<std::string> vec(args, std::next(args, argsCnt));\n\n        std::ostringstream oss;\n        if (!vec.empty())\n        {\n            //--- Assemble output array\n            std::copy(vec.begin(), vec.end() - 1, std::ostream_iterator<std::string>(oss, \",\"));\n            oss << vec.back();\n        }\n\n        //--- Extension result\n        strncpy_s(output, outputSize, (\"[\" + oss.str() + \"]\").c_str(), _TRUNCATE);\n\n        //--- Extension return code\n        return 200;\n    }\n\n    else\n    {\n        strncpy_s(output, outputSize, \"Avaliable Functions: fnc1, fnc2\", outputSize - 1);\n        return -1;\n    }\n}\n```","code":["_result = \"test_extension\" callExtension [\"fnc1\", [1, \"two\", true, [4, \"five\", false]]];\nparseSimpleArray (_result select 0) params [\"_number\",\"_string\",\"_boolean\",\"_array\"];\nsystemChat str [_number,_string,_boolean,_array];"]},{"text":"Since Arma 3 v2.12: \n\n```sqf\nhint (\"myExtContext\" callExtension \"\");\n```\n\nHere is a minimal example:\n\n```cpp\n#include <string>\n#include <vector>\n#include <iterator>\n#include <sstream>\n#include <iomanip>\n\nBOOL APIENTRY DllMain(    HMODULE hModule,\n                        DWORD ul_reason_for_call,\n                        LPVOID lpReserved)\n{\n    switch (ul_reason_for_call)\n    {\n        case DLL_PROCESS_ATTACH:\n        case DLL_THREAD_ATTACH:\n        case DLL_THREAD_DETACH:\n        case DLL_PROCESS_DETACH:\n            break;\n    }\n    return TRUE;\n}\n\nstd::vector<std::string> contextInfo;\n\nextern \"C\"\n{\n    //--- User entry point\n    __declspec (dllexport) void __stdcall RVExtension(char *output, int outputSize, const char *function);\n    //--- Engine passed context\n    __declspec (dllexport) void __stdcall RVExtensionContext(const char **args, int argsCnt);\n}\n\n//--- name callExtension function\nvoid __stdcall RVExtension(char *output, int outputSize, const char *function)\n{\n    //--- Not used here\n    (void)function;\n\n    if (!contextInfo.empty())\n    {\n        std::ostringstream oss;\n        const char qt = '\"';\n\n        for (auto it = contextInfo.begin(); it != contextInfo.end() - 1; ++it)\n            oss << std::quoted(*it, qt, qt) << \",\";\n        oss << std::quoted(contextInfo.back(), qt, qt);\n\n        //--- Send context info back\n        strncpy_s(output, outputSize, (\"[\" + oss.str() + \"]\").c_str(), _TRUNCATE);\n    }\n}\n\n//--- Context is executed first, copy it\nvoid __stdcall RVExtensionContext(const char **args, int argsCnt)\n{\n    contextInfo.assign(args, std::next(args, argsCnt));\n}\n```","code":["hint (\"myExtContext\" callExtension \"\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["freeExtension","call","compile","parseSimpleArray","Extensions"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camCommand","operator":null,"title":"camCommand","type":"command","url":"https://community.bistudio.com/wiki/camCommand","revid":369082,"updated":"2024-09-02T20:36:38Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Executes a command on the given *camera / actor* object. Known commands:\n\n| All cameras | \"Camera\" | \"Seagull\" | \"CamCurator\" |\n|---|---|---|---|\n| - `\"manual on\"`<br>- `\"manual off\"` | - `\"inertia on\"`<br>- `\"inertia off\"` | - `\"landed\"` lands the seagull<br>- `\"airborne\"` makes the seagull fly | - `\"maxPitch (x)\"` (number, in degrees)<br>- `\"minPitch (x)\"` (number, in degrees)<br>- `\"speedDefault (x)\"` (number)<br>- `\"speedMax (x)\"` (number)<br>- `\"ceilingHeight (x)\"` (number, in meters, ASL)<br>- `\"atl (x)\"` (on/off)<br>- `\"surfaceSpeed (x)\"` (on/off) |\n\n> [!NOTE]\n> The camCommand effect is immediate and does not need camCommit/camCommitPrepared.","syntaxes":[{"syntax":"camera camCommand command","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"see camCreate","types":["Object"],"since":null,"text":"camera: Object - see camCreate"},{"name":"command","type":"String","optional":false,"default":null,"description":"see description","types":["String"],"since":null,"text":"command: String - see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\n_camera camCommand \"manual on\";\n```","code":["_camera camCommand \"manual on\";"]},{"text":"```sqf\nprivate _camera = \"CamCurator\" camCreate [0,0,0];\n_camera camCommand \"maxPitch 89\";\n_camera camCommand \"minPitch -89\";\n_camera camCommand \"speedDefault 0.1\";\n_camera camCommand \"speedMax 2\";\n_camera camCommand \"ceilingHeight 5000\";\n_camera camCommand \"atl off\";\n_camera camCommand \"surfaceSpeed off\";\n```","code":["private _camera = \"CamCurator\" camCreate [0,0,0];\n_camera camCommand \"maxPitch 89\";\n_camera camCommand \"minPitch -89\";\n_camera camCommand \"speedDefault 0.1\";\n_camera camCommand \"speedMax 2\";\n_camera camCommand \"ceilingHeight 5000\";\n_camera camCommand \"atl off\";\n_camera camCommand \"surfaceSpeed off\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cameraEffect","camCreate","camCommit"],"notes":[],"categories":[]},{"name":"camCommit","operator":null,"title":"camCommit","type":"command","url":"https://community.bistudio.com/wiki/camCommit","revid":325309,"updated":"2022-07-10T23:02:07Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Smoothly conduct the changes that were assigned to a camera within the given time. If the time is set to zero, the changes are done immediately. For `camPrepareXXX` commands use camCommitPrepared.","syntaxes":[{"syntax":"camera camCommit time","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"time","type":"Number","optional":false,"default":null,"description":"time in seconds during which the changes shall be done","types":["Number"],"since":null,"text":"time: Number - time in seconds during which the changes shall be done"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"time","types":["Number"]}}],"examples":[{"text":"SQS Syntax:\n\n```sqs\n; create a camera object\n_cam = \"camera\" camCreate [5600,4800,10]\n_cam camSetTarget player\n_cam cameraEffect [\"internal\", \"BACK\"]\n_cam camCommit 0\n\n; smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [5680,4720,20]\n_cam camCommit 6\n@camCommitted _cam\n\n; proceed\n```","code":["; create a camera object\n_cam = \"camera\" camCreate [5600,4800,10]\n_cam camSetTarget player\n_cam cameraEffect [\"internal\", \"BACK\"]\n_cam camCommit 0\n\n; smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [5680,4720,20]\n_cam camCommit 6\n@camCommitted _cam\n\n; proceed"]},{"text":"SQF Syntax:\n\n```sqf\nprivate \"_cam\";\n\n// create a camera object\n_cam = \"camera\" camCreate [position player select 0, position player select 1, 2];\n_cam camSetTarget player;\n_cam cameraEffect [\"internal\", \"BACK\"];\n_cam camCommit 0;\n\n// smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [position player select 0, (position player select 1) + 10, 20];\n_cam camCommit 6;\nwaitUntil { camCommitted _cam; };\n```","code":["private \"_cam\";\n\n// create a camera object\n_cam = \"camera\" camCreate [position player select 0, position player select 1, 2];\n_cam camSetTarget player;\n_cam cameraEffect [\"internal\", \"BACK\"];\n_cam camCommit 0;\n\n// smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [position player select 0, (position player select 1) + 10, 20];\n_cam camCommit 6;\nwaitUntil { camCommitted _cam; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCommitted","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camCommitPrepared","operator":null,"title":"camCommitPrepared","type":"command","url":"https://community.bistudio.com/wiki/camCommitPrepared","revid":349291,"updated":"2023-11-08T14:51:57Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Smoothly conducts the changes that were assigned to a camera within the given time. If the time is set to zero, the changes are done immediately.\nThis command is for use with `camPrepareXXX` commands. For the normal cam command use camCommit.","syntaxes":[{"syntax":"camera camCommitPrepared time","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"time","type":"Number","optional":false,"default":null,"description":"time in seconds in which the changes shall be done","types":["Number"],"since":null,"text":"time: Number - time in seconds in which the changes shall be done"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"time","types":["Number"]}}],"examples":[{"text":"```sqf\n// create a camera object\n_cam = \"camera\" camCreate [5600, 4800, 10];\n_cam camPrepareTarget player;\n_cam cameraEffect [\"internal\", \"BACK\"];\n_cam camCommitPrepared 0;\n\n// smoothly move the camera to its new position in 6 seconds\n_cam camPreparePos [5680, 4720, 20];\n_cam camCommitPrepared 6;\nwaitUntil { camCommitted _cam };\n\n// proceed\n```","code":["// create a camera object\n_cam = \"camera\" camCreate [5600, 4800, 10];\n_cam camPrepareTarget player;\n_cam cameraEffect [\"internal\", \"BACK\"];\n_cam camCommitPrepared 0;\n\n// smoothly move the camera to its new position in 6 seconds\n_cam camPreparePos [5680, 4720, 20];\n_cam camCommitPrepared 6;\nwaitUntil { camCommitted _cam };\n\n// proceed"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCommitted","camCommit"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camCommitted","operator":null,"title":"camCommitted","type":"command","url":"https://community.bistudio.com/wiki/camCommitted","revid":325310,"updated":"2022-07-10T23:05:00Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the conduction of the last camCommit call already finished.","syntaxes":[{"syntax":"camCommitted camera","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the last camCommit already finished, false if not","text":"Boolean - true if the last camCommit already finished, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"camera","types":["Object"]}}],"examples":[{"text":"SQS:\n\n```sqs\n; create a camera object\n_cam = \"camera\" camCreate [5600,4800,10]\n_cam camSetTarget player\n_cam cameraEffect [\"internal\", \"BACK\"]\n_cam camCommit 0\n\n; smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [5680,4720,20]\n_cam camCommit 6\n@camCommitted _cam\n\n; proceed\n```","code":["; create a camera object\n_cam = \"camera\" camCreate [5600,4800,10]\n_cam camSetTarget player\n_cam cameraEffect [\"internal\", \"BACK\"]\n_cam camCommit 0\n\n; smoothly move the camera to its new position in 6 seconds\n_cam camSetPos [5680,4720,20]\n_cam camCommit 6\n@camCommitted _cam\n\n; proceed"]},{"text":"SQF:\n\n```sqf\n_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, -5, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 0;\n\nwaitUntil { camCommitted _cam };\n\n_cam camSetTarget player;\n_cam camSetRelPos [90, 25, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 5;\n\nwaitUntil {camCommitted _cam};\n\n_cam camSetTarget player;\n_cam camSetRelPos [-90, -5, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 5;\n```","code":["_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, -5, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 0;\n\nwaitUntil { camCommitted _cam };\n\n_cam camSetTarget player;\n_cam camSetRelPos [90, 25, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 5;\n\nwaitUntil {camCommitted _cam};\n\n_cam camSetTarget player;\n_cam camSetRelPos [-90, -5, 10];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCommit"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camConstuctionSetParams","operator":null,"title":"camConstuctionSetParams","type":"command","url":"https://community.bistudio.com/wiki/camConstuctionSetParams","revid":377514,"updated":"2026-01-02T06:50:21Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets construction camera parameters. To work with \"camconstruct\" object.\n\n> [!IMPORTANT]\n> Beware: camCon**stu**ctionSetParams [sic].","syntaxes":[{"syntax":"camera camConstuctionSetParams [position, radius, maxAboveLand]","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"},{"name":"maxAboveLand","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"maxAboveLand: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"[position, radius, maxAboveLand]","types":["Array"]}}],"examples":[{"text":"```sqf\n_camera camConstuctionSetParams [getPos player, 50, 20];\n```","code":["_camera camConstuctionSetParams [getPos player, 50, 20];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","cameraEffect"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camCreate","operator":null,"title":"camCreate","type":"command","url":"https://community.bistudio.com/wiki/camCreate","revid":377423,"updated":"2026-01-02T06:45:34Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Create a camera or a seagull object on the given position. The creation happens immediately and doesn't wait for camCommit.\n\nAmong other commands, cameraEffect must be used to enter the camera's view and camDestroy to delete the created camera. See also Camera Control.\n\n> [!IMPORTANT]\n> - Other objects can be created this way, but vehicles created with camCreate cannot be entered\n> - Any unit created with camCreate will remain static\n> - Unlike createVehicle, objects are created exactly at the given position, without consideration of the surrounding objects.","syntaxes":[{"syntax":"type camCreate position","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"camera type, one of the following:\n- \"camera\"\n- \"seagull\" (a crow in Arma 2)\n- \"camconstruct\"\n- \"camcurator\" (Since Arma 3 Zeus)\n- \"crowe\" (crow - Arma 3)\n- or any vehicle class suitable to be spawned with camera","types":["String"],"since":null,"text":"type: String - camera type, one of the following:\n- \"camera\"\n- \"seagull\" (a crow in Arma 2)\n- \"camconstruct\"\n- \"camcurator\" (Since Arma 3 Zeus)\n- \"crowe\" (crow - Arma 3)\n- or any vehicle class suitable to be spawned with camera"},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":"position at which to create the object","types":["PositionAGL"],"since":null,"text":"position: PositionAGL - position at which to create the object"}],"returns":{"type":"Object","types":["Object"],"description":"the created camera","text":"Object - the created camera"},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"position","types":["PositionAGL"]}}],"examples":[{"text":"```sqf\n_cam = \"camera\" camCreate (ASLToAGL eyePos player);\n```","code":["_cam = \"camera\" camCreate (ASLToAGL eyePos player);"]},{"text":"```sqf\n_flr = \"flare\" camCreate (position _myPlane); // works too\n```","code":["_flr = \"flare\" camCreate (position _myPlane); // works too"]}],"multiplayer":"camCreated objects are only visible locally (meaning they are client-side effects).","problems":null,"aliases":[],"see_also":["camCommand","camDestroy","camSetFocus","camCommit","setPiPEffect","createVehicle","createUnit","showCinemaBorder","cameraEffect","cameraEffectEnableHUD"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camDestroy","operator":null,"title":"camDestroy","type":"command","url":"https://community.bistudio.com/wiki/camDestroy","revid":369081,"updated":"2024-09-02T20:36:38Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Destroys camera object created with camCreate. This command doesn't need camCommit.\n\n> [!IMPORTANT]\n> Destroying camera object does not terminate camera effect automatically, use cameraEffect prior to deleting the camera (see Example 2)","syntaxes":[{"syntax":"camDestroy object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ncamDestroy _cam;\n```","code":["camDestroy _cam;"]},{"text":"```sqf\n_cam cameraEffect [\"terminate\",\"back\"];\ncamDestroy _cam;\n```","code":["_cam cameraEffect [\"terminate\",\"back\"];\ncamDestroy _cam;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","cameraEffect"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"cameraEffect","operator":null,"title":"cameraEffect","type":"command","url":"https://community.bistudio.com/wiki/cameraEffect","revid":336915,"updated":"2023-01-04T16:43:59Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the given effect on the given camera. If you want to switch the screen directly to the first-person, aiming, third-person or group view of an object, use switchCamera instead. The effect type \"Terminate\" is used to exit the current camera view and switch back to the player's view. Does not need camCommit.\n\nSince Arma 3 v1.74, it is possible to terminate individual r2t source. For example:\n\n```sqf\ncam cameraEffect [\"terminate\", \"back\", \"rtt1\"]; // would terminate \"rtt1\" r2t source\ncam cameraEffect [\"terminate\", \"back\"]; // would terminate all r2t sources\n```\n\n> [!IMPORTANT]\n> One cannot mix and match cameraEffect and can either have multiple r2t cameras or a single camera for the whole screen.\n> If one needs a background stream overlayed with r2t streams, this could be achieved by creating an object and using switchCamera to switch to it for background image, while using cameraEffect for r2t overlay (see #Example 4).","syntaxes":[{"syntax":"camera cameraEffect [effectName, effectPosition, r2tName]","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"effectName","type":"String","optional":false,"default":null,"description":"the effect type (defined in main config or CfgCameraEffects >> Array). Defaults are: `\"Internal\"`, `\"External\"`, `\"Fixed\"`, `\"FixedWithZoom\"`, `\"Terminate\"`","types":["String"],"since":null,"text":"effectName: String - the effect type (defined in main config or CfgCameraEffects >> Array). Defaults are: `\"Internal\"`, `\"External\"`, `\"Fixed\"`, `\"FixedWithZoom\"`, `\"Terminate\"`"},{"name":"effectPosition","type":"String","optional":false,"default":null,"description":"position of the effect. Can be one of:\n- `\"TOP\"`\n- `\"LEFT\"`\n- `\"RIGHT\"`\n- `\"FRONT\"`\n- `\"BACK\"`\n- `\"LEFT FRONT\"`\n- `\"RIGHT FRONT\"`\n- `\"LEFT BACK\"`\n- `\"RIGHT BACK\"`\n- `\"LEFT TOP\"`\n- `\"RIGHT TOP\"`\n- `\"FRONT TOP\"`\n- `\"BACK TOP\"`\n- `\"BOTTOM\"`\nThese are usually used with \"Fixed\" and \"FixedWithZoom\" effect types. If not sure which position to use, set it to `\"BACK\"`.","types":["String"],"since":null,"text":"effectPosition: String - position of the effect. Can be one of:\n- `\"TOP\"`\n- `\"LEFT\"`\n- `\"RIGHT\"`\n- `\"FRONT\"`\n- `\"BACK\"`\n- `\"LEFT FRONT\"`\n- `\"RIGHT FRONT\"`\n- `\"LEFT BACK\"`\n- `\"RIGHT BACK\"`\n- `\"LEFT TOP\"`\n- `\"RIGHT TOP\"`\n- `\"FRONT TOP\"`\n- `\"BACK TOP\"`\n- `\"BOTTOM\"`\nThese are usually used with \"Fixed\" and \"FixedWithZoom\" effect types. If not sure which position to use, set it to `\"BACK\"`."},{"name":"r2tName","type":"String","optional":true,"default":null,"description":"Render To Texture surface reference","types":["String"],"since":null,"text":"r2tName: String - (Optional) Render To Texture surface reference"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"[effectName, effectPosition, r2tName]","types":["Array"]}}],"examples":[{"text":"```sqf\n_cam cameraEffect [\"internal\", \"BACK\"];\n```","code":["_cam cameraEffect [\"internal\", \"BACK\"];"]},{"text":"```sqf\n_cam cameraEffect [\"internal\", \"back\", \"rendersurface\"];\n```","code":["_cam cameraEffect [\"internal\", \"back\", \"rendersurface\"];"]},{"text":"```sqf\ncam = \"seagull\" camCreate (player modelToWorld [0,0,100]);\ncam cameraEffect [\"FIXED\", \"LEFT TOP\"];\ncam camCommand \"MANUAL ON\";\n```","code":["cam = \"seagull\" camCreate (player modelToWorld [0,0,100]);\ncam cameraEffect [\"FIXED\", \"LEFT TOP\"];\ncam camCommand \"MANUAL ON\";"]},{"text":"```sqf\n_ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscPicture\", -1];\n_ctrl ctrlSetPosition [0.5, 0, 0.5, 0.5];\n_ctrl ctrlSetText \"#(argb,512,512,1)r2t(rtt1,1.0)\";\n_ctrl ctrlCommit 0;\n_cam1 = \"camera\" camCreate (ASLToAGL eyePos player vectorAdd [0, -10, 0]);\n_cam1 cameraEffect [\"Internal\", \"Back\", \"rtt1\"];\n_cam2 = \"Land_HandyCam_F\" createVehicle [0,0,0];\n_cam2 enableSimulation false;\n_cam2 setPos (ASLToAGL eyePos player vectorAdd [0, 10, 0]);\n_cam2 setDir (_cam2 getDir player);\nswitchCamera _cam2;\n```","code":["_ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscPicture\", -1];\n_ctrl ctrlSetPosition [0.5, 0, 0.5, 0.5];\n_ctrl ctrlSetText \"#(argb,512,512,1)r2t(rtt1,1.0)\";\n_ctrl ctrlCommit 0;\n_cam1 = \"camera\" camCreate (ASLToAGL eyePos player vectorAdd [0, -10, 0]);\n_cam1 cameraEffect [\"Internal\", \"Back\", \"rtt1\"];\n_cam2 = \"Land_HandyCam_F\" createVehicle [0,0,0];\n_cam2 enableSimulation false;\n_cam2 setPos (ASLToAGL eyePos player vectorAdd [0, 10, 0]);\n_cam2 setDir (_cam2 getDir player);\nswitchCamera _cam2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchCamera","cameraView","cameraOn","setPiPEffect","camCreate","cameraEffectEnableHUD","camUseNVG","setCamUseTI"],"notes":[{"user":"Killzone_Kid","date":"2016-10-30T16:40:00Z","text":"Types of camera for CfgCameraEffects config:\n- CamExternal (CamInterpolated)  // linked directly with object\n- CamStatic  // fixed point in space\n- CamStaticWithZoom  // fixed point in space\n- CamChained  // chained\n- CamTerminate  // terminate\n- CamInternal  // internal view"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"cameraEffectEnableHUD","operator":null,"title":"cameraEffectEnableHUD","type":"command","url":"https://community.bistudio.com/wiki/cameraEffectEnableHUD","revid":341143,"updated":"2023-05-13T22:12:46Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable / disable showing of in-game UI during currently active camera effect. By default the HUD is off, which will make results of drawIcon3D invisible, for example.","syntaxes":[{"syntax":"cameraEffectEnableHUD enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncameraEffectEnableHUD true;\n```","code":["cameraEffectEnableHUD true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showHUD","shownMap","visibleMap","forceMap","shownGPS","shownWatch","shownCompass","shownUAVFeed","camCreate","cameraEffect"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cameraInterest","operator":null,"title":"cameraInterest","type":"command","url":"https://community.bistudio.com/wiki/cameraInterest","revid":320962,"updated":"2022-05-13T10:04:50Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return camera interest for given entity, as set by setCameraInterest, or as autodetected.","syntaxes":[{"syntax":"cameraInterest entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\ncamInterest = cameraInterest myUnit;\n```","code":["camInterest = cameraInterest myUnit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCameraInterest"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cameraOn","operator":null,"title":"cameraOn","type":"command","url":"https://community.bistudio.com/wiki/cameraOn","revid":347206,"updated":"2023-09-05T08:55:52Z","groups":["Camera Control","Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the vehicle to which the camera is attached. If you need the person, see focusOn.","syntaxes":[{"syntax":"cameraOn","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":"vehicle","text":"Object - vehicle"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_object = cameraOn;\n```","code":["_object = cameraOn;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchCamera","cameraView","cameraEffect","focusOn","remoteControl"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Remote Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cameraView","operator":null,"title":"cameraView","type":"command","url":"https://community.bistudio.com/wiki/cameraView","revid":378176,"updated":"2026-03-03T19:06:53Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns mode of active camera view. Mode is one of:\n- \"INTERNAL\" (1st person)\n- \"EXTERNAL\" (3rd person)\n- \"GUNNER\" (optics / sights)\n- \"GROUP\" (commander view)","syntaxes":[{"syntax":"cameraView","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (cameraOn == _vehicle && cameraView == \"EXTERNAL\") then\n{\n    _vehicle switchCamera \"INTERNAL\";\n};\n```","code":["if (cameraOn == _vehicle && cameraView == \"EXTERNAL\") then\n{\n\t_vehicle switchCamera \"INTERNAL\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchCamera","cameraOn","cameraEffect"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"campaignConfigFile","operator":null,"title":"campaignConfigFile","type":"command","url":"https://community.bistudio.com/wiki/campaignConfigFile","revid":347514,"updated":"2023-09-28T02:08:51Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns root of campaign description.ext entries hierarchy.","syntaxes":[{"syntax":"campaignConfigFile","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_config = campaignConfigFile;\n```","code":["_config = campaignConfigFile;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","missionConfigFile"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPreload","operator":null,"title":"camPreload","type":"command","url":"https://community.bistudio.com/wiki/camPreload","revid":369112,"updated":"2024-09-03T10:28:47Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Preloads the scene for the prepared camera with given timeout after which preloading is aborted. Max timeout is 30 seconds. Timeout of 0 means max timeout of 30 seconds as well. \n\n> [!NOTE]\n> This command will read prepared params set with camPrepareFOV, camPreparePos and camPrepareTarget, so no camCommitPrepared is necessary. If camPrepareFOV is not set, the default value is 1. If camPrepareTarget (for direction) and camPreparePos (for position) are not set, current direction and position of the camera are used. The prepared camera preload will preload main camera as well. cameraEffect is not necessary","syntaxes":[{"syntax":"camera camPreload timeout","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"timeout","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"timeout: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"timeout","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camPreload 5;\n```","code":["_camera camPreload 5;"]},{"text":"Preload camera around player to avoid stuttering on optics zooming:\n\n```sqf\n0 spawn \n{\n    _cam = \"camera\" camCreate (player selectionPosition \"camera\");\n    for \"_i\" from 0 to 359 do\n    {\n        _cam setDir _i;\n        _cam camPrepareFov 0.25;\n        _cam camPreload 0;\n        waitUntil { camPreloaded _cam };\n    };\n    camDestroy _cam;\n};\n```","code":["0 spawn \n{\n\t_cam = \"camera\" camCreate (player selectionPosition \"camera\");\n\tfor \"_i\" from 0 to 359 do\n\t{\n\t\t_cam setDir _i;\n\t\t_cam camPrepareFov 0.25;\n\t\t_cam camPreload 0;\n\t\twaitUntil { camPreloaded _cam };\n\t};\n\tcamDestroy _cam;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreloaded","preloadCamera"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPreloaded","operator":null,"title":"camPreloaded","type":"command","url":"https://community.bistudio.com/wiki/camPreloaded","revid":321907,"updated":"2022-05-22T12:22:10Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the camera has finished preloading.","syntaxes":[{"syntax":"camPreloaded camera","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"camera","types":["Object"]}}],"examples":[{"text":"```sqf\nif (camPreloaded _camera) exitWith { hint \"loaded\" };\n```","code":["if (camPreloaded _camera) exitWith { hint \"loaded\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cameraEffect","camCreate","camCommit"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareBank","operator":null,"title":"camPrepareBank","type":"command","url":"https://community.bistudio.com/wiki/camPrepareBank","revid":352123,"updated":"2024-02-01T23:25:04Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera bank angle.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camPrepareBank bank","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"bank","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"bank: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"bank","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camPrepareBank -0.1;\n```","code":["_camera camPrepareBank -0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareDir","operator":null,"title":"camPrepareDir","type":"command","url":"https://community.bistudio.com/wiki/camPrepareDir","revid":352231,"updated":"2024-02-01T23:26:09Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera heading.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camPrepareDir direction","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"direction","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"direction: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"direction","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camPrepareDir 150;\n```","code":["_camera camPrepareDir 150;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareDive","operator":null,"title":"camPrepareDive","type":"command","url":"https://community.bistudio.com/wiki/camPrepareDive","revid":352190,"updated":"2024-02-01T23:25:57Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera dive angle.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camPrepareDive dive","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"dive","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"dive: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"dive","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camPrepareDive -0.1;\n```","code":["_camera camPrepareDive -0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareFocus","operator":null,"title":"camPrepareFocus","type":"command","url":"https://community.bistudio.com/wiki/camPrepareFocus","revid":323042,"updated":"2022-06-28T21:43:09Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"focusRange is . Prepares the camera focus blur.\n\n**[-1,1]** will reset default values (auto focusing), **[-1,-1]** will disable postprocessing (all is focused). Needs the call of camCommitPrepared to be conducted.","syntaxes":[{"syntax":"camera camPrepareFocus [distance, blur]","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"distance","type":"Number","optional":false,"default":null,"description":"blur distance","types":["Number"],"since":null,"text":"distance: Number - blur distance"},{"name":"blur","type":"Number","optional":false,"default":null,"description":"blur intensity","types":["Number"],"since":null,"text":"blur: Number - blur intensity"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"[distance, blur]","types":["Array"]}}],"examples":[{"text":"```sqf\n_camera camPrepareFocus [50, 1];\n```","code":["_camera camPrepareFocus [50, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared","camSetFocus"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareFov","operator":null,"title":"camPrepareFov","type":"command","url":"https://community.bistudio.com/wiki/camPrepareFov","revid":323072,"updated":"2022-06-28T21:43:12Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera field of view (zoom). The default zoom level is 0.75, 0.01 is the nearest and 2 the furthest zoom value. The angle of the field of view is *atan(FOV)*2* radians when in 4:3 aspect ratio. Needs the call of camCommitPrepared to be conducted.","syntaxes":[{"syntax":"camera camPrepareFov fieldOfView","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"fieldOfView","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"fieldOfView: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"fieldOfView","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camPrepareFov 0.1;\n```","code":["_camera camPrepareFov 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetFov","camPreload","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareFovRange","operator":null,"title":"camPrepareFovRange","type":"command","url":"https://community.bistudio.com/wiki/camPrepareFovRange","revid":369600,"updated":"2024-09-26T20:16:06Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera field of view range for auto zooming.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camPrepareFovRange [minFovRange, maxFovRange]","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"minFovRange","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"minFovRange: Number"},{"name":"maxFovRange","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"maxFovRange: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"[minFovRange, maxFovRange]","types":["Array"]}}],"examples":[{"text":"```sqf\n_camera camPrepareFovRange [0.1, 0.5];\n```","code":["_camera camPrepareFovRange [0.1, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPreparePos","operator":null,"title":"camPreparePos","type":"command","url":"https://community.bistudio.com/wiki/camPreparePos","revid":377762,"updated":"2026-01-03T00:59:06Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera position. Needs the call of camCommitPrepared to be conducted.","syntaxes":[{"syntax":"camera camPreparePos position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\n_camera camPreparePos getPos player;\n```","code":["_camera camPreparePos getPos player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared","camSetPos"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareRelPos","operator":null,"title":"camPrepareRelPos","type":"command","url":"https://community.bistudio.com/wiki/camPrepareRelPos","revid":377385,"updated":"2026-01-02T06:43:54Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera position relative to the current position of the currect target (see camPrepareTarget). Needs the call of camCommitPrepared to be conducted.","syntaxes":[{"syntax":"camera camPrepareRelPos position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"position","type":"PositionRelative","optional":false,"default":null,"description":null,"types":["PositionRelative"],"since":null,"text":"position: PositionRelative"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\n_camera camPrepareRelPos [10,5,-2];\n```","code":["_camera camPrepareRelPos [10,5,-2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared","camSetRelPos"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camPrepareTarget","operator":null,"title":"camPrepareTarget","type":"command","url":"https://community.bistudio.com/wiki/camPrepareTarget","revid":318609,"updated":"2022-05-13T09:21:11Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Prepares the camera target to a position or to a target. Needs the call of camCommitPrepared to be conducted.","syntaxes":[{"syntax":"camera camPrepareTarget position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"position","type":"Position","optional":false,"default":null,"description":"target location","types":["Position"],"since":null,"text":"position: Position - target location"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["Position"]}},{"syntax":"camera camPrepareTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_camera camPrepareTarget getPos player;\n```","code":["_camera camPrepareTarget getPos player;"]},{"text":"```sqf\n_camera camPrepareTarget player;\n```","code":["_camera camPrepareTarget player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camCommitPrepared","camSetTarget"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camSetBank","operator":null,"title":"camSetBank","type":"command","url":"https://community.bistudio.com/wiki/camSetBank","revid":352087,"updated":"2024-02-01T23:24:46Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets camera bank angle. Does not commit changes.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camSetBank bank","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"bank","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"bank: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"bank","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camSetBank -0.1;\n```","code":["_camera camSetBank -0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetDive","setVectorUp"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camSetDir","operator":null,"title":"camSetDir","type":"command","url":"https://community.bistudio.com/wiki/camSetDir","revid":377244,"updated":"2026-01-02T04:23:26Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the orientation of the given camera in the direction of the given vector. Needs camCommit. Since Arma 3 v0.50, only the second syntax with a Vector3D is available.","syntaxes":[{"syntax":"camera camSetDir azimuth","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"azimuth","type":"Number","optional":false,"default":null,"description":"camera azimuth","types":["Number"],"since":null,"text":"azimuth: Number - camera azimuth"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"azimuth","types":["Number"]}},{"syntax":"camera camSetDir direction","since":"arma3 0.50","effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"direction","type":"Vector3D","optional":false,"default":null,"description":"direction of camera. Must be a valid vector.","types":["Vector3D"],"since":null,"text":"direction: Vector3D - direction of camera. Must be a valid vector."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"direction","types":["Vector3D"]}}],"examples":[{"text":"Since Arma 3:\n\n```sqf\nprivate _pos1 = player modelToWorld [0, 5, 5];\nprivate _pos2 = player modelToWorld [0, 50, 50];\n\nprivate _cam = \"camera\" camCreate _pos1;\n_cam cameraEffect [\"INTERNAL\", \"BACK\"];\n\n_cam camSetPos _pos2;\n_cam camSetDir (_pos2 vectorFromTo _pos1);\n_cam camCommit 5;\nwaitUntil { camCommitted _cam };\n\n_cam camSetPos _pos1;\n_cam camCommit 5;\n```","code":["private _pos1 = player modelToWorld [0, 5, 5];\nprivate _pos2 = player modelToWorld [0, 50, 50];\n\nprivate _cam = \"camera\" camCreate _pos1;\n_cam cameraEffect [\"INTERNAL\", \"BACK\"];\n\n_cam camSetPos _pos2;\n_cam camSetDir (_pos2 vectorFromTo _pos1);\n_cam camCommit 5;\nwaitUntil { camCommitted _cam };\n\n_cam camSetPos _pos1;\n_cam camCommit 5;"]},{"text":"Before Arma 3:\n\n```sqf\nprivate _pos1 = player modelToWorld [0, 5, 5];\nprivate _pos2 = player modelToWorld [0, 50, 50];\n\nprivate _cam = \"camera\" camCreate _pos1;\n_cam cameraEffect [\"INTERNAL\", \"BACK\"];\n\n_cam camSetPos _pos2;\n_cam camSetDir 180;\n_cam camCommit 5;\nwaitUntil { camCommitted _cam };\n\n_cam camSetPos _pos1;\n_cam camCommit 5;\n```","code":["private _pos1 = player modelToWorld [0, 5, 5];\nprivate _pos2 = player modelToWorld [0, 50, 50];\n\nprivate _cam = \"camera\" camCreate _pos1;\n_cam cameraEffect [\"INTERNAL\", \"BACK\"];\n\n_cam camSetPos _pos2;\n_cam camSetDir 180;\n_cam camCommit 5;\nwaitUntil { camCommitted _cam };\n\n_cam camSetPos _pos1;\n_cam camCommit 5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["direction","setDir","camSetTarget","getCameraViewDirection"],"notes":[{"user":"Killzone_Kid","date":"2016-05-09T19:47:00Z","text":"cameraEffect \"INTERNAL\" works better than \"EXTERNAL\" with this command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camSetDive","operator":null,"title":"camSetDive","type":"command","url":"https://community.bistudio.com/wiki/camSetDive","revid":352204,"updated":"2024-02-01T23:26:03Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets camera dive angle. Does not commit changes.\n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camSetDive dive","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"dive","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"dive: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"dive","types":["Number"]}}],"examples":[{"text":"```sqf\n_camera camSetDive -0.1;\n```","code":["_camera camSetDive -0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetBank","setVectorUp"],"notes":[{"user":"Kronzky","date":"2010-04-15T18:29:00Z","text":"Command is non-functional.\n\nInstead use setVectorUp or [this user function](http://forums.bistudio.com/showthread.php?t=67384) in Armed Assault.\n\n```sqf\n// Get Pitch and Bank\n// By General Barron (aw_barron@hotmail.com) and vektorboson\n// Parameters: object\n// Returns: [pitch, bank]\n// Returns the pitch and bank of an object, in degrees.\n// Yaw can be found using the getdir command.\n// Pitch is 0 when the object is level; 90 when pointing straight\n// up; and -90 when pointing straight down.\n// Bank is 0 when level; 90 when the object is rolled to the right,\n// -90 when rolled to the left, and 180 when rolled upside down.\n\n// extract parameters\nprivate [\"_obj\", \"_pitch\", \"_bank\", \"_yaw\", \"_vdir\", \"_vup\", \"_sign\", \"_rotate\"];\n_obj = _this;\n// find the yaw (direction) of the object\n// note that map compass directions go CW, while coordinate (vector) directions go CCW\n// so when we rotate vectors by this much (below), we are actually adjusting the vector as though the object were pointing north\n_yaw = getDir _obj;\n\n//----------------------------\n// function to rotate a 2d vector around the origin\n//----------------------------\n_rotate =\n{\n    private [\"_v\", \"_d\", \"_x\", \"_y\"];\n\n    // extract parameters\n    _v = +(_this select 0); // we don't want to modify the originally passed vector\n    _d = _this select 1;\n\n    // extract old x/y values\n    _x = _v select 0;\n    _y = _v select 1;\n    // if vector is 3d, we don't want to mess up the last element\n    _v set [0, (cos _d)*_x - (sin _d)*_y];\n    _v set [1, (sin _d)*_x + (cos _d)*_y];\n    // return new vector\n    _v;\n};\n//----------------------------\n// find pitch\n//----------------------------\n// get vector dir (pitch)\n_vdir = vectorDir _obj;\n\n// rotate X & Y around the origin according to the object's yaw (direction)\n// we will then be left with the objects vectordir if it were facing north\n_vdir = [_vdir, _yaw] call _rotate;\n\n// if we reverse the process we used to set pitch when facing north, we can now get pitch\nif ((_vdir select 1) != 0) then\n{\n    _pitch = atan ((_vdir select 2) / (_vdir select 1));\n}\nelse\n{\n    // we need a fail-safe here to prevent divide-by-zero errors\n    // if X is zero, that means pitch is +/-90, we just need to figure out which one\n    if ((_vdir select 2) >= 0) then { _pitch = 90 } else { _pitch = -90 };\n};\n\n//----------------------------\n// find bank\n//----------------------------\n// get vector up (bank)\n_vup = vectorUp _obj;\n\n// rotate X & Y around the origin according to the object's yaw (direction)\n// we will then be left with the objects vectorup if it were facing north\n_vup = [_vup, _yaw] call _rotate;\n\n// rotate Y & Z around according to the object's pitch\n_vup = [_vup select 0] + ([[_vup select 1, _vup select 2], 360 - _pitch] call _rotate);\n\n// if we reverse the process we used to set bank when facing north, we can now get bank\nif ((_vup select 2) != 0) then\n{\n    _bank = atan ((_vup select 0) / (_vup select 2));\n}\nelse\n{\n    // we need a fail-safe here to prevent divide-by-zero errors\n    // if Z is zero, that means bank is +/-90, we just need to figure out which one\n    if ((_vdir select 2) >= 0) then { _bank = 90 } else { _bank = -90 };\n};\n\n// if we are rolled over (abs bank > 90), we need to adjust our result\nif ((_vup select 2) < 0) then\n{\n    _sign = [1, -1] select (_bank < 0);\n    _bank = _bank - _sign*180;\n};\n\n//----------------------------\n// return value\n//----------------------------\n[_pitch, _bank];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camSetFocus","operator":null,"title":"camSetFocus","type":"command","url":"https://community.bistudio.com/wiki/camSetFocus","revid":377681,"updated":"2026-01-02T09:02:47Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets camera focus range. It does not automatically commit changes (see camCommit). Use [-1, -1] to disable focus completely.","syntaxes":[{"syntax":"camera camSetFocus focusRange","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"},{"name":"focusRange","type":"Array with [distance, blur]","optional":false,"default":null,"description":"Array with [distance, blur]\n- distance: Number\n- blur: Number -  sets the camera focus blur","types":["Array"],"since":null,"text":"focusRange: Array with [distance, blur]\n- distance: Number\n- blur: Number -  sets the camera focus blur"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"focusRange","types":["Array"]}}],"examples":[{"text":"```sqf\n_camera camSetFocus [50, 1];\n```","code":["_camera camSetFocus [50, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","camCommand","camDestroy","camCommit","camPrepareFocus"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camSetFov","operator":null,"title":"camSetFov","type":"command","url":"https://community.bistudio.com/wiki/camSetFov","revid":318602,"updated":"2022-05-13T09:21:10Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set the zoom level (**F**ield **O**f **V**iew) of the given camera.\n\nThe zoom level is from *`0.01`* for the nearest and *`8.5`* for the furthest zoom value, with a default zoom level of *`0.75`*\n\nThe angle of the field of view is *`atan(FOV)*2`* radians when in 4:3 aspect ratio. Needs the call of camCommit to be conducted.","syntaxes":[{"syntax":"camera camSetFov level","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"level","type":"Number","optional":false,"default":null,"description":"zoom level, range 0.01 to 8.5 (see description above)","types":["Number"],"since":null,"text":"level: Number - zoom level, range 0.01 to 8.5 (see description above)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"level","types":["Number"]}}],"examples":[{"text":"```sqf\n_cam camSetFov 0.75;\n```","code":["_cam camSetFov 0.75;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPrepareFov","camSetFovRange","camSetTarget"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camSetFovRange","operator":null,"title":"camSetFovRange","type":"command","url":"https://community.bistudio.com/wiki/camSetFovRange","revid":369601,"updated":"2024-09-26T20:17:08Z","groups":["Broken Commands","Camera Control"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set the zoom level (**F**ield **O**f **V**iew) start and end values for automatical zooming.\n\nThe default zoom level is *`0.7`* where *`0`* is the nearest and *`1`* is the most far zoom value.\n \n\n> [!WARNING]\n> This command is **non-functional**!","syntaxes":[{"syntax":"camera camSetFovRange [minFovRange, maxFovRange]","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"minFovRange","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"minFovRange: Number"},{"name":"maxFovRange","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"maxFovRange: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"[minFovRange, maxFovRange]","types":["Array"]}}],"examples":[{"text":"```sqf\n_cam camSetFovRange [0.1, 0.7];\n```","code":["_cam camSetFovRange [0.1, 0.7];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetFov"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camSetPos","operator":null,"title":"camSetPos","type":"command","url":"https://community.bistudio.com/wiki/camSetPos","revid":377590,"updated":"2026-01-02T06:58:01Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the position of the given camera or seagull (see camCreate).\nIt is worth mentioning that camera position can also be set with setPos, in which case it would be instant.\nWith camSetPos it is possible to make smooth position transition in time, defined with camCommit, which is required in this case.","syntaxes":[{"syntax":"camera camSetPos position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\" or \"seagull\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\" or \"seagull\""},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":"camera destination","types":["PositionAGL"],"since":null,"text":"position: PositionAGL - camera destination"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["PositionAGL"]}}],"examples":[{"text":"```sqf\n_cam camSetPos [2300, 1000, 130];\n_cam camCommit 10;\n```","code":["_cam camSetPos [2300, 1000, 130];\n_cam camCommit 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetRelPos","setPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camSetRelPos","operator":null,"title":"camSetRelPos","type":"command","url":"https://community.bistudio.com/wiki/camSetRelPos","revid":377388,"updated":"2026-01-02T06:43:59Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the position of the given camera relative to its target, set with camSetTarget. Needs a call to camCommit to be conducted.\n\n> [!IMPORTANT]\n> Since it sets relative position to the target, the camSetTarget command should be executed already, before camSetRelPos.","syntaxes":[{"syntax":"camera camSetRelPos position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"position","type":"PositionRelative","optional":false,"default":null,"description":null,"types":["PositionRelative"],"since":null,"text":"position: PositionRelative"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\n_cam camSetTarget _car;\n_cam camSetRelPos [0,10,8];\n```","code":["_cam camSetTarget _car;\n_cam camSetRelPos [0,10,8];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camSetTarget","operator":null,"title":"camSetTarget","type":"command","url":"https://community.bistudio.com/wiki/camSetTarget","revid":369114,"updated":"2024-09-03T10:28:47Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set the target object or position where the given camera should point at. Needs the call of camCommit to be conducted. To reset the target use objNull.","syntaxes":[{"syntax":"camera camSetTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"target","type":"Object","optional":false,"default":null,"description":"target location","types":["Object"],"since":null,"text":"target: Object - target location"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"target","types":["Object"]}},{"syntax":"camera camSetTarget position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"object of type \"camera\"","types":["Object"],"since":null,"text":"camera: Object - object of type \"camera\""},{"name":"position","type":"Array","optional":false,"default":null,"description":"target location - Position","types":["Array"],"since":null,"text":"position: Array - target location - Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["Array"]}}],"examples":[{"text":"```sqf\n_camera camSetTarget player;\n```","code":["_camera camSetTarget player;"]},{"text":"```sqf\n_camera camSetTarget [2540,1503,26];\n```","code":["_camera camSetTarget [2540,1503,26];"]},{"text":"```sqf\n_cam = \"camera\" camCreate (player modelToWorld [0, 100, 10]);\n_cam camSetTarget player;\n_cam camSetRelPos [0, 0.5, 1.5];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 1;\nplayer setRandomLip true;\n```","code":["_cam = \"camera\" camCreate (player modelToWorld [0, 100, 10]);\n_cam camSetTarget player;\n_cam camSetRelPos [0, 0.5, 1.5];\n_cam cameraEffect [\"internal\", \"back\"];\n_cam camCommit 1;\nplayer setRandomLip true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","camTarget"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"camTarget","operator":null,"title":"camTarget","type":"command","url":"https://community.bistudio.com/wiki/camTarget","revid":363230,"updated":"2024-03-26T10:51:07Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns camera's target.","syntaxes":[{"syntax":"camTarget camera","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"camera: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"camera","types":["Object"]}}],"examples":[{"text":"```sqf\n_someObject = camTarget _camera;\n```","code":["_someObject = camTarget _camera;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camSetTarget"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"camUseNVG","operator":null,"title":"camUseNVG","type":"command","url":"https://community.bistudio.com/wiki/camUseNVG","revid":369119,"updated":"2024-09-03T10:30:51Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set / clear using of night vision during cutscenes. This command only works with camCreate created camera that is currently the main camera for the player (see #Examples).","syntaxes":[{"syntax":"camUseNVG set","since":null,"effect":null,"exec":null,"params":[{"name":"set","type":"Boolean","optional":false,"default":null,"description":"enable/disable night vision","types":["Boolean"],"since":null,"text":"set: Boolean - enable/disable night vision"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncamUseNVG true;\n```","code":["camUseNVG true;"]},{"text":"```sqf\nsetDate [2000, 12, 31, 0, 0];\n_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, -5, 3];\n_cam cameraEffect [\"Internal\", \"Back\"];\n_cam camCommit 0;\ncamUseNVG true;\n```","code":["setDate [2000, 12, 31, 0, 0];\n_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, -5, 3];\n_cam cameraEffect [\"Internal\", \"Back\"];\n_cam camCommit 0;\ncamUseNVG true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCamUseTI","disableTIEquipment"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"canAdd","operator":null,"title":"canAdd","type":"command","url":"https://community.bistudio.com/wiki/canAdd","revid":376862,"updated":"2025-12-08T21:18:49Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if given object can be stored in inventory of given object or any inventory container (uniform, vest, backpack) of given unit.\n\nBefore Arma 3 v2.10 this comment verified only the biggest container when multiple items were queried; now it checks all containers.\n\n> [!IMPORTANT]\n> Avoid passing an empty string `\"\"` to this command as it will create a warning dialog:\n>\n> This message will show once per mission restart.","syntaxes":[{"syntax":"object canAdd item","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or container","types":["Object"],"since":null,"text":"object: Object - unit or container"},{"name":"item","type":"String","optional":false,"default":null,"description":"config class","types":["String"],"since":null,"text":"item: String - config class"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"item","types":["String"]}},{"syntax":"object canAdd [item, count, ignoreSoldierMaxLoad]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or container","types":["Object"],"since":null,"text":"object: Object - unit or container"},{"name":"item","type":"String","optional":false,"default":null,"description":"config class","types":["String"],"since":null,"text":"item: String - config class"},{"name":"count","type":"Number","optional":false,"default":null,"description":"desired quantity","types":["Number"],"since":null,"text":"count: Number - desired quantity"},{"name":"ignoreSoldierMaxLoad","type":"Boolean","optional":true,"default":"false","description":"true to ignore 'soldierMaxLoad' param, container's maxLoad is still counted","types":["Boolean"],"since":"arma3 2.18","text":"ignoreSoldierMaxLoad: Boolean - (Optional, default false) true to ignore 'soldierMaxLoad' param, container's maxLoad is still counted"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[item, count, ignoreSoldierMaxLoad]","types":["Array"]}},{"syntax":"weapon canAdd item","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"item","type":"String","optional":false,"default":null,"description":"config class of magazine or attachment","types":["String"],"since":null,"text":"item: String - config class of magazine or attachment"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"weapon","types":["String"]},"right":{"text":"item","types":["String"]}},{"syntax":"weapon canAdd [attachment, slot]","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"attachment","type":"String","optional":false,"default":null,"description":"attachment class name","types":["String"],"since":null,"text":"attachment: String - attachment class name"},{"name":"slot","type":"String","optional":false,"default":null,"description":"slot class name (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods","types":["String"],"since":null,"text":"slot: String - slot class name (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"weapon","types":["String"]},"right":{"text":"[attachment, slot]","types":["Array"]}},{"syntax":"weapon canAdd [magazine, muzzle]","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"magazine","type":"String","optional":false,"default":null,"description":"magazine class name","types":["String"],"since":null,"text":"magazine: String - magazine class name"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"muzzle class name","types":["String"],"since":null,"text":"muzzle: String - muzzle class name"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"weapon","types":["String"]},"right":{"text":"[magazine, muzzle]","types":["Array"]}}],"examples":[{"text":"<sqf\n>if (player canAdd \"FirstAidKit\") then\n{\n\tplayer addItem \"FirstAidKit\";\n}\nelse\n{\n\thint \"Not enough space\";\n};\n</sqf>","code":[]},{"text":"```sqf\nif (_box canAdd \"FirstAidKit\") then\n{\n    _box addWeaponCargo [\"FirstAidKit\", 1];\n}\nelse\n{\n    hint \"Not enough space\";\n};\n```","code":["if (_box canAdd \"FirstAidKit\") then\n{\n\t_box addWeaponCargo [\"FirstAidKit\", 1];\n}\nelse\n{\n\thint \"Not enough space\";\n};"]},{"text":"```sqf\ncar canAdd [currentWeapon player, 50];\n```","code":["car canAdd [currentWeapon player, 50];"]},{"text":"```sqf\n// check if attachment can be loaded\n\"arifle_Katiba_GL_F\" canAdd \"acc_pointer_IR\";\n\"arifle_Katiba_GL_F\" canAdd [\"acc_pointer_IR\", \"PointerSlot\"];\n```","code":["// check if attachment can be loaded\n\"arifle_Katiba_GL_F\" canAdd \"acc_pointer_IR\";\n\"arifle_Katiba_GL_F\" canAdd [\"acc_pointer_IR\", \"PointerSlot\"];"]},{"text":"```sqf\n// check if magazine can be loaded\n\"arifle_Katiba_GL_F\" canAdd \"30Rnd_65x39_caseless_green\";\n\"arifle_Katiba_GL_F\" canAdd [\"30Rnd_65x39_caseless_green\", \"this\"];\n\"arifle_Katiba_GL_F\" canAdd [\"1Rnd_SmokeRed_Grenade_shell\", \"EGLM\"];\n```","code":["// check if magazine can be loaded\n\"arifle_Katiba_GL_F\" canAdd \"30Rnd_65x39_caseless_green\";\n\"arifle_Katiba_GL_F\" canAdd [\"30Rnd_65x39_caseless_green\", \"this\"];\n\"arifle_Katiba_GL_F\" canAdd [\"1Rnd_SmokeRed_Grenade_shell\", \"EGLM\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canAddItemToBackpack","canAddItemToUniform","canAddItemToVest","compatibleMagazines","compatibleItems","compatibleWeapons"],"notes":[{"user":"Jonpas","date":"2015-11-29T00:02:00Z","text":"Can also be used on any object that has inventory, not only player inventory containers.\n\nWhere **_box** is **B_supplyCrate_F**:\n\n```sqf\n// empty\n_box canAdd \"FirstAidKit\"; // returns true\n\n// full\n_box canAdd \"FirstAidKit\"; // returns false\n```"},{"user":"Demellion","date":"2017-02-11T18:40:00Z","text":"This can also be used as alternative to canAddItemToBackpack, canAddItemToUniform, canAddItemToVest where container might not be strictly defined. In some cases it might be a good optimisation for your code, where you also don't need to perform checks on which type of player container this is. Example:\n\n```sqf\nprivate _container = selectRandom [uniformContainer player, vestContainer player, backpackContainer player];\nif (_container canAdd \"Rangefinder\") then\n{\n    _container addItemCargoGlobal [\"Rangefinder\", 1];\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands"]},{"name":"canAddItemToBackpack","operator":null,"title":"canAddItemToBackpack","type":"command","url":"https://community.bistudio.com/wiki/canAddItemToBackpack","revid":369124,"updated":"2024-09-03T10:33:08Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if given object can be stored into soldier's backpack.\n\n> [!IMPORTANT]\n> Avoid passing an empty string `\"\"` to this command as it will create a warning dialog:\n>\n> This message will show once per mission restart.","syntaxes":[{"syntax":"unit canAddItemToBackpack item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}},{"syntax":"unit canAddItemToBackpack [item, count, ignoreSoldierMaxLoad]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"count: Number"},{"name":"ignoreSoldierMaxLoad","type":"Boolean","optional":true,"default":"false","description":"true to ignore 'soldierMaxLoad' param, container maxLoad is still counted.","types":["Boolean"],"since":"arma3 2.18","text":"ignoreSoldierMaxLoad: Boolean - (Optional, default false) true to ignore 'soldierMaxLoad' param, container maxLoad is still counted."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[item, count, ignoreSoldierMaxLoad]","types":["Array"]}}],"examples":[{"text":"```sqf\nif (player canAddItemToBackpack \"HandGrenade\") then { player addItemToBackpack _item } else { hint \"no room!\" };\n```","code":["if (player canAddItemToBackpack \"HandGrenade\") then { player addItemToBackpack _item } else { hint \"no room!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canAdd","canAddItemToUniform","canAddItemToVest","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[{"user":"AgentRev","date":"2022-03-29T04:56:58Z","text":"This command is very unreliable, along with all other canAdd commands. For example, in the inventory screen, an empty `\"B_Bergen_dgtl_F\"` backpack can fit a total of 30 `\"5Rnd_127x108_APDS_Mag\"` mags. However, `player canAddItemToBackpack \"5Rnd_127x108_APDS_Mag\"` starts returning false once there are 17 in the backpack. Furthermore, if the player has equipped an empty PCML launcher (without any missile in his inventory), the command starts returning false once there are only 11, despite the fact that the launcher has no effect on backpack space...\n\nI wrote a function almost 9 years ago to bypass this (surprisingly still existing) bug. You can check it [here](https://github.com/A3Wasteland/ArmA3_Wasteland.Altis/blob/dev/client/functions/fn_fitsInventory.sqf), with a usage example [here](https://github.com/A3Wasteland/ArmA3_Wasteland.Altis/blob/dc41623f154d6c5be683374784aba201a0628e60/client/functions/addWeaponInventory.sqf#L18-L20)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"canAddItemToUniform","operator":null,"title":"canAddItemToUniform","type":"command","url":"https://community.bistudio.com/wiki/canAddItemToUniform","revid":376946,"updated":"2025-12-31T22:55:22Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if given object can be stored into soldier's uniform.\n\n> [!IMPORTANT]\n> Avoid passing an empty string `\"\"` to this command as it will create a warning dialog:\n>\n> This message will show once per mission restart.","syntaxes":[{"syntax":"unit canAddItemToUniform item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}},{"syntax":"unit canAddItemToUniform [item, count, ignoreSoldierMaxLoad]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"count: Number"},{"name":"ignoreSoldierMaxLoad","type":"Boolean","optional":true,"default":"false","description":"true to ignore 'soldierMaxLoad' param, container maxLoad is still counted.","types":["Boolean"],"since":"arma3 2.18","text":"ignoreSoldierMaxLoad: Boolean - (Optional, default false) true to ignore 'soldierMaxLoad' param, container maxLoad is still counted."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[item, count, ignoreSoldierMaxLoad]","types":["Array"]}}],"examples":[{"text":"```sqf\n_item = \"HandGrenade\";\n_fits = player canAddItemToUniform _item;\nif (_fits) then\n{\n    player addItemToUniform _item;\n}\nelse\n{\n    hint \"no room!\";\n};\n```","code":["_item = \"HandGrenade\";\n_fits = player canAddItemToUniform _item;\nif (_fits) then\n{\n\tplayer addItemToUniform _item;\n}\nelse\n{\n\thint \"no room!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canAdd","canAddItemToBackpack","canAddItemToVest"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"canAddItemToVest","operator":null,"title":"canAddItemToVest","type":"command","url":"https://community.bistudio.com/wiki/canAddItemToVest","revid":369122,"updated":"2024-09-03T10:33:08Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if given object can be stored into soldier's vest.\n\n> [!IMPORTANT]\n> Avoid passing an empty string `\"\"` to this command as it will create a warning dialog:\n>\n> This message will show once per mission restart.","syntaxes":[{"syntax":"unit canAddItemToVest item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}},{"syntax":"unit canAddItemToVest [item, count, ignoreSoldierMaxLoad]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"},{"name":"count","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"count: Number"},{"name":"ignoreSoldierMaxLoad","type":"Boolean","optional":true,"default":"true","description":"true to ignore 'soldierMaxLoad' param, container maxLoad is still counted.","types":["Boolean"],"since":"arma3 2.18","text":"ignoreSoldierMaxLoad: Boolean - (Optional, default true) true to ignore 'soldierMaxLoad' param, container maxLoad is still counted."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[item, count, ignoreSoldierMaxLoad]","types":["Array"]}}],"examples":[{"text":"```sqf\n_item = \"HandGrenade\";\nprivate _fits = player canAddItemToVest _item;\nif (_fits) then {\n    player addItemToVest _item;\n} else {\n    hint \"no room!\";\n};\n```","code":["_item = \"HandGrenade\";\nprivate _fits = player canAddItemToVest _item;\nif (_fits) then {\n\tplayer addItemToVest _item;\n} else {\n\thint \"no room!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canAdd","canAddItemToBackpack","canAddItemToUniform"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"cancelSimpleTaskDestination","operator":null,"title":"cancelSimpleTaskDestination","type":"command","url":"https://community.bistudio.com/wiki/cancelSimpleTaskDestination","revid":320959,"updated":"2022-05-13T10:04:50Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Cancels a simple task destination.","syntaxes":[{"syntax":"cancelSimpleTaskDestination task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\ncancelSimpleTaskDestination myTask;\n```","code":["cancelSimpleTaskDestination myTask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskDestination","setSimpleTaskDestination"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"canDeployWeapon","operator":null,"title":"canDeployWeapon","type":"command","url":"https://community.bistudio.com/wiki/canDeployWeapon","revid":310452,"updated":"2022-05-05T18:08:10Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns true if a unit's weapon can be deployed.","syntaxes":[{"syntax":"canDeployWeapon unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit : Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if unit's weapon can be deployed","text":"Boolean - true if unit's weapon can be deployed"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (canDeployWeapon player) then { hint \"I could rest my weapon here...\" };\n```","code":["if (canDeployWeapon player) then { hint \"I could rest my weapon here...\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isWeaponDeployed","isWeaponRested"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"canFire","operator":null,"title":"canFire","type":"command","url":"https://community.bistudio.com/wiki/canFire","revid":377852,"updated":"2026-01-03T21:50:58Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if the given vehicle is still able to fire.\nFor the command to return true, vehicle must be alive, have weapon operator and the weapon cannot be damaged ≥ 0.9 but can be empty due to running out of ammo.\nIf mission starts with vehicle having no ammo or setVehicleAmmo 0 command is executed on the vehicle, then canFire will always report false for it.","syntaxes":[{"syntax":"canFire unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if able to fire","text":"Boolean - true if able to fire"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nif (not canFire _tank) then\n{\n    player sideChat \"Tank disabled!\";\n};\n```","code":["if (not canFire _tank) then\n{\n\tplayer sideChat \"Tank disabled!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canMove","canStand","fire","doFire","commandFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire"],"notes":[{"user":"Bdfy","date":"2007-01-20T07:16:00Z","text":"true even if unit is out of ammo. Only false if gun is damaged."},{"user":"Canukausiuka","date":"2008-08-24T05:20:00Z","text":"False if there is no gunner in the vehicle, regardless of damage level."},{"user":"Pierre MGI","date":"2018-04-23T07:20:00Z","text":"This command seems to have evolved. Returns \"true\" (on Hunter, Ifrit) even if Gun's damage is set to 1 and turret also, as far there is a gunner. The only way to obtain a canFire  \"false\"  is to make the crew disembark (2 burned tires for example). Then no matter the gun state, if the gunner disembarks without order, the vehicle can't fire. In this case: can't move >> can't fire.\nNB: if you jump into a hunter HMG after having setHitPointDamage(d) \"hitTurret\" and \"hitGun\"  to 1, the turret can't rotate any more, the gun is pitched down but you can fire (trigger) to the ground. Difficult to check the behavior for each vehicles."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"canMove","operator":null,"title":"canMove","type":"command","url":"https://community.bistudio.com/wiki/canMove","revid":369116,"updated":"2024-09-03T10:28:47Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns if the given vehicle is still able to move.\n- This command does not check for the amount of fuel the vehicle has, except for helicopters and airplanes.\n- A helicopter with a damaged tail rotor may return that it cannot move, where a skilled pilot could use it.","syntaxes":[{"syntax":"canMove vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the vehicle is able to move, false if not","text":"Boolean - true if the vehicle is able to move, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (not canMove _tank) then\n{\n    player sideChat \"He's nailed on the ground! Now hurry!\";\n};\n```","code":["if (not canMove _tank) then\n{\n\tplayer sideChat \"He's nailed on the ground! Now hurry!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canFire","canStand"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"canSlingLoad","operator":null,"title":"canSlingLoad","type":"command","url":"https://community.bistudio.com/wiki/canSlingLoad","revid":352426,"updated":"2024-02-09T15:26:09Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if setSlingLoad is possible.","syntaxes":[{"syntax":"heli canSlingLoad cargo","since":null,"effect":null,"exec":null,"params":[{"name":"heli","type":"Object","optional":false,"default":null,"description":"a helicopter","types":["Object"],"since":null,"text":"heli: Object - a helicopter"},{"name":"cargo","type":"Object","optional":false,"default":null,"description":"an entity","types":["Object"],"since":null,"text":"cargo: Object - an entity"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if setSlingLoad is possible","text":"Boolean - true if setSlingLoad is possible"},"form":"binary","operator":null,"left":{"text":"heli","types":["Object"]},"right":{"text":"cargo","types":["Object"]}},{"syntax":"typeOfHeli canSlingLoad typeOfCargo","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"typeOfHeli","type":"String","optional":false,"default":null,"description":"a config type of helicopter","types":["String"],"since":null,"text":"typeOfHeli: String - a config type of helicopter"},{"name":"typeOfCargo","type":"String","optional":false,"default":null,"description":"a config type of cargo (the object of type cargo has to exist in the mission)","types":["String"],"since":null,"text":"typeOfCargo: String - a config type of cargo (the object of type cargo has to exist in the mission)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if can be sling loaded in principle","text":"Boolean - true if can be sling loaded *in principle*"},"form":"binary","operator":null,"left":{"text":"typeOfHeli","types":["String"]},"right":{"text":"typeOfCargo","types":["String"]}}],"examples":[{"text":"```sqf\n_canSling = veh1 canSlingLoad veh2;\n```","code":["_canSling = veh1 canSlingLoad veh2;"]},{"text":"```sqf\nhint str ((vehicle player) canSlingLoad veh1);\n```","code":["hint str ((vehicle player) canSlingLoad veh1);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"canStand","operator":null,"title":"canStand","type":"command","url":"https://community.bistudio.com/wiki/canStand","revid":329497,"updated":"2022-07-29T13:30:20Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns if the given soldier is able to stand up. It only checks for the unit's legs and not its alive/dead status - it can return true for a dead unit.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.60 and the introduction of limping, this command always returns true for humans.","syntaxes":[{"syntax":"canStand unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the unit is human and is still able to stand up, false otherwise.","text":"Boolean - true if the unit is human and is still able to stand up, false otherwise."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"SQS:\n\n```sqs\n? (not canStand player) : player groupChat \"My legs! They hit my legs!\"\n```","code":["? (not canStand player) : player groupChat \"My legs! They hit my legs!\""]},{"text":"```sqf\nif (not canStand player) then\n{\n    player groupChat \"My legs! They hit my legs!\";\n};\n```","code":["if (not canStand player) then\n{\n\tplayer groupChat \"My legs! They hit my legs!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canMove","canFire"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"canSuspend","operator":null,"title":"canSuspend","type":"command","url":"https://community.bistudio.com/wiki/canSuspend","revid":353403,"updated":"2024-03-17T20:47:33Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if sleep, uiSleep or waitUntil commands can be used in the current scope.\nUsually when suspension is not allowed but used, for example when code is executed in unscheduled environment, the script engine would ignore any suspension command and throw error: \"Suspending not allowed in this context\".\nUsing canSuspend command allows to detect the correct environment for the code.\n\n> [!NOTE]\n> The definition of scheduled and unscheduled environment is not the same as whether or not the script execution can or cannot be suspended.\n> For example while .*sqs* and .*fsm* scripts are scheduled (i.e. added to the scheduler:\n> diag_activeSQSScripts, diag_activeMissionFSMs), they cannot use sleep or be suspended like execVM or spawn scripts can, therefore canSuspend for these types of scripts will return false.","syntaxes":[{"syntax":"canSuspend","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nonEachFrame\n{\n    systemChat str canSuspend;            // false\n    0 spawn { hint str canSuspend };    // true\n    onEachFrame {};\n};\n```","code":["onEachFrame\n{\n\tsystemChat str canSuspend;\t\t\t// false\n\t0 spawn { hint str canSuspend };\t// true\n\tonEachFrame {};\n};"]},{"text":"Make sure the function code is always spawned even when called:\n\n```sqf\nprivate _sleepingCode =\n{\n    if (!canSuspend) exitWith { _this spawn _sleepingCode };\n    sleep _this;\n    hint (\"slept \" + str _this);\n};\n\n5 call _sleepingCode;\n```","code":["private _sleepingCode =\n{\n\tif (!canSuspend) exitWith { _this spawn _sleepingCode };\n\tsleep _this;\n\thint (\"slept \" + str _this);\n};\n\n5 call _sleepingCode;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sleep","uiSleep","waitUntil","call","spawn","execVM","isRemoteExecuted","isRemoteExecutedJIP","remoteExecutedOwner","isUIContext","isGamePaused","isGameFocused"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"canTriggerDynamicSimulation","operator":null,"title":"canTriggerDynamicSimulation","type":"command","url":"https://community.bistudio.com/wiki/canTriggerDynamicSimulation","revid":351687,"updated":"2023-12-24T14:10:58Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for triggerDynamicSimulation. \n\n> [!IMPORTANT]\n> This command returns always true for vehicles.","syntaxes":[{"syntax":"canTriggerDynamicSimulation unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str canTriggerDynamicSimulation player;\n```","code":["hint str canTriggerDynamicSimulation player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"canUnloadInCombat","operator":null,"title":"canUnloadInCombat","type":"command","url":"https://community.bistudio.com/wiki/canUnloadInCombat","revid":363231,"updated":"2024-03-26T10:51:07Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns config value of `unloadInCombat` for a vehicle. Alternatively see getUnloadInCombat","syntaxes":[{"syntax":"canUnloadInCombat vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (canUnloadInCombat _vehicle) then { hint \"unload in combat is possible!\" };\n```","code":["if (canUnloadInCombat _vehicle) then { hint \"unload in combat is possible!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnloadInCombat","getUnloadInCombat"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"canVehicleCargo","operator":null,"title":"canVehicleCargo","type":"command","url":"https://community.bistudio.com/wiki/canVehicleCargo","revid":336373,"updated":"2022-12-30T13:44:50Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns bool array if it is possible to load cargo inside vehicle and if possible to load cargo into empty vehicle","syntaxes":[{"syntax":"vehicle canVehicleCargo cargo","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle carrying cargo","types":["Object"],"since":null,"text":"vehicle: Object - vehicle carrying cargo"},{"name":"cargo","type":"Object","optional":false,"default":null,"description":"cargo to put in vehicle","types":["Object"],"since":null,"text":"cargo: Object - cargo to put in vehicle"}],"returns":{"type":"Array of Booleans","types":["Array","Boolean"],"description":"[willFitIntoCurrentVehicle, willFitIntoEmptyVehicle]","text":"Array of Booleans - [willFitIntoCurrentVehicle, willFitIntoEmptyVehicle]"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"Blackfish with no vehicle cargo loaded\n\n```sqf\nprivate _result = blackfish canVehicleCargo offroad; // [true, true]\n```","code":["private _result = blackfish canVehicleCargo offroad; // [true, true]"]},{"text":"Blackfish with one vehicle cargo called offroad already loaded\n\n```sqf\nprivate _result = blackfish canVehicleCargo offroad; // [false, false]\n```\n\nEven if the Blackfish were empty, the offroad could not be loaded because it is already in a cargo space","code":["private _result = blackfish canVehicleCargo offroad; // [false, false]"]},{"text":"Blackfish with one vehicle cargo called offroad already loaded\n\n```sqf\nprivate _result = blackfish canVehicleCargo offroad2; // [false, true]\n```\n\noffroad2 can't be loaded because there isn't enough space in the Blackfish, but if there were space offroad2 could be loaded into the Blackfish","code":["private _result = blackfish canVehicleCargo offroad2; // [false, true]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleCargo","enableVehicleCargo","getVehicleCargo","isVehicleCargo","vehicleCargoEnabled","canSlingLoad","Arma 3: Vehicle in Vehicle Transport"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"captive","operator":null,"title":"captive","type":"command","url":"https://community.bistudio.com/wiki/captive","revid":318573,"updated":"2022-05-13T09:21:07Z","groups":["Object Manipulation","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the captive state of the given unit (set with setCaptive). A captive unit will not be attacked by its enemies.\n\n> [!IMPORTANT]\n> While a captive unit won't be attacked, it will still attack its enemies – be sure to setBehaviour \"CARELESS\" / removeAllWeapons accordingly.","syntaxes":[{"syntax":"captive object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"object: Object - unit or vehicle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the unit is captive, false if not","text":"Boolean - true if the unit is captive, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nif (captive _general) then { removeAllWeapons _general; };\n```","code":["if (captive _general) then { removeAllWeapons _general; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["captiveNum","setCaptive","side"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"captiveNum","operator":null,"title":"captiveNum","type":"command","url":"https://community.bistudio.com/wiki/captiveNum","revid":369311,"updated":"2024-09-03T18:42:55Z","groups":["Object Manipulation","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks whether the unit is a captive. If the unit is a vehicle, its commander is checked instead.\n\nIf a unit's captivity level was set as a Boolean, then the returned number is either 0 (for false) or 1 (for true).","syntaxes":[{"syntax":"captiveNum unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":"anything from 0 to value set by setCaptive alt syntax. A non zero value means captive.","text":"Number - anything from 0 to value set by setCaptive alt syntax. A non zero value means captive."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_captivity = captiveNum _unit;\n```","code":["_captivity = captiveNum _unit;"]},{"text":"```sqf\n_unit setCaptive 1024;\nhint str captive _unit; // true\nhint str captiveNum _unit; // 1024\n```","code":["_unit setCaptive 1024;\nhint str captive _unit; // true\nhint str captiveNum _unit; // 1024"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["captive","setCaptive"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Sides","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"case","operator":null,"title":"case","type":"command","url":"https://community.bistudio.com/wiki/case","revid":347319,"updated":"2023-09-10T15:36:24Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command is used as a keyword inside a switch structure to define a value case.\n\n> [!IMPORTANT]\n> This command **must** be written and used inside a switch construct, never stored in a variable, otherwise its behaviour is not guaranteed - see <https://foxhound.international/arma-3-sqf-grammar.html> for further explanation.","syntaxes":[{"syntax":"case b","since":null,"effect":null,"exec":null,"params":[{"name":"b","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"b: Anything"}],"returns":{"type":"Switch Type","types":["Switch Type"],"description":null,"text":"Switch Type"},"form":"unary","operator":null,"left":null,"right":{"text":"b","types":["Anything"]}}],"examples":[{"text":"```sqf\nswitch (_condition) do\n{\n    case 1: { hint \"1\" };\n    case 2: { hint \"2\" };\n    default { hint \"default\" };\n};\n```","code":["switch (_condition) do\n{\n\tcase 1: { hint \"1\" };\n\tcase 2: { hint \"2\" };\n\tdefault { hint \"default\" };\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","switch","default"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"catch","operator":null,"title":"catch","type":"command","url":"https://community.bistudio.com/wiki/catch","revid":369419,"updated":"2024-09-03T18:48:49Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Processes code when an exception is thrown in a try block. The exception caught can be found in the *_exception* variable.","syntaxes":[{"syntax":"tryBlock catch code","since":null,"effect":null,"exec":null,"params":[{"name":"tryBlock","type":"Exception Type","optional":false,"default":null,"description":null,"types":["Exception handling"],"since":null,"text":"tryBlock: Exception Type"},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"tryBlock","types":["Exception handling"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\ntry { throw \"invalid argument\" } catch {hint str _exception};\n```","code":["try { throw \"invalid argument\" } catch {hint str _exception};"]},{"text":"```sqf\n123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };\n```","code":["123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };"]},{"text":"The correct usage of shorthand alt syntax:\n\n```sqf\ntry {\n    if (a > b) throw \"Error: some error\"; // OK\n    // the command argument is static\n} catch {\n    hint str _exception;\n};\n\ntry {\n    _someFunc = {\n        // ...\n    };\n    if (a > b) throw (call _someFunc); // NOT OK\n    // the command argument is dynamic\n    // _someFunc is called first to get the value regardless of (a > b) outcome\n} catch {\n    hint str _exception;\n};\n\ntry {\n    _someFunc = {\n        // ...\n    };\n    if (a > b) then { throw (call _someFunc) }; /// OK\n    // the command argument is dynamic\n    // _someFunc is only called when (a > b) is true\n} catch {\n    hint str _exception;\n};\n```","code":["try {\n\tif (a > b) throw \"Error: some error\"; // OK\n\t// the command argument is static\n} catch {\n\thint str _exception;\n};\n\ntry {\n\t_someFunc = {\n\t\t// ...\n\t};\n\tif (a > b) throw (call _someFunc); // NOT OK\n\t// the command argument is dynamic\n\t// _someFunc is called first to get the value regardless of (a > b) outcome\n} catch {\n\thint str _exception;\n};\n\ntry {\n\t_someFunc = {\n\t\t// ...\n\t};\n\tif (a > b) then { throw (call _someFunc) }; /// OK\n\t// the command argument is dynamic\n\t// _someFunc is only called when (a > b) is true\n} catch {\n\thint str _exception;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Exception handling","try","throw"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cbChecked","operator":null,"title":"cbChecked","type":"command","url":"https://community.bistudio.com/wiki/cbChecked","revid":310825,"updated":"2022-05-07T20:23:49Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current state of a CT_CHECKBOX control.","syntaxes":[{"syntax":"cbChecked control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control : Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_checked = cbChecked _myCheckBox;\n```","code":["_checked = cbChecked _myCheckBox;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cbSetChecked","ctrlChecked","ctrlSetChecked"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"cbSetChecked","operator":null,"title":"cbSetChecked","type":"command","url":"https://community.bistudio.com/wiki/cbSetChecked","revid":369236,"updated":"2024-09-03T10:35:01Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the current state of a CT_CHECKBOX control. Use `\"CheckedChanged\"` control event handler with it.","syntaxes":[{"syntax":"control cbSetChecked state","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control : Control"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"state : Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_myCheckBox cbSetChecked true;\n```","code":["_myCheckBox cbSetChecked true;"]},{"text":"```sqf\n_disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n_chk = _disp ctrlCreate [\"RscCheckBox\", -1];\n_chk cbSetChecked true;\n```","code":["_disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n_chk = _disp ctrlCreate [\"RscCheckBox\", -1];\n_chk cbSetChecked true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cbChecked","ctrlSetChecked","ctrlChecked"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"ceil","operator":null,"title":"ceil","type":"command","url":"https://community.bistudio.com/wiki/ceil","revid":318729,"updated":"2022-05-13T09:21:23Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The ceil value of x.","syntaxes":[{"syntax":"ceil x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\nceil 5.25; // Result is 6\n```","code":["ceil 5.25; // Result is 6"]},{"text":"```sqf\nceil -5.25; // Result is -5\n```","code":["ceil -5.25; // Result is -5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["floor","round","linearConversion"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"channelEnabled","operator":null,"title":"channelEnabled","type":"command","url":"https://community.bistudio.com/wiki/channelEnabled","revid":378505,"updated":"2026-05-03T16:53:27Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Array of Booleans in format [enabledChat, enabledVoN] for the given channel.\nFor more information about enabling/disabling of chat channels see enableChannel.\n\n| Channel ID number correspondence |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| Default Channels | Custom Channels |  |  |  |  |  |  |  |  |  |  |  |  |  |  |\n| Global | Side | Command | Group | Vehicle | Direct | CC 1 | CC 2 | CC 3 | CC 4 | CC 5 | CC 6 | CC 7 | CC 8 | CC 9 | CC 10 |\n| 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |","syntaxes":[{"syntax":"channelEnabled channelID","since":null,"effect":null,"exec":null,"params":[{"name":"channelID","type":"Number","optional":false,"default":null,"description":"Channel ID (see description)","types":["Number"],"since":null,"text":"channelID: Number - Channel ID (see description)"}],"returns":{"type":"Array with [chat, VoN, mapMarkers, mapDrawing]","types":["Array"],"description":"chat: Boolean - is use of the text chat enabled - VoN: Boolean - is use of the voice chat enabled - Arma 3 v2.20 mapMarkers: Boolean - can map markers be created - Arma 3 v2.20 mapDrawing: Boolean - can players draw on the map","text":"Array with [chat, VoN, mapMarkers, mapDrawing]\n- chat: Boolean - is use of the text chat enabled\n- VoN: Boolean - is use of the voice chat enabled\n- Arma 3 v2.20 mapMarkers: Boolean - can map markers be created\n- Arma 3 v2.20 mapDrawing: Boolean - can players draw on the map"},"form":"unary","operator":null,"left":null,"right":{"text":"channelID","types":["Number"]}}],"examples":[{"text":"```sqf\n_isGlobalChatEnabled = (channelEnabled 0) select 0; // check if user can use text on global channel\n```","code":["_isGlobalChatEnabled = (channelEnabled 0) select 0; // check if user can use text on global channel"]},{"text":"```sqf\n_isGlobalVoiceEnabled = (channelEnabled 0) select 1; // check if user can use the VoN on global channel\n```","code":["_isGlobalVoiceEnabled = (channelEnabled 0) select 1; // check if user can use the VoN on global channel"]},{"text":"```sqf\n// sets all variables\n(channelEnabled 0) params [\n    \"_isGlobalChatEnabled\",\n    \"_isGlobalVoiceEnabled\",\n    \"_areMarkersEnabled\",\n    \"_isMapDrawingEnabled\"\n];\n```","code":["// sets all variables\n(channelEnabled 0) params [\n\t\"_isGlobalChatEnabled\",\n\t\"_isGlobalVoiceEnabled\",\n\t\"_areMarkersEnabled\",\n\t\"_isMapDrawingEnabled\"\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentChannel","setCurrentChannel","getPlayerChannel","enableChannel","radioChannelCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"cheatsEnabled","operator":null,"title":"cheatsEnabled","type":"command","url":"https://community.bistudio.com/wiki/cheatsEnabled","revid":351326,"updated":"2023-11-27T05:09:28Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether cheats are enabled (whether the designers' version is running).","syntaxes":[{"syntax":"cheatsEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_enabled = cheatsEnabled;\n```","code":["_enabled = cheatsEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ArmA: Armed Assault: Cheats","Arma 3: Cheats"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"checkAIFeature","operator":null,"title":"checkAIFeature","type":"command","url":"https://community.bistudio.com/wiki/checkAIFeature","revid":369971,"updated":"2024-10-22T12:51:32Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the given AI feature is currently enabled.","syntaxes":[{"syntax":"checkAIFeature feature","since":null,"effect":null,"exec":null,"params":[{"name":"feature","type":"String","optional":false,"default":null,"description":"can be one of:\n- `\"AwareFormationSoft\"`\n- `\"CombatFormationSoft\"`\n- AI skill - see disableAI#Syntax 1 (since Arma 3 v1.96)","types":["String"],"since":null,"text":"feature: String - can be one of:\n- `\"AwareFormationSoft\"`\n- `\"CombatFormationSoft\"`\n- AI skill - see disableAI#Syntax 1 (since Arma 3 v1.96)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if is enabled","text":"Boolean - true if is enabled"},"form":"unary","operator":null,"left":null,"right":{"text":"feature","types":["String"]}},{"syntax":"unit checkAIFeature feature","since":"arma3 1.96","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to test AI feature for","types":["Object"],"since":null,"text":"unit: Object - unit to test AI feature for"},{"name":"feature","type":"String","optional":false,"default":null,"description":"disableAI / enableAI feature","types":["String"],"since":null,"text":"feature: String - disableAI / enableAI feature"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if is enabled","text":"Boolean - true if is enabled"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"feature","types":["String"]}}],"examples":[{"text":"```sqf\n_featureUsed = checkAIFeature \"AwareFormationSoft\";\n```","code":["_featureUsed = checkAIFeature \"AwareFormationSoft\";"]},{"text":"```sqf\n_autotargetOn = bob checkAIFeature \"AUTOTARGET\";\n```","code":["_autotargetOn = bob checkAIFeature \"AUTOTARGET\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableAIFeature","enableAI","getUnitState","disableAI"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"checkVisibility","operator":null,"title":"checkVisibility","type":"command","url":"https://community.bistudio.com/wiki/checkVisibility","revid":377827,"updated":"2026-01-03T04:27:56Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"| Affected by | Not affected by |\n|---|---|\n| - terrain grid<br>- obstacles<br>- particles<br>(with `blockAIVisibility = 1`) | - daylight<br>- distance<br>- overcast<br>- fog |\n\nChecks if one position is visible from another position and how much.\n\n> [!NOTE]\n> Particles that have `blockAIVisibility` set to 1 will influence the result, but will never make checkVisibility return 0; an extremely small number will be returned instead.","syntaxes":[{"syntax":"[ignore, LOD, ignore2] checkVisibility [beg, end]","since":null,"effect":null,"exec":null,"params":[{"name":"ignore","type":"Object","optional":false,"default":null,"description":"object to exclude from calculations","types":["Object"],"since":null,"text":"ignore: Object - object to exclude from calculations"},{"name":"LOD","type":"String","optional":false,"default":null,"description":"level of details to use. Possible values are: `\"FIRE\"`, `\"VIEW\"`, `\"GEOM\"`, `\"IFIRE\"`, and Arma 3 v2.02 `\"PHYSX\"`","types":["String"],"since":null,"text":"LOD: String - level of details to use. Possible values are: `\"FIRE\"`, `\"VIEW\"`, `\"GEOM\"`, `\"IFIRE\"`, and Arma 3 v2.02 `\"PHYSX\"`"},{"name":"ignore2","type":"Object","optional":true,"default":"objNull","description":"second object to exclude from calculations","types":["Object"],"since":"arma3 1.62","text":"ignore2: Object - (Optional, default objNull) second object to exclude from calculations"},{"name":"beg","type":"PositionASL","optional":false,"default":null,"description":"start position","types":["PositionASL"],"since":null,"text":"beg: PositionASL - start position"},{"name":"end","type":"PositionASL","optional":false,"default":null,"description":"end position","types":["PositionASL"],"since":null,"text":"end: PositionASL - end position"}],"returns":{"type":"Number","types":["Number"],"description":"how much end position is visible to start position in range 0..1, where 1 is fully visible.","text":"Number - how much end position is visible to start position in range 0..1, where 1 is fully visible."},"form":"binary","operator":null,"left":{"text":"[ignore, LOD, ignore2]","types":["Array"]},"right":{"text":"[beg, end]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _canSee = [objNull, \"VIEW\"] checkVisibility [eyePos player, eyePos unit1];\n```","code":["private _canSee = [objNull, \"VIEW\"] checkVisibility [eyePos player, eyePos unit1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsWith","lineIntersectsSurfaces","lineIntersectsObjs","intersect","terrainIntersect","terrainIntersectASL","terrainIntersectAtASL","lineIntersects","cursorObject","cursorTarget","disableRemoteSensors"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"childAttached","operator":null,"title":"childAttached","type":"command","url":"https://community.bistudio.com/wiki/childAttached","revid":378906,"updated":"2026-08-11T14:57:07Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Get the child that has been attached via attachChild","syntaxes":[{"syntax":"childAttached parent","since":null,"effect":null,"exec":null,"params":[{"name":"parent","type":"Object","optional":false,"default":null,"description":"Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?).","types":["Object"],"since":null,"text":"parent: Object -  Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?)."}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"parent","types":["Object"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","parentAttached"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"civilian","operator":null,"title":"civilian","type":"command","url":"https://community.bistudio.com/wiki/civilian","revid":343875,"updated":"2023-07-27T16:10:26Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the civilian side.\n\nWhen used in a format statement (`hint format [\"%1\", civilian]`), the string returned is `\"CIV\"`.","syntaxes":[{"syntax":"civilian","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"SQS:\n\n```sqs\n? side _unit == civilian : hint \"This is a civilian unit!\"\n```","code":["? side _unit == civilian : hint \"This is a civilian unit!\""]},{"text":"SQF:\n\n```sqf\nif (side _unit == civilian) then\n{\n    hint \"This is a civilian unit!\";\n};\n```","code":["if (side _unit == civilian) then\n{\n\thint \"This is a civilian unit!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["side","west","east","resistance","sideEmpty","sideAmbientLife"],"notes":[{"user":"Ceeeb","date":"2007-02-12T06:06:00Z","text":"In **OFP v1.96**, empty vehicles, objects and dead soldiers are on side civilian."},{"user":"KC Grimes","date":"2018-05-01T15:03:00Z","text":"In **Arma 3 v1.82**, units where setCaptive and/or setUnconscious are set to true are on side civilian, regardless of low rating (Renegade status)."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"className","operator":null,"title":"className","type":"command","url":"https://community.bistudio.com/wiki/className","revid":318707,"updated":"2022-05-13T09:21:21Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns short name of location. For config class name, see configName","syntaxes":[{"syntax":"className location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_shortName = className myLocation;\n```","code":["_shortName = className myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setText","createLocation","deleteLocation","drawLocation","locationPosition","locationNull","nearestLocation","nearestLocations","nearestLocationWithDubbing","name"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"clear3DENAttribute","operator":null,"title":"clear3DENAttribute","type":"command","url":"https://community.bistudio.com/wiki/clear3DENAttribute","revid":364152,"updated":"2024-05-05T10:44:17Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Clears the value of the given entity's attribute in Eden Editor. An attribute is identified by its `property` (`data` when it is engine-drive attribute) value in config. For the list of all attributes with their properties, see Setting Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. You cannot access them in scenario preview or exported scenario!","syntaxes":[{"syntax":"entity clear3DENAttribute attribute","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Eden Entity","Eden ID"],"since":null,"text":"entity: Eden Entity or Eden ID"},{"name":"attribute","type":"String","optional":false,"default":null,"description":"attribute property","types":["String"],"since":null,"text":"attribute: String - attribute property"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"entity","types":["Eden Entity","Eden ID"]},"right":{"text":"attribute","types":["String"]}}],"examples":[{"text":"```sqf\n0 clear3DENAttribute \"name\";\n```","code":["0 clear3DENAttribute \"name\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENAttribute","set3DENAttributes","set3DENMissionAttributes","get3DENMissionAttribute","get3DENAttribute"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"clear3DENInventory","operator":null,"title":"clear3DENInventory","type":"command","url":"https://community.bistudio.com/wiki/clear3DENInventory","revid":321908,"updated":"2022-05-22T12:24:36Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deletes inventory from mission.sqm of given units. Effect is not immediately visible, only when previewing the inventory resets to default.","syntaxes":[{"syntax":"clear3DENInventory entities","since":null,"effect":null,"exec":null,"params":[{"name":"entities","type":"Array of Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Array","Eden Entity","Eden ID"],"since":null,"text":"entities: Array of Eden Entity or Eden ID"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"entities","types":["Array","Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\nclear3DENInventory get3DENSelected \"Object\";\n```","code":["clear3DENInventory get3DENSelected \"Object\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["save3DENInventory","get3DENEntityID","collect3DENHistory","get3DENSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"clearAllItemsFromBackpack","operator":null,"title":"clearAllItemsFromBackpack","type":"command","url":"https://community.bistudio.com/wiki/clearAllItemsFromBackpack","revid":310196,"updated":"2022-05-05T13:10:37Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all items from backpack of a unit.","syntaxes":[{"syntax":"clearAllItemsFromBackpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nclearAllItemsFromBackpack player;\n```","code":["clearAllItemsFromBackpack player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"clearBackpackCargo","operator":null,"title":"clearBackpackCargo","type":"command","url":"https://community.bistudio.com/wiki/clearBackpackCargo","revid":341085,"updated":"2023-05-13T22:09:13Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all backpacks from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"clearBackpackCargo box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nclearBackpackCargo myBox;\n```","code":["clearBackpackCargo myBox;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"clearBackpackCargoGlobal","operator":null,"title":"clearBackpackCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/clearBackpackCargoGlobal","revid":378439,"updated":"2026-04-12T19:56:27Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all backpacks from the vehicle cargo space; MP-synchronised.","syntaxes":[{"syntax":"clearBackpackCargoGlobal unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nclearBackpackCargoGlobal jeepOne;\n```","code":["clearBackpackCargoGlobal jeepOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","clearMagazineCargo","clearMagazineCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal","clearItemCargo","clearItemCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearForcesRTD","operator":null,"title":"clearForcesRTD","type":"command","url":"https://community.bistudio.com/wiki/clearForcesRTD","revid":318552,"updated":"2022-05-13T09:21:05Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all force generators from world.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"clearForcesRTD","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nclearForcesRTD;\n```","code":["clearForcesRTD;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceGeneratorRTD","forceAtPositionRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"clearGroupIcons","operator":null,"title":"clearGroupIcons","type":"command","url":"https://community.bistudio.com/wiki/clearGroupIcons","revid":347632,"updated":"2023-09-28T20:46:38Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all icons from group.","syntaxes":[{"syntax":"clearGroupIcons group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\nclearGroupIcons (group player);\n```","code":["clearGroupIcons (group player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"clearItemCargo","operator":null,"title":"clearItemCargo","type":"command","url":"https://community.bistudio.com/wiki/clearItemCargo","revid":309943,"updated":"2022-05-05T12:16:59Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all items from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"clearItemCargo box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nclearItemCargo myBox;\n```","code":["clearItemCargo myBox;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearItemCargoGlobal","addItemCargo","clearMagazineCargo","clearMagazineCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"clearItemCargoGlobal","operator":null,"title":"clearItemCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/clearItemCargoGlobal","revid":309899,"updated":"2022-05-05T12:16:44Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all items from ammo box (or any general weapon holder container). It also removes vests and uniforms.","syntaxes":[{"syntax":"clearItemCargoGlobal box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nclearItemCargoGlobal _ammoBox;\n```","code":["clearItemCargoGlobal _ammoBox;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearItemCargo","addItemCargoGlobal","clearMagazineCargo","clearMagazineCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"clearItemPool","operator":null,"title":"clearItemPool","type":"command","url":"https://community.bistudio.com/wiki/clearItemPool","revid":309902,"updated":"2022-05-05T12:16:48Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all items from ammo box (or any general weapon holder container)","syntaxes":[{"syntax":"clearItemPool box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nclearItemPool jeepOne;\n```","code":["clearItemPool jeepOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemPool"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"clearMagazineCargo","operator":null,"title":"clearMagazineCargo","type":"command","url":"https://community.bistudio.com/wiki/clearMagazineCargo","revid":309907,"updated":"2022-05-05T12:16:53Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Remove all magazines from the given vehicle's magazine cargo space.","syntaxes":[{"syntax":"clearMagazineCargo vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\nclearMagazineCargo _truck;\n```","code":["clearMagazineCargo _truck;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearMagazineCargoGlobal","addMagazineCargo","addWeaponCargo","clearWeaponCargo","clearWeaponCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearItemCargo","clearItemCargoGlobal","addMagazineAmmoCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearMagazineCargoGlobal","operator":null,"title":"clearMagazineCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/clearMagazineCargoGlobal","revid":309919,"updated":"2022-05-05T12:16:57Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all magazines from the vehicle cargo space. MP synchronized.","syntaxes":[{"syntax":"clearMagazineCargoGlobal object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nclearMagazineCargoGlobal jeepOne;\n```","code":["clearMagazineCargoGlobal jeepOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearMagazineCargo","addMagazineCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearItemCargo","clearItemCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearMagazinePool","operator":null,"title":"clearMagazinePool","type":"command","url":"https://community.bistudio.com/wiki/clearMagazinePool","revid":318569,"updated":"2022-05-13T09:21:06Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all magazines from the magazine pool, of which the player may choose in the following missions. Available in campaigns only.","syntaxes":[{"syntax":"clearMagazinePool","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nclearMagazinePool;\n```","code":["clearMagazinePool;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazinePool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"clearOverlay","operator":null,"title":"clearOverlay","type":"command","url":"https://community.bistudio.com/wiki/clearOverlay","revid":376349,"updated":"2025-10-07T17:08:59Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Clear the current overlay.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"clearOverlay map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\nclearOverlay _map;\n```","code":["clearOverlay _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"clearRadio","operator":null,"title":"clearRadio","type":"command","url":"https://community.bistudio.com/wiki/clearRadio","revid":370204,"updated":"2024-11-06T23:34:35Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Clean up the content of radio protocol history.","syntaxes":[{"syntax":"clearRadio","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nfor \"_i\" from 3 to 1 step -1 do\n{\n    systemChat format [\"The chat history will disappear in %1\", _i];\n    sleep 1;\n};\n\nclearRadio;            // removes previous messages\nenableRadio false;    // disables the chat\n```","code":["for \"_i\" from 3 to 1 step -1 do\n{\n\tsystemChat format [\"The chat history will disappear in %1\", _i];\n\tsleep 1;\n};\n\nclearRadio;\t\t\t// removes previous messages\nenableRadio false;\t// disables the chat"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableRadio"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearWeaponCargo","operator":null,"title":"clearWeaponCargo","type":"command","url":"https://community.bistudio.com/wiki/clearWeaponCargo","revid":341124,"updated":"2023-05-13T22:12:31Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Remove all weapons from the given vehicle's weapon cargo space.","syntaxes":[{"syntax":"clearWeaponCargo vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\nclearWeaponCargo _truck;\n```","code":["clearWeaponCargo _truck;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearWeaponCargoGlobal","addWeaponCargo","addMagazineCargo","clearMagazineCargo","clearMagazineCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearItemCargo","clearItemCargoGlobal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearWeaponCargoGlobal","operator":null,"title":"clearWeaponCargoGlobal","type":"command","url":"https://community.bistudio.com/wiki/clearWeaponCargoGlobal","revid":309985,"updated":"2022-05-05T12:17:03Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all weapons from the vehicle cargo space. MP synchronized.","syntaxes":[{"syntax":"clearWeaponCargoGlobal unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nclearWeaponCargoGlobal jeepOne;\n```","code":["clearWeaponCargoGlobal jeepOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearWeaponCargo","addWeaponCargo","clearMagazineCargo","clearMagazineCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearItemCargo","clearItemCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"clearWeaponPool","operator":null,"title":"clearWeaponPool","type":"command","url":"https://community.bistudio.com/wiki/clearWeaponPool","revid":318753,"updated":"2022-05-13T09:21:26Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove all weapons from the weapon pool, of which the player may choose in the following missions. Available in campaigns only.","syntaxes":[{"syntax":"clearWeaponPool","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nclearWeaponPool;\n```","code":["clearWeaponPool;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponPool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"clientOwner","operator":null,"title":"clientOwner","type":"command","url":"https://community.bistudio.com/wiki/clientOwner","revid":353110,"updated":"2024-03-12T12:48:23Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the machine network ID of the client executing the command.","syntaxes":[{"syntax":"clientOwner","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _myNetworkId = clientOwner;\n```","code":["private _myNetworkId = clientOwner;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["owner","groupOwner","onPlayerConnected","onPlayerDisconnected","getClientState","getClientStateNumber","admin","remoteExecutedOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"closeDialog","operator":null,"title":"closeDialog","type":"command","url":"https://community.bistudio.com/wiki/closeDialog","revid":349590,"updated":"2023-11-11T22:42:19Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Closes the currently active dialog with exit code. It does not instantly close the dialog but does it on next simulation cycle. Most common exit codes are:\n\n```cpp\n#define IDC_OK        1 // emulate \"OK\" button\n#define IDC_CANCEL    2 // emulate \"Cancel\" button\n```","syntaxes":[{"syntax":"closeDialog exitcode","since":null,"effect":null,"exec":null,"params":[{"name":"exitcode","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"exitcode: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"exitcode","types":["Number"]}}],"examples":[{"text":"```sqf\ncloseDialog 2;\n```","code":["closeDialog 2;"]},{"text":"```sqf\n#define IDC_CANCEL 2\ncloseDialog IDC_CANCEL;\n```","code":["#define IDC_CANCEL 2\ncloseDialog IDC_CANCEL;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDialog","dialog","closeDisplay"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"closeDisplay","operator":null,"title":"closeDisplay","type":"command","url":"https://community.bistudio.com/wiki/closeDisplay","revid":323157,"updated":"2022-07-01T10:11:40Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Closes given display with exit code. It does not instantly close the display but does it on next simulation cycle. Most common exit codes are:\n\n```cpp\n#define IDC_OK        1 // emulate \"OK\" button\n#define IDC_CANCEL    2 // emulate \"Cancel\" button\n```\n\n> [!IMPORTANT]\n> Sometimes when one display is opened on top of another display the previous display may not close properly; some display EHs such as \"onUnload\" may never fire.\n> Use this command to manually handle such displays.","syntaxes":[{"syntax":"display closeDisplay exitCode","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"exitCode","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"exitCode: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"exitCode","types":["Number"]}}],"examples":[{"text":"```sqf\n_display closeDisplay 1;\n```","code":["_display closeDisplay 1;"]},{"text":"```sqf\n#define IDC_OK 1\n_display closeDisplay IDC_OK;\n```","code":["#define IDC_OK 1\n_display closeDisplay IDC_OK;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDisplay","closeDialog"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"closeOverlay","operator":null,"title":"closeOverlay","type":"command","url":"https://community.bistudio.com/wiki/closeOverlay","revid":363284,"updated":"2024-03-26T10:51:54Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Closes the current overlay without committing.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"closeOverlay map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"collapseObjectTree","operator":null,"title":"collapseObjectTree","type":"command","url":"https://community.bistudio.com/wiki/collapseObjectTree","revid":376356,"updated":"2025-10-07T21:29:10Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Collapse the object tree.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"collapseObjectTree map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\ncollapseObjectTree _map;\n```","code":["collapseObjectTree _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"collect3DENHistory","operator":null,"title":"collect3DENHistory","type":"command","url":"https://community.bistudio.com/wiki/collect3DENHistory","revid":376415,"updated":"2025-10-11T01:38:31Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Execute a block of code in which all Eden Editor operations will be recorded as one history step. For example creating an entity, setting its attributes and then connections would normally be recorded as three different steps. Calling them all within single **collect3DENHistory** block will group them together and the user will need to undo only once to revert the changes. Use ignore3DENHistory to ignore history entry creation.\n\n> [!NOTE]\n> In order to only change the 2nd or 3rd parameter of the alternative syntax use nil as the preceding parameters.\n\nSome useful icons are:\n\n- `\"\\a3\\3den\\data\\cfg3den\\history\\addtolayer_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\changeattributes_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\changeseat_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\connectitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\create_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\createcomment_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\deleteitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\disconnectitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\makenewlayer_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\missionnew_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\moveitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\multipleoperations_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\pasteitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\removefromlayer_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\rotateitems_ca.paa\"`\n- `\"\\a3\\3den\\data\\cfg3den\\history\\scaleitems_ca.paa\"`","syntaxes":[{"syntax":"collect3DENHistory code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"code that is executed in **Unscheduled Environment**","types":["Code"],"since":null,"text":"code: Code - code that is executed in **Unscheduled Environment**"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}},{"syntax":"[text, tooltip, icon] collect3DENHistory code","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"text","type":"String or Nothing","optional":false,"default":null,"description":"text of the entry that is added to the history list","types":["String","Nothing"],"since":null,"text":"text: String or Nothing - text of the entry that is added to the history list"},{"name":"tooltip","type":"String","optional":true,"default":"\"Batch Change\" (localized)","description":"tooltip of the entry","types":["String"],"since":null,"text":"tooltip: String - (Optional, default \"Batch Change\" (localized)) - tooltip of the entry"},{"name":"icon","type":"String","optional":true,"default":"\"a3\\3den\\data\\cfg3den\\history\\multipleoperations_ca.paa\"","description":"path to the icon that is displayed left of the *text*. **Must not start with a `\\`!**","types":["String"],"since":null,"text":"icon: String - (Optional, default \"a3\\3den\\data\\cfg3den\\history\\multipleoperations_ca.paa\") - path to the icon that is displayed left of the *text*. **Must not start with a `\\`!**"},{"name":"code","type":"Code","optional":false,"default":null,"description":"code that is executed in **Unscheduled Environment**","types":["Code"],"since":null,"text":"code: Code - code that is executed in **Unscheduled Environment**"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[text, tooltip, icon]","types":["Array"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\ncollect3DENHistory \n{\n    _logic = create3DENEntity [\"Logic\", \"Logic\", position player];\n    add3DENConnection [\"Sync\", [_logic], player];\n}; // Creates a logic and connects it to player in one history step.\n```","code":["collect3DENHistory \n{\n\t_logic = create3DENEntity [\"Logic\", \"Logic\", position player];\n\tadd3DENConnection [\"Sync\", [_logic], player];\n}; // Creates a logic and connects it to player in one history step."]},{"text":"```sqf\n[\"Create Entity\", \"B_Soldier_F\", \"a3\\3den\\data\\cfg3den\\history\\create_ca.paa\"] collect3DENHistory \n{\n    create3DENEntity [\"Object\",\"B_Soldier_F\", screenToWorld [0.5,0.5]];\n};\n```","code":["[\"Create Entity\", \"B_Soldier_F\", \"a3\\3den\\data\\cfg3den\\history\\create_ca.paa\"] collect3DENHistory \n{\n\tcreate3DENEntity [\"Object\",\"B_Soldier_F\", screenToWorld [0.5,0.5]];\n};"]},{"text":"```sqf\n[nil, nil, \"a3\\3den\\data\\cfg3den\\history\\moveitems_ca.paa\"] collect3DENHistory \n{\n    create3DENEntity [\"Object\",\"B_Soldier_F\", screenToWorld [0.5,0.5]];\n}; // Change only the icon\n```","code":["[nil, nil, \"a3\\3den\\data\\cfg3den\\history\\moveitems_ca.paa\"] collect3DENHistory \n{\n\tcreate3DENEntity [\"Object\",\"B_Soldier_F\", screenToWorld [0.5,0.5]];\n}; // Change only the icon"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ignore3DENHistory","add3DENConnection","create3DENComposition","create3DENEntity","delete3DENEntities","do3DENAction","remove3DENConnection","set3DENAttributes","set3DENObjectType"],"notes":[{"user":"7erra","date":"2020-10-26T01:15:00Z","text":"Contrary to other code block structures (call, if/then/exitWith, switch/case/default, etc.) the code block of collect3DENHistory will not return any value:\n\n```sqf\n_unit = collect3DENHistory {\n    create3DENEntity [\"Object\", \"C_Protagonist_VR_F\", screenToWorld [0.5, 0.5]];\n};\n_unit // <null>\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"collectiveRTD","operator":null,"title":"collectiveRTD","type":"command","url":"https://community.bistudio.com/wiki/collectiveRTD","revid":377772,"updated":"2026-01-03T01:32:23Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current position of a helicopter's collective pitch control.\n- 0: fully lowered\n- 1: fully raised\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"collectiveRTD helicopterRTD","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopterRTD","types":["Object"]}}],"examples":[{"text":"```sqf\n_collective = collectiveRTD vehicle player;\n```","code":["_collective = collectiveRTD vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setActualCollectiveRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"collisionDisabledWith","operator":null,"title":"collisionDisabledWith","type":"command","url":"https://community.bistudio.com/wiki/collisionDisabledWith","revid":377648,"updated":"2026-01-02T09:01:51Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the object, given object has collision disabled with and whether or not returned object has also collision disabled with given object.","syntaxes":[{"syntax":"collisionDisabledWith obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"given object","types":["Object"],"since":null,"text":"obj: Object - given object"}],"returns":{"type":"Array with [other, mutual]","types":["Array"],"description":"other: Object - the object, obj has collision disabled with, or objNull - mutual: Boolean - true if other has also disabled collision with obj, false otherwise","text":"Array with [other, mutual]\n- other: Object - the object, *obj* has collision disabled with, or objNull\n- mutual: Boolean - true if *other* has also disabled collision with *obj*, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _collisionInfo = collisionDisabledWith _tank;\n```","code":["private _collisionInfo = collisionDisabledWith _tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableCollisionWith","enableCollisionWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"combatBehaviour","operator":null,"title":"combatBehaviour","type":"command","url":"https://community.bistudio.com/wiki/combatBehaviour","revid":351327,"updated":"2023-11-27T05:09:56Z","groups":["AI Behaviour","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns combat behaviour of unit or group. To set unit or group behaviour see setCombatBehaviour. The behaviour is one of:","syntaxes":[{"syntax":"combatBehaviour unitOrGroup","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrGroup","type":"Object or Group","optional":false,"default":null,"description":"AI unit or group","types":["Object","Group"],"since":null,"text":"unitOrGroup: Object or Group - AI unit or group"}],"returns":{"type":"String","types":["String"],"description":"unit behaviour - one of: - \"CARELESS\" - \"SAFE\" - \"AWARE\" - \"COMBAT\" - \"STEALTH\" - \"ERROR\" - when not available","text":"String - unit behaviour - one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"\n- \"ERROR\" - when not available"},"form":"unary","operator":null,"left":null,"right":{"text":"unitOrGroup","types":["Object","Group"]}}],"examples":[{"text":"```sqf\nunit1 setCombatBehaviour \"CARELESS\";\ncombatBehaviour unit1; // \"CARELESS\"\n```","code":["unit1 setCombatBehaviour \"CARELESS\";\ncombatBehaviour unit1; // \"CARELESS\""]},{"text":"```sqf\ngroup unit1 setCombatBehaviour \"SAFE\";\ncombatBehaviour group unit1; // \"SAFE\"\n```","code":["group unit1 setCombatBehaviour \"SAFE\";\ncombatBehaviour group unit1; // \"SAFE\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCombatBehaviour","setBehaviour","setBehaviourStrong","setWaypointBehaviour","combatMode","setCombatMode","skill","setSkill"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"combatMode","operator":null,"title":"combatMode","type":"command","url":"https://community.bistudio.com/wiki/combatMode","revid":364813,"updated":"2024-06-16T08:46:50Z","groups":["Groups","AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the combat mode of the given AI group. See setCombatMode for more information about combat modes.","syntaxes":[{"syntax":"combatMode group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"One of","optional":false,"default":null,"description":"One of\n- Group\n- Object of type Unit - if the argument is unit Object, unit's current group is used.","types":[],"since":null,"text":"group: One of\n- Group\n- Object of type Unit - if the argument is unit Object, unit's current group is used."}],"returns":{"type":"String","types":["String"],"description":"one of: - \"BLUE\" - \"GREEN\" - \"WHITE\" - \"YELLOW\" - \"RED\" - \"ERROR\"","text":"String - one of:\n- \"BLUE\"\n- \"GREEN\"\n- \"WHITE\"\n- \"YELLOW\"\n- \"RED\"\n- \"ERROR\""},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":[]}}],"examples":[{"text":"```sqf\nif (combatMode _grp1 == \"BLUE\") then {_grp1 setCombatMode \"GREEN\"};\n```","code":["if (combatMode _grp1 == \"BLUE\") then {_grp1 setCombatMode \"GREEN\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Combat Modes","setCombatMode","behaviour","setBehaviour","skill","setSkill","Arma 3: AI Skill","setUnitCombatMode","unitCombatMode","setCombatBehaviour","combatBehaviour"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"combatPace","operator":null,"title":"combatPace","type":"command","url":"https://community.bistudio.com/wiki/combatPace","revid":378225,"updated":"2026-03-15T12:52:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets or gets the combat pace for the local player. If the right-hand array is empty, the command will simply return the current combat pace mode without making any changes to combat pace.","syntaxes":[{"syntax":"soldier combatPace [enable, duration]","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":"The local player unit.","types":["Object"],"since":null,"text":"soldier: Object - The local player unit."},{"name":"enable","type":"Boolean","optional":true,"default":null,"description":"Whether to enable or disable combat pace. This param is optional, i.e. the right-hand array can be completely empty (see #Example 1).","types":["Boolean"],"since":null,"text":"enable: Boolean - (Optional, no default) Whether to enable or disable combat pace. This param is optional, i.e. the right-hand array can be completely empty (see #Example 1)."},{"name":"duration","type":"Scalar","optional":true,"default":"-1","description":"Duration of combat pace in seconds (maximum 5 seconds). If duration < 0, combat pace will be toggled. If duration >= 0, short combat pace will be used. duration == 0 means use the default short combat pace duration in config, similar to when the player presses the fire button and weapon is raised. Note that the combat pace modes are mutually exclusive (enabling one disables the other)","types":["Scalar"],"since":null,"text":"duration: Scalar - (Optional, default -1) Duration of combat pace in seconds (maximum 5 seconds). If duration < 0, combat pace will be toggled. If duration >= 0, short combat pace will be used. duration == 0 means use the default short combat pace duration in config, similar to when the player presses the fire button and weapon is raised. Note that the combat pace modes are mutually exclusive (enabling one disables the other)"}],"returns":{"type":"String","types":["String"],"description":"previous combat pace. Possible values: \"None\", \"Timer\", \"Toggle\"","text":"String - previous combat pace. Possible values: \"None\", \"Timer\", \"Toggle\""},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"[enable, duration]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _isCombatPaceToggled = player combatPace [] == \"Toggle\"; // current combat pace is toggled\n```","code":["private _isCombatPaceToggled = player combatPace [] == \"Toggle\"; // current combat pace is toggled"]},{"text":"```sqf\nprivate _isInCombatPace = player combatPace [] != \"None\"; // either using timer or toggled combat pace\n```","code":["private _isInCombatPace = player combatPace [] != \"None\"; // either using timer or toggled combat pace"]},{"text":"```sqf\nplayer combatPace [false]; // disables combat pace (both short and toggle)\n```","code":["player combatPace [false]; // disables combat pace (both short and toggle)"]},{"text":"```sqf\nplayer combatPace [true]; // enables combat pace toggle and disables timer mode\n```","code":["player combatPace [true]; // enables combat pace toggle and disables timer mode"]},{"text":"```sqf\nplayer combatPace [true, 1]; // disables combat pace toggle, enables timer mode for 1 second\n```","code":["player combatPace [true, 1]; // disables combat pace toggle, enables timer mode for 1 second"]},{"text":"```sqf\nplayer combatPace [player combatPace [] != \"Toggle\"]; // toggle combat pace (enable<->disable)\n```","code":["player combatPace [player combatPace [] != \"Toggle\"]; // toggle combat pace (enable<->disable)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWalk","getSpeed","isWalking","isForcedWalk"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"commandArtilleryFire","operator":null,"title":"commandArtilleryFire","type":"command","url":"https://community.bistudio.com/wiki/commandArtilleryFire","revid":377430,"updated":"2026-01-02T06:45:46Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Orders an artillery unit to fire a burst on the given position (via the radio).","syntaxes":[{"syntax":"unit commandArtilleryFire [position, type, rounds]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"position: PositionAGL"},{"name":"type","type":"String","optional":false,"default":null,"description":"magazine class name from CfgMagazines (case sensitive).","types":["String"],"since":null,"text":"type: String - magazine class name from CfgMagazines (case sensitive)."},{"name":"rounds","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rounds: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[position, type, rounds]","types":["Array"]}}],"examples":[{"text":"```sqf\nMortar commandArtilleryFire [[3000, 120, 1000], \"8Rnd_82mm_Mo_shells\", 3];\n```","code":["Mortar commandArtilleryFire [[3000, 120, 1000], \"8Rnd_82mm_Mo_shells\", 3];"]}],"multiplayer":null,"problems":"The unit will fire a burst even if the **rounds** parameter is 0 or a negative number.","aliases":[],"see_also":["doArtilleryFire","getArtilleryAmmo","getArtilleryETA","enableEngineArtillery","getArtilleryComputerSettings","shownArtilleryComputer","inRangeOfArtillery","fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandSuppressiveFire","doSuppressiveFire","isManualFire"],"notes":[{"user":"ansin11","date":"2020-04-18T14:28:00Z","text":"This command can not fire bursts consisting of more rounds than the given magazine type holds, even if there are several magazines of the same type available. The fire mission issued by this command ends once the artillery unit has to reload.\n\n**Example:**\n\nThe Mk6 Mortar comes with four \"8Rnd_82mm_Mo_shells\" magazines, giving it a total of 32 HE shells. However, `_mortar commandArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 10];` will only fire 8 rounds instead of 10.\n\nSimilarly, ...\n\n```sqf\n_mortar commandArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 7]; // First burst\nsleep 20; // Wait until first burst has been fired\n_mortar commandArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 2]; // Second burst\n```\n\n... will only fire 8 rounds total instead of 9; the second round of the second burst is never fired because the artillery unit has to reload after the first round of the second burst."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"commandChat","operator":null,"title":"commandChat","type":"command","url":"https://community.bistudio.com/wiki/commandChat","revid":376776,"updated":"2025-11-17T00:05:50Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Types text to the command radio channel. The text will be visible only on the PC where command was executed. If you need the message to show on all computers, you have to execute it globally (see remoteExec). Use clearRadio to clear chat history\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.","syntaxes":[{"syntax":"unit commandChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit transmitting message","types":["Object"],"since":null,"text":"unit: Object - unit transmitting message"},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"chatText","types":["String"]}},{"syntax":"[side, identity] commandChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"side to which the message will be seen","types":["Side"],"since":null,"text":"side: Side - side to which the message will be seen"},{"name":"identity","type":"String","optional":false,"default":null,"description":"class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\"","types":["String"],"since":null,"text":"identity: String - class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\""},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[side, identity]","types":["Array"]},"right":{"text":"chatText","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne commandChat \"Show this text\";\n```","code":["_soldierOne commandChat \"Show this text\";"]},{"text":"```sqf\n[playerSide, \"HQ\"] commandChat \"Do this! That's an order!\";\n```","code":["[playerSide, \"HQ\"] commandChat \"Do this! That's an order!\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","groupChat","vehicleChat","sideChat","customChat","systemChat","commandRadio"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"commander","operator":null,"title":"commander","type":"command","url":"https://community.bistudio.com/wiki/commander","revid":363370,"updated":"2024-03-28T10:39:29Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"In Operation Flashpoint it returns the commander of a vehicle. Since Armed Assault it returns the primary observer. The commander of a vehicle can be found with effectiveCommander.","syntaxes":[{"syntax":"commander vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle","types":["Object"],"since":null,"text":"vehicle: Object - vehicle"}],"returns":{"type":"Object","types":["Object"],"description":"the unit sitting in the commander place is returned. If vehicle is not a vehicle but a person, the person is returned.","text":"Object - the unit sitting in the commander place is returned. If vehicle is not a vehicle but a person, the person is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nmoveOut commander _tank;\n```","code":["moveOut commander _tank;"]},{"text":"Detect if player is in commander turret of a vehicle:\n\n```sqf\n_isVehicleCommander = player isEqualTo commander objectParent player;\n```","code":["_isVehicleCommander = player isEqualTo commander objectParent player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["driver","gunner","crew","currentPilot","effectiveCommander"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"commandFire","operator":null,"title":"commandFire","type":"command","url":"https://community.bistudio.com/wiki/commandFire","revid":364826,"updated":"2024-06-16T09:28:16Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Order the given unit to fire on the given target (via the radio).\nIf the target is objNull, the unit is ordered to fire on its current target (set with doTarget or commandTarget).","syntaxes":[{"syntax":"unit commandFire target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object of type Unit or Array of Units","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit: Object of type Unit or Array of Units"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_ESoldier1 commandFire _WSoldier1;\n```","code":["_ESoldier1 commandFire _WSoldier1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","doFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandFollow","operator":null,"title":"commandFollow","type":"command","url":"https://community.bistudio.com/wiki/commandFollow","revid":370900,"updated":"2025-02-21T10:44:32Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Order the given unit(s) to follow another from his own group (via radio).\nIt can also be used to resume unit formation after e.g doStop.","syntaxes":[{"syntax":"unit commandFollow unitLead","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects"},{"name":"unitLead","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitLead: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"unitLead","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 commandFollow _soldier2;\n```","code":["_soldier1 commandFollow _soldier2;"]},{"text":"```sqf\n(units group _leader - [_leader]) commandFollow _leader; // returns all the units (but the leader) to formation\n```","code":["(units group _leader - [_leader]) commandFollow _leader; // returns all the units (but the leader) to formation"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doFollow","formationLeader","formLeader","isFormationLeader","leader","selectLeader","setLeader"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"commandFSM","operator":null,"title":"commandFSM","type":"command","url":"https://community.bistudio.com/wiki/commandFSM","revid":377186,"updated":"2026-01-01T10:51:44Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Orders a unit to process command defined by FSM file (via the radio).","syntaxes":[{"syntax":"unitName commandFSM [fsmFile, position, target]","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unitName: Object or Array of Objects"},{"name":"fsmFile","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fsmFile: String"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object","Array"]},"right":{"text":"[fsmFile, position, target]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne commandFSM [\"move.fsm\", position player, player];\n```","code":["_soldierOne commandFSM [\"move.fsm\", position player, player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","FSM Editor Manual","execFSM","completedFSM","doFSM","getFSMVariable","setFSMVariable"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"commandGetOut","operator":null,"title":"commandGetOut","type":"command","url":"https://community.bistudio.com/wiki/commandGetOut","revid":364242,"updated":"2024-05-06T09:38:17Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Orders one or multiple units to get out from the vehicle (via the radio). Same as doGetOut with latter being silent.\n\n> [!NOTE]\n> - Works for both AI and player entities\n> - AI unit gets back in - unless is under player command or combined with other sqf commands (orderGetIn false, allowGetIn false or leaveVehicle)\n> - Ignores vehicle's lock state - unlike action \"Eject\" and moveOut\n> - AI waits for execution until vehicle has stopped/is no longer flying (unclear if any timeout exists for order to be discarded) - unlike action \"Eject\" and moveOut\n> - Plays the vehicle's position's get out animation (same as action \"Eject\") - unlike moveOut\n> - When execute for multiple units, it waits till the action is completed, before the next to take his turn (same as action \"Eject\") - unlike moveOut\n> - AI gets back into formation afterwards\n> - Works only on alive units - unlike action \"Eject\" (one after another) or moveOut (instantly)\n> - Does not work on unconscious units - unless the AI is under player command. Unlike moveOut or action \"Eject\" (but one after another)","syntaxes":[{"syntax":"commandGetOut unit(s)","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit(s)","types":["Object","Array"]}}],"examples":[{"text":"```sqf\ncommandGetOut _unitOne;\n```","code":["commandGetOut _unitOne;"]},{"text":"```sqf\ncommandGetOut [_unitOne,_unitTwo];\n```","code":["commandGetOut [_unitOne,_unitTwo];"]}],"multiplayer":"This command is only effective when used on local units. When used on a remote unit, this command will create radio dialogue on the machine the unit is local to, but the unit will not leave the vehicle.","problems":null,"aliases":[],"see_also":["doGetOut","moveOut","leaveVehicle"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandingMenu","operator":null,"title":"commandingMenu","type":"command","url":"https://community.bistudio.com/wiki/commandingMenu","revid":337562,"updated":"2023-02-10T01:04:40Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of the topmost commanding menu or \"\" if the menu is closed. For action menu visibility check see isActionMenuVisible. See #Notes for Arma 2/Arma 3 structure.","syntaxes":[{"syntax":"commandingMenu","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nwaitUntil { sleep 0.1; commandingMenu == \"RscStatus\" };\nhint \"Press 4, I'm bleeding !\";\n```","code":["waitUntil { sleep 0.1; commandingMenu == \"RscStatus\" };\nhint \"Press 4, I'm bleeding !\";"]},{"text":"```sqf\nif (commandingMenu != \"\") then { hint \"Command menu is opened\" };\n```","code":["if (commandingMenu != \"\") then { hint \"Command menu is opened\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showCommandingMenu","isActionMenuVisible","BIS_fnc_addCommMenuItem","BIS_fnc_removeCommMenuItem"],"notes":[{"user":"Lou Montana","date":"2009-07-15T12:21:00Z","text":"Arma 2 possible values are:\n- **\"\"** - means the menu is closed\n- **\"RscMainMenu\"** - Main menu, by pressing backspace\n  - **\"RscMoveHigh\"** - Move menu (1)\n  - **\"#WATCH\"** - Watch menu (2)\n    - **\"#WATCH0\"** - Watch menu - next page (2-0)\n  - **\"RscWatchDir\"** - Engage menu (3)\n    - **\"RscWatchMoreDir\"** - Engage menu - watch a direction (3-8)\n  - **\"#GET_IN\"** - Mount menu (4)\n  - **\"RscStatus\"** - Status menu (5)\n    - **\"RscCallSupport\"** - Mount menu - call support (5-1)\n  - **\"#ACTION\"** - Action menu (6)\n  - **\"RscCombatMode\"** - Combat mode menu (7)\n  - **\"RscFormations\"** - Formation menu(8)\n  - **\"RscTeam\"** - Team menu (9)\n    - **\"RscSelectTeam\"** - Team menu - select team (0-5)\n  - **\"RscReply\"** - Reply menu (0)\n    - **\"#User:BIS_Menu_GroupCommunication\"** - Communication menu (0-8)\n    - **\"#CUSTOM_RADIO\"** - Custom sounds menu (0-9)\n  - **\"RscRadio\"** - Radio menu (0-0)\n- **\"RscGroupRootMenu\"** - \"simplified\" menu"},{"user":"Lou Montana","date":"2021-08-02T07:42:00Z","text":"Arma 3 possible values (thanks to **RCA3**):\n- **\"\"** - means the menu is closed\n- **\"RscGroupRootMenu\"** Group menu root\n  - **\"RscMenuMove\"** (1) Move menu\n  - **\"#WATCH\"** (2) Watch menu\n    - **\"#WATCH1\"** (2-0) Watch menu - next page\n  - **\"RscMenuEngage\"** (3) Engage menu\n    - **\"RscMenuWatchDir\"** (3-8) Engage menu - watch a direction\n  - **\"#GET_IN\"** (4) Mount menu\n  - **\"RscMenuStatus\"** (5) Status menu\n    - **\"RscCallSupport\"** (5-1) Status menu - call support\n  - **\"#ACTION\"** (6) Action menu Action menu\n  - **\"RscMenuCombatMode\"** (7) Combat mode menu\n  - **\"RscMenuFormations\"** (8) Formation menu\n  - **\"RscMenuTeam\"** (9) Team menu\n    - **\"RscMenuSelectTeam\"** (9-9) Team menu - select team\n  - **\"RscMenuReply\"** (0) Reply menu\n    - **\"#User:BIS_fnc_addCommMenuItem_menu\"** (0-8) BIS Supports\n    - **\"#CUSTOM_RADIO\"** (0-9) Custom radio\n    - **\"RscRadio\"** (0-0) Radio menu\n  - **\"RscMainMenu\"** (Backspace) Main menu"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"commandMove","operator":null,"title":"commandMove","type":"command","url":"https://community.bistudio.com/wiki/commandMove","revid":377521,"updated":"2026-01-02T06:52:09Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to move to the given location (via the radio). Exactly the same as doMove, except this command displays a radio message. The command will not put a visible waypoint marker unlike when move command is given via commanding menu.","syntaxes":[{"syntax":"unitName commandMove position","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unitName: Object or Array of Objects"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object","Array"]},"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\n_soldier1 commandMove getMarkerPos \"Marker1\";\n```","code":["_soldier1 commandMove getMarkerPos \"Marker1\";"]},{"text":"```sqf\n[_soldier1, _soldier2] commandMove getMarkerPos \"Marker1\";\n```","code":["[_soldier1, _soldier2] commandMove getMarkerPos \"Marker1\";"]}],"multiplayer":"When used on a remote unit, this command will still create a radio message on the remote machine but the unit will not move.","problems":null,"aliases":[],"see_also":["doMove","setDestination","moveTo","move","addWaypoint"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandRadio","operator":null,"title":"commandRadio","type":"command","url":"https://community.bistudio.com/wiki/commandRadio","revid":325178,"updated":"2022-07-01T14:34:30Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the audio message to the command radio channel. The message is defined in CfgRadio in the description.ext file or config radio protocol. The transmission will play only on the PC where command was executed. If you need the transmission to play on all computers, you have to execute it globally (see remoteExec).\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages.\n> A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit commandRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from CfgRadio","types":["String"],"since":null,"text":"radioName: String - class name from CfgRadio"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}},{"syntax":"[side, identity] commandRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"side to which the transmission will be played","types":["Side"],"since":null,"text":"side: Side - side to which the transmission will be played"},{"name":"identity","type":"String","optional":false,"default":null,"description":"class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\"","types":["String"],"since":null,"text":"identity: String - class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\""},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from CfgRadio","types":["String"],"since":null,"text":"radioName: String - class name from CfgRadio"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[side, identity]","types":["Array"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne commandRadio \"messageOne\";\n```","code":["_soldierOne commandRadio \"messageOne\";"]},{"text":"```sqf\nplayer commandRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["player commandRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]},{"text":"```sqf\n[west, \"Base\"] commandRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["[west, \"Base\"] commandRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideRadio","groupRadio","customRadio","vehicleRadio","globalRadio","directSay","commandChat"],"notes":[{"user":"Nikita320106","date":"2010-06-24T08:55:00Z","text":"*example:*\n\n```sqf\n_unit commandRadio \"SentCmdHide\";\n```\n\nradio command from CA_Dubbing config should work"},{"user":"Killzone_Kid","date":"2016-12-03T21:33:00Z","text":"To transmit user custom sounds (see Multiplayer_Custom_Sounds_Tutorial), prefix the full filename including file extension with #.\nFor example if there is a custom user sound file called `MySound.ogg`, to play it on the radio use:\n\n```sqf\nplayer commandRadio \"#MySound.ogg\";\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandStop","operator":null,"title":"commandStop","type":"command","url":"https://community.bistudio.com/wiki/commandStop","revid":318579,"updated":"2022-05-13T09:21:07Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to stop via radio. A stop command will never finish, the unit(s) will never be ready.","syntaxes":[{"syntax":"commandStop target","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"target: Object or Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object","Array"]}}],"examples":[{"text":"```sqf\ncommandStop _soldier1;\n```","code":["commandStop _soldier1;"]},{"text":"```sqf\ncommandStop [_soldier1, _soldier2];\n```","code":["commandStop [_soldier1, _soldier2];"]},{"text":"```sqf\ncommandStop (units player);\n```","code":["commandStop (units player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doStop","stopped","stop"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandSuppressiveFire","operator":null,"title":"commandSuppressiveFire","type":"command","url":"https://community.bistudio.com/wiki/commandSuppressiveFire","revid":377828,"updated":"2026-01-03T04:28:29Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Orders the given unit or a group of units to suppress the given position or target (with radio messages, see doSuppressiveFire if you do not want messages).\n- When an Array of units is passed as param, only units from the same Group as the first unit in array are considered.\n- The unit (units) starts firing at the given target or position random amount of shots (exact formula unknown, but seems to depend on amount of ammo unit has) after which it stops.\n- currentCommand shows `\"Suppress\"` and there is no way of stopping unit before it completes random amount of rounds.\n- If a position is passed as target param, it stays fixed.\n- If an object is passed as target param, it depends on what kind of object:\n  - If it is considered a proper target by the unit, it is tracked by the unit dynamically.\n  - If it is not, the position gets obtained via getPosWorld, which could be different from PositionASL of the object, and it is fixed even if the target is able to change position later.","syntaxes":[{"syntax":"unit commandSuppressiveFire target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":"a single unit or array of units","types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects - a single unit or array of units"},{"name":"target","type":"Object or PositionASL","optional":false,"default":null,"description":"actual target or position","types":["Object","PositionASL"],"since":null,"text":"target: Object or PositionASL - actual target or position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"target","types":["Object","PositionASL"]}}],"examples":[{"text":"```sqf\n_soldier commandSuppressiveFire getPosWorld _enemy;\n```","code":["_soldier commandSuppressiveFire getPosWorld _enemy;"]},{"text":"```sqf\n_soldier commandSuppressiveFire cursorTarget;\n```","code":["_soldier commandSuppressiveFire cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","doArtilleryFire","doSuppressiveFire","isManualFire","suppressFor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.60","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"commandTarget","operator":null,"title":"commandTarget","type":"command","url":"https://community.bistudio.com/wiki/commandTarget","revid":318640,"updated":"2022-05-13T09:21:13Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to target the given target (via the radio). Command given to the player, puts a red square with words Target and Distance on player's HUD at target location. If player in vehicle and has radar facilities, it also adds target marker to the radar.","syntaxes":[{"syntax":"unit commandTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"target","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"target: Object or Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"target","types":["Object","Array"]}}],"examples":[{"text":"```sqf\n_ESoldier1 commandTarget _WSoldier1;\n```","code":["_ESoldier1 commandTarget _WSoldier1;"]},{"text":"```sqf\nplayer commandTarget [ted, bill];\n```","code":["player commandTarget [ted, bill];"]}],"multiplayer":"This command is only effective when used on local units. When used on a remote unit, this command will create radio dialogue on the machine the unit is local to, but the unit will not target the target.","problems":null,"aliases":[],"see_also":["assignedTarget","doTarget"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"commandWatch","operator":null,"title":"commandWatch","type":"command","url":"https://community.bistudio.com/wiki/commandWatch","revid":378095,"updated":"2026-02-12T23:52:45Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Orders the unit(s) to watch the given position or target (via the radio). Use objNull as the target to order a unit to stop watching a position/target.","syntaxes":[{"syntax":"units commandWatch target","since":null,"effect":null,"exec":null,"params":[{"name":"units","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"units: Object or Array of Objects"},{"name":"target","type":"Position or Object","optional":false,"default":null,"description":null,"types":["Position","Object"],"since":null,"text":"target: Position or Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"units","types":["Object","Array"]},"right":{"text":"target","types":["Position","Object"]}}],"examples":[{"text":"```sqf\n_soldierOne commandWatch markerPos \"MarkerMoveOne\";\n```","code":["_soldierOne commandWatch markerPos \"MarkerMoveOne\";"]},{"text":"```sqf\n[s1, s2] commandWatch player;\n```","code":["[s1, s2] commandWatch player;"]}],"multiplayer":"This command is only effective when used on local units.\nWhen used on a remote unit, this command will create radio dialogue on the machine the unit is local to, but the unit will not watch the target object/position.","problems":null,"aliases":[],"see_also":["doWatch","lookAt","glanceAt"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"comment","operator":null,"title":"comment","type":"command","url":"https://community.bistudio.com/wiki/comment","revid":363597,"updated":"2024-04-07T18:56:13Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines a comment. See SQF Syntax#Comments to learn more about comments.\n\n> [!WARNING]\n> This command is evaluated during execution, and as such is infinitely slower than other SQF comment methods (`// comment` or `/* comment */`) which get preprocessed and do not exist at runtime).\n> See SQF Syntax for additional documentation on comments.\n\n> [!NOTE]\n> This command is only used to place comments in unpreprocessed codes, such as trigger On Activation field, object init field, etc.\n> Alternatively, one can use a plain string followed by a semicolon as a way to comment; e.g `\"Some comment\";`.","syntaxes":[{"syntax":"comment text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"the comment","types":["String"],"since":null,"text":"text: String - the comment"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"In a preprocessed SQF script (e.g. when doing `execVM \"myScript.sqf\"`)\n\n```sqf\ncomment \"This is a commented line\";        // bad\n\"This is a commented line\";                // slightly better\n// This is a commented line                // perfect\n```","code":["comment \"This is a commented line\";\t\t// bad\n\"This is a commented line\";\t\t\t\t// slightly better\n// This is a commented line\t\t\t\t// perfect"]},{"text":"In an object init field (in editor):\n\n```sqf\ncomment \"This comment works\";\n\"This comment works too\";\n// This doesn't work\n/* This doesn't work either */\n```","code":["comment \"This comment works\";\n\"This comment works too\";\n// This doesn't work\n/* This doesn't work either */"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures"],"notes":[{"user":"Tom_48_97","date":"2009-09-12T19:50:00Z","text":"Like Armed Assault, you can not use brackets to make a multi-lines comment. But, in a sqf file, you can make a comment as follow :\n\n```sqf\ncomment \"\n first line\n seconde line\";\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"commitOverlay","operator":null,"title":"commitOverlay","type":"command","url":"https://community.bistudio.com/wiki/commitOverlay","revid":376346,"updated":"2025-10-07T17:02:42Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Commit the current overlay.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"commitOverlay map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\ncommitOverlay _map;\n```","code":["commitOverlay _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"compatibleItems","operator":null,"title":"compatibleItems","type":"command","url":"https://community.bistudio.com/wiki/compatibleItems","revid":376857,"updated":"2025-12-08T20:38:25Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all items (attachments) that can be mounted on the given weapon.","syntaxes":[{"syntax":"compatibleItems weapon","since":null,"effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"compatible attachments","text":"Array of Strings - compatible attachments"},"form":"unary","operator":null,"left":null,"right":{"text":"weapon","types":["String"]}},{"syntax":"compatibleItems [weapon, slot]","since":null,"effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"slot","type":"String","optional":false,"default":null,"description":"class name of the slot (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods","types":["String"],"since":null,"text":"slot: String - class name of the slot (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"compatible attachments","text":"Array of Strings - compatible attachments"},"form":"unary","operator":null,"left":null,"right":{"text":"[weapon, slot]","types":["Array"]}}],"examples":[{"text":"```sqf\ncompatibleItems \"arifle_Katiba_GL_F\"; // [\"optic_Nightstalker\",\"optic_tws\",\"optic_tws_mg\",\"optic_NVS\", ...]\n```","code":["compatibleItems \"arifle_Katiba_GL_F\"; // [\"optic_Nightstalker\",\"optic_tws\",\"optic_tws_mg\",\"optic_NVS\", ...]"]},{"text":"```sqf\ncompatibleItems [\"arifle_Katiba_GL_F\", \"PointerSlot\"]; // [\"acc_flashlight\",\"acc_flashlight_broken\",\"acc_pointer_IR\", ...]\n```","code":["compatibleItems [\"arifle_Katiba_GL_F\", \"PointerSlot\"]; // [\"acc_flashlight\",\"acc_flashlight_broken\",\"acc_pointer_IR\", ...]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compatibleWeapons","compatibleMagazines","BIS_fnc_compatibleItems","canAdd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"compatibleMagazines","operator":null,"title":"compatibleMagazines","type":"command","url":"https://community.bistudio.com/wiki/compatibleMagazines","revid":376900,"updated":"2025-12-20T16:40:46Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all magazines that can be loaded in the given weapon or all magazines containing the provided ammo. No compatible magazines are returned for submunition or missiles.","syntaxes":[{"syntax":"compatibleMagazines weaponOrAmmo","since":null,"effect":null,"exec":null,"params":[{"name":"weaponOrAmmo","type":"String","optional":false,"default":null,"description":"weapon class name or Arma 3 v2.22 ammo class name","types":["String"],"since":null,"text":"weaponOrAmmo: String - weapon class name or Arma 3 v2.22 ammo class name"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"all magazines that can be loaded in any muzzle of the given weapon or magazines containing given ammo.","text":"Array of Strings - all magazines that can be loaded in **any muzzle** of the given weapon or magazines containing given ammo."},"form":"unary","operator":null,"left":null,"right":{"text":"weaponOrAmmo","types":["String"]}},{"syntax":"compatibleMagazines [weapon, muzzle]","since":null,"effect":null,"exec":null,"params":[{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"muzzle name (\"this\" is supported for primary muzzle)","types":["String"],"since":null,"text":"muzzle: String - muzzle name (\"this\" is supported for primary muzzle)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"all magazines that can be loaded in the given muzzle of the given weapon.","text":"Array of Strings - all magazines that can be loaded in the given muzzle of the given weapon."},"form":"unary","operator":null,"left":null,"right":{"text":"[weapon, muzzle]","types":["Array"]}}],"examples":[{"text":"```sqf\ncompatibleMagazines \"arifle_Katiba_GL_F\";\n```","code":["compatibleMagazines \"arifle_Katiba_GL_F\";"]},{"text":"```sqf\ncompatibleMagazines [\"arifle_Katiba_GL_F\", \"this\"];\n```","code":["compatibleMagazines [\"arifle_Katiba_GL_F\", \"this\"];"]},{"text":"```sqf\ncompatibleMagazines [\"arifle_Katiba_GL_F\", \"EGLM\"];\n```","code":["compatibleMagazines [\"arifle_Katiba_GL_F\", \"EGLM\"];"]},{"text":"```sqf\ncompatibleMagazines \"B_65x39_Caseless_green\"; // [\"30Rnd_65x39_caseless_green\", \"30Rnd_65x39_caseless_green_mag_Tracer\"]\n```","code":["compatibleMagazines \"B_65x39_Caseless_green\"; // [\"30Rnd_65x39_caseless_green\", \"30Rnd_65x39_caseless_green_mag_Tracer\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compatibleWeapons","compatibleItems","BIS_fnc_compatibleMagazines","canAdd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"compatibleWeapons","operator":null,"title":"compatibleWeapons","type":"command","url":"https://community.bistudio.com/wiki/compatibleWeapons","revid":378898,"updated":"2026-08-11T14:56:33Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all compatible weapons for given weapon item, weapon magazine or weapon slot.","syntaxes":[{"syntax":"compatibleWeapons name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"weapon item (see compatibleItems), weapon magazine (see compatibleMagazines) or weapon slot (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods","types":["String"],"since":null,"text":"name: String - weapon item (see compatibleItems), weapon magazine (see compatibleMagazines) or weapon slot (defined under **WeaponSlotsInfo** class in weapon config), for example:\n- \"CowsSlot\" for optics\n- \"MuzzleSlot\" for silencers\n- \"PointerSlot\" for laser pointers and flashlights\n- \"UnderBarrelSlot\" for bipods"}],"returns":{"type":"Array of Arrays in format:","types":["Array"],"description":"[weapon, slot] - for weapon items - [weapon, muzzle] - for weapon magazines (primary muzzle returned as \"this\") - [weapon, slot] - for weapon slot","text":"Array of Arrays in format:\n- [weapon, slot] - for weapon items\n- [weapon, muzzle] - for weapon magazines (primary muzzle returned as \"this\")\n- [weapon, slot] - for weapon slot"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\ncompatibleWeapons \"LaserBatteries\"; // [[\"Laserdesignator_pilotCamera\",\"this\"],[\"Laserdesignator_mounted\",\"this\"],...]\n```","code":["compatibleWeapons \"LaserBatteries\"; // [[\"Laserdesignator_pilotCamera\",\"this\"],[\"Laserdesignator_mounted\",\"this\"],...]"]},{"text":"```sqf\ncompatibleWeapons \"PointerSlot\"; // [[\"arifle_MX_ACO_pointer_F\",\"PointerSlot\"],[\"arifle_TRG21_F\",\"PointerSlot\"],...]\n```","code":["compatibleWeapons \"PointerSlot\"; // [[\"arifle_MX_ACO_pointer_F\",\"PointerSlot\"],[\"arifle_TRG21_F\",\"PointerSlot\"],...]"]},{"text":"```sqf\ncompatibleWeapons \"1Rnd_HE_Grenade_shell\"; // [[\"arifle_Katiba_GL_F\",\"EGLM\"],[\"arifle_Katiba_GL_ACO_F\",\"EGLM\"],...]\n```","code":["compatibleWeapons \"1Rnd_HE_Grenade_shell\"; // [[\"arifle_Katiba_GL_F\",\"EGLM\"],[\"arifle_Katiba_GL_ACO_F\",\"EGLM\"],...]"]},{"text":"```sqf\ncompatibleWeapons \"bipod_01_F_blk\"; // [[\"arifle_MX_ACO_pointer_F\",\"UnderBarrelSlot\"],[\"arifle_MX_F\",\"UnderBarrelSlot\"],...]\n```","code":["compatibleWeapons \"bipod_01_F_blk\"; // [[\"arifle_MX_ACO_pointer_F\",\"UnderBarrelSlot\"],[\"arifle_MX_F\",\"UnderBarrelSlot\"],...]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compatibleItems","compatibleMagazines","BIS_fnc_compatibleItems","canAdd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"compile","operator":null,"title":"compile","type":"command","url":"https://community.bistudio.com/wiki/compile","revid":321043,"updated":"2022-05-13T12:05:32Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compiles String expression into Code.","syntaxes":[{"syntax":"compile expression","since":null,"effect":null,"exec":null,"params":[{"name":"expression","type":"String","optional":false,"default":null,"description":"expression to be compiled","types":["String"],"since":null,"text":"expression: String - expression to be compiled"}],"returns":{"type":"Code","types":["Code"],"description":"compiled expression","text":"Code - compiled expression"},"form":"unary","operator":null,"left":null,"right":{"text":"expression","types":["String"]}}],"examples":[{"text":"```sqf\n_string = \"a = a + 1\";\n_code = compile _string;\ncall _code;\n```","code":["_string = \"a = a + 1\";\n_code = compile _string;\ncall _code;"]},{"text":"```sqf\nhint str compile \"a = b\";\n// result: { a = b }\n```","code":["hint str compile \"a = b\";\n// result: { a = b }"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["call","spawn","compileFinal","compileScript","parseSimpleArray","isFinal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"compileFinal","operator":null,"title":"compileFinal","type":"command","url":"https://community.bistudio.com/wiki/compileFinal","revid":378946,"updated":"2026-08-29T21:45:18Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compiles an expression / takes an existing HashMap and makes it final, preventing it from being modified or overwritten (by = assignation, publicVariable, set or any other command).\n\n> [!NOTE]\n> This feature is only available in the retail version of Arma 3.","syntaxes":[{"syntax":"compileFinal expression","since":null,"effect":null,"exec":null,"params":[{"name":"expression","type":"String, Arma 3 v2.14 Code or HashMap","optional":false,"default":null,"description":null,"types":["String","Code","HashMap"],"since":null,"text":"expression: String, Arma 3 v2.14 Code or HashMap"}],"returns":{"type":"Code or HashMap","types":["Code","HashMap"],"description":null,"text":"Code or HashMap"},"form":"unary","operator":null,"left":null,"right":{"text":"expression","types":["String","Code","HashMap"]}}],"examples":[{"text":"```sqf\nMyCode = compileFinal \"a = a + 1\";\ncall MyCode;\n \n// repeated compile won't have any effect\nMyCode = compileFinal \"a = a + 2\";\n```","code":["MyCode = compileFinal \"a = a + 1\";\ncall MyCode;\n \n// repeated compile won't have any effect\nMyCode = compileFinal \"a = a + 2\";"]},{"text":"```sqf\n// duplicate code will be final as well\nMyDuplicateCode = MyCode;\n\n// an alternative is to copy str'd code (since Arma 3 v2.02)\nMyNonFinalCopy = compile toString MyCode;\n```","code":["// duplicate code will be final as well\nMyDuplicateCode = MyCode;\n\n// an alternative is to copy str'd code (since Arma 3 v2.02)\nMyNonFinalCopy = compile toString MyCode;"]},{"text":"```sqf\n// since Arma 3 v2.14\nReadonlyCode = compileFinal { systemChat \"Hello World!\"; };\nReadonlyHashMap = compileFinal _myHashMap;\n```","code":["// since Arma 3 v2.14\nReadonlyCode = compileFinal { systemChat \"Hello World!\"; };\nReadonlyHashMap = compileFinal _myHashMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compile","compileScript","isFinal","call","spawn"],"notes":[{"user":"AgentRev01","date":"2013-08-15T00:35:00Z","text":"When broadcasting a compileFinal'ed variable using publicVariable or its variants, the variable also becomes final on the other client(s) and/or the server.\nAlso, compileFinal does not prevent event handlers from being removed or overwritten."},{"user":"Nelis75733126","date":"2017-05-27T11:58:00Z","text":"in Arma 3 v1.70.141838, compileFinal also works for profileNamespace and uiNamespace. But be careful with that."},{"user":"Hypoxic125","date":"2024-06-22T23:41:27Z","text":"Making a base class read only using HashMapObjects\n\n```sqf\nClass_Dog = compileFinal createHashMapObject [\n    // Properties\n    [\"#type\", \"Dog\"],\n    [\"owner\", objNull],\n    [\"legs\", 4],\n    [\"health\", 100],\n    [\"vehicleclass\", \"Dog_Base_F\"],\n    [\"vehicle\", objNull],\n\n    // Constructor\n    [\"#create\", {\n        params [[\"_owner\", objNull], [\"_vehicle\", objNull]];\n\n        if ([_owner, _vehicle] findIf {isNull _x} != -1) exitWith {};\n\n        _self set [\"owner\", _owner];\n        _self set [\"vehicle\", _vehicle]\n    }]\n];\n\nNewDog = createHashMapObject [\n    [[\"#base\", Class_Dog]],\n    [player_1, createVehicle [Class_Dog get \"vehicleclass\", [0,0,0], 0, [], \"NONE\"]]\n];\n\nNewDog set [\"owner\", player_2];\nNewDog get \"owner\";                 // returns player_2\n\nClass_Dog set [\"owner\", player_1];  // Error: Read Only\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"compileScript","operator":null,"title":"compileScript","type":"command","url":"https://community.bistudio.com/wiki/compileScript","revid":365141,"updated":"2024-07-26T16:44:13Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command is an alias for `compile(Final) (prefixHeader + preprocessFileLineNumbers path)`. See description of preprocessFileLineNumbers for more details.\n\nIn addition, this command can also compile SQF Bytecode files, which can reduce compilation time. If both a .sqf file and .sqfc file are pressing in the the path, this command will automatically compile the .sqfc file.","syntaxes":[{"syntax":"compileScript [path, final, prefixHeader]","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"path to script file","types":["String"],"since":null,"text":"path: String - path to script file"},{"name":"final","type":"Boolean","optional":true,"default":"false","description":"compile final, see compileFinal","types":["Boolean"],"since":null,"text":"final: Boolean - (Optional, default false) compile final, see compileFinal"},{"name":"prefixHeader","type":"String","optional":true,"default":"\"\"","description":"value added at the beginning of the file","types":["String"],"since":null,"text":"prefixHeader: String - (Optional, default \"\") value added at the beginning of the file"}],"returns":{"type":"Code","types":["Code"],"description":null,"text":"Code"},"form":"unary","operator":null,"left":null,"right":{"text":"[path, final, prefixHeader]","types":["Array"]}}],"examples":[{"text":"```sqf\ncompileScript [\"a3\\props_f_enoch\\military\\equipment\\scripts\\meteo.sqf\"];\n// has the same functionality as \ncompile preprocessFileLineNumbers \"a3\\props_f_enoch\\military\\equipment\\scripts\\meteo.sqf\";\n```","code":["compileScript [\"a3\\props_f_enoch\\military\\equipment\\scripts\\meteo.sqf\"];\n// has the same functionality as \ncompile preprocessFileLineNumbers \"a3\\props_f_enoch\\military\\equipment\\scripts\\meteo.sqf\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compile","compileFinal","preprocessFileLineNumbers","preprocessFile","call","spawn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"completedFSM","operator":null,"title":"completedFSM","type":"command","url":"https://community.bistudio.com/wiki/completedFSM","revid":310814,"updated":"2022-05-07T20:23:36Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the given FSM is completed. The FSM handle is the number returned by the execFSM command.","syntaxes":[{"syntax":"completedFSM fsmHandle","since":null,"effect":null,"exec":null,"params":[{"name":"fsmHandle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"fsmHandle: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"fsmHandle","types":["Number"]}}],"examples":[{"text":"```sqf\n_completed = completedFSM _fsmHandle;\n```","code":["_completed = completedFSM _fsmHandle;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","commandFSM","doFSM","execFSM","getFSMVariable","setFSMVariable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"composeText","operator":null,"title":"composeText","type":"command","url":"https://community.bistudio.com/wiki/composeText","revid":336896,"updated":"2023-01-04T16:43:56Z","groups":["Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a Structured Text by joining the given structured or plain text arguments.","syntaxes":[{"syntax":"composeText arguments","since":null,"effect":null,"exec":null,"params":[{"name":"arguments","type":"Array of String and/or Structured Text","optional":false,"default":null,"description":"use Structured Text where necessary (see #Example 2)","types":["Array","String","Structured Text"],"since":null,"text":"arguments: Array of String and/or Structured Text - use Structured Text where necessary (see #Example 2)"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"arguments","types":["Array","String","Structured Text"]}}],"examples":[{"text":"```sqf\nhint composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];\n```","code":["hint composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];"]},{"text":"```sqf\nhint composeText [\"line1\", \"<br/>\", \"line2\"];        // result displayed in one line\nhint composeText [\"line1\", lineBreak, \"line2\"];    // result displayed in two lines\n```","code":["hint composeText [\"line1\", \"<br/>\", \"line2\"];\t\t// result displayed in one line\nhint composeText [\"line1\", lineBreak, \"line2\"];\t// result displayed in two lines"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Structured Text","formatText","image","lineBreak","parseText","text","setAttributes"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: Structured Text","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"config greater greater name","operator":">>","title":"config greater greater name","type":"command","url":"https://community.bistudio.com/wiki/config_greater_greater_name","revid":363978,"updated":"2024-04-29T22:51:43Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns config entry with given name (alias of a / b, slightly faster but with lower precedence)","syntaxes":[{"syntax":"config >> name","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Config","types":["Config"],"description":"config entry","text":"Config - config entry"},"form":"binary","operator":">>","left":{"text":"config","types":["Config"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nconfigFile >> \"CfgVehicles\";\n```","code":["configFile >> \"CfgVehicles\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getText","isArray","isClass","isNumber","isText","select","configClasses"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"configClasses","operator":null,"title":"configClasses","type":"command","url":"https://community.bistudio.com/wiki/configClasses","revid":378371,"updated":"2026-04-03T16:49:12Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of config entries which meet criteria in condition code. Command iterates through all available config sub classes of the given config class. Current looked at config is stored in _x variable (similar to alternative count command implementation). Condition has to return true in order for the looked at config to be added to the resulting array. Slightly faster than configProperties, but doesn't account for config properties or inherited entries.\n\n> [!IMPORTANT]\n> - The condition code passed to configClasses should only be used for **simple filter expressions** and nothing more\n> - Do not use `\"isClass _x\"` in the condition. The engine does this check already\n>\n> - Arma 3 v2.02 brought specific engine optimisations for the following conditions:\n>   - `\"true\"`\n>   - `\"getNumber (_x >> 'scope') > 0\"`","syntaxes":[{"syntax":"condition configClasses config","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"condition: String"},{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Array of Configs","types":["Array","Config"],"description":null,"text":"Array of Configs"},"form":"binary","operator":null,"left":{"text":"condition","types":["String"]},"right":{"text":"config","types":["Config"]}},{"syntax":"configClasses [config, depth, includeInherited, allSubclasses, classNames]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"target config","types":["Config"],"since":null,"text":"config: Config - target config"},{"name":"depth","type":"Number","optional":false,"default":null,"description":"how many levels of subclasses to go deep","types":["Number"],"since":null,"text":"depth: Number - how many levels of subclasses to go deep"},{"name":"includeInherited","type":"Boolean","optional":false,"default":null,"description":"true to look through inherited classes","types":["Boolean"],"since":null,"text":"includeInherited: Boolean - true to look through inherited classes"},{"name":"allSubclasses","type":"Boolean","optional":false,"default":null,"description":"true to return all subclasses, false - to return only the last tier.","types":["Boolean"],"since":null,"text":"allSubclasses: Boolean - true to return all subclasses, false - to return only the last tier."},{"name":"classNames","type":"Boolean","optional":true,"default":"false","description":"when true class names Strings are returned, when false - Configs are returned.","types":["Boolean"],"since":null,"text":"classNames: Boolean - (Optional, default: false) when true class names Strings are returned, when false - Configs are returned."}],"returns":{"type":"Array of Configs or Strings, which represent class names.","types":["Array","Config","String"],"description":null,"text":"Array of Configs or Strings, which represent class names."},"form":"unary","operator":null,"left":null,"right":{"text":"[config, depth, includeInherited, allSubclasses, classNames]","types":["Array"]}}],"examples":[{"text":"collect all CfgVehicles configs:\n\n```sqf\n_configs = \"true\" configClasses (configFile >> \"CfgVehicles\");\n```","code":["_configs = \"true\" configClasses (configFile >> \"CfgVehicles\");"]},{"text":"Return all classes that can transport 10 and more soldiers:\n\n```sqf\n_transporters = \"getNumber (_x >> 'transportSoldier') >= 10\" configClasses (configFile >> \"CfgVehicles\");\n```","code":["_transporters = \"getNumber (_x >> 'transportSoldier') >= 10\" configClasses (configFile >> \"CfgVehicles\");"]},{"text":"Return all classes that inherit from 'RscText':\n\n```sqf\nhint str (\"inheritsFrom _x == (configFile >> 'RscText')\" configClasses configFile);\n```","code":["hint str (\"inheritsFrom _x == (configFile >> 'RscText')\" configClasses configFile);"]},{"text":"Return children:\n\n```sqf\nconfigClasses [configFile >> \"CfgGroups\", 0, true, true, true]\n//Returns [\"West\",\"East\",\"Indep\",\"Empty\"]\n```","code":["configClasses [configFile >> \"CfgGroups\", 0, true, true, true]\n//Returns [\"West\",\"East\",\"Indep\",\"Empty\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Config","configFile","missionConfigFile","configProperties","configHierarchy","BIS_fnc_returnChildren"],"notes":[{"user":"Iceman77","date":"2014-10-19T12:24:00Z","text":"A fantastic way to filter stuff. eg:\n\n```sqf\n// create an array of west vehicles and spawn then in front of the player in rows of 5\n\nprivate [\"_cfgArray\", \"_xPos\", \"_yPos\", \"_veh\"];\n\n_cfgArray = \"( \n    (getNumber (_x >> 'scope') >= 2) && \n    {\n        getNumber (_x >> 'side') == 1 && \n        { getText (_x >> 'vehicleClass') in ['Armored', 'Car', 'Air'] }\n    }\n)\" configClasses (configFile >> \"CfgVehicles\");\n\n_xPos = 0;\n_yPos = 0;\n\n{\n    _yPos = _yPos + 20;\n    _veh = createVehicle [(configName _x), player modelToWorld [_xPos, _yPos, 0], [], 0, \"NONE\"];\n    if (_yPos >= 100) then\n    {\n        _yPos = 0;\n        _xPos = _xPos + 20;\n    };\n} forEach _cfgArray;\n```"},{"user":"Benargee","date":"2016-05-28T20:28:00Z","text":"configClasses does not account for inherited subclasses, use configProperties with isClass filter instead\n\n```sqf\nconfigProperties [_config, \"isClass _x\", true];\n```"},{"user":"Nelis75733126","date":"2017-05-28T09:18:00Z","text":"this will get a list of ALL locations on the currently loaded world\n\n```sqf\n( \"true\" configClasses (configFile >> \"CfgWorlds\" >> worldName >> \"names\" ) ) apply {\n    // change each config entry into a location\n    nearestLocation [\n        getArray ( _x >> \"position\" ),\n        getText ( _x >> \"type\" )\n    ]\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"configFile","operator":null,"title":"configFile","type":"command","url":"https://community.bistudio.com/wiki/configFile","revid":369418,"updated":"2024-09-03T18:48:49Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return root of config entries hierarchy.","syntaxes":[{"syntax":"configFile","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_isMyClassActive = isClass (configFile >> \"CfgPatches\" >> \"MyClass\");\n```","code":["_isMyClassActive = isClass (configFile >> \"CfgPatches\" >> \"MyClass\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionConfigFile","campaignConfigFile"],"notes":[{"user":"ffur2007slx2_5","date":"2014-07-19T20:08:00Z","text":"Arma 3 v1.24 It is recommended to use configClasses instead of BIS_fnc_getCfgSubClasses and BIS_fnc_uniqueClasses on subclasses collection or conditional selection.\n\n```sqf\n_faces = \"true\" configClasses (configFile >> \"CfgFaces\");\n// same as:\n_faces = (configfile >> \"CfgFaces\") call BIS_fnc_getCfgSubClasses;\n```\n\n```sqf\n//Extract all animals:\nanimals = \"configName _x isKindOf 'animal'\" configClasses (configFile >> \"CfgVehicles\");\n// same as:\nanimals = [];\n[\n    configFile >> \"CfgVehicles\",\n    {\n        if ((configName _this) isKindOf \"animal\") then {\n            animals set [count animals, _this]\n        }\n    }\n] call BIS_fnc_uniqueClasses;\n```\n\nReturn nested subclasses, currently still BIS_fnc_returnChildren\n\n```sqf\n// return all nested config classes\n[configFile >> \"CfgFaces\", 1, true, true] call BIS_fnc_returnChildren;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"configHierarchy","operator":null,"title":"configHierarchy","type":"command","url":"https://community.bistudio.com/wiki/configHierarchy","revid":378521,"updated":"2026-05-04T01:50:46Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns hierarchy of the given config class. Just like with inheritsFrom, only complete config classes are supported (before Arma 3 v2.14). Since Arma 3 v2.22, an alt syntax is added, which allows to return parents identical to BIS_fnc_returnParents (see Example 2)","syntaxes":[{"syntax":"configHierarchy config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"target config","types":["Config"],"since":null,"text":"config: Config - target config"}],"returns":{"type":"Array of Configs","types":["Array","Config"],"description":"ordered from parent to child","text":"Array of Configs - ordered from parent to child"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}},{"syntax":"configHierarchy [config, classesOnly, includeBases, reversedOrder, configNames]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"target config","types":["Config"],"since":null,"text":"config: Config - target config"},{"name":"classesOnly","type":"Boolean","optional":false,"default":null,"description":"when true, only classes are included in output and not properties","types":["Boolean"],"since":null,"text":"classesOnly: Boolean - when true, only classes are included in output and not properties"},{"name":"includeBases","type":"Boolean","optional":false,"default":null,"description":"when true, returned parents will include base classes (see description)","types":["Boolean"],"since":null,"text":"includeBases: Boolean - when true, returned parents will include base classes (see description)"},{"name":"reversedOrder","type":"Boolean","optional":false,"default":null,"description":"when true, the return order is from child to parent","types":["Boolean"],"since":null,"text":"reversedOrder: Boolean - when true, the return order is from child to parent"},{"name":"configNames","type":"Boolean","optional":true,"default":null,"description":"when true, the return is Array of Strings, when false - Array of Configs. Default: false","types":["Boolean"],"since":null,"text":"configNames: Boolean - (Optional) when true, the return is Array of Strings, when false - Array of Configs. Default: false"}],"returns":{"type":"Array of Configs or Strings","types":["Array","Config","String"],"description":"Strings represent config names","text":"Array of Configs or Strings - Strings represent config names"},"form":"unary","operator":null,"left":null,"right":{"text":"[config, classesOnly, includeBases, reversedOrder, configNames]","types":["Array"]}}],"examples":[{"text":"```sqf\n_hierarchy = configHierarchy (configFile >> \"CfgVehicles\" >> \"Car\");\n// Returns [bin\\config.bin, bin\\config.bin/CfgVehicles, bin\\config.bin/CfgVehicles/Car]\n```","code":["_hierarchy = configHierarchy (configFile >> \"CfgVehicles\" >> \"Car\");\n// Returns [bin\\config.bin, bin\\config.bin/CfgVehicles, bin\\config.bin/CfgVehicles/Car]"]},{"text":"```sqf\n_bis_fnc_returnParents = configHierarchy [configFile >> \"CfgVehicles\" >> \"Land_FirePlace_F\", true, true, true, true];\n// Returns [\"Land_FirePlace_F\",\"House_F\",\"House\",\"HouseBase\",\"NonStrategic\",\"Building\",\"Static\",\"All\"]\n```","code":["_bis_fnc_returnParents = configHierarchy [configFile >> \"CfgVehicles\" >> \"Land_FirePlace_F\", true, true, true, true];\n// Returns [\"Land_FirePlace_F\",\"House_F\",\"House\",\"HouseBase\",\"NonStrategic\",\"Building\",\"Static\",\"All\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configClasses","configProperties","missionConfigFile","campaignConfigFile","a / b","config greater greater name","configName","count","getArray","getText","getNumber","inheritsFrom","isArray","isClass","isNumber","isText","select","isKindOf","BIS_fnc_returnParents"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"configName","operator":null,"title":"configName","type":"command","url":"https://community.bistudio.com/wiki/configName","revid":339071,"updated":"2023-04-26T10:53:59Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns name of config entry.","syntaxes":[{"syntax":"configName config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_name = configName (configFile >> \"CfgVehicles\"); // result is \"CfgVehicles\"\n```","code":["_name = configName (configFile >> \"CfgVehicles\"); // result is \"CfgVehicles\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","config greater greater name","count","getArray","getText","getNumber","inheritsFrom","isArray","isClass","isNumber","isText","select"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"configNull","operator":null,"title":"configNull","type":"command","url":"https://community.bistudio.com/wiki/configNull","revid":321052,"updated":"2022-05-13T12:13:46Z","groups":["Variables","Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Config.\n\n> [!IMPORTANT]\n> Unlike other null values (objNull, grpNull, etc), configNull returns true when compared to itself.\n>\n> ```sqf\n> configNull == configNull;                            // returns true\n> isNull configNull;                                    // returns true\n> configNull isEqualTo configNull;                    // returns true\n> configNull == configFile >> \"ANonExistentEntry\";    // returns true\n> ```","syntaxes":[{"syntax":"configNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_config = missionNamespace getVariable [\"myConfig\", configNull];\n```","code":["_config = missionNamespace getVariable [\"myConfig\", configNull];"]},{"text":"```sqf\nstr configNull; // returns \"\"\n```","code":["str configNull; // returns \"\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","locationNull","objNull","taskNull","teamMemberNull","scriptNull","typeName","isNull"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Command Group: Variables","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"configOf","operator":null,"title":"configOf","type":"command","url":"https://community.bistudio.com/wiki/configOf","revid":309234,"updated":"2022-05-04T10:23:40Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns config path of the provided object.","syntaxes":[{"syntax":"configOf object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nconfigOf player; // returns bin\\config.bin/CfgVehicles/B_W_Soldier_TL_F\n```","code":["configOf player; // returns bin\\config.bin/CfgVehicles/B_W_Soldier_TL_F"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["typeOf"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"configProperties","operator":null,"title":"configProperties","type":"command","url":"https://community.bistudio.com/wiki/configProperties","revid":377082,"updated":"2026-01-01T09:41:25Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.36"}],"since":{"game":"arma3","name":"Arma 3","version":"1.36"},"arma3_since":"1.36","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of config entries that meet the criteria in the condition code. The command iterates through available classes and config properties for given config entry.\nCurrent looked at config is stored in _x variable (similar to alternative count command implementation).\nThe condition has to return true in order for the looked at property to be added to the resulting array. This command is a bit slower than configClasses but allows to access inherited entries.","syntaxes":[{"syntax":"configProperties [config, condition, inherit]","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"config entry to search","types":["Config"],"since":null,"text":"config: Config - config entry to search"},{"name":"condition","type":"String","optional":true,"default":"\"true\"","description":"expression, which if returns true, adds current property to result\n\n> [!IMPORTANT]\n> - The condition code passed to configProperties should only be used for **simple filter expressions** and nothing more.\n> - Since Arma 3 v2.02 the following conditions are optimised for performance:\n>   - `\"true\"` (omitted condition)\n>   - `\"isClass _x\"`\n>   - `\"isClass _x && (...)\"`","types":["String"],"since":null,"text":"condition: String - (Optional, default \"true\") expression, which if returns true, adds current property to result\n\n> [!IMPORTANT]\n> - The condition code passed to configProperties should only be used for **simple filter expressions** and nothing more.\n> - Since Arma 3 v2.02 the following conditions are optimised for performance:\n>   - `\"true\"` (omitted condition)\n>   - `\"isClass _x\"`\n>   - `\"isClass _x && (...)\"`"},{"name":"inherit","type":"Boolean","optional":true,"default":"true","description":"include inherited properties","types":["Boolean"],"since":null,"text":"inherit: Boolean - (Optional, default true) include inherited properties"}],"returns":{"type":"Array of Configs","types":["Array","Config"],"description":null,"text":"Array of Configs"},"form":"unary","operator":null,"left":null,"right":{"text":"[config, condition, inherit]","types":["Array"]}}],"examples":[{"text":"```sqf\n_configs = configProperties [configFile >> \"CfgVehicles\" >> \"O_Truck_02_box_F\"];\n```","code":["_configs = configProperties [configFile >> \"CfgVehicles\" >> \"O_Truck_02_box_F\"];"]},{"text":"```sqf\n_configs = configProperties [configFile >> \"RscText\", \"true\", true];\n```","code":["_configs = configProperties [configFile >> \"RscText\", \"true\", true];"]},{"text":"Get all hitpoints of a truck:\n\n```sqf\n_hitPoints = [];\n_hitPointsCfgs = configProperties [\n    configFile >> \"CfgVehicles\" >> \"O_Truck_02_box_F\" >> \"HitPoints\", \n    \"true\", \n    true\n];\nhint str _hitPointsCfgs;\n```","code":["_hitPoints = [];\n_hitPointsCfgs = configProperties [\n\tconfigFile >> \"CfgVehicles\" >> \"O_Truck_02_box_F\" >> \"HitPoints\", \n\t\"true\", \n\ttrue\n];\nhint str _hitPointsCfgs;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Config","configFile","missionConfigFile","configClasses","configHierarchy"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Arma 3 version 1.36","Scripting Commands"]},{"name":"configSourceAddonList","operator":null,"title":"configSourceAddonList","type":"command","url":"https://community.bistudio.com/wiki/configSourceAddonList","revid":318786,"updated":"2022-05-13T09:21:30Z","groups":["Mods and Addons","Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of addons (CfgPatches) in which the given config class is defined.","syntaxes":[{"syntax":"configSourceAddonList config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_addons = configSourceAddonList (configFile >> \"CfgVehicles\" >> \"Man\"); // returns [\"A3_Data_F\", \"A3_Characters_F\", \"A3_Data_F_Curator\", \"A3_Air_F_Heli\"]\n```","code":["_addons = configSourceAddonList (configFile >> \"CfgVehicles\" >> \"Man\"); // returns [\"A3_Data_F\", \"A3_Characters_F\", \"A3_Data_F_Curator\", \"A3_Air_F_Heli\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","configSourceMod","configSourceModList"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Command Group: Mods and Addons","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"configSourceMod","operator":null,"title":"configSourceMod","type":"command","url":"https://community.bistudio.com/wiki/configSourceMod","revid":318766,"updated":"2022-05-13T09:21:28Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns modDir of the mod that given config class was loaded from.","syntaxes":[{"syntax":"configSourceMod config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\nconfigSourceMod (configFile >> \"CfgVehicles\" >> \"Heli_Transport_04_base_F\"); // returns \"heli\"\n```","code":["configSourceMod (configFile >> \"CfgVehicles\" >> \"Heli_Transport_04_base_F\"); // returns \"heli\""]},{"text":"```sqf\nconfigSourceMod (configFile >> \"CfgVehicles\" >> \"Car\"); // returns \"A3\"\n```","code":["configSourceMod (configFile >> \"CfgVehicles\" >> \"Car\"); // returns \"A3\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","configSourceModList","modParams"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"configSourceModList","operator":null,"title":"configSourceModList","type":"command","url":"https://community.bistudio.com/wiki/configSourceModList","revid":369411,"updated":"2024-09-03T18:43:26Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of mods (CfgMods) in which the given config class is defined.","syntaxes":[{"syntax":"configSourceModList config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_mods = configSourceModList (configFile >> \"CfgVehicles\" >> \"Man\");\nhint str _mods; // [\"A3\",\"curator\",\"heli\"]\n```","code":["_mods = configSourceModList (configFile >> \"CfgVehicles\" >> \"Man\");\nhint str _mods; // [\"A3\",\"curator\",\"heli\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","configSourceMod","configSourceAddonList","modParams"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 1.40","Scripting Commands"]},{"name":"confirmSensorTarget","operator":null,"title":"confirmSensorTarget","type":"command","url":"https://community.bistudio.com/wiki/confirmSensorTarget","revid":310881,"updated":"2022-05-07T20:25:14Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets for which Side the entity becomes a \"confirmed hostile\" target - a target that becomes highlighted red on the sensors display.","syntaxes":[{"syntax":"vehicle confirmSensorTarget [side, isConfirmed]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"isConfirmed","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"isConfirmed: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[side, isConfirmed]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player confirmSensorTarget [blufor, true];\n```","code":["vehicle player confirmSensorTarget [blufor, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","setVehicleReportRemoteTargets","vehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"connectTerminalToUAV","operator":null,"title":"connectTerminalToUAV","type":"command","url":"https://community.bistudio.com/wiki/connectTerminalToUAV","revid":363209,"updated":"2024-03-25T20:30:02Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Connect person with UAV terminal to UAV unit. UAV Terminal item needs to be assigned to GPS slot. In MP the connection is handled locally, therefore it is possible for multiple MP clients to connect to the same UAV. However, each UAV can only have one connection to a terminal per MP client, so if UAV is already connected to another terminal on the same MP client, this new connection will fail.","syntaxes":[{"syntax":"person connectTerminalToUAV uav","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"uav","types":["Object"]}}],"examples":[{"text":"```sqf\nbool = player connectTerminalToUAV uav1;\n```","code":["bool = player connectTerminalToUAV uav1;"]},{"text":"```sqf\nplayer connectTerminalToUAV objNull; //disconnect\n```","code":["player connectTerminalToUAV objNull; //disconnect"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUnitsUAV","getConnectedUAV","isUAVConnected","UAVControl","showUAVFeed","shownUAVFeed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"connectToServer","operator":null,"title":"connectToServer","type":"command","url":"https://community.bistudio.com/wiki/connectToServer","revid":373150,"updated":"2025-04-04T09:14:53Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Connects the client to the provided server.\n\n> [!NOTE]\n> - only works on the Main Menu.\n> - must be executed from UI context, such as *onButtonDown* or similar events (see User Interface Event Handlers).\n\n> [!NOTE]\n> **Since Arma 3 v2.20:** If port is 0, the IP will be resolved as a SRV DNS Record.\n>\n> [\"domain.com\", 0, \"password\"] will be resolved as \"_arma3._udp.domain.com\".\n>\n> Only the first found record will be used, there is no support for multiple records with priority/weights.","syntaxes":[{"syntax":"connectToServer [ip, port, password]","since":null,"effect":null,"exec":null,"params":[{"name":"ip","type":"String","optional":false,"default":null,"description":"IP in <https://en.wikipedia.org/wiki/IPv4> format or Arma 3 v2.20 domain name","types":["String"],"since":null,"text":"ip: String - IP in <https://en.wikipedia.org/wiki/IPv4> format or Arma 3 v2.20 domain name"},{"name":"port","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"port: Number"},{"name":"password","type":"String","optional":false,"default":null,"description":"\"\" if no password","types":["String"],"since":null,"text":"password: String - \"\" if no password"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[ip, port, password]","types":["Array"]}}],"examples":[{"text":"```sqf\nconnectToServer [\"192.168.0.2\", 2302, \"test\"];\n```","code":["connectToServer [\"192.168.0.2\", 2302, \"test\"];"]},{"text":"```sqf\nconnectToServer [\"publicserver.mydomain.com\", 2302, \"\"];\n```","code":["connectToServer [\"publicserver.mydomain.com\", 2302, \"\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["serverCommand","getSteamFriendsServers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"continue","operator":null,"title":"continue","type":"command","url":"https://community.bistudio.com/wiki/continue","revid":309284,"updated":"2022-05-04T15:26:09Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Skips current loop iteration and continues with the next one.","syntaxes":[{"syntax":"continue","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// prints 0, 1, 3\nfor \"_i\" from 0 to 3 do \n{\n    if (_i == 2) then { continue };\n    systemChat str _i;\n};\n```","code":["// prints 0, 1, 3\nfor \"_i\" from 0 to 3 do \n{\n\tif (_i == 2) then { continue };\n\tsystemChat str _i;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["continueWith","break","breakWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"continueWith","operator":null,"title":"continueWith","type":"command","url":"https://community.bistudio.com/wiki/continueWith","revid":378202,"updated":"2026-03-12T15:42:26Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Skips the current loop iteration, continues with the next one and returns the given value.","syntaxes":[{"syntax":"continueWith return","since":null,"effect":null,"exec":null,"params":[{"name":"return","type":"Anything","optional":false,"default":null,"description":"value to be returned when iteration is skipped","types":["Anything"],"since":null,"text":"return: Anything - value to be returned when iteration is skipped"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"unary","operator":null,"left":null,"right":{"text":"return","types":["Anything"]}},{"syntax":"scriptHandle continueWith code","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":null,"types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle"},{"name":"code","type":"Code","optional":false,"default":null,"description":"Code to execute once the Promise has completed. The code will be executed in Unscheduled Environment.","types":["Code"],"since":null,"text":"code: Code - Code to execute once the Promise has completed. The code will be executed in Unscheduled Environment."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"scriptHandle","types":["Script Handle"]},"right":{"text":"code","types":["Code"]}},{"syntax":"scriptHandle continueWith [code, args]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":null,"types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle"},{"name":"code","type":"Code","optional":false,"default":null,"description":"Code to execute once the Promise has completed. The code will be executed in Unscheduled Environment.","types":["Code"],"since":null,"text":"code: Code - Code to execute once the Promise has completed. The code will be executed in Unscheduled Environment."},{"name":"args","type":"Anything","optional":false,"default":null,"description":"Arguments passed into code in _thisArgs variable","types":["Anything"],"since":null,"text":"args: Anything - Arguments passed into code in _thisArgs variable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"scriptHandle","types":["Script Handle"]},"right":{"text":"[code, args]","types":["Array"]}}],"examples":[{"text":"```sqf\n// results in [2, \"TEST\", 4]\nprivate _result = [1, 2, 3] apply {\n    if (_x == 2) then {\n        continueWith \"TEST\";\n    } else {\n        _x + 1;\n    };\n};\n```","code":["// results in [2, \"TEST\", 4]\nprivate _result = [1, 2, 3] apply {\n\tif (_x == 2) then {\n\t\tcontinueWith \"TEST\";\n\t} else {\n\t\t_x + 1;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["continue","break","breakWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"controlNull","operator":null,"title":"controlNull","type":"command","url":"https://community.bistudio.com/wiki/controlNull","revid":369405,"updated":"2024-09-03T18:43:23Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Control. To compare non-existent objects use isNull or isEqualTo (see examples).","syntaxes":[{"syntax":"controlNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (_myCtrl isEqualTo controlNull) then { hint \"_myCtrl is null!\"; };\n```","code":["if (_myCtrl isEqualTo controlNull) then { hint \"_myCtrl is null!\"; };"]},{"text":"```sqf\ncontrolNull == controlNull;            // returns false\nisNull controlNull;                        // returns true\ncontrolNull isEqualTo controlNull;        // returns true\n```","code":["controlNull == controlNull;\t\t\t// returns false\nisNull controlNull;\t\t\t\t\t\t// returns true\ncontrolNull isEqualTo controlNull;\t\t// returns true"]},{"text":"```sqf\nstr controlNull; // No control\n```","code":["str controlNull; // No control"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayNull","grpNull","locationNull","objNull","taskNull","teamMemberNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"controlsGroupCtrl","operator":null,"title":"controlsGroupCtrl","type":"command","url":"https://community.bistudio.com/wiki/controlsGroupCtrl","revid":310912,"updated":"2022-05-07T20:33:32Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a child control with specified idc from a controls group","syntaxes":[{"syntax":"ctrlgrp controlsGroupCtrl idc","since":null,"effect":null,"exec":null,"params":[{"name":"ctrlgrp","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrlgrp: Control"},{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"binary","operator":null,"left":{"text":"ctrlgrp","types":["Control"]},"right":{"text":"idc","types":["Number"]}}],"examples":[{"text":"```sqf\n_control = _controlsGroup controlsGroupCtrl 101;\n```","code":["_control = _controlsGroup controlsGroupCtrl 101;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDisplays","allControls","ctrlCreate","ctrlParentControlsGroup"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"conversationDisabled","operator":null,"title":"conversationDisabled","type":"command","url":"https://community.bistudio.com/wiki/conversationDisabled","revid":349091,"updated":"2023-11-08T14:47:27Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for disableConversation.","syntaxes":[{"syntax":"conversationDisabled unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if the status of kbTell's IsSpeaking for the given unit is `> 0`. See disableConversation for more info","text":"Boolean - returns true if the status of kbTell's *IsSpeaking* for the given unit is `> 0`. See disableConversation for more info"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (conversationDisabled soldier1) then { soldier1 disableConversation false };\n```","code":["if (conversationDisabled soldier1) then { soldier1 disableConversation false };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableConversation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"copyFromClipboard","operator":null,"title":"copyFromClipboard","type":"command","url":"https://community.bistudio.com/wiki/copyFromClipboard","revid":310206,"updated":"2022-05-05T13:10:41Z","groups":["System","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return ANSI content of the (text) clipboard. If Unicode support is desired, see forceUnicode.","syntaxes":[{"syntax":"copyFromClipboard","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint copyFromClipboard;\n```","code":["hint copyFromClipboard;"]}],"multiplayer":"> [!IMPORTANT]\n> This command is disabled in multiplayer for security reasons.","problems":null,"aliases":[],"see_also":["copyToClipboard","diag_log","forceUnicode"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"copyToClipboard","operator":null,"title":"copyToClipboard","type":"command","url":"https://community.bistudio.com/wiki/copyToClipboard","revid":337563,"updated":"2023-02-10T01:05:53Z","groups":["System","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Copies ANSI text string to the clipboard. If Unicode support is desired, see forceUnicode.","syntaxes":[{"syntax":"copyToClipboard text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\ncopyToClipboard str _data;\n```","code":["copyToClipboard str _data;"]}],"multiplayer":"> [!IMPORTANT]\n> Restricted to **the server** for safety reasons.","problems":null,"aliases":[],"see_also":["copyFromClipboard","diag_log","forceUnicode"],"notes":[{"user":"Benargee","date":"2014-10-12T02:38:00Z","text":"To add a line break in output text do this:\n\n```sqf\n_br = toString [13,10]; // (carriage return & line feed)\n_string = \"Line 1\" + _br + \"Line 2\";\ncopyToClipboard _string;\n```\n\nPaste into text editor of choice, you get:\n\n```\nLine 1\nLine 2\n```\n\n(A3 1.30 Stable executed inside .sqf via execVM)"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"copyWaypoints","operator":null,"title":"copyWaypoints","type":"command","url":"https://community.bistudio.com/wiki/copyWaypoints","revid":320957,"updated":"2022-05-13T10:04:50Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Copy the chain of waypoints from source to target group. The target group will start to process waypoints from the first one.","syntaxes":[{"syntax":"groupTo copyWaypoints groupFrom","since":null,"effect":null,"exec":null,"params":[{"name":"groupTo","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"groupTo: Group"},{"name":"groupFrom","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"groupFrom: Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupTo","types":["Group"]},"right":{"text":"groupFrom","types":["Group"]}}],"examples":[{"text":"```sqf\ngroup1 copyWaypoints group2;\n```","code":["group1 copyWaypoints group2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cos","operator":null,"title":"cos","type":"command","url":"https://community.bistudio.com/wiki/cos","revid":321053,"updated":"2022-05-13T12:15:18Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Cosine of a number, argument in degrees.","syntaxes":[{"syntax":"cos x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\ncos 60; // returns 0.5\n```","code":["cos 60; // returns 0.5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["acos","sin","asin","tan","atan","atan2"],"notes":[{"user":"Hardrock","date":"2006-08-08T23:54:00Z","text":"Be aware that there might be rounding errors in the results of this command.\n\n```sqf\ncos 90\n```\n\nfor example doesn't return the expected '0', but '-4.37114e-008'. So, if you want to compare results of Cosinus, don't use the compare operator\n\n```sqf\n(cos 90) == 0\n```\n\nbut rather use less than.\n\n```sqf\n(cos 90) < 0.00001\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"count","operator":null,"title":"count","type":"command","url":"https://community.bistudio.com/wiki/count","revid":377184,"updated":"2026-01-01T10:51:01Z","groups":["Arrays","Strings","Config","HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Can be used to count:\n- The number of elements in an array (returns the already internally known array size)\n- The number of elements in an array matching the condition\n- The number of sub-entries in a config entry\n- Arma 3 v1.28 The number of characters in an ANSI string \n\n> [!NOTE]\n> If Unicode support is desired, see forceUnicode.","syntaxes":[{"syntax":"count value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"String, Config, HashMap or Array of Anything","optional":false,"default":null,"description":null,"types":["String","Config","HashMap","Array","Anything"],"since":null,"text":"value: String, Config, HashMap or Array of Anything"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["String","Config","HashMap","Array","Anything"]}},{"syntax":"condition count array","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"Code","optional":false,"default":null,"description":"condition that must return true for the tested element to be counted. The variable `_x` will contain the currently tested element\n\n> [!NOTE]\n> **Arma 3:** If the provided array contains different data types, use isEqualTo for item comparison instead of ==.","types":["Code"],"since":null,"text":"condition: Code - condition that must return true for the tested element to be counted. The variable `_x` will contain the currently tested element\n\n> [!NOTE]\n> **Arma 3:** If the provided array contains different data types, use isEqualTo for item comparison instead of ==."},{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"condition","types":["Code"]},"right":{"text":"array","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\ncount [0, 0, 1, 2]; // returns 4\ncount units group player; // returns number of units in player group\n```","code":["count [0, 0, 1, 2]; // returns 4\ncount units group player; // returns number of units in player group"]},{"text":"```sqf\nprivate _cnt = { _x == 4 } count [1, 9, 8, 3, 4, 4, 4, 5, 6]; // returns 3\n_cnt = { alive _x } count allUnits; // returns the number of alive units\n```","code":["private _cnt = { _x == 4 } count [1, 9, 8, 3, 4, 4, 4, 5, 6]; // returns 3\n_cnt = { alive _x } count allUnits; // returns the number of alive units"]},{"text":"```sqf\nprivate _cnt = count (configFile >> \"CfgVehicles\");\n```","code":["private _cnt = count (configFile >> \"CfgVehicles\");"]},{"text":"```sqf\nhint str count \"japa is the man!\"; // 16\n```","code":["hint str count \"japa is the man!\"; // 16"]},{"text":"```sqf\nhint format [\"There are %1 elements in the provided hashmap\", count _myHashMap];\n```","code":["hint format [\"There are %1 elements in the provided hashmap\", count _myHashMap];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["apply","select","in","find","countFriendly","countEnemy","countUnknown","countSide","countType","findIf","forceUnicode"],"notes":[{"user":"Hardrock","date":"2006-08-03T14:27:00Z","text":"*Notes from before the conversion:*\n\nUse this to calculate how many \"M16\" mags a soldier has left.\n\n```sqf\n{ _x == \"M16\" } count magazines soldier1;\n```\n\nTake care when using count to determine how many units are left alive in a group: count units group player or count units groupname Will return the number of units the leader of the group thinks are alive. If some units have been killed out of sight of other members of the group then it may take sometime for this to be the actual numbers in the group. To determine exactly how many units are really alive in a group use:\n\n```sqf\n{ alive _x } count units group player;\n```\n\nor\n\n```sqf\n{ alive _x } count units groupname;\n```"},{"user":"Heeeere's Johnny!","date":"2014-12-15T00:01:00Z","text":"*count* can be (ab)used for a very fast and simple check if at least one element in an array fulfills a certain condition:\n\n```sqf\nif ({ if (/* _x fulfills condition */) exitWith {1}; false } count _array isEqualTo 1) then\n{\n    // do whatever here\n};\n```\n\nThis code will exit the *count* loop as soon as it finds an element fulfilling the condition, leaving the *count* with the value of 1, hence make the larger if-condition be *true*.\n\nIf no array element fulfills the condition, the *count* will be 0 and the if-condition will be *false*."},{"user":"Killzone_Kid","date":"2014-12-29T21:23:00Z","text":"Quit loop at first fulfilled condition (same as above but faster):\n\n```sqf\n{\n    if (_x == 4) exitWith {\n        // do something when we reach 4\n    }\n} count [1,2,3,4,5,6];\n```"},{"user":"Heeeere's Johnny!","date":"2015-01-02T22:32:00Z","text":"Using exitWith inside a **count** loop will overwrite the default functionality and make **count** return whatever the **exitWith** returns:\n\n```sqf\n_result = {\n    if (_x isEqualTo 3) exitWith { \"Hello\" }\n} count [1,2,3,4,5];\n// _result = \"Hello\"\n```"},{"user":"Ebay","date":"2016-08-22T19:41:00Z","text":"With the alternative syntax each iteration should result in an interior return of bool or nothing. Example:\n\n```sqf\ncreateDialog \"RscFunctionsViewer\";\n{ lbAdd [292901, _x]; } count [\"first\", \"second\", \"third\"];\n```\n\nlbAdd returns a number, so this throws \"Error Type Number, expected Bool\". Tested in A2OA 1.63.131129"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Config","Command Group: HashMap","Command Group: Strings","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"countEnemy","operator":null,"title":"countEnemy","type":"command","url":"https://community.bistudio.com/wiki/countEnemy","revid":377183,"updated":"2026-01-01T10:50:22Z","groups":["Sides","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Count how many units in the array are considered enemy to the given unit.","syntaxes":[{"syntax":"unit countEnemy others","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"others","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"others: Array of Objects"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"others","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n_num = player countEnemy list _triggerOne;\n```","code":["_num = player countEnemy list _triggerOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["countFriendly","count","countUnknown","countSide","countType"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"countFriendly","operator":null,"title":"countFriendly","type":"command","url":"https://community.bistudio.com/wiki/countFriendly","revid":377182,"updated":"2026-01-01T10:49:48Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Count how many units in the array are considered friendly to the given unit.","syntaxes":[{"syntax":"unit countFriendly others","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"others","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"others: Array of Objects"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"others","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n_num = player countFriendly list _triggerOne;\n```","code":["_num = player countFriendly list _triggerOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["count","countEnemy","countUnknown","countSide","countType"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"countSide","operator":null,"title":"countSide","type":"command","url":"https://community.bistudio.com/wiki/countSide","revid":378522,"updated":"2026-05-04T01:53:42Z","groups":["Sides","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns how many units in the given array belong to given side.","syntaxes":[{"syntax":"side countSide array","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"array","type":"Array of Objects or Groups","optional":false,"default":null,"description":"Array of Objects or Groups\n\n> [!NOTE]\n> If the object in passed array is a Group, the leader of the group will be counted.","types":["Array","Object","Group"],"since":null,"text":"array: Array of Objects or Groups\n\n> [!NOTE]\n> If the object in passed array is a Group, the leader of the group will be counted."}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"side","types":["Side"]},"right":{"text":"array","types":["Array","Object","Group"]}}],"examples":[{"text":"```sqf\n_num = west countSide list _triggerOne;\n```","code":["_num = west countSide list _triggerOne;"]},{"text":"```sqf\n_numCivPlayable = civilian countSide playableUnits;\n```","code":["_numCivPlayable = civilian countSide playableUnits;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["countFriendly","countEnemy","countUnknown","count","countType","playersNumber","units","allUnits"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"countType","operator":null,"title":"countType","type":"command","url":"https://community.bistudio.com/wiki/countType","revid":377068,"updated":"2026-01-01T09:25:18Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Count how many objects in the array are of given type. This command also works with parent classes like \"Air\", \"Tank\", and \"Car\". For a full class reference see Classes.","syntaxes":[{"syntax":"type countType objects","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"class type","types":["String"],"since":null,"text":"type: String - class type"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n_count = \"Tank\" countType list _triggerOne;\n```","code":["_count = \"Tank\" countType list _triggerOne;"]},{"text":"```sqf\n_count = \"B_medic_F\" countType units player;\n```","code":["_count = \"B_medic_F\" countType units player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["count","isKindOf","typeOf","countFriendly","countEnemy","countSide","countUnknown"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"countUnknown","operator":null,"title":"countUnknown","type":"command","url":"https://community.bistudio.com/wiki/countUnknown","revid":377181,"updated":"2026-01-01T10:49:16Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Count how many units in the array are unknown to the given unit.","syntaxes":[{"syntax":"unit countUnknown others","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"others","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"others: Array of Objects"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"others","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n_num = player countUnknown list _triggerOne;\n```","code":["_num = player countUnknown list _triggerOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["countFriendly","countEnemy","count","countSide","countType"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"create3DENComposition","operator":null,"title":"create3DENComposition","type":"command","url":"https://community.bistudio.com/wiki/create3DENComposition","revid":377506,"updated":"2026-01-02T06:50:07Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create new Composition. To create individual entities, use create3DENEntity.","syntaxes":[{"syntax":"create3DENComposition [configPath, position]","since":null,"effect":null,"exec":null,"params":[{"name":"configPath","type":"Config","optional":false,"default":null,"description":"path to `CfgGroups` or since Arma 3 v2.18 `configFile >> \"Cfg3DEN\" >> \"Compositions\"` class of a composition","types":["Config"],"since":null,"text":"configPath: Config - path to `CfgGroups` or since Arma 3 v2.18 `configFile >> \"Cfg3DEN\" >> \"Compositions\"` class of a composition"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Array of Eden Entities","types":["Array","Eden Entity"],"description":null,"text":"Array of Eden Entities"},"form":"unary","operator":null,"left":null,"right":{"text":"[configPath, position]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyComposition = create3DENComposition [\n    configFile >> \"CfgGroups\" >> \"West\" >> \"BLU_F\" >> \"Infantry\" >> \"BUS_InfSquad\",\n    screenToWorld [0.5, 0.5]\n];\n```","code":["myComposition = create3DENComposition [\n\tconfigFile >> \"CfgGroups\" >> \"West\" >> \"BLU_F\" >> \"Infantry\" >> \"BUS_InfSquad\",\n\tscreenToWorld [0.5, 0.5]\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["create3DENEntity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"create3DENEntity","operator":null,"title":"create3DENEntity","type":"command","url":"https://community.bistudio.com/wiki/create3DENEntity","revid":377519,"updated":"2026-01-02T06:52:05Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create new Eden Entity. Used for creating individual entities; to create a composition (e.g., infantry squad), use create3DENComposition and to create a layer use add3DENLayer.\n\nThis is the only way to add new editable entities to an Eden Editor scenario. Other 'create' commands like createVehicle or createUnit will still work, but the resulting entity will not be editable.","syntaxes":[{"syntax":"create3DENEntity [mode, class, position, isEmpty]","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"String","optional":false,"default":null,"description":"can be \"Object\", \"Trigger\", \"Waypoint\", \"Logic\", \"Marker\" or Arma 3 v2.14 \"Comment\"","types":["String"],"since":null,"text":"mode: String - can be \"Object\", \"Trigger\", \"Waypoint\", \"Logic\", \"Marker\" or Arma 3 v2.14 \"Comment\""},{"name":"class","type":"String","optional":false,"default":null,"description":"entity class, defined in one of the following classes:\n- `CfgVehicles` - objects and logic entities\n- `CfgNonAIVehicles` - triggers\n- `CfgWaypoint` - waypoints\n- `CfgMarkers` - markers","types":["String"],"since":null,"text":"class: String - entity class, defined in one of the following classes:\n- `CfgVehicles` - objects and logic entities\n- `CfgNonAIVehicles` - triggers\n- `CfgWaypoint` - waypoints\n- `CfgMarkers` - markers"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"isEmpty","type":"Boolean","optional":true,"default":"false","description":"true to create vehicle without crew","types":["Boolean"],"since":null,"text":"isEmpty: Boolean - (Optional, default false) true to create vehicle without crew"}],"returns":{"type":"Eden Entity (Eden_ID for Comment)","types":["Eden Entity","Eden ID"],"description":null,"text":"Eden Entity (Eden_ID for Comment)"},"form":"unary","operator":null,"left":null,"right":{"text":"[mode, class, position, isEmpty]","types":["Array"]}},{"syntax":"group create3DENEntity [mode, class, position]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"group in which an AI character or waypoint is created.\n- When missing for AI characters, a new group is created for them\n- When missing for waypoints, an error is logged and nothing is created\n- When used on any other mode, it is ignored and the entity is created as usual","types":["Group"],"since":null,"text":"group: Group - group in which an AI character or waypoint is created.\n- When missing for AI characters, a new group is created for them\n- When missing for waypoints, an error is logged and nothing is created\n- When used on any other mode, it is ignored and the entity is created as usual"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be \"Object\", \"Trigger\", \"Waypoint\", \"Logic\", \"Marker\" or Arma 3 v2.14 \"Comment\"","types":["String"],"since":null,"text":"mode: String - can be \"Object\", \"Trigger\", \"Waypoint\", \"Logic\", \"Marker\" or Arma 3 v2.14 \"Comment\""},{"name":"class","type":"String","optional":false,"default":null,"description":"entity class","types":["String"],"since":null,"text":"class: String - entity class"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Eden Entity (Eden_ID for Comment)","types":["Eden Entity","Eden ID"],"description":null,"text":"Eden Entity (Eden_ID for Comment)"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"[mode, class, position]","types":["Array"]}}],"examples":[{"text":"```sqf\ndude1 = create3DENEntity [\"Object\", \"B_Soldier_F\", screenToWorld [0.5, 0.5]];\n```","code":["dude1 = create3DENEntity [\"Object\", \"B_Soldier_F\", screenToWorld [0.5, 0.5]];"]},{"text":"```sqf\ndude2 = group dude1 create3DENEntity [\"Object\", \"B_Soldier_AR_F\", screenToWorld [0.5, 0.5]];\n```","code":["dude2 = group dude1 create3DENEntity [\"Object\", \"B_Soldier_AR_F\", screenToWorld [0.5, 0.5]];"]},{"text":"```sqf\nmyMarker = create3DENEntity [\"Marker\", \"mil_warning\", getPosATL player];\n```","code":["myMarker = create3DENEntity [\"Marker\", \"mil_warning\", getPosATL player];"]},{"text":"```sqf\nmytrigger = create3DENEntity [\"Trigger\", \"EmptyDetectorArea10x10\", getPosATL player];\n```","code":["mytrigger = create3DENEntity [\"Trigger\", \"EmptyDetectorArea10x10\", getPosATL player];"]},{"text":"Arma 3 v2.06 Create a shape marker:\n\n```sqf\nm = create3DENEntity [\"Marker\", \"\", getPosATL player];    // default rectangular marker\nm set3DENAttribute [\"markerType\", 1];                    // 0 - rectangle; 1 - ellipse\nm set3DENAttribute [\"brush\", \"DiagGrid\"];\n```","code":["m = create3DENEntity [\"Marker\", \"\", getPosATL player];\t// default rectangular marker\nm set3DENAttribute [\"markerType\", 1];\t\t\t\t\t// 0 - rectangle; 1 - ellipse\nm set3DENAttribute [\"brush\", \"DiagGrid\"];"]},{"text":"Arma 3 v2.14 Create a comment:\n\n```sqf\nmyComment = create3DENEntity [\"Comment\", \"loc_talk\", [0,0,0]];\nmyComment set3DENAttribute [\"name\", \"Title Here\"];\nmyComment set3DENAttribute [\"description\", \"Tooltip Here\"];\n```","code":["myComment = create3DENEntity [\"Comment\", \"loc_talk\", [0,0,0]];\nmyComment set3DENAttribute [\"name\", \"Title Here\"];\nmyComment set3DENAttribute [\"description\", \"Tooltip Here\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["create3DENComposition","delete3DENEntities","add3DENLayer"],"notes":[{"user":"R3vo","date":"2019-09-06T08:33:00Z","text":"To create a waypoint, use the alternative syntax and pass the group which should receive it as the left-hand argument."},{"user":"POLPOX","date":"2022-10-09T07:26:29Z","text":"Due to an unknown reason, you cannot create3DENEntity animals, will cause a crash of the game."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"createAgent","operator":null,"title":"createAgent","type":"command","url":"https://community.bistudio.com/wiki/createAgent","revid":378352,"updated":"2026-04-02T16:33:41Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Creates an agent of the given type. An agent does not have a group or leader or the standard soldier FSM associated with it - for instance, an enemy soldier spawned as an agent has limited AI and will do nothing when fired upon - which can be useful to limit the amount of AI processing being done in a mission with very large numbers of \"AI\". Animals are also commonly created as agents.\n\n> [!NOTE]\n> - Players assigned to an agent using selectPlayer will be able to control the agent, operate weapons and other actions, but will not be able to access their inventory using the gear screen.\n> - To create objects of type `\"Logic\"`, use createUnit.","syntaxes":[{"syntax":"createAgent [type, position, markers, placement, special]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"class from CfgVehicles","types":["String"],"since":null,"text":"type: String - class from CfgVehicles"},{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"desired placement position","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D - desired placement position"},{"name":"markers","type":"Array of Strings","optional":false,"default":null,"description":"if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position. If any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate.","types":["Array","String"],"since":null,"text":"markers: Array of Strings - if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position. If any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate."},{"name":"placement","type":"Number","optional":false,"default":null,"description":"placement radius, the unit is randomly place in a circle with this radius","types":["Number"],"since":null,"text":"placement: Number - placement radius, the unit is randomly place in a circle with this radius"},{"name":"special","type":"String","optional":false,"default":null,"description":"one of:\n- `\"NONE\"` - will look for a suitable empty position near given position (subject to other placement params) before creating the agent\n- `\"CAN_COLLIDE\"` - creates the agent at given position (subject to other placement params), without checking if others objects can cross its 3D model","types":["String"],"since":null,"text":"special: String - one of:\n- `\"NONE\"` - will look for a suitable empty position near given position (subject to other placement params) before creating the agent\n- `\"CAN_COLLIDE\"` - creates the agent at given position (subject to other placement params), without checking if others objects can cross its 3D model"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, markers, placement, special]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _agent = createAgent [\"B_Soldier_F\", getPosATL player, [], 0, \"NONE\"];\n```","code":["private _agent = createAgent [\"B_Soldier_F\", getPosATL player, [], 0, \"NONE\"];"]},{"text":"```sqf\nprivate _agent = createAgent [\"Snake_random_F\", ASLToAGL getPosASL player, [], 0, \"CAN_COLLIDE\"]; // Creates a snake at player's feet\n```","code":["private _agent = createAgent [\"Snake_random_F\", ASLToAGL getPosASL player, [], 0, \"CAN_COLLIDE\"]; // Creates a snake at player's feet"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["agent","agents","isAgent","forEachMemberAgent","execFSM","BIS_fnc_execFSM"],"notes":[{"user":"Killzone_Kid","date":"2014-09-29T20:03:00Z","text":"In Arma 3, default FSM is calling BIS_fnc_animalBehaviour script upon agent creation, which takes on some animal behavioural logic. The problem here is that it is almost impossible to make animal do what is told. Until now. Since Arma 3 v1.32 you can set *BIS_fnc_animalBehaviour_disable* variable on the agent at the moment of agent creation, to override the function.\n\n```sqf\ntr = createTrigger [\"EmptyDetector\", player modelToWorld [0, 10, 0]];\ntr setTriggerArea [5, 5, 0, true];\ntr setTriggerActivation [\"CIV\", \"PRESENT\", true];\nrabbits = [];\nprivate \"_r\";\nfor \"_i\" from 1 to 10 do {\n    _r = createAgent [\"Rabbit_F\", position tr, [], 0, \"NONE\"];\n    _r setVariable [\"BIS_fnc_animalBehaviour_disable\", true];\n    rabbits pushBack _r;\n};\ntr setTriggerStatements [\n    \"if (rabbits isEqualTo thisList) exitWith {\n        _r = thisList select floor random count thisList;\n        _r moveTo (_r modelToWorld [2.5 - random 5, 2.5 - random 5, 0]);\n    };\n    _esc = rabbits - thisList;\n    doStop _esc;\n    {_x moveTo position thisTrigger} forEach _esc;\n    systemChat str [time, _esc];\n    false\",\n    \"\",\n    \"\"\n];\n```"},{"user":"Waffle SS.","date":"2015-04-18T07:17:00Z","text":"Agents seem to use the same collision model that the player uses, unlike normal AI. Normal AI don't collide with objects, but agents are physically stopped by obstacles the same way players are. This also probably means agents cost more resources than normal AI."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createCenter","operator":null,"title":"createCenter","type":"command","url":"https://community.bistudio.com/wiki/createCenter","revid":353367,"updated":"2024-03-15T17:11:57Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Instanciate a Side center. A Side center is required to be able to create groups of this side.\n\nCenters can only be created for east, west, resistance, civilian and sideLogic sides.\n\nCreated sides must have their \"side-friendship\" defined with setFriend.\n\n> [!NOTE]\n> In Armed Assault and Arma 2, only Mission.sqm's units side centers are created; e.g if no resistance unit has been placed in the editor you must use createCenter before being able to create a resistance group.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, centers for all sides are all created by the engine.","syntaxes":[{"syntax":"createCenter side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\ncreateCenter east;\n```","code":["createCenter east;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteCenter","createUnit","createGroup","createVehicle","side","Side"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createDialog","operator":null,"title":"createDialog","type":"command","url":"https://community.bistudio.com/wiki/createDialog","revid":338553,"updated":"2023-03-19T00:02:56Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Creates a dialog which is defined either in the mission's description.ext, in the campaign's description.ext or in the global resource.cpp. The given name has to be the class name used in one of these files. If another dialog is already opened, the desired dialog is created as a child dialog of the one already opened.\n\n> [!NOTE]\n> By default, displays created with createDisplay are rendered on top of dialogs created with createDialog. If *forceOnTop* is set to true, the dialog will be rendered on top of displays.","syntaxes":[{"syntax":"createDialog dialogName","since":null,"effect":null,"exec":null,"params":[{"name":"dialogName","type":"String","optional":false,"default":null,"description":"class name used in the description.ext, resource.cpp or config.cpp","types":["String"],"since":null,"text":"dialogName: String - class name used in the description.ext, resource.cpp or config.cpp"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when the dialog was created successfully","text":"Boolean -  true when the dialog was created successfully"},"form":"unary","operator":null,"left":null,"right":{"text":"dialogName","types":["String"]}},{"syntax":"createDialog [dialogName, forceOnTop]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"dialogName","type":"String","optional":false,"default":null,"description":"class name used in the description.ext, resource.cpp or config.cpp","types":["String"],"since":null,"text":"dialogName: String - class name used in the description.ext, resource.cpp or config.cpp"},{"name":"forceOnTop","type":"Boolean","optional":true,"default":"false","description":"if true, dialog will be rendered on top of displays","types":["Boolean"],"since":null,"text":"forceOnTop: Boolean - (Optional, default false) if true, dialog will be rendered on top of displays"}],"returns":{"type":"Display","types":["Display"],"description":"created dialog","text":"Display - created dialog"},"form":"unary","operator":null,"left":null,"right":{"text":"[dialogName, forceOnTop]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _ok = createDialog \"RscDisplayGame\";\nif (!_ok) then { hint \"Dialog could not be opened!\" };\n```","code":["private _ok = createDialog \"RscDisplayGame\";\nif (!_ok) then { hint \"Dialog could not be opened!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayCtrl","createDisplay","closeDialog","dialog","displayNull","controlNull","ctrlCreate","displayParent"],"notes":[{"user":"Killzone_Kid","date":"2017-07-29T09:04:00Z","text":"A user dialog created with createDisplay over mission display (findDisplay 46) will stop display event handlers added to mission display from firing. However if it is created with createDialog then the event handlers continue to work."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createDiaryLink","operator":null,"title":"createDiaryLink","type":"command","url":"https://community.bistudio.com/wiki/createDiaryLink","revid":325179,"updated":"2022-07-01T14:35:13Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a link to the given diary entry.","syntaxes":[{"syntax":"createDiaryLink [subject, record, text]","since":null,"effect":null,"exec":null,"params":[{"name":"subject","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"subject: String"},{"name":"record","type":"Object, Task or Diary Record","optional":false,"default":null,"description":null,"types":["Object","Task","Diary Record"],"since":null,"text":"record: Object, Task or Diary Record"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"String","types":["String"],"description":"empty string or a string similar to the result of `format [\"<log subject=\"\"%1\"\" record=\"\"%2\"\">%3</log>\", subject, processedRecordId, text]`","text":"String - empty string or a string similar to the result of `format [\"<log subject=\"\"%1\"\" record=\"\"%2\"\">%3</log>\", subject, processedRecordId, text]`"},"form":"unary","operator":null,"left":null,"right":{"text":"[subject, record, text]","types":["Array"]}}],"examples":[{"text":"```sqf\n_diaryRec1 = player createDiaryRecord [\"Diary\", [\"Record 1\", \"We can not refer to the next record because it does not exist yet.\"]];\n_diaryRec2 = player createDiaryRecord [\"Diary\", [\"Record 2\", \"Go to \" + createDiaryLink [\"Diary\", _diaryRec1, \"record 1\"]]];\n_diaryRec3 = player createDiaryRecord [\"Diary\", [\"Record 3\", \"Go to \" + createDiaryLink [\"Diary\", _diaryRec2, \"record 2\"]]];\n```","code":["_diaryRec1 = player createDiaryRecord [\"Diary\", [\"Record 1\", \"We can not refer to the next record because it does not exist yet.\"]];\n_diaryRec2 = player createDiaryRecord [\"Diary\", [\"Record 2\", \"Go to \" + createDiaryLink [\"Diary\", _diaryRec1, \"record 1\"]]];\n_diaryRec3 = player createDiaryRecord [\"Diary\", [\"Record 3\", \"Go to \" + createDiaryLink [\"Diary\", _diaryRec2, \"record 2\"]]];"]},{"text":"In this example, one can go to any next record.\n\n```sqf\nTAG_fnc_processDiaryLink = {\n    processDiaryLink createDiaryLink [\"Diary\", _this, \"\"];\n};\nDiaryRec1 = player createDiaryRecord [\"Diary\", [\"Record 1\", \n    \"Go to <execute expression='DiaryRec2 call TAG_fnc_processDiaryLink'>Record 2</execute>\"\n]];\nDiaryRec2 = player createDiaryRecord [\"Diary\", [\"Record 2\", \n    \"Go to <execute expression='DiaryRec3 call TAG_fnc_processDiaryLink'>Record 3</execute>\"\n]];\nDiaryRec3 = player createDiaryRecord [\"Diary\", [\"Record 3\", \n    \"Go to <execute expression='DiaryRec1 call TAG_fnc_processDiaryLink'>Record 1</execute>\"\n]];\n```","code":["TAG_fnc_processDiaryLink = {\n\tprocessDiaryLink createDiaryLink [\"Diary\", _this, \"\"];\n};\nDiaryRec1 = player createDiaryRecord [\"Diary\", [\"Record 1\", \n\t\"Go to <execute expression='DiaryRec2 call TAG_fnc_processDiaryLink'>Record 2</execute>\"\n]];\nDiaryRec2 = player createDiaryRecord [\"Diary\", [\"Record 2\", \n\t\"Go to <execute expression='DiaryRec3 call TAG_fnc_processDiaryLink'>Record 3</execute>\"\n]];\nDiaryRec3 = player createDiaryRecord [\"Diary\", [\"Record 3\", \n\t\"Go to <execute expression='DiaryRec1 call TAG_fnc_processDiaryLink'>Record 1</execute>\"\n]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["processDiaryLink","createDiaryRecord","createDiarySubject","diarySubjectExists","setDiaryRecordText"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createDiaryRecord","operator":null,"title":"createDiaryRecord","type":"command","url":"https://community.bistudio.com/wiki/createDiaryRecord","revid":370359,"updated":"2024-12-02T16:08:54Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Creates a Diary entry. Supported tags and their parameters:\n\n| Tag | Options | Example |\n|---|---|---|\n| img | - *image*: String - path to image. When present, any element with it will be displayed as image.<br>- *width*: Number - image width in pixels.<br>- *height*: Number - image height in pixels.<br>- Arma 3 v2.10 *title*: String - tooltip to show on mouse over image<br>- Arma 3 v2.10 *src*: String - alternative to 'image'<br>> [!NOTE]<br>> **Arma 3:** Maximum width supported seems to be **370** pixels as a wider image will be cut off. Height should be calculated with the aspect ratio of the image. `height = 370; ratio = 16/9; height = width / ratio;` | ```html<br><img image=\"picture.paa\" width=\"128\" height=\"64\" /><br>```<br>Since Arma 3 v2.10:<br>```html<br><img src=\"picture.paa\" width=\"128\" height=\"64\" title=\"this is an image\" /><br>``` |\n| font | - *color*: String - [HTML color](https://en.wikipedia.org/wiki/HTML_color) in format #aarrggbb or #rrggbb<br>- *size*: Number - font height in pixels (default: 14)<br>- *face*: String - font type (see Fonts) | ```html<br><font color=\"#FF00FF\" size=\"16\" face=\"LucidaConsoleB\">Hello there</font><br>``` |\n| br | N/A | ```html<br>Line 1<br />Line 2<br>``` |\n| marker | - *name*: String - marker name | ```html<br><marker name=\"respawn_west\">Respawn point</marker><br>``` |\n| execute | - *expression*: String - executed code | ```html<br><execute expression=\"player setDamage 1\">Die!</execute><br>``` |\n| executeClose | - *expression*: String - executed code, diary is closed afterwards | ```html<br><executeClose expression=\"player setDamage 1\">Die and close</executeClose><br>``` |\n| log | - *subject*: String - subject name.<br>- *record*: String - record ID (e.g. \"Record6\" or \"Unit1059524\") | ```html<br><log subject=\"Hello\">Get to the \"Hello\" subject</log><br>```<br>```html<br><log subject=\"Hello\" record=\"Record0\">Go to the first record added to \"Hello\"</log><br>``` |\n| gear | - *unit*: Number - unit ID | ```html<br><gear unit=\"123456\">Open unit 123456's gear</gear><br>``` |\n| teamSwitch | - *unit*: Number - unit ID | ```html<br><teamSwitch unit=\"123456\">Switch to unit 123456</teamSwitch><br>``` |\n| kick | - *id*: Number - unit ID | ```html<br><kick unit=\"123456\">Kick player unit 123456</kick><br>``` |\n| ban | - *id*: Number - unit ID | ```html<br><ban unit=\"123456\">ban player unit 123456</ban><br>``` |\n| mute | - *id*: Number - unit ID | ```html<br><mute unit=\"123456\">mute player unit 123456</mute><br>``` |\n| voteadmin | - *id*: Number - unit ID | ```html<br><voteadmin unit=\"123456\">vote admin unit 123456</voteadmin><br>``` |\n| votekick | - *id*: Number - unit ID | ```html<br><votekick unit=\"123456\">vote kick player unit 123456</votekick><br>``` |\n| currentTask | - *id*: Number - task ID<br>- *action*: String - 'n' or 's' (select) | ```html<br><currentTask id=\"my_task\">get to my_task task</currentTask><br>``` |\n\n> [!NOTE]\n> If the createDiaryRecord command fails, it returns a null record.\n> Before Arma 3 v2.00, isNull did not work with the diary record type and diaryRecordNull did not exist.\n> In order to verify a null record, it is possible to create a variable and compare against it:\n>\n> ```sqf\n> private _recordNull = objNull createDiaryRecord [];\n> private _createdRecord = player createDiaryRecord [\"Diary\", [\"Title\", \"Description\"]];\n> if (_createdRecord isEqualTo _recordNull) then { hint \"Failed\"; };\n> ```","syntaxes":[{"syntax":"player createDiaryRecord [subject, textInfo, task, taskState, showTitle]","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"subject","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"subject: String"},{"name":"textInfo","type":"String or Array of Strings","optional":true,"default":null,"description":"can be:\n- String - the record's content - its title will be empty\n- Array of Strings - format [title, text, icon]:\n  - title: String\n  - text: String\n  - Arma 3 v2.10 icon: String -  icon to show next to the title","types":["String","Array"],"since":null,"text":"textInfo: String or Array of Strings - can be:\n- String - the record's content - its title will be empty\n- Array of Strings - format [title, text, icon]:\n  - title: String\n  - text: String\n  - Arma 3 v2.10 icon: String - (Optional) icon to show next to the title"},{"name":"task","type":"Task","optional":true,"default":"taskNull","description":null,"types":["Task"],"since":null,"text":"task: Task - (Optional, default taskNull)"},{"name":"taskState","type":"String","optional":true,"default":"`\"NONE\"`","description":"changes the state of the given task. Can be one of:\n- `\"NONE\"`\n- `\"CREATED\"`\n- `\"ASSIGNED\"`\n- `\"SUCCEEDED\"`\n- `\"FAILED\"`\n- `\"CANCELED\"`","types":["String"],"since":null,"text":"taskState: String - (Optional, default `\"NONE\"`) changes the state of the given task. Can be one of:\n- `\"NONE\"`\n- `\"CREATED\"`\n- `\"ASSIGNED\"`\n- `\"SUCCEEDED\"`\n- `\"FAILED\"`\n- `\"CANCELED\"`"},{"name":"showTitle","type":"Boolean","optional":true,"default":"true","description":"whether or not to show title in the description section as well","types":["Boolean"],"since":"arma3 1.96","text":"showTitle: Boolean - (Optional, default true) whether or not to show title in the description section as well"}],"returns":{"type":"Diary Record","types":["Diary Record"],"description":null,"text":"Diary Record"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"[subject, textInfo, task, taskState, showTitle]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", [\"Intel\", \"Enemy base is on grid <marker name='enemyBase'>161170</marker>\"]];\n```","code":["player createDiaryRecord [\"Diary\", [\"Intel\", \"Enemy base is on grid <marker name='enemyBase'>161170</marker>\"]];"]},{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", \"Information gathered.<br /><img image='wellDone_ca.paa' />\"];\n```","code":["player createDiaryRecord [\"Diary\", \"Information gathered.<br /><img image='wellDone_ca.paa' />\"];"]},{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", [\"Title\", \"Description\"], taskNull, \"\", false];\n```","code":["player createDiaryRecord [\"Diary\", [\"Title\", \"Description\"], taskNull, \"\", false];"]},{"text":"```sqf\nplayer createDiaryRecord [\n    \"Diary\",\n    [\"Font tag\", \"<font color='#7FFF00' size='30' face='TahomaB'>This will changed text size, colour and font</font>\"],\n    taskNull,\n    \"\",\n    false\n];\n```","code":["player createDiaryRecord [\n\t\"Diary\",\n\t[\"Font tag\", \"<font color='#7FFF00' size='30' face='TahomaB'>This will changed text size, colour and font</font>\"],\n\ttaskNull,\n\t\"\",\n\tfalse\n];"]},{"text":"```sqf\nplayer createDiaryRecord [\n    \"Diary\",\n    [\"Image\", \"<img image='\\A3\\Ui_F_Curator\\Data\\Logos\\arma3_curator_artwork.jpg' width='500' height='800' />\"],\n    taskNull,\n    \"\",\n    false\n];\n```","code":["player createDiaryRecord [\n\t\"Diary\",\n\t[\"Image\", \"<img image='\\A3\\Ui_F_Curator\\Data\\Logos\\arma3_curator_artwork.jpg' width='500' height='800' />\"],\n\ttaskNull,\n\t\"\",\n\tfalse\n];"]},{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", [\"Linebreak\", \"Line1<br />Line2<br /><br />Line4\"], taskNull, \"\", false];\n```","code":["player createDiaryRecord [\"Diary\", [\"Linebreak\", \"Line1<br />Line2<br /><br />Line4\"], taskNull, \"\", false];"]},{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", [\"Execute\",\"<execute expression='hint \"\"Some code\"\";'>Some text</execute>\"], taskNull, \"\", false];\n```","code":["player createDiaryRecord [\"Diary\", [\"Execute\",\"<execute expression='hint \"\"Some code\"\";'>Some text</execute>\"], taskNull, \"\", false];"]},{"text":"```sqf\nplayer createDiaryRecord [\"Diary\", [\"ExecuteClose\", \"<executeClose expression=\"\"hint 'Diary closed';\"\">Close Diary</executeClose>\"], taskNull, \"\", false];\n```","code":["player createDiaryRecord [\"Diary\", [\"ExecuteClose\", \"<executeClose expression=\"\"hint 'Diary closed';\"\">Close Diary</executeClose>\"], taskNull, \"\", false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDiaryRecords","processDiaryLink","createDiaryLink","createDiarySubject","diarySubjectExists","setDiaryRecordText","removeDiaryRecord"],"notes":[{"user":"Tankbuster","date":"2017-03-24T20:11:00Z","text":"When adding multiple diary records, be aware that they appear in reverse order. ie the first one you add will appear last and the last one you add will be first."},{"user":"R3vo","date":"2019-06-22T16:28:00Z","text":"It seems that the **task** parameter has no effect in Arma 3 because the task entry in the briefing menu is created when the task itself was created."},{"user":"Honger","date":"2022-10-18T17:51:12Z","text":"<log>, as `createDiaryLink`, requires declaring **both** subject and ID of the record belonging to said subject. Otherwise generated text will not be clickable or might open a non-existing record (behaviour similar to clicking on map when viewing Diary)."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createDiarySubject","operator":null,"title":"createDiarySubject","type":"command","url":"https://community.bistudio.com/wiki/createDiarySubject","revid":364194,"updated":"2024-05-05T10:46:53Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Creates a new subject in the Diary.","syntaxes":[{"syntax":"player createDiarySubject [subject, displayName, picture]","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"subject","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"subject: String"},{"name":"displayName","type":"String","optional":false,"default":null,"description":"the visible name","types":["String"],"since":null,"text":"displayName: String - the visible name"},{"name":"picture","type":"String","optional":true,"default":"`\"\"`","description":"icon to display next to the subject. Can be set later with setDiarySubjectPicture. Similar to lbSetPictureRight.","types":["String"],"since":null,"text":"picture: String - (Optional, default `\"\"`) icon to display next to the subject. Can be set later with setDiarySubjectPicture. Similar to lbSetPictureRight."}],"returns":{"type":"Number","types":["Number"],"description":"index of the entry that was added","text":"Number - index of the entry that was added"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"[subject, displayName, picture]","types":["Array"]}}],"examples":[{"text":"```sqf\n_index = player createDiarySubject [\"myPage\",\"My page\"];\n```","code":["_index = player createDiarySubject [\"myPage\",\"My page\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeDiarySubject","processDiaryLink","createDiaryLink","createDiaryRecord","diarySubjectExists","setDiarySubjectPicture","allDiarySubjects"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createDisplay","operator":null,"title":"createDisplay","type":"command","url":"https://community.bistudio.com/wiki/createDisplay","revid":369323,"updated":"2024-09-03T18:42:58Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates child display of given display and loads from \"resourceName\". The notable difference between createDisplay and createDialog is that with createDisplay the player would be able to move around while the display is shown.\n\nDisplays created with createDisplay or createDialog will take control of the mouse pointer and will close when user presses <kbd>Esc</kbd>.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.50 createDisplay returns Display and will first look in description.ext for resourceName config, if not found, it will then look in main config.\n\n> [!NOTE]\n> If an *overlay* is needed instead, use cutRsc.","syntaxes":[{"syntax":"parent createDisplay resourceName","since":null,"effect":null,"exec":null,"params":[{"name":"parent","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"parent: Display"},{"name":"resourceName","type":"String","optional":false,"default":null,"description":"custom display class defined in description.ext or existing display class from main config","types":["String"],"since":null,"text":"resourceName: String - custom display class defined in description.ext or existing display class from main config"}],"returns":{"type":"Display (since Arma 3 v1.50, Nothing before)","types":["Display","Nothing"],"description":null,"text":"Display (since Arma 3 v1.50, Nothing before)"},"form":"binary","operator":null,"left":{"text":"parent","types":["Display"]},"right":{"text":"resourceName","types":["String"]}}],"examples":[{"text":"```sqf\nfindDisplay 46 createDisplay \"RscCredits\";\n```","code":["findDisplay 46 createDisplay \"RscCredits\";"]},{"text":"```sqf\n// creates an empty display\nprivate _emptyDisplay = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n```","code":["// creates an empty display\nprivate _emptyDisplay = findDisplay 46 createDisplay \"RscDisplayEmpty\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["closeDisplay","createDialog","displayCtrl","dialog","displayNull","controlNull","ctrlCreate","displayParent"],"notes":[{"user":"MrPineapple","date":"2014-11-15T13:20:00Z","text":"When using createDisplay instead of createDialog, all the commands for working with the controls of the display only work with the control version, not the IDC version:\n\n```sqf\nlbAdd [1234, \"item\"];    // does not work on displays, and won't error either\n_ctrl lbAdd \"item\";        // does work with displays\n```\n\nSo you have to use the control(DisplayCtrl) and not the IDC."},{"user":"Killzone_Kid","date":"2017-06-29T09:02:00Z","text":"A user dialog created with createDisplay over mission display (findDisplay 46) will stop display event handlers added to mission display from firing. However if it is created with createDialog then the event handlers continue to work."},{"user":"Target_practice","date":"2020-06-21T17:01:00Z","text":"Creating a display with the same parent as an existing display will destroy the latter and all of its children. However, their onUnload, onChildDestroyed, and onDestroy event handlers will not fire."},{"user":"7erra","date":"2022-02-05T15:47:14Z","text":"When trying to create a display with createDisplay on a non existing display the command will fail silently and return displayNull."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createGearDialog","operator":null,"title":"createGearDialog","type":"command","url":"https://community.bistudio.com/wiki/createGearDialog","revid":321391,"updated":"2022-05-14T11:20:25Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens gear dialog for given unit.\n\n> [!NOTE]\n> action command can also be used:\n>\n> ```sqf\n> player action [\"Gear\", player];\n> ```","syntaxes":[{"syntax":"createGearDialog [unit, resource]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"resource","type":"String","optional":true,"default":null,"description":null,"types":["String"],"since":null,"text":"resource: String - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, resource]","types":["Array"]}}],"examples":[{"text":"```sqf\ncreateGearDialog [player];\n```","code":["createGearDialog [player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDialog","createDisplay","action"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createGroup","operator":null,"title":"createGroup","type":"command","url":"https://community.bistudio.com/wiki/createGroup","revid":364085,"updated":"2024-05-03T19:33:29Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Creates a new Group for the given Side. Using this command if the group limit is reached will return grpNull. The new Group exists globally, but it's locality is where this command was executed.\n\n|  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|\n| Game | Operation Flashpoint v1.00 | Operation Flashpoint: Elite v1.00 | Armed Assault v1.00 | Arma 2 v1.00 | Arma 2: Operation Arrowhead v1.50 | Take On Helicopters v1.00 | Arma 3 v1.00 | Arma 3 v1.68 |\n| Group auto-deletion | ✗ | ✓ |  |  |  |  |  |  |\n| Group limit per side | 63 | 144 | 288 |  |  |  |  |  |\n\n> [!IMPORTANT]\n> - Groups can only be created for the west/blufor, opfor/east, independent/resistance, civilian and sideLogic sides - any other side will return grpNull\n> - Before Arma 3, a Side center must exist before group creation (either by having editor-placed units or createCenter usage)\n\n> [!NOTE]\n> **Arma 3:** - createCenter usage is not needed anymore as all centers are automatically created.\n> - When the last unit leaves its group, the group usually gets immediately auto-deleted, regardless of its auto-deletion setting.","syntaxes":[{"syntax":"createGroup side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Group","types":["Group"],"description":"grpNull if the group limit is reached","text":"Group - grpNull if the group limit is reached"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}},{"syntax":"createGroup [side, deleteWhenEmpty]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"deleteWhenEmpty","type":"Boolean","optional":false,"default":null,"description":"true to delete the group when empty.\n- If set to true, forces a group to get deleted when empty - it does **not** prevent its deletion by other commands when set to false.\n- Deletion may take up to a minute after the last unit is removed.","types":["Boolean"],"since":null,"text":"deleteWhenEmpty: Boolean - true to delete the group when empty.\n- If set to true, forces a group to get deleted when empty - it does **not** prevent its deletion by other commands when set to false.\n- Deletion may take up to a minute after the last unit is removed."}],"returns":{"type":"Group","types":["Group"],"description":"grpNull if the group limit is reached","text":"Group - grpNull if the group limit is reached"},"form":"unary","operator":null,"left":null,"right":{"text":"[side, deleteWhenEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _group = createGroup east;\n```","code":["private _group = createGroup east;"]},{"text":"```sqf\nprivate _group = createGroup [east, true];\n```","code":["private _group = createGroup [east, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteGroup","deleteGroupWhenEmpty","isGroupDeletedWhenEmpty","group","setGroupId","groupID","units","groupFromNetId","netId","leader","selectLeader","join","createCenter","createUnit","createVehicle","Side"],"notes":[{"user":".kju","date":"2011-01-04T10:19:00Z","text":"A group created with createGroup will get a waypoint at [0,0,0]. When you use createUnit to fill it with units, it will get an additional waypoint at the position the first unit is created. This new waypoint will also be set as currentWaypoint. However keep these two waypoints in mind when you do some scripting involving this groups' waypoints."},{"user":"DreadedEntity","date":"2022-05-04T14:20:23Z","text":"New group is local to the machine that executed the command (**A3 2.08.149102**):\n\n```sqf\nplayer addAction [\"Group Test (Dedicated Server)\", {\n    [[], {\n        _test = createGroup [west, true];\n        [str (local _test)] remoteExec [\"hint\", -2]; //tell all clients group locality; true\n        missionNamespace setVariable [\"Group_Reference\", _test, true]; //broadcast group reference to all players\n    }] remoteExec [\"call\", 2]; //create group on dedicated server only\n    sleep 1;\n    _newGroup = missionNamespace getVariable \"Group_Reference\"; //receive group reference from server\n    systemChat format [\"Group local to player: %1\", local _newGroup]; //false\n}];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createGuardedPoint","operator":null,"title":"createGuardedPoint","type":"command","url":"https://community.bistudio.com/wiki/createGuardedPoint","revid":348606,"updated":"2023-11-08T13:45:17Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds a point guarded by the given side (scripted way of adding equivalent of \"GUARDED BY\" trigger in Editor). A closest AI group in the given side with assigned \"GUARD\" waypoint will attempt to secure this guard point. The actual guarded position is determined via the following rules:\n- Given \"position\" is always considered. It could be Object, Group, Position2D or Position3D. In every case, z coordinate will be ignored and point will be placed on nearest surface.\n- If \"objectMapID\" is not negative, the position of the object with the given ID is used (Overrides \"position\"). -1 to ignore this argument. z of the object position will be intact.\n- If the given \"vehicle\" is valid, the position of the vehicle is extracted and guarded (Overrides both \"position\" and \"objectMapID\"). objNull to ignore. z of the vehicle position will be intact.\nTo be used with \"GUARD\" waypoint.\n\n> [!NOTE]\n> To know how does the \"GUARD\" waypoint work, see Waypoint:Guard.","syntaxes":[{"syntax":"createGuardedPoint [side, position, objectMapID, vehicle]","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"the side which will be guarding","types":["Side"],"since":null,"text":"side: Side - the side which will be guarding"},{"name":"position","type":"Object, Group, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Group","Position2D","Position3D"],"since":null,"text":"position: Object, Group, Position2D or Position3D"},{"name":"objectMapID","type":"Number","optional":false,"default":null,"description":"static id of map object. -1 to ignore","types":["Number"],"since":null,"text":"objectMapID: Number - static id of map object. -1 to ignore"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be used for position. objNull to ignore","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to be used for position. objNull to ignore"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[side, position, objectMapID, vehicle]","types":["Array"]}}],"examples":[{"text":"```sqf\ncreateGuardedPoint [east, [0,0], -1, vehicle player];\n```","code":["createGuardedPoint [east, [0,0], -1, vehicle player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","addWaypoint","setWaypointType"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createHashMap","operator":null,"title":"createHashMap","type":"command","url":"https://community.bistudio.com/wiki/createHashMap","revid":308959,"updated":"2022-04-18T21:22:24Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a new empty HashMap.","syntaxes":[{"syntax":"createHashMap","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _myHashMap = createHashMap;\n```","code":["private _myHashMap = createHashMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createHashMapFromArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"createHashMapFromArray","operator":null,"title":"createHashMapFromArray","type":"command","url":"https://community.bistudio.com/wiki/createHashMapFromArray","revid":377214,"updated":"2026-01-02T00:12:06Z","groups":["HashMap","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a new HashMap and initializes it from a key-value pair array","syntaxes":[{"syntax":"createHashMapFromArray [[key1, value1], [key2, value2], ...]","since":null,"effect":null,"exec":null,"params":[{"name":"keyN","type":"HashMapKey","optional":false,"default":null,"description":null,"types":["HashMapKey"],"since":null,"text":"keyN: HashMapKey"},{"name":"valueN","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"valueN: Anything"}],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"unary","operator":null,"left":null,"right":{"text":"[[key1, value1], [key2, value2], ...]","types":["Array"]}},{"syntax":"keys createHashMapFromArray values","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"keys","type":"Array of HashMapKeys","optional":false,"default":null,"description":null,"types":["Array","HashMapKey"],"since":null,"text":"keys: Array of HashMapKeys"},{"name":"values","type":"Array of Anything","optional":false,"default":null,"description":"Array of Anything\n\n> [!NOTE]\n> Size of *keys* and size of *values* arrays do not need to be equal. Missing values will be filled with nil.","types":["Array","Anything"],"since":null,"text":"values: Array of Anything\n\n> [!NOTE]\n> Size of *keys* and size of *values* arrays do not need to be equal. Missing values will be filled with nil."}],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"binary","operator":null,"left":{"text":"keys","types":["Array","HashMapKey"]},"right":{"text":"values","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\ncreateHashMapFromArray [[\"a\", 1], [\"b\", 2], [\"c\", 3]];\n```","code":["createHashMapFromArray [[\"a\", 1], [\"b\", 2], [\"c\", 3]];"]},{"text":"```sqf\n[1, 2, 3, 4] createHashMapFromArray []; // returns [[1, <null>], [2, <null>], [4, <null>], [3, <null>]]\n```","code":["[1, 2, 3, 4] createHashMapFromArray []; // returns [[1, <null>], [2, <null>], [4, <null>], [3, <null>]]"]},{"text":"```sqf\n[1, 2, 3] createHashMapFromArray [\"one\", \"two\", \"three\", \"four\"]; // returns [[1, \"one\"], [2, \"two\"], [3, \"three\"]]\n```","code":["[1, 2, 3] createHashMapFromArray [\"one\", \"two\", \"three\", \"four\"]; // returns [[1, \"one\"], [2, \"two\"], [3, \"three\"]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createHashMap"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"createHashMapObject","operator":null,"title":"createHashMapObject","type":"command","url":"https://community.bistudio.com/wiki/createHashMapObject","revid":377952,"updated":"2026-01-15T10:26:48Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a HashMap with an [Object-Oriented Programming](https://en.wikipedia.org/wiki/Object-oriented_programming) behaviour.\n\nInside a object, Methods (if they are called correctly, either by engine or via call#Syntax 3) will have the objects instance inside the `_self` variable.\n\nThe Destructor (\"#delete\" method) will be executed when the last reference to the objects variable gets deleted. (Except when the mission is ended and all variables are deleted at once)\n\nInheritance: HashMap objects support a simple form of Inheritance.\n\nIt behaves similar to the merge command with overwriteExisting enabled. Sub-class methods and properties with same name, overwrite their Base-class values.\n\nConstructor/Destructor/Clone methods will be merged together and executed in sequence.\n\nFlags entry will use overwrite behaviour.","syntaxes":[{"syntax":"createHashMapObject [classDefinition, constructorArguments]","since":null,"effect":null,"exec":null,"params":[{"name":"classDefinition","type":"HashMap or Array of Arrays, format [name, value]:","optional":false,"default":null,"description":"HashMap or Array of Arrays, format [name, value]:\n*name* can be anything like any other HashMap, but it must be a String for it to be used like an OOP object method (see call#Syntax 3).\n\nSome special values, starting with `1.`, are reserved and expect a specific *value* type (they are all optional):\n- `\"#create\"`: Code - this is the hashmap object's constructor\n- `\"#clone\"`: Code - this is code happening when cloning is done on this hashmap object\n- `\"#delete\"`: Code - this is the hashmap object's destructor. It will always be executed inside missionNamespace.\n- `\"#str\"`: Code - code that is used to evaluate what is displayed when the str function is called on the object - **must** return String\n- `\"#flags\"`: Array of Strings - case-*in*sensitive flags regarding this hashmap object\n  - \"noCopy\": forbids copying, `+_hashMapObject` will throw an error\n  - \"sealed\": prevents from adding and removing any keys - key values can still be edited\n  - \"unscheduled\": all methods (including `1. clone` and `1. create`) will be executed in unscheduled environment\n- `\"#base\"`: Array or HashMap - declaration of base class for inheritance\n- `\"#type\"`: String - can be used to give a object a \"type name\", on inheritance types will be merged into an Array\nNote that all entries beginning with `1.` are reserved, the engine might use these internally without their use being documented.","types":["HashMap","Array"],"since":null,"text":"classDefinition: HashMap or Array of Arrays, format [name, value]:\n*name* can be anything like any other HashMap, but it must be a String for it to be used like an OOP object method (see call#Syntax 3).\n\nSome special values, starting with `1.`, are reserved and expect a specific *value* type (they are all optional):\n- `\"#create\"`: Code - this is the hashmap object's constructor\n- `\"#clone\"`: Code - this is code happening when cloning is done on this hashmap object\n- `\"#delete\"`: Code - this is the hashmap object's destructor. It will always be executed inside missionNamespace.\n- `\"#str\"`: Code - code that is used to evaluate what is displayed when the str function is called on the object - **must** return String\n- `\"#flags\"`: Array of Strings - case-*in*sensitive flags regarding this hashmap object\n  - \"noCopy\": forbids copying, `+_hashMapObject` will throw an error\n  - \"sealed\": prevents from adding and removing any keys - key values can still be edited\n  - \"unscheduled\": all methods (including `1. clone` and `1. create`) will be executed in unscheduled environment\n- `\"#base\"`: Array or HashMap - declaration of base class for inheritance\n- `\"#type\"`: String - can be used to give a object a \"type name\", on inheritance types will be merged into an Array\nNote that all entries beginning with `1.` are reserved, the engine might use these internally without their use being documented."},{"name":"constructorArguments","type":"Anything","optional":true,"default":"Nothing","description":"passed as `_this` argument to the \"#create\" method.","types":["Anything"],"since":null,"text":"constructorArguments: Anything - (Optional, default Nothing) passed as `_this` argument to the \"#create\" method."}],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"unary","operator":null,"left":null,"right":{"text":"[classDefinition, constructorArguments]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _declaration = [\n    [\"#flags\", [\"sealed\"]],\n    [\"#create\", { hint \"Hello!\" }],\n    [\"#clone\", { hint \"We were copied!\" }],\n    [\"#delete\", { hint \"Goodbye\" }],\n    [\"#str\", { \"My HashMap Object\" }],\n    [\"Method\", { hint \"Method has been called\" }]\n];\n\nprivate _hashMapObject = createHashMapObject [_declaration];    // hints \"Hello!\"\n_hashMapObject call [\"Method\"];                                    // hints \"Method has been called\"\nhint str _hashMapObject;                                        // hints \"My HashMap Object\"\nprivate _shallowCopy = _hashMapObject;                            // no hint\nprivate _deepCopy = +_hashMapObject;                            // hints \"We were copied!\"\n// at the end of the scope, _hashMapObject is deleted and hints \"Goodbye\"\n```","code":["private _declaration = [\n\t[\"#flags\", [\"sealed\"]],\n\t[\"#create\", { hint \"Hello!\" }],\n\t[\"#clone\", { hint \"We were copied!\" }],\n\t[\"#delete\", { hint \"Goodbye\" }],\n\t[\"#str\", { \"My HashMap Object\" }],\n\t[\"Method\", { hint \"Method has been called\" }]\n];\n\nprivate _hashMapObject = createHashMapObject [_declaration];\t// hints \"Hello!\"\n_hashMapObject call [\"Method\"];\t\t\t\t\t\t\t\t\t// hints \"Method has been called\"\nhint str _hashMapObject;\t\t\t\t\t\t\t\t\t\t// hints \"My HashMap Object\"\nprivate _shallowCopy = _hashMapObject;\t\t\t\t\t\t\t// no hint\nprivate _deepCopy = +_hashMapObject;\t\t\t\t\t\t\t// hints \"We were copied!\"\n// at the end of the scope, _hashMapObject is deleted and hints \"Goodbye\""]},{"text":"Inheritance constructor/destructor/copy orderings: \n\n```sqf\nprivate _animalDeclaration = [\n    [\"#type\", \"IAnimal\"],\n    [\"#create\", { systemChat \"Animal Init\" }],\n    [\"#clone\", { systemChat \"Animal Copied\" }],\n    [\"#delete\", { systemChat \"Animal Bye\" }]\n];\n\nprivate _pigDeclaration = [\n    [\"#base\", _animalDeclaration],\n    [\"#type\", \"Pig\"],\n    [\"#create\", { systemChat \"Pig Init\" }],\n    [\"#clone\", { systemChat \"Pig Copied\" }],\n    [\"#delete\", { systemChat \"Pig Bye\" }]\n];\n\nprivate _smolPigDeclaration = [\n    [\"#base\", _pigDeclaration],\n    [\"#type\", \"SmolPig\"],\n    [\"#create\", { systemChat \"SmolPig Init\" }],\n    [\"#clone\", { systemChat \"Smol Copied\" }],\n    [\"#delete\", { systemChat \"Smol Bye\" }]\n];\n\nprivate _smolPigInstance = createHashMapObject [_smolPigDeclaration]; // prints \"Animal Init\", \"Pig Init\", \"SmolPig Init\"\nprivate _copy = +_smolPigInstance; // prints \"Animal Copied\", \"Pig Copied\", \"SmolPig Copied\"\n_copy = nil; // prints \"SmolPig Bye\", \"Pig Bye\", \"Animal Bye\"\n```","code":["private _animalDeclaration = [\n\t[\"#type\", \"IAnimal\"],\n\t[\"#create\", { systemChat \"Animal Init\" }],\n\t[\"#clone\", { systemChat \"Animal Copied\" }],\n\t[\"#delete\", { systemChat \"Animal Bye\" }]\n];\n\nprivate _pigDeclaration = [\n\t[\"#base\", _animalDeclaration],\n\t[\"#type\", \"Pig\"],\n\t[\"#create\", { systemChat \"Pig Init\" }],\n\t[\"#clone\", { systemChat \"Pig Copied\" }],\n\t[\"#delete\", { systemChat \"Pig Bye\" }]\n];\n\nprivate _smolPigDeclaration = [\n\t[\"#base\", _pigDeclaration],\n\t[\"#type\", \"SmolPig\"],\n\t[\"#create\", { systemChat \"SmolPig Init\" }],\n\t[\"#clone\", { systemChat \"Smol Copied\" }],\n\t[\"#delete\", { systemChat \"Smol Bye\" }]\n];\n\nprivate _smolPigInstance = createHashMapObject [_smolPigDeclaration]; // prints \"Animal Init\", \"Pig Init\", \"SmolPig Init\"\nprivate _copy = +_smolPigInstance; // prints \"Animal Copied\", \"Pig Copied\", \"SmolPig Copied\"\n_copy = nil; // prints \"SmolPig Bye\", \"Pig Bye\", \"Animal Bye\""]},{"text":"Inheritance type checking:\n\n```sqf\nprivate _animalDeclaration = [\n    [\"#type\", \"IAnimal\"],\n    [\"FurType\", { \"None\" }] // default implementation\n];\n\nprivate _pigDeclaration = [\n    [\"#base\", _animalDeclaration],\n    [\"#type\", \"Pig\"],\n    [\"FurType\", { \"Bristles\" }] // override the base class method\n];\n\nprivate _catDeclaration = [\n    [\"#base\", _animalDeclaration],\n    [\"#type\", \"Cat\"],\n    [\"FurType\", { \"Hair\" }] // override the base class method\n];\n\nprivate _instance = createHashMapObject [selectRandom [_pigDeclaration, _catDeclaration]];\n\nif (\"IAnimal\" in (_instance get \"#type\")) then // check if a object instance is or inherits from a specific type\n{\n    _instance call [\"FurType\"]; // now that we know it implements IAnimal, we know that \"FurType\" method will be present\n};\n```","code":["private _animalDeclaration = [\n\t[\"#type\", \"IAnimal\"],\n\t[\"FurType\", { \"None\" }] // default implementation\n];\n\nprivate _pigDeclaration = [\n\t[\"#base\", _animalDeclaration],\n\t[\"#type\", \"Pig\"],\n\t[\"FurType\", { \"Bristles\" }] // override the base class method\n];\n\nprivate _catDeclaration = [\n\t[\"#base\", _animalDeclaration],\n\t[\"#type\", \"Cat\"],\n\t[\"FurType\", { \"Hair\" }] // override the base class method\n];\n\nprivate _instance = createHashMapObject [selectRandom [_pigDeclaration, _catDeclaration]];\n\nif (\"IAnimal\" in (_instance get \"#type\")) then // check if a object instance is or inherits from a specific type\n{\n\t_instance call [\"FurType\"]; // now that we know it implements IAnimal, we know that \"FurType\" method will be present\n};"]},{"text":"Destructor: \n\n```sqf\nprivate _temporaryVehicle = [\n    [\"#create\", {\n        params [\"_vehicleType\", \"_vehiclePos\", \"_lifetimeSeconds\"]; // handle constructor arguments\n        private _newVehicle = _vehicleType createVehicle _vehiclePos;\n        _self set [\"MyVehicle\", _newVehicle]; // Store the vehicle inside the object for later\n\n        // because _self is passed as parameter, it will be referenced by the spawned script until it ends.\n        [_lifetimeSeconds, _self] spawn { params [\"_lifetimeSeconds\", \"_self\"]; sleep _lifetimeSeconds; };\n    }],\n    [\"#delete\", {\n        deleteVehicle (_self get \"MyVehicle\"); // delete the vehicle when we go away\n    }],\n    [\"MyVehicle\", objNull] // placeholder, this is not needed\n];\n\n// create a temporary RoadCone, at player position, that will delete itself after 5 seconds.\ncreateHashMapObject [_temporaryVehicle, [\"RoadCone_F\", getPos player, 5]];\n```","code":["private _temporaryVehicle = [\n\t[\"#create\", {\n\t\tparams [\"_vehicleType\", \"_vehiclePos\", \"_lifetimeSeconds\"]; // handle constructor arguments\n\t\tprivate _newVehicle = _vehicleType createVehicle _vehiclePos;\n\t\t_self set [\"MyVehicle\", _newVehicle]; // Store the vehicle inside the object for later\n\n\t\t// because _self is passed as parameter, it will be referenced by the spawned script until it ends.\n\t\t[_lifetimeSeconds, _self] spawn { params [\"_lifetimeSeconds\", \"_self\"]; sleep _lifetimeSeconds; };\n\t}],\n\t[\"#delete\", {\n\t\tdeleteVehicle (_self get \"MyVehicle\"); // delete the vehicle when we go away\n\t}],\n\t[\"MyVehicle\", objNull] // placeholder, this is not needed\n];\n\n// create a temporary RoadCone, at player position, that will delete itself after 5 seconds.\ncreateHashMapObject [_temporaryVehicle, [\"RoadCone_F\", getPos player, 5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["call","createHashMap"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"createLocation","operator":null,"title":"createLocation","type":"command","url":"https://community.bistudio.com/wiki/createLocation","revid":322768,"updated":"2022-06-23T13:56:55Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Creates a location of the specified class and dimensions at the specified position.\nClasses are defined in `CfgLocationTypes`; for possible location types see Location Types.\n\nThe alternative syntax allows to convert a non-editable (built-in) terrain location into an editable one, with the following restrictions:\n- it cannot be deleted (but can be setType to \"Invisible\" to hide it)\n- it cannot be moved","syntaxes":[{"syntax":"createLocation [className, position, sizeX, sizeY]","since":null,"effect":null,"exec":null,"params":[{"name":"className","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"className: String"},{"name":"position","type":"Position2D, Position3D or Object","optional":false,"default":null,"description":null,"types":["Position2D","Position3D","Object"],"since":null,"text":"position: Position2D, Position3D or Object"},{"name":"sizeX","type":"Number","optional":false,"default":null,"description":"in meters","types":["Number"],"since":null,"text":"sizeX: Number - in meters"},{"name":"sizeY","type":"Number","optional":false,"default":null,"description":"in meters","types":["Number"],"since":null,"text":"sizeY: Number - in meters"}],"returns":{"type":"Location","types":["Location"],"description":null,"text":"Location"},"form":"unary","operator":null,"left":null,"right":{"text":"[className, position, sizeX, sizeY]","types":["Array"]}},{"syntax":"createLocation [location]","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":"a terrain's location. If a scripted location is provided, it is simply returned","types":["Location"],"since":null,"text":"location: Location - a terrain's location. If a scripted location is provided, it is simply returned"}],"returns":{"type":"Location","types":["Location"],"description":"a script-editable location","text":"Location - a script-editable location"},"form":"unary","operator":null,"left":null,"right":{"text":"[location]","types":["Array"]}}],"examples":[{"text":"```sqf\n_location = createLocation [\"NameVillage\", [4035,2151,10], 100, 100];\n```","code":["_location = createLocation [\"NameVillage\", [4035,2151,10], 100, 100];"]},{"text":"```sqf\n_location = createLocation [\"NameVillage\", [4035,2151,10], 30, 30];\n_location setText \"Player town\";\n```","code":["_location = createLocation [\"NameVillage\", [4035,2151,10], 30, 30];\n_location setText \"Player town\";"]},{"text":"```sqf\nprivate _terrainLocation = nearestLocation [player, \"nameCity\"];    // assuming it returns a built-in location\n_terrainLocation setType \"Invisible\";                                // does not do anything\nprivate _editableLocation = createLocation [_terrainLocation];        // does the conversion\n_editableLocation setType \"Invisible\";                                // hides the location\n```","code":["private _terrainLocation = nearestLocation [player, \"nameCity\"];\t// assuming it returns a built-in location\n_terrainLocation setType \"Invisible\";\t\t\t\t\t\t\t\t// does not do anything\nprivate _editableLocation = createLocation [_terrainLocation];\t\t// does the conversion\n_editableLocation setType \"Invisible\";\t\t\t\t\t\t\t\t// hides the location"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setText","nearestLocation","nearestLocations","locationPosition","nearestLocationWithDubbing","setRectangular","rectangular","size"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createMarker","operator":null,"title":"createMarker","type":"command","url":"https://community.bistudio.com/wiki/createMarker","revid":378854,"updated":"2026-07-21T08:47:29Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Creates a new map marker at the given position. The marker will be created for every connected player as well as all JIP players. The marker name has to be unique; the command will be ignored if a marker with the given name already exists.\n\n> [!IMPORTANT]\n> The marker will be visible only once at least markerType has been defined:\n>\n> ```sqf\n> _marker = createMarker [\"markername\", player]; // Not visible yet.\n> _marker setMarkerType \"hd_dot\"; // Visible.\n> ```\n\n> [!NOTE]\n> If the marker position is given in 3D format, the `z`-coordinate is stored with the marker and will be used when the marker is passed to commands such as createVehicle, createUnit, createAgent, createMine or setVehiclePosition.\n> When a marker is manually placed in the editor, `z` is always 0, which means the marker is placed on the ground. But when the player places a marker on the map in game, it is placed at sea level, so the `z`-coordinate of that marker is `-getTerrainHeightASL markerPos \"userMarker\";`.","syntaxes":[{"syntax":"createMarker [name, position, channel, creator]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"the marker's name, used to reference the marker in scripts.","types":["String"],"since":null,"text":"name: String - the marker's name, used to reference the marker in scripts."},{"name":"position","type":"Position2D, PositionAGL or Object","optional":false,"default":null,"description":"In case of an object, the object's model [0,0,0] is used.","types":["Position2D","PositionAGL","Object"],"since":null,"text":"position: Position2D, PositionAGL or Object - In case of an object, the object's model [0,0,0] is used."},{"name":"channel","type":"Number","optional":true,"default":"-1","description":"the marker channel - see Channel IDs (for multiplayer)","types":["Number"],"since":"arma3 2.02","text":"channel: Number - (Optional, default -1) the marker channel - see Channel IDs (for multiplayer)"},{"name":"creator","type":"Object","optional":true,"default":"objNull","description":"the marker creator (for multiplayer)","types":["Object"],"since":"arma3 2.02","text":"creator: Object - (Optional, default objNull) the marker creator (for multiplayer)"}],"returns":{"type":"String","types":["String"],"description":"the marker's name or empty string if the marker name is not unique.","text":"String - the marker's name or empty string if the marker name is not unique."},"form":"unary","operator":null,"left":null,"right":{"text":"[name, position, channel, creator]","types":["Array"]}}],"examples":[{"text":"```sqf\n_marker1 = createMarker [\"Marker1\", position player];\n```","code":["_marker1 = createMarker [\"Marker1\", position player];"]},{"text":"```sqf\n_marker2 = createMarker [\"Marker2\", player]; // since Arma 3 1.50\n```","code":["_marker2 = createMarker [\"Marker2\", player]; // since Arma 3 1.50"]}],"multiplayer":"> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","problems":"setMarkerDrawPriority sorts allMapMarkers from least to most priority. Before Arma 3 v2.18 createMarker/createMarkerLocal did **not** care about drawing priority and added the created marker to the end of the array, making it top priority. Running setMarkerDrawPriority again sorted this issue.","aliases":[],"see_also":["createMarkerLocal","deleteMarker","BIS_fnc_markerToString","BIS_fnc_stringToMarker"],"notes":[{"user":"Soldia","date":"2015-09-19T21:02:00Z","text":"createMarker accepts an object as position parameter as well . You could try this with the following code (both SP/MP)\n\n```sqf\n_markerstr = createMarker [\"markername\", player];\n_markerstr setMarkerShape \"RECTANGLE\";\n_markerstr setMarkerSize [100, 100];\n```"},{"user":"X39","date":"2018-05-28T11:57:00Z","text":"In Arma 3, one can create markers which are deletable by the user by prefixing the name with `_USER_DEFINED`.\n\nExample:\n\n```sqf\ncreateMarker \"_USER_DEFINED someMarkerName\"\n```"},{"user":"7erra","date":"2019-05-03T15:53:00Z","text":"There is a new function with which you can create a marker with all settings applied in one step: BIS_fnc_stringToMarker and BIS_fnc_stringToMarkerLocal"},{"user":"Tirpitz","date":"2021-01-26T22:42:00Z","text":"When creating a marker with the name format: \"_USER_DEFINED #n1/n2/n3\".\nn1 can be used to set the owner, n2 I think is an incrementing index to ensure markers are unique, to this end also mangle some more characters onto the end of the string, and n3 is the channel ID the marker is in.\n\n```sqf\n_markerName = format [\"_USER_DEFINED #%1/%2/%3\" , clientOwner,_index, _ChannelID];\n_marker = createMarkerLocal [_markerName, _pos];\n```"},{"user":"POLPOX","date":"2023-07-08T16:03:57Z","text":"If you use the letter \"/\" in the name, it may break the channel visibilities (especially in MP).\nPossible reason is described above by Tirpitz, the engine may confuse which channel the marker belongs to after the \"/\"."},{"user":"Leopard20","date":"2026-07-21T08:47:29Z","text":"You can use a helper function if you intend to call createMarker with duplicate marker names. It doesn't necessarily guarantee that the marker has been created (e.g. it could fail not due to duplicate name, but due to maximum number of allowed markers reached)\n\n```sqf\nprivate _fnc_createMarkerSafe = { private _marker = _this#0; createMarker _this; _marker };\nprivate _marker = [\"MyMarker\", [0,0]] call _fnc_createMarkerSafe; // will return \"MyMarker\"\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createMarkerLocal","operator":null,"title":"createMarkerLocal","type":"command","url":"https://community.bistudio.com/wiki/createMarkerLocal","revid":378419,"updated":"2026-04-05T12:27:41Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Creates a local marker at the given position - the marker only exists on the machine that created it. The marker name has to be unique, if a marker with the given name exists, the command will be ignored. Use deleteMarkerLocal to delete a local marker.\n\nIf the position is given in 3D format, `z` coordinate is stored with the marker and will be used when marker is passed to commands like createVehicle, createUnit, createAgent, createMine, setVehiclePosition for example. However getMarkerPos and markerPos will always return 0 for `z`.\n\n> [!IMPORTANT]\n> Local markers have their own set of local commands \"xxMarkerxxLocal\" to work with. If you use global marker commands on a local marker, the local marker will become **global**.","syntaxes":[{"syntax":"createMarkerLocal [name, position, channel, creator]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"},{"name":"position","type":"Position2D, PositionAGL or Object","optional":false,"default":null,"description":"object's model centre is used (see getPosWorld)","types":["Position2D","PositionAGL","Object"],"since":null,"text":"position: Position2D, PositionAGL or Object - object's model centre is used (see getPosWorld)"},{"name":"channel","type":"Number","optional":true,"default":null,"description":"The marker side for multiplayer","types":["Number"],"since":"arma3 2.02","text":"channel: Number - (Optional)The marker side for multiplayer"},{"name":"creator","type":"Object","optional":true,"default":null,"description":"The marker creator for multiplayer","types":["Object"],"since":"arma3 2.02","text":"creator: Object - (Optional) The marker creator for multiplayer"}],"returns":{"type":"String","types":["String"],"description":"the marker's name, or an empty string if the marker name is not unique","text":"String - the marker's name, or an empty string if the marker name is not unique"},"form":"unary","operator":null,"left":null,"right":{"text":"[name, position, channel, creator]","types":["Array"]}}],"examples":[{"text":"```sqf\n_marker = createMarkerLocal [\"Marker1\", position player];\n```","code":["_marker = createMarkerLocal [\"Marker1\", position player];"]}],"multiplayer":"createMarkerLocal is local, so it should be used along with the other local commands. For global equivalent use createMarker.","problems":"setMarkerDrawPriority sorts allMapMarkers from least to most priority. Before Arma 3 v2.18 createMarker/createMarkerLocal did **not** care about drawing priority and added the created marker to the end of the array, making it top priority. Running setMarkerDrawPriority again sorted this issue.","aliases":[],"see_also":["allMapMarkers","deleteMarkerLocal","createMarker","setMarkerBrushLocal","setMarkerColorLocal","setMarkerDirLocal","setMarkerPosLocal","setMarkerShapeLocal","setMarkerSizeLocal","setMarkerTextLocal","setMarkerTypeLocal","setMarkerAlphaLocal","BIS_fnc_markerToString","BIS_fnc_stringToMarkerLocal"],"notes":[{"user":"Hoz","date":"2007-01-06T17:21:00Z","text":"To create a marker which is visible on the map you need to define *at least* the following three settings:\n\n```sqf\n_markerstr = createMarkerLocal [\"markername\",[_Xpos,_Ypos]];\n_markerstr setMarkerShapeLocal \"ICON\";\n_markerstr setMarkerTypeLocal \"DOT\";\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createMenu","operator":null,"title":"createMenu","type":"command","url":"https://community.bistudio.com/wiki/createMenu","revid":363232,"updated":"2024-03-26T10:51:07Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a previously added menu.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map createMenu index","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createMine","operator":null,"title":"createMine","type":"command","url":"https://community.bistudio.com/wiki/createMine","revid":377391,"updated":"2026-01-02T06:44:33Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a mine of the given type.\n\nIf the *markers* array only contains one marker name, it is ignored and the *position* parameter is used instead.\nIf *markers* contains multiple marker names, one of them is chosen randomly and used as the center of the placement area.\n\nThis command creates objects of the `CfgAmmo` class named in `configFile >> \"CfgVehicles\" >> _type >> \"ammo\"`.\n\n> [!NOTE]\n> Unit ability to detect mines depends on many factors:\n> The starting value is defined in config, for example `./CfgVehicles/B_soldier_F/detectSkill`, which in this case is 12.\n> Mine specialist value for example, defined in `./CfgVehicles/B_soldier_exp_F/detectSkill` is 38.\n> This value is then dynamically reduced depending on factors such as distance, if a unit is in a vehicle, if it is day or night time, how directly unit is looking at the mine, how fast unit is moving, how inconspicuous is the mine or even if it is visible.","syntaxes":[{"syntax":"createMine [type, position, markers, placement]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"mine class name from `CfgVehicles`","types":["String"],"since":null,"text":"type: String - mine class name from `CfgVehicles`"},{"name":"position","type":"Object or PositionAGL","optional":false,"default":null,"description":null,"types":["Object","PositionAGL"],"since":null,"text":"position: Object or PositionAGL"},{"name":"markers","type":"Array of Strings","optional":false,"default":null,"description":"marker name(s)","types":["Array","String"],"since":null,"text":"markers: Array of Strings - marker name(s)"},{"name":"placement","type":"Number","optional":false,"default":null,"description":"placement radius","types":["Number"],"since":null,"text":"placement: Number - placement radius"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, markers, placement]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mine = createMine [\"APERSMine\", ASLToAGL getPosASL player, [], 3];\n```","code":["_mine = createMine [\"APERSMine\", ASLToAGL getPosASL player, [], 3];"]},{"text":"Create a satchel charge and give the player control over it:\n\n```sqf\n_charge = createMine [\"SatchelCharge_F\", player, [], 0];\nplayer addOwnedMine _charge;\n```","code":["_charge = createMine [\"SatchelCharge_F\", player, [], 0];\nplayer addOwnedMine _charge;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","detectedMines","mineDetectedBy","mineActive","revealMine","getAllOwnedMines","addOwnedMine","removeOwnedMine","removeAllOwnedMines"],"notes":[{"user":"Tankbuster","date":"2017-06-05T22:43:00Z","text":"Note that this command uses AGL (very similar to ASL) positions, so if you want to use the moored or seabed mine, you'll have to find the appropriate negative z value that is underwater and convert that to ASL.\nAlso note that you can't adjust the positions of sea mines after they've been created. The command is either ignored or not propagated across the network to clients."},{"user":"Killzone_Kid","date":"2019-09-25T03:28:00Z","text":"The following explosives used in Arma 3 can be created with this command:\n{| class=\"wikitable\"\n! Mines\n! Remote detonation charges\n|- style=\"vertical-align: top\"\n|\n- `\"ATMine\"`\n- `\"APERSMine\"`\n- `\"APERSBoundingMine\"`\n- `\"SLAMDirectionalMine\"`\n- `\"APERSTripMine\"`\n- `\"UnderwaterMine\"`\n- `\"UnderwaterMineAB\"`\n- `\"UnderwaterMinePDM\"`\n|\n- `\"SatchelCharge_F\"`\n- `\"DemoCharge_F\"`\n- `\"Claymore_F\"`\n- `\"IEDUrbanBig_F\"`\n- `\"IEDLandBig_F\"`\n- `\"IEDUrbanSmall_F\"`\n- `\"IEDLandSmall_F\"`"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createMissionDisplay","operator":null,"title":"createMissionDisplay","type":"command","url":"https://community.bistudio.com/wiki/createMissionDisplay","revid":368962,"updated":"2024-08-21T08:48:56Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create single missions display as a child of given display. The mission dialog will be set to the directory given as an argument \"root\".","syntaxes":[{"syntax":"display createMissionDisplay missionRootDirectoryString","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"missionRootDirectoryString","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"missionRootDirectoryString: String"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"missionRootDirectoryString","types":["String"]}},{"syntax":"display createMissionDisplay [missionRootDirectoryString, cfgMissionsClass]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"missionRootDirectoryString","type":"String","optional":false,"default":null,"description":"root direction from `\\Arma 3\\Missions\\ROOT`","types":["String"],"since":null,"text":"missionRootDirectoryString: String - root direction from `\\Arma 3\\Missions\\ROOT`"},{"name":"cfgMissionsClass","type":"String","optional":false,"default":null,"description":"cfgMissions class to use","types":["String"],"since":null,"text":"cfgMissionsClass: String - cfgMissions class to use"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[missionRootDirectoryString, cfgMissionsClass]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ChildDisplay = _Rootdisplay createMissionDisplay \"Tutorial\";\n```","code":["_ChildDisplay = _Rootdisplay createMissionDisplay \"Tutorial\";"]},{"text":"In Arma 3 this creates the scenarios UI:\n\n```sqf\nfindDisplay 46 createMissionDisplay \"\";\n```","code":["findDisplay 46 createMissionDisplay \"\";"]},{"text":"Other options for Arma 3:\n\n```sqf\nprivate _missionDisplay = findDisplay 46;\n_missionDisplay createMissionDisplay [\"\", \"Cutscenes\"];\n_missionDisplay createMissionDisplay [\"\", \"Campaigns\"];\n_missionDisplay createMissionDisplay [\"\", \"MPMissions\"];\n_missionDisplay createMissionDisplay [\"\", \"Challenges\"];\n_missionDisplay createMissionDisplay [\"\", \"Showcases\"];\n```","code":["private _missionDisplay = findDisplay 46;\n_missionDisplay createMissionDisplay [\"\", \"Cutscenes\"];\n_missionDisplay createMissionDisplay [\"\", \"Campaigns\"];\n_missionDisplay createMissionDisplay [\"\", \"MPMissions\"];\n_missionDisplay createMissionDisplay [\"\", \"Challenges\"];\n_missionDisplay createMissionDisplay [\"\", \"Showcases\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMPCampaignDisplay","playMission","playScriptedMission","hostMission"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createMPCampaignDisplay","operator":null,"title":"createMPCampaignDisplay","type":"command","url":"https://community.bistudio.com/wiki/createMPCampaignDisplay","revid":368963,"updated":"2024-08-21T08:49:17Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Create a MP campaign display. The class name must be a mission collection declared in the configs; for example, `configFile >> \"CfgMissions\" >> \"MPMissions\" >> \"Apex\"`\n\nIf the class does not exist or is not a mission collection, the display will be created empty.","syntaxes":[{"syntax":"display createMPCampaignDisplay class","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"class","type":"String","optional":false,"default":null,"description":"mission collection classname","types":["String"],"since":null,"text":"class: String - mission collection classname"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"class","types":["String"]}}],"examples":[{"text":"```sqf\nfindDisplay 46 createMPCampaignDisplay \"Apex\";\n```","code":["findDisplay 46 createMPCampaignDisplay \"Apex\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMissionDisplay","playMission","playScriptedMission","hostMission"],"notes":[{"user":"R3vo","date":"2016-07-14T23:16:00Z","text":"```sqf\nfindDisplay 46 createMPCampaignDisplay \"123\";\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"createSimpleObject","operator":null,"title":"createSimpleObject","type":"command","url":"https://community.bistudio.com/wiki/createSimpleObject","revid":377446,"updated":"2026-01-02T06:47:00Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Create object with given shape defined as path to .p3d model. Supported LODs include Geometry, Fire Geometry, Roadway, View Geometry and ShadowVolume. Supported features include collision, texturing, animation, penetration, AI spotting occlusion, and surface specific sounds (like footsteps). Unsupported features include PhysX, damage, AI pathfinding (causes walking through walls), and built-in lights.\n\nGiven the simulation limitations, global decorative objects can be created with very little network traffic. Objects that could be exclusively created with this command are: trees, bushes, rocks, bridges, roads, vehicle wrecks, custom models in mission, and other objects without a class in config. The height of the placement position might need to be adjusted experimentally.\n\n> [!NOTE]\n> - See Arma 3: Simple Objects to learn more about simple objects.\n> - See Arma 3: createSimpleObject/objects for a p3d models' list.\n> - See Arma 3: Livonia Props for Livonia furniture.\n>\n> Please note that:\n> - addAction does not work with simple objects.\n> - objects created with #Syntax 1 cannot be textured. Some objects may also have inverted default direction.\n> - objects created with #Syntax 2 can be textured. The default direction should match the direction of the object if it was created with createVehicle.\n> - only as of Arma 3 v1.68 do simple objects support getVariable and setVariable.","syntaxes":[{"syntax":"createSimpleObject [shapeName, positionWorld, local]","since":null,"effect":null,"exec":null,"params":[{"name":"shapeName","type":"String","optional":false,"default":null,"description":"path to the 3d model (can be obtained with getModelInfo command)","types":["String"],"since":null,"text":"shapeName: String - path to the 3d model (can be obtained with getModelInfo command)"},{"name":"positionWorld","type":"PositionASL","optional":false,"default":null,"description":"placement position by the **model centre**'s position (see getPosWorld)","types":["PositionASL"],"since":null,"text":"positionWorld: PositionASL - placement position by the **model centre**'s position (see getPosWorld)"},{"name":"local","type":"Boolean","optional":true,"default":"false","description":"true to create a local instance only","types":["Boolean"],"since":"arma3 1.96","text":"local: Boolean - (Optional, default false) true to create a local instance only"}],"returns":{"type":"Object","types":["Object"],"description":"created simple object","text":"Object - created simple object"},"form":"unary","operator":null,"left":null,"right":{"text":"[shapeName, positionWorld, local]","types":["Array"]}},{"syntax":"createSimpleObject [className, positionASL, local]","since":null,"effect":null,"exec":null,"params":[{"name":"className","type":"String","optional":false,"default":null,"description":"CfgVehicles class name","types":["String"],"since":null,"text":"className: String - CfgVehicles class name"},{"name":"positionASL","type":"PositionASL","optional":false,"default":null,"description":"placement position","types":["PositionASL"],"since":null,"text":"positionASL: PositionASL - placement position"},{"name":"local","type":"Boolean","optional":true,"default":"false","description":"true to create a local instance only","types":["Boolean"],"since":"arma3 1.96","text":"local: Boolean - (Optional, default false) true to create a local instance only"}],"returns":{"type":"Object","types":["Object"],"description":"created simple object","text":"Object - created simple object"},"form":"unary","operator":null,"left":null,"right":{"text":"[className, positionASL, local]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _pos = player getRelPos [10, 0];\nprivate _tank = createSimpleObject [\"a3\\armor_f_beta\\apc_tracked_01\\apc_tracked_01_rcws_f.p3d\", _pos];\n_tank setPos (_pos vectorAdd (getPosWorld _tank vectorDiff (_tank modelToWorld [0,0,0])));\n\n_tank hideSelection [\"zasleh\", true];\n_tank hideSelection [\"zasleh2\", true];\n_tank hideSelection [\"clan\", true];\n \n_tank animate [\"Wheel_podkoloL3\", 0.5, true];\n_tank animate [\"Wheel_podkoloL6\", 0.5, true];\n```","code":["private _pos = player getRelPos [10, 0];\nprivate _tank = createSimpleObject [\"a3\\armor_f_beta\\apc_tracked_01\\apc_tracked_01_rcws_f.p3d\", _pos];\n_tank setPos (_pos vectorAdd (getPosWorld _tank vectorDiff (_tank modelToWorld [0,0,0])));\n\n_tank hideSelection [\"zasleh\", true];\n_tank hideSelection [\"zasleh2\", true];\n_tank hideSelection [\"clan\", true];\n \n_tank animate [\"Wheel_podkoloL3\", 0.5, true];\n_tank animate [\"Wheel_podkoloL6\", 0.5, true];"]},{"text":"```sqf\nprivate _pos = player getRelPos [10, 0];\nprivate _tank = createSimpleObject [\"B_APC_Tracked_01_CRV_F\", AGLToASL _pos];\n_tank setObjectTexture [0, \"#(rgb,8,8,3)color(0,1,0,0.01)\"];\n\n_tank hideSelection [\"zasleh\", true];\n_tank hideSelection [\"zasleh2\", true];\n_tank hideSelection [\"clan\", true];\n  \n_tank animate [\"Wheel_podkoloL3\", 0.5, true];\n_tank animate [\"Wheel_podkoloL6\", 0.5, true];\n```","code":["private _pos = player getRelPos [10, 0];\nprivate _tank = createSimpleObject [\"B_APC_Tracked_01_CRV_F\", AGLToASL _pos];\n_tank setObjectTexture [0, \"#(rgb,8,8,3)color(0,1,0,0.01)\"];\n\n_tank hideSelection [\"zasleh\", true];\n_tank hideSelection [\"zasleh2\", true];\n_tank hideSelection [\"clan\", true];\n  \n_tank animate [\"Wheel_podkoloL3\", 0.5, true];\n_tank animate [\"Wheel_podkoloL6\", 0.5, true];"]},{"text":"Create a pond:\n\n```sqf\nprivate _waterTileModel = \"a3\\structures_f_enoch\\Water\\pond_big_01.p3d\"; // visual only - this pond is a hard surface\nprivate _tileSize = 18; // width & height\nprivate _tileX = 10;\nprivate _tileY = 5;\nprivate _bottomLeftCorner = getPosWorld player;\nprivate _tilePos = -1;\nprivate _tiles = [];\nprivate _tile = objNull;\nfor \"_y\" from 0 to (_tileY - 1) do\n{\n    for \"_x\" from 0 to (_tileX - 1) do\n    {\n        _tilePos = _bottomLeftCorner vectorAdd [_x * _tileSize, _y * _tileSize, 0];\n        _tile = createSimpleObject [_waterTileModel, _tilePos];\n        _tiles pushBack _tile;\n    };\n};\nsleep 10;\n{ deleteVehicle _x } forEach _tiles;\n```","code":["private _waterTileModel = \"a3\\structures_f_enoch\\Water\\pond_big_01.p3d\"; // visual only - this pond is a hard surface\nprivate _tileSize = 18; // width & height\nprivate _tileX = 10;\nprivate _tileY = 5;\nprivate _bottomLeftCorner = getPosWorld player;\nprivate _tilePos = -1;\nprivate _tiles = [];\nprivate _tile = objNull;\nfor \"_y\" from 0 to (_tileY - 1) do\n{\n\tfor \"_x\" from 0 to (_tileX - 1) do\n\t{\n\t\t_tilePos = _bottomLeftCorner vectorAdd [_x * _tileSize, _y * _tileSize, 0];\n\t\t_tile = createSimpleObject [_waterTileModel, _tilePos];\n\t\t_tiles pushBack _tile;\n\t};\n};\nsleep 10;\n{ deleteVehicle _x } forEach _tiles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isSimpleObject","hideSelection","selectionPosition","getModelInfo","getObjectType","cursorObject","selectionNames","animationNames","createVehicle","enableSimulation","hideObject","getMissionPath","allLODs","Arma 3: Simple Objects","Arma 3: createSimpleObject/objects"],"notes":[{"user":"Killzone_Kid","date":"2016-04-18T20:03:00Z","text":"The easiest way to correctly place simple object is to create normal object of the same shape from class (if possible), then copy getPosWorld, vectorDir and vectorUp from it. Then create the simple object and apply copied values to it, this will position simple object exactly as normal object was positioned:\n\n```sqf\nprivate _heli = \"B_Heli_Light_01_F\" createVehicleLocal (player getRelPos [10, 0]);\nprivate _position = getPosWorld _heli;\nprivate _vectorDirUp = [vectorDir _heli, vectorUp _heli];\nprivate _model = getModelInfo _heli select 1;\ndeleteVehicle _heli;\nprivate _simpleHeli = createSimpleObject [_model, _position];\n_simpleHeli setVectorDirAndUp _vectorDirUp;\n```"},{"user":"Waffle SS.","date":"2016-04-28T18:10:00Z","text":"Models from within the mission file/folder can be created, but full system path is needed. See getMissionPath"},{"user":"Waffle SS.","date":"2016-05-11T01:28:00Z","text":"simulationEnabled returns false."},{"user":"Warka","date":"2016-09-05T15:10:00Z","text":"There is a section in function library dedicated to simple object creation and interaction. It's purpose is to simplify the operations:\n- BIS_fnc_createSimpleObject\n  - creates simple object according to the supplied data\n  - you can supply p3d path, class name or data you get from scanning a non-simple object\n\n- BIS_fnc_simpleObjectData\n  - gathers and returns data about the non-simple object\n  - data can be then used to create simple object\n\n- BIS_fnc_replaceWithSimpleObject\n  - replaces non-simple object with simple object on the scene\n  - do not use it in large scale in MP missions as it is not network efficient\n\n- BIS_fnc_adjustSimpleObject\n  - adjusts simple object to looks as close to the non-simple object as possible\n  - function is internally called from the 'BIS_fnc_createSimpleObject', you won't probably need to call this function directly\n\nCheck the function headers for more info about the input parameters and possibilities."},{"user":"POLPOX","date":"2024-01-27T23:23:10Z","text":"Before circa Arma 3 2.07: The path must **not** start with a backslash:\n\n|  |  |\n|---|---|\n| ✗ | `\"**\\**a3\\armor_f_beta...` |\n| ✓ | `\"a3\\armor_f_beta...` |"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"createSimpleTask","operator":null,"title":"createSimpleTask","type":"command","url":"https://community.bistudio.com/wiki/createSimpleTask","revid":353044,"updated":"2024-03-12T12:09:28Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Creates a new Task and adds it to the Diary.\n\n> [!NOTE]\n> **Arma 3:** Using the **Arma 3: Task Framework** instead is recommended\n\n> [!NOTE]\n> When task is added as a child, it appears as subcategory to the parent task in the Tasks menu and can be parent to another child task. However this is cosmetic appearance as each task has own id and can be referenced directly via diary link.","syntaxes":[{"syntax":"unit createSimpleTask [name, parentTask]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to add this new task","types":["Object"],"since":null,"text":"unit: Object - unit to add this new task"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"},{"name":"parentTask","type":"Task","optional":true,"default":null,"description":"The new task will be a sub task of the parent task","types":["Task"],"since":null,"text":"parentTask: Task - (Optional, taskNull) - The new task will be a sub task of the parent task"}],"returns":{"type":"Task","types":["Task"],"description":"the new task","text":"Task - the new task"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[name, parentTask]","types":["Array"]}}],"examples":[{"text":"```sqf\n_currentTask = player createSimpleTask [\"NewTask\"];\n```","code":["_currentTask = player createSimpleTask [\"NewTask\"];"]},{"text":"```sqf\n_childTask = player createSimpleTask [\"ChildTask\", _currentTask];\n```","code":["_childTask = player createSimpleTask [\"ChildTask\", _currentTask];"]}],"multiplayer":"The task effect is local, it will only exist on the client it was added.","problems":null,"aliases":[],"see_also":["simpleTasks","removeSimpleTask","setSimpleTaskDescription","setSimpleTaskDestination","setTaskState","setTaskResult","taskState","Tasks","Briefing"],"notes":[{"user":"Lou Montana","date":"2011-07-02T11:45:00Z","text":"- Creating child will position the new task just under the parent task.\n- Creating another \"normal\" (parent) task will create a new line **above** the others. Think of it if you want ordered objectives.\n- Succeeding parent task will automatically succeed childs, whatever their taskState was set to. (I.E. If a task is set as a child to another, it will be completed when its parent is complete.. no matter if the child task really was or not).\n- This command has to be executed again for it to be applied for JIP players - no server sync\n\nFull step by step code from beginning to end:\n\n**Step 1: create a new simpleTask**\n\n```sqf\nMySimpleTask = player createSimpleTask [(localize \"STR_aSimpleTask\")];\n```\n\nYou may create a task at any given point in time. You just need to be aware of the fact, that you've created the task for a single unit (the player). So if you make use of teamSwitch, respawn or similiar, you need to think about how to manage this, so all of these units will have up to date tasks assigned to them.\nSecond, it is a good practice to use a stringtable, even if you do not plan (yet) to offer translations.\n\n**Step 2: task destination**\n\n```sqf\nMySimpleTask setSimpleTaskDestination _destination;\n```\n\nvariable/pointer-to-your-task setSimpleTaskDestination some-position. That's it.\n\n**Step 3: task description**\n\n```sqf\nMySimpleTask setSimpleTaskDescription [\n    localize \"STR_aSimpleTaskLongText\",\n    localize \"STR_aSimpleTask\",\n    localize \"STR_aSimpleTaskWaypointLabel\"\n];\n```\n\nAgain, no magic involved here. You take your task, the command setSimpleTaskDescription an pass an array with three strings in it.\nThe first string is the long description text, the second is the name/title of the task and the last one will show up on-screen on the waypoint in cadet mode.\n\n**Step 4: set and update task states**\n\n```sqf\nMySimpleTask setTaskState \"CREATED\";\n```\n\nAnd that's it. Here a minimal working example:\n\n```sqf\nMySimpleTask = player createSimpleTask [\"simple task title\"];\nMySimpleTask setSimpleTaskDestination (position player);\nMySimpleTask setSimpleTaskDescription [\n    \"simple task long description\",\n    \"simple task title\",\n    \"simple task waypoint label\"\n];\nMySimpleTask setTaskState \"CREATED\";\n```\n\nAnd then later in the mission:\n\n```sqf\nMySimpleTask setTaskState \"SUCCEEDED\";\n```\n\nIf you want to keep the player in the loop about the status of tasks, you may always do this:\n\n```sqf\n[objNull, objNull, MySimpleTask, \"SUCCEEDED\"] execVM \"CA\\Modules\\MP\\data\\scriptCommands\\taskHint.sqf\";\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"createSite","operator":null,"title":"createSite","type":"command","url":"https://community.bistudio.com/wiki/createSite","revid":337564,"updated":"2023-02-10T01:11:02Z","groups":["Broken Commands","Sides"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a new site.\n\n> [!WARNING]\n> This command is considered deprecated and is no longer supported","syntaxes":[{"syntax":"type createSite pos","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"},{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"pos","types":["Position"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteSite","allSites"],"notes":[{"user":"Strangepete","date":"2014-02-19T02:49:00Z","text":"> CreateSite is an obsolete command from the time in development when Sites were handled separately from other modules. Now they use the modules framework. If you want a specific Site to be activated during the mission, place it in the editor and use the Condition line in its parameters (the last one)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Sides","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"createSoundSource","operator":null,"title":"createSoundSource","type":"command","url":"https://community.bistudio.com/wiki/createSoundSource","revid":377426,"updated":"2026-01-02T06:45:39Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Creates a sound source of the given type (type is the name of the subclass of CfgVehicles which is pointing to the sound defined in CfgSFX).\nThe actual sound object created is of type `\"#dynamicsound\"` and could be detected with allMissionObjects.\nIf the markers array contains several marker names, the position of a random one is used, otherwise, the given position is used.\nThe sound source is placed inside a circle with this position as its center and placement as its radius. Some of the vanilla classes pre-configured in Arma 3:\n- `\"Sound_Alarm\"`\n- `\"Sound_Alarm2\"`\n- `\"Sound_BattlefieldExplosions\"`\n- `\"Sound_BattlefieldFirefight\"`\n- `\"Sound_Fire\"`\n- `\"Sound_SmokeWreck1\"`\n- `\"Sound_SparklesWreck1\"`\n- `\"Sound_SparklesWreck2\"`\n- `\"Sound_Stream\"`\n\nSince Arma 3 v1.70 it is possible to define sounds for use with createSoundSource in Description.ext.\nAs mentioned earlier, the sounds needed for this command should be defined inside CfgVehicles class, which itself references CfgSFX class.\nIf given class searched in main config and is not found, the search will continue in description.ext - see #Example 3.\n\n> [!NOTE]\n> A sound created by createSoundSource will always be looping.\n\n> [!NOTE]\n> **Arma 3:** In earlier Arma 3 versions, the sound created was greatly attenuated if the player was in first person view inside a vehicle at the moment of execution.","syntaxes":[{"syntax":"createSoundSource [type, position, markers, placement]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"CfgVehicles class","types":["String"],"since":null,"text":"type: String - CfgVehicles class"},{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"desired placement position","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D - desired placement position"},{"name":"markers","type":"Array","optional":false,"default":null,"description":"if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given a Z coordinate with setMarkerPos, the sound will also be created at the given Z coordinate","types":["Array"],"since":null,"text":"markers: Array - if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given a Z coordinate with setMarkerPos, the sound will also be created at the given Z coordinate"},{"name":"placement","type":"Number","optional":false,"default":null,"description":"the sound is placed inside a circle with given position as center and placement as its radius","types":["Number"],"since":null,"text":"placement: Number - the sound is placed inside a circle with given position as center and placement as its radius"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, markers, placement]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soundSource = createSoundSource [\"LittleDog\", position player, [], 0];\n```","code":["_soundSource = createSoundSource [\"LittleDog\", position player, [], 0];"]},{"text":"```sqf\n0 spawn \n{\n    _alarm = createSoundSource [\"Sound_Alarm\", position player, [], 0]; // starts alarm\n    sleep 10;\n    deleteVehicle _alarm; // stops alarm\n};\n```","code":["0 spawn \n{\n\t_alarm = createSoundSource [\"Sound_Alarm\", position player, [], 0]; // starts alarm\n\tsleep 10;\n\tdeleteVehicle _alarm; // stops alarm\n};"]},{"text":"Arma 3 v1.70 Here is an example of suitable mission config definition:\n\n```cpp\n// description.ext\nclass CfgSFX\n{\n    class MyOwl\n    {\n        sound0[] = { \"@A3\\Sounds_F\\environment\\animals\\birds\\owl1\", db-10, 1.0, 1000, 0.2, 0, 15, 30 };    // path to addon sound\n        sound1[] = { \"@A3\\Sounds_F\\environment\\animals\\birds\\owl2\", db-10, 1.0, 1000, 0.2, 0, 15, 30 };    // path to addon sound\n        sound2[] = { \"@A3\\Sounds_F\\environment\\animals\\birds\\owl3\", db-10, 1.0, 1000, 0.2, 0, 15, 30 };    // path to addon sound\n        sounds[] = { \"sound0\", \"sound1\", \"sound2\" };\n        empty[] = { \"\", 0, 0, 0, 0, 0, 0, 0 };\n    };\n};\n\nclass CfgVehicles\n{\n    class MyOwlSound // class name to be used with createSoundSource\n    {\n        sound = \"MyOwl\"; // reference to CfgSFX class\n    };\n};\n```\n\n```sqf\nprivate _owl = createSoundSource [\"MyOwlSound\", position player, [], 0];\n```","code":["private _owl = createSoundSource [\"MyOwlSound\", position player, [], 0];"]}],"multiplayer":"When a CfgSFX sound definition contains more than 1 sound, there is no guarantee that the sound played will be the same on every PC in Multiplayer.","problems":null,"aliases":[],"see_also":["createSoundSourceLocal","playSound","playSound3D","sideRadio","say","say2D","say3D","playMusic","playSoundUI"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createSoundSourceLocal","operator":null,"title":"createSoundSourceLocal","type":"command","url":"https://community.bistudio.com/wiki/createSoundSourceLocal","revid":369781,"updated":"2024-10-08T15:09:02Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Same as createSoundSource but with local effect - the created sound is not transferred to other clients.","syntaxes":[{"syntax":"see createSoundSource","since":null,"effect":null,"exec":null,"params":[{"name":"see createSoundSource","type":null,"optional":false,"default":null,"description":null,"types":["createSoundSource"],"since":null,"text":"see createSoundSource"}],"returns":{"type":"see createSoundSource","types":["createSoundSource"],"description":null,"text":"see createSoundSource"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ncreateSoundSource        [\"LittleDog\", position player, [], 0]; // global\ncreateSoundSourceLocal    [\"LittleDog\", position player, [], 0]; // local\n```","code":["createSoundSource\t\t[\"LittleDog\", position player, [], 0]; // global\ncreateSoundSourceLocal\t[\"LittleDog\", position player, [], 0]; // local"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSoundSource","Description.ext","CfgSFX"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"createTarget","operator":null,"title":"createTarget","type":"command","url":"https://community.bistudio.com/wiki/createTarget","revid":352192,"updated":"2024-02-01T23:25:58Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a target.","syntaxes":[{"syntax":"obj createTarget [type, position, typeAccuracy, posAccuracy]","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"},{"name":"position","type":"Position Placement","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position Placement"},{"name":"typeAccuracy","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"typeAccuracy: Number"},{"name":"posAccuracy","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"posAccuracy: Number"}],"returns":{"type":"Target","types":["Target"],"description":null,"text":"Target"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"[type, position, typeAccuracy, posAccuracy]","types":["Array"]}}],"examples":[{"text":"```sqf\n_target = createTarget [\"targetType\", [0,0,0], 1, 1];\n```","code":["_target = createTarget [\"targetType\", [0,0,0], 1, 1];"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command is not implemented.","aliases":[],"see_also":["moveTarget","deleteTarget"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createTask","operator":null,"title":"createTask","type":"command","url":"https://community.bistudio.com/wiki/createTask","revid":351331,"updated":"2023-11-27T05:30:49Z","groups":["Briefing","Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a new AI task (subtask of parentTask). Type is name of registered task type.","syntaxes":[{"syntax":"teamMember createTask [[type, parentTask], priority, name1, value1, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"},{"name":"type","type":"String","optional":false,"default":null,"description":"`name` defined in `CfgTasks`","types":["String"],"since":null,"text":"type: String - `name` defined in `CfgTasks`"},{"name":"parentTask","type":"Task","optional":true,"default":null,"description":null,"types":["Task"],"since":null,"text":"parentTask: Task - (Optional)"},{"name":"priority","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"priority: Number"},{"name":"nameN","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"nameN: String"},{"name":"valueN","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"valueN: String"}],"returns":{"type":"Task","types":["Task"],"description":null,"text":"Task"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"[[type, parentTask], priority, name1, value1, ...]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","type","briefing","createSimpleTask","simpleTasks","currentTask","currentTasks","setCurrentTask","taskState","setTaskState","taskResult","setTaskResult","taskCompleted","removeSimpleTask"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createTeam","operator":null,"title":"createTeam","type":"command","url":"https://community.bistudio.com/wiki/createTeam","revid":364171,"updated":"2024-05-05T10:46:44Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a Team and names it.","syntaxes":[{"syntax":"createTeam [type, name]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Team Member","types":["Team Member"],"description":null,"text":"Team Member"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, name]","types":["Array"]}}],"examples":[{"text":"```sqf\n_team = createTeam [\"USMC_Team\", \"Fire Team Red\"];\n```","code":["_team = createTeam [\"USMC_Team\", \"Fire Team Red\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","removeTeamMember"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createTrigger","operator":null,"title":"createTrigger","type":"command","url":"https://community.bistudio.com/wiki/createTrigger","revid":370090,"updated":"2024-10-31T19:20:48Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a trigger of the given type and at the given position. The type must be a class name in *CfgNonAIVehicles* or *CfgVehicles* with `simulation = detector`. An array containing all units that have activated the trigger is available via `list triggerobj`. Since triggers are **Objects**, commands such as getPosASL, setPosASL, deleteVehicle etc. work on them.\n\n> [!IMPORTANT]\n> Triggers are always created on the road surface (AGL) at provided x, y coordinates. The z param is ignored. In order to place the trigger with a custom z, use a 'setPosXXX' command after trigger creation.\n\n> [!NOTE]\n> Since Arma 3 v1.54 triggers can be disabled/enabled using enableSimulation command.\n\nTriggers are created with default parameters:\n- `a`: 50\n- `b`: 50\n- `c`: -1\n- `angle`: 0\n- `rectangular`: false\n- `activationBy`: None\n- `activationType`: Present\n- `repeating`: false\n- `timeoutMin`: 0\n- `timeoutMid`: 0\n- `timeoutMax`: 0\n- `interruptable`: true\n- `type`: None\n- `text`: \"\"\n- `name`: \"\"\n- `expCond`: \"this\"\n- `expActiv`: \"\"\n- `expDesactiv`: \"\"\n- Arma 3 v1.98 `interval`: 0.5","syntaxes":[{"syntax":"createTrigger [type, position, makeGlobal]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"usually \"EmptyDetector\"","types":["String"],"since":null,"text":"type: String - usually \"EmptyDetector\""},{"name":"position","type":null,"optional":false,"default":null,"description":"Position2D, Position3D or Object (see the note in description)","types":["Position2D","Position3D","Object"],"since":null,"text":"position: Position2D, Position3D or Object (see the note in description)"},{"name":"makeGlobal","type":"Boolean","optional":true,"default":"true","description":"locality flag\n- true - trigger is global Global Effect\n- false - trigger is local Local Effect","types":["Boolean"],"since":"arma3 1.44","text":"makeGlobal: Boolean - (Optional - default true) locality flag\n- true - trigger is global Global Effect\n- false - trigger is local Local Effect"}],"returns":{"type":"Object","types":["Object"],"description":"created trigger","text":"Object - created trigger"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, makeGlobal]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trg = createTrigger [\"EmptyDetector\", getPos player];\n_trg setTriggerArea [5, 5, 0, false];\n_trg setTriggerActivation [\"CIV\", \"PRESENT\", true];\n_trg setTriggerStatements [\"this\", \"hint 'Civilian near player'\", \"hint 'no civilian near'\"];\n```","code":["_trg = createTrigger [\"EmptyDetector\", getPos player];\n_trg setTriggerArea [5, 5, 0, false];\n_trg setTriggerActivation [\"CIV\", \"PRESENT\", true];\n_trg setTriggerStatements [\"this\", \"hint 'Civilian near player'\", \"hint 'no civilian near'\"];"]},{"text":"Open/close Bar Gate automatically:\n\n```sqf\n//--- init of the Bar Gate\nif (isServer) then\n{    \n    _gateTrigger = createTrigger [\"EmptyDetector\", getPosWorld this, false];\n    _gateTrigger setVariable [\"BarGateObj\", this];\n    _gateTrigger setTriggerActivation [\"ANYPLAYER\", \"PRESENT\", true];\n    _gateTrigger setTriggerArea [5, 25, getDir this, true];\n    _gateTrigger setTriggerStatements \n    [\n        \"this\", \n        \"thisTrigger getVariable \"\"BarGateObj\"\" animateSource [\"\"Door_1_sound_source\"\", 1]\", \n        \"thisTrigger getVariable \"\"BarGateObj\"\" animateSource [\"\"Door_1_sound_source\"\", 0]\"\n    ];\n};\n```","code":["//--- init of the Bar Gate\nif (isServer) then\n{\t\n\t_gateTrigger = createTrigger [\"EmptyDetector\", getPosWorld this, false];\n\t_gateTrigger setVariable [\"BarGateObj\", this];\n\t_gateTrigger setTriggerActivation [\"ANYPLAYER\", \"PRESENT\", true];\n\t_gateTrigger setTriggerArea [5, 25, getDir this, true];\n\t_gateTrigger setTriggerStatements \n\t[\n\t\t\"this\", \n\t\t\"thisTrigger getVariable \"\"BarGateObj\"\" animateSource [\"\"Door_1_sound_source\"\", 1]\", \n\t\t\"thisTrigger getVariable \"\"BarGateObj\"\" animateSource [\"\"Door_1_sound_source\"\", 0]\"\n\t];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerActivation","setTriggerArea","setTriggerStatements","setTriggerText","setTriggerTimeout","setTriggerType","setEffectCondition","setSoundEffect","setMusicEffect","setTitleEffect","deleteVehicle","synchronizeWaypoint","synchronizeTrigger","createGuardedPoint","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[{"user":"TeaCup","date":"2013-03-06T14:15:00Z","text":"Calling list immediately after creating a trigger this way (and setting up activation, area, statements, timeout, etc..), will return <null> instead of an array. It seems the trigger needs about 1 second to initialise, after which it will behave as expected: returning an array of all the objects inside the trigger (the ones matching the criteria), or an empty array."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"createUnit","operator":null,"title":"createUnit","type":"command","url":"https://community.bistudio.com/wiki/createUnit","revid":377516,"updated":"2026-01-02T06:50:26Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Create a unit of the provided CfgVehicles class.\n\n> [!WARNING]\n> The unit will not be created if the passed group does not exist (a.k.a grpNull);\n> this can happen if createGroup fails because the **group limit has been reached** (see createGroup for respective game limits).\n\n|  | #Syntax 1 | #Syntax 2 |\n|---|---|---|\n| Group's locality | the provided group *can* be non-local, but a warning will be logged | the provided group **must** be local |\n| Unit's side | using a classname from a different side than the provided group will result in the unit itself being of a (config-defined) side inside a group of another side - see #Example 6 for more information | using a classname from a different side than the provided group will result in the unit being of the same side as the provided group |\n| Other | the unit's init code will execute after a slight delay if the provided group is not local | this syntax does **not** return a reference to the created unit (see #Example 7) |\n\n> [!NOTE]\n> **Armed Assault:** Operation Flashpoint v1.34 Armed Assault v1.00 This command was sometimes bugged in Operation Flashpoint or Armed Assault; an additional join may solve the problem.\n>\n> However, some commands such as setUnitPos only work if run before the join.","syntaxes":[{"syntax":"group createUnit [type, position, markers, placement, special]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"existing group new unit will join; if the group is not local, a warning will be logged","types":["Group"],"since":null,"text":"group: Group - existing group new unit will join; if the group is not local, a warning will be logged"},{"name":"type","type":"String","optional":false,"default":null,"description":"classname of unit to be created as per CfgVehicles","types":["String"],"since":null,"text":"type: String - classname of unit to be created as per CfgVehicles"},{"name":"position","type":"Object, Group or Position or Position2D","optional":false,"default":null,"description":"location where to create the unit. In case of Group, the group leader's position is used. The Z component of the position is ignored and the unit is always placed on the surface.","types":["Object","Group","Position","Position2D"],"since":null,"text":"position: Object, Group or Position or Position2D - location where to create the unit. In case of Group, the group leader's position is used. The Z component of the position is ignored and the unit is always placed on the surface."},{"name":"markers","type":"Array","optional":false,"default":null,"description":"placement markers","types":["Array"],"since":null,"text":"markers: Array - placement markers"},{"name":"placement","type":"Number","optional":false,"default":null,"description":"placement radius","types":["Number"],"since":null,"text":"placement: Number - placement radius"},{"name":"special","type":"String","optional":false,"default":null,"description":"unit placement special, one of:\n- `\"NONE\"` - The unit will be created at the first available free position nearest to given position\n- `\"FORM\"` - Not implemented, currently functions the same as \"NONE\"\n- `\"CAN_COLLIDE\"` - The unit will be created exactly at the provided position\n- `\"CARGO\"` - The unit will be created in cargo of the group's vehicle, regardless of the passed position (see #Example 5). If group has no vehicle or there is no cargo space available, the unit will be placed according to `\"NONE\"`. `\"CARGO\"` placement excludes cargo positions with personal FFV turrets. To check available cargo space use:\n\n|  |  |\n|---|---|\n| Arma 3 v1.34 FFV | ```sqf<br>private _hasCargo = { isNull (_x select 0) } count (fullCrew [_veh, \"cargo\", true]) > 0;<br>``` |\n| before | ```sqf<br>_hasCargo = _veh emptyPositions \"CARGO\" > 0;<br>``` |","types":["String"],"since":null,"text":"special: String - unit placement special, one of:\n- `\"NONE\"` - The unit will be created at the first available free position nearest to given position\n- `\"FORM\"` - Not implemented, currently functions the same as \"NONE\"\n- `\"CAN_COLLIDE\"` - The unit will be created exactly at the provided position\n- `\"CARGO\"` - The unit will be created in cargo of the group's vehicle, regardless of the passed position (see #Example 5). If group has no vehicle or there is no cargo space available, the unit will be placed according to `\"NONE\"`. `\"CARGO\"` placement excludes cargo positions with personal FFV turrets. To check available cargo space use:\n\n|  |  |\n|---|---|\n| Arma 3 v1.34 FFV | ```sqf<br>private _hasCargo = { isNull (_x select 0) } count (fullCrew [_veh, \"cargo\", true]) > 0;<br>``` |\n| before | ```sqf<br>_hasCargo = _veh emptyPositions \"CARGO\" > 0;<br>``` |"}],"returns":{"type":"Object","types":["Object"],"description":"the created unit","text":"Object - the created unit"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"[type, position, markers, placement, special]","types":["Array"]}},{"syntax":"type createUnit [position, group, init, skill, rank]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"classname of unit to be created as per CfgVehicles","types":["String"],"since":null,"text":"type: String - classname of unit to be created as per CfgVehicles"},{"name":"position","type":"Object, Group or Position or Position2D","optional":false,"default":null,"description":"location at which the unit is created. In case of Group position of the group leader is used","types":["Object","Group","Position","Position2D"],"since":null,"text":"position: Object, Group or Position or Position2D - location at which the unit is created. In case of Group position of the group leader is used"},{"name":"group","type":"Group","optional":false,"default":null,"description":"existing group the new unit will join","types":["Group"],"since":null,"text":"group: Group - existing group the new unit will join"},{"name":"init","type":"String","optional":true,"default":"\"\"","description":"unit init statement, similar to unit init field in the editor. The code placed in unit init will run upon unit creation for every client on network, present and future.\nThe code itself receives the reference to the created unit via local variable this.\n\n> [!WARNING]\n> - Do not use global effect commands in a unit's *init* as it runs on every client (local effect ones are OK, e.g setIdentity).\n> - Do not use local variables inside the init code as they are not available in multiplayer.","types":["String"],"since":null,"text":"init: String - (Optional, default \"\") unit init statement, similar to unit init field in the editor. The code placed in unit init will run upon unit creation for every client on network, present and future.\nThe code itself receives the reference to the created unit via local variable this.\n\n> [!WARNING]\n> - Do not use global effect commands in a unit's *init* as it runs on every client (local effect ones are OK, e.g setIdentity).\n> - Do not use local variables inside the init code as they are not available in multiplayer."},{"name":"skill","type":"Number","optional":true,"default":"0.5","description":"unit skill","types":["Number"],"since":null,"text":"skill: Number - (Optional, default 0.5) unit skill"},{"name":"rank","type":"String","optional":true,"default":"\"PRIVATE\"","description":"unit rank","types":["String"],"since":null,"text":"rank: String - (Optional, default \"PRIVATE\") unit rank"}],"returns":{"type":"> [!WARNING] > Nothing","types":["Nothing"],"description":"this syntax does not return a unit reference! See #Example 7 for a workaround.","text":"> [!WARNING]\n> **Nothing** - this syntax does **not** return a unit reference! See #Example 7 for a workaround."},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"[position, group, init, skill, rank]","types":["Array"]}}],"examples":[{"text":"```sqf\n_unit = group player createUnit [\"B_RangeMaster_F\", position player, [], 0, \"NONE\"];\n```","code":["_unit = group player createUnit [\"B_RangeMaster_F\", position player, [], 0, \"NONE\"];"]},{"text":"```sqf\n\"B_RangeMaster_F\" createUnit [position player, group player];\n```","code":["\"B_RangeMaster_F\" createUnit [position player, group player];"]},{"text":"```sqf\n\"B_RangeMaster_F\" createUnit [getMarkerPos \"barracks\", _groupAlpha];\n```","code":["\"B_RangeMaster_F\" createUnit [getMarkerPos \"barracks\", _groupAlpha];"]},{"text":"```sqf\n\"B_RangeMaster_F\" createUnit [\n    getMarkerPos \"marker_1\",\n    _groupAlpha,\n    \"loon1 = this; this addWeapon 'BAF_L85A2_RIS_SUSAT'\",\n    0.6,\n    \"corporal\"\n];\n```","code":["\"B_RangeMaster_F\" createUnit [\n\tgetMarkerPos \"marker_1\",\n\t_groupAlpha,\n\t\"loon1 = this; this addWeapon 'BAF_L85A2_RIS_SUSAT'\",\n\t0.6,\n\t\"corporal\"\n];"]},{"text":"```sqf\n_veh = \"O_Quadbike_01_F\" createVehicle (player getRelPos [10, 0]);\n_grp = createVehicleCrew _veh;\n_unit = _grp createUnit [typeOf driver _veh, _grp, [], 0, \"CARGO\"];\n```","code":["_veh = \"O_Quadbike_01_F\" createVehicle (player getRelPos [10, 0]);\n_grp = createVehicleCrew _veh;\n_unit = _grp createUnit [typeOf driver _veh, _grp, [], 0, \"CARGO\"];"]},{"text":"Creating a unit from a different side may lead to issues:\n\n```sqf\n_grp = createGroup east;\nhint str side _grp; // EAST\n_ap = _grp createUnit [\"C_man_p_beggar_F\", position player, [], 0, \"NONE\"];\nhint str side _ap; // CIV, not EAST\n\n// workaround\n[_ap] joinSilent _grp;\nhint str side _ap; // EAST\n```","code":["_grp = createGroup east;\nhint str side _grp; // EAST\n_ap = _grp createUnit [\"C_man_p_beggar_F\", position player, [], 0, \"NONE\"];\nhint str side _ap; // CIV, not EAST\n\n// workaround\n[_ap] joinSilent _grp;\nhint str side _ap; // EAST"]},{"text":"Reference the created unit through a global variable:\n\n```sqf\n_myUnit = \"B_RangeMaster_F\" createUnit [position player, group player];            // wrong - this syntax does not return a reference\n\n\"B_RangeMaster_F\" createUnit [position player, group player, \"myUnit = this\"];    // correct - the unit is myUnit (NOT _myUnit!)\n```","code":["_myUnit = \"B_RangeMaster_F\" createUnit [position player, group player];\t\t\t// wrong - this syntax does not return a reference\n\n\"B_RangeMaster_F\" createUnit [position player, group player, \"myUnit = this\"];\t// correct - the unit is myUnit (NOT _myUnit!)"]}],"multiplayer":"It is recommended to create the unit where the group is **local** - use remoteExec if needed.","problems":null,"aliases":[],"see_also":["createCenter","createGroup","createVehicle","setVehiclePosition","create3DENEntity"],"notes":[{"user":"oOKexOo","date":"2018-12-08T21:57:00Z","text":"Since Arma 3 v1.86: If you want to place a module with createUnit, you have to ensure that the module gets activated automatically by setting **BIS_fnc_initModules_disableAutoActivation** to false, *e.g*:\n\n```sqf\nprivate _grp = createGroup sideLogic;\n\"ModuleSmokeWhite_F\" createUnit [\n    getPos player,\n    _grp,\n    \"this setVariable ['BIS_fnc_initModules_disableAutoActivation', false, true];\"\n];\n```"},{"user":"Killzone_Kid","date":"2019-03-18T19:31:00Z","text":"Alt Syntax is the older syntax and differs in functionality from the main, newer syntax. The main difference is that the older syntax **does not** return unit reference.\nThis is because the unit created with Alt Syntax is created strictly where passed group is local.\nThis means that if the group is remote the unit will be created on the different client than the one the command was executed on and therefore it is not possible to return created unit reference immediately.\nIn contrast, the newer syntax allows creating units in remote groups while returning unit reference immediately, which could be unsafe and the appropriate warning is logged into *.rpt* file: `Warning: Adding units to a remote group is not safe. Please use setGroupOwner to change the group owner first.`\n\nAnother very important difference is that the older syntax (Alt Syntax) will create unit of the same side as the side of the group passed as argument.\nFor example, if the group is WEST and the unit faction is OPFOR of type, say `\"O_Soldier_GL_F\"`, the unit created will be on the WEST side as well.\nIn contrast, newer syntax will create the same unit on the EAST side in the WEST group, which will be treated as hostile by other group members and eliminated.\n\n> [!WARNING]\n> Beware that in MP if unit is created in remote group with older syntax, the unit init will execute on calling client sometime in the future, after the unit is created on remote client, therefore the following code will fail:\n>\n> ```sqf\n> // real example of the bad code\n> \"O_Soldier_AR_F\" createUnit [position player, someRemoteGroup, \"thisUnit = this\"];\n> publicVariable \"thisUnit\";\n> hint str isNil \"thisUnit\"; // true!\n> // the unit reference is nil because init statement has not been executed on this client yet\n> ```"},{"user":"fusselwurm","date":"2020-06-19T10:13:00Z","text":"Arma 3 v1.98 note that even when setting the *placement special* parameter to \"NONE\", 3DEN-placed objects are being ignored when looking for a free position.\nIn other words: units will spawn within editor-placed rocks or under houses."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createVehicle","operator":null,"title":"createVehicle","type":"command","url":"https://community.bistudio.com/wiki/createVehicle","revid":377509,"updated":"2026-01-02T06:50:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Creates an empty object of given classname type.\nSee Arma 3: Assets / Arma 3: createVehicle/vehicles, or Category:CfgVehicles for earlier games.\n\n> [!NOTE]\n> - To create objects of type `\"Logic\"`, use createUnit.\n> - To create an editable Eden Editor entity, see create3DENEntity.\n\n> [!NOTE]\n> **Arma 3:** To avoid vehicle randomisation in Arma 3, set the `BIS_enableRandomization` variable immediately after creating the vehicle:\n>\n> ```sqf\n> private \"_vehicle\";\n> isNil { // run unscheduled\n>     _vehicle = \"C_Offroad_01_F\" createVehicle getPosATL player;\n>     _vehicle setVariable [\"BIS_enableRandomization\", false];\n> };\n> // the _vehicle variable is available after that\n> ```\n>\n> See the Arma 3: Vehicle Customisation page for more information and settings.","syntaxes":[{"syntax":"type createVehicle position","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"vehicle/object className","types":["String"],"since":null,"text":"type: String - vehicle/object className"},{"name":"position","type":"Position","optional":false,"default":null,"description":"desired placement position. If the exact position is occupied, nearest empty position is used.","types":["Position"],"since":null,"text":"position: Position - desired placement position. If the exact position is occupied, nearest empty position is used."}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"position","types":["Position"]}},{"syntax":"createVehicle [type, position, markers, placement, special]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"vehicle/object className","types":["String"],"since":null,"text":"type: String - vehicle/object className"},{"name":"position","type":"Object, Position2D, PositionATL or PositionAGL","optional":false,"default":null,"description":"desired placement position, (PositionAGL if watercraft or amphibious)","types":["Object","Position2D","PositionATL","PositionAGL"],"since":null,"text":"position: Object, Position2D, PositionATL or PositionAGL - desired placement position, (PositionAGL if watercraft or amphibious)"},{"name":"markers","type":"Array of Strings","optional":true,"default":"`[]`","description":"if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate.","types":["Array","String"],"since":null,"text":"markers: Array of Strings - (Optional, default `[]`) if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate."},{"name":"placement","type":"Number","optional":true,"default":"0","description":"the vehicle is placed inside a circle with given position as center and placement as its radius.","types":["Number"],"since":null,"text":"placement: Number - (Optional, default 0) the vehicle is placed inside a circle with given position as center and placement as its radius."},{"name":"special","type":"String","optional":true,"default":"\"NONE\"","description":"can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used.","types":["String"],"since":null,"text":"special: String - (Optional, default \"NONE\") can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used."}],"returns":{"type":"Object","types":["Object"],"description":"created vehicle or objNull if failed","text":"Object - created vehicle or objNull if failed"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, markers, placement, special]","types":["Array"]}}],"examples":[{"text":"```sqf\n_jeep = \"Jeep\" createVehicle position player;\n```","code":["_jeep = \"Jeep\" createVehicle position player;"]},{"text":"```sqf\n_heli = \"AH1Z\" createVehicle getMarkerPos \"hspawn\";\n```","code":["_heli = \"AH1Z\" createVehicle getMarkerPos \"hspawn\";"]},{"text":"```sqf\n_veh = createVehicle [\"ah1w\", position player, [], 0, \"FLY\"];\n```","code":["_veh = createVehicle [\"ah1w\", position player, [], 0, \"FLY\"];"]},{"text":"```sqf\n_veh = createVehicle [\"2S6M_Tunguska\", getMarkerPos \"marker1\", [\"marker2\", \"marker3\"], 0, \"NONE\"];\n```","code":["_veh = createVehicle [\"2S6M_Tunguska\", getMarkerPos \"marker1\", [\"marker2\", \"marker3\"], 0, \"NONE\"];"]},{"text":"Objects such as\n- \"test_EmptyObjectForBubbles\"\n- \"test_EmptyObjectForFireBig\"\n- \"test_EmptyObjectForSmoke\"\ncreate additional emitters, which are stored in \"effects\" variable on the object. Since Arma 3 v1.72 these emitters are automatically deleted when object is deleted\n\n```sqf\n0 spawn\n{\n    private _fire = \"test_EmptyObjectForFireBig\" createVehicle position player;\n    sleep 5;\n    deleteVehicle _fire;\n};\n```","code":["0 spawn\n{\n\tprivate _fire = \"test_EmptyObjectForFireBig\" createVehicle position player;\n\tsleep 5;\n\tdeleteVehicle _fire;\n};"]},{"text":"The following explosives (ending with `_Scripted`) can be set off by applying setDamage 1 to them for ease of scripting:\n- \"DemoCharge_Remote_Ammo_Scripted\"\n- \"SatchelCharge_Remote_Ammo_Scripted\"\n- \"ClaymoreDirectionalMine_Remote_Ammo_Scripted\"\n\n```sqf\n_claymore = \"ClaymoreDirectionalMine_Remote_Ammo_Scripted\" createVehicle position player;\n_claymore spawn\n{\n    sleep 5;\n    _this setDamage 1;\n};\n```","code":["_claymore = \"ClaymoreDirectionalMine_Remote_Ammo_Scripted\" createVehicle position player;\n_claymore spawn\n{\n\tsleep 5;\n\t_this setDamage 1;\n};"]},{"text":"Add inventory to objects without inventory:\n\n```sqf\n_boxes = \"Land_Pallet_MilBoxes_F\" createVehicle position player;\n_cargo = \"Supply500\" createVehicle [0,0,0];\n_cargo attachTo [_boxes, [0,0,0.85]];\n\n// optional for objects that can take damage\n_boxes addEventHandler [\"Killed\",\n{\n    {\n        detach _x;\n        deleteVehicle _x;\n    }\n    forEach attachedObjects (_this select 0);\n}];\n```","code":["_boxes = \"Land_Pallet_MilBoxes_F\" createVehicle position player;\n_cargo = \"Supply500\" createVehicle [0,0,0];\n_cargo attachTo [_boxes, [0,0,0.85]];\n\n// optional for objects that can take damage\n_boxes addEventHandler [\"Killed\",\n{\n\t{\n\t\tdetach _x;\n\t\tdeleteVehicle _x;\n\t}\n\tforEach attachedObjects (_this select 0);\n}];"]},{"text":"Drop player's weapon:\n\n```sqf\n_weaponHolder = \"GroundWeaponHolder_Scripted\" createVehicle position player;\nplayer action [\"DropWeapon\", _weaponHolder, currentWeapon player];\n```","code":["_weaponHolder = \"GroundWeaponHolder_Scripted\" createVehicle position player;\nplayer action [\"DropWeapon\", _weaponHolder, currentWeapon player];"]},{"text":"The following weapon holders (ending with *_Scripted*) do **not** auto-delete when empty. It is up to the mission maker to take care of these:\n- \"GroundWeaponHolder_Scripted\"\n- \"WeaponHolderSimulated_Scripted\"\n- \"Weapon_Empty\" (a special weaponholder that displays only a single weapon, even if it contains magazines for this weapon)\n\n```sqf\n0 spawn \n{\n    private _weaponHolder = createVehicle [\"Weapon_Empty\", getPosATL player, [], 0, \"CAN_COLLIDE\"];\n    _weaponHolder addWeaponCargo [\"arifle_Katiba_F\", 1];\n    hint \"You have 5 seconds to grab this weapon\";\n    sleep 5;\n    deleteVehicle _weaponHolder;\n};\n```","code":["0 spawn \n{\n\tprivate _weaponHolder = createVehicle [\"Weapon_Empty\", getPosATL player, [], 0, \"CAN_COLLIDE\"];\n\t_weaponHolder addWeaponCargo [\"arifle_Katiba_F\", 1];\n\thint \"You have 5 seconds to grab this weapon\";\n\tsleep 5;\n\tdeleteVehicle _weaponHolder;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createVehicleLocal","create3DENEntity","createVehicleCrew","createAgent","createTrigger","createUnit","createMine","deleteVehicle","createGroup","createCenter","setVehiclePosition"],"notes":[{"user":"MrSanchez","date":"2015-08-22T13:04:00Z","text":"GroundWeaponHolder class is automatically deleted when empty after 0.5 to 1 seconds in A3 1.48. The exact delay is random but never lower than 0.50 secs after creation.\nYou can stop deletion by adding something (cargo) to it within 0.5 seconds."},{"user":"AgentRev","date":"2017-05-16T09:05:00Z","text":"For the alternative syntax, if the vehicle has `canFloat = 1;` in its config class (e.g. boats and wheeled APCs) the command expects PositionAGL,\notherwise always PositionATL."},{"user":"demellion","date":"2018-11-02T12:16:00Z","text":"**WARNING:** Do not instigate createVehicle or createVehicleLocal within a server function executed with preInit flag.\n\nThis will cause *\"You cannot play/edit this mission\"* for a vehicles compiled from a -mod and make server skip/loop that mission init."},{"user":"R3vo","date":"2019-08-10T09:10:00Z","text":"The main syntax creates vehicles at ground level ignoring the Z in *pos* and is also faster than the alternative syntax.\n\n```sqf\n\"vehclass\" createVehicle pos;\n```\n\nThis is equivalent to \n\n```sqf\ncreateVehicle [\"vehclass\", [pos select 0, pos select 1, 0], [], 0, \"NONE\"];\n```"},{"user":"DreadedEntity","date":"2022-03-13T17:22:36Z","text":"Objects are created with a vectorUp of terrain surface normal. If you are creating new buildings to add to the map, you will probably want to call setVectorUp on the newly-spawned object.\n\n```sqf\n_veh = createVehicle [/*etc...*/];\n_veh setVectorUp [0,0,1];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"createVehicleCrew","operator":null,"title":"createVehicleCrew","type":"command","url":"https://community.bistudio.com/wiki/createVehicleCrew","revid":369241,"updated":"2024-09-03T10:35:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Creates vehicle crew corresponding to the provided vehicle's faction. If the vehicle is already occupied, the command will only create missing crew in the existing vehicle's group.\n\nTo find out which crew will be created, use BIS_fnc_vehicleCrewTurrets.\n\n|  |  |  |\n|---|---|---|\n| + This command: | Does | Does not |\n| - Arma 3 v1.26 create a group if one is needed (otherwise uses `group _vehicle`)<br>- create a driver if the vehicle needs one (`hasDriver = 1;` in config)<br>- create all non-FFV turrets gunners (if the turret needs one - config {`hasGunner` without `dontCreateAI`)<br>- create crew with **ranks** - with the driver as `\"LIEUTENANT\"` and all turret units as `\"SERGEANT\"`, unlike a crewed vehicle placed in Eden Editor where all units are `\"PRIVATE\"`. | - add vehicle to the group, unlike a crewed vehicle placed in Eden Editor. See BIS_fnc_spawnVehicle to spawn a crew-full vehicle with group addition<br>- create cargo units. |  |","syntaxes":[{"syntax":"createVehicleCrew vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to populate with crew","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to populate with crew"}],"returns":{"type":"Group","types":["Group"],"description":"the group of the created crew (since Arma 3 v1.94; before that returned Nothing)","text":"Group - the group of the created crew (since Arma 3 v1.94; before that returned Nothing)"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"group createVehicleCrew vehicle","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"group to put crew in","types":["Group"],"since":null,"text":"group: Group - group to put crew in"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to populate with crew","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to populate with crew"}],"returns":{"type":"Group","types":["Group"],"description":"the group of the created crew or grpNull","text":"Group - the group of the created crew or grpNull"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"vehicle","types":["Object"]}},{"syntax":"side createVehicleCrew vehicle","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"side to create crew on","types":["Side"],"since":null,"text":"side: Side - side to create crew on"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to populate with crew","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to populate with crew"}],"returns":{"type":"Group","types":["Group"],"description":"the group of the created crew or grpNull","text":"Group - the group of the created crew or grpNull"},"form":"binary","operator":null,"left":{"text":"side","types":["Side"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_veh = createVehicle [\"B_MRAP_01_F\", getMarkerPos \"createVeh\", [], 0, \"NONE\"];\ncreateVehicleCrew _veh;\n```","code":["_veh = createVehicle [\"B_MRAP_01_F\", getMarkerPos \"createVeh\", [], 0, \"NONE\"];\ncreateVehicleCrew _veh;"]},{"text":"```sqf\n_veh = createVehicle [\"O_MRAP_02_hmg_F\", position player, [], 0, \"NONE\"];\ncreateVehicleCrew _veh;\n{\n    diag_log [_x, faction _x, side _x, side group _x];\n} forEach crew _veh;\n\n// [O Alpha 1-1:1,\"OPF_F\",EAST,EAST]\n// [O Alpha 1-1:2,\"OPF_F\",EAST,EAST]\n```","code":["_veh = createVehicle [\"O_MRAP_02_hmg_F\", position player, [], 0, \"NONE\"];\ncreateVehicleCrew _veh;\n{\n\tdiag_log [_x, faction _x, side _x, side group _x];\n} forEach crew _veh;\n\n// [O Alpha 1-1:1,\"OPF_F\",EAST,EAST]\n// [O Alpha 1-1:2,\"OPF_F\",EAST,EAST]"]}],"multiplayer":"This command seems to be Local Argument with UAVs.","problems":null,"aliases":[],"see_also":["deleteVehicleCrew","moveInDriver","moveInGunner","moveInCommander","moveInTurret","moveInCargo","BIS_fnc_spawnVehicle"],"notes":[{"user":"SilentSpike","date":"2014-08-20T14:01:00Z","text":"As of Arma 3 v1.26 the command will work on non-empty vehicles. If any of the crew defined in config are missing they will be added."},{"user":"DrPastah","date":"2015-12-22T14:19:00Z","text":"createVehicleCrew does not work with Transport Unload waypoints for helicopters. You need to spawn the pilots separately and then get them into the helicopter in order to get Transport Unload waypoints to work."},{"user":"AgentRev","date":"2017-06-02T03:26:00Z","text":"The particular seats to which units are added depend on the `dontCreateAI` property, the `hasDriver` property of the base class, and the `hasGunner` propery of turret classes.\n\nFor instance, the following snippet calculates how many seats will be occupied by the created crew:\n\n```sqf\nprivate _vehCfg = configFile >> \"CfgVehicles\" >> typeOf _vehicle;\nprivate _crewCount = {\n    round getNumber (_x >> \"dontCreateAI\") < 1 && \n    ((_x == _vehCfg && { round getNumber (_x >> \"hasDriver\") > 0 }) ||\n    (_x != _vehCfg && { round getNumber (_x >> \"hasGunner\") > 0 }))\n} count ([_vehicle, configNull] call BIS_fnc_getTurrets);\n```\n\nAlso, I've written a function to create a UAV crew for a specific side: https://gist.github.com/AgentRev/cb25d30e464f2239b6cee51fa0110c78"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"createVehicleLocal","operator":null,"title":"createVehicleLocal","type":"command","url":"https://community.bistudio.com/wiki/createVehicleLocal","revid":377538,"updated":"2026-01-02T06:54:18Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Creates an object of the given type. The Created object is not transferred through network in MP games.\nnetId of such vehicle in multiplayer will be \"0:0\". To disable local vehicle creation, use CfgDisabledCommands to blacklist this command.\nAlternatively, you can use createSimpleObject with local option enabled where applicable.","syntaxes":[{"syntax":"type createVehicleLocal position","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"vehicle/object className","types":["String"],"since":null,"text":"type: String - vehicle/object className"},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"position: PositionAGL"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"type","types":["String"]},"right":{"text":"position","types":["PositionAGL"]}},{"syntax":"createVehicleLocal [type, position, markers, placement, special]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"vehicle/object className","types":["String"],"since":null,"text":"type: String - vehicle/object className"},{"name":"position","type":"Object, Position2D or PositionATL (PositionAGL if watercraft or amphibious)","optional":false,"default":null,"description":"desired placement position","types":["Object","Position2D","PositionATL","PositionAGL"],"since":null,"text":"position: Object, Position2D or PositionATL (PositionAGL if watercraft or amphibious) - desired placement position"},{"name":"markers","type":"Array of Strings","optional":true,"default":"`[]`","description":"if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate.","types":["Array","String"],"since":null,"text":"markers: Array of Strings - (Optional, default `[]`) if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate."},{"name":"placement","type":"Number","optional":true,"default":"0","description":"the vehicle is placed inside a circle with given position as center and placement as its radius.","types":["Number"],"since":null,"text":"placement: Number - (Optional, default 0) the vehicle is placed inside a circle with given position as center and placement as its radius."},{"name":"special","type":"String","optional":true,"default":"\"NONE\"","description":"can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used.","types":["String"],"since":null,"text":"special: String - (Optional, default \"NONE\") can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used."}],"returns":{"type":"Object","types":["Object"],"description":"created vehicle or objNull if failed","text":"Object - created vehicle or objNull if failed"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, position, markers, placement, special]","types":["Array"]}}],"examples":[{"text":"```sqf\n_lightSource = \"#lightpoint\" createVehicleLocal _pos;\n```","code":["_lightSource = \"#lightpoint\" createVehicleLocal _pos;"]},{"text":"Multiple types:\n\n```sqf\nprivate _lightSource =        \"#lightsource\"        createVehicleLocal _pos;    // see [[Light Source Tutorial]]\nprivate _lightReflector =    \"#lightreflector\"    createVehicleLocal _pos;    // see [[Light Source Tutorial]] - since Arma 3 v2.06\nprivate _particleSource =    \"#particlesource\"    createVehicleLocal _pos;    // see [[Particles Tutorial]]\nprivate _dynamicSound =        \"#dynamicsound\"        createVehicleLocal _pos;    // see [[createSoundSource]]\n```","code":["private _lightSource =\t\t\"#lightsource\"\t\tcreateVehicleLocal _pos;\t// see [[Light Source Tutorial]]\nprivate _lightReflector =\t\"#lightreflector\"\tcreateVehicleLocal _pos;\t// see [[Light Source Tutorial]] - since Arma 3 v2.06\nprivate _particleSource =\t\"#particlesource\"\tcreateVehicleLocal _pos;\t// see [[Particles Tutorial]]\nprivate _dynamicSound =\t\t\"#dynamicsound\"\t\tcreateVehicleLocal _pos;\t// see [[createSoundSource]]"]},{"text":"```sqf\n// since Arma 3 v2.14\nprivate _lightPoint = createVehicleLocal [\"#lightpoint\", getMarkerPos \"marker1\", [\"marker2\", \"marker3\"], 0, \"NONE\"];\n```","code":["// since Arma 3 v2.14\nprivate _lightPoint = createVehicleLocal [\"#lightpoint\", getMarkerPos \"marker1\", [\"marker2\", \"marker3\"], 0, \"NONE\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createVehicle","createMine","deleteVehicle","createUnit"],"notes":[{"user":"Kronzky","date":"2008-06-05T07:18:00Z","text":"If the object that is created is of the type ammo, then it will created on **all** clients (*tested only on VBS2*)."},{"user":"DamonDaemon","date":"2013-09-05T18:04:00Z","text":"Indeed the type of Ammo is transfered to **ALL** clients, but apparently also the muzzle effects (firing sound, light, etc.); this includes muzzles from Horns (Truck or Car Horn, Bicycle bells, etc.) as well as any other weapon. Tested on ArmA - Arma 2:OA (latest patch)."},{"user":"demellion","date":"2018-11-02T12:16:00Z","text":"**WARNING:** Do not instigate createVehicle or createVehicleLocal within a server function executed with preInit flag.\n\nThis will cause *\"You cannot play/edit this mission\"* for a vehicles compiled from a -mod and make server skip/loop that mission init."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"crew","operator":null,"title":"crew","type":"command","url":"https://community.bistudio.com/wiki/crew","revid":348275,"updated":"2023-11-08T11:40:38Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the crew (both dead and alive) of the given vehicle.","syntaxes":[{"syntax":"crew vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Array","types":["Array"],"description":"an array with all units in the vehicle is returned.","text":"Array - an array with all units in the vehicle is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer in (crew _tank);\n```","code":["player in (crew _tank);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commander","driver","gunner","fullCrew","assignedVehicleRole"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands"]},{"name":"ctAddHeader","operator":null,"title":"ctAddHeader","type":"command","url":"https://community.bistudio.com/wiki/ctAddHeader","revid":377658,"updated":"2026-01-02T09:02:08Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds a header line of controls according to the HeaderTemplate class. Note that rows and headers are indexed separately.","syntaxes":[{"syntax":"ctAddHeader control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array with [headerIndex, createdControls]","types":["Array"],"description":"headerIndex: Number - createdControls: Array of Controls","text":"Array with [headerIndex, createdControls]\n- headerIndex: Number\n- createdControls: Array of Controls"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _array = ctAddHeader _control;\n```","code":["private _array = ctAddHeader _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctAddRow","operator":null,"title":"ctAddRow","type":"command","url":"https://community.bistudio.com/wiki/ctAddRow","revid":310853,"updated":"2022-05-07T20:24:08Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds one row of controls according to the RowTemplate class. It returns an array containing row index and array of created controls in a format [<rowIndex>, [<control0>, <control1>...<control n>]].\n\nNote that rows and headers are indexed separately.","syntaxes":[{"syntax":"ctAddRow control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_array = ctAddRow _control;\n```","code":["_array = ctAddRow _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctClear","operator":null,"title":"ctClear","type":"command","url":"https://community.bistudio.com/wiki/ctClear","revid":309971,"updated":"2022-05-05T12:17:02Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Removes all the lines from the RscControlsTable. Returns Nothing.","syntaxes":[{"syntax":"ctClear ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nctClear _control;\n```","code":["ctClear _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddHeader","ctAddRow","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctCurSel","operator":null,"title":"ctCurSel","type":"command","url":"https://community.bistudio.com/wiki/ctCurSel","revid":310869,"updated":"2022-05-07T20:24:09Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns index of the selected row. Will take only rows, but not headers into account.","syntaxes":[{"syntax":"ctCurSel ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\n_curSel = ctCurSel _control;\n```","code":["_curSel = ctCurSel _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctData","operator":null,"title":"ctData","type":"command","url":"https://community.bistudio.com/wiki/ctData","revid":309082,"updated":"2022-04-30T15:25:34Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns metadata associated with a particular row of a CT_CONTROLS_TABLE control.","syntaxes":[{"syntax":"ctrl ctData row","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":"the respective control","types":["Control"],"since":null,"text":"ctrl: Control - the respective control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"the row index","types":["Number"],"since":null,"text":"row: Number - the row index"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"row","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _data = _ctrl ctData 0;\n```","code":["private _data = _ctrl ctData 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctFindHeaderRows","operator":null,"title":"ctFindHeaderRows","type":"command","url":"https://community.bistudio.com/wiki/ctFindHeaderRows","revid":377180,"updated":"2026-01-01T10:48:22Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Gets array of indices of rows under this header.","syntaxes":[{"syntax":"ctrl ctFindHeaderRows index","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":"header's index","types":["Number"],"since":null,"text":"index: Number - header's index"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _indices = _control ctFindHeaderRows 0;\n```","code":["private _indices = _control ctFindHeaderRows 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctFindRowHeader","operator":null,"title":"ctFindRowHeader","type":"command","url":"https://community.bistudio.com/wiki/ctFindRowHeader","revid":310883,"updated":"2022-05-07T20:26:57Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Gets index of the closest header above this row.","syntaxes":[{"syntax":"ctrl ctFindRowHeader rowIndex","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"rowIndex","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rowIndex: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"rowIndex","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _index = _control ctFindRowHeader 0;\n```","code":["private _index = _control ctFindRowHeader 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctHeaderControls","operator":null,"title":"ctHeaderControls","type":"command","url":"https://community.bistudio.com/wiki/ctHeaderControls","revid":377179,"updated":"2026-01-01T10:48:06Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns array of controls on the header with the given index.","syntaxes":[{"syntax":"ctrl ctHeaderControls index","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Array of Controls","types":["Array","Control"],"description":null,"text":"Array of Controls"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_array = _control ctHeaderControls 0;\n```","code":["_array = _control ctHeaderControls 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctHeaderCount","operator":null,"title":"ctHeaderCount","type":"command","url":"https://community.bistudio.com/wiki/ctHeaderCount","revid":309979,"updated":"2022-05-05T12:17:02Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns number of headers (rows not included) in the RscControlsTable.","syntaxes":[{"syntax":"ctHeaderCount ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nctHeaderCount _control;\n```","code":["ctHeaderCount _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddHeader","ctAddRow","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctRemoveHeaders","operator":null,"title":"ctRemoveHeaders","type":"command","url":"https://community.bistudio.com/wiki/ctRemoveHeaders","revid":377178,"updated":"2026-01-01T10:47:51Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Takes array of header indices as a parameter and removes headers with those indices. Indices of remaining headers will be recomputed.","syntaxes":[{"syntax":"ctrl ctRemoveHeaders indices","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"indices","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"indices: Array of Numbers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"indices","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_control ctRemoveHeaders [0, 1, 2];\n```","code":["_control ctRemoveHeaders [0, 1, 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctRemoveRows","operator":null,"title":"ctRemoveRows","type":"command","url":"https://community.bistudio.com/wiki/ctRemoveRows","revid":376516,"updated":"2025-10-22T23:05:37Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Takes array of row indices as a parameter and removes rows with those indices. Indices of remaining rows will be recomputed.","syntaxes":[{"syntax":"ctrl ctRemoveRows [index1, index2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"indexN","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"indexN: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[index1, index2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctRemoveRows [0, 1, 2];\n```","code":["_control ctRemoveRows [0, 1, 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[{"user":"7erra","date":"2021-01-02T15:05:00Z","text":"If you want to remove a row by clicking on a button in the ControlsTable make sure that the code is scheduled. Otherwise the game will crash."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlActivate","operator":null,"title":"ctrlActivate","type":"command","url":"https://community.bistudio.com/wiki/ctrlActivate","revid":369263,"updated":"2024-09-03T18:42:41Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Launches action attached to given (button based) control. Command ignores control disabled state. (Example 2). Main syntax command only triggers engine-based actions (cancel or ok codes) and will not trigger button related User Interface Event Handlers or buttonAction, use the alternative syntax for this. \"ButtonClick\" UI event handler will also be triggered with the alternative syntax. Use isUIContext to distinguish between scripted activation and user activation.","syntaxes":[{"syntax":"ctrlActivate control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}},{"syntax":"control ctrlActivate full","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"button based control (CT_BUTTON, CT_XBUTTON, CT_SHORTCUTBUTTON, CT_ACTIVETEXT)","types":["Control"],"since":null,"text":"control: Control - button based control (CT_BUTTON, CT_XBUTTON, CT_SHORTCUTBUTTON, CT_ACTIVETEXT)"},{"name":"full","type":"Boolean","optional":false,"default":null,"description":"true to simulate button click in full including UI event handling","types":["Boolean"],"since":null,"text":"full: Boolean - true to simulate button click in full including UI event handling"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"full","types":["Boolean"]}}],"examples":[{"text":"```sqf\nctrlActivate _control;\n```","code":["ctrlActivate _control;"]},{"text":"```sqf\n_control ctrlEnable false;\nctrlActivate _control; // Action fired.\n```","code":["_control ctrlEnable false;\nctrlActivate _control; // Action fired."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlAddEventHandler","operator":null,"title":"ctrlAddEventHandler","type":"command","url":"https://community.bistudio.com/wiki/ctrlAddEventHandler","revid":376337,"updated":"2025-10-07T13:17:20Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add an event handler to the given control.\n\n> [!IMPORTANT]\n> - Control event handlers are processed in reversed order, i.e. last added: first, first added: last. So if you have an override it should be set up in the 1st added EH.\n> - When using the event names listed here with the ctrlAddEventHandler, ctrlSetEventHandler, displayAddEventHandler or displaySetEventHandler commands, the prefix \"on\" in the event name must be removed (e.g. **'ButtonDown**' instead of **'onButtonDown**').","syntaxes":[{"syntax":"control ctrlAddEventHandler [handler, function]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"handler","type":"String","optional":false,"default":null,"description":"handler name, see User Interface Event Handlers","types":["String"],"since":null,"text":"handler: String - handler name, see User Interface Event Handlers"},{"name":"function","type":"String, since Arma 3 v1.06 also Code","optional":false,"default":null,"description":"script. Several Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`","types":["String","Code"],"since":null,"text":"function: String, since Arma 3 v1.06 also Code - script. Several Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`"}],"returns":{"type":"Number","types":["Number"],"description":"handler ID or -1 if failed","text":"Number - handler ID or -1 if failed"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[handler, function]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map ctrlAddEventHandler [\"Draw\", \"_this call BIS_fnc_strategicMapOpen_draw\"];\n```","code":["_map ctrlAddEventHandler [\"Draw\", \"_this call BIS_fnc_strategicMapOpen_draw\"];"]},{"text":"```sqf\n_map ctrlAddEventHandler [\"Draw\", { hintSilent str _this }];\n```","code":["_map ctrlAddEventHandler [\"Draw\", { hintSilent str _this }];"]},{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", { hintSilent str _this }]; //Arma 3 map control\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", { hintSilent str _this }]; //Arma 3 map control"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayAddEventHandler","ctrlRemoveEventHandler","ctrlRemoveAllEventHandlers"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlAngle","operator":null,"title":"ctrlAngle","type":"command","url":"https://community.bistudio.com/wiki/ctrlAngle","revid":378507,"updated":"2026-05-03T17:04:17Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets rotation info of a control set as `ST_PICTURE`. Supported control types:\n- CT_STATIC\n- Arma 3 v2.10 CT_ACTIVETEXT","syntaxes":[{"syntax":"ctrlAngle control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"picture control","types":["Control"],"since":null,"text":"control: Control  - picture control"}],"returns":{"type":"Array with [angle, centerX, centerY]","types":["Array"],"description":"angle: Number - centerX: Number - centerY: Number","text":"Array with [angle, centerX, centerY]\n- angle: Number\n- centerX: Number\n- centerY: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlAngle _control;\n```","code":["ctrlAngle _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAngle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.52","Scripting Commands"]},{"name":"ctrlAnimateModel","operator":null,"title":"ctrlAnimateModel","type":"command","url":"https://community.bistudio.com/wiki/ctrlAnimateModel","revid":329860,"updated":"2022-08-07T23:03:59Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.84"}],"since":{"game":"arma3","name":"Arma 3","version":"1.84"},"arma3_since":"1.84","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Process an animation of 3D Arma: GUI Configuration. Command uses name defined by source property and works similar like animateSource command.","syntaxes":[{"syntax":"control ctrlAnimateModel [source, phase, speed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"},{"name":"source","type":"String","optional":false,"default":null,"description":"common source","types":["String"],"since":null,"text":"source: String - common source"},{"name":"phase","type":"Number","optional":false,"default":null,"description":"wanted animation phase","types":["Number"],"since":null,"text":"phase: Number - wanted animation phase"},{"name":"speed","type":"Boolean or Number","optional":true,"default":"false","description":"Boolean - when set to true, animation is instant\n- Arma 3 v1.66 Number - > 0 is treated as config speed value multiplier","types":["Boolean","Number"],"since":null,"text":"speed: Boolean or Number - (Optional, default false)\n- Boolean - when set to true, animation is instant\n- Arma 3 v1.66 Number - > 0 is treated as config speed value multiplier"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[source, phase, speed]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control3D ctrlAnimateModel [\"Close\", 1];\n```","code":["_control3D ctrlAnimateModel [\"Close\", 1];"]},{"text":"```sqf\n_ctrlLaptop ctrlAnimateModel [\"Lid\", 1, 2];\n```","code":["_ctrlLaptop ctrlAnimateModel [\"Lid\", 1, 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAnimationPhaseModel","ctrlCreate","ctrlDelete","ctrlModel","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.84","Scripting Commands"]},{"name":"ctrlAnimationPhaseModel","operator":null,"title":"ctrlAnimationPhaseModel","type":"command","url":"https://community.bistudio.com/wiki/ctrlAnimationPhaseModel","revid":309213,"updated":"2022-05-03T22:27:25Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.84"}],"since":{"game":"arma3","name":"Arma 3","version":"1.84"},"arma3_since":"1.84","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current animation phase of given source. Similar to animationSourcePhase.","syntaxes":[{"syntax":"control ctrlAnimationPhaseModel source","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"},{"name":"source","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"source: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"source","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _phase = _control3D ctrlAnimationPhaseModel \"Close\";\n```","code":["private _phase = _control3D ctrlAnimationPhaseModel \"Close\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAnimateModel","ctrlCreate","ctrlDelete","ctrlModel","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.84","Scripting Commands"]},{"name":"ctrlAt","operator":null,"title":"ctrlAt","type":"command","url":"https://community.bistudio.com/wiki/ctrlAt","revid":338355,"updated":"2023-03-01T00:25:09Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the control at the specified coordinates.","syntaxes":[{"syntax":"display ctrlAt [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":"the display to check","types":["Display"],"since":null,"text":"display: Display - the display to check"},{"name":"x","type":"Number","optional":false,"default":null,"description":"position (0 = left, 1 = right)","types":["Number"],"since":null,"text":"x: Number - position (0 = left, 1 = right)"},{"name":"y","type":"Number","optional":false,"default":null,"description":"position (0 = top, 1 = bottom)","types":["Number"],"since":null,"text":"y: Number - position (0 = top, 1 = bottom)"}],"returns":{"type":"Control","types":["Control"],"description":"the control at the specified coordinates, controlNull if none","text":"Control - the control at the specified coordinates, controlNull if none"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _ctrl = _myDisplay ctrlAt [0.5, 0.5];\n```","code":["private _ctrl = _myDisplay ctrlAt [0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","ctrlSetPosition","ctrlCommit"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"ctrlAutoScrollDelay","operator":null,"title":"ctrlAutoScrollDelay","type":"command","url":"https://community.bistudio.com/wiki/ctrlAutoScrollDelay","revid":310817,"updated":"2022-05-07T20:23:39Z","groups":["GUI Control","GUI Control - ListBox","GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns number of seconds auto-scroll will wait before scroll and/or rewind. -2 if scrollbar not present.\n\nAutorscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"ctrlAutoScrollDelay control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_ctrlDelay = ctrlAutoScrollDelay _ctrlGroup;\n```","code":["_ctrlDelay = ctrlAutoScrollDelay _ctrlGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAutoScrollSpeed","ctrlAutoScrollSpeed","ctrlSetAutoScrollDelay","ctrlSetAutoScrollRewind","ctrlAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: GUI Control - ListBox","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlAutoScrollRewind","operator":null,"title":"ctrlAutoScrollRewind","type":"command","url":"https://community.bistudio.com/wiki/ctrlAutoScrollRewind","revid":310871,"updated":"2022-05-07T20:24:10Z","groups":["GUI Control","GUI Control - ListBox","GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if auto-scroll should move back to start after it reaches the end.\n\nAutorscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"ctrlAutoScrollRewind control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_ctrlRewind = ctrlAutoScrollRewind _ctrlGroup;\n```","code":["_ctrlRewind = ctrlAutoScrollRewind _ctrlGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAutoScrollSpeed","ctrlAutoScrollSpeed","ctrlSetAutoScrollDelay","ctrlAutoScrollDelay","ctrlSetAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: GUI Control - ListBox","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlAutoScrollSpeed","operator":null,"title":"ctrlAutoScrollSpeed","type":"command","url":"https://community.bistudio.com/wiki/ctrlAutoScrollSpeed","revid":319021,"updated":"2022-05-13T09:22:12Z","groups":["GUI Control","GUI Control - ListBox","GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns number of seconds to auto-scroll one line. -1 if auto-scroll is disabled. -2 if scrollbar not present.\n\nAutoscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"ctrlAutoScrollSpeed control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_ctrlSpeed =  ctrlAutoScrollSpeed _ctrlGroup;\n```","code":["_ctrlSpeed =  ctrlAutoScrollSpeed _ctrlGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAutoScrollSpeed","ctrlSetAutoScrollDelay","ctrlAutoScrollDelay","ctrlSetAutoScrollRewind","ctrlAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: GUI Control - ListBox","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlBackgroundColor","operator":null,"title":"ctrlBackgroundColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlBackgroundColor","revid":377353,"updated":"2026-01-02T06:40:17Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns control's background color.","syntaxes":[{"syntax":"ctrlBackgroundColor control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlBackgroundColor _control;\n```","code":["ctrlBackgroundColor _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetBackgroundColor","ctrlText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"ctrlChecked","operator":null,"title":"ctrlChecked","type":"command","url":"https://community.bistudio.com/wiki/ctrlChecked","revid":353343,"updated":"2024-03-15T17:11:52Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current state of given CT_CHECKBOXES control. Since Arma 3 v1.72 it is possible to query multiple checkboxes by providing checkbox index. For more information see CT_CHECKBOXES.\n\n> [!NOTE]\n> The `\"CheckBoxesSelChanged\"` control EH returns the control, index of changed checkbox and its current checked state. The checked state however is not a Boolean but Number 0 or 1. To convert ctrlChecked command output into number as well, use parseNumber command","syntaxes":[{"syntax":"ctrlChecked control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_CHECKBOXES control. If control contain multiple checkboxes, only checkbox with index 0 is queried.","types":["Control"],"since":null,"text":"control: Control - CT_CHECKBOXES control. If control contain multiple checkboxes, only checkbox with index 0 is queried."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true checked, false unchecked","text":"Boolean - true checked, false unchecked"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}},{"syntax":"control ctrlChecked index","since":"arma3 1.72","effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_CHECKBOXES control","types":["Control"],"since":null,"text":"control: Control - CT_CHECKBOXES control"},{"name":"index","type":"Number","optional":false,"default":null,"description":"checkbox index","types":["Number"],"since":null,"text":"index: Number - checkbox index"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true checked, false unchecked","text":"Boolean - true checked, false unchecked"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nctrlChecked _control;\n```","code":["ctrlChecked _control;"]},{"text":"```sqf\n_control ctrlChecked 3;\n```","code":["_control ctrlChecked 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetChecked","cbChecked","cbSetChecked"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlClassName","operator":null,"title":"ctrlClassName","type":"command","url":"https://community.bistudio.com/wiki/ctrlClassName","revid":321025,"updated":"2022-05-13T11:30:29Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the class name of a Control as it is defined in config. If you need config class of a game created Display, it is stored on display itself:\n\n```sqf\n_className = findDisplay 12 getVariable [\"BIS_fnc_initDisplay_configClass\", \"\"]; // \"RscDiary\"\n```","syntaxes":[{"syntax":"ctrlClassName control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control : Control"}],"returns":{"type":"String","types":["String"],"description":"class name","text":"String - class name"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"List class names of all controls present on display 46:\n\n```sqf\n_return = [];\n{\n    _return pushBack format [\"IDC: %1, className: %2\", ctrlIDC _x, ctrlClassName _x];\n} forEach (allControls findDisplay 46);\n\ncopyToClipboard (_return joinString endl);\n```","code":["_return = [];\n{\n\t_return pushBack format [\"IDC: %1, className: %2\", ctrlIDC _x, ctrlClassName _x];\n} forEach (allControls findDisplay 46);\n\ncopyToClipboard (_return joinString endl);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlIDC","ctrlIDD","ctrlType","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"ctrlCommit","operator":null,"title":"ctrlCommit","type":"command","url":"https://community.bistudio.com/wiki/ctrlCommit","revid":369237,"updated":"2024-09-03T10:35:01Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Commits control animation to last specified duration.\n\n> [!IMPORTANT]\n> The duration of the animation is not guaranteed to be exactly the same as the given time.","syntaxes":[{"syntax":"control ctrlCommit time","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"control to animate","types":["Control"],"since":null,"text":"control: Control - control to animate"},{"name":"time","type":"Number","optional":false,"default":null,"description":"animation duration","types":["Number"],"since":null,"text":"time: Number - animation duration"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"time","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlCommit 2; // make animation last approx. 2 seconds\n```","code":["_control ctrlCommit 2; // make animation last approx. 2 seconds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCommitted","ctrlSetPosition","ctrlSetFade"],"notes":[{"user":"Nelis75733126","date":"2015-04-11T23:06:00Z","text":"**2024-04-16 edit:**:\n`ctrlCommit` is required to apply the effect of, for example, ctrlSetFade."},{"user":"Demellion","date":"2017-08-28T11:33:00Z","text":"The resulting speed might not to be exactly what ctrlCommit commands it to be. It seems to be dependent on your current framerate. Example:\n\n```sqf\n_ctrl ctrlSetFade 0.5;\n_ctrl ctrlCommit 1;\n```\n\nWill actually result in:\n\n| FPS | Duration |\n|---|---|\n| 60+ | ~1.0s |\n| ~30 | ~1.2s |\n| 10- | ~5-10s |\n\nThis phenomenon probably occurs because of engine time simulation disruption caused by performance damage."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlCommitted","operator":null,"title":"ctrlCommitted","type":"command","url":"https://community.bistudio.com/wiki/ctrlCommitted","revid":310867,"updated":"2022-05-07T20:24:09Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if the control animation is finished.","syntaxes":[{"syntax":"ctrlCommitted controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_done = ctrlCommitted _control;\n```","code":["_done = ctrlCommitted _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCommit"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlCreate","operator":null,"title":"ctrlCreate","type":"command","url":"https://community.bistudio.com/wiki/ctrlCreate","revid":378109,"updated":"2026-02-15T22:08:16Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a new control in the given display.\n\nThe control class could be an existing class from the main config or a custom class defined in the mission config.\nThe main config is searched first, if the class does not exist there, the mission config is searched.\nSome of the common controls defined in the main config that can be used with this command:\n\n> [!NOTE]\n> This list contains controls which are guaranteed to work with this command. However, controls not listed here should work as well - as long as they are properly defined.\n\n| Class | Description | Available since |\n|---|---|---|\n| RscText | simple text box |  |\n| RscStructuredText | text box which supports structured text |  |\n| RscTextMulti | simple multiline text box |  |\n| RscPicture | simple picture box |  |\n| RscPictureKeepAspect | picture box that doesn't stretch picture |  |\n| RscEdit | input box |  |\n| RscEditMulti | multiline input box |  |\n| RscEditReadOnly | input box with | Arma 3 v1.98 |\n| RscEditMultiReadOnly | multiline input box with | Arma 3 v1.98 |\n| RscTree | tree view control |  |\n| RscTreeMulti | multi-select tree view | Arma 3 v2.02 |\n| RscTreeSearch | searchable tree view control (see Example 4) |  |\n| RscVideo | picture control with autostart for video texture (see BIS_fnc_playVideo) |  |\n| RscVideoKeepAspect | picture control for video to keep original video aspect ratio |  |\n| RscButtonMenuBIKI | shortcut button with url pointing to \"https://community.bistudio.com/wiki/\" | Arma 3 v1.98 |\n| RscControlsGroup | default controls group |  |\n| RscControlsGroupNoScrollbars | controls group without scrollbars |  |\n| RscControlsGroupNoHScrollbars | controls group without horizontal scrollbar |  |\n| RscControlsGroupNoVScrollbars | controls group without vertical scrollbar |  |\n\n> [!IMPORTANT]\n> If you are creating CT_MAP control dynamically, use ctrlMapSetPosition to update control position instead of ctrlSetPosition.","syntaxes":[{"syntax":"display ctrlCreate [class, idc, controlsGroup]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":"display in which control will be created","types":["Display"],"since":null,"text":"display: Display - display in which control will be created"},{"name":"class","type":"String or Arma 3 v2.14 Config","optional":false,"default":null,"description":"existing classname (see ctrlCreate/classnames) of the new control;  Arma 3 v1.70 it is possible to use classes defined in mission config","types":["String","Config"],"since":null,"text":"class: String or Arma 3 v2.14 Config - existing classname (see ctrlCreate/classnames) of the new control;  Arma 3 v1.70 it is possible to use classes defined in mission config"},{"name":"idc","type":"Number","optional":false,"default":null,"description":"IDC of the new control. Use -1 if not needed. Using 0 will use the IDC that is provided by the class.\n\n> [!WARNING]\n> Be careful when setting the IDC to `-1` if the GUI also contains a CT_LISTNBOX since `idcLeft` and `idcRight` by default have `idc = -1;`.","types":["Number"],"since":null,"text":"idc: Number - IDC of the new control. Use -1 if not needed. Using 0 will use the IDC that is provided by the class.\n\n> [!WARNING]\n> Be careful when setting the IDC to `-1` if the GUI also contains a CT_LISTNBOX since `idcLeft` and `idcRight` by default have `idc = -1;`."},{"name":"controlsGroup","type":"Control","optional":true,"default":"controlNull","description":"creates controls in existing controls group","types":["Control"],"since":null,"text":"controlsGroup: Control - (Optional, default controlNull) creates controls in existing controls group"}],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[class, idc, controlsGroup]","types":["Array"]}}],"examples":[{"text":"```sqf\n_display ctrlCreate [\"RscText\", 1234];\n```","code":["_display ctrlCreate [\"RscText\", 1234];"]},{"text":"```sqf\n_map = findDisplay 46 ctrlCreate [\"RscMapControl\", -1];\n_multiLineText = findDisplay 46 ctrlCreate [\"RscTextMulti\", -1];\n_multiLineEdit = findDisplay 46 ctrlCreate [\"RscEditMulti\", -1];\n```","code":["_map = findDisplay 46 ctrlCreate [\"RscMapControl\", -1];\n_multiLineText = findDisplay 46 ctrlCreate [\"RscTextMulti\", -1];\n_multiLineEdit = findDisplay 46 ctrlCreate [\"RscEditMulti\", -1];"]},{"text":"```sqf\nmyControl = findDisplay 0 ctrlCreate [\"RscText\", 1234, findDisplay 0 displayCtrl 2300];\n```","code":["myControl = findDisplay 0 ctrlCreate [\"RscText\", 1234, findDisplay 0 displayCtrl 2300];"]},{"text":"Create Tree View control with search. Available `RscTreeSearch` class is hardcoded to be used with `RscEdit` with idc `645`.\nExample below demonstrates how to. After tree is generated, try typing something in the top box.\n\n```sqf\n0 spawn \n{\n    disableSerialization;\n\n    _display = (if (is3DEN) then {findDisplay 313} else {[] call BIS_fnc_displayMission}) createDisplay \"RscDisplayEmpty\";\n\n    _edit = _display ctrlCreate [\"RscEdit\", 645];\n    _edit ctrlSetPosition [0,0,1,0.04];\n    _edit ctrlSetBackgroundColor [0,0,0,1];\n    _edit ctrlCommit 0;\n\n    _tv = _display ctrlCreate [\"RscTreeSearch\", -1];\n    _tv ctrlSetFont \"EtelkaMonospacePro\";\n    _tv ctrlSetFontHeight 0.03;\n    _tv ctrlSetPosition [0,0.06,1,0.94];\n    _tv ctrlSetBackgroundColor [0,0,0,1];\n    _tv ctrlCommit 0;\n\n    _classes = \"true\" configClasses (configFile >> \"CfgVehicles\");\n\n    for \"_i\" from 0 to 5 do\n    {\n        _tv tvAdd [[], configName selectRandom _classes];\n        for \"_j\" from 0 to 5 do\n        {\n            _tv tvAdd [[_i], configName selectRandom _classes];\n            for \"_k\" from 0 to 5 do\n            {\n                _tv tvAdd [[_i, _j], configName selectRandom _classes];\n                for \"_n\" from 0 to 5 do\n                {\n                    _tv tvAdd [[_i, _j, _k], configName selectRandom _classes];\n                };\n            };\n        };\n    };\n};\n```","code":["0 spawn \n{\n\tdisableSerialization;\n\n\t_display = (if (is3DEN) then {findDisplay 313} else {[] call BIS_fnc_displayMission}) createDisplay \"RscDisplayEmpty\";\n\n\t_edit = _display ctrlCreate [\"RscEdit\", 645];\n\t_edit ctrlSetPosition [0,0,1,0.04];\n\t_edit ctrlSetBackgroundColor [0,0,0,1];\n\t_edit ctrlCommit 0;\n\n\t_tv = _display ctrlCreate [\"RscTreeSearch\", -1];\n\t_tv ctrlSetFont \"EtelkaMonospacePro\";\n\t_tv ctrlSetFontHeight 0.03;\n\t_tv ctrlSetPosition [0,0.06,1,0.94];\n\t_tv ctrlSetBackgroundColor [0,0,0,1];\n\t_tv ctrlCommit 0;\n\n\t_classes = \"true\" configClasses (configFile >> \"CfgVehicles\");\n\n\tfor \"_i\" from 0 to 5 do\n\t{\n\t\t_tv tvAdd [[], configName selectRandom _classes];\n\t\tfor \"_j\" from 0 to 5 do\n\t\t{\n\t\t\t_tv tvAdd [[_i], configName selectRandom _classes];\n\t\t\tfor \"_k\" from 0 to 5 do\n\t\t\t{\n\t\t\t\t_tv tvAdd [[_i, _j], configName selectRandom _classes];\n\t\t\t\tfor \"_n\" from 0 to 5 do\n\t\t\t\t{\n\t\t\t\t\t_tv tvAdd [[_i, _j, _k], configName selectRandom _classes];\n\t\t\t\t};\n\t\t\t};\n\t\t};\n\t};\n};"]},{"text":"Create a simple submit edit box and show content in hint:\n\n```sqf\ndisableSerialization;\nprivate _display = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGroup = _display ctrlCreate [\"RscControlsGroupNoScrollbars\", -1];\nprivate _ctrlBackground = _display ctrlCreate [\"RscTextMulti\", -1, _ctrlGroup];\nIDD_EDIT_BOX = 123;\nprivate _ctrlEdit = _display ctrlCreate [\"RscEditMulti\", IDD_EDIT_BOX, _ctrlGroup];\nprivate _ctrlButton = _display ctrlCreate [\"RscShortcutButton\", -1, _ctrlGroup];\n_ctrlGroup ctrlSetPosition [0.5, 0.5, 0, 0];\n_ctrlGroup ctrlCommit 0;\n_ctrlBackground ctrlSetPosition [0, 0, 0.5, 0.5];\n_ctrlBackground ctrlSetBackgroundColor [0.5, 0.5, 0.5, 0.9];\n_ctrlBackground ctrlSetText \"ENTER TEXT:\";\n_ctrlBackground ctrlEnable false;\n_ctrlBackground ctrlCommit 0;\n_ctrlEdit ctrlSetPosition [0.01, 0.05, 0.48, 0.34];\n_ctrlEdit ctrlSetBackgroundColor [0, 0, 0, 0.5];\n_ctrlEdit ctrlCommit 0;\n_ctrlButton ctrlSetPosition [0.185, 0.42, 0.13, 0.05];\n_ctrlButton ctrlCommit 0;\n_ctrlButton ctrlSetText \"SUBMIT\";\n_ctrlButton ctrlAddEventHandler [\"ButtonClick\", \n{\n    params [\"_ctrl\"];\n    _display = ctrlParent _ctrl;\n    _text = ctrlText (_display displayCtrl IDD_EDIT_BOX);\n    if (_text == \"\") then { _text = \"EMPTY\" };\n    hint _text;\n    _display closeDisplay 1;\n}];\nctrlSetFocus _ctrlEdit;\n_ctrlGroup ctrlSetPosition [0.25, 0.25, 0.5, 0.5];\n_ctrlGroup ctrlCommit 0.1;\nplaySound \"Hint3\";\n```","code":["disableSerialization;\nprivate _display = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGroup = _display ctrlCreate [\"RscControlsGroupNoScrollbars\", -1];\nprivate _ctrlBackground = _display ctrlCreate [\"RscTextMulti\", -1, _ctrlGroup];\nIDD_EDIT_BOX = 123;\nprivate _ctrlEdit = _display ctrlCreate [\"RscEditMulti\", IDD_EDIT_BOX, _ctrlGroup];\nprivate _ctrlButton = _display ctrlCreate [\"RscShortcutButton\", -1, _ctrlGroup];\n_ctrlGroup ctrlSetPosition [0.5, 0.5, 0, 0];\n_ctrlGroup ctrlCommit 0;\n_ctrlBackground ctrlSetPosition [0, 0, 0.5, 0.5];\n_ctrlBackground ctrlSetBackgroundColor [0.5, 0.5, 0.5, 0.9];\n_ctrlBackground ctrlSetText \"ENTER TEXT:\";\n_ctrlBackground ctrlEnable false;\n_ctrlBackground ctrlCommit 0;\n_ctrlEdit ctrlSetPosition [0.01, 0.05, 0.48, 0.34];\n_ctrlEdit ctrlSetBackgroundColor [0, 0, 0, 0.5];\n_ctrlEdit ctrlCommit 0;\n_ctrlButton ctrlSetPosition [0.185, 0.42, 0.13, 0.05];\n_ctrlButton ctrlCommit 0;\n_ctrlButton ctrlSetText \"SUBMIT\";\n_ctrlButton ctrlAddEventHandler [\"ButtonClick\", \n{\n\tparams [\"_ctrl\"];\n\t_display = ctrlParent _ctrl;\n\t_text = ctrlText (_display displayCtrl IDD_EDIT_BOX);\n\tif (_text == \"\") then { _text = \"EMPTY\" };\n\thint _text;\n\t_display closeDisplay 1;\n}];\nctrlSetFocus _ctrlEdit;\n_ctrlGroup ctrlSetPosition [0.25, 0.25, 0.5, 0.5];\n_ctrlGroup ctrlCommit 0.1;\nplaySound \"Hint3\";"]},{"text":"```sqf\n// since Arma 3 v2.14\nfindDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [configFile >> \"RscDisplayBootcampMsgBox\" >> \"controls\" >> \"BootcampMessageBox\", -1];\n```","code":["// since Arma 3 v2.14\nfindDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [configFile >> \"RscDisplayBootcampMsgBox\" >> \"controls\" >> \"BootcampMessageBox\", -1];"]},{"text":"```sqf\n// Creates a vertical slider. Execute in [[Eden Editor]]\nprivate _display = findDisplay 313 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlSlider = _display ctrlCreate [\"ctrlSliderV\", -1];\n\n_ctrlSlider ctrlSetPosition \n[\n  0.5 - 0.5 * pixelGrid * pixelW * 10, \n  0.5 - 0.5 * pixelGrid * pixelH * 40, \n  0.5 * pixelGrid * pixelW * 20, \n  0.5 * pixelGrid * pixelH * 80\n];\n\n_ctrlSlider ctrlCommit 0;\n```","code":["// Creates a vertical slider. Execute in [[Eden Editor]]\nprivate _display = findDisplay 313 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlSlider = _display ctrlCreate [\"ctrlSliderV\", -1];\n\n_ctrlSlider ctrlSetPosition \n[\n  0.5 - 0.5 * pixelGrid * pixelW * 10, \n  0.5 - 0.5 * pixelGrid * pixelH * 40, \n  0.5 * pixelGrid * pixelW * 20, \n  0.5 * pixelGrid * pixelH * 80\n];\n\n_ctrlSlider ctrlCommit 0;"]},{"text":"```sqf\n// The following script creates a button that follows the position of the player unit in [[Eden Editor]]\n\nif (isNull player) exitWith {[\"Place a player entity first\", 1] call BIS_fnc_3DENNotification};\n\nprivate _display = findDisplay 313;\n\nprivate _ctrlButton = _display ctrlCreate [\"ctrlButton\", 1234];\n_ctrlButton ctrlSetText \"Delete Me\";\n\n_ctrlButton ctrlAddEventHandler [\"ButtonClick\",\n{\n    params [\"_ctrlButton\"];\n\n    onEachFrame {};\n    _ctrlButton spawn {sleep 0.05; ctrlDelete _this};\n}];\n\nonEachFrame\n{\n    private _ctrlButton = findDisplay 313 displayCtrl 1234;\n\n    if (isNull player) exitWith {};\n\n    (worldToScreen getPosWorld player) params [\"_xPos\", \"_yPos\"];\n\n    _ctrlButton ctrlSetPosition [_xPos, _yPos, 0.1 * safeZoneW, 0.05 * safeZoneH];\n    _ctrlButton ctrlCommit 0;\n};\n```","code":["// The following script creates a button that follows the position of the player unit in [[Eden Editor]]\n\nif (isNull player) exitWith {[\"Place a player entity first\", 1] call BIS_fnc_3DENNotification};\n\nprivate _display = findDisplay 313;\n\nprivate _ctrlButton = _display ctrlCreate [\"ctrlButton\", 1234];\n_ctrlButton ctrlSetText \"Delete Me\";\n\n_ctrlButton ctrlAddEventHandler [\"ButtonClick\",\n{\n    params [\"_ctrlButton\"];\n\n    onEachFrame {};\n    _ctrlButton spawn {sleep 0.05; ctrlDelete _this};\n}];\n\nonEachFrame\n{\n    private _ctrlButton = findDisplay 313 displayCtrl 1234;\n\n    if (isNull player) exitWith {};\n\n    (worldToScreen getPosWorld player) params [\"_xPos\", \"_yPos\"];\n\n    _ctrlButton ctrlSetPosition [_xPos, _yPos, 0.1 * safeZoneW, 0.05 * safeZoneH];\n    _ctrlButton ctrlCommit 0;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapSetPosition","allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"ctrlDelete","operator":null,"title":"ctrlDelete","type":"command","url":"https://community.bistudio.com/wiki/ctrlDelete","revid":337526,"updated":"2023-02-05T19:30:47Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deletes given control. The control has to be created either by script with ctrlCreate or to have `deletable` property in config set to 1. Use ctrlShow false and ctrlEnable false to disable controls that cannot be deleted. Returns Boolean indicating  whether the deletion was successful.\n\n> [!WARNING]\n> Using ctrlDelete in a UI eventhandler called by the to be deleted control will crash the game! This also happens when a controls group is deleted that contains the \"calling\" control.","syntaxes":[{"syntax":"ctrlDelete control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlDelete ((findDisplay 20000) displayCtrl 20001);\n```","code":["ctrlDelete ((findDisplay 20000) displayCtrl 20001);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"ctrlEnable","operator":null,"title":"ctrlEnable","type":"command","url":"https://community.bistudio.com/wiki/ctrlEnable","revid":364166,"updated":"2024-05-05T10:46:43Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Enables or disables a control of the currently active user dialog.\nDisabled controls cannot be clicked onto.\nRead Arma: GUI Configuration for more information about user dialogs and controls.","syntaxes":[{"syntax":"ctrlEnable [idc, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"true to enable the control, false to disable it","types":["Boolean"],"since":null,"text":"enable: Boolean - true to enable the control, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, enable]","types":["Array"]}},{"syntax":"controlName ctrlEnable enable","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nctrlEnable [100, false];\n```","code":["ctrlEnable [100, false];"]},{"text":"```sqf\n_ctrl ctrlEnable false;\n```","code":["_ctrl ctrlEnable false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlEnabled"],"notes":[{"user":"Yuval","date":"2017-07-20T11:59:00Z","text":"Please do note that enabled controls can gain focus upon click. Therefore do not enable background controls or else they will cover any controls on top of them.\n\nAs a general rule of thumb, enabled controls should only be already on the top of the GUI."},{"user":"R3vo","date":"2020-09-07T22:26:00Z","text":"One can disable a control when it is loaded by using ctrlEnable in the onLoad event handler.\n\n```cpp\nclass MyDialog\n{\n    class MyControl\n    {\n        onLoad = \"(_this # 0) ctrlEnable false;\";\n    };\n};\n```"}],"categories":[]},{"name":"ctrlEnabled","operator":null,"title":"ctrlEnabled","type":"command","url":"https://community.bistudio.com/wiki/ctrlEnabled","revid":338573,"updated":"2023-03-20T14:59:19Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns if a control on the currently active user dialog is enabled. Disabled controls cannot be focused. Read Arma: GUI Configuration for more information about user dialogs and controls.","syntaxes":[{"syntax":"ctrlEnabled idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the control is enabled, false if not","text":"Boolean - true if the control is enabled, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"ctrlEnabled controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the control is enabled, false if not","text":"Boolean - true if the control is enabled, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\nif !(ctrlEnabled 100) then\n{\n    ctrlEnable [100, true];\n};\n```","code":["if !(ctrlEnabled 100) then\n{\n\tctrlEnable [100, true];\n};"]},{"text":"```sqf\n_enabled = ctrlEnabled _control;\n```","code":["_enabled = ctrlEnabled _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlEnable"],"notes":[],"categories":[]},{"name":"ctrlFade","operator":null,"title":"ctrlFade","type":"command","url":"https://community.bistudio.com/wiki/ctrlFade","revid":379115,"updated":"2026-10-07T21:16:51Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current fade factor of control.\n\n> [!NOTE]\n> Despite having `fade = 1;` inside a control's config, this command **will** report a fade of 0.\n>\n> Only the value actually set by ctrlSetFade will be returned by ctrlFade.","syntaxes":[{"syntax":"ctrlFade controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_fade = ctrlFade _control;\n```","code":["_fade = ctrlFade _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFade"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlFontHeight","operator":null,"title":"ctrlFontHeight","type":"command","url":"https://community.bistudio.com/wiki/ctrlFontHeight","revid":309906,"updated":"2022-05-05T12:16:53Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns control's font size, usually `sizeEx` value (see ctrlSetFontHeight).","syntaxes":[{"syntax":"ctrlFontHeight control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlFontHeight _control;\n```","code":["ctrlFontHeight _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextHeight","ctrlTextWidth","ctrlSetFontHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlForegroundColor","operator":null,"title":"ctrlForegroundColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlForegroundColor","revid":377364,"updated":"2026-01-02T06:40:35Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns control's foreground color.","syntaxes":[{"syntax":"ctrlForegroundColor control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlForegroundColor _control;\n```","code":["ctrlForegroundColor _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetForegroundColor","ctrlText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"ctrlGetProperty","operator":null,"title":"ctrlGetProperty","type":"command","url":"https://community.bistudio.com/wiki/ctrlGetProperty","revid":379130,"updated":"2026-10-09T16:30:40Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.24"}],"since":{"game":"arma3","name":"Arma 3","version":"2.24"},"arma3_since":"2.24","branch":"dev","locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns one or multiple given properties of given control.","syntaxes":[{"syntax":"control ctrlGetProperty property","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"property","type":"String","optional":false,"default":null,"description":"Any property available for given control type. Case insensitive","types":["String"],"since":null,"text":"property: String - Any property available for given control type. Case insensitive"}],"returns":{"type":"Anything","types":["Anything"],"description":"Return value depends on the property","text":"Anything - Return value depends on the property"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"property","types":["String"]}},{"syntax":"control ctrlGetProperty properties","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"properties","type":"Array of Strings","optional":false,"default":null,"description":"Properties available for given control type. Case insensitive","types":["Array","String"],"since":null,"text":"properties: Array of Strings - Properties available for given control type. Case insensitive"}],"returns":{"type":"HashMap in format:","types":["HashMap"],"description":"key: String - Name of the property - value: Anything - Value depends on the property","text":"HashMap in format:\n- key: String -  Name of the property\n- value: Anything - Value depends on the property"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"properties","types":["Array","String"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlGetProperty \"x\"; // Return 0.015\n```","code":["_ctrl ctrlGetProperty \"x\"; // Return 0.015"]},{"text":"```sqf\n_ctrl ctrlGetProperty [\"x\", \"colorBackground\"]; // Return {\"x\": 0.015, \"colorBackground\": [1, 0.4, 1, 1]}\n```","code":["_ctrl ctrlGetProperty [\"x\", \"colorBackground\"]; // Return {\"x\": 0.015, \"colorBackground\": [1, 0.4, 1, 1]}"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetProperty"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Development Branch","Command Group: GUI Control","Introduced with Arma 3 version 2.24","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlHTMLLoaded","operator":null,"title":"ctrlHTMLLoaded","type":"command","url":"https://community.bistudio.com/wiki/ctrlHTMLLoaded","revid":369233,"updated":"2024-09-03T10:35:01Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true when HTML content was successfully loaded.","syntaxes":[{"syntax":"ctrlHTMLLoaded control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_control htmlLoad \"test.html\";\nif (!ctrlHTMLLoaded _control) then {\n    hint \"Loading test.html failed!\";\n};\n```","code":["_control htmlLoad \"test.html\";\nif (!ctrlHTMLLoaded _control) then {\n\thint \"Loading test.html failed!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["htmlLoad","Arma: GUI Configuration"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlIDC","operator":null,"title":"ctrlIDC","type":"command","url":"https://community.bistudio.com/wiki/ctrlIDC","revid":364443,"updated":"2024-05-16T09:58:13Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns control IDC.","syntaxes":[{"syntax":"ctrlIDC control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlIDC _ctrl;\n```","code":["ctrlIDC _ctrl;"]},{"text":"```sqf\nctrlIDC controlNull; // returns -1\n```","code":["ctrlIDC controlNull; // returns -1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlIDD","operator":null,"title":"ctrlIDD","type":"command","url":"https://community.bistudio.com/wiki/ctrlIDD","revid":376847,"updated":"2025-12-05T16:57:27Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns display IDD.","syntaxes":[{"syntax":"ctrlIDD display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\n_display = findDisplay 46;\nctrlIDD _display; // 46\n```","code":["_display = findDisplay 46;\nctrlIDD _display; // 46"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayCtrl","findDisplay"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlMapAnimAdd","operator":null,"title":"ctrlMapAnimAdd","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapAnimAdd","revid":377869,"updated":"2026-01-04T11:37:23Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds the next frame to the map animation.","syntaxes":[{"syntax":"map ctrlMapAnimAdd [time, zoom, position]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"CT_MAP control","types":["Control"],"since":null,"text":"map: Control - CT_MAP control"},{"name":"time","type":"Number","optional":false,"default":null,"description":"duration of the animation in seconds","types":["Number"],"since":null,"text":"time: Number - duration of the animation in seconds"},{"name":"zoom","type":"Number","optional":false,"default":null,"description":"zoom in range from 0.001 (max) to 1 (min). Custom map scales can be set in map control's config. See also ctrlMapScale","types":["Number"],"since":null,"text":"zoom: Number - zoom in range from 0.001 (max) to 1 (min). Custom map scales can be set in map control's config. See also ctrlMapScale"},{"name":"position","type":"Position2D, Position3D, Object","optional":false,"default":null,"description":null,"types":["Position2D","Position3D","Object"],"since":null,"text":"position: Position2D, Position3D, Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[time, zoom, position]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map ctrlMapAnimAdd [1, 0.1, getMarkerPos \"anim1\"];\nctrlMapAnimCommit _map;\n```","code":["_map ctrlMapAnimAdd [1, 0.1, getMarkerPos \"anim1\"];\nctrlMapAnimCommit _map;"]},{"text":"Center map on player:\n\n```sqf\n_ctrl ctrlMapAnimAdd [0, 0.05, player];\nctrlMapAnimCommit _ctrl;\n```","code":["_ctrl ctrlMapAnimAdd [0, 0.05, player];\nctrlMapAnimCommit _ctrl;"]},{"text":"```sqf\n_map ctrlMapSetPosition [];\n_map ctrlMapAnimAdd [1, 0.1, getMarkerPos \"anim1\"];\nctrlMapAnimCommit _map;\n```","code":["_map ctrlMapSetPosition [];\n_map ctrlMapAnimAdd [1, 0.1, getMarkerPos \"anim1\"];\nctrlMapAnimCommit _map;"]}],"multiplayer":null,"problems":"When used on a CT_MAP that was created dynamically the target position could be offset. Use ctrlMapSetPosition before adding animation (Example 3).","aliases":[],"see_also":["ctrlMapSetPosition","mapAnimAdd","mapAnimClear","mapAnimCommit","mapAnimDone","ctrlMapAnimClear","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapAnimClear","operator":null,"title":"ctrlMapAnimClear","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapAnimClear","revid":339139,"updated":"2023-04-26T10:55:02Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Clears the map animation.","syntaxes":[{"syntax":"ctrlMapAnimClear controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlMapAnimClear _ctrlMap;\n```","code":["ctrlMapAnimClear _ctrlMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimClear","mapAnimCommit","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapAnimCommit","operator":null,"title":"ctrlMapAnimCommit","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapAnimCommit","revid":321386,"updated":"2022-05-14T11:14:10Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Plays the map animation.","syntaxes":[{"syntax":"ctrlMapAnimCommit mapControl","since":null,"effect":null,"exec":null,"params":[{"name":"mapControl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"mapControl: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"mapControl","types":["Control"]}}],"examples":[{"text":"Center map on player:\n\n```sqf\n_ctrl ctrlMapAnimAdd [0, 0.05, player];\nctrlMapAnimCommit _ctrl;\n```","code":["_ctrl ctrlMapAnimAdd [0, 0.05, player];\nctrlMapAnimCommit _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimClear","mapAnimCommit","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimDone"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapAnimDone","operator":null,"title":"ctrlMapAnimDone","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapAnimDone","revid":351328,"updated":"2023-11-27T05:10:48Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Checks whether the map animation has finished.","syntaxes":[{"syntax":"ctrlMapAnimDone controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_isDone = ctrlMapAnimDone _ctrlMap;\n```","code":["_isDone = ctrlMapAnimDone _ctrlMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimClear","mapAnimCommit","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimCommit"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapCursor","operator":null,"title":"ctrlMapCursor","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapCursor","revid":369056,"updated":"2024-09-02T20:24:53Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the default cursor that appears when interacting with a map control to a custom one. Use an empty string to restore the default cursor.\n\n> [!IMPORTANT]\n> Before Arma 3, if the specified cursor does not exist the default is used and no error is produced.\n>\n> In Arma 3, this would result in the following error: `\"No entry 'bin\\config.bin/CfgWrapperUI/Cursors'\"`.\n\nThe cursor is the name of a config entry from *CfgWrapperUI / Cursors*. This command has the following specifics:\n- When used on the Main Map (`findDisplay 12 displayCtrl 51`), it is possible to override multiple default cursors. For example, while leaving default \"Arrow\" intact, it is possible to just override \"Scroll\" with e.g \"Wait\" (See #Example 3)\n- When used on a custom map, for example user made Mini Map, there is only one single cursor \"\" for everything, therefore only this cursor can be overridden (see #Example 4 on how to override it)\nSome possible class names (See ctrlMapCursor/cursors for the whole list):\n- Arrow\n- Track\n- Move\n- Scroll\n- Rotate\n- Track3D\n- Move3D\n- Rotate3D\n- Raise3D\n- Wait\n- HC_move\n- HC_overFriendly\n- HC_overEnemy\n- HC_overMission\n- HC_unsel","syntaxes":[{"syntax":"control ctrlMapCursor [defaultCursor, newCursor]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"control: Control - map control"},{"name":"defaultCursor","type":"String","optional":false,"default":null,"description":"cursor class name, **case-sensitive**","types":["String"],"since":null,"text":"defaultCursor: String - cursor class name, **case-sensitive**"},{"name":"newCursor","type":"String","optional":false,"default":null,"description":"cursor class name, **case-sensitive**","types":["String"],"since":null,"text":"newCursor: String - cursor class name, **case-sensitive**"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[defaultCursor, newCursor]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map ctrlMapCursor [\"Track\", \"Arrow\"];\n```","code":["_map ctrlMapCursor [\"Track\", \"Arrow\"];"]},{"text":"```sqf\nuiNamespace setVariable [\"_map\", findDisplay 12 displayCtrl 51];\n(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\", \"HC_overFriendly\"];\n```","code":["uiNamespace setVariable [\"_map\", findDisplay 12 displayCtrl 51];\n(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\", \"HC_overFriendly\"];"]},{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlMapCursor [\"Scroll\", \"Wait\"];\n```","code":["findDisplay 12 displayCtrl 51 ctrlMapCursor [\"Scroll\", \"Wait\"];"]},{"text":"Cycle through all available cursors over custom map:\n\n```sqf\n0 spawn\n{\n    disableSerialization;\n    _map = findDisplay 46 createDisplay \"RscCredits\" ctrlCreate [\"RscMapControl\", -1];\n    _map ctrlSetPosition [0,0,1,1];\n    _map ctrlCommit 0;\n    {\n        _map ctrlMapCursor [\"\", configName _x]; //<-- the actual usage\n        hint format [\"Current cursor: %1\", configName _x];\n        sleep 1;\n    }\n    forEach (\"true\" configClasses (configFile >> \"CfgWrapperUI\" >> \"Cursors\"));\n};\n```","code":["0 spawn\n{\n\tdisableSerialization;\n\t_map = findDisplay 46 createDisplay \"RscCredits\" ctrlCreate [\"RscMapControl\", -1];\n\t_map ctrlSetPosition [0,0,1,1];\n\t_map ctrlCommit 0;\n\t{\n\t\t_map ctrlMapCursor [\"\", configName _x]; //<-- the actual usage\n\t\thint format [\"Current cursor: %1\", configName _x];\n\t\tsleep 1;\n\t}\n\tforEach (\"true\" configClasses (configFile >> \"CfgWrapperUI\" >> \"Cursors\"));\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMousePosition","getMousePosition"],"notes":[{"user":"Bull A","date":"2016-02-08T22:43:00Z","text":"When using this command, the cursor will change for the whole display, resulting in visual glitches. Adding the onMouseMoving event handler can help solve this problem:\n\n```sqf\n_control ctrlAddEventHandler [\"MouseMoving\", {\n    params [\n        [\"_mapCtrl\",controlNull, [controlNull]],\n        [\"_xPos\",-1,[0]],\n        [\"_yPos\",-1,[0]],\n        [\"_mouseIn\", false, [true]]\n    ];\n\n    if (_mouseIn) then {\n    // Mouse is in control area\n    _mapCtrl ctrlMapCursor [\"\", \"Track\"];\n    } else {\n    // Mouse is out of control area, goes back to arrow\n    _mapCtrl ctrlMapCursor [\"\", \"Arrow\"];\n    };\n}];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapDir","operator":null,"title":"ctrlMapDir","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapDir","revid":347213,"updated":"2023-09-05T16:49:02Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current orientation angle of the map control in degrees.","syntaxes":[{"syntax":"ctrlMapDir ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _mapControl = findDisplay 12 displayCtrl 51; // get the map\nprivate _dir = ctrlMapDir _mapControl; // returns 0 as the main map does not autorotate\n```","code":["private _mapControl = findDisplay 12 displayCtrl 51; // get the map\nprivate _dir = ctrlMapDir _mapControl; // returns 0 as the main map does not autorotate"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapScale"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"ctrlMapMouseOver","operator":null,"title":"ctrlMapMouseOver","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapMouseOver","revid":369404,"updated":"2024-09-03T18:43:23Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns description of map sign mouse cursor is over. Works with in-game map as well as 2D editor map in edit mode.","syntaxes":[{"syntax":"ctrlMapMouseOver control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"control: Control - map control"}],"returns":{"type":"Array","types":["Array"],"description":"possible values: - [\"unit\", Object] - [\"vehicle\", Object] - [\"vehicleGroup\", Object] - [\"object\", Object] - [\"waypoint\", Waypoint] - [\"trigger\", Object] - [\"marker\", String] - [\"task\", Task] - [\"customMark\"]","text":"Array - possible values:\n- [\"unit\", Object]\n- [\"vehicle\", Object]\n- [\"vehicleGroup\", Object]\n- [\"object\", Object]\n- [\"waypoint\", Waypoint]\n- [\"trigger\", Object]\n- [\"marker\", String]\n- [\"task\", Task]\n- [\"customMark\"]"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_overFriendly\"];\n\n_mouseover = if (count (ctrlMapMouseOver (uiNamespace getVariable \"_map\")) > 0) then\n{\n    ctrlMapMouseOver (uiNamespace getVariable \"_map\")\n}\nelse\n{\n    [\"\"]\n};\n\nif (_mouseover select 0 == \"task\" && str(_logic getVariable \"onTaskAssigned\") != str{}) then\n{\n    //--- Task\n    (uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_overMission\"];\n}\nelse\n{\n    //--- Waypoint\n    (uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_move\"];\n};\n```","code":["(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_overFriendly\"];\n\n_mouseover = if (count (ctrlMapMouseOver (uiNamespace getVariable \"_map\")) > 0) then\n{\n\tctrlMapMouseOver (uiNamespace getVariable \"_map\")\n}\nelse\n{\n\t[\"\"]\n};\n\nif (_mouseover select 0 == \"task\" && str(_logic getVariable \"onTaskAssigned\") != str{}) then\n{\n\t//--- Task\n\t(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_overMission\"];\n}\nelse\n{\n\t//--- Waypoint\n\t(uiNamespace getVariable \"_map\") ctrlMapCursor [\"Track\",\"HC_move\"];\n};"]},{"text":"```sqf\nonEachFrame {hintSilent str ctrlMapMouseOver (findDisplay 12 displayCtrl 51)};\n```","code":["onEachFrame {hintSilent str ctrlMapMouseOver (findDisplay 12 displayCtrl 51)};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findDisplay","displayCtrl","BIS_fnc_createTooltip"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapPosition","operator":null,"title":"ctrlMapPosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapPosition","revid":377802,"updated":"2026-01-03T04:03:42Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for ctrlMapSetPosition. Returns map position in format [x, y, w, h]. If map is inside a Controls Group, the x and y position is relative to the Controls Group top left corner.","syntaxes":[{"syntax":"ctrlMapPosition map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"Map control","types":["Control"],"since":null,"text":"map: Control - Map control"}],"returns":{"type":"Array with [x, y, w, h]","types":["Array"],"description":"x: Number - position in x - y: Number - position in y - w: Number - width of the map control - h: Number - height of the map control","text":"Array with [x, y, w, h]\n- x: Number - position in x\n- y: Number - position in y\n- w: Number - width of the map control\n- h: Number - height of the map control"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlMapPosition _map;\n```","code":["ctrlMapPosition _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapSetPosition","ctrlCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"ctrlMapScale","operator":null,"title":"ctrlMapScale","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapScale","revid":378435,"updated":"2026-04-07T21:06:22Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current scale of given map control.","syntaxes":[{"syntax":"ctrlMapScale ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\n_control = (findDisplay 12) displayCtrl 51; // Arma 3\n_scale = ctrlMapScale _control; // returns number from 1 to 0.001\n```","code":["_control = (findDisplay 12) displayCtrl 51; // Arma 3\n_scale = ctrlMapScale _control; // returns number from 1 to 0.001"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlScale","ctrlSetScale","ctrlMapDir"],"notes":[{"user":"Veteran29","date":"2024-10-07T00:35:13Z","text":"Following formula can be used to calculate current \"zoom points\", these can be used to hide/show icons at the same thresholds as the native map icons:\n\n```sqf\n800 * (1 / ctrlMapScale _ctrlMap) * (1 / getTerrainInfo#1)\n```\n\nThe thresholds are defined in\nptsPerSquare* ctrl map properties, e.g:\n\n```sqf\ngetNumber (configFile >> \"ctrlMap\" >> \"ptsPerSquareObj\")\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapScreenToWorld","operator":null,"title":"ctrlMapScreenToWorld","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapScreenToWorld","revid":377831,"updated":"2026-01-03T04:31:43Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts map screen coordinates into world coordinates. Unlike posScreenToWorld, this command returns world position is format [x, y], otherwise it is identical to posScreenToWorld.","syntaxes":[{"syntax":"control ctrlMapScreenToWorld [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"control: Control - map control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"screen X","types":["Number"],"since":null,"text":"x: Number - screen X"},{"name":"y","type":"Number","optional":false,"default":null,"description":"screen Y","types":["Number"],"since":null,"text":"y: Number - screen Y"}],"returns":{"type":"Position2D","types":["Position2D"],"description":"world coordinates","text":"Position2D - world coordinates"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\n_worldCoord = _control ctrlMapScreenToWorld _ScreenCoord;\n```","code":["_worldCoord = _control ctrlMapScreenToWorld _ScreenCoord;"]},{"text":"```sqf\n_worldCoord = _control ctrlMapScreenToWorld [_x, _y];\n```","code":["_worldCoord = _control ctrlMapScreenToWorld [_x, _y];"]},{"text":"```sqf\n_worldCoord = findDisplay 12 displayCtrl 51 ctrlMapScreenToWorld [0.5, 0.5];\n```","code":["_worldCoord = findDisplay 12 displayCtrl 51 ctrlMapScreenToWorld [0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapWorldToScreen","posScreenToWorld","posWorldToScreen","findDisplay","displayCtrl"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlMapSetPosition","operator":null,"title":"ctrlMapSetPosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapSetPosition","revid":352027,"updated":"2024-02-01T23:24:23Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets position and size of the given map control and recalculates control center. The effect is immediate and no ctrlCommit is necessary, unlike with ctrlSetPosition command.\n\n> [!NOTE]\n> The Map control is different from other controls and normally does not behave well inside Controls Groups. When this command is used on the Map control inside a Controls Group, The *x* and *y* will be treated as relative position to the top left of Controls Group. Use this command to set position before you use ctrlMapAnimAdd. Use this command to update Map control after its position or size had been changed or the Map control was created dynamically (Example 2). If you move Controls Group, use this command to refresh Map control (Example 3).","syntaxes":[{"syntax":"map ctrlMapSetPosition [x, y, w, h]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"Map control","types":["Control"],"since":null,"text":"map: Control - Map control"},{"name":"x","type":"Number","optional":true,"default":null,"description":"Left top x of map control","types":["Number"],"since":null,"text":"x: Number - (Optional) Left top x of map control"},{"name":"y","type":"Number","optional":true,"default":null,"description":"Left top y of map control","types":["Number"],"since":null,"text":"y: Number - (Optional) Left top y of map control"},{"name":"w","type":"Number","optional":true,"default":null,"description":"Width of map control","types":["Number"],"since":null,"text":"w: Number - (Optional) Width of map control"},{"name":"h","type":"Number","optional":true,"default":null,"description":"Height of map control","types":["Number"],"since":null,"text":"h: Number - (Optional) Height of map control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[x, y, w, h]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map ctrlMapSetPosition [0,0,1,1];\n```","code":["_map ctrlMapSetPosition [0,0,1,1];"]},{"text":"```sqf\n_map ctrlSetPosition [0.5, 0.5, 0.5, 0.5];\n_map ctrlCommit 0;\n_map ctrlMapSetPosition []; // sync\n```","code":["_map ctrlSetPosition [0.5, 0.5, 0.5, 0.5];\n_map ctrlCommit 0;\n_map ctrlMapSetPosition []; // sync"]},{"text":"```sqf\nwith localNamespace do\n{\n    private _display = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n    private _ctrlGroup = _display ctrlCreate [\"RscControlsGroup\", -1];\n    private _ctrlText = _display ctrlCreate [\"RscText\", -1, _ctrlGroup];\n    _ctrltext ctrlSetPosition [0, 0, 1, 1];\n    _ctrlText ctrlSetBackgroundColor [1, 0, 0, 0.5];\n    _ctrlText ctrlCommit 0;\n    private _ctrlMap = _display ctrlCreate [\"RscMapControl\", -1, _ctrlGroup];\n    _ctrlMap ctrlMapSetPosition [0, 0, 0.5, 0.5]; // effect is immediate\n    _ctrlMap ctrlMapAnimAdd [0, ctrlMapScale _ctrlMap, player];\n    ctrlMapAnimCommit _ctrlMap;\n    _ctrlGroup ctrlSetPosition [safeZoneX, safeZoneY, 1, 1];\n    _ctrlGroup ctrlCommit 0.3; // non instant transition\n    _ctrlMap ctrlMapSetPosition []; // instant sync to new _ctrlGroup position\n};\n```","code":["with localNamespace do\n{\n\tprivate _display = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n\tprivate _ctrlGroup = _display ctrlCreate [\"RscControlsGroup\", -1];\n\tprivate _ctrlText = _display ctrlCreate [\"RscText\", -1, _ctrlGroup];\n\t_ctrltext ctrlSetPosition [0, 0, 1, 1];\n\t_ctrlText ctrlSetBackgroundColor [1, 0, 0, 0.5];\n\t_ctrlText ctrlCommit 0;\n\tprivate _ctrlMap = _display ctrlCreate [\"RscMapControl\", -1, _ctrlGroup];\n\t_ctrlMap ctrlMapSetPosition [0, 0, 0.5, 0.5]; // effect is immediate\n\t_ctrlMap ctrlMapAnimAdd [0, ctrlMapScale _ctrlMap, player];\n\tctrlMapAnimCommit _ctrlMap;\n\t_ctrlGroup ctrlSetPosition [safeZoneX, safeZoneY, 1, 1];\n\t_ctrlGroup ctrlCommit 0.3; // non instant transition\n\t_ctrlMap ctrlMapSetPosition []; // instant sync to new _ctrlGroup position\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapPosition","ctrlSetPosition","ctrlMapAnimAdd","ctrlCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"ctrlMapWorldToScreen","operator":null,"title":"ctrlMapWorldToScreen","type":"command","url":"https://community.bistudio.com/wiki/ctrlMapWorldToScreen","revid":378320,"updated":"2026-04-02T16:18:50Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts world coordinates into map screen coordinates. This command is identical to posWorldToScreen.","syntaxes":[{"syntax":"control ctrlMapWorldToScreen position","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"control : Control - map control"},{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"world position","types":["Position2D","Position3D"],"since":null,"text":"position : Position2D or Position3D - world position"}],"returns":{"type":"Position2D","types":["Position2D"],"description":"screen coordinates in format [x, y]","text":"Position2D - screen coordinates in format [x, y]"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"position","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_screenCoord = _control ctrlMapWorldToScreen _worldCoord;\n```","code":["_screenCoord = _control ctrlMapWorldToScreen _worldCoord;"]},{"text":"```sqf\n_screenCoord = _control ctrlMapWorldToScreen position player;\n```","code":["_screenCoord = _control ctrlMapWorldToScreen position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapScreenToWorld","posWorldToScreen"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlModel","operator":null,"title":"ctrlModel","type":"command","url":"https://community.bistudio.com/wiki/ctrlModel","revid":310856,"updated":"2022-05-07T20:24:08Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns model used in 3D-Dialog.","syntaxes":[{"syntax":"ctrlModel control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"}],"returns":{"type":"String","types":["String"],"description":"model path","text":"String - model path"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_model = ctrlModel _control3D;\n```","code":["_model = ctrlModel _control3D;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","ctrlDelete","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlModelDirAndUp","operator":null,"title":"ctrlModelDirAndUp","type":"command","url":"https://community.bistudio.com/wiki/ctrlModelDirAndUp","revid":365012,"updated":"2024-07-10T09:58:01Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns vectorDir and vectorUp of the model used in 3D-Dialogs. Returns [[],[]] if control is null.","syntaxes":[{"syntax":"ctrlModelDirAndUp control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"}],"returns":{"type":"Array of Vector3Ds format [vectorDir, vectorUp] or [[],[]]","types":["Array","Vector3D","vectorDir","vectorUp"],"description":null,"text":"Array of Vector3Ds format [vectorDir, vectorUp] or [[],[]]"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_vectorDirAndUp = ctrlModelDirAndUp _control3D;\n```","code":["_vectorDirAndUp = ctrlModelDirAndUp _control3D;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlModelVectorSide","ctrlCreate","ctrlDelete","ctrlSetModelDirAndUp","ctrlModel","ctrlSetModel","ctrlSetModelScale","ctrlModelScale","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlModelScale","operator":null,"title":"ctrlModelScale","type":"command","url":"https://community.bistudio.com/wiki/ctrlModelScale","revid":310836,"updated":"2022-05-07T20:23:59Z","groups":["GUI Control - Object","GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns 3D control model scale.","syntaxes":[{"syntax":"ctrlModelScale control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_currentScale = ctrlModelScale _ctrl3D;\n```","code":["_currentScale = ctrlModelScale _ctrl3D;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlModelDirAndUp","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlSetModelDirAndUp","ctrlSetModelScale","ctrlPosition","ctrlScale","ctrlSetScale","ctrlSetPosition","ctrlClassName","vectorDir","vectorUp","setVectorDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlModelVectorSide","operator":null,"title":"ctrlModelVectorSide","type":"command","url":"https://community.bistudio.com/wiki/ctrlModelVectorSide","revid":377877,"updated":"2026-01-04T13:26:46Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the provided control model's vectorSide in 3D-Dialogs.","syntaxes":[{"syntax":"ctrlModelVectorSide control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"vectorSide of the model or empty array if control is null","text":"Vector3D - vectorSide of the model or empty array if *control* is null"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _vectorSide = ctrlModelVectorSide _control3D;\n```","code":["private _vectorSide = ctrlModelVectorSide _control3D;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlModelDirAndUp","ctrlCreate","ctrlDelete","ctrlSetModelDirAndUp","ctrlModel","ctrlSetModel","ctrlSetModelScale","ctrlModelScale","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"ctrlMousePosition","operator":null,"title":"ctrlMousePosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlMousePosition","revid":378524,"updated":"2026-05-04T01:55:42Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns position of the mouse on the screen relative to UI Control in UI coordinates. Also works within CT_CONTROLS_GROUPs. In that case, returned position is relative to the position of the group.","syntaxes":[{"syntax":"ctrlMousePosition control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Position2D","types":["Position2D"],"description":"x and y UI coordinates of the mouse position","text":"Position2D - x and y UI coordinates of the mouse position"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _mouseRelPos = ctrlMousePosition _ctrl;\n```","code":["private _mouseRelPos = ctrlMousePosition _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetMousePosition","setMousePosition","getMousePosition","ctrlMapCursor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"ctrlParent","operator":null,"title":"ctrlParent","type":"command","url":"https://community.bistudio.com/wiki/ctrlParent","revid":310860,"updated":"2022-05-07T20:24:09Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the parent Display of the given control. For parent Controls group see ctrlParentControlsGroup.","syntaxes":[{"syntax":"ctrlParent control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_display = ctrlParent _control;\n```","code":["_display = ctrlParent _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent","ctrlParentControlsGroup"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlParentControlsGroup","operator":null,"title":"ctrlParentControlsGroup","type":"command","url":"https://community.bistudio.com/wiki/ctrlParentControlsGroup","revid":369358,"updated":"2024-09-03T18:43:05Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the parent control of a given child control. If the control is not part of a CT_CONTROLS_GROUP control then controlNull is returned. To return parent Display of the control use ctrlParent.","syntaxes":[{"syntax":"ctrlParentControlsGroup ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":"child control","types":["Control"],"since":null,"text":"ctrl: Control - child control"}],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\n_ctrlCombo = _ctrl controlsGroupCtrl 100; // control\nctrlParentControlsGroup _ctrlCombo; // parent control group (_ctrl)\n```","code":["_ctrlCombo = _ctrl controlsGroupCtrl 100; // control\nctrlParentControlsGroup _ctrlCombo; // parent control group (_ctrl)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlsGroupCtrl","ctrlParent","displayParent","allControls","allDisplays"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"ctrlPosition","operator":null,"title":"ctrlPosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlPosition","revid":377302,"updated":"2026-01-02T06:38:20Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current position of 2D control as `[x, y, w, h]` array. For 3D control it returns relative `[x, z, y]`.\n\nIf the control is within a CT_CONTROLS_GROUP, the returned position will be relative to the group's position.\n\nIf the control is a CT_CONTROLS_TABLE header or row the returned position is relative to the table's position.","syntaxes":[{"syntax":"ctrlPosition controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Array format `[x, y, w, h]` (2D) or `[x, z, y]` (3D)","types":["Array"],"description":null,"text":"Array format `[x, y, w, h]` (2D) or `[x, z, y]` (3D)"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_pos = ctrlPosition _control;\n```","code":["_pos = ctrlPosition _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlRemoveAllEventHandlers","operator":null,"title":"ctrlRemoveAllEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/ctrlRemoveAllEventHandlers","revid":363228,"updated":"2024-03-26T10:51:07Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove all event handlers from the given control.","syntaxes":[{"syntax":"control ctrlRemoveAllEventHandlers handlerName","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"handlerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"handlerName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"handlerName","types":["String"]}}],"examples":[{"text":"```sqf\n_ctrlButton ctrlRemoveAllEventHandlers \"ButtonDown\";\n```","code":["_ctrlButton ctrlRemoveAllEventHandlers \"ButtonDown\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAddEventHandler"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlRemoveEventHandler","operator":null,"title":"ctrlRemoveEventHandler","type":"command","url":"https://community.bistudio.com/wiki/ctrlRemoveEventHandler","revid":329861,"updated":"2022-08-07T23:04:48Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove a given event handler from the given control.","syntaxes":[{"syntax":"control ctrlRemoveEventHandler [type, id]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"},{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[type, id]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map ctrlRemoveEventHandler [\"Draw\", _id];\n```","code":["_map ctrlRemoveEventHandler [\"Draw\", _id];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAddEventHandler","ctrlRemoveAllEventHandlers"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlScale","operator":null,"title":"ctrlScale","type":"command","url":"https://community.bistudio.com/wiki/ctrlScale","revid":310878,"updated":"2022-05-07T20:24:10Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current scale of the control.","syntaxes":[{"syntax":"ctrlScale control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_scale = ctrlScale _control;\n```","code":["_scale = ctrlScale _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetScale","ctrlModelScale","ctrlSetModelScale"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlScrollValues","operator":null,"title":"ctrlScrollValues","type":"command","url":"https://community.bistudio.com/wiki/ctrlScrollValues","revid":377723,"updated":"2026-01-02T09:27:52Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns scroll values for current scrollbars in range 0...1 (-1 if not applicable) for the following controls:\n- CT_CONTROLS_TABLE\n- CT_CONTROLS_GROUP\n- CT_TREE\n- CT_LISTBOX\n- CT_COMBO\n- CT_XCOMBO\n- CT_LISTNBOX\n- CT_LISTNBOX_CHECKABLE","syntaxes":[{"syntax":"ctrlScrollValues control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array with [vertical, horizontal]","types":["Array"],"description":"vertical: Number in range 0..1 - horizontal: Number in range 0..1","text":"Array with [vertical, horizontal]\n- vertical: Number in range 0..1\n- horizontal: Number in range 0..1"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _scrollvalues = ctrlScrollValues _ctrl;\n```","code":["private _scrollvalues = ctrlScrollValues _ctrl;"]},{"text":"```sqf\n// ControlsGroup\nprivate _disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGrp = _disp ctrlCreate [\"RscControlsGroup\", -1];\nprivate _ctrl = _disp ctrlCreate [\"RscTree\", -1, _ctrlGrp];\n_ctrl tvAdd [[], \"Root\"];\nfor \"_i\" from 1 to 25 do\n{\n    _ctrl tvAdd [[0], format [\"Tree Item %1\", _i]];\n};\n_ctrl ctrlSetPosition [0,0,0.3,1.2];\n_ctrl ctrlCommit 0;\ntvExpandAll _ctrl;\n_ctrlGrp ctrlSetPosition [0,0,0.2,0.3];\n_ctrlGrp ctrlCommit 0;\n \nuiNamespace setVariable [\"_ctrl\", _ctrlGrp];\nonEachFrame\n{\n    hintSilent str ctrlScrollValues (uiNamespace getVariable [\"_ctrl\", controlNull]);\n};\n0 spawn\n{\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.3, -1];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.3];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.7, -1];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.7];\n};\n```","code":["// ControlsGroup\nprivate _disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGrp = _disp ctrlCreate [\"RscControlsGroup\", -1];\nprivate _ctrl = _disp ctrlCreate [\"RscTree\", -1, _ctrlGrp];\n_ctrl tvAdd [[], \"Root\"];\nfor \"_i\" from 1 to 25 do\n{\n\t_ctrl tvAdd [[0], format [\"Tree Item %1\", _i]];\n};\n_ctrl ctrlSetPosition [0,0,0.3,1.2];\n_ctrl ctrlCommit 0;\ntvExpandAll _ctrl;\n_ctrlGrp ctrlSetPosition [0,0,0.2,0.3];\n_ctrlGrp ctrlCommit 0;\n \nuiNamespace setVariable [\"_ctrl\", _ctrlGrp];\nonEachFrame\n{\n\thintSilent str ctrlScrollValues (uiNamespace getVariable [\"_ctrl\", controlNull]);\n};\n0 spawn\n{\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.3, -1];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.3];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.7, -1];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.7];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetScrollValues","sliderPosition","progressPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"ctrlSetActiveColor","operator":null,"title":"ctrlSetActiveColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetActiveColor","revid":377734,"updated":"2026-01-03T00:21:56Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets text color of given control when it is selected.","syntaxes":[{"syntax":"control ctrlSetActiveColor color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetActiveColor [1, 0, 0, 1];\n```","code":["_control ctrlSetActiveColor [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetAngle","operator":null,"title":"ctrlSetAngle","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetAngle","revid":376965,"updated":"2026-01-01T05:57:04Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the rotation of a control set as `ST_PICTURE`. Rotation will be done within the control boundaries, so if the X and Y are given off center, the picture may get clipped by the control boundaries.\nOnly requires ctrlCommit when fourth parameter is set to false. Procedural textures filled controls do not rotate. Supported control types:\n- CT_STATIC\n- Arma 3 v2.10 CT_ACTIVETEXT\n\n> [!IMPORTANT]\n> Images that touch borders may \"bleed\" during rotation transformation, to avoid this, make sure the image has a 1px transparent padding.","syntaxes":[{"syntax":"control ctrlSetAngle [angle, centerX, centerY, now]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"picture control","types":["Control"],"since":null,"text":"control: Control - picture control"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"rotation angle (clockwise)","types":["Number"],"since":null,"text":"angle: Number - rotation angle (clockwise)"},{"name":"centerX","type":"Number in range 0..1","optional":false,"default":null,"description":"rotation center X. Control center is 0.5","types":["Number"],"since":null,"text":"centerX: Number in range 0..1 - rotation center X. Control center is 0.5"},{"name":"centerY","type":"Number in range 0..1","optional":false,"default":null,"description":"rotation center Y. Control center is 0.5","types":["Number"],"since":null,"text":"centerY: Number in range 0..1 - rotation center Y. Control center is 0.5"},{"name":"now","type":"Boolean","optional":true,"default":"true","description":"if false, control will wait for ctrlCommit input for result to apply","types":["Boolean"],"since":"arma3 1.78","text":"now: Boolean - (Optional, default true) if false, control will wait for ctrlCommit input for result to apply"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[angle, centerX, centerY, now]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlSetAngle [25, 0.5, 0.5];\n```","code":["_control ctrlSetAngle [25, 0.5, 0.5];"]},{"text":"```sqf\nwith uiNamespace do\n{\n    ctrl = findDisplay 46 ctrlCreate [\"RscPictureKeepAspect\", -1];\n    ctrl ctrlSetPosition [0,0,1,1];\n    ctrl ctrlSetText \"A3\\Missions_F_Exp\\data\\Img\\lobby\\ui_campaign_lobby_background_tablet_radial_left_ca.paa\";\n    ctrl ctrlCommit 0;\n    angle = 0;\n    onEachFrame\n    {\n        with uiNamespace do\n        {\n            if (angle > 359) then { angle = 0 };\n            ctrl ctrlSetAngle [angle, 0.5, 0.5];\n            angle = angle + 1;\n        };\n    };\n};\n```","code":["with uiNamespace do\n{\n\tctrl = findDisplay 46 ctrlCreate [\"RscPictureKeepAspect\", -1];\n\tctrl ctrlSetPosition [0,0,1,1];\n\tctrl ctrlSetText \"A3\\Missions_F_Exp\\data\\Img\\lobby\\ui_campaign_lobby_background_tablet_radial_left_ca.paa\";\n\tctrl ctrlCommit 0;\n\tangle = 0;\n\tonEachFrame\n\t{\n\t\twith uiNamespace do\n\t\t{\n\t\t\tif (angle > 359) then { angle = 0 };\n\t\t\tctrl ctrlSetAngle [angle, 0.5, 0.5];\n\t\t\tangle = angle + 1;\n\t\t};\n\t};\n};"]},{"text":"```sqf\n_control ctrlSetAngle [25, 0.5, 0.5, false];\n_control ctrlCommit 1; // Rotation applies smoothly for 1 second.\n```","code":["_control ctrlSetAngle [25, 0.5, 0.5, false];\n_control ctrlCommit 1; // Rotation applies smoothly for 1 second."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAngle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlSetAutoScrollDelay","operator":null,"title":"ctrlSetAutoScrollDelay","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetAutoScrollDelay","revid":310075,"updated":"2022-05-05T12:25:08Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets number of second before auto-scroll starts/rewinds. Setter for ctrlAutoScrollDelay.\n\nAutorscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"control ctrlSetAutoScrollDelay delay","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"},{"name":"delay","type":"Number","optional":false,"default":null,"description":"seconds to wait before scroll and/or rewind","types":["Number"],"since":null,"text":"delay: Number - seconds to wait before scroll and/or rewind"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"delay","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrlGroup ctrlSetAutoScrollDelay 5;\n```","code":["_ctrlGroup ctrlSetAutoScrollDelay 5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAutoScrollSpeed","ctrlAutoScrollSpeed","ctrlAutoScrollDelay","ctrlSetAutoScrollRewind","ctrlAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetAutoScrollRewind","operator":null,"title":"ctrlSetAutoScrollRewind","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetAutoScrollRewind","revid":318987,"updated":"2022-05-13T09:22:08Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines if scroll should rewind when auto-scroll reach end. Setter for ctrlAutoScrollRewind.\n\nAutorscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"control ctrlSetAutoScrollRewind set","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"},{"name":"set","type":"Boolean","optional":false,"default":null,"description":"true to enable rewind","types":["Boolean"],"since":null,"text":"set: Boolean - true to enable rewind"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_ctrlGroup ctrlSetAutoScrollRewind true;\n```","code":["_ctrlGroup ctrlSetAutoScrollRewind true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetAutoScrollSpeed","ctrlAutoScrollSpeed","ctrlSetAutoScrollDelay","ctrlAutoScrollDelay","ctrlAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetAutoScrollSpeed","operator":null,"title":"ctrlSetAutoScrollSpeed","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetAutoScrollSpeed","revid":318963,"updated":"2022-05-13T09:22:07Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets number of second required to scroll to next line. If speed < 0, auto-scroll is disabled. Setter for ctrlAutoScrollSpeed.\n\nAutorscroll is available for CT_LISTBOX and CT_CONTROLS_GROUP types of controls only. Autoscroll will wait ctrlAutoScrollDelay seconds (must be  > 0) and then will scroll the scroll bar down to the bottom. ctrlAutoScrollSpeed defines the speed with which scrollbar is scrolled. If ctrlAutoScrollRewind is true, the control will fade out, immediately rewind to the top, then fade in, wait ctrlAutoScrollDelay seconds and then repeat the scrolling in a loop. If user focuses on the control, autoscrolling is interrupted.","syntaxes":[{"syntax":"control ctrlSetAutoScrollSpeed speed","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_LISTBOX or CT_CONTROLS_GROUP","types":["Control"],"since":null,"text":"control: Control - CT_LISTBOX or CT_CONTROLS_GROUP"},{"name":"speed","type":"Number","optional":false,"default":null,"description":"seconds to autoscroll to the next line","types":["Number"],"since":null,"text":"speed: Number - seconds to autoscroll to the next line"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"speed","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrlGroup ctrlSetAutoScrollSpeed 0.1;\n```","code":["_ctrlGroup ctrlSetAutoScrollSpeed 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlAutoScrollSpeed","ctrlSetAutoScrollDelay","ctrlAutoScrollDelay","ctrlSetAutoScrollRewind","ctrlAutoScrollRewind"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetBackgroundColor","operator":null,"title":"ctrlSetBackgroundColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetBackgroundColor","revid":377733,"updated":"2026-01-03T00:21:54Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets background color of given control. Only affects:\n- CT_COMBO\n- CT_STATIC\n- CT_STRUCTURED_TEXT\n- CT_MAP\n- CT_MAP_MAIN\n- Arma 3 v2.02 CT_BUTTON\n- Arma 3 v2.02 CT_SHORTCUTBUTTON\n- Arma 3 v2.02 CT_ACTIVETEXT","syntaxes":[{"syntax":"control ctrlSetBackgroundColor color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetBackgroundColor [1, 0, 0, 1];\n```","code":["_control ctrlSetBackgroundColor [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allControls","allDisplays","controlsGroupCtrl","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetChecked","operator":null,"title":"ctrlSetChecked","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetChecked","revid":330383,"updated":"2022-09-04T21:37:19Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets checked state of a CT_CHECKBOXES control.","syntaxes":[{"syntax":"control ctrlSetChecked checked","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_CHECKBOXES control. If control contain multiple checkboxes, only checkbox with index 0 is queried.","types":["Control"],"since":null,"text":"control: Control - CT_CHECKBOXES control. If control contain multiple checkboxes, only checkbox with index 0 is queried."},{"name":"checked","type":"Boolean","optional":false,"default":null,"description":"true to check, false to uncheck the checkbox","types":["Boolean"],"since":null,"text":"checked: Boolean - true to check, false to uncheck the checkbox"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"checked","types":["Boolean"]}},{"syntax":"control ctrlSetChecked [index, checked]","since":"arma3 1.72","effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_CHECKBOXES control","types":["Control"],"since":null,"text":"control: Control - CT_CHECKBOXES control"},{"name":"index","type":"Number","optional":false,"default":null,"description":"checkbox index","types":["Number"],"since":null,"text":"index: Number - checkbox index"},{"name":"checked","type":"Boolean","optional":false,"default":null,"description":"true to check, false to uncheck the checkbox","types":["Boolean"],"since":null,"text":"checked: Boolean - true to check, false to uncheck the checkbox"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, checked]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlSetChecked true;\n```","code":["_control ctrlSetChecked true;"]},{"text":"```sqf\n_control ctrlSetChecked [3, true];\n```","code":["_control ctrlSetChecked [3, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlChecked","cbChecked","cbSetChecked"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlSetDisabledColor","operator":null,"title":"ctrlSetDisabledColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetDisabledColor","revid":347537,"updated":"2023-09-28T08:53:50Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the colorDisabled attribute of a control.","syntaxes":[{"syntax":"ctrlSetDisabledColor [idc, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, color]","types":["Array"]}},{"syntax":"ctrl ctrlSetDisabledColor color","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetDisabledColor [0.5, 0.5, 0.5, 0.5];\n```","code":["_control ctrlSetDisabledColor [0.5, 0.5, 0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetActiveColor","ctrlSetBackgroundColor","ctrlTextColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"ctrlSetEventHandler","operator":null,"title":"ctrlSetEventHandler","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetEventHandler","revid":369343,"updated":"2024-09-03T18:43:02Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"deprecated","replaced_by":["ctrlAddEventHandler"],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!CAUTION]\n> This information is **obsolete**. Use ctrlAddEventHandler instead as it can stack event handlers.\n\nSets given event handler of given control: any previously added event handler is removed.\n\n> [!NOTE]\n> - See User Interface Event Handlers for the full list of handler names\n> - See also DIK KeyCodes for a list of key code constants relevant to key-related events like KeyDown and KeyUp\n\n> [!IMPORTANT]\n> When using the event names listed here with the ctrlAddEventHandler, ctrlSetEventHandler, displayAddEventHandler or displaySetEventHandler commands, the prefix \"on\" in the event name must be removed (e.g. **'ButtonDown**' instead of **'onButtonDown**').","syntaxes":[{"syntax":"controlName ctrlSetEventHandler [handlerName, function]","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"handlerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"handlerName: String"},{"name":"function","type":"String","optional":false,"default":null,"description":"should return a Boolean indicating that the event has handled this event fully or not and whether the engine should execute its default code or not afterwards","types":["String"],"since":null,"text":"function: String - should return a Boolean indicating that the event has handled this event fully or not and whether the engine should execute its default code or not afterwards"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"[handlerName, function]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlSetEventHandler [\"KeyDown\", \"\"];\n```","code":["_control ctrlSetEventHandler [\"KeyDown\", \"\"];"]},{"text":"```sqf\n(_display displayCtrl 108) ctrlSetEventHandler [\"LBSelChanged\",\"['ListChange',_this] call FireEvents\"];\n```","code":["(_display displayCtrl 108) ctrlSetEventHandler [\"LBSelChanged\",\"['ListChange',_this] call FireEvents\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displaySetEventHandler","ctrlAddEventHandler","ctrlRemoveEventHandler","User Interface Event Handlers","DIK KeyCodes"],"notes":[{"user":"pierremgi","date":"2021-04-28T19:59:00Z","text":"This command doesn't work on map.\n\n```sqf\nwaitUntil { !isNull (findDisplay 12 displayCtrl 51) };\n(findDisplay 12 displayCtrl 51) ctrlSetEventHandler [\"MouseButtonDblClick\", \"hint str _this; true\"]; // doesn't skip the marker dialog as it should.\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFade","operator":null,"title":"ctrlSetFade","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFade","revid":369232,"updated":"2024-09-03T10:35:00Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets wanted transparency for control animation. Requires ctrlCommit to commit changes. To hide or show a control instantly, use ctrlShow.\n\n> [!NOTE]\n> If there are multiple (interactable) controls on top of each other but the top-most control is faded using `ctrlSetFade 1`,\n> this control will interfere with other controls that were defined earlier and in the exact same position.\n> To counter that, the faded control **must** be disabled with ctrlEnable.","syntaxes":[{"syntax":"controlName ctrlSetFade fade","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fade","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"fade: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fade","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFade 1;\n_control ctrlCommit 5;\n```","code":["_control ctrlSetFade 1;\n_control ctrlCommit 5;"]}],"multiplayer":null,"problems":"Despite having `fade = 1;` in a control's config, ctrlFade will still report a fade of 0 - resulting in `ctrlSetFade 0` doing nothing.\n\nTo counter that, first use `ctrlSetFade 1`, then `ctrlCommit 0` to apply it, and only then ctrlSetFade can be used as usual.","aliases":[],"see_also":["ctrlFade","cutFadeOut","ctrlCommit"],"notes":[{"user":"Nelis75733126","date":"2024-04-16T21:10:07Z","text":"in Arma 3 2.17, when `ctrlSetFade` is used on a CtrlToolbox or RscToolbox, it only has effect on the text of it."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFocus","operator":null,"title":"ctrlSetFocus","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFocus","revid":373983,"updated":"2025-07-13T08:12:31Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the input focus on given control.\n\n> [!IMPORTANT]\n> - ctrlSetFocus seems to only work on controls that accept any input from keyboard or mouse.\n> - if ctrlSetFocus is used on a CT_CONTROLS_GROUP that contains an interactable control, that control will automatically be active.\n> - if ctrlSetFocus is used on a CT_CONTROLS_GROUP in which there are no interactable controls, then ctrlSetFocus will do nothing.","syntaxes":[{"syntax":"ctrlSetFocus control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlSetFocus _control;\n```","code":["ctrlSetFocus _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["focusedCtrl"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFont","operator":null,"title":"ctrlSetFont","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFont","revid":323058,"updated":"2022-06-28T21:43:11Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the font for given control (see available fonts)","syntaxes":[{"syntax":"control ctrlSetFont fontName","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":"one of the fonts defined in CfgFontFamilies","types":["String"],"since":null,"text":"fontName: String - one of the fonts defined in CfgFontFamilies"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFont \"TahomaB\";\n```","code":["_control ctrlSetFont \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Fonts"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH1","operator":null,"title":"ctrlSetFontH1","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH1","revid":323052,"updated":"2022-06-28T21:43:10Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H1 font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH1 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH1 \"TahomaB\";\n```","code":["_control ctrlSetFontH1 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Fonts"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH1B","operator":null,"title":"ctrlSetFontH1B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH1B","revid":318797,"updated":"2022-05-13T09:21:51Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H1 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH1B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH1B \"TahomaB\";\n```","code":["_control ctrlSetFontH1B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH2","operator":null,"title":"ctrlSetFontH2","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH2","revid":323053,"updated":"2022-06-28T21:43:10Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H2 font of given HTML control","syntaxes":[{"syntax":"controlName ctrlSetFontH2 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH2 \"TahomaB\";\n```","code":["_control ctrlSetFontH2 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH2B","operator":null,"title":"ctrlSetFontH2B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH2B","revid":323059,"updated":"2022-06-28T21:43:11Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H2 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH2B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH2B \"TahomaB\";\n```","code":["_control ctrlSetFontH2B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH3","operator":null,"title":"ctrlSetFontH3","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH3","revid":323048,"updated":"2022-06-28T21:43:10Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H3 font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH3 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH3 \"TahomaB\";\n```","code":["_control ctrlSetFontH3 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFocus","ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH3B","operator":null,"title":"ctrlSetFontH3B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH3B","revid":323049,"updated":"2022-06-28T21:43:10Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H3 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH3B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH3B \"TahomaB\";\n```","code":["_control ctrlSetFontH3B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH4","operator":null,"title":"ctrlSetFontH4","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH4","revid":322929,"updated":"2022-06-28T21:42:41Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H4 font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH4 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH4 \"TahomaB\";\n```","code":["_control ctrlSetFontH4 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH4B","operator":null,"title":"ctrlSetFontH4B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH4B","revid":323039,"updated":"2022-06-28T21:43:09Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H4 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH4B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH4B \"TahomaB\";\n```","code":["_control ctrlSetFontH4B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH5","operator":null,"title":"ctrlSetFontH5","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH5","revid":322973,"updated":"2022-06-28T21:42:53Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H5 font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH5 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH5 \"TahomaB\";\n```","code":["_control ctrlSetFontH5 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5B","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH5B","operator":null,"title":"ctrlSetFontH5B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH5B","revid":322936,"updated":"2022-06-28T21:42:44Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H5 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH5B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH5B \"TahomaB\";\n```","code":["_control ctrlSetFontH5B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH6","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH6","operator":null,"title":"ctrlSetFontH6","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH6","revid":322949,"updated":"2022-06-28T21:42:48Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H6 font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH6 fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH6 \"TahomaB\";\n```","code":["_control ctrlSetFontH6 \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6B"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontH6B","operator":null,"title":"ctrlSetFontH6B","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontH6B","revid":323027,"updated":"2022-06-28T21:43:08Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H6 bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontH6B fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontH6B \"TahomaB\";\n```","code":["_control ctrlSetFontH6B \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1B","ctrlSetFontH2","ctrlSetFontH2B","ctrlSetFontH3","ctrlSetFontH3B","ctrlSetFontH4","ctrlSetFontH4B","ctrlSetFontH5","ctrlSetFontH5B","ctrlSetFontH6"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeight","operator":null,"title":"ctrlSetFontHeight","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeight","revid":336297,"updated":"2022-12-21T11:10:07Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the `sizeEx` property for most controls as follows:\n- `CT_MAP` - \"sizeExNames\"\n- `CT_HTML` - \"P\" >> \"sizeEx\"\n- Other - \"sizeEx\"\n- Arma 3 v2.02 `CT_STRUCTURED_TEXT` - \"size\"","syntaxes":[{"syntax":"control ctrlSetFontHeight size","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"size","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"size: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"size","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeight 0.05;\n```","code":["_control ctrlSetFontHeight 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlFontHeight","Arma: GUI Configuration"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH1","operator":null,"title":"ctrlSetFontHeightH1","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH1","revid":323080,"updated":"2022-06-28T21:43:13Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H1 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH1 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH1 0.05;\n```","code":["_control ctrlSetFontHeightH1 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH1"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH2","operator":null,"title":"ctrlSetFontHeightH2","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH2","revid":322946,"updated":"2022-06-28T21:42:46Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H2 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH2 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH2 0.05;\n```","code":["_control ctrlSetFontHeightH2 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH2"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH3","operator":null,"title":"ctrlSetFontHeightH3","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH3","revid":322957,"updated":"2022-06-28T21:42:50Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H3 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH3 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH3 0.05;\n```","code":["_control ctrlSetFontHeightH3 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH3"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH4","operator":null,"title":"ctrlSetFontHeightH4","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH4","revid":323040,"updated":"2022-06-28T21:43:09Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H4 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH4 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH4 0.05;\n```","code":["_control ctrlSetFontHeightH4 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH4"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH5","operator":null,"title":"ctrlSetFontHeightH5","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH5","revid":323046,"updated":"2022-06-28T21:43:09Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H5 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH5 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH5 0.05;\n```","code":["_control ctrlSetFontHeightH5 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH5"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightH6","operator":null,"title":"ctrlSetFontHeightH6","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightH6","revid":323026,"updated":"2022-06-28T21:43:08Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets H6 font size of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontHeightH6 height","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontHeightH6 0.05;\n```","code":["_control ctrlSetFontHeightH6 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontH6"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontHeightSecondary","operator":null,"title":"ctrlSetFontHeightSecondary","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontHeightSecondary","revid":297936,"updated":"2022-01-20T13:02:47Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the font size of the secondary text of given control.","syntaxes":[{"syntax":"ctrl ctrlSetFontHeightSecondary value","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"_control ctrlSetFontHeightSecondary 0.05;","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontP","ctrlSetFontSecondary"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlSetFontP","operator":null,"title":"ctrlSetFontP","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontP","revid":318848,"updated":"2022-05-13T09:21:55Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets P font of given HTML control or its size.","syntaxes":[{"syntax":"control ctrlSetFontP fontOrSize","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"fontOrSize","type":"String or Number","optional":false,"default":null,"description":null,"types":["String","Number"],"since":null,"text":"fontOrSize: String or Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"fontOrSize","types":["String","Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontP \"TahomaB\";\n```","code":["_control ctrlSetFontP \"TahomaB\";"]},{"text":"```sqf\n_control ctrlSetFontP 0.05;\n```","code":["_control ctrlSetFontP 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontHeightSecondary","ctrlSetFontSecondary"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontPB","operator":null,"title":"ctrlSetFontPB","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontPB","revid":323083,"updated":"2022-06-28T21:43:13Z","groups":["GUI Control - HTML"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets P bold font of given HTML control.","syntaxes":[{"syntax":"controlName ctrlSetFontPB fontName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"},{"name":"fontName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fontName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"fontName","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetFontPB \"TahomaB\";\n```","code":["_control ctrlSetFontPB \"TahomaB\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontP"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - HTML","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetFontSecondary","operator":null,"title":"ctrlSetFontSecondary","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetFontSecondary","revid":348687,"updated":"2023-11-08T14:29:23Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the font size of the secondary text of given control.","syntaxes":[{"syntax":"ctrl ctrlSetFontSecondary fontClass","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"fontClass","type":"String","optional":false,"default":null,"description":"font class","types":["String"],"since":null,"text":"fontClass: String - font class"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"fontClass","types":["String"]}}],"examples":[{"text":"_control ctrlSetFontSecondary \"TahomaB\";","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFontP","ctrlSetFontHeightSecondary"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlSetForegroundColor","operator":null,"title":"ctrlSetForegroundColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetForegroundColor","revid":377732,"updated":"2026-01-03T00:21:53Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets foreground color of the given control.\n\n> [!NOTE]\n> Also try ctrlSetTextColor, if this command doesn't have the desired effect.","syntaxes":[{"syntax":"control ctrlSetForegroundColor color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetForegroundColor [1, 0, 0, 1];\n```","code":["_control ctrlSetForegroundColor [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTextColor","ctrlSetBackgroundColor"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetModel","operator":null,"title":"ctrlSetModel","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetModel","revid":336418,"updated":"2023-01-03T08:09:24Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets model for 3D-Dialogs (see Arma 3: createSimpleObject/objects for a p3d models' list).","syntaxes":[{"syntax":"control ctrlSetModel model","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"},{"name":"model","type":"String","optional":false,"default":null,"description":"model path","types":["String"],"since":null,"text":"model : String - model path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"model","types":["String"]}}],"examples":[{"text":"```sqf\n_control3D ctrlSetModel \"\\a3\\Ui_f\\objects\\Compass.p3d\";\n```","code":["_control3D ctrlSetModel \"\\a3\\Ui_f\\objects\\Compass.p3d\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","ctrlDelete","ctrlModel","ctrlPosition","ctrlSetPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlSetModelDirAndUp","operator":null,"title":"ctrlSetModelDirAndUp","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetModelDirAndUp","revid":378364,"updated":"2026-04-03T16:42:03Z","groups":["GUI Control - Object"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets orientation of 3D control model. It is similar to setVectorDirAndUp command for an object.","syntaxes":[{"syntax":"control ctrlSetModelDirAndUp dirAndUp","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"},{"name":"dirAndUp","type":"Array with [vectorDir, vectorUp]","optional":false,"default":null,"description":"Array with [vectorDir, vectorUp]\n- vectorDir: Vector3D - see vectorDir\n- vectorUp: Vector3D - see vectorUp","types":["Array"],"since":null,"text":"dirAndUp: Array with [vectorDir, vectorUp]\n- vectorDir: Vector3D - see vectorDir\n- vectorUp: Vector3D - see vectorUp"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"dirAndUp","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl3D ctrlSetModelDirAndUp [[0,1,0],[0,0,1]]; //default orientation\n```","code":["_ctrl3D ctrlSetModelDirAndUp [[0,1,0],[0,0,1]]; //default orientation"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlModelDirAndUp","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlModelScale","ctrlSetModelScale","ctrlPosition","ctrlSetPosition","ctrlClassName","vectorDir","vectorUp","setVectorDirAndUp","ctrlModelVectorSide"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlSetModelScale","operator":null,"title":"ctrlSetModelScale","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetModelScale","revid":318942,"updated":"2022-05-13T09:22:05Z","groups":["GUI Control - Object","GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets 3D control model scale","syntaxes":[{"syntax":"control ctrlSetModelScale scale","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"control : Control - 3D control"},{"name":"scale","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"scale : Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"scale","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl3D ctrlSetModelScale 1.5;\n```","code":["_ctrl3D ctrlSetModelScale 1.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlModelDirAndUp","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlSetModelDirAndUp","ctrlModelScale","ctrlPosition","ctrlScale","ctrlSetScale","ctrlSetPosition","ctrlClassName","vectorDir","vectorUp","setVectorDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Object","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"ctrlSetMousePosition","operator":null,"title":"ctrlSetMousePosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetMousePosition","revid":348960,"updated":"2023-11-08T14:45:40Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Similar to setMousePosition but relative to the given control.","syntaxes":[{"syntax":"control ctrlSetMousePosition [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"position in x","types":["Number"],"since":null,"text":"x: Number - position in x"},{"name":"y","type":"Number","optional":false,"default":null,"description":"position in y","types":["Number"],"since":null,"text":"y: Number - position in y"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlSetMousePosition [0.5, 0.5];\n```","code":["_control ctrlSetMousePosition [0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMousePosition","setMousePosition","getMousePosition","ctrlMapCursor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlSetPixelPrecision","operator":null,"title":"ctrlSetPixelPrecision","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPixelPrecision","revid":309215,"updated":"2022-05-03T22:40:41Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Switches mode of pixel precision (rounding) in a given control interface.","syntaxes":[{"syntax":"control ctrlSetPixelPrecision mode","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"mode","type":"Number or String","optional":false,"default":null,"description":"can be one of the following:\n- 0 / \"AUTO\" - control position (x, y, w, h) is always rounded to whole pixels (game default)\n- 1 / \"ON\" - control position (x, y, w, h) is rounded to whole pixels only when not animating\n- 2 / \"OFF\" - control position (x, y, w, h) is always precise, no pixel rounding applies here","types":["Number","String"],"since":null,"text":"mode: Number or String - can be one of the following:\n- 0 / \"AUTO\" - control position (x, y, w, h) is always rounded to whole pixels (game default)\n- 1 / \"ON\" - control position (x, y, w, h) is rounded to whole pixels only when not animating\n- 2 / \"OFF\" - control position (x, y, w, h) is always precise, no pixel rounding applies here"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"mode","types":["Number","String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetPixelPrecision 2; // Enables pixel precision of the given control\n```","code":["_control ctrlSetPixelPrecision 2; // Enables pixel precision of the given control"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCommit","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","ctrlSetPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"ctrlSetPosition","operator":null,"title":"ctrlSetPosition","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPosition","revid":373619,"updated":"2025-05-25T10:19:49Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets wanted position and size for 2D control animation. Width and height are optional. ctrlCommit is required to complete the operation.\nFor 3D control, param is relative `[x, z, y]` and no ctrlCommit is required as it cannot be animated. If target control is inside a CT_CONTROLS_GROUP, the position needs to be relative to it.\n\n> [!IMPORTANT]\n> This command doesn't work well with CT_MAP control. Use ctrlMapSetPosition instead.","syntaxes":[{"syntax":"controlName ctrlSetPosition [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"controlName: Control - 2D control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"position in x","types":["Number"],"since":null,"text":"x: Number - position in x"},{"name":"y","type":"Number","optional":false,"default":null,"description":"position in y","types":["Number"],"since":null,"text":"y: Number - position in y"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"[x, y]","types":["Array"]}},{"syntax":"controlName ctrlSetPosition [x, y, w, h]","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"controlName: Control - 2D control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"position in x","types":["Number"],"since":null,"text":"x: Number - position in x"},{"name":"y","type":"Number","optional":false,"default":null,"description":"position in y","types":["Number"],"since":null,"text":"y: Number - position in y"},{"name":"w","type":"Number","optional":false,"default":null,"description":"width of the control","types":["Number"],"since":null,"text":"w: Number - width of the control"},{"name":"h","type":"Number","optional":false,"default":null,"description":"height of the control","types":["Number"],"since":null,"text":"h: Number - height of the control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"[x, y, w, h]","types":["Array"]}},{"syntax":"controlName ctrlSetPosition [x, z, y]","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":"3D control","types":["Control"],"since":null,"text":"controlName: Control - 3D control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"screen x","types":["Number"],"since":null,"text":"x: Number - screen x"},{"name":"z","type":"Number","optional":false,"default":null,"description":"distance from the screen (depth). If object is too far, it cannot be dragged by the mouse.","types":["Number"],"since":null,"text":"z: Number - distance from the screen (depth). If object is too far, it cannot be dragged by the mouse."},{"name":"y","type":"Number","optional":false,"default":null,"description":"screen y","types":["Number"],"since":null,"text":"y: Number - screen y"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlName","types":["Control"]},"right":{"text":"[x, z, y]","types":["Array"]}}],"examples":[{"text":"Move control:\n\n```sqf\n_control2D ctrlSetPosition [0, 0];\n_control2D ctrlCommit 0;\n```","code":["_control2D ctrlSetPosition [0, 0];\n_control2D ctrlCommit 0;"]},{"text":"Move control and resize:\n\n```sqf\n_control2D ctrlSetPosition [0, 0, 1, 1];\n_control2D ctrlCommit 0;\n```","code":["_control2D ctrlSetPosition [0, 0, 1, 1];\n_control2D ctrlCommit 0;"]},{"text":"```sqf\n_control3D ctrlSetPosition [0.5, 1, 0.5]; //centered and 1m away from screen\n```","code":["_control3D ctrlSetPosition [0.5, 1, 0.5]; //centered and 1m away from screen"]},{"text":"Typewriter effect:\n\n```sqf\nwith uiNamespace do\n{\n    0 spawn\n    {\n        _text1 = \"This is a simple demo of typewriter text effect with various speed.\";\n        _text2 = \"This took 10 seconds.\";\n        _text3 = \"This is a fast one, set for 2 seconds.\";\n\n        ctrl = findDisplay 46 ctrlCreate [\"RscStructuredText\", -1];\n\n        ctrl ctrlSetPosition [0, 0, 0, 0.1];\n        ctrl ctrlCommit 0;\n        ctrl ctrlSetStructuredText parseText format [\"<t color='#ff0000' size='2.1'>%1</t>\", _text1 splitString \" \" joinString \" \"];\n        ctrl ctrlSetPosition [0, 0, ctrlTextWidth ctrl, 0.1];\n        ctrl ctrlCommit 8;\n\n        waitUntil { ctrlCommitted ctrl };\n        sleep 0.5;\n\n        ctrl ctrlSetPosition [0,0,0,0.1];\n        ctrl ctrlCommit 0;\n        ctrl ctrlSetStructuredText parseText format [\"<t color='#ff0000' size='2.1'>%1</t>\", _text2 splitString \" \" joinString \" \"];\n        ctrl ctrlSetPosition [0, 0, ctrlTextWidth ctrl, 0.1];\n        ctrl ctrlCommit 2;\n\n        waitUntil { ctrlCommitted ctrl };\n        sleep 2;\n\n        ctrl ctrlSetPosition [0,0,0,0.1];\n        ctrl ctrlCommit 0;\n        ctrl ctrlSetStructuredText parseText format [\"<t color='#00ff00' size='2.1'>%1</t>\", _text3 splitString \" \" joinString \" \"];\n        ctrl ctrlSetPosition [0,0,ctrlTextWidth ctrl,0.1];\n        ctrl ctrlCommit 2;\n\n        waitUntil { ctrlCommitted ctrl };\n        sleep 2;\n\n        ctrlDelete ctrl;\n    };\n};\n```","code":["with uiNamespace do\n{\n\t0 spawn\n\t{\n\t\t_text1 = \"This is a simple demo of typewriter text effect with various speed.\";\n\t\t_text2 = \"This took 10 seconds.\";\n\t\t_text3 = \"This is a fast one, set for 2 seconds.\";\n\n\t\tctrl = findDisplay 46 ctrlCreate [\"RscStructuredText\", -1];\n\n\t\tctrl ctrlSetPosition [0, 0, 0, 0.1];\n\t\tctrl ctrlCommit 0;\n\t\tctrl ctrlSetStructuredText parseText format [\"<t color='#ff0000' size='2.1'>%1</t>\", _text1 splitString \" \" joinString \" \"];\n\t\tctrl ctrlSetPosition [0, 0, ctrlTextWidth ctrl, 0.1];\n\t\tctrl ctrlCommit 8;\n\n\t\twaitUntil { ctrlCommitted ctrl };\n\t\tsleep 0.5;\n\n\t\tctrl ctrlSetPosition [0,0,0,0.1];\n\t\tctrl ctrlCommit 0;\n\t\tctrl ctrlSetStructuredText parseText format [\"<t color='#ff0000' size='2.1'>%1</t>\", _text2 splitString \" \" joinString \" \"];\n\t\tctrl ctrlSetPosition [0, 0, ctrlTextWidth ctrl, 0.1];\n\t\tctrl ctrlCommit 2;\n\n\t\twaitUntil { ctrlCommitted ctrl };\n\t\tsleep 2;\n\n\t\tctrl ctrlSetPosition [0,0,0,0.1];\n\t\tctrl ctrlCommit 0;\n\t\tctrl ctrlSetStructuredText parseText format [\"<t color='#00ff00' size='2.1'>%1</t>\", _text3 splitString \" \" joinString \" \"];\n\t\tctrl ctrlSetPosition [0,0,ctrlTextWidth ctrl,0.1];\n\t\tctrl ctrlCommit 2;\n\n\t\twaitUntil { ctrlCommitted ctrl };\n\t\tsleep 2;\n\n\t\tctrlDelete ctrl;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapSetPosition","ctrlCommit","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlClassName","displayCtrl","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp"],"notes":[{"user":"Yuval","date":"2017-06-20T11:56:00Z","text":"If the target control is a controls' group, all the child controls of that group will be moved automatically (as their position is relative to the control group rather than the display)."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetPositionH","operator":null,"title":"ctrlSetPositionH","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPositionH","revid":309179,"updated":"2022-05-03T18:04:10Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the height of a 2D control. ctrlCommit is required to complete the operation.","syntaxes":[{"syntax":"control ctrlSetPositionH h","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"control: Control - 2D control"},{"name":"h","type":"Number","optional":false,"default":null,"description":"height of the control","types":["Number"],"since":null,"text":"h: Number - height of the control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"h","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlSetPositionH 0.5;\n_ctrl ctrlCommit 1;\n```","code":["_ctrl ctrlSetPositionH 0.5;\n_ctrl ctrlCommit 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetPosition","ctrlSetPositionX","ctrlSetPositionY","ctrlSetPositionW"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"ctrlSetPositionW","operator":null,"title":"ctrlSetPositionW","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPositionW","revid":309180,"updated":"2022-05-03T18:04:27Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the width of a 2D control. ctrlCommit is required to complete the operation.","syntaxes":[{"syntax":"control ctrlSetPositionW w","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"control: Control - 2D control"},{"name":"w","type":"Number","optional":false,"default":null,"description":"width of the control","types":["Number"],"since":null,"text":"w: Number - width of the control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"w","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlSetPositionW 0.5;\n_ctrl ctrlCommit 1;\n```","code":["_ctrl ctrlSetPositionW 0.5;\n_ctrl ctrlCommit 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetPosition","ctrlSetPositionX","ctrlSetPositionY","ctrlSetPositionH"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"ctrlSetPositionX","operator":null,"title":"ctrlSetPositionX","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPositionX","revid":309181,"updated":"2022-05-03T18:04:56Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets horizontal position (x) of the 2D control. ctrlCommit is required to complete the operation.","syntaxes":[{"syntax":"control ctrlSetPositionX x","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"control: Control - 2D control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"horizontal position of the control","types":["Number"],"since":null,"text":"x: Number - horizontal position of the control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlSetPositionX 0.5;\n_ctrl ctrlCommit 1;\n```","code":["_ctrl ctrlSetPositionX 0.5;\n_ctrl ctrlCommit 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetPosition","ctrlSetPositionY","ctrlSetPositionW","ctrlSetPositionH"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"ctrlSetPositionY","operator":null,"title":"ctrlSetPositionY","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetPositionY","revid":349336,"updated":"2023-11-08T14:53:28Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets vertical position (y) of a 2D control. ctrlCommit is required to complete the operation.","syntaxes":[{"syntax":"control ctrlSetPositionY y","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"2D control","types":["Control"],"since":null,"text":"control: Control - 2D control"},{"name":"y","type":"Number","optional":false,"default":null,"description":"vertical position of the control","types":["Number"],"since":null,"text":"y: Number - vertical position of the control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"y","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlSetPositionY 0.5;\n_ctrl ctrlCommit 1;\n```","code":["_ctrl ctrlSetPositionY 0.5;\n_ctrl ctrlCommit 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetPosition","ctrlSetPositionX","ctrlSetPositionW","ctrlSetPositionH"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"ctrlSetProperty","operator":null,"title":"ctrlSetProperty","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetProperty","revid":379135,"updated":"2026-10-12T14:41:15Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.24"}],"since":{"game":"arma3","name":"Arma 3","version":"2.24"},"arma3_since":"2.24","branch":"dev","locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets one or multiple given properties of given control.","syntaxes":[{"syntax":"control ctrlSetProperty property","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"property","type":"Array in format [name, value]:","optional":false,"default":null,"description":"Array in format [name, value]:\n- name: String - Name of the property, case insensitive\n- value: Anything- Value depends on the property","types":["Array"],"since":null,"text":"property: Array in format [name, value]:\n- name: String - Name of the property, case insensitive\n- value: Anything- Value depends on the property"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"property","types":["Array"]}},{"syntax":"control ctrlSetProperty properties","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"properties","type":"HashMap in format:","optional":false,"default":null,"description":"HashMap in format:\n- key: String - Name of the property, case insensitive\n- value: Anything - Value depends on the property","types":["HashMap"],"since":null,"text":"properties: HashMap in format:\n- key: String - Name of the property, case insensitive\n- value: Anything - Value depends on the property"}],"returns":null,"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"properties","types":["HashMap"]}}],"examples":[{"text":"```sqf\n_ctrl ctrlSetProperty [\"x\", 0.015];\n```","code":["_ctrl ctrlSetProperty [\"x\", 0.015];"]},{"text":"```sqf\n_ctrl ctrlSetProperty #{\n    \"x\": 0.015, \n    \"colorBackground\": [1, 0.4, 1, 1]\n}\n```","code":["_ctrl ctrlSetProperty #{\n\t\"x\": 0.015, \n\t\"colorBackground\": [1, 0.4, 1, 1]\n}"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlGetProperty"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Development Branch","Command Group: GUI Control","Introduced with Arma 3 version 2.24","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctrlSetScale","operator":null,"title":"ctrlSetScale","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetScale","revid":369376,"updated":"2024-09-03T18:43:13Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets scale of a control. Top left corner remains same. This command requires ctrlCommit.","syntaxes":[{"syntax":"control ctrlSetScale scale","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"scale","type":"Number","optional":false,"default":null,"description":"scale e.g. 2 = 200% in size","types":["Number"],"since":null,"text":"scale: Number - scale e.g. 2 = 200% in size"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"scale","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetScale 0.5;// Makes the control 50% smaller\n_control ctrlCommit 0;\n```","code":["_control ctrlSetScale 0.5;// Makes the control 50% smaller\n_control ctrlCommit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlScale","ctrlModelScale","ctrlSetModelScale"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetScrollValues","operator":null,"title":"ctrlSetScrollValues","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetScrollValues","revid":338941,"updated":"2023-04-17T15:45:43Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets scroll values for current scrollbars in range 0..1 for the following controls:\n- CT_CONTROLS_TABLE\n- CT_CONTROLS_GROUP\n- CT_TREE\n- CT_LISTBOX\n- CT_COMBO\n- CT_XCOMBO\n- CT_LISTNBOX\n- CT_LISTNBOX_CHECKABLE","syntaxes":[{"syntax":"control ctrlSetScrollValues [vScrollValue, hScrollValue]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"vScrollValue","type":"Number","optional":false,"default":null,"description":"vertical scroll value in 0..1 range. -1 to skip","types":["Number"],"since":null,"text":"vScrollValue: Number - vertical scroll value in 0..1 range. -1 to skip"},{"name":"hScrollValue","type":"Number","optional":false,"default":null,"description":"horizontal scroll value in 0..1 range. -1 to skip","types":["Number"],"since":null,"text":"hScrollValue: Number - horizontal scroll value in 0..1 range. -1 to skip"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[vScrollValue, hScrollValue]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrlGrp ctrlSetScrollValues [-1, 0.5];\n```","code":["_ctrlGrp ctrlSetScrollValues [-1, 0.5];"]},{"text":"```sqf\n// ControlsGroup\nprivate _disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGrp = _disp ctrlCreate [\"RscControlsGroup\", -1];\nprivate _ctrl = _disp ctrlCreate [\"RscTree\", -1, _ctrlGrp];\n_ctrl tvAdd [[], \"Root\"];\nfor \"_i\" from 1 to 25 do\n{\n    _ctrl tvAdd [[0], format [\"Tree Item %1\", _i]];\n};\n_ctrl ctrlSetPosition [0,0,0.3,1.2];\n_ctrl ctrlCommit 0;\ntvExpandAll _ctrl;\n_ctrlGrp ctrlSetPosition [0,0,0.2,0.3];\n_ctrlGrp ctrlCommit 0;\n \nuiNamespace setVariable [\"_ctrl\", _ctrlGrp];\nonEachFrame\n{\n    hintSilent str ctrlScrollValues (uiNamespace getVariable [\"_ctrl\", controlNull]);\n};\n0 spawn\n{\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.3, -1];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.3];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.7, -1];\n    sleep 1;\n    uiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.7];\n};\n```","code":["// ControlsGroup\nprivate _disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\nprivate _ctrlGrp = _disp ctrlCreate [\"RscControlsGroup\", -1];\nprivate _ctrl = _disp ctrlCreate [\"RscTree\", -1, _ctrlGrp];\n_ctrl tvAdd [[], \"Root\"];\nfor \"_i\" from 1 to 25 do\n{\n\t_ctrl tvAdd [[0], format [\"Tree Item %1\", _i]];\n};\n_ctrl ctrlSetPosition [0,0,0.3,1.2];\n_ctrl ctrlCommit 0;\ntvExpandAll _ctrl;\n_ctrlGrp ctrlSetPosition [0,0,0.2,0.3];\n_ctrlGrp ctrlCommit 0;\n \nuiNamespace setVariable [\"_ctrl\", _ctrlGrp];\nonEachFrame\n{\n\thintSilent str ctrlScrollValues (uiNamespace getVariable [\"_ctrl\", controlNull]);\n};\n0 spawn\n{\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.3, -1];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.3];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [0.7, -1];\n\tsleep 1;\n\tuiNamespace getVariable [\"_ctrl\", controlNull] ctrlSetScrollValues [-1, 0.7];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlScrollValues","sliderSetPosition","progressSetPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"ctrlSetShadow","operator":null,"title":"ctrlSetShadow","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetShadow","revid":330159,"updated":"2022-08-23T12:23:54Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets 'shadow' property of the control:\n- 0 - no shadow\n- 1 - shadow\n- 2 - outline","syntaxes":[{"syntax":"control ctrlSetShadow shadow","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"shadow","type":"Number","optional":false,"default":null,"description":"shadow value, see description","types":["Number"],"since":null,"text":"shadow: Number - shadow value, see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"shadow","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetShadow 1;\n```","code":["_control ctrlSetShadow 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlShadow","ctrlCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"ctrlSetStructuredText","operator":null,"title":"ctrlSetStructuredText","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetStructuredText","revid":321026,"updated":"2022-05-13T11:32:18Z","groups":["GUI Control","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the Structured Text which will be displayed in structured text control.","syntaxes":[{"syntax":"control ctrlSetStructuredText structuredText","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"structuredText","type":"Structured Text","optional":false,"default":null,"description":null,"types":["Structured Text"],"since":null,"text":"structuredText: Structured Text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"structuredText","types":["Structured Text"]}}],"examples":[{"text":"```sqf\n_control ctrlSetStructuredText parseText \"First line<img image=data\\isniper.paa /><br />Second line\"\n```","code":["_control ctrlSetStructuredText parseText \"First line<img image=data\\isniper.paa /><br />Second line\""]},{"text":"To adjust text vertically, add extra line above with blank space (&#160;) and set its size accordingly:\n\n```sqf\nwith uiNamespace do {\n    button = findDisplay 46 ctrlCreate [\"RscShortcutButton\", -1];\n    button ctrlSetPosition [0,0,0.3,0.1];\n    button ctrlCommit 0;\n    button ctrlSetStructuredText parseText \n    \"<t size='0.5'> </t><br/><t size='1' align='center'>Button Text  </t>\";\n};\n```","code":["with uiNamespace do {\n\tbutton = findDisplay 46 ctrlCreate [\"RscShortcutButton\", -1];\n\tbutton ctrlSetPosition [0,0,0.3,0.1];\n\tbutton ctrlCommit 0;\n\tbutton ctrlSetStructuredText parseText \n\t\"<t size='0.5'> </t><br/><t size='1' align='center'>Button Text  </t>\";\n};"]},{"text":"There is a bug with `valign` that requires adding 1 extra trailing space per line to the displayed text in order to keep it centered horizontally:\n\n```sqf\ndisableSerialization;\nprivate _ctrl = findDisplay 46 ctrlCreate [\"RscStructuredText\", -1];\n_ctrl ctrlSetPosition [0, 0, 0.5, 0.5];\n_ctrl ctrlSetBackgroundColor [0, 0, 0, 1];\n_ctrl ctrlCommit 0;\nprivate _lineHeight = getNumber (configFile >> \"RscStructuredText\" >> \"size\");\nprivate _linesTotal = (ctrlPosition _ctrl select 2) / _lineHeight;\nprivate _trailingSpace = \"\";\nfor \"_i\" from 1 to _linesTotal do { _trailingSpace = _trailingSpace + \" \" };\n_ctrl ctrlSetStructuredText parseText format [\"<t size='%1'><t size='1' align='center' valign='middle'>%2%3</t> </t>\", _linesTotal, \"------ Centered Text ------\", _trailingSpace];\n```","code":["disableSerialization;\nprivate _ctrl = findDisplay 46 ctrlCreate [\"RscStructuredText\", -1];\n_ctrl ctrlSetPosition [0, 0, 0.5, 0.5];\n_ctrl ctrlSetBackgroundColor [0, 0, 0, 1];\n_ctrl ctrlCommit 0;\nprivate _lineHeight = getNumber (configFile >> \"RscStructuredText\" >> \"size\");\nprivate _linesTotal = (ctrlPosition _ctrl select 2) / _lineHeight;\nprivate _trailingSpace = \"\";\nfor \"_i\" from 1 to _linesTotal do { _trailingSpace = _trailingSpace + \" \" };\n_ctrl ctrlSetStructuredText parseText format [\"<t size='%1'><t size='1' align='center' valign='middle'>%2%3</t> </t>\", _linesTotal, \"------ Centered Text ------\", _trailingSpace];"]}],"multiplayer":null,"problems":"Using this command will modify the provided *structuredText* - a way to circumvent this issue is to parseText in-line. See Notes.","aliases":[],"see_also":["Structured Text","composeText","parseText","text"],"notes":[{"user":"Dscha","date":"2020-03-20T19:48:00Z","text":"When using parseText on an RscStructuredText control, with **custom Attributes** set (extra config Class), it needs to be in the same line as ctrlSetStructuredText:\n\n```sqf\n_text = \"abc\";\n_ctrl ctrlSetStructuredText parseText _text;\n```\n\nThe following Code would use **none** of the custom Attributes of the selected Control, instead it falls back to Standard Values (Font, Size, Color, Align, etc)\n\n```sqf\n_text = parseText \"abc\";\n_ctrl ctrlSetStructuredText _text;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Structured Text","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetText","operator":null,"title":"ctrlSetText","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetText","revid":378494,"updated":"2026-04-26T15:15:10Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the text of a control of the currently active user dialog or display.\nThis command can be used for static texts, buttons, edit lines and active texts as well as for images, where you can use it to set the image path.\n\nRead Arma: GUI Configuration for more information about user dialogs and controls.\n\nUse endl to insert line breaks.\n\nSince Arma 3 v2.06 supported control types are:\n- CT_STATIC\n- CT_EDIT\n- CT_XKEYDESC\n- CT_XBUTTON\n- CT_SHORTCUTBUTTON\n- CT_STRUCTURED_TEXT\n- CT_BUTTON\n- CT_ACTIVETEXT\n\nSince Arma 3 v2.22 CT_PROGRESS is also supported.","syntaxes":[{"syntax":"ctrlSetText [idc, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"text","type":"String","optional":false,"default":null,"description":"text or image path or texture, depending on the control type","types":["String"],"since":null,"text":"text: String - text or image path or texture, depending on the control type"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, text]","types":["Array"]}},{"syntax":"control ctrlSetText text","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"control","types":["Control"],"since":null,"text":"control: Control - control"},{"name":"text","type":"String","optional":false,"default":null,"description":"text or image path or texture, depending on the control type","types":["String"],"since":null,"text":"text: String - text or image path or texture, depending on the control type"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\nctrlSetText [100, \"Hello world\"]; // for Dialogs\n```","code":["ctrlSetText [100, \"Hello world\"]; // for Dialogs"]},{"text":"```sqf\n_control ctrlSetText \"Hello world.\"; // for Displays\n```","code":["_control ctrlSetText \"Hello world.\"; // for Displays"]},{"text":"Since Arma 3 2.22:\n\n```sqf\nwith uiNamespace do \n{ \n bar = findDisplay 46 ctrlCreate [\"RscProgress\", -1]; \n bar ctrlSetText \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";\n bar ctrlSetPosition [0,0,1,0.25]; \n bar ctrlCommit 0; \n bar progressSetPosition 0.7;\n};\n```","code":["with uiNamespace do \n{ \n bar = findDisplay 46 ctrlCreate [\"RscProgress\", -1]; \n bar ctrlSetText \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";\n bar ctrlSetPosition [0,0,1,0.25]; \n bar ctrlCommit 0; \n bar progressSetPosition 0.7;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlText","ctrlTextSelection","ctrlSetTextSelection"],"notes":[],"categories":[]},{"name":"ctrlSetTextColor","operator":null,"title":"ctrlSetTextColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTextColor","revid":377177,"updated":"2026-01-01T10:47:30Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets text color of given control. As of Arma 3 v1.40 this command can also be used to change fill-color of a CT_PROGRESS control.\n\n> [!NOTE]\n> Also try ctrlSetForegroundColor, if this command doesn't have the desired effect.","syntaxes":[{"syntax":"control ctrlSetTextColor color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTextColor [1, 0, 0, 1];\n```","code":["_control ctrlSetTextColor [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetForegroundColor","ctrlTextColor","ctrlSetText"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTextColorSecondary","operator":null,"title":"ctrlSetTextColorSecondary","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTextColorSecondary","revid":377731,"updated":"2026-01-03T00:21:36Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the secondary text color of a text control.","syntaxes":[{"syntax":"control ctrlSetTextColorSecondary color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"text control","types":["Control"],"since":null,"text":"control: Control - text control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_ctrlText ctrlSetTextColorSecondary [1, 0.5, 0.1, 0.5];\n```","code":["_ctrlText ctrlSetTextColorSecondary [1, 0.5, 0.1, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextSecondary","ctrlSetText","ctrlText","ctrlSetTextSecondary"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTextSecondary","operator":null,"title":"ctrlSetTextSecondary","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTextSecondary","revid":349266,"updated":"2023-11-08T14:51:08Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the secondary text of a text control.","syntaxes":[{"syntax":"control ctrlSetTextSecondary text","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"text control","types":["Control"],"since":null,"text":"control: Control - text control"},{"name":"text","type":"String","optional":false,"default":null,"description":"secondary text","types":["String"],"since":null,"text":"text: String - secondary text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n_ctrlText ctrlSetTextSecondary \"Hello World!\";\n```","code":["_ctrlText ctrlSetTextSecondary \"Hello World!\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextSecondary","ctrlSetText","ctrlText","ctrlSetTextColorSecondary"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTextSelection","operator":null,"title":"ctrlSetTextSelection","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTextSelection","revid":309239,"updated":"2022-05-04T10:30:57Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects `length` characters of edit control from the `start` position and places cursor at the end of selection.\n\n> [!NOTE]\n> To only move the cursor, set *length* to 0. To select text from right to left, use negative *length* (See ctrlTextSelection for more info)","syntaxes":[{"syntax":"control ctrlSetTextSelection [start, length]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"start","type":"Number","optional":false,"default":null,"description":"selection start position","types":["Number"],"since":null,"text":"start: Number - selection start position"},{"name":"length","type":"Number","optional":false,"default":null,"description":"length of characters to select (0 to only move the cursor). Negative length will select text from right to left (see example 3)","types":["Number"],"since":null,"text":"length: Number - length of characters to select (0 to only move the cursor). Negative length will select text from right to left (see example 3)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[start, length]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTextSelection [5, 10];\n```","code":["_control ctrlSetTextSelection [5, 10];"]},{"text":"```sqf\ndisableSerialization;\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscEditMulti\", -1];\n_ctrl ctrlSetPosition [0,0,0.5,0.3];\n_ctrl ctrlCommit 0;\n_ctrl ctrlSetText \"Hello World\";\n_ctrl ctrlSetTextSelection [6, 5]; // selects World\nctrlSetFocus _ctrl;\n```","code":["disableSerialization;\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscEditMulti\", -1];\n_ctrl ctrlSetPosition [0,0,0.5,0.3];\n_ctrl ctrlCommit 0;\n_ctrl ctrlSetText \"Hello World\";\n_ctrl ctrlSetTextSelection [6, 5]; // selects World\nctrlSetFocus _ctrl;"]},{"text":"Select text from right to left:\n\n```sqf\n_control ctrlSetTextSelection [5, -4];\n```","code":["_control ctrlSetTextSelection [5, -4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextSelection","ctrlSetText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"ctrlSetTooltip","operator":null,"title":"ctrlSetTooltip","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTooltip","revid":369134,"updated":"2024-09-03T10:34:34Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip text of given control.\n\n> [!NOTE]\n> If control supports URL property, like `RscActiveText` for example, and the URL is set, tooltip text displayed on mouse over will be appended with URL text.","syntaxes":[{"syntax":"control ctrlSetTooltip text","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"any control type, (except for CT_STATIC & CT_STRUCTURED_TEXT, although Arma 3 now supports these too)","types":["Control"],"since":null,"text":"control: Control - any control type, (except for CT_STATIC & CT_STRUCTURED_TEXT, although Arma 3 now supports these too)"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTooltip \"tooltip\";\n```","code":["_control ctrlSetTooltip \"tooltip\";"]},{"text":"```sqf\nfindDisplay 10000 displayCtrl 10001 ctrlSetTooltip \"ThisIsAGoodTip\";\n```","code":["findDisplay 10000 displayCtrl 10001 ctrlSetTooltip \"ThisIsAGoodTip\";"]},{"text":"```sqf\nwith uiNamespace do \n{\n    bar = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscProgress\", -1];\n    bar ctrlSetPosition [0,0,1,0.01];\n    bar ctrlCommit 0;\n    bar progressSetPosition 0.75;\n    bar ctrlSetTooltip \"lalalalalalalala\";\n};\n```","code":["with uiNamespace do \n{\n\tbar = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscProgress\", -1];\n\tbar ctrlSetPosition [0,0,1,0.01];\n\tbar ctrlCommit 0;\n\tbar progressSetPosition 0.75;\n\tbar ctrlSetTooltip \"lalalalalalalala\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTooltipColorBox","ctrlSetTooltipColorShade","ctrlSetTooltipColorText"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTooltipColorBox","operator":null,"title":"ctrlSetTooltipColorBox","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTooltipColorBox","revid":378388,"updated":"2026-04-04T06:25:53Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip border color of given control.","syntaxes":[{"syntax":"control ctrlSetTooltipColorBox color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTooltipColorBox [1, 0, 0, 1];\n```","code":["_control ctrlSetTooltipColorBox [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTooltip","ctrlSetTooltipColorShade","ctrlSetTooltipColorText"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTooltipColorShade","operator":null,"title":"ctrlSetTooltipColorShade","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTooltipColorShade","revid":377368,"updated":"2026-01-02T06:42:12Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip background color of given control.","syntaxes":[{"syntax":"control ctrlSetTooltipColorShade color","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTooltipColorShade [1, 0, 0, 1];\n```","code":["_control ctrlSetTooltipColorShade [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTooltip","ctrlSetTooltipColorBox","ctrlSetTooltipColorText"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTooltipColorText","operator":null,"title":"ctrlSetTooltipColorText","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTooltipColorText","revid":377176,"updated":"2026-01-01T10:47:06Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip text color of given control.","syntaxes":[{"syntax":"display ctrlSetTooltipColorText color","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"display: Control"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Control"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\n_control ctrlSetTooltipColorText [1, 0, 0, 1];\n```","code":["_control ctrlSetTooltipColorText [1, 0, 0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTooltip","ctrlSetTooltipColorBox","ctrlSetTooltipColorShade"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlSetTooltipMaxWidth","operator":null,"title":"ctrlSetTooltipMaxWidth","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetTooltipMaxWidth","revid":310331,"updated":"2022-05-05T16:44:26Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set maximum width of a control's tooltip.","syntaxes":[{"syntax":"ctrl ctrlSetTooltipMaxWidth width","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"width","type":"Number","optional":false,"default":null,"description":"in screen measurement units","types":["Number"],"since":null,"text":"width: Number - in screen measurement units"}],"returns":{"type":"Number","types":["Number"],"description":"the previous maximum width of the tooltip","text":"Number - the previous maximum width of the tooltip"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"width","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _previousMaxWidth = _myControl ctrlSetTooltipMaxWidth (SafeZoneW / 2);\n```","code":["private _previousMaxWidth = _myControl ctrlSetTooltipMaxWidth (SafeZoneW / 2);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","SafeZoneW"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"ctrlSetURL","operator":null,"title":"ctrlSetURL","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetURL","revid":325207,"updated":"2022-07-03T07:02:32Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets URL property of the given control subject to `allowedHTMLLoadURIs[]` whitelisting in CfgCommands config. Supported controls are:\n- `CT_BUTTON`\n- `CT_SHORTCUTBUTTON`\n- `CT_ACTIVETEXT`","syntaxes":[{"syntax":"control ctrlSetURL URL","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"URL","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"URL: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"URL","types":["String"]}}],"examples":[{"text":"```sqf\n_control ctrlSetURL \"http://arma3.com/\";\n```","code":["_control ctrlSetURL \"http://arma3.com/\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlURL","menuSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlSetURLOverlayMode","operator":null,"title":"ctrlSetURLOverlayMode","type":"command","url":"https://community.bistudio.com/wiki/ctrlSetURLOverlayMode","revid":376033,"updated":"2025-07-22T09:12:10Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets how to handle opening of URL, default browser or Steam overlay. Possible values:\n- 0 - default browser\n- 1 - Steam overlay if enabled, otherwise default browser\n- 2 - Steam overlay, shows error message box if disabled (the box has a button to continue with default browser)\n\n> [!NOTE]\n> Toggling Steam overlay in Steam options will require game restart for the changes to take effect.","syntaxes":[{"syntax":"control ctrlSetURLOverlayMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"control that contain url opening action","types":["Control"],"since":null,"text":"control: Control - control that contain url opening action"},{"name":"mode","type":"Number","optional":false,"default":null,"description":"overlay mode, see description","types":["Number"],"since":null,"text":"mode: Number - overlay mode, see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"mode","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctrlSetURLOverlayMode 1;\n```","code":["_control ctrlSetURLOverlayMode 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isSteamOverlayEnabled","ctrlURLOverlayMode","ctrlURL","menuSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"ctrlShadow","operator":null,"title":"ctrlShadow","type":"command","url":"https://community.bistudio.com/wiki/ctrlShadow","revid":330174,"updated":"2022-08-23T12:24:04Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns 'shadow' property of the control (see ctrlSetShadow).","syntaxes":[{"syntax":"ctrlShadow control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_shadow = ctrlShadow _control;\n```","code":["_shadow = ctrlShadow _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetShadow","ctrlCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"ctrlShow","operator":null,"title":"ctrlShow","type":"command","url":"https://community.bistudio.com/wiki/ctrlShow","revid":370565,"updated":"2025-01-09T18:12:50Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Shows or hides a control, or group of controls together with all the controls inside that group of controls.\n\nRead Arma: GUI Configuration for more information about user dialogs and controls.\n\n> [!NOTE]\n> Using ctrlShow on a controls group will show or hide all controls within the controls group (including controls that are placed in nested controls groups).","syntaxes":[{"syntax":"ctrlShow [idc, show]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"show","type":"Boolean","optional":false,"default":null,"description":"true to show the control, false to hide it","types":["Boolean"],"since":null,"text":"show: Boolean - true to show the control, false to hide it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, show]","types":["Array"]}},{"syntax":"control ctrlShow show","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"show","type":"Boolean","optional":false,"default":null,"description":"true to show the control, false to hide it","types":["Boolean"],"since":null,"text":"show: Boolean - true to show the control, false to hide it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nctrlShow [100, false];\n```","code":["ctrlShow [100, false];"]},{"text":"```sqf\n_control ctrlShow false;\n```","code":["_control ctrlShow false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlVisible","ctrlShown","ctrlEnable"],"notes":[],"categories":[]},{"name":"ctrlShown","operator":null,"title":"ctrlShown","type":"command","url":"https://community.bistudio.com/wiki/ctrlShown","revid":310874,"updated":"2022-05-07T20:24:10Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether given control is shown.","syntaxes":[{"syntax":"ctrlShown controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"controlName: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_bool = ctrlShown _ctrl;\n```","code":["_bool = ctrlShown _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlShow","ctrlVisible"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlStyle","operator":null,"title":"ctrlStyle","type":"command","url":"https://community.bistudio.com/wiki/ctrlStyle","revid":336960,"updated":"2023-01-04T16:44:17Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the provided control's style. See Arma: GUI Configuration#Control Styles.","syntaxes":[{"syntax":"ctrlStyle control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":"see Arma: GUI Configuration#Control Styles","text":"Number - see Arma: GUI Configuration#Control Styles"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _ctrlStyle = ctrlStyle _myControl;\n\nprivate _bitFlags = _ctrlStyle call BIS_fnc_bitflagsToArray;\nif (2 in _bitFlags) then\n{\n    hint \"This control has centered text!\";\n};\n```","code":["private _ctrlStyle = ctrlStyle _myControl;\n\nprivate _bitFlags = _ctrlStyle call BIS_fnc_bitflagsToArray;\nif (2 in _bitFlags) then\n{\n\thint \"This control has centered text!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlType","BIS_fnc_bitflagsToArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlText","operator":null,"title":"ctrlText","type":"command","url":"https://community.bistudio.com/wiki/ctrlText","revid":378493,"updated":"2026-04-26T15:11:35Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the text of a control of the currently active user dialog. This command can be used on static texts, buttons, edit lines and active texts as well as for images, where it returns the image path. Does not work on HTML control and returns empty string \"\". Since Arma 3 v2.05 supported control types are:\n- CT_STATIC\n\n- CT_EDIT\n- CT_XKEYDESC\n- CT_XBUTTON\n- CT_SHORTCUTBUTTON\n- CT_STRUCTURED_TEXT\n- CT_BUTTON\n- CT_ACTIVETEXT\n\nSince Arma 3 v2.20 CT_PROGRESS is also supported.","syntaxes":[{"syntax":"ctrlText idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control ID","types":["Number"],"since":null,"text":"idc: Number - control ID"}],"returns":{"type":"String","types":["String"],"description":"the text or image path or texture is returned, dependent on the control type","text":"String - the text or image path or texture is returned, dependent on the control type"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"ctrlText controlName","since":null,"effect":null,"exec":null,"params":[{"name":"controlName","type":"Control","optional":false,"default":null,"description":"control","types":["Control"],"since":null,"text":"controlName: Control - control"}],"returns":{"type":"String","types":["String"],"description":"the text or image path or texture is returned, dependent on the control type","text":"String - the text or image path or texture is returned, dependent on the control type"},"form":"unary","operator":null,"left":null,"right":{"text":"controlName","types":["Control"]}}],"examples":[{"text":"```sqf\n_text = ctrlText 100;\n```","code":["_text = ctrlText 100;"]},{"text":"```sqf\n_text = ctrlText _control;\n```","code":["_text = ctrlText _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextSecondary","ctrlSetText","Arma: GUI Configuration"],"notes":[],"categories":[]},{"name":"ctrlTextColor","operator":null,"title":"ctrlTextColor","type":"command","url":"https://community.bistudio.com/wiki/ctrlTextColor","revid":377354,"updated":"2026-01-02T06:40:18Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns control's text color","syntaxes":[{"syntax":"ctrlTextColor control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":"text color","text":"Color (RGBA) - text color"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlTextColor _control;\n```","code":["ctrlTextColor _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTextColor","ctrlText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlTextHeight","operator":null,"title":"ctrlTextHeight","type":"command","url":"https://community.bistudio.com/wiki/ctrlTextHeight","revid":377912,"updated":"2026-01-09T17:38:24Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the text control's height. Supported control types:\n- CT_STATIC\n- CT_STRUCTURED_TEXT\n- CT_EDIT\n- Arma 3 v2.06 CT_XKEYDESC\n- Arma 3 v2.06 CT_XBUTTON\n- Arma 3 v2.06 CT_SHORTCUTBUTTON\n- Arma 3 v2.06 CT_BUTTON\n- Arma 3 v2.06 CT_ACTIVETEXT","syntaxes":[{"syntax":"ctrlTextHeight control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_h = ctrlTextHeight _ctrl;\n```","code":["_h = ctrlTextHeight _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlFontHeight","ctrlTextWidth","ctrlSetText","ctrlType","Arma: GUI Configuration"],"notes":[{"user":"Nelis75733126","date":"2017-05-24T21:34:00Z","text":"In Arma 3 v1.70, this command always returns 0 if the definition for width of the control ( inside .hpp or .cpp file ) is missing."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"ctrlTextSecondary","operator":null,"title":"ctrlTextSecondary","type":"command","url":"https://community.bistudio.com/wiki/ctrlTextSecondary","revid":349260,"updated":"2023-11-08T14:51:05Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the secondary text of a text control.","syntaxes":[{"syntax":"ctrlTextSecondary control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"text control","types":["Control"],"since":null,"text":"control: Control - text control"}],"returns":{"type":"String","types":["String"],"description":"secondary text of given control","text":"String - secondary text of given control"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_secondaryText = ctrlTextSecondary _ctrlText;\n```","code":["_secondaryText = ctrlTextSecondary _ctrlText;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTextSecondary","ctrlSetText","ctrlText","ctrlSetTextColorSecondary"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlTextSelection","operator":null,"title":"ctrlTextSelection","type":"command","url":"https://community.bistudio.com/wiki/ctrlTextSelection","revid":377654,"updated":"2026-01-02T09:02:02Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns edit control text selection in format [start, length, selectedText].\n\n> [!NOTE]\n> *length* can be negative if text selection is made from right to left. Use abs with *length* or count with `selectedText` if string length is required. *start* always indicates at what position in text the selection is started. The cursor position will always be at the end of the selection. So if selection is made from right to left the cursor position will be at the left end of the selection. In order to find cursor position add *start* and *length* together (see #Example 3).","syntaxes":[{"syntax":"ctrlTextSelection control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array with [start, length, selectedText]","types":["Array"],"description":"start: Number - position in text selection started - length: Number - number of the highlighted characters (this number could be negative, see description) - selectedText: String - selected text","text":"Array with [start, length, selectedText]\n- start: Number - position in text selection started\n- length: Number - number of the highlighted characters (this number could be negative, see description)\n- selectedText: String - selected text"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"Selection is made from left to right:\n\n```sqf\nctrlTextSelection _control; //[0, 11, \"Hello World\"];\n```","code":["ctrlTextSelection _control; //[0, 11, \"Hello World\"];"]},{"text":"Selection is made from right to left:\n\n```sqf\nctrlTextSelection _control; //[11, -11, \"Hello World\"];\n```","code":["ctrlTextSelection _control; //[11, -11, \"Hello World\"];"]},{"text":"Find cursor position:\n\n```sqf\nctrlTextSelection _control params [\"_start\", \"_length\"];\nprivate _cursorPos = _start + _length;\n```","code":["ctrlTextSelection _control params [\"_start\", \"_length\"];\nprivate _cursorPos = _start + _length;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTextSelection"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"ctrlTextWidth","operator":null,"title":"ctrlTextWidth","type":"command","url":"https://community.bistudio.com/wiki/ctrlTextWidth","revid":373703,"updated":"2025-06-20T08:16:47Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the width of the control text including left and right margins (0.008 each). Supported control types are:\n- CT_STATIC 0\n- CT_EDIT 2\n- CT_STRUCTURED_TEXT 13\n- Arma 3 v2.06 CT_XKEYDESC 40\n- Arma 3 v2.06 CT_XBUTTON 41\n- Arma 3 v2.06 CT_SHORTCUTBUTTON 16\n- Arma 3 v2.06 CT_BUTTON 1\n- Arma 3 v2.06 CT_ACTIVETEXT 11\n\n> [!NOTE]\n> For control-independent text width estimate see getTextWidth.","syntaxes":[{"syntax":"ctrlTextWidth control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _w = ctrlTextWidth _ctrl;\n```","code":["private _w = ctrlTextWidth _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTextWidth","ctrlTextHeight","ctrlSetText","ctrlType","Arma: GUI Configuration"],"notes":[{"user":"R3vo","date":"2020-10-28T22:10:00Z","text":"When working with multiline controls ctrlTextWidth or getTextWidth will not return a proper value since the text will be treated as one long line.\n\n**Solution (Execute in Eden Editor):**\n\n```sqf\ndisableSerialization;\n\nprivate _display = findDisplay 313 createDisplay \"RscDisplayEmpty\";\n\nprivate _edit = _display ctrlCreate [\"RscEditMulti\", -1];\n_edit ctrlSetPosition [0,0,1,1];\n_edit ctrlSetBackgroundColor [0,0,0,1];\n_edit ctrlSetFont \"EtelkaMonospacePro\";\n_edit ctrlSetFontHeight 0.03;\n_edit ctrlCommit 0;\n\nprivate _longestLineWidth = 0;\nprivate _exampleString = \"abcdefghijklmnopqrstuvxyz0134567890\";\nprivate _text = \"\";\n\nfor \"_lines\" from 1 to 400 do // loop through all lines and find the longest one\n{\n    _lineText = _exampleString select [round random 35];\n    _longestLineWidth = _longestLineWidth max (_lineText getTextWidth [\"EtelkaMonospacePro\", 0.03]);\n    _text = _text + _lineText + endl;\n};\n\n_edit ctrlSetPositionW (_longestLineWidth + 2 * 0.008); // width of longest line + left and right margin set in engine\n_edit ctrlCommit 0;\n_edit ctrlSetText _text;\n```"},{"user":"Sa-Matra","date":"2025-06-20T04:57:35Z","text":"If you have ui2textures in the text, there is a slight change this command can return NaN if texture is bugged, can be checked with finite for these rare cases."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.78","Scripting Commands"]},{"name":"ctrlTooltip","operator":null,"title":"ctrlTooltip","type":"command","url":"https://community.bistudio.com/wiki/ctrlTooltip","revid":309294,"updated":"2022-05-05T11:52:36Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the tooltip property of a button control. Getter for ctrlSetTooltip.","syntaxes":[{"syntax":"ctrlTooltip control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctrlTooltip _control;\n```","code":["ctrlTooltip _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetTooltip"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlType","operator":null,"title":"ctrlType","type":"command","url":"https://community.bistudio.com/wiki/ctrlType","revid":318899,"updated":"2022-05-13T09:22:00Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns number representing the type of control, which is also defined by *type* property in config. For more information see Arma: GUI Configuration","syntaxes":[{"syntax":"ctrlType control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_type = ctrlType _rscEdit; // 2\n```","code":["_type = ctrlType _rscEdit; // 2"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlCreate","Arma: GUI Configuration"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ctrlURL","operator":null,"title":"ctrlURL","type":"command","url":"https://community.bistudio.com/wiki/ctrlURL","revid":309293,"updated":"2022-05-05T11:52:21Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the URL property of a button control. Getter for ctrlSetURL.","syntaxes":[{"syntax":"ctrlURL control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _ctrlUrl = ctrlURL _control; // e.g. \"http://arma3.com/\"\n```","code":["private _ctrlUrl = ctrlURL _control; // e.g. \"http://arma3.com/\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"ctrlURLOverlayMode","operator":null,"title":"ctrlURLOverlayMode","type":"command","url":"https://community.bistudio.com/wiki/ctrlURLOverlayMode","revid":330165,"updated":"2022-08-23T12:23:58Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the URL overlay mode 0, 1, 2 (see ctrlSetURLOverlayMode) or -1 if something went wrong.","syntaxes":[{"syntax":"ctrlURLOverlayMode control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_mode = ctrlURLOverlayMode _control; // e.g. 0\n```","code":["_mode = ctrlURLOverlayMode _control; // e.g. 0"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetURLOverlayMode","ctrlURL","isSteamOverlayEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"ctrlVisible","operator":null,"title":"ctrlVisible","type":"command","url":"https://community.bistudio.com/wiki/ctrlVisible","revid":348410,"updated":"2023-11-08T13:00:06Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns if a control of the currently active user dialog is shown or not. Read Arma: GUI Configuration for more information about user dialogs and controls.","syntaxes":[{"syntax":"ctrlVisible idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the control is shown, false if not","text":"Boolean - true if the control is shown, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}}],"examples":[{"text":"```sqf\n_bool = ctrlVisible 100;\n```","code":["_bool = ctrlVisible 100;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlShow","ctrlShown"],"notes":[],"categories":[]},{"name":"ctrlWebBrowserAction","operator":null,"title":"ctrlWebBrowserAction","type":"command","url":"https://community.bistudio.com/wiki/ctrlWebBrowserAction","revid":379128,"updated":"2026-10-09T13:10:17Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Executes an action on a WebBrowser control. The type of parameters depends on the action type. Possible Actions are:\n\n| Action | Parameter | Result | Description |\n|---|---|---|---|\n| OpenDevConsole | None | Nothing | Opens a Chrome Developer console for this browser, in a external window. (Only available if -debug start parameter is set) |\n| ExecJS | String | Nothing | Executes Javascript code inside the currently loaded page. |\n| JSDialogResponse | Boolean | Nothing | Respond to a Javascript alert() or confirm(), after triggered by \"JSDialog\" Eventhandler |\n| OpenDataAsURL | String | Nothing | Displays provided data in browser. This can be used to load HTML from a file and display it in the Browser window. |\n| LoadFile | String | Nothing | Loads file into browser (Equivalent to [\"OpenDataAsURL\", loadFile \"filePathHere\"])<br>_ctrl ctrlWebBrowserAction [\"LoadFile\", \"z\\mod\\file.html\"] is equivalent to _ctrl ctrlSetURL \"file://z/mod/file.html\" |\n| ToBase64 | String | String | Encodes the input string into Base64 (This also works with controlNull) |\n| FromBase64 | String | String | Decodes the input Base64 string (This also works with controlNull) |\n| Deflate | String | String | Compresses the input and returns a Base64 Deflate compressed output with ZLib header (This also works with controlNull) |\n| Inflate | String | String | Takes Base64 encoded, Deflate compressed input data and returns the decompressed output (This also works with controlNull). Output is limited to 1Megabyte. Equivalent Javascript code:<br>is https://gist.github.com/asidko/9c7064027039411a11323eaf7d8ea2a4#file-gzip-js-L12 but replace 'gzip' with 'deflate' |\n| StopBrowser |  | Nothing | Freezes the currently displayed image (the same image will keep being displayed). Closes the browser and free's all resources of it. This is useful if the Browser is only used to generate a static element and it doesn't need to keep updating it. It saves CPU and Memory resources. |\n| ResumeBrowser |  | Nothing | Unfreezes the browser, and loads the currently set URL (Either that was set before StopBrowser, or which has been set while the browser was paused). Note that when unfreezing, the browser may show one or two black frames while the page is loading. For seemless transition from Paused/Resumed state, you can use a ui2texture and not send any displayUpdate's to it until you consider the resumed browser to be ready. |\n| SetBrowserInternalSize Arma 3 v2.24 | Scalar, Scalar (width, height) | Nothing | Sets the browsers internal render size. Any display will scale the texture up/down as needed. |\n| SetControlReference Arma 3 v2.24 | Control | Nothing | Sets the control to be referenced by CT_CONTROL_REF control. |","syntaxes":[{"syntax":"control ctrlWebBrowserAction [Action, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"Action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"Action: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[Action, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctrlWebBrowserAction [\"OpenDataAsURL\", loadFile \"example.html\"];\n```","code":["_control ctrlWebBrowserAction [\"OpenDataAsURL\", loadFile \"example.html\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlURL","menuSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.20","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctRowControls","operator":null,"title":"ctRowControls","type":"command","url":"https://community.bistudio.com/wiki/ctRowControls","revid":377175,"updated":"2026-01-01T10:46:47Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns array of controls on the row with the given index.","syntaxes":[{"syntax":"control ctRowControls index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Array of Controls","types":["Array","Control"],"description":null,"text":"Array of Controls"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_array = _control ctRowControls 0;\n```","code":["_array = _control ctRowControls 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctRowCount","operator":null,"title":"ctRowCount","type":"command","url":"https://community.bistudio.com/wiki/ctRowCount","revid":309962,"updated":"2022-05-05T12:17:01Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns number of rows (headers not included) in the RscControlsTable.","syntaxes":[{"syntax":"ctRowCount control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nctRowCount _control;\n```","code":["ctRowCount _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddHeader","ctAddRow","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctSetCurSel","operator":null,"title":"ctSetCurSel","type":"command","url":"https://community.bistudio.com/wiki/ctSetCurSel","revid":310076,"updated":"2022-05-05T12:25:08Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Selects the line with the given index. Will take only rows, but not headers into account. -1 deselects all. Returns Nothing.","syntaxes":[{"syntax":"control ctSetCurSel index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_control ctSetCurSel 0;\n```","code":["_control ctSetCurSel 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctSetData","operator":null,"title":"ctSetData","type":"command","url":"https://community.bistudio.com/wiki/ctSetData","revid":310914,"updated":"2022-05-07T20:34:41Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Associates metadata (string) with the row determined by the index. Returns Nothing.","syntaxes":[{"syntax":"ctrl ctSetData [index, data]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":"the respective control","types":["Control"],"since":null,"text":"ctrl: Control - the respective control"},{"name":"index","type":"Number","optional":false,"default":null,"description":"the row index","types":["Number"],"since":null,"text":"index: Number - the row index"},{"name":"data","type":"String","optional":false,"default":null,"description":"the data to set","types":["String"],"since":null,"text":"data: String - the data to set"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[index, data]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctSetData [0, \"Test\"];\n```","code":["_control ctSetData [0, \"Test\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctValue","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctSetHeaderTemplate","operator":null,"title":"ctSetHeaderTemplate","type":"command","url":"https://community.bistudio.com/wiki/ctSetHeaderTemplate","revid":310130,"updated":"2022-05-05T12:25:42Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Takes config path to the new header template. Clears the whole RscControlsTable and sets the new header template.","syntaxes":[{"syntax":"control ctSetHeaderTemplate config","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_control ctSetHeaderTemplate _configPath;\n```","code":["_control ctSetHeaderTemplate _configPath;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetCurSel","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctSetRowTemplate","operator":null,"title":"ctSetRowTemplate","type":"command","url":"https://community.bistudio.com/wiki/ctSetRowTemplate","revid":310121,"updated":"2022-05-05T12:25:35Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Takes config path to the new row template. Clears the whole RscControlsTable and sets the new row template (Deleting all rows and headers is easier to implement than replacing the rows and filling them with new data. IDCs could overflow etc.).","syntaxes":[{"syntax":"control ctSetRowTemplate config","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_control ctSetRowTemplate _configPath;\n```","code":["_control ctSetRowTemplate _configPath;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetCurSel","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"ctSetValue","operator":null,"title":"ctSetValue","type":"command","url":"https://community.bistudio.com/wiki/ctSetValue","revid":310049,"updated":"2022-05-05T12:23:39Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Associates metadata (number) with the row determined by the index. Returns Nothing.","syntaxes":[{"syntax":"control ctSetValue [index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, value]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control ctSetValue [0, 23];\n```","code":["_control ctSetValue [0, 23];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetCurSel","ctValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"ctValue","operator":null,"title":"ctValue","type":"command","url":"https://community.bistudio.com/wiki/ctValue","revid":310913,"updated":"2022-05-07T20:33:32Z","groups":["GUI Control - Controls Table"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns metadata (number) associated with a particular row of RscControlsTable.","syntaxes":[{"syntax":"control ctValue index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_number = _control ctValue 0;\n```","code":["_number = _control ctValue 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctAddRow","ctAddHeader","ctClear","ctCurSel","ctSetCurSel","ctRowControls","ctHeaderControls","ctRowCount","ctHeaderCount","ctSetValue","ctSetData","ctData","ctFindRowHeader","ctFindHeaderRows","ctRemoveRows","ctRemoveHeaders","ctSetRowTemplate","ctSetHeaderTemplate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Controls Table","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"curatorAddons","operator":null,"title":"curatorAddons","type":"command","url":"https://community.bistudio.com/wiki/curatorAddons","revid":377174,"updated":"2026-01-01T10:46:28Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of addons allowed to given curator. The addon names are not guaranteed to be all lower case","syntaxes":[{"syntax":"curatorAddons curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _addons = curatorAddons myCurator;\n```","code":["private _addons = curatorAddons myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorAddons","removeCuratorAddons","removeAllCuratorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorCamera","operator":null,"title":"curatorCamera","type":"command","url":"https://community.bistudio.com/wiki/curatorCamera","revid":310772,"updated":"2022-05-07T20:21:44Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns curator camera object.","syntaxes":[{"syntax":"curatorCamera","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_camCurator = curatorCamera;\n```","code":["_camCurator = curatorCamera;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorCameraArea","operator":null,"title":"curatorCameraArea","type":"command","url":"https://community.bistudio.com/wiki/curatorCameraArea","revid":377883,"updated":"2026-01-04T16:25:20Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all curator camera areas.","syntaxes":[{"syntax":"curatorCameraArea curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Array with [cameraAreaID, position, radius]","types":["Array"],"description":"cameraAreaID: Number - position: Position - radius: Number","text":"Array with [cameraAreaID, position, radius]\n- cameraAreaID: Number\n- position: Position\n- radius: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\n_camArea = curatorCameraArea myCurator; // [[8052,[4027.36,4024.89,0],250]]\n```","code":["_camArea = curatorCameraArea myCurator; // [[8052,[4027.36,4024.89,0],250]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorCameraArea","removeCuratorCameraArea","removeAllCuratorCameraAreas"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorCameraAreaCeiling","operator":null,"title":"curatorCameraAreaCeiling","type":"command","url":"https://community.bistudio.com/wiki/curatorCameraAreaCeiling","revid":348441,"updated":"2023-11-08T13:00:15Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ceiling height for curator camera.","syntaxes":[{"syntax":"curatorCameraAreaCeiling curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _height = curatorCameraAreaCeiling BIS_curatorUnit;\n```","code":["private _height = curatorCameraAreaCeiling BIS_curatorUnit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorCoef","operator":null,"title":"curatorCoef","type":"command","url":"https://community.bistudio.com/wiki/curatorCoef","revid":348299,"updated":"2023-11-08T12:59:35Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current coeficient setting.","syntaxes":[{"syntax":"curatorObj curatorCoef action","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\ncuratorModule curatorCoef \"Place\";\n```","code":["curatorModule curatorCoef \"Place\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorEditableObjects","operator":null,"title":"curatorEditableObjects","type":"command","url":"https://community.bistudio.com/wiki/curatorEditableObjects","revid":377173,"updated":"2026-01-01T10:46:13Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all editable objects which belong to a curator.","syntaxes":[{"syntax":"curatorEditableObjects curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\n_objects = curatorEditableObjects myCurator;\n```","code":["_objects = curatorEditableObjects myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","curatorMouseOver","addCuratorEditableObjects","removeCuratorEditableObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorEditingArea","operator":null,"title":"curatorEditingArea","type":"command","url":"https://community.bistudio.com/wiki/curatorEditingArea","revid":348379,"updated":"2023-11-08T12:59:58Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all curator editing areas.","syntaxes":[{"syntax":"curatorEditingArea curator","since":null,"effect":null,"exec":null,"params":[{"name":"curator","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curator: Object - curator module."}],"returns":{"type":"Array of arrays in format: [ID, PositionAGL, radius]","types":["Array","PositionAGL"],"description":null,"text":"Array of arrays in format: [ID, PositionAGL, radius]"},"form":"unary","operator":null,"left":null,"right":{"text":"curator","types":["Object"]}}],"examples":[{"text":"```sqf\n_editingAreas = curatorEditingArea myCurator;\n```","code":["_editingAreas = curatorEditingArea myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorEditingArea","removeCuratorEditingArea","removeAllCuratorEditingAreas"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorEditingAreaType","operator":null,"title":"curatorEditingAreaType","type":"command","url":"https://community.bistudio.com/wiki/curatorEditingAreaType","revid":310854,"updated":"2022-05-07T20:24:08Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns type of edit areas assigned to curator (blacklist/whitelist).","syntaxes":[{"syntax":"curatorEditingAreaType curator","since":null,"effect":null,"exec":null,"params":[{"name":"curator","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"curator: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"curator","types":["Object"]}}],"examples":[{"text":"```sqf\n_isBlacklist = curatorEditingAreaType _curator;\n```","code":["_isBlacklist = curatorEditingAreaType _curator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_addCuratorAreaFromTrigger","removeCuratorEditingArea","removeAllCuratorEditingAreas","curatorEditingArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorMouseOver","operator":null,"title":"curatorMouseOver","type":"command","url":"https://community.bistudio.com/wiki/curatorMouseOver","revid":318936,"updated":"2022-05-13T09:22:04Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns Curator Editable Object under curator mouse pointer.","syntaxes":[{"syntax":"curatorMouseOver","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"[] - when not in curator mode - [\"\"] - if no curator editable object under the pointer in curator mode - [typeName, Curator Editable Object] - if there is curator editable object under the pointer in curator mode","text":"Array\n- [] - when not in curator mode\n- [\"\"] - if no curator editable object under the pointer in curator mode\n- [typeName, Curator Editable Object] - if there is curator editable object under the pointer in curator mode"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_mouseOver = curatorMouseOver; // Possible return value: [\"OBJECT\", 3594ab00# 164218: apc_wheeled_01_cannon_f.p3d]\n```","code":["_mouseOver = curatorMouseOver; // Possible return value: [\"OBJECT\", 3594ab00# 164218: apc_wheeled_01_cannon_f.p3d]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","curatorEditableObjects","curatorSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorPoints","operator":null,"title":"curatorPoints","type":"command","url":"https://community.bistudio.com/wiki/curatorPoints","revid":376976,"updated":"2026-01-01T06:06:14Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns number of points that curator have.","syntaxes":[{"syntax":"curatorPoints curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\n_points = curatorPoints myCurator;\n```","code":["_points = curatorPoints myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorPoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorRegisteredObjects","operator":null,"title":"curatorRegisteredObjects","type":"command","url":"https://community.bistudio.com/wiki/curatorRegisteredObjects","revid":377172,"updated":"2026-01-01T10:45:58Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all objects that has curator registered and their settings.","syntaxes":[{"syntax":"curatorRegisteredObjects curator","since":null,"effect":null,"exec":null,"params":[{"name":"curator","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curator: Object - curator module"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"curator","types":["Object"]}}],"examples":[{"text":"```sqf\ncuratorRegisteredObjects _curatorModule;\n```","code":["curatorRegisteredObjects _curatorModule;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorSelected","operator":null,"title":"curatorSelected","type":"command","url":"https://community.bistudio.com/wiki/curatorSelected","revid":377660,"updated":"2026-01-02T09:02:11Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of all curator selected items.","syntaxes":[{"syntax":"curatorSelected","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [objects, groups, waypoints, markers]","types":["Array"],"description":"objects: Array of Objects - groups: Array of Groups - waypoints: Waypoint - markers: Array of Strings","text":"Array with [objects, groups, waypoints, markers]\n- objects: Array of Objects\n- groups: Array of Groups\n- waypoints: Waypoint\n- markers: Array of Strings"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_selectedItems = curatorSelected;\n```","code":["_selectedItems = curatorSelected;"]},{"text":"```sqf\ncuratorSelected params [\"_selObjects\", \"_selGroups\", \"_selWaypoints\", \"_selMarkers\"];\n```","code":["curatorSelected params [\"_selObjects\", \"_selGroups\", \"_selWaypoints\", \"_selMarkers\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["curatorMouseOver","setCuratorSelected","addCuratorSelected","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"curatorSelectionPreset","operator":null,"title":"curatorSelectionPreset","type":"command","url":"https://community.bistudio.com/wiki/curatorSelectionPreset","revid":347229,"updated":"2023-09-05T17:11:28Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of all objects stored in the given selection preset.","syntaxes":[{"syntax":"curatorSelectionPreset numkey","since":null,"effect":null,"exec":null,"params":[{"name":"numkey","type":"Number","optional":false,"default":null,"description":"number key under which the selection preset is saved","types":["Number"],"since":null,"text":"numkey: Number - number key under which the selection preset is saved"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"objects saved in the selection preset","text":"Array of Objects - objects saved in the selection preset"},"form":"unary","operator":null,"left":null,"right":{"text":"numkey","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _savedItems = curatorSelectionPreset 1;\n```","code":["private _savedItems = curatorSelectionPreset 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadCuratorSelectionPreset","setCuratorSelectionPreset","curatorSelected","setCuratorSelected","addCuratorSelected","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"curatorWaypointCost","operator":null,"title":"curatorWaypointCost","type":"command","url":"https://community.bistudio.com/wiki/curatorWaypointCost","revid":353723,"updated":"2024-03-21T19:38:08Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return current price for placing waypoints (curator specific).","syntaxes":[{"syntax":"curatorWaypointCost curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nvar_wpcost = curatorWaypointCost bis_curator;\n```","code":["var_wpcost = curatorWaypointCost bis_curator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","curatorPoints","addCuratorPoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"current3DENOperation","operator":null,"title":"current3DENOperation","type":"command","url":"https://community.bistudio.com/wiki/current3DENOperation","revid":348917,"updated":"2023-11-08T14:44:04Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the currently performed editing operation in Eden Editor.","syntaxes":[{"syntax":"current3DENOperation","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":"operation name. Can be: - `\"\"` (no operation) - `\"CreateObject\"` - `\"CreateMarker\"` - `\"CreateTrigger\"` - `\"MoveItems\"` - `\"RotateItems\"` - `\"ScaleItems\"` - `\"SyncWith\"` - `\"GroupWith\"` - `\"SetTriggerOwner\"` - `\"AddRandomStart\"`","text":"String - operation name. Can be:\n- `\"\"` (no operation)\n- `\"CreateObject\"`\n- `\"CreateMarker\"`\n- `\"CreateTrigger\"`\n- `\"MoveItems\"`\n- `\"RotateItems\"`\n- `\"ScaleItems\"`\n- `\"SyncWith\"`\n- `\"GroupWith\"`\n- `\"SetTriggerOwner\"`\n- `\"AddRandomStart\"`"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (current3DENOperation == \"MoveItems\") then { hint \"Moving things are we\"; };\n```","code":["if (current3DENOperation == \"MoveItems\") then { hint \"Moving things are we\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["do3DENAction","get3DENActionState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"currentChannel","operator":null,"title":"currentChannel","type":"command","url":"https://community.bistudio.com/wiki/currentChannel","revid":376817,"updated":"2025-11-21T20:34:59Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns currently selected user chat channel on the UI (selected with <kbd><</kbd> and <kbd>></kbd> in multiplayer).\n\n| channel ID number correspondence |  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| N/A | Global | Side | Command | Group | Vehicle | Direct | Custom1 | .. | Custom10 | Arma 3 v2.22 Custom11 | .. | Custom50 |\n| -1 | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 15 | 26 | 65 |  |  |\n\nFor Custom Radio, see radioChannelCreate.","syntaxes":[{"syntax":"currentChannel","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"channel ID (see BIS_fnc_channelNumToRadioChannelID, BIS_fnc_radioChannelIDToChannelNum)","text":"Number - channel ID (see BIS_fnc_channelNumToRadioChannelID, BIS_fnc_radioChannelIDToChannelNum)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_selected = currentChannel; // 3 for the Group channel\n```","code":["_selected = currentChannel; // 3 for the Group channel"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCurrentChannel","getPlayerChannel","enableChannel","channelEnabled","radioChannelCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"currentCommand","operator":null,"title":"currentCommand","type":"command","url":"https://community.bistudio.com/wiki/currentCommand","revid":318985,"updated":"2022-05-13T09:22:08Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current command type (empty string when no command) for the commander of given vehicle (or for a given soldier). Returned value can be one of:\n- \"WAIT\"\n- \"ATTACK\"\n- \"HIDE\"\n- \"MOVE\"\n- \"HEAL\"\n- \"REPAIR\"\n- \"REFUEL\"\n- \"REARM\"\n- \"SUPPORT\"\n- \"JOIN\"\n- \"GET IN\"\n- \"FIRE\"\n- \"GET OUT\"\n- \"STOP\"\n- \"EXPECT\"\n- \"ACTION\"\n- \"ATTACKFIRE\"\n- \"Suppress\"","syntaxes":[{"syntax":"currentCommand vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_command = currentCommand player;\n```","code":["_command = currentCommand player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFire","commandMove","commandSuppressiveFire","join"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentMagazine","operator":null,"title":"currentMagazine","type":"command","url":"https://community.bistudio.com/wiki/currentMagazine","revid":364070,"updated":"2024-05-03T19:32:45Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns class name of currently loaded vehicle's / unit's magazine.","syntaxes":[{"syntax":"currentMagazine vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_magazineClass = currentMagazine player;//Example: \"30Rnd_545x39_AK\"\n```","code":["_magazineClass = currentMagazine player;//Example: \"30Rnd_545x39_AK\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazines","currentMagazineDetail","currentWeapon","currentMuzzle","currentThrowable","currentVisionMode","currentWeaponMode","currentZeroing","magazinesTurret","weaponsTurret"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentMagazineDetail","operator":null,"title":"currentMagazineDetail","type":"command","url":"https://community.bistudio.com/wiki/currentMagazineDetail","revid":369313,"updated":"2024-09-03T18:42:56Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns description of vehicle's currently loaded magazine, its ammo count (current/default) and its id.","syntaxes":[{"syntax":"currentMagazineDetail object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"object: Object - unit or vehicle"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_currentMagazineDetail = currentMagazineDetail player; // \"6.5mm 30Rnd STANAG Mag(30/30)[id:0]\"\n```","code":["_currentMagazineDetail = currentMagazineDetail player; // \"6.5mm 30Rnd STANAG Mag(30/30)[id:0]\""]},{"text":"```sqf\n_currentMagazineDetail = currentMagazineDetail Mi_48; // \"30mm HE Shells(250/250)[id:21]\n```","code":["_currentMagazineDetail = currentMagazineDetail Mi_48; // \"30mm HE Shells(250/250)[id:21]"]},{"text":"```sqf\n_cmd = currentMagazineDetail player; // \"9mm 16Rnd Mag(13/16)[id/cr:10000011/0]\"\n_cmd splitString \"([ ]/:)\"; // [\"9mm\",\"16Rnd\",\"Mag\",\"13\",\"16\",\"id\",\"cr\",\"10000011\",\"0\"]\n```","code":["_cmd = currentMagazineDetail player; // \"9mm 16Rnd Mag(13/16)[id/cr:10000011/0]\"\n_cmd splitString \"([ ]/:)\"; // [\"9mm\",\"16Rnd\",\"Mag\",\"13\",\"16\",\"id\",\"cr\",\"10000011\",\"0\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesDetail","currentMagazine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"currentMagazineDetailTurret","operator":null,"title":"currentMagazineDetailTurret","type":"command","url":"https://community.bistudio.com/wiki/currentMagazineDetailTurret","revid":377470,"updated":"2026-01-02T06:48:37Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the class name of currently used magazine on specified turret. Use turret path [-1] for driver's turret. Note that a turret is not loaded until unit enters it, so this command will return \"\".","syntaxes":[{"syntax":"vehicle currentMagazineDetailTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_magazineDetail = MBT_Kuma currentMagazineDetailTurret [0];\n```","code":["_magazineDetail = MBT_Kuma currentMagazineDetailTurret [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazineTurret","currentWeaponTurret","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"currentMagazineTurret","operator":null,"title":"currentMagazineTurret","type":"command","url":"https://community.bistudio.com/wiki/currentMagazineTurret","revid":377500,"updated":"2026-01-02T06:49:28Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of the type of the currently using magazine on specified turret. Use turret path [-1] for driver's turret. Note that a turret is not loaded until unit enters it, so this command will return \"\".","syntaxes":[{"syntax":"vehicle currentMagazineTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_magazine = MBT_Kuma currentMagazineTurret [0];\n```","code":["_magazine = MBT_Kuma currentMagazineTurret [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazineDetailTurret","currentWeaponTurret","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"currentMuzzle","operator":null,"title":"currentMuzzle","type":"command","url":"https://community.bistudio.com/wiki/currentMuzzle","revid":321269,"updated":"2022-05-13T19:08:05Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a unit's current weapon muzzle. Does not work on vehicles.","syntaxes":[{"syntax":"currentMuzzle unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"current muzzle > [!IMPORTANT] > In earlier games/versions, this command could return a Number (`0`) if unit was in a vehicle. > Use the following to circumvent the issue: > > ```sqf > _muzzle = weaponState unit select 1; > ```","text":"String - current muzzle\n\n> [!IMPORTANT]\n> In earlier games/versions, this command could return a Number (`0`) if *unit* was in a vehicle.\n> Use the following to circumvent the issue:\n>\n> ```sqf\n> _muzzle = weaponState unit select 1;\n> ```"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_muzzle = currentMuzzle player;\n```","code":["_muzzle = currentMuzzle player;"]},{"text":"```sqf\n_muzzle = currentMuzzle (gunner (vehicle player));\n```","code":["_muzzle = currentMuzzle (gunner (vehicle player));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentWeapon","currentMagazine","currentThrowable"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentNamespace","operator":null,"title":"currentNamespace","type":"command","url":"https://community.bistudio.com/wiki/currentNamespace","revid":339095,"updated":"2023-04-26T10:54:14Z","groups":["Namespaces","System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current global namespace the script runs in.\n\n> [!NOTE]\n> Since Arma 3 v2.00, Namespaces can be compared with == and != operators in addition to isEqualTo.","syntaxes":[{"syntax":"currentNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":"one of: - missionNamespace - uiNamespace - parsingNamespace - profileNamespace - localNamespace","text":"Namespace - one of:\n- missionNamespace\n- uiNamespace\n- parsingNamespace\n- profileNamespace\n- localNamespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (currentNamespace isEqualTo uiNamespace) then { hint \"This is uiNamespace\" };\n```","code":["if (currentNamespace isEqualTo uiNamespace) then { hint \"This is uiNamespace\" };"]},{"text":"```sqf\nprivate _fn_getCurrentNamespaceName = {\n    if (currentNamespace isEqualTo missionNamespace) exitWith { \"missionNamespace\" };\n    if (currentNamespace isEqualTo parsingNamespace) exitWith { \"parsingNamespace\" };\n    if (currentNamespace isEqualTo profileNamespace) exitWith { \"profileNamespace\" };\n    if (currentNamespace isEqualTo uiNamespace) exitWith { \"uiNamespace\" };\n    \"error\";\n};\n\nwith profileNamespace do {\n    systemChat call _fn_getCurrentNamespaceName;    // profileNamespace\n};\n\nsystemChat call _fn_getCurrentNamespaceName;        // missionNamespace\n\nwith uiNamespace do {\n    systemChat call _fn_getCurrentNamespaceName;    // uiNamespace\n};\n```","code":["private _fn_getCurrentNamespaceName = {\n\tif (currentNamespace isEqualTo missionNamespace) exitWith { \"missionNamespace\" };\n\tif (currentNamespace isEqualTo parsingNamespace) exitWith { \"parsingNamespace\" };\n\tif (currentNamespace isEqualTo profileNamespace) exitWith { \"profileNamespace\" };\n\tif (currentNamespace isEqualTo uiNamespace) exitWith { \"uiNamespace\" };\n\t\"error\";\n};\n\nwith profileNamespace do {\n\tsystemChat call _fn_getCurrentNamespaceName;\t// profileNamespace\n};\n\nsystemChat call _fn_getCurrentNamespaceName;\t\t// missionNamespace\n\nwith uiNamespace do {\n\tsystemChat call _fn_getCurrentNamespaceName;\t// uiNamespace\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","uiNamespace","parsingNamespace","profileNamespace","localNamespace","allVariables","with","ArmA: Editing"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: System","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"currentPilot","operator":null,"title":"currentPilot","type":"command","url":"https://community.bistudio.com/wiki/currentPilot","revid":309146,"updated":"2022-05-03T14:07:26Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the person piloting the vehicle. If co-pilot is piloting, co-pilot is returned. If you need current pilot of a UAV or UGV, see UAVControl command.","syntaxes":[{"syntax":"currentPilot vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":"piloting unit or objNull","text":"Object - piloting unit or objNull"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (currentPilot _vehicle != driver _vehicle) then\n{\n    hint \"The pilot is not piloting!\";\n};\n```","code":["if (currentPilot _vehicle != driver _vehicle) then\n{\n\thint \"The pilot is not piloting!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["driver","gunner","commander","effectiveCommander","turretUnit","UAVControl","enableCopilot"],"notes":[{"user":"Killzone_Kid","date":"2019-08-20T23:15:00Z","text":"To return co-pilot units:\n\n```sqf\nprivate _fnc_getCoPilots = \n{\n    private _copilotTurrets = allTurrets _this select { getNumber ([_this, _x] call BIS_fnc_turretConfig >> \"isCopilot\") > 0 };\n    private _copilots = _copilotTurrets apply { _this turretUnit _x };\n    _copilots;\n};\n\nhint str (heli call _fnc_getCoPilots);\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"currentTask","operator":null,"title":"currentTask","type":"command","url":"https://community.bistudio.com/wiki/currentTask","revid":318828,"updated":"2022-05-13T09:21:54Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return current task of given person.","syntaxes":[{"syntax":"currentTask person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Task","types":["Task"],"description":null,"text":"Task"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_currTask = currentTask player;\n```","code":["_currTask = currentTask player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskNull","createSimpleTask","simpleTasks","taskCompleted"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentTasks","operator":null,"title":"currentTasks","type":"command","url":"https://community.bistudio.com/wiki/currentTasks","revid":377084,"updated":"2026-01-01T09:42:58Z","groups":["Briefing","Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all uncompleted tasks for the given agent.\ngetVariable could be used on Task to get the following special local variables from the task:\n- `\"_this\"` Team Member - the teamMember agent the task is assigned to\n- `\"_taskType\"` String - the name of the task (see registeredTasks)\n- `\"_thisCreated\"` Number - 1 or 0\n- `\"_thisRunning\"` Number - 1 or 0\n- `\"_totalCreated\"` Number - total number of tasks\n- `\"_totalRunning\"` Number - total number of running tasks\n- `\"_task\"`Task - often null","syntaxes":[{"syntax":"currentTasks teamMember","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":"teamMember agent","types":["Team Member"],"since":null,"text":"teamMember: Team Member - teamMember agent"}],"returns":{"type":"Array of Tasks","types":["Array","Task"],"description":null,"text":"Array of Tasks"},"form":"unary","operator":null,"left":null,"right":{"text":"teamMember","types":["Team Member"]}}],"examples":[{"text":"```sqf\ncurrentTasks teamMember _agent;\n```","code":["currentTasks teamMember _agent;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskCompleted","registerTask","registeredTasks","unregisterTask","sendTask","createTask"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentThrowable","operator":null,"title":"currentThrowable","type":"command","url":"https://community.bistudio.com/wiki/currentThrowable","revid":377712,"updated":"2026-01-02T09:03:53Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns currently selected throwable (and the muzzle it is loaded into), which will be launched if the user presses <kbd>G</kbd>.","syntaxes":[{"syntax":"currentThrowable unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [magazineName, muzzleName, id, ammoCount]","types":["Array"],"description":"magazineName: String - muzzleName: String - id: Array of Number pairs: [itemWorldID, creatorID] - Arma 3 v2.22 ammoCount: Number - magazine ammo","text":"Array with [magazineName, muzzleName, id, ammoCount]\n- magazineName: String\n- muzzleName: String\n- id: Array of Number pairs: [itemWorldID, creatorID]\n- Arma 3 v2.22 ammoCount: Number - magazine ammo"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ncurrentThrowable player; // [\"SmokeShellGreen\", \"SmokeShellGreenMuzzle\", [1.00002e+007, 0], 1]\n```","code":["currentThrowable player; // [\"SmokeShellGreen\", \"SmokeShellGreenMuzzle\", [1.00002e+007, 0], 1]"]},{"text":"```sqf\n_ct = currentThrowable player;                // [\"HandGrenade\", \"HandGrenadeMuzzle\", [1e+007, 0], 1]\n_id = (_ct select 2 select 0) - 1e7;        // 18\n```","code":["_ct = currentThrowable player;\t\t\t\t// [\"HandGrenade\", \"HandGrenadeMuzzle\", [1e+007, 0], 1]\n_id = (_ct select 2 select 0) - 1e7;\t\t// 18"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectThrowable","currentWeapon","currentMagazine","currentMuzzle","BIS_fnc_isThrowable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"currentVisionMode","operator":null,"title":"currentVisionMode","type":"command","url":"https://community.bistudio.com/wiki/currentVisionMode","revid":378560,"updated":"2026-05-08T13:11:39Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns current vision mode of unit's weapon. Vision mode could be one of:\n- 0 - normal vision\n- 1 - night vision\n- 2 - thermal vision\nAlternative syntaxes additionally return FLIR index (see setCamUseTI) of the thermal vision mode (See also \"VisionModeChanged\" entity event handler)","syntaxes":[{"syntax":"currentVisionMode entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode"}],"returns":{"type":"Number","types":["Number"],"description":"vision mode (0 on error, e.g on objNull)","text":"Number - vision mode (**0** on error, e.g on objNull)"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"currentVisionMode [entity]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode"}],"returns":{"type":"Array format [visionMode, flirIndex] where:","types":["Array"],"description":"visionMode: Number - flirIndex: Number [-1, -1] on error","text":"Array format [visionMode, flirIndex] where:\n- visionMode: Number\n- flirIndex: Number\n[-1, -1] on error"},"form":"unary","operator":null,"left":null,"right":{"text":"[entity]","types":["Array"]}},{"syntax":"vehicle currentVisionMode turretPath","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with vision modes","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with vision modes"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"path to vehicle's turret. Use [-1] for driver turret, [] for default primary gunner turret","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - path to vehicle's turret. Use [-1] for driver turret, [] for default primary gunner turret"}],"returns":{"type":"Array format [visionMode, flirIndex] where:","types":["Array"],"description":"visionMode: Number - flirIndex: Number [-1, -1] on error","text":"Array format [visionMode, flirIndex] where:\n- visionMode: Number\n- flirIndex: Number\n[-1, -1] on error"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}},{"syntax":"unit currentVisionMode weapon","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"soldier","types":["Object"],"since":null,"text":"unit: Object - soldier"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"unit's weapon. Use \"\" for current weapon","types":["String"],"since":null,"text":"weapon: String - unit's weapon. Use \"\" for current weapon"}],"returns":{"type":"Array format [visionMode, flirIndex] where:","types":["Array"],"description":"visionMode: Number - flirIndex: Number [-1, -1] on error","text":"Array format [visionMode, flirIndex] where:\n- visionMode: Number\n- flirIndex: Number\n[-1, -1] on error"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}}],"examples":[{"text":"```sqf\n_visionMode = currentVisionMode gunner _tank;\n```","code":["_visionMode = currentVisionMode gunner _tank;"]},{"text":"```sqf\nif (currentVisionMode player == 1) then\n{\n    hint \"nightvision active\";\n};\n```","code":["if (currentVisionMode player == 1) then\n{\n\thint \"nightvision active\";\n};"]},{"text":"```sqf\nprivate _detailedVisionMode = currentVisionMode [gunner _tank];\n_detailedVisionMode params [\"_mode\", \"_flirIndex\"];\n```","code":["private _detailedVisionMode = currentVisionMode [gunner _tank];\n_detailedVisionMode params [\"_mode\", \"_flirIndex\"];"]},{"text":"```sqf\nprivate _detailedGunnerVisionMode = _tank currentVisionMode [0];\n```","code":["private _detailedGunnerVisionMode = _tank currentVisionMode [0];"]},{"text":"```sqf\nprivate _detailedWeaponVisionMode = player currentVisionMode \"\";\n```","code":["private _detailedWeaponVisionMode = player currentVisionMode \"\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableNVGEquipment","disableTIEquipment","camUseNVG","setCamUseTI","currentMagazine","currentWeapon","currentMuzzle","currentWeaponMode","currentZeroing","magazinesTurret","weaponsTurret"],"notes":[{"user":"AgentRev","date":"2016-04-29T21:31:00Z","text":"> [!CAUTION]\n> This information is **obsolete**. \n\nThe return value is somewhat erratic for UAVs. For example, if you are connected to a UAV, with the turret set to thermal vision and PIP feed enabled, `currentVisionMode gunner _uav` returns 2 when controlling the turret, but returns 0 after releasing control, even thought the PIP feed is still in thermal mode. With nightvision, it will return 1 whether or not you are controlling the turret, but if you switch from 1st to 3rd person before releasing control, then it returns 0 afterwards..."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentWaypoint","operator":null,"title":"currentWaypoint","type":"command","url":"https://community.bistudio.com/wiki/currentWaypoint","revid":378132,"updated":"2026-02-22T20:40:12Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the *index* of the current waypoint (**not** the waypoint in Waypoint Array format).\n\n- To determine the validity of the index, compare it to the waypoints count.\n- If all waypoints are completed, then the index is 1 greater than the last valid index.\n- If there are no waypoints, then the index is 0.\n\nBy default, a group has one already-completed waypoint at their starting position, making the first waypoint number one, not zero.","syntaxes":[{"syntax":"currentWaypoint groupName","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"groupName: Group"}],"returns":{"type":"Number","types":["Number"],"description":"index of the current waypoint","text":"Number - index of the current waypoint"},"form":"unary","operator":null,"left":null,"right":{"text":"groupName","types":["Group"]}}],"examples":[{"text":"```sqf\n_index = currentWaypoint group player;\n```","code":["_index = currentWaypoint group player;"]},{"text":"```sqf\n_waypointFormat = [_group, currentWaypoint _group];\n```","code":["_waypointFormat = [_group, currentWaypoint _group];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setCurrentWaypoint"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentWeapon","operator":null,"title":"currentWeapon","type":"command","url":"https://community.bistudio.com/wiki/currentWeapon","revid":378862,"updated":"2026-07-22T17:08:42Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the name of the currently selected weapon (on the primary turret for vehicles).","syntaxes":[{"syntax":"currentWeapon vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_weaponClass = currentWeapon (vehicle player);//Example: \"M16A2GL\"\n```","code":["_weaponClass = currentWeapon (vehicle player);//Example: \"M16A2GL\""]},{"text":"```sqf\n_weaponClass = currentWeapon player;\n```","code":["_weaponClass = currentWeapon player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazine","currentMuzzle","currentThrowable","currentVisionMode","currentWeaponMode","currentZeroing","magazinesTurret","weaponsTurret","currentWeaponTurret","weaponState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentWeaponMode","operator":null,"title":"currentWeaponMode","type":"command","url":"https://community.bistudio.com/wiki/currentWeaponMode","revid":369197,"updated":"2024-09-03T10:34:48Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current weapon mode of unit's weapon.\n\n> [!WARNING]\n> This command will return 0 Number if given object is a vehicle instead of a person.\n>\n> You can alternatively use \n>\n> ```sqf\n> _muzzle = weaponState player select 2;\n> ```","syntaxes":[{"syntax":"currentWeaponMode gunner","since":null,"effect":null,"exec":null,"params":[{"name":"gunner","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"gunner: Object"}],"returns":{"type":"String","types":["String"],"description":"current mode's classname","text":"String - current mode's classname"},"form":"unary","operator":null,"left":null,"right":{"text":"gunner","types":["Object"]}}],"examples":[{"text":"```sqf\n_weaponMode = currentWeaponMode player;\n```","code":["_weaponMode = currentWeaponMode player;"]},{"text":"```sqf\n_weaponMode = currentWeaponMode gunner vehicle player;\n```","code":["_weaponMode = currentWeaponMode gunner vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ArmA: Actions","currentWeapon"],"notes":[{"user":"Sarogahtyp","date":"2022-07-04T12:48:33Z","text":"To set the firemode of the current weapon of a player, simply use the workaround described by Killzone_Kid in the first note of the forceWeaponFire wiki entry:\n\n```sqf\n_weapon = currentWeapon player;\n_ammo = player ammo _weapon;\nplayer setAmmo [_weapon, 0];\nplayer forceWeaponFire [_weapon, \"FullAuto\"];\nplayer setAmmo [_weapon, _ammo];\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"currentWeaponTurret","operator":null,"title":"currentWeaponTurret","type":"command","url":"https://community.bistudio.com/wiki/currentWeaponTurret","revid":378861,"updated":"2026-07-22T17:03:52Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of the currently selected weapon on specified turret. Use turret path [-1] for driver's turret.","syntaxes":[{"syntax":"vehicle currentWeaponTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_weapon = MBT_Kuma currentWeaponTurret [0];\n```","code":["_weapon = MBT_Kuma currentWeaponTurret [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazineDetailTurret","currentMagazineTurret","addWeaponTurret","removeWeaponTurret","turretLocal","currentWeapon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"currentZeroing","operator":null,"title":"currentZeroing","type":"command","url":"https://community.bistudio.com/wiki/currentZeroing","revid":378508,"updated":"2026-05-03T17:08:03Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns current zeroing.","syntaxes":[{"syntax":"currentZeroing object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit (vehicles are not supported)","types":["Object"],"since":null,"text":"object: Object - unit (vehicles are not supported)"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"object currentZeroing [weaponClass, muzzleClass]","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit (vehicles are not supported)","types":["Object"],"since":null,"text":"object: Object - unit (vehicles are not supported)"},{"name":"weaponClass","type":"String","optional":false,"default":null,"description":"class name of weapon","types":["String"],"since":null,"text":"weaponClass: String - class name of weapon"},{"name":"muzzleClass","type":"String","optional":true,"default":"currently active muzzle or first that is found","description":"muzzle classname","types":["String"],"since":null,"text":"muzzleClass: String - (Optional, default currently active muzzle or first that is found) muzzle classname"}],"returns":{"type":"Array with [distance, zeroingIndex]","types":["Array"],"description":"distance: Number - distance in meters, Since Arma 3 v2.20 supports laser rangefinder value - zeroingIndex: Number - 0 ≙ 50 m, 1 ≙ 100 m, 2 ≙ 150 m, ..., -1 for laser rangefinding","text":"Array with [distance, zeroingIndex]\n- distance: Number - distance in meters, Since Arma 3 v2.20 supports laser rangefinder value\n- zeroingIndex: Number - 0 ≙ 50 m, 1 ≙ 100 m, 2 ≙ 150 m, ..., -1 for laser rangefinding"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weaponClass, muzzleClass]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _zeroing = currentZeroing player;\n```","code":["private _zeroing = currentZeroing player;"]},{"text":"```sqf\n(player currentZeroing [\"arifle_MX_GL_F\", \"GL_3GL_F\"]) params [\"_distance\", \"_zeroingIndex\"];\n```","code":["(player currentZeroing [\"arifle_MX_GL_F\", \"GL_3GL_F\"]) params [\"_distance\", \"_zeroingIndex\"];"]},{"text":"```sqf\nprivate _zeroing = currentZeroing myVehicle; // does not work\nprivate _zeroing = currentZeroing gunner myVehicle; // works\n```","code":["private _zeroing = currentZeroing myVehicle; // does not work\nprivate _zeroing = currentZeroing gunner myVehicle; // works"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWeaponZeroing"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cursorObject","operator":null,"title":"cursorObject","type":"command","url":"https://community.bistudio.com/wiki/cursorObject","revid":341004,"updated":"2023-05-13T22:06:20Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the object under cursor. This command is quite different from cursorTarget as it is more precise in determining the boundaries of the pointed at object and can detect a larger variety of objects including map objects and trees.","syntaxes":[{"syntax":"cursorObject","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str [getModelInfo cursorObject, typeOf cursorObject];\n```","code":["hint str [getModelInfo cursorObject, typeOf cursorObject];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCursorObjectParams","cursorTarget","lineIntersects","lineIntersectsWith","lineIntersectsObjs","lineIntersectsSurfaces","intersect","checkVisibility"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"cursorTarget","operator":null,"title":"cursorTarget","type":"command","url":"https://community.bistudio.com/wiki/cursorTarget","revid":373164,"updated":"2025-04-08T21:03:11Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the target pointed at by the player (usually with cross-hairs). The target has to be known to the player to some degree (knowsAbout > 0). If target is completely unknown, command returns objNull.\n\nA valid target could belong to an enemy or a friendly side. Buildings are normally known to player and so are valid targets. Try nearTargets to see what else is considered a target.\nWhile friendly targets are usually known to the player, enemy targets can be totally unknown, especially if \"auto-spotting\" (or sometimes called \"auto-reporting\") is switched off. To check if auto-spotting is enabled: `difficultyEnabled \"autospot\"`.\n\ncursorTarget also returns locked target for the duration of the lock even if there is another target under the cursor. As soon as missile is fired, cursorTarget switches to current known target under cursor or objNull.\nTargeting (<kbd>T</kbd> in Arma 3) works regardless of the state of \"auto-spotting\".\n\nAdding a target to the known list could be done with reveal command. When auto-spotting is enabled, zooming on the enemy target with cross-hairs usually reveals the target.\nAs friendly targets are always known, zooming on friendly target could improve knowsAbout value.\n\nSide Relations can also influence target knowledge. For example east target is unknown target for civilian, but making them friends with setFriend instantly improves civilian knowledge of the east.","syntaxes":[{"syntax":"cursorTarget","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nalive cursorTarget;\n```","code":["alive cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cursorObject","getCursorObjectParams","laserTarget","nearTargets","knowsAbout","reveal","lineIntersects","lineIntersectsWith","lineIntersectsObjs","lineIntersectsSurfaces","intersect","checkVisibility"],"notes":[{"user":"FRL Myke","date":"2011-02-18T00:28:00Z","text":"If the player is in a vehicle and a lockable weapon is selected and a target is locked, the locked target will be returned, regardless if it is in sight or not."},{"user":".kju","date":"2011-03-11T12:48:00Z","text":"Addition to Myke's note:\nIt also works for infantry with launchers that canLock, like Javelin or AA.\nOnly the lock cursor must be visible on the target - not a full lock necessarily."},{"user":"Lou Montana","date":"2009-07-11T12:13:00Z","text":"- Player must know about what he is pointing to for this command to return something other than <NULL-OBJECT>\n- This command doesn't work through building windows\n- This recognition doesn't work with every object : soldiers, vehicles, big houses are ok, but not trees, plants, road signs or others little things"},{"user":"Killzone_Kid","date":"2013-08-23T22:16:00Z","text":"To add to User:Lou Montana's note, use reveal command on the object you want to be detected with cursorTarget when pointing at it.\nWithout it, distant units are most likely to return objNull even if you shoot and hit them.\n\nUnits that have been previously subjected to enableSimulation false; or enableSimulationGlobal false; may stay unrecognised for a long time even after simulation was re-enabled, returning objNull as cursorTarget.\nForce revealing units with reveal command usually solves the problem. For example:\n\n```sqf\n{ player reveal _x } forEach allUnits;\n```"},{"user":"DreadedEntity","date":"2014-12-03T18:40:00Z","text":"cursorTarget seems to change when your cursor enters an object's boundingBox.\nBecause of this, if the player is **inside** the boundingBox, the object will always be the current cursorTarget if the player is not looking at another object, although sometimes the object will remain the cursorTarget even if the player does."},{"user":"Pierre MGI","date":"2015-04-21T03:53:00Z","text":"cursorTarget will not return enemy units, even very close, if \"autoreport\" is disabled in game difficulty settings, and if player is alone.\nHowever, when enemy units open fire on player, the cursortarget becomes functional on these units. If player is in a group, cursortarget is also functional (report by other units)."},{"user":"Pierre MGI","date":"2016-02-05T20:38:00Z","text":"CursorTarget will return a <Null_Object> for all of thus which have a disabled simulation (_object enableSimulation false)."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"customChat","operator":null,"title":"customChat","type":"command","url":"https://community.bistudio.com/wiki/customChat","revid":376773,"updated":"2025-11-17T00:04:58Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the chat message to the custom radio channel. The radio channel needs to be created on the server before hand, with radioChannelCreate command. Use clearRadio to clear chat history\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.","syntaxes":[{"syntax":"unit customChat [customChannelID, message]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"sender","types":["Object"],"since":null,"text":"unit: Object - sender"},{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"Custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - Custom channel ID returned by radioChannelCreate command"},{"name":"message","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"message: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[customChannelID, message]","types":["Array"]}}],"examples":[{"text":"```sqf\n_unit customChat [1, \"Hi, I am a custom chat message\"];\n```","code":["_unit customChat [1, \"Hi, I am a custom chat message\"];"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","groupChat","vehicleChat","commandChat","sideChat","systemChat","radioChannelCreate","customRadio"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"customRadio","operator":null,"title":"customRadio","type":"command","url":"https://community.bistudio.com/wiki/customRadio","revid":376763,"updated":"2025-11-16T23:13:01Z","groups":["Radio and Chat","Sounds","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the message to the custom radio channel. The message is defined in the description.ext file or radio protocol.\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item to the radio inventory slot (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit customRadio [customChannelID, message]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"sender","types":["Object"],"since":null,"text":"unit: Object - sender"},{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate command"},{"name":"message","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"message: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[customChannelID, message]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne customRadio [1, \"WordEnemy\"];\n```","code":["_soldierOne customRadio [1, \"WordEnemy\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelCreate","customChat","sideRadio","groupRadio","vehicleRadio","globalRadio","directSay"],"notes":[{"user":"Killzone_Kid","date":"2016-12-03T21:35:00Z","text":"To transmit user custom sounds (see Multiplayer_Custom_Sounds_Tutorial), prefix the full filename including file extension with #. For example if there is a custom user sound file called `MySound.ogg`, to play it on the radio use:\n\n```sqf\nplayer customRadio [1, \"#MySound.ogg\"];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"customWaypointPosition","operator":null,"title":"customWaypointPosition","type":"command","url":"https://community.bistudio.com/wiki/customWaypointPosition","revid":377508,"updated":"2026-01-02T06:50:11Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns player's custom waypoint (<kbd>LShift</kbd>+<kbd>LMB</kbd>) position.","syntaxes":[{"syntax":"customWaypointPosition","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Position"],"description":null,"text":"Position as [x,y,0], or empty array [] if the waypoint does not exist"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (customWaypointPosition isNotEqualTo []) then\n{\n    hint format [\"You are %1m away from your custom waypoint.\", round (player distance customWaypointPosition)];\n};\n```","code":["if (customWaypointPosition isNotEqualTo []) then\n{\n\thint format [\"You are %1m away from your custom waypoint.\", round (player distance customWaypointPosition)];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMapMarkers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"cutFadeOut","operator":null,"title":"cutFadeOut","type":"command","url":"https://community.bistudio.com/wiki/cutFadeOut","revid":369415,"updated":"2024-09-03T18:46:04Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Terminates the effect in the given layer by fading it out according to the given duration. If named layer is used and it doesn't exist, it will be allocated. For title layer see titleFadeOut.\n\n> [!NOTE]\n> **Arma 3:** For greater efficiency and ease of moddability, it is recommended to use named layers.","syntaxes":[{"syntax":"layer cutFadeOut duration","since":null,"effect":null,"exec":null,"params":[{"name":"layer","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"layer: Number"},{"name":"duration","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"duration: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"layer","types":["Number"]},"right":{"text":"duration","types":["Number"]}},{"syntax":"layerName cutFadeOut duration","since":"arma3 1.58","effect":null,"exec":null,"params":[{"name":"layerName","type":"String","optional":false,"default":null,"description":"effect layer name. Layer names are CaSe SeNsItIvE","types":["String"],"since":null,"text":"layerName: String - effect layer name. Layer names are CaSe SeNsItIvE"},{"name":"duration","type":"Number","optional":false,"default":null,"description":"fade out time","types":["Number"],"since":null,"text":"duration: Number - fade out time"}],"returns":{"type":"Number","types":["Number"],"description":"number of the corresponding layer","text":"Number - number of the corresponding layer"},"form":"binary","operator":null,"left":{"text":"layerName","types":["String"]},"right":{"text":"duration","types":["Number"]}}],"examples":[{"text":"```sqf\n0 cutFadeOut 2;\n```","code":["0 cutFadeOut 2;"]},{"text":"```sqf\nprivate _layer = \"layer1\" cutFadeOut 2;\n```","code":["private _layer = \"layer1\" cutFadeOut 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","cutText","cutRsc","cutObj","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"cutObj","operator":null,"title":"cutObj","type":"command","url":"https://community.bistudio.com/wiki/cutObj","revid":348145,"updated":"2023-11-08T11:32:40Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Displays an object defined in the global config in `CfgTitles`.\n\n> [!NOTE]\n> **Arma 3:** For greater efficiency and ease of modability, it is recommended to use named layers with #Syntax 3.","syntaxes":[{"syntax":"cutObj [class, type, speed, showInMap, drawOverHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"the className of the object defined in `configFile >> \"CfgTitles\" >> class`","types":["String"],"since":null,"text":"class: String - the className of the object defined in `configFile >> \"CfgTitles\" >> class`"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values"},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the object under in-game HUD","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the object under in-game HUD"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[class, type, speed, showInMap, drawOverHUD]","types":["Array"]}},{"syntax":"layer cutObj [class, type, speed, showInMap, drawOverHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"layer","type":"Number","optional":false,"default":null,"description":"layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100","types":["Number"],"since":null,"text":"layer: Number - layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100"},{"name":"class","type":"String","optional":false,"default":null,"description":"the className of the object defined in `configFile >> \"CfgTitles\" >> class`","types":["String"],"since":null,"text":"class: String - the className of the object defined in `configFile >> \"CfgTitles\" >> class`"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the object under in-game HUD","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the object under in-game HUD"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"layer","types":["Number"]},"right":{"text":"[class, type, speed, showInMap, drawOverHUD]","types":["Array"]}},{"syntax":"layerName cutObj [class, type, speed, showInMap, drawOverHUD]","since":"arma3 1.58","effect":null,"exec":null,"params":[{"name":"layerName","type":"String","optional":false,"default":null,"description":"layer name on which the effect is shown. Layer names are CaSe SeNsItIvE","types":["String"],"since":null,"text":"layerName: String - layer name on which the effect is shown. Layer names are CaSe SeNsItIvE"},{"name":"class","type":"String","optional":false,"default":null,"description":"the className of the object defined in `configFile >> \"CfgTitles\" >> class`","types":["String"],"since":null,"text":"class: String - the className of the object defined in `configFile >> \"CfgTitles\" >> class`"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values"},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the object under in-game HUD","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the object under in-game HUD"}],"returns":{"type":"Number","types":["Number"],"description":"number of the allocated layer","text":"Number - number of the allocated layer"},"form":"binary","operator":null,"left":{"text":"layerName","types":["String"]},"right":{"text":"[class, type, speed, showInMap, drawOverHUD]","types":["Array"]}}],"examples":[{"text":"```sqf\ncutObj [\"TVSet\", \"PLAIN\"];\ncutObj [\"TVSet\", \"PLAIN\", 2];\n```","code":["cutObj [\"TVSet\", \"PLAIN\"];\ncutObj [\"TVSet\", \"PLAIN\", 2];"]},{"text":"```sqf\n2 cutObj [\"Sphere\", \"PLAIN\"];\n```","code":["2 cutObj [\"Sphere\", \"PLAIN\"];"]},{"text":"```sqf\nprivate _layer = \"layer1\" cutObj [\"BISLogo\", \"PLAIN\"];\n```","code":["private _layer = \"layer1\" cutObj [\"BISLogo\", \"PLAIN\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","titleObj","cutText","cutRsc","cutFadeOut","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":[]},{"name":"cutRsc","operator":null,"title":"cutRsc","type":"command","url":"https://community.bistudio.com/wiki/cutRsc","revid":378028,"updated":"2026-01-24T02:09:18Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Display a resource defined in RscTitles of the mission's Description.ext, the campaign's description.ext or the global config.\n\n> [!NOTE]\n> **Arma 3:** For greater efficiency and ease of modability, it is recommended to use named layers available with String and #Syntax 2.\n\n> [!IMPORTANT]\n> To avoid conflicts with existing layers it is recommended to register a layer with BIS_fnc_rscLayer and to start the name with a TAG:\n>\n> ```sqf\n> (\"TAG_myLayer\" call BIS_fnc_rscLayer) cutRsc [\"myRsc\", \"PLAIN\"];\n> \"TAG_myLayer\" cutRsc [\"myRsc\", \"PLAIN\"];\n> ```","syntaxes":[{"syntax":"cutRsc [class, effect, speed, showInMap, drawOverHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"the class name of the resource. (\"Default\" will remove the current resource.)","types":["String"],"since":null,"text":"class: String - the class name of the resource. (\"Default\" will remove the current resource.)"},{"name":"effect","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"effect: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource.","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource."},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened.","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened."},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the resource under in-game HUD (for example, a binocular effect)","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the resource under in-game HUD (for example, a binocular effect)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[class, effect, speed, showInMap, drawOverHUD]","types":["Array"]}},{"syntax":"layer cutRsc [class, effect, speed, showInMap, drawOverHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"layer","type":"Number or String","optional":false,"default":null,"description":"Number or String\n- Number - layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100\n- String - Arma 3 v1.58 layer name on which the effect is shown. Layer names are **CaSe SeNsItIvE**.","types":["Number","String"],"since":null,"text":"layer: Number or String\n- Number - layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100\n- String - Arma 3 v1.58 layer name on which the effect is shown. Layer names are **CaSe SeNsItIvE**."},{"name":"class","type":"String","optional":false,"default":null,"description":"the class name of the resource. (\"Default\" will remove the current resource.)","types":["String"],"since":null,"text":"class: String - the class name of the resource. (\"Default\" will remove the current resource.)"},{"name":"effect","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"effect: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource.","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource."},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened.","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened."},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the resource under in-game HUD (for example, a binocular effect)","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the resource under in-game HUD (for example, a binocular effect)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"layer","types":["Number","String"]},"right":{"text":"[class, effect, speed, showInMap, drawOverHUD]","types":["Array"]}}],"examples":[{"text":"```sqf\ncutRsc [\"binocular\", \"PLAIN\"];\ncutRsc [\"binocular\", \"PLAIN\", 2];\ncutRsc [\"binocular\", \"PLAIN\", 2, false];\n```","code":["cutRsc [\"binocular\", \"PLAIN\"];\ncutRsc [\"binocular\", \"PLAIN\", 2];\ncutRsc [\"binocular\", \"PLAIN\", 2, false];"]},{"text":"```sqf\n2 cutRsc [\"binocular\", \"PLAIN\", 2];\n```","code":["2 cutRsc [\"binocular\", \"PLAIN\", 2];"]},{"text":"```sqf\n\"layer1\" cutRsc [\"binocular\", \"PLAIN\", 2];\n```","code":["\"layer1\" cutRsc [\"binocular\", \"PLAIN\", 2];"]},{"text":"```sqf\n// create IGUI display\n// such display can be closed with closeDisplay command or by overwriting the same cut layer with another output.\n// note that \"Unload\" EH for some reason does not work with such display.\n\"someLayer\" cutRsc [\"RscTitleDisplayEmpty\", \"PLAIN\"];\nprivate _display = uiNamespace getVariable \"RscTitleDisplayEmpty\";\n```","code":["// create IGUI display\n// such display can be closed with closeDisplay command or by overwriting the same cut layer with another output.\n// note that \"Unload\" EH for some reason does not work with such display.\n\"someLayer\" cutRsc [\"RscTitleDisplayEmpty\", \"PLAIN\"];\nprivate _display = uiNamespace getVariable \"RscTitleDisplayEmpty\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","titleRsc","cutText","cutObj","cutFadeOut","setTitleEffect","allActiveTitleEffects","activeTitleEffectParams"],"notes":[{"user":"Dr_Eyeball","date":"2008-06-30T08:44:00Z","text":"Using cutRsc (instead of titleRsc) for a HUD has the benefits of:\n- having the HUD automatically hide itself when you access the map and redisplay itself after closing the map.\n- using the 'Direct communication' chat channel messages will not interfere with the HUD by hiding it."},{"user":"Killzone_Kid","date":"2013-10-17T16:30:00Z","text":"Regarding removing current resource with cutRsc [\"Default\", \"PLAIN\"]. If it does't work and it gives you error message that \"Default\" is not found, add it by yourself to RscTitles in description.ext so it looks like this:\n\n```cpp\nclass RscTitles\n{\n    class Default \n    {\n        idd = -1;\n        fadein = 0;\n        fadeout = 0;\n        duration = 0;\n    };\n};\n```\n\nAlternatively, you can use cutText, yes cutText command to cancel your resources. As Karel Moricky explains: \"All 'cut' commands are in the same layer, the same as all 'title' commands are in another one.\" So to remove cutRsc resource execute cutText on the same layer:\n\n```sqf\ncutRsc [\"myRsc\", \"PLAIN\"];    // show\ncutText [\"\", \"PLAIN\"];        // remove\n```\n\n```sqf\n10 cutRsc [\"myRsc\", \"PLAIN\"];    // show\n10 cutText [\"\", \"PLAIN\"];        // remove\n```\n\nAlso if you use layers would be a good idea to register them with BIS_fnc_rscLayer to avoid possible clashes with other layers:\n\n```sqf\n(\"myLayerName\" call BIS_fnc_rscLayer) cutRsc [\"myRsc\", \"PLAIN\"];    // show\n(\"myLayerName\" call BIS_fnc_rscLayer) cutText [\"\", \"PLAIN\"];        // remove\n```\n\nYou can also immediately remove resource with cutFadeOut command:\n\n```sqf\n123 cutFadeOut 0;\n```"},{"user":"Sa-Matra","date":"2023-04-13T08:19:35Z","text":"Layer display time seems to be display's \"duration\" parameter divided by \"speed\" provided into this command, which also acts as effect time. So to make sure your display doesn't close after a bit, have your \"\"duration\"\" at a very high number like `duration = 1e11;`"},{"user":"Rpg12","date":"2025-09-01T21:27:41Z","text":"The note by Killzone_kid is no longer valid due to an arma 3 update, ensure you do this instead:\n\n```sqf\n\"exampleLayer\" cutRsc [\"RCSDefinedLayer\", \"PLAIN\"];\n```\n\nThe RCSDefinedLayer is something you define in either config.cpp or description.ext"}],"categories":[]},{"name":"cutText","operator":null,"title":"cutText","type":"command","url":"https://community.bistudio.com/wiki/cutText","revid":347960,"updated":"2023-11-07T15:58:14Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Displays a text message in the center of the screen. The text can be displayed on multiple lines by using \"\\n\" new line characters: `cutText [\"line1\\nline2\\nline3\", \"PLAIN\"];`\n\n> [!NOTE]\n> **Arma 3:** For greater efficiency and ease of modability it is recommended to use named layers through the alternative syntax.","syntaxes":[{"syntax":"cutText [text, type, speed, showInMap, isStructuredText, drawOverHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"text to be displayed","types":["String"],"since":null,"text":"text: String - text to be displayed"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"1","description":"time in seconds to fade in resource. If 0 or less, default value is used","types":["Number"],"since":null,"text":"speed: Number - (Optional, default 1) time in seconds to fade in resource. If 0 or less, default value is used"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":"arma3 0.50","text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"isStructuredText","type":"Boolean","optional":true,"default":"false","description":"true to switch support for Structured Text formatting - see #Example 4","types":["Boolean"],"since":"arma3 1.74","text":"isStructuredText: Boolean - (Optional, default false) true to switch support for Structured Text formatting - see #Example 4"},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the text under in-game HUD","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the text under in-game HUD"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, type, speed, showInMap, isStructuredText, drawOverHUD]","types":["Array"]}},{"syntax":"layer cutText [text, type, speed, showInMap, isStructuredText, drawOverHUD]","since":"arma3 1.58","effect":null,"exec":null,"params":[{"name":"layer","type":"Number or String","optional":false,"default":null,"description":"Number or String\n- Number - layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100.\n- String - layer name on which the effect is shown. Layer names are CaSe SeNsItIvE.","types":["Number","String"],"since":null,"text":"layer: Number or String\n- Number - layer number on which the effect is shown, where 0 is the back most. Layer number is rounded to the nearest integer and also cannot be negative. Layer 99.5 will be treated as layer 100.\n- String - layer name on which the effect is shown. Layer names are CaSe SeNsItIvE."},{"name":"text","type":"String","optional":false,"default":null,"description":"text to be displayed","types":["String"],"since":null,"text":"text: String - text to be displayed"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource. If 0 or less, default value is used","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource. If 0 or less, default value is used"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"isStructuredText","type":"Boolean","optional":true,"default":"false","description":"true to switch support for Structured Text formatting - see #Example 4","types":["Boolean"],"since":"arma3 1.74","text":"isStructuredText: Boolean - (Optional, default false) true to switch support for Structured Text formatting - see #Example 4"},{"name":"drawOverHUD","type":"Boolean","optional":true,"default":"true","description":"false to show the text under in-game HUD","types":["Boolean"],"since":"arma3 2.16","text":"drawOverHUD: Boolean - (Optional, default true) false to show the text under in-game HUD"}],"returns":{"type":"- Nothing when layer is a Number","types":["Nothing","Number"],"description":"Number when ''layer is a String","text":"- Nothing when *layer* is a Number\n- Number when ''layer is a String"},"form":"binary","operator":null,"left":{"text":"layer","types":["Number","String"]},"right":{"text":"[text, type, speed, showInMap, isStructuredText, drawOverHUD]","types":["Array"]}}],"examples":[{"text":"```sqf\ncutText [\"\", \"BLACK OUT\"];\ncutText [\"Hello World!\", \"PLAIN\", 2];\n```","code":["cutText [\"\", \"BLACK OUT\"];\ncutText [\"Hello World!\", \"PLAIN\", 2];"]},{"text":"```sqf\n2 cutText [\"Hello World!\", \"PLAIN\", 2]; // returns nothing\n```","code":["2 cutText [\"Hello World!\", \"PLAIN\", 2]; // returns nothing"]},{"text":"```sqf\nprivate _layer1 = \"normal\" cutText [\"In The Centre\", \"PLAIN\"];\nprivate _layer2 = \"down\" cutText [\"At The Bottom\", \"PLAIN DOWN\"];\n```","code":["private _layer1 = \"normal\" cutText [\"In The Centre\", \"PLAIN\"];\nprivate _layer2 = \"down\" cutText [\"At The Bottom\", \"PLAIN DOWN\"];"]},{"text":"```sqf\ncutText [\"<t color='#ff0000' size='5'>RED ALERT!</t><br/>***********\", \"PLAIN\", -1, true, true];\n```","code":["cutText [\"<t color='#ff0000' size='5'>RED ALERT!</t><br/>***********\", \"PLAIN\", -1, true, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCutLayers","titleText","cutRsc","cutObj","cutFadeOut","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"damage","operator":null,"title":"damage","type":"command","url":"https://community.bistudio.com/wiki/damage","revid":364153,"updated":"2024-05-05T10:44:17Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return the damage value of an object.","syntaxes":[{"syntax":"damage object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":"the returned number in range (healthy) 0..1 (dead).","text":"Number - the returned number in range (healthy) 0..1 (dead)."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqs\n? damage player > 0.1 : player groupChat \"I'm hurt! Medic!\"\n```","code":["? damage player > 0.1 : player groupChat \"I'm hurt! Medic!\""]},{"text":"```sqf\nif (damage player > 0.1) then\n{\n    player groupChat \"I'm hurt! Medic!\";\n};\n```","code":["if (damage player > 0.1) then\n{\n\tplayer groupChat \"I'm hurt! Medic!\";\n};"]},{"text":"```sqf\nprivate _health = (1 - damage player) * 100; // health in % from 0 to 100\n```","code":["private _health = (1 - damage player) * 100; // health in % from 0 to 100"]}],"multiplayer":null,"problems":null,"aliases":["getDammage"],"see_also":["setDamage","setHit","getHit","getHitIndex","setHitIndex","getHitPointDamage","setHitPointDamage","waterDamaged","Arma 3: Event Handlers"],"notes":[{"user":"Pierre MGI","date":"2015-02-13T20:20:00Z","text":"The returned value depends on the couple target/ammo fired. This value has no correlation with the sum of all hitpoints damage status and the effective status of the object.\nFiring bullets on cars often lead to weird results. For example: damage returns zero while a Hunter is fired at will with an .50 HMG! Hunter can be almost destroyed with zero damage for this function.\nIf you script, use instead the getHitPointDamage command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"date","operator":null,"title":"date","type":"command","url":"https://community.bistudio.com/wiki/date","revid":377601,"updated":"2026-01-02T08:16:59Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Return the actual in-mission date and time.","syntaxes":[{"syntax":"date","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Date","types":["Date"],"description":null,"text":"Date"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// in Arma 3\ndate params [\"_year\", \"_month\", \"_day\", \"_hours\", \"_minutes\"];\n\n// pre Arma 3\nprivate [\"_now\", \"_year\", \"_month\", \"_day\", \"_hours\", \"_minutes\"];\n_now = date;    // [2014,10,30,2,30] a.k.a Oct. 30th, 2:30am\n_year        = _now select 0;\n_month        = _now select 1;\n_day        = _now select 2;\n_hours        = _now select 3;\n_minutes    = _now select 4;\n```","code":["// in Arma 3\ndate params [\"_year\", \"_month\", \"_day\", \"_hours\", \"_minutes\"];\n\n// pre Arma 3\nprivate [\"_now\", \"_year\", \"_month\", \"_day\", \"_hours\", \"_minutes\"];\n_now = date;\t// [2014,10,30,2,30] a.k.a Oct. 30th, 2:30am\n_year\t\t= _now select 0;\n_month\t\t= _now select 1;\n_day\t\t= _now select 2;\n_hours\t\t= _now select 3;\n_minutes\t= _now select 4;"]},{"text":"```sqf\nif (date select 3 >= 19) then        // 7pm\n{\n    hintSilent \"ah, Arma sunset\";    // ...cue bad guys\n};\n```","code":["if (date select 3 >= 19) then\t\t// 7pm\n{\n\thintSilent \"ah, Arma sunset\";\t// ...cue bad guys\n};"]}],"multiplayer":"Returns the current **local** (MP client) in-game date.\n\n> [!NOTE]\n> **Arma 3:** Clients' local date is automatically and periodically synchronised with the server date.","problems":null,"aliases":[],"see_also":["setDate","dateToNumber","numberToDate","time","missionStart","systemTime","systemTimeUTC"],"notes":[{"user":"Lou Montana","date":"2018-01-23T23:35:00Z","text":"a useful script to format the date:\n\n```sqf\n_curDate = date;\nprivate _ddMMyyyy = format [\"%3/%2/%1\",\n    _curDate select 0,\n    (if (_curDate select 1 < 10) then { \"0\" } else { \"\" }) + str (_curDate select 1),\n    (if (_curDate select 2 < 10) then { \"0\" } else { \"\" }) + str (_curDate select 2)\n];\n```\n\nit can be shortened to: (no intermediary variable but more request to date)\n\n```sqf\nprivate _ddMMyyyy = format [\"%3/%2/%1\",\n    date select 0,\n    (if (date select 1 < 10) then { \"0\" } else { \"\" }) + str (date select 1),\n    (if (date select 2 < 10) then { \"0\" } else { \"\" }) + str (date select 2)\n];\n```\n\n**EDIT:** or to\n\n```sqf\nprivate _ddMMyyyy = format [\"%4%5/%2%3/%1\",\n    date select 0,\n    [\"\", \"0\"] select (date select 1 < 10),\n    date select 1,\n    [\"\", \"0\"] select (date select 2 < 10),\n    date select 2\n];\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"dateToNumber","operator":null,"title":"dateToNumber","type":"command","url":"https://community.bistudio.com/wiki/dateToNumber","revid":378087,"updated":"2026-02-12T17:31:59Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Convert a date to a float number, based on Jan 1st 00:00:00 = 0 and Dec 31st  23:59:59 = 1.\nThe same day and time in leap year will be different after 28th of February and 23:59 on 31st of December will be 1.00274.\n\nThis is how this command works. The 365 days of the year are presented in range 0..1. So each day will be:\n\n```sqf\n1 / 365 = 0.00273973\n```\n\nIn a leap year there are 366 days, so the range will increase by 1 day:\n\n```sqf\n1 / 365 * 366 = 1.00274\n```\n\nIn short, in a normal year the command returns in range 0...1 in a leap year it will return in range 0...1.00274.","syntaxes":[{"syntax":"dateToNumber date","since":null,"effect":null,"exec":null,"params":[{"name":"date","type":"Date","optional":false,"default":null,"description":null,"types":["Date"],"since":null,"text":"date: Date"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"date","types":["Date"]}}],"examples":[{"text":"```sqf\n_float = dateToNumber [2035, 7, 6, 12, 0]; // 0.510959\n```","code":["_float = dateToNumber [2035, 7, 6, 12, 0]; // 0.510959"]},{"text":"```sqf\ndateToNumber date; // returns float number for the current date\n```","code":["dateToNumber date; // returns float number for the current date"]},{"text":"Calculate days from 1/1/1970:\n\n```sqf\n_fnc_daysFromEpoch =\n{\n    private _year = param [0];\n    private _days = 0;\n    for \"_i\" from 1970 to _year - 1 do\n    {\n        _days = _days + round linearConversion [0, 1, dateToNumber [_i, 12, 31, 23, 59], 0, 365, false];\n    };\n\n    _days + linearConversion [0, 1, dateToNumber _this, 0, 365, false];\n};\n\nhint str (date call _fnc_daysFromEpoch);\n```","code":["_fnc_daysFromEpoch =\n{\n\tprivate _year = param [0];\n\tprivate _days = 0;\n\tfor \"_i\" from 1970 to _year - 1 do\n\t{\n\t\t_days = _days + round linearConversion [0, 1, dateToNumber [_i, 12, 31, 23, 59], 0, 365, false];\n\t};\n\n\t_days + linearConversion [0, 1, dateToNumber _this, 0, 365, false];\n};\n\nhint str (date call _fnc_daysFromEpoch);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["date","dayTime","time","numberToDate"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"dayTime","operator":null,"title":"dayTime","type":"command","url":"https://community.bistudio.com/wiki/dayTime","revid":378415,"updated":"2026-04-04T08:39:14Z","groups":["Environment","Mission Information","Time"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current in-game time in hours. For a formatted version of time, see BIS_fnc_timeToString.","syntaxes":[{"syntax":"dayTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..24","types":["Number"],"description":"day time using a 24 hour clock, using fractions of hours","text":"Number in range 0..24 - day time using a 24 hour clock, using fractions of hours"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndayTime; // returns 16.5 given it is 16:30 (4.30pm) in game\n```","code":["dayTime; // returns 16.5 given it is 16:30 (4.30pm) in game"]},{"text":"Get hour, minute, seconds:\n\n```sqf\nprivate _daytime = dayTime; // assuming dayTime returns 1.66046\nprivate _hours = floor _daytime;                                            //  1\nprivate _minutes = floor ((_daytime - _hours) * 60);                        // 39\nprivate _seconds = floor ((((_daytime - _hours) * 60) - _minutes) * 60);    // 37\n```","code":["private _daytime = dayTime; // assuming dayTime returns 1.66046\nprivate _hours = floor _daytime;\t\t\t\t\t\t\t\t\t\t\t//  1\nprivate _minutes = floor ((_daytime - _hours) * 60);\t\t\t\t\t\t// 39\nprivate _seconds = floor ((((_daytime - _hours) * 60) - _minutes) * 60);\t// 37"]}],"multiplayer":"Returns the current **local** in-game time in hours.","problems":null,"aliases":[],"see_also":["date","dateToNumber","BIS_fnc_timeToString","time","skipTime","systemTime","systemTimeUTC"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Mission Information","Command Group: Time","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deActivateKey","operator":null,"title":"deActivateKey","type":"command","url":"https://community.bistudio.com/wiki/deActivateKey","revid":318885,"updated":"2022-05-13T09:21:59Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deactivates the given keyname for the current user profile. The keys are used to unlock missions or campaigns.\n\nSee keys, keysLimit and doneKeys in the description.ext file of the missions.","syntaxes":[{"syntax":"deActivateKey keyname","since":null,"effect":null,"exec":null,"params":[{"name":"keyname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"keyname: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"keyname","types":["String"]}}],"examples":[{"text":"```sqf\ndeActivateKey \"Mission04Key\";\n```","code":["deActivateKey \"Mission04Key\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isKeyActive","activateKey"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"debriefingText","operator":null,"title":"debriefingText","type":"command","url":"https://community.bistudio.com/wiki/debriefingText","revid":318861,"updated":"2022-05-13T09:21:57Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns debriefing text of provided end.","syntaxes":[{"syntax":"debriefingText end","since":null,"effect":null,"exec":null,"params":[{"name":"end","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"end: String"}],"returns":{"type":"String","types":["String"],"description":"end debriefing text. If it does not exist in config, empty string is returned.","text":"String - *end* debriefing text. If it does not exist in config, empty string is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"end","types":["String"]}}],"examples":[{"text":"```sqf\n_deathText = debriefingText \"endDeath\";\n```","code":["_deathText = debriefingText \"endDeath\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDebriefingText","disableDebriefingStats","enableDebriefingStats"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"debugFSM","operator":null,"title":"debugFSM","type":"command","url":"https://community.bistudio.com/wiki/debugFSM","revid":352205,"updated":"2024-02-01T23:26:03Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dump (something about FSM) to debugging output. This command is (assumed to be) non-functional in the retail version.\n\n> [!WARNING]\n> Non functional in retail","syntaxes":[{"syntax":"FSMhandle debugFSM true","since":null,"effect":null,"exec":null,"params":[{"name":"FSMhandle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"FSMhandle: Number"},{"name":"true","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"true: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"FSMhandle","types":["Number"]},"right":{"text":"true","types":["Boolean"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"debugLog","operator":null,"title":"debugLog","type":"command","url":"https://community.bistudio.com/wiki/debugLog","revid":352160,"updated":"2024-02-01T23:25:24Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dump argument type and value to debugging output.\n\n> [!WARNING]\n> This command is non-functional in the retail version. Use diag_log instead.","syntaxes":[{"syntax":"debugLog anything","since":null,"effect":null,"exec":null,"params":[{"name":"anything","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"anything: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"anything","types":["Anything"]}}],"examples":[{"text":"```sqf\ndebugLog player;\n```","code":["debugLog player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"decayGraphValues","operator":null,"title":"decayGraphValues","type":"command","url":"https://community.bistudio.com/wiki/decayGraphValues","revid":309184,"updated":"2022-05-03T18:08:43Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Multiplies graph values by the given coefficient. The corresponding lower bound value is used instead if the product is smaller than the bound.","syntaxes":[{"syntax":"decayGraphValues [lowerBoundValues, graphValues, coef]","since":null,"effect":null,"exec":null,"params":[{"name":"lowerBoundValues","type":"Array of Numbers","optional":false,"default":null,"description":"lower bound for the new graph","types":["Array","Number"],"since":null,"text":"lowerBoundValues: Array of Numbers - lower bound for the new graph"},{"name":"graphValues","type":"Array of Numbers","optional":false,"default":null,"description":"graph values","types":["Array","Number"],"since":null,"text":"graphValues: Array of Numbers - graph values"},{"name":"coef","type":"Number","optional":false,"default":null,"description":"the multiplication coefficient","types":["Number"],"since":null,"text":"coef: Number - the multiplication coefficient"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"[lowerBoundValues, graphValues, coef]","types":["Array"]}}],"examples":[{"text":"```sqf\ndecayGraphValues [[1,2,3,4,5], [1,4,9,16,25], 0.3]; // returns [1,2,3,4.8,7.5]\n```","code":["decayGraphValues [[1,2,3,4,5], [1,4,9,16,25], 0.3]; // returns [1,2,3,4.8,7.5]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getGraphValues"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"default","operator":null,"title":"default","type":"command","url":"https://community.bistudio.com/wiki/default","revid":369400,"updated":"2024-09-03T18:43:21Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines a Switch Type default case - does **not** need a colon to define its block. See switch for more information.","syntaxes":[{"syntax":"default a","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"a: Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"a","types":["Code"]}}],"examples":[{"text":"```sqf\nswitch (_condition) do\n{\n    case 1: { hint \"1\" };\n    case 2: { hint \"2\" };\n    default { hint \"default\" }; // no colon after default\n};\n```","code":["switch (_condition) do\n{\n\tcase 1: { hint \"1\" };\n\tcase 2: { hint \"2\" };\n\tdefault { hint \"default\" }; // no colon after default\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","switch","case"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deg","operator":null,"title":"deg","type":"command","url":"https://community.bistudio.com/wiki/deg","revid":349072,"updated":"2023-11-08T14:47:22Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts given value in radians to degrees. 1 degree equals 0.01745 radians or pi / 180.\n\n> [!NOTE]\n>","syntaxes":[{"syntax":"deg value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":"radians","types":["Number"],"since":null,"text":"value: Number - radians"}],"returns":{"type":"Number","types":["Number"],"description":"degrees","text":"Number - degrees"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n_degrees = deg 1; // Returns 57.2958\n```","code":["_degrees = deg 1; // Returns 57.2958"]},{"text":"```sqf\ndeg (2 * pi / 360); // Returns 1\n```","code":["deg (2 * pi / 360); // Returns 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rad"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"delete3DENEntities","operator":null,"title":"delete3DENEntities","type":"command","url":"https://community.bistudio.com/wiki/delete3DENEntities","revid":342152,"updated":"2023-07-09T12:26:49Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Delete given entities in Eden Editor.","syntaxes":[{"syntax":"delete3DENEntities entities","since":null,"effect":null,"exec":null,"params":[{"name":"entities","type":"Array of Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Array","Eden Entity","Eden ID"],"since":null,"text":"entities: Array of Eden Entity or Eden ID"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"entities","types":["Array","Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\ndelete3DENEntities (all3DENEntities select 0); // Removes all objects\n```","code":["delete3DENEntities (all3DENEntities select 0); // Removes all objects"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["collect3DENHistory","create3DENComposition","create3DENEntity","all3DENEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"deleteAt","operator":null,"title":"deleteAt","type":"command","url":"https://community.bistudio.com/wiki/deleteAt","revid":378389,"updated":"2026-04-04T07:34:56Z","groups":["Arrays","HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes array element at the given index and returns removed element (modifies the original array, just like resize or set).\n\n> [!NOTE]\n> For the main Array variant, if the index is a negative Number, no error will appear, making it ideal for using with find (see #Example 2) or findIf (see #Example 3).","syntaxes":[{"syntax":"array deleteAt index","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"index","type":"Number","optional":false,"default":null,"description":"see the note in description","types":["Number"],"since":null,"text":"index: Number - see the note in description"}],"returns":{"type":"Anything or Nothing","types":["Anything","Nothing"],"description":"returns the deleted element if one existed","text":"Anything or Nothing - returns the deleted element if one existed"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"index","types":["Number"]}},{"syntax":"hashMap deleteAt key","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":null,"types":["HashMapKey"],"since":null,"text":"key: HashMapKey"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"key","types":["HashMapKey"]}},{"syntax":"array deleteAt indexes","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"indexes","type":"Array of Numbers","optional":false,"default":null,"description":"multiple indexes, negative indexes are supported and would remove elements counting from the end of array (see #Example 4).","types":["Array","Number"],"since":null,"text":"indexes: Array of Numbers - multiple indexes, negative indexes are supported and would remove elements counting from the end of array (see #Example 4)."}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"deleted elements in order of user supplied indexes","text":"Array of Anything - deleted elements in order of user supplied indexes"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"indexes","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3];\n_rem = _arr deleteAt 1;\nhint str [_rem, _arr]; // [2, [1, 3]]\n```","code":["_arr = [1,2,3];\n_rem = _arr deleteAt 1;\nhint str [_rem, _arr]; // [2, [1, 3]]"]},{"text":"```sqf\n_arr = [1,2,3];\n_arr deleteAt (_arr find 0); // non existent item\nhint str _arr; // [1,2,3]\n_arr deleteAt (_arr find 2); // existent item\nhint str _arr; // [1,3]\n```","code":["_arr = [1,2,3];\n_arr deleteAt (_arr find 0); // non existent item\nhint str _arr; // [1,2,3]\n_arr deleteAt (_arr find 2); // existent item\nhint str _arr; // [1,3]"]},{"text":"```sqf\n_arr = [1,2,3];\n_arr deleteAt (_arr findIf {(_x % 5) == 0}); // Remove first number that's divisible by 5\nhint str _arr; // [1,2,3]\n_arr deleteAt (_arr findIf {(_x % 2) == 0}); // Remove first number that's divisible by 2\nhint str _arr; // [1,3]\n```","code":["_arr = [1,2,3];\n_arr deleteAt (_arr findIf {(_x % 5) == 0}); // Remove first number that's divisible by 5\nhint str _arr; // [1,2,3]\n_arr deleteAt (_arr findIf {(_x % 2) == 0}); // Remove first number that's divisible by 2\nhint str _arr; // [1,3]"]},{"text":"```sqf\n_arr = [1,2,3,4];\n_res = _arr deleteAt [-1, 0]; // Remove the last and the first array element\nsystemchat str [_res, _arr]; // [[4,1],[2,3]]\n```","code":["_arr = [1,2,3,4];\n_res = _arr deleteAt [-1, 0]; // Remove the last and the first array element\nsystemchat str [_res, _arr]; // [[4,1],[2,3]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteRange","set","resize","select","in","find","findIf","toArray","toString","forEach","count","pushBack","pushBackUnique","apply","append","sort","param","params","arrayIntersect","splitString","joinString"],"notes":[{"user":"Heeeere's Johnny!","date":"2014-10-15T16:55:00Z","text":"```sqf\n_array deleteAt 0;\n```\n\n is almost 60x faster than \n\n```sqf\n_array = _array - [_array select 0]\n```\n\n (Tested with an array of 10.000 strings, iterating through it using a for-from-to-do loop)"},{"user":"Highhead","date":"2016-03-04T15:58:00Z","text":"Deleting from an array with foreach and _foreachIndex variable is tricky.\nThe array is being altered, the _foreachIndex won't keep up and other elements in the array will be skipped and in worst case not being deleted.\nIf you delete elements from an array in descending order (using while or for) it will work."},{"user":"Igneous01","date":"2017-02-09T22:45:00Z","text":"To expand on Highheads comment above - this is because forEach implements iterators to traverse a collection, which are read only by definition.\nThe variable _x is an iterator that points to the current item in the collection. Trying to alter _x will have no effect.\n\n```sqf\nprivate _array = [1,2,3,4,5,6,7,8];\n{ _x = 2; } forEach _array\n// _array is still [1,2,3,4,5,6,7,8]\n```\n\nWhen trying to use deleteAt inside forEach, the behaviour would be undefined as you are invalidating the iterator reference, and it will not know how to traverse to the next element.\nIn short, only use forEach when reading data from an array.\nFor more info about iterators, see C++ Iterators."},{"user":"Freghar","date":"2021-02-01T18:06:00Z","text":"As you would expect from a simple array implementation,\n\n```sqf\narray deleteAt (count array - 1);\n```\n\nis virtually zero cost (0.0005ms on an array of 1000000 elements), while\n\n```sqf\narray deleteAt 0;\n```\n\nis very performance heavy (0.7ms on the same huge array)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"deleteCenter","operator":null,"title":"deleteCenter","type":"command","url":"https://community.bistudio.com/wiki/deleteCenter","revid":310241,"updated":"2022-05-05T13:11:01Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"In a nutshell, this command removes gaming Side (see createCenter). If a side has >0 Groups it cannot be deleted. Center can only be created for: east, west, resistance, civilian and sideLogic, therefore only centers from the mentioned sides can be deleted.\n\n**Old description:** Destroys the AI center of the given side.","syntaxes":[{"syntax":"deleteCenter side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\ndeleteCenter east;\n```","code":["deleteCenter east;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createCenter"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteCollection","operator":null,"title":"deleteCollection","type":"command","url":"https://community.bistudio.com/wiki/deleteCollection","revid":353153,"updated":"2024-03-12T12:48:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Delete a collection. As example, used with a soldier, it'll hide the ingame model.\n\n*When targetting Arma 2 1.06 or newer, use hideObject instead. This function is a relic from dynamic building destruction development. It is left only for compatibility with scripts created before Arma 2 1.06, and its functionality may be changed or removed in the future.*","syntaxes":[{"syntax":"deleteCollection object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ndeleteCollection unitName;\n```","code":["deleteCollection unitName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideObject","hideObjectGlobal","isObjectHidden"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deleteEditorObject","operator":null,"title":"deleteEditorObject","type":"command","url":"https://community.bistudio.com/wiki/deleteEditorObject","revid":363263,"updated":"2024-03-26T10:51:33Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Delete the editor object. Requires all editor object links to be removed prior.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map deleteEditorObject object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deleteGroup","operator":null,"title":"deleteGroup","type":"command","url":"https://community.bistudio.com/wiki/deleteGroup","revid":330309,"updated":"2022-08-30T23:40:39Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Destroys the given group - the group must be empty and local to the machine executing this command.\n\n> [!NOTE]\n> In Arma 3 you can find out locality of the group with local command, unlike with previous games. However owner and setOwner don't work with groups anywhere. The group will always be local to the client that created it, until the client disconnects, then the group becomes local to the server. So if you need to delete a group, delete all members first then execute deleteGroup where is it local.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3 when the last unit leaves a group, the group gets automatically deleted. Manually deleting all units from a group, however, does **not** automatically delete the empty group. To force the group to get auto-deleted when empty, use deleteGroupWhenEmpty.","syntaxes":[{"syntax":"deleteGroup group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\ndeleteGroup _group;\n```","code":["deleteGroup _group;"]},{"text":"```sqf\n[_group] remoteExec [\"deleteGroup\", groupOwner _group]; // server only\n```","code":["[_group] remoteExec [\"deleteGroup\", groupOwner _group]; // server only"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteGroupWhenEmpty","isGroupDeletedWhenEmpty","createGroup","units","group","groupFromNetId"],"notes":[{"user":"ColonelSandersLite","date":"2006-12-17T00:34:00Z","text":"The deleteGroup Command does not work when there are living members of in the group.  It doesn't error, it simply doesn't do anything."},{"user":"5133p39","date":"2007-07-10T07:50:00Z","text":"Living or not doesn't matter - you can't delete the group while it contains any units - even dead ones. It takes few seconds until a dead unit is automatically removed from its group."},{"user":"LongEnoughName","date":"2013-09-12T03:54:00Z","text":"deleteGroup will only delete local groups even if called by server.\nSay we have a situation where client creates a group and puts a unit there and later unit dies/gets deleted, server will not be able to delete that empty group until client leaves the game and group ownership switches to server."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteGroupWhenEmpty","operator":null,"title":"deleteGroupWhenEmpty","type":"command","url":"https://community.bistudio.com/wiki/deleteGroupWhenEmpty","revid":353027,"updated":"2024-03-12T11:37:47Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Marks given group for auto-deletion when group is empty.\ntrue will mark the group for auto-deletion once empty, false will simply unmark the group that was marked previously.\n\n> [!IMPORTANT]\n> This command does **not** prevent group deletion (through e.g deleteGroup or any engine group management).","syntaxes":[{"syntax":"group deleteGroupWhenEmpty delete","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"delete","type":"Boolean","optional":false,"default":null,"description":"true to mark for auto-deletion on empty group, false to not use this auto-deletion system","types":["Boolean"],"since":null,"text":"delete: Boolean - true to mark for auto-deletion on empty group, false to not use this auto-deletion system"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"delete","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_group deleteGroupWhenEmpty true;\n```","code":["_group deleteGroupWhenEmpty true;"]},{"text":"Executed on the server:\n\n```sqf\nif (local _group) then\n{\n    _group deleteGroupWhenEmpty true;\n}\nelse // group is local to a client\n{\n    [_group, true] remoteExec [\"deleteGroupWhenEmpty\", groupOwner _group];\n};\n```","code":["if (local _group) then\n{\n\t_group deleteGroupWhenEmpty true;\n}\nelse // group is local to a client\n{\n\t[_group, true] remoteExec [\"deleteGroupWhenEmpty\", groupOwner _group];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteGroup","isGroupDeletedWhenEmpty","createGroup","group","setGroupId","groupID","units","groupFromNetId","netId","leader","selectLeader","join","createCenter","createUnit","createVehicle","Side"],"notes":[{"user":"PierreMGI","date":"2023-12-01T05:04:28Z","text":"The auto-deletion of a group is not automatic. For example, if you place a group in editor, name it (grp1), and kill the units in preview, this group remains not null and is counted as group (checked by count allGroups).\nOn the other hand, if you write: `this deleteGroupWhenEmpty true` in composition init (group init), this group will become null sometimes after the units are killed. It takes a little time for dead units to exit the group, then an extra time for the group to be deleted once all units dead. (count allGroups decreases).\nOf course, in both cases, grp1 remains a variable (\"grp1\" is not nil)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"deleteIdentity","operator":null,"title":"deleteIdentity","type":"command","url":"https://community.bistudio.com/wiki/deleteIdentity","revid":348911,"updated":"2023-11-08T14:40:02Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Deletes an identity created with saveIdentity from the campaign's progress file.","syntaxes":[{"syntax":"deleteIdentity identityName","since":null,"effect":null,"exec":null,"params":[{"name":"identityName","type":"String","optional":false,"default":null,"description":"name of the saved identity","types":["String"],"since":null,"text":"identityName: String - name of the saved identity"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the identity was deleted successfully, false if not","text":"Boolean - true if the identity was deleted successfully, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"identityName","types":["String"]}}],"examples":[{"text":"```sqf\n_deleted = deleteIdentity \"playerIdentity\";\n```","code":["_deleted = deleteIdentity \"playerIdentity\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveIdentity"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteLocation","operator":null,"title":"deleteLocation","type":"command","url":"https://community.bistudio.com/wiki/deleteLocation","revid":309921,"updated":"2022-05-05T12:16:57Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deletes scripted location.","syntaxes":[{"syntax":"deleteLocation location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\ndeleteLocation myLocation;\n```","code":["deleteLocation myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["location","text"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deleteMarker","operator":null,"title":"deleteMarker","type":"command","url":"https://community.bistudio.com/wiki/deleteMarker","revid":338571,"updated":"2023-03-20T14:56:08Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Destroys the given marker.","syntaxes":[{"syntax":"deleteMarker name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\ndeleteMarker \"Marker1\";\n```","code":["deleteMarker \"Marker1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMarker","deleteMarkerLocal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteMarkerLocal","operator":null,"title":"deleteMarkerLocal","type":"command","url":"https://community.bistudio.com/wiki/deleteMarkerLocal","revid":338570,"updated":"2023-03-20T14:55:35Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Destroys the given marker.","syntaxes":[{"syntax":"deleteMarkerLocal markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\ndeleteMarkerLocal \"Marker1\";\n```","code":["deleteMarkerLocal \"Marker1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMarkerLocal","deleteMarker"],"notes":[{"user":"HomerJohnston","date":"2012-01-07T09:16:00Z","text":"Unproven: I believe that if you use this command on a globally-created marker, and subsequently another machine executes a global command on the same marker (e.g. setMarkerPos), then the marker will be re-created on the machine it was previously deleted on. Can result in confusing marker behaviour."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteRange","operator":null,"title":"deleteRange","type":"command","url":"https://community.bistudio.com/wiki/deleteRange","revid":377170,"updated":"2026-01-01T10:45:25Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes a range of array elements from the given array. Modifies the original array, just like resize or set.","syntaxes":[{"syntax":"array deleteRange [from, count]","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"from","type":"Number","optional":false,"default":null,"description":"array index to start selection from.","types":["Number"],"since":null,"text":"from: Number - array index to start selection from."},{"name":"count","type":"Number","optional":false,"default":null,"description":"number of array elements to remove. If the selected range exceeds source array boundaries, selection will be made up to the end of the array.","types":["Number"],"since":null,"text":"count: Number - number of array elements to remove. If the selected range exceeds source array boundaries, selection will be made up to the end of the array."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"[from, count]","types":["Array"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3,4,5,6];\n_arr deleteRange [1,4];\nhint str _arr; // [1,6]\n```","code":["_arr = [1,2,3,4,5,6];\n_arr deleteRange [1,4];\nhint str _arr; // [1,6]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteAt","set","resize","select","in","find","toArray","toString","forEach","count","pushBack","pushBackUnique","apply","append","sort","param","params","arrayIntersect","splitString","joinString"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"deleteResources","operator":null,"title":"deleteResources","type":"command","url":"https://community.bistudio.com/wiki/deleteResources","revid":321170,"updated":"2022-05-13T15:14:30Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Delete (unregister) resources of the team member. Resources are deleted in the order they were added. Case insensitive.","syntaxes":[{"syntax":"teamMember deleteResources resources","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"},{"name":"resources","type":"Array of Strings","optional":false,"default":null,"description":null,"types":["Array","String"],"since":null,"text":"resources: Array of Strings"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"resources","types":["Array","String"]}}],"examples":[{"text":"```sqf\nteamMember _agent deleteResources [\"Legs\"];\n```","code":["teamMember _agent deleteResources [\"Legs\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["resources","addResources"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteSite","operator":null,"title":"deleteSite","type":"command","url":"https://community.bistudio.com/wiki/deleteSite","revid":364517,"updated":"2024-05-16T20:46:22Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes the site.\n\n> [!WARNING]\n> This command is considered deprecated and is no longer supported","syntaxes":[{"syntax":"deleteSite site","since":null,"effect":null,"exec":null,"params":[{"name":"site","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"site: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"site","types":["Object"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSite","allSites"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"deleteStatus","operator":null,"title":"deleteStatus","type":"command","url":"https://community.bistudio.com/wiki/deleteStatus","revid":348884,"updated":"2023-11-08T14:39:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Deletes a status created with saveStatus from the campaign's progress file.","syntaxes":[{"syntax":"deleteStatus statusName","since":null,"effect":null,"exec":null,"params":[{"name":"statusName","type":"String","optional":false,"default":null,"description":"name of the saved status","types":["String"],"since":null,"text":"statusName: String - name of the saved status"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the status was deleted successfully, false if not","text":"Boolean - true if the status was deleted successfully, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"statusName","types":["String"]}}],"examples":[{"text":"```sqf\n_deleted = deleteStatus \"playerStatus\";\n```","code":["_deleted = deleteStatus \"playerStatus\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveStatus","deleteIdentity","saveIdentity"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteTarget","operator":null,"title":"deleteTarget","type":"command","url":"https://community.bistudio.com/wiki/deleteTarget","revid":352111,"updated":"2024-02-01T23:24:58Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Delete a target.","syntaxes":[{"syntax":"deleteTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Target","optional":false,"default":null,"description":null,"types":["Target"],"since":null,"text":"target: Target"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Target"]}}],"examples":[{"text":"```sqf\ndeleteTarget target1;\n```","code":["deleteTarget target1;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command is not implemented.","aliases":[],"see_also":["createTarget","moveTarget"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deleteTeam","operator":null,"title":"deleteTeam","type":"command","url":"https://community.bistudio.com/wiki/deleteTeam","revid":309920,"updated":"2022-05-05T12:16:57Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Destroy given team.","syntaxes":[{"syntax":"deleteTeam team","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"team","types":["Team Member"]}}],"examples":[{"text":"```sqf\ndeleteTeam _team;\n```","code":["deleteTeam _team;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"deleteVehicle","operator":null,"title":"deleteVehicle","type":"command","url":"https://community.bistudio.com/wiki/deleteVehicle","revid":352346,"updated":"2024-02-08T14:01:50Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Deletes an object. Only objects inserted in the mission editor and objects created during the game's progress can be deleted by this command. Terrain objects and players cannot be deleted.\n\n> [!NOTE]\n> The actual object deletion, when the object becomes objNull, happens on the next frame after command execution, but there are some object modifications that happen immediately. For example if the object is a unit in a group, it immediately becomes groupless (`isNull group _unit; // true`).","syntaxes":[{"syntax":"deleteVehicle object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"deleteVehicle objects","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\ndeleteVehicle _house1;\n```","code":["deleteVehicle _house1;"]},{"text":"Deleting a vehicle with crew:\n\n```sqf\n// might want to make sure that the car is local\n{ car deleteVehicleCrew _x } forEach crew car;\ndeleteVehicle car;\n```","code":["// might want to make sure that the car is local\n{ car deleteVehicleCrew _x } forEach crew car;\ndeleteVehicle car;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> Use deleteVehicleCrew to delete units that are in a vehicle! Do **not** use this command for a vehicle's crew members as it may lead to all sorts of bugs and ghost objects left on the map.","aliases":[],"see_also":["deleteVehicleCrew","createUnit","createVehicleLocal","createVehicle","Arma 3: Event Handlers"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"deleteVehicleCrew","operator":null,"title":"deleteVehicleCrew","type":"command","url":"https://community.bistudio.com/wiki/deleteVehicleCrew","revid":347420,"updated":"2023-09-18T16:02:36Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Deletes a member of or the whole crew of a vehicle. Human players cannot be deleted.\n\n> [!NOTE]\n> This command attempts to move the given crew member out before deleting it. Made especially for deleting dead crew members, as using conventional deleteVehicle leads to all sorts of bugs and ghost objects. While the argument is global, you should take extra steps and execute this where vehicle is local as moving units out of the vehicle happens where vehicle is local and you want this to always precede deletion.","syntaxes":[{"syntax":"vehicle deleteVehicleCrew unit","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"unit","types":["Object"]}},{"syntax":"deleteVehicleCrew vehicle","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n// delete when knowing the vehicle\n_helicopter deleteVehicleCrew driver _helicopter;\n\n// delete when only knowing the unit\n// vehicle _soldier deleteVehicleCrew _soldier;        // may return the unit itself when used on dead crew\nobjectParent _soldier deleteVehicleCrew _soldier;    // faster and always returns the vehicle\n```","code":["// delete when knowing the vehicle\n_helicopter deleteVehicleCrew driver _helicopter;\n\n// delete when only knowing the unit\n// vehicle _soldier deleteVehicleCrew _soldier;\t\t// may return the unit itself when used on dead crew\nobjectParent _soldier deleteVehicleCrew _soldier;\t// faster and always returns the vehicle"]},{"text":"Delete entire crew:\n\n```sqf\ndeleteVehicleCrew _tank; // since v2.06\n\n{ _helicopter deleteVehicleCrew _x } forEach crew _helicopter; // before v2.06\n```","code":["deleteVehicleCrew _tank; // since v2.06\n\n{ _helicopter deleteVehicleCrew _x } forEach crew _helicopter; // before v2.06"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createVehicleCrew","moveInDriver","moveInGunner","moveInCommander","moveInTurret","moveInCargo","Arma 3: Event Handlers"],"notes":[{"user":"Killzone_Kid","date":"2014-08-31T10:15:00Z","text":"If you delete the AI pilot with `deleteVehicle driver heli` the co-pilot will jump out.\n\nIf you delete the AI pilot with `heli deleteVehicleCrew driver heli` the co-pilot will stay."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"deleteWaypoint","operator":null,"title":"deleteWaypoint","type":"command","url":"https://community.bistudio.com/wiki/deleteWaypoint","revid":339202,"updated":"2023-04-27T17:09:15Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes the specified waypoint.\n\n> [!NOTE]\n> - When a waypoint is deleted, all other group waypoints are immediately re-indexed. See #Example 2 for a deletion of all group's waypoints.\n> - Deleting a group's current waypoint will *not* stop the group on its tracks.","syntaxes":[{"syntax":"deleteWaypoint [group, index]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[group, index]","types":["Array"]}}],"examples":[{"text":"```sqf\ndeleteWaypoint [_grp, 2];\n```","code":["deleteWaypoint [_grp, 2];"]},{"text":"Because waypoints get immediately re-indexed when one gets deleted, delete them from last to first:\n\n```sqf\nprivate _group = group _unit;\nfor \"_i\" from (count waypoints _group - 1) to 0 step -1 do\n{\n    deleteWaypoint [_group, _i];\n};\n```\n\nor always delete the first one (if you want to delete them all)\n\n```sqf\nprivate _group = group _unit;\nfor \"_i\" from 0 to (count waypoints _group - 1) do\n{\n    deleteWaypoint [_group, 0];\n};\n```\n\nor use forEachReversed:\n\n```sqf\n{ deleteWaypoint _x } forEachReversed waypoints _group; // Arma 3 v2.14+ only\n```","code":["private _group = group _unit;\nfor \"_i\" from (count waypoints _group - 1) to 0 step -1 do\n{\n\tdeleteWaypoint [_group, _i];\n};","private _group = group _unit;\nfor \"_i\" from 0 to (count waypoints _group - 1) do\n{\n\tdeleteWaypoint [_group, 0];\n};","{ deleteWaypoint _x } forEachReversed waypoints _group; // Arma 3 v2.14+ only"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setCurrentWaypoint","setWaypointPosition","setWaypointScript","setWaypointStatements","setWaypointType","addWaypoint"],"notes":[{"user":"Saintolaf","date":"2008-01-01T07:48:00Z","text":"In order to change the behavior of a unit currently following some waypoints, it is not enough to use deleteWaypoint.\nTo achieve the wanted effect, you should rather use setWPPos to the unit's current position (thereby stopping the unit), and (after a small delay) use deleteWaypoint to remove the next waypoints."},{"user":"VictorFarbau","date":"2008-11-15T13:37:00Z","text":"Another (more foolproof) method to avoid the problem of non-deleteable waypoints is to introduce another group (createGroup) and join all units of the present group. A new group will start without any preset waypoints so you can start setting new WPs all over again.\nOld group is \"_combatGroup\", new group is \"_combatGroup2\"\n\n```sqf\n_combatGroup2 = createGroup east;\n{ [_x] joinSilent _combatGroup2 } forEach (units _combatGroup);\n_combatGroup2 addWaypoint [getPos player, 25];\n```"},{"user":"Mr H.","date":"2019-11-17T16:52:00Z","text":"To have the unit stop on the spot you need to set its current waypoint where it is and add a little delay, as stated above by Saintolaf so:\n\n```sqf\ngroup _unit spawn\n{\n    [_this, currentWaypoint _this] setWaypointPosition [getPosASL ((units _this) select 0), -1];\n    sleep 0.1;\n    for \"_i\" from count waypoints _this - 1 to 0 step -1 do \n    {\n        deleteWaypoint [_this, _i];\n    };\n};\n```\n\nWill stop the group where it is and delete its waypoints."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"detach","operator":null,"title":"detach","type":"command","url":"https://community.bistudio.com/wiki/detach","revid":369227,"updated":"2024-09-03T10:34:55Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Detaches previously attached with attachTo object.","syntaxes":[{"syntax":"detach object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nobj1 attachTo [player];\ndetach obj1;\n```","code":["obj1 attachTo [player];\ndetach obj1;"]}],"multiplayer":"Only has to be executed on one client.","problems":null,"aliases":[],"see_also":["attachedObjects","attachedTo","attachTo"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"detachChild","operator":null,"title":"detachChild","type":"command","url":"https://community.bistudio.com/wiki/detachChild","revid":378900,"updated":"2026-08-11T14:56:33Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Detaches previously attached with attachChild object.","syntaxes":[{"syntax":"detachChild parent","since":null,"effect":null,"exec":null,"params":[{"name":"parent","type":"Object","optional":false,"default":null,"description":"The parent object that another object is attached to. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?).","types":["Object"],"since":null,"text":"parent: Object - The parent object that another object is attached to. Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?)."}],"returns":{"type":"Nothing or Object","types":["Nothing","Object"],"description":null,"text":"Nothing or Object"},"form":"unary","operator":null,"left":null,"right":{"text":"parent","types":["Object"]}}],"examples":[{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","childAttached","parentAttached","chainedObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"detectedMines","operator":null,"title":"detectedMines","type":"command","url":"https://community.bistudio.com/wiki/detectedMines","revid":377169,"updated":"2026-01-01T10:45:10Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all mines detected by a given side","syntaxes":[{"syntax":"detectedMines side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"side","optional":false,"default":null,"description":null,"types":["side"],"since":null,"text":"side: side"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["side"]}}],"examples":[{"text":"```sqf\ndetectedMines west;\n```","code":["detectedMines west;"]},{"text":"```sqf\ndetectedMines side player;\n```","code":["detectedMines side player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","mineDetectedBy","createMine","mineActive","revealMine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"diag_activeMissionFSMs","operator":null,"title":"diag activeMissionFSMs","type":"command","url":"https://community.bistudio.com/wiki/diag_activeMissionFSMs","revid":349639,"updated":"2023-11-16T21:59:22Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.44"}],"since":{"game":"arma3","name":"Arma 3","version":"1.44"},"arma3_since":"1.44","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with active Mission FSMs. To see number of all scripts currently in the scheduler use diag_activeScripts.","syntaxes":[{"syntax":"diag_activeMissionFSMs","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"format [[name, state, timeout],...]: - name: String - state: - timeout:","text":"Array - format [[name, state, timeout],...]:\n- name: String\n- state:\n- timeout:"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ systemChat str _x } forEach diag_activeMissionFSMs;\n```","code":["{ systemChat str _x } forEach diag_activeMissionFSMs;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_activeSQSScripts","diag_activeSQFScripts","diag_log","diag_fps","diag fpsmin","diag frameno","diag_tickTime","diag_activeScripts"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.44","Scripting Commands"]},{"name":"diag_activeScripts","operator":null,"title":"diag activeScripts","type":"command","url":"https://community.bistudio.com/wiki/diag_activeScripts","revid":379080,"updated":"2026-09-27T07:38:25Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns 4 element array with numbers of currently running scripts","syntaxes":[{"syntax":"diag_activeScripts","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [spawn, execVM, exec, execFSM]","types":["Array"],"description":"spawn: Number - The number of scripts running with spawn - execVM: Number - The number of scripts running with execVM - exec: Number - The number of scripts running with exec - execFSM: Number - The number of scripts running with execFSM","text":"Array with [spawn, execVM, exec, execFSM]\n- spawn: Number - The number of scripts running with spawn\n- execVM: Number - The number of scripts running with execVM\n- exec: Number - The number of scripts running with exec\n- execFSM: Number - The number of scripts running with execFSM"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str diag_activeScripts; //[0,0,0,1]\n```","code":["hint str diag_activeScripts; //[0,0,0,1]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log","diag_fps","diag fpsmin","diag frameno","diag_tickTime","diag_activeSQFScripts","diag_activeSQSScripts","diag_activeMissionFSMs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"diag_activeSQFScripts","operator":null,"title":"diag activeSQFScripts","type":"command","url":"https://community.bistudio.com/wiki/diag_activeSQFScripts","revid":363594,"updated":"2024-04-07T18:45:53Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.44"}],"since":{"game":"arma3","name":"Arma 3","version":"1.44"},"arma3_since":"1.44","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns information about active SQF scripts. To see number of all scripts currently in the scheduler use diag_activeScripts.","syntaxes":[{"syntax":"diag_activeSQFScripts","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Arrays","types":["Array"],"description":"to format [[scriptName, fileName, isRunning, currentLine], ...]: - scriptName: String - Returns: - Script name set with scriptName - File name if script name is empty - <spawn> + first 100 characters if script name and file name are both empty - filePath: String - path of the parent script - isRunning: Boolean - currentLine: Number - line currently executing","text":"Array of Arrays - to format [[scriptName, fileName, isRunning, currentLine], ...]:\n- scriptName: String - Returns:\n  - Script name set with scriptName\n  - File name if script name is empty\n  - <spawn> + first 100 characters if script name and file name are both empty\n- filePath: String - path of the parent script\n- isRunning: Boolean\n- currentLine: Number - line currently executing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n0 spawn { hint str diag_activeSQFScripts; }; // displays [[\"<spawn> hint str diag_activeSQFScripts;\", \"\", true, 1]]\n```","code":["0 spawn { hint str diag_activeSQFScripts; }; // displays [[\"<spawn> hint str diag_activeSQFScripts;\", \"\", true, 1]]"]},{"text":"```sqf\n0 spawn {\n    hint str diag_activeSQFScripts; // displays [[\"<spawn> hint str diag_activeSQFScripts;\", \"\", true, 2]]\n};\n```","code":["0 spawn {\n\thint str diag_activeSQFScripts; // displays [[\"<spawn> hint str diag_activeSQFScripts;\", \"\", true, 2]]\n};"]},{"text":"```sqf\n0 spawn {\n    scriptName \"aScript\";\n    hint str diag_activeSQFScripts; // displays [[\"aScript\", \"\", true, 3]]\n};\n```","code":["0 spawn {\n\tscriptName \"aScript\";\n\thint str diag_activeSQFScripts; // displays [[\"aScript\", \"\", true, 3]]\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log","diag_fps","diag fpsmin","diag_frameNo","diag_tickTime","diag_activeSQSScripts","diag_activeMissionFSMs","diag_activeScripts","execVM","spawn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.44","Scripting Commands"]},{"name":"diag_activeSQSScripts","operator":null,"title":"diag activeSQSScripts","type":"command","url":"https://community.bistudio.com/wiki/diag_activeSQSScripts","revid":377696,"updated":"2026-01-02T09:03:19Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.44"}],"since":{"game":"arma3","name":"Arma 3","version":"1.44"},"arma3_since":"1.44","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with active SQSs. To see number of all scripts currently in the scheduler use diag_activeScripts.","syntaxes":[{"syntax":"diag_activeSQSScripts","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [[name, fileName, isRunning, currentLine],...]","types":["Array"],"description":"name: String - function or file name - fileName: String - isRunning: Boolean - currentLine: Number - line currently executing","text":"Array with [[name, fileName, isRunning, currentLine],...]\n- name: String - function or file name\n- fileName: String\n- isRunning: Boolean\n- currentLine: Number - line currently executing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ systemChat str _x } forEach diag_activeSQSScripts;\n```","code":["{ systemChat str _x } forEach diag_activeSQSScripts;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_activeMissionFSMs","diag_activeSQFScripts","diag_log","diag_fps","diag fpsmin","diag frameno","diag_tickTime","diag_activeScripts"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.44","Scripting Commands"]},{"name":"diag_allMissionEventHandlers","operator":null,"title":"diag allMissionEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/diag_allMissionEventHandlers","revid":363556,"updated":"2024-04-06T08:27:26Z","groups":["Diagnostic","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Returns an array with all mission event handlers.","syntaxes":[{"syntax":"diag_allMissionEventHandlers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"in format [\"EH1name\", EH1count, \"EH2name\", EH2count, ...]","text":"Array - in format [\"EH1name\", EH1count, \"EH2name\", EH2count, ...]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_allMissionEventHandlers;\n/*\nreturns:\n[\n    \"Ended\",0,\n    \"SelectedActionPerformed\",0,\n    \"SelectedRotorLibActionPerformed\",0,\n    \"SelectedActionChanged\",0,\n    \"SelectedRotorLibActionChanged\",0,\n    \"ControlsShifted\",0,\n    \"Draw3D\",1,\n    \"Loaded\",0,\n    \"HandleDisconnect\",0,\n    \"EntityRespawned\",0,\n    \"EntityKilled\",0,\n    \"MapSingleClick\",0,\n    \"HCGroupSelectionChanged\",0,\n    \"CommandModeChanged\",0,\n    \"PlayerConnected\",0,\n    \"PlayerDisconnected\",0,\n    \"TeamSwitch\",0,\n    \"GroupIconClick\",0,\n    \"GroupIconOverEnter\",0,\n    \"GroupIconOverLeave\",0,\n    \"EachFrame\",0,\n    \"PreloadStarted\",0,\n    \"PreloadFinished\",0,\n    \"Map\",0,\n    \"PlayerViewChanged\",0,\n    \"BuildingChanged\",0,\n    \"MPEnded\",0,\n    \"HandleAccTime\",0,\n    \"ExtensionCallback\",0\n]\n*/\n```","code":["diag_allMissionEventHandlers;\n/*\nreturns:\n[\n\t\"Ended\",0,\n\t\"SelectedActionPerformed\",0,\n\t\"SelectedRotorLibActionPerformed\",0,\n\t\"SelectedActionChanged\",0,\n\t\"SelectedRotorLibActionChanged\",0,\n\t\"ControlsShifted\",0,\n\t\"Draw3D\",1,\n\t\"Loaded\",0,\n\t\"HandleDisconnect\",0,\n\t\"EntityRespawned\",0,\n\t\"EntityKilled\",0,\n\t\"MapSingleClick\",0,\n\t\"HCGroupSelectionChanged\",0,\n\t\"CommandModeChanged\",0,\n\t\"PlayerConnected\",0,\n\t\"PlayerDisconnected\",0,\n\t\"TeamSwitch\",0,\n\t\"GroupIconClick\",0,\n\t\"GroupIconOverEnter\",0,\n\t\"GroupIconOverLeave\",0,\n\t\"EachFrame\",0,\n\t\"PreloadStarted\",0,\n\t\"PreloadFinished\",0,\n\t\"Map\",0,\n\t\"PlayerViewChanged\",0,\n\t\"BuildingChanged\",0,\n\t\"MPEnded\",0,\n\t\"HandleAccTime\",0,\n\t\"ExtensionCallback\",0\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMissionEventHandler","Arma 3: Mission Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Event Handlers","Introduced with Arma 3 version 2.00","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"diag_captureFrame","operator":null,"title":"diag captureFrame","type":"command","url":"https://community.bistudio.com/wiki/diag_captureFrame","revid":379089,"updated":"2026-09-27T09:45:01Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},"arma3_since":"1.00","branch":"diag prof","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command starts counting frames from the moment it is executed and when the count reaches the number passed as param, the current frame is captured and captured data UI dialog appears, similar to diag_captureSlowFrame. This can also be executed on a dedicated Server and because a Server has no UI it will behave like diag_captureFrameToFile.\n\n> [!IMPORTANT]\n> BattlEye's RCON variant of this command is **#captureFrame**","syntaxes":[{"syntax":"diag_captureFrame frame","since":null,"effect":null,"exec":null,"params":[{"name":"frame","type":"Number","optional":false,"default":null,"description":"next n-th frame to be captured","types":["Number"],"since":null,"text":"frame: Number - next n-th frame to be captured"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"frame","types":["Number"]}}],"examples":[{"text":"```sqf\ndiag_captureFrame 1; // capture the first frame after command execution\n```","code":["diag_captureFrame 1; // capture the first frame after command execution"]},{"text":"```sqf\ndiag_captureFrame 24; // capture 24th frame after command execution\n```","code":["diag_captureFrame 24; // capture 24th frame after command execution"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","Performance Profiling","Arma 3: Cheats","Multiplayer Server Commands","diag_captureFrameToFile","diag_captureSlowFrame","diag logSlowFrame","logEntities","exportJIPMessages"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Arma 3: Scripting Commands: Profiling Branch","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 2: Operation Arrowhead version 1.63","Scripting Commands"]},{"name":"diag_captureFrameToFile","operator":null,"title":"diag captureFrameToFile","type":"command","url":"https://community.bistudio.com/wiki/diag_captureFrameToFile","revid":318853,"updated":"2022-05-13T09:21:56Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":"diag prof","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command starts counting frames from the moment it is executed and when the count reaches the number passed as param, the current frame is captured and\nwritten to a log file in the same directory as the .rpt file.\n\nThe full Path to the log file is logged to simultaneously.\n\nThe data in the log file can be copied and pasted into the diag_captureFrame UI dialog to get a visualisation later on.","syntaxes":[{"syntax":"diag_captureFrameToFile frame","since":null,"effect":null,"exec":null,"params":[{"name":"frame","type":"Number","optional":false,"default":null,"description":"next n-th frame to be captured","types":["Number"],"since":null,"text":"frame: Number - next n-th frame to be captured"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"frame","types":["Number"]}}],"examples":[{"text":"```sqf\ndiag_captureFrameToFile 1; //capture the first frame after command execution\n```","code":["diag_captureFrameToFile 1; //capture the first frame after command execution"]},{"text":"```sqf\ndiag_captureFrameToFile 24; //capture 24th frame after command execution\n```","code":["diag_captureFrameToFile 24; //capture 24th frame after command execution"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Performance Profiling","diag_captureSlowFrame","diag logSlowFrame","diag_captureFrame","logEntities","exportJIPMessages"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Arma 3: Scripting Commands: Profiling Branch","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"diag_captureSlowFrame","operator":null,"title":"diag captureSlowFrame","type":"command","url":"https://community.bistudio.com/wiki/diag_captureSlowFrame","revid":370412,"updated":"2024-12-05T18:30:13Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},"arma3_since":"1.00","branch":"diag prof","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens \"capture frame\" dialog if current frame exceeds set threshold in seconds. One can indicate to either capture duration of a specific profiling selection or the total duration of the frame.\nThe selection names can be obtained by expanding the profiling tree. Clicking on a tree item will highlight the item on the graph and vice versa.\nThe GUI also provides method of copying of the displayed data to clipboard.\n\n> [!NOTE]\n> **Chrome export format**:\n> Capturing to file also creates a .trace file, which can be imported into chrome://tracing (in chromium based webbrowsers), or https://ui.perfetto.dev/\n>\n> The same format can be exported by pressing the \"COPY ALL\" button, in the capture frame UI, with <kbd>Ctrl</kbd> key being held down.","syntaxes":[{"syntax":"diag_captureSlowFrame [section, threshold, frameSkip, toFile, continuousCounter]","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"String","optional":false,"default":null,"description":"**case-sensitive**; some of the selections:\n\n| Render | Main Thread | Visualize | Mjob |\n|---|---|---|---|\n| - bgD3D | - total<br>- sLoop (for dedicated server)<br>- cLoop (for headless client)<br>- memAl | - visul | - Mjob |","types":["String"],"since":null,"text":"section: String - **case-sensitive**; some of the selections:\n\n| Render | Main Thread | Visualize | Mjob |\n|---|---|---|---|\n| - bgD3D | - total<br>- sLoop (for dedicated server)<br>- cLoop (for headless client)<br>- memAl | - visul | - Mjob |"},{"name":"threshold","type":"Number or Arma 3 v2.20 String","optional":false,"default":null,"description":"Number or Arma 3 v2.20 String\n- Number: section duration in seconds. 0 captures always **IF** the section you gave as section filter appears inside the given frame. \"total\" always appears, while \"callExt\" might not always appear for example.\n- String: number with unit (s / ms / us / ns / fps, e.g \"30fps\" - see [SI prefixes](https://en.wikipedia.org/wiki/Second#SI_multiples) for more unit information)\n\n> [!IMPORTANT]\n> The capture happens \"when the section/scope duration is larger/longer than this\", except with \"fps\" where it is \"when smaller/lower\".","types":["Number","String"],"since":null,"text":"threshold: Number or Arma 3 v2.20 String\n- Number: section duration in seconds. 0 captures always **IF** the section you gave as section filter appears inside the given frame. \"total\" always appears, while \"callExt\" might not always appear for example.\n- String: number with unit (s / ms / us / ns / fps, e.g \"30fps\" - see [SI prefixes](https://en.wikipedia.org/wiki/Second#SI_multiples) for more unit information)\n\n> [!IMPORTANT]\n> The capture happens \"when the section/scope duration is larger/longer than this\", except with \"fps\" where it is \"when smaller/lower\"."},{"name":"frameSkip","type":"Number","optional":true,"default":"0","description":"number of frames to ignore before measuring","types":["Number"],"since":"arma3 1.18","text":"frameSkip: Number - (Optional, default 0) number of frames to ignore before measuring"},{"name":"toFile","type":"Boolean","optional":true,"default":"false","description":"if true, doesn't open UI and writes straight to file. If logging to file, it automatically also outputs a .trace file. Note: even if false it might still force to file if it doesn't have a UI, like a server or HC","types":["Boolean"],"since":"arma3 2.20","text":"toFile: Boolean - (Optional, default false) if true, doesn't open UI and writes straight to file. If logging to file, it automatically also outputs a .trace file. Note: even if false it might still force to file if it doesn't have a UI, like a server or HC"},{"name":"continuousCounter","type":"Number","optional":true,"default":"0","description":"captures N slow frames. 0 or 1 will only capture one frame - do **not** set it to negative! Can be aborted by running diag_captureFrame or another diag_captureSlowFrame usage","types":["Number"],"since":"arma3 2.20","text":"continuousCounter: Number - (Optional, default 0) captures N slow frames. 0 or 1 will only capture one frame - do **not** set it to negative! Can be aborted by running diag_captureFrame or another diag_captureSlowFrame usage"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[section, threshold, frameSkip, toFile, continuousCounter]","types":["Array"]}}],"examples":[{"text":"```sqf\ndiag_captureSlowFrame [\"total\", 0.003];\n```","code":["diag_captureSlowFrame [\"total\", 0.003];"]},{"text":"```sqf\ndiag_captureSlowFrame [\"total\", \"0.003s\"];\n```","code":["diag_captureSlowFrame [\"total\", \"0.003s\"];"]},{"text":"```sqf\ndiag_captureSlowFrame [\"total\", \"3ms\"];\n```","code":["diag_captureSlowFrame [\"total\", \"3ms\"];"]},{"text":"```sqf\ndiag_captureSlowFrame [\"total\", \"333fps\"];\n```","code":["diag_captureSlowFrame [\"total\", \"333fps\"];"]},{"text":"```sqf\ndiag_captureSlowFrame [\"memAl\", 0.0001, 30];\n```","code":["diag_captureSlowFrame [\"memAl\", 0.0001, 30];"]},{"text":"```sqf\ndiag_captureSlowFrame [\"total\", 0, 0, false, 3]; // opens the capture UI three times\n```","code":["diag_captureSlowFrame [\"total\", 0, 0, false, 3]; // opens the capture UI three times"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","Performance Profiling","Arma 3: Cheats","Multiplayer Server Commands","diag_captureFrameToFile","diag_captureFrame","diag logSlowFrame","logEntities","exportJIPMessages"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Arma 3: Scripting Commands: Profiling Branch","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 2: Operation Arrowhead version 1.63","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_codePerformance","operator":null,"title":"diag codePerformance","type":"command","url":"https://community.bistudio.com/wiki/diag_codePerformance","revid":377699,"updated":"2026-01-02T09:03:27Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attempts to run given code with given arguments given number of cycles in unscheduled environment and returns average time it took to run the code as well as actual number of executions performed.\nThe command will return as soon as possible if the tested code is slow and the duration of the command exceeds 1 second.\nEngine alternative to BIS_fnc_codePerformance.","syntaxes":[{"syntax":"diag_codePerformance [code, arguments, cycles]","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"code to compare performance","types":["Code"],"since":null,"text":"code: Code - code to compare performance"},{"name":"arguments","type":"Anything","optional":true,"default":"nil","description":"arguments to pass to the code in _this variable. Default: nil","types":["Anything"],"since":null,"text":"arguments: Anything - (Optional, default nil) arguments to pass to the code in _this variable. Default: nil"},{"name":"cycles","type":"Number","optional":true,"default":"100000","description":"wanted number of cycles to run the given code. > 1000 is recommended","types":["Number"],"since":null,"text":"cycles: Number - (Optional, default 100000) wanted number of cycles to run the given code. > 1000 is recommended"},{"name":"ignoreTimeLimit","type":"Boolean","optional":true,"default":"false","description":"ignore the 1 second timelimit, and always run the provided number of cycles (except in multiplayer)","types":["Boolean"],"since":"arma3 2.14","text":"ignoreTimeLimit: Boolean - (Optional, default false) - ignore the 1 second timelimit, and always run the provided number of cycles (except in multiplayer)"}],"returns":{"type":"Array with [duration, cycles]","types":["Array"],"description":"duration: Number - average duration of 1 execution in milliseconds - cycles: Number - actual number of cycles executed","text":"Array with [duration, cycles]\n- duration: Number - average duration of 1 execution in milliseconds\n- cycles: Number - actual number of cycles executed"},"form":"unary","operator":null,"left":null,"right":{"text":"[code, arguments, cycles]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _result = diag_codePerformance [{ private _a = 123; }, 0, 10000];\n```","code":["private _result = diag_codePerformance [{ private _a = 123; }, 0, 10000];"]}],"multiplayer":"For security purposes, this command will only run for 1 cycle in multiplayer, unless in-game debug console is available via description.ext option or Eden attribute setting.","problems":null,"aliases":[],"see_also":["diag_log","BIS_fnc_codePerformance","Code Optimisation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"diag_deltaTime","operator":null,"title":"diag deltaTime","type":"command","url":"https://community.bistudio.com/wiki/diag_deltaTime","revid":309147,"updated":"2022-05-03T14:08:33Z","groups":["Diagnostic","Time"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the duration of the previous frame in seconds","syntaxes":[{"syntax":"diag_deltaTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _frameTime = diag_deltaTime;\n```","code":["private _frameTime = diag_deltaTime;"]},{"text":"```sqf\nprivate _fps = 1 / diag_deltaTime;\n```","code":["private _fps = 1 / diag_deltaTime;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_tickTime","diag_fps","diag_fpsMin","diag_frameNo","diag_log","time"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Time","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"diag_drawMode","operator":null,"title":"diag drawMode","type":"command","url":"https://community.bistudio.com/wiki/diag_drawMode","revid":336291,"updated":"2022-12-21T11:09:54Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.86"}],"since":{"game":"arma3","name":"Arma 3","version":"1.86"},"arma3_since":"1.86","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Activates a debug visualisation.","syntaxes":[{"syntax":"diag_drawMode type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"type of visualisation. Can be one of:\n- \"Normal\"\n- \"Roadway\"\n- \"Geometry\"\n- \"ViewGeometry\"\n- \"FireGeometry\"\n- \"Paths\"\n- \"ShadowVolume\"\n- \"ShadowBuffer\"\n- \"Buoyancy\"\n- Arma 3 v2.10 \"Wire\" - can be used along other visualisation\n  - first mode: pure wireframe, no normal rendering\n  - second mode: normal rendering combined with wireframe\n  - third mode: back to normal","types":["String"],"since":null,"text":"type: String - type of visualisation. Can be one of:\n- \"Normal\"\n- \"Roadway\"\n- \"Geometry\"\n- \"ViewGeometry\"\n- \"FireGeometry\"\n- \"Paths\"\n- \"ShadowVolume\"\n- \"ShadowBuffer\"\n- \"Buoyancy\"\n- Arma 3 v2.10 \"Wire\" - can be used along other visualisation\n  - first mode: pure wireframe, no normal rendering\n  - second mode: normal rendering combined with wireframe\n  - third mode: back to normal"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_drawMode \"FireGeometry\";\nsleep 5;\ndiag_drawMode \"Normal\";\n```","code":["diag_drawMode \"FireGeometry\";\nsleep 5;\ndiag_drawMode \"Normal\";"]},{"text":"\"Wire\" can be used along other modes:\n\n```sqf\ndiag_drawMode \"Wire\";            // switch to first Wire mode\ndiag_drawMode \"Roadway\";        // switch to Roadway like usual\n\ndiag_drawMode \"Wire\";            // switch to second Wire mode\ndiag_drawMode \"ViewGeometry\";    // switch to ViewGeometry, keeping the current Wire mode\n\ndiag_drawMode \"Wire\";            // disable Wire\n```","code":["diag_drawMode \"Wire\";\t\t\t// switch to first Wire mode\ndiag_drawMode \"Roadway\";\t\t// switch to Roadway like usual\n\ndiag_drawMode \"Wire\";\t\t\t// switch to second Wire mode\ndiag_drawMode \"ViewGeometry\";\t// switch to ViewGeometry, keeping the current Wire mode\n\ndiag_drawMode \"Wire\";\t\t\t// disable Wire"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_list"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.86","Scripting Commands"]},{"name":"diag_dumpCalltraceToLog","operator":null,"title":"diag dumpCalltraceToLog","type":"command","url":"https://community.bistudio.com/wiki/diag_dumpCalltraceToLog","revid":351629,"updated":"2023-12-11T19:47:26Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dumps current callstack/calltrace to RPT.","syntaxes":[{"syntax":"diag_dumpCalltraceToLog","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_dumpCalltraceToLog;\n/* outputs:\nCallstack:\"\n14:17:06 \"    [] L1 ()\"\n14:17:06 \"    [] L25 (A3\\functions_f\\Debug\\fn_debugConsoleExec.sqf)\"\n14:17:06 \"        _this:[{st = 15 / 0;}]\"\n14:17:06 \"    [] L0 ()\"\n14:17:06 \"    [] L25 (A3\\functions_f\\Debug\\fn_debugConsoleExec.sqf)\"\n14:17:06 \"        _x:any\"\n14:17:06 \"    [] L1 ()\"\n14:17:06 \"        _this:[]\"\n14:17:06 \"CALLSTACK END;;;\n*/\n```","code":["diag_dumpCalltraceToLog;\n/* outputs:\nCallstack:\"\n14:17:06 \"    [] L1 ()\"\n14:17:06 \"    [] L25 (A3\\functions_f\\Debug\\fn_debugConsoleExec.sqf)\"\n14:17:06 \"        _this:[{st = 15 / 0;}]\"\n14:17:06 \"    [] L0 ()\"\n14:17:06 \"    [] L25 (A3\\functions_f\\Debug\\fn_debugConsoleExec.sqf)\"\n14:17:06 \"        _x:any\"\n14:17:06 \"    [] L1 ()\"\n14:17:06 \"        _this:[]\"\n14:17:06 \"CALLSTACK END;;;\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["arma.RPT","diag_stacktrace","diag_log"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"diag_dumpScriptAssembly","operator":null,"title":"diag dumpScriptAssembly","type":"command","url":"https://community.bistudio.com/wiki/diag_dumpScriptAssembly","revid":310216,"updated":"2022-05-05T13:10:44Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dump script assembly.","syntaxes":[{"syntax":"diag_dumpScriptAssembly code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\ndiag_dumpScriptAssembly BIS_fnc_taskCreate;\n```","code":["diag_dumpScriptAssembly BIS_fnc_taskCreate;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"diag_dumpTerrainSynth","operator":null,"title":"diag dumpTerrainSynth","type":"command","url":"https://community.bistudio.com/wiki/diag_dumpTerrainSynth","revid":310309,"updated":"2022-05-05T16:20:41Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns OutsideTerrain's current world's values.","syntaxes":[{"syntax":"diag_dumpTerrainSynth","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Number, Array of Numbers: [analysisLength, [min1, max1], [min2, max2], ..., [min512, max512]]. There are 512 min/max pairs.","types":["Array","Number"],"description":"analysisLength: Number - altitude analysis distance from terrain's border towards its centre - min1..512: Number - minimum altitude - max1..512: Number - maximum altitude","text":"Array of Number, Array of Numbers: [analysisLength, [min1, max1], [min2, max2], ..., [min512, max512]]. There are 512 min/max pairs.\n- analysisLength: Number - altitude analysis distance from terrain's border towards its centre\n- min1..512: Number - minimum altitude\n- max1..512: Number - maximum altitude"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _terrainSynth = diag_dumpTerrainSynth;\n```","code":["private _terrainSynth = diag_dumpTerrainSynth;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_exportConfig","diag_exportTerrainSVG"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"diag_dynamicSimulationEnd","operator":null,"title":"diag dynamicSimulationEnd","type":"command","url":"https://community.bistudio.com/wiki/diag_dynamicSimulationEnd","revid":347048,"updated":"2023-08-28T22:05:05Z","groups":["Diagnostic","Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":"diag","locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Ends dynamic simulation data gathering and writes collected data into given (txt) file. The file is saved in the Arma 3 installation folder.\n\n```cpp\n// Example output\nEnabled time (in % of collection time)       Subject name\n  1.$                                          O Bravo 1-5\n  1.$                                          O Bravo 1-6\n  1.$                                          extraction_bike (B_Quadbike_01_F) - [3151,9662,59]\n  .....                                          ..................................\n  -1.$                                         O Bravo 1-4\n  -1.$                                         target_1 (O_SAM_System_04_F) - [3571,9878,70]\n  -1.$                                         O Alpha 3-4\nCollection took 0.0s\n```","syntaxes":[{"syntax":"diag_dynamicSimulationEnd file","since":null,"effect":null,"exec":null,"params":[{"name":"file","type":"String","optional":false,"default":null,"description":"file name without extension","types":["String"],"since":null,"text":"file: String - file name without extension"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"file","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_dynamicSimulationEnd \"dynSimDebugData\"; // creates a file called \"dynSimDebugData_runtimelog.txt\"\n```","code":["diag_dynamicSimulationEnd \"dynSimDebugData\"; // creates a file called \"dynSimDebugData_runtimelog.txt\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Dynamic Simulation","diag_dynamicSimulationStart"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"diag_dynamicSimulationStart","operator":null,"title":"diag dynamicSimulationStart","type":"command","url":"https://community.bistudio.com/wiki/diag_dynamicSimulationStart","revid":349478,"updated":"2023-11-08T17:06:18Z","groups":["Dynamic Simulation","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":"diag","locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Starts gathering Arma 3: Dynamic Simulation diagnostic data.","syntaxes":[{"syntax":"diag_dynamicSimulationStart","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_dynamicSimulationStart;\n```","code":["diag_dynamicSimulationStart;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_dynamicSimulationEnd","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"diag_enable","operator":null,"title":"diag enable","type":"command","url":"https://community.bistudio.com/wiki/diag_enable","revid":349134,"updated":"2023-11-08T14:49:45Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggles various diagnostics.","syntaxes":[{"syntax":"mode diag_enable state","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"String","optional":false,"default":null,"description":"see Arma 3: Diagnostics Exe","types":["String"],"since":null,"text":"mode: String - see Arma 3: Diagnostics Exe"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to enable diag mode, false to disable it","types":["Boolean"],"since":null,"text":"state: Boolean - true to enable diag mode, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"mode","types":["String"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\n\"All\" diag_enable true;\n```","code":["\"All\" diag_enable true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","diag_toggle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"diag_enabled","operator":null,"title":"diag enabled","type":"command","url":"https://community.bistudio.com/wiki/diag_enabled","revid":369346,"updated":"2024-09-03T18:43:02Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether specific diagnostic mode is activated.","syntaxes":[{"syntax":"diag_enabled mode","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"String","optional":false,"default":null,"description":"see Arma 3: Diagnostics Exe","types":["String"],"since":null,"text":"mode: String - see Arma 3: Diagnostics Exe"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when enabled, false when disabled","text":"Boolean - true when enabled, false when disabled"},"form":"unary","operator":null,"left":null,"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n\"Animation\" diag_enable true;\ndiag_enabled \"Animation\"; // returns true\n```","code":["\"Animation\" diag_enable true;\ndiag_enabled \"Animation\"; // returns true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","diag_toggle","diag_enable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"diag_exportConfig","operator":null,"title":"diag exportConfig","type":"command","url":"https://community.bistudio.com/wiki/diag_exportConfig","revid":349240,"updated":"2023-11-08T14:50:57Z","groups":["Diagnostic","Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Exports given config into file of given path.","syntaxes":[{"syntax":"diag_exportConfig [path, config]","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"file path on disc","types":["String"],"since":null,"text":"path: String - file path on disc"},{"name":"config","type":"Config","optional":false,"default":null,"description":"the config you would like to export","types":["Config"],"since":null,"text":"config: Config - the config you would like to export"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[path, config]","types":["Array"]}}],"examples":[{"text":"export an All-in-One config:\n\n```sqf\ndiag_exportConfig [\"O:/config.cpp\", configFile];\n```","code":["diag_exportConfig [\"O:/config.cpp\", configFile];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Config","Command Group: Diagnostic","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"diag_exportTerrainSVG","operator":null,"title":"diag exportTerrainSVG","type":"command","url":"https://community.bistudio.com/wiki/diag_exportTerrainSVG","revid":349370,"updated":"2023-11-08T15:35:12Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Like the old TOPOGRAPHY cheat code, exports terrain, but in modern SVG format instead of the proprietary EMF format.","syntaxes":[{"syntax":"diag_exportTerrainSVG [filePath, drawLocationNames, drawGrid, drawCountlines, drawTreeObjects, drawMountainHeightpoints, simpleRoads]","since":null,"effect":null,"exec":null,"params":[{"name":"filePath","type":"String","optional":false,"default":null,"description":"path on disk. File name and extension have to be included","types":["String"],"since":null,"text":"filePath: String - path on disk. File name and extension have to be included"},{"name":"drawLocationNames","type":"Boolean","optional":false,"default":null,"description":"whether or not to draw location names","types":["Boolean"],"since":null,"text":"drawLocationNames: Boolean - whether or not to draw location names"},{"name":"drawGrid","type":"Boolean","optional":false,"default":null,"description":"whether or not to draw grid","types":["Boolean"],"since":null,"text":"drawGrid: Boolean - whether or not to draw grid"},{"name":"drawCountlines","type":"Boolean","optional":false,"default":null,"description":"whether or not to count lines","types":["Boolean"],"since":null,"text":"drawCountlines: Boolean - whether or not to count lines"},{"name":"drawTreeObjects","type":"Boolean","optional":false,"default":null,"description":"whether or not to draw trees","types":["Boolean"],"since":null,"text":"drawTreeObjects: Boolean - whether or not to draw trees"},{"name":"drawMountainHeightpoints","type":"Boolean","optional":false,"default":null,"description":"whether or not to draw mountain height spots","types":["Boolean"],"since":null,"text":"drawMountainHeightpoints: Boolean - whether or not to draw mountain height spots"},{"name":"simpleRoads","type":"Boolean","optional":false,"default":null,"description":"simplify roads. Draw roads as one long polyline instead of separate segments. Uses average road width as overall width","types":["Boolean"],"since":null,"text":"simpleRoads: Boolean - simplify roads. Draw roads as one long polyline instead of separate segments. Uses average road width as overall width"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[filePath, drawLocationNames, drawGrid, drawCountlines, drawTreeObjects, drawMountainHeightpoints, simpleRoads]","types":["Array"]}}],"examples":[{"text":"```sqf\ndiag_exportTerrainSVG [\"C:\\Users\\USERNAME\\Desktop\\Stratis_Map.svg\", true, true, true, true, true, false]; // replace USERNAME with your username!\n```","code":["diag_exportTerrainSVG [\"C:\\Users\\USERNAME\\Desktop\\Stratis_Map.svg\", true, true, true, true, true, false]; // replace USERNAME with your username!"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"diag_fps","operator":null,"title":"diag fps","type":"command","url":"https://community.bistudio.com/wiki/diag_fps","revid":341165,"updated":"2023-05-13T22:13:12Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns average framerate calculated over last 16 frames.","syntaxes":[{"syntax":"diag_fps","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_log diag_fps;\n```","code":["diag_log diag_fps;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_fpsMin","diag_frameNo","diag_log","diag_tickTime","diag_deltaTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_fpsMin","operator":null,"title":"diag fpsMin","type":"command","url":"https://community.bistudio.com/wiki/diag_fpsMin","revid":310884,"updated":"2022-05-07T20:28:57Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns minimal framerate. Calculated from the longest frame over last 16 frames.","syntaxes":[{"syntax":"diag_fpsMin","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_minfps = diag_fpsMin;\n```","code":["_minfps = diag_fpsMin;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_fps","diag_frameNo","diag_log","diag_tickTime","diag_deltaTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_frameNo","operator":null,"title":"diag frameNo","type":"command","url":"https://community.bistudio.com/wiki/diag_frameNo","revid":341158,"updated":"2023-05-13T22:13:08Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns number of frame currently displayed.","syntaxes":[{"syntax":"diag_frameNo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_currFrameNo = diag_frameNo;\n```","code":["_currFrameNo = diag_frameNo;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_fps","diag_fpsMin","diag_log","diag_tickTime","diag_deltaTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_getTerrainGrid","operator":null,"title":"diag getTerrainGrid","type":"command","url":"https://community.bistudio.com/wiki/diag_getTerrainGrid","revid":322636,"updated":"2022-06-20T11:53:38Z","groups":["Diagnostic"],"status":"deprecated","replaced_by":["getTerrainInfo"],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns terrain cell size (size of each grid cell in the Heightmap).\n\n> [!CAUTION]\n> This information is **obsolete**. This command is subject to be removed and replaced with: getTerrainInfo","syntaxes":[{"syntax":"diag_getTerrainGrid","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"terrain grid","text":"Number - terrain grid"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _terrainGrid = diag_getTerrainGrid;\n```","code":["private _terrainGrid = diag_getTerrainGrid;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_getTerrainSegmentOffset","getTerrainGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"diag_getTerrainHeight","operator":null,"title":"diag getTerrainHeight","type":"command","url":"https://community.bistudio.com/wiki/diag_getTerrainHeight","revid":348945,"updated":"2023-11-08T14:45:37Z","groups":["Diagnostic"],"status":"deprecated","replaced_by":["getTerrainHeight"],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns terrain height at the specified location.\n\n> [!NOTE]\n> Unlike getTerrainHeightASL which  returns the exact position's height, this commands returns the apex of the terrain polygon.\n\n> [!CAUTION]\n> This information is **obsolete**. This command is subject to be removed and replaced with: getTerrainHeight","syntaxes":[{"syntax":"diag_getTerrainHeight positionWorld","since":null,"effect":null,"exec":null,"params":[{"name":"positionWorld","type":"Position2D or Position3D","optional":false,"default":null,"description":"position in world coordinates either in Position2D or Position3D","types":["Position2D","Position3D"],"since":null,"text":"positionWorld: Position2D or Position3D - position in world coordinates either in Position2D or Position3D"}],"returns":{"type":"Number","types":["Number"],"description":"terrain height","text":"Number - terrain height"},"form":"unary","operator":null,"left":null,"right":{"text":"positionWorld","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\nprivate _h = diag_getTerrainHeight position player;\n```","code":["private _h = diag_getTerrainHeight position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_setTerrainHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"diag_getTerrainSegmentOffset","operator":null,"title":"diag getTerrainSegmentOffset","type":"command","url":"https://community.bistudio.com/wiki/diag_getTerrainSegmentOffset","revid":377557,"updated":"2026-01-02T06:54:58Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the terrain segment. It is basically the same as:\n\n```sqf\n_worldPos params [\"_x\", \"_y\"];\n[floor (_x / diag_getTerrainGrid), floor (_y / diag_getTerrainGrid)];\n```","syntaxes":[{"syntax":"diag_getTerrainSegmentOffset worldPos","since":null,"effect":null,"exec":null,"params":[{"name":"worldPos","type":"Position2D or Position3D","optional":false,"default":null,"description":"world coordinates","types":["Position2D","Position3D"],"since":null,"text":"worldPos: Position2D or Position3D - world coordinates"}],"returns":{"type":"Position2D","types":["Position2D"],"description":"[x,y] of terrain segment (integer, basically pixel coordinates in heightmap)","text":"Position2D - [x,y] of terrain segment (integer, basically pixel coordinates in heightmap)"},"form":"unary","operator":null,"left":null,"right":{"text":"worldPos","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\nprivate _segmentOffset = diag_getTerrainSegmentOffset getPosWorld player;\n```","code":["private _segmentOffset = diag_getTerrainSegmentOffset getPosWorld player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_getTerrainHeight","diag_getTerrainGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"diag_lightNewLoad","operator":null,"title":"diag lightNewLoad","type":"command","url":"https://community.bistudio.com/wiki/diag_lightNewLoad","revid":309216,"updated":"2022-05-03T22:41:30Z","groups":["Lights","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Allows loading of lighting config during the gameplay (effectively changing the current scene lighting).\nFilename path can be either absolute or relative. The file must contain only the class LightingNew, which should contain lighting configuration.","syntaxes":[{"syntax":"diag_lightNewLoad path","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"the path to the config filename","types":["String"],"since":null,"text":"path: String - the path to the config filename"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"path","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_lightNewLoad \"o:\\lighting.txt\";\n```","code":["diag_lightNewLoad \"o:\\lighting.txt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_setLightNew"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Lights","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"diag_list","operator":null,"title":"diag list","type":"command","url":"https://community.bistudio.com/wiki/diag_list","revid":348389,"updated":"2023-11-08T13:00:00Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all diagnostic modes available in the game.","syntaxes":[{"syntax":"diag_list mode","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"String","optional":false,"default":null,"description":"can be `\"toggle\"` or `\"drawMode\"`","types":["String"],"since":null,"text":"mode: String - can be `\"toggle\"` or `\"drawMode\"`"}],"returns":{"type":"Array","types":["Array"],"description":"[\"Force\", \"Animation\", \"Mines\", \"HitPoints\", \"AnimSrcUnit\", \"AnimSrcTarget\", \"Suspension\", \"EPEForce\", \"EPEVehicle\", \"ParticleNames\", \"Particles\", \"SurfaceUnder\", \"AISkill\", \"AIDriving\", \"AIAiming\", \"AIBrain\", \"AIDynamicError\", \"AISuppression\"] Arma 3 v1.66","text":"Array - [\"Force\", \"Animation\", \"Mines\", \"HitPoints\", \"AnimSrcUnit\", \"AnimSrcTarget\", \"Suspension\", \"EPEForce\", \"EPEVehicle\", \"ParticleNames\", \"Particles\", \"SurfaceUnder\", \"AISkill\", \"AIDriving\", \"AIAiming\", \"AIBrain\", \"AIDynamicError\", \"AISuppression\"] Arma 3 v1.66"},"form":"unary","operator":null,"left":null,"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_list \"toggle\";\n```","code":["diag_list \"toggle\";"]},{"text":"```sqf\ndiag_list \"drawMode\";\n```","code":["diag_list \"drawMode\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_toggle","diag_enable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"diag_localized","operator":null,"title":"diag localized","type":"command","url":"https://community.bistudio.com/wiki/diag_localized","revid":377085,"updated":"2026-01-01T09:43:24Z","groups":["Strings","Localization"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all localized keys from the given stringtable or the array of all stringtables names if empty string `\"\"` is given. Common stringtables are: `\"Global\"`, `\"Mission\"`, `\"Campaign\"`.","syntaxes":[{"syntax":"diag_localized stringtable","since":null,"effect":null,"exec":null,"params":[{"name":"stringtable","type":"String","optional":false,"default":null,"description":"stringtable name or \"\"","types":["String"],"since":null,"text":"stringtable: String - stringtable name or \"\""}],"returns":{"type":"Array Strings","types":["Array","String"],"description":"see description","text":"Array Strings - see description"},"form":"unary","operator":null,"left":null,"right":{"text":"stringtable","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _randomKey = selectRandom diag_localized \"Global\";\nhint format [\"Key: %1\\nValue: %2\", _randomKey, localize _randomKey];\n```","code":["private _randomKey = selectRandom diag_localized \"Global\";\nhint format [\"Key: %1\\nValue: %2\", _randomKey, localize _randomKey];"]},{"text":"```sqf\nprivate _allTables = diag_localized \"\";\n```","code":["private _allTables = diag_localized \"\";"]},{"text":"```sqf\ndiag_localized \"Global\" select 0; // \"$STR_A3_SHOWCASE_SLINGLOADING_15_AMMODROPPED_PIL_0\"\n```","code":["diag_localized \"Global\" select 0; // \"$STR_A3_SHOWCASE_SLINGLOADING_15_AMMODROPPED_PIL_0\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["localize","isLocalized","getTextRaw","Stringtable.csv","Stringtable.xml","BIS_fnc_localize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Localization","Command Group: Strings","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"diag_log","operator":null,"title":"diag log","type":"command","url":"https://community.bistudio.com/wiki/diag_log","revid":351628,"updated":"2023-12-11T19:47:08Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dumps the argument's value to the report file. Each call creates a new line in the file.","syntaxes":[{"syntax":"diag_log output","since":null,"effect":null,"exec":null,"params":[{"name":"output","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"output: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"output","types":["Anything"]}}],"examples":[{"text":"```sqf\ndiag_log time;\n```","code":["diag_log time;"]},{"text":"```sqf\ndiag_log format [\"%1, %2\", player, time];\n```","code":["diag_log format [\"%1, %2\", player, time];"]},{"text":"```sqf\n_array = [1, \"foo\", player, \"bar\"];\n{\n    diag_log _x;\n} forEach _array ; // creates 4 entries on 4 lines\n```","code":["_array = [1, \"foo\", player, \"bar\"];\n{\n\tdiag_log _x;\n} forEach _array ; // creates 4 entries on 4 lines"]},{"text":"```sqf\n_array = [1, \"foo\", player, \"bar\"];\ndiag_log _array; // Creates one entry of e.g. [1,\"foo\",B Alpha 1-1:1 (Player Name),\"bar\"]\n```","code":["_array = [1, \"foo\", player, \"bar\"];\ndiag_log _array; // Creates one entry of e.g. [1,\"foo\",B Alpha 1-1:1 (Player Name),\"bar\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["arma.RPT","diag_dumpCalltraceToLog","diag_stacktrace","copyToClipboard","copyFromClipboard","diag_fps","diag_fpsMin","diag_frameNo","diag_tickTime","diag_deltaTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_mergeConfigFile","operator":null,"title":"diag mergeConfigFile","type":"command","url":"https://community.bistudio.com/wiki/diag_mergeConfigFile","revid":364163,"updated":"2024-05-05T10:46:42Z","groups":["Diagnostic","Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Updates config without restarting. Attributes and classes can not be deleted unless `delete` is used. Changes to the config are applied to all new entities, a mission restart is not necessarily required. Spawning the vehicle again or switching weapons works too. Since Arma 3 v1.70 CfgAmmo should be mergeable as well.\n\n> [!WARNING]\n> Merging a config with an include statement, that points to a non existing file, will crash the game.","syntaxes":[{"syntax":"diag_mergeConfigFile [path, userdir]","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"absolute or relative path","types":["String"],"since":null,"text":"path: String - absolute or relative path"},{"name":"userdir","type":"Boolean","optional":true,"default":"false","description":"path is relative to the user directory, otherwise it is relative to the mission directory","types":["Boolean"],"since":null,"text":"userdir: Boolean - (Optional, default false) path is relative to the user directory, otherwise it is relative to the mission directory"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[path, userdir]","types":["Array"]}}],"examples":[{"text":"```sqf\ndiag_mergeConfigFile [\"O:\\Arma3\\A3\\Stuff_F\\config.cpp\"]\n```","code":["diag_mergeConfigFile [\"O:\\Arma3\\A3\\Stuff_F\\config.cpp\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Config","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"diag_recordTurretLimits","operator":null,"title":"diag recordTurretLimits","type":"command","url":"https://community.bistudio.com/wiki/diag_recordTurretLimits","revid":309925,"updated":"2022-05-05T12:16:58Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Start recording tool for creating turret aiming limits.","syntaxes":[{"syntax":"diag_recordTurretLimits section","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"section: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"section","types":["Boolean"]}}],"examples":[{"text":"```sqf\ndiag_recordTurretLimits true;\n```","code":["diag_recordTurretLimits true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"diag_remainsCollector","operator":null,"title":"diag remainsCollector","type":"command","url":"https://community.bistudio.com/wiki/diag_remainsCollector","revid":377638,"updated":"2026-01-02T08:52:35Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current settings for the remains collector and the list of monitored units if any.","syntaxes":[{"syntax":"diag_remainsCollector option","since":null,"effect":null,"exec":null,"params":[{"name":"option","type":"Number","optional":false,"default":null,"description":"can be one of:\n- -1: Arma 3 v2.20 log remains collector entities into a file in the RPT directory - see also the REMAINS cheat and the `1. logremains` server command.\n\n> [!IMPORTANT]\n> Only available in Diagnostic/Profiling branch.\n\n- 0: corpses - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 1: wrecks - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 2: weaponholders - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 3: Arma 3 v2.20 overrideTimes - returns [overrideTimeCorpses, overrideTimeWrecks, overrideTimeWeaponholders]","types":["Number"],"since":null,"text":"option: Number - can be one of:\n- -1: Arma 3 v2.20 log remains collector entities into a file in the RPT directory - see also the REMAINS cheat and the `1. logremains` server command.\n\n> [!IMPORTANT]\n> Only available in Diagnostic/Profiling branch.\n\n- 0: corpses - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 1: wrecks - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 2: weaponholders - returns [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...]\n- 3: Arma 3 v2.20 overrideTimes - returns [overrideTimeCorpses, overrideTimeWrecks, overrideTimeWeaponholders]"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array with [disposalPeriod, managerMode, removeLimit, removeMinTime, removeMaxTime, minPlayerDistance, unit1, unit2...] or [overrideTimeCorpses, overrideTimeWrecks, overrideTimeWeaponholders]"},"form":"unary","operator":null,"left":null,"right":{"text":"option","types":["Number"]}}],"examples":[{"text":"```sqf\nhintSilent str diag_remainsCollector 0;\n```","code":["hintSilent str diag_remainsCollector 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addToRemainsCollector","removeFromRemainsCollector","isInRemainsCollector"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"diag_resetAnims","operator":null,"title":"diag resetAnims","type":"command","url":"https://community.bistudio.com/wiki/diag_resetAnims","revid":353741,"updated":"2024-03-22T13:45:12Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Resets the animations system cache, so that animation makers can test their animations without restarting the game. A **mission restart** is required for the changes to be applied.","syntaxes":[{"syntax":"diag_resetAnims","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_resetShapes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"diag_resetShapes","operator":null,"title":"diag resetShapes","type":"command","url":"https://community.bistudio.com/wiki/diag_resetShapes","revid":310721,"updated":"2022-05-07T19:53:41Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Reload models on-the-fly without the need of restarting the game.\nChanges applied by **diag_resetShapes** are applied to all new entities so restart of mission is not necessarily  required - spawning vehicle again or changing back forth weapon should usually do the trick.\nIt works only with `-filePatching` in combination with local data. Command will reload **only** models present in local data.\n\n> [!NOTE]\n> Limitation: `CfgSkeletons` (inside `model.cfg`) cannot be reloaded.","syntaxes":[{"syntax":"diag_resetShapes","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_resetShapes;\n```","code":["diag_resetShapes;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"diag_scope","operator":null,"title":"diag scope","type":"command","url":"https://community.bistudio.com/wiki/diag_scope","revid":369074,"updated":"2024-09-02T20:25:00Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns script scope depth. When script is directly executed by the engine or a new script is added to the scheduler, the scope depth is 0.\nThe examples of such execution are event handlers, spawn, etc. isNil Code will also create a parent scope.\nAny use of call and such will stack execution creating child scopes and increasing scope depth.","syntaxes":[{"syntax":"diag_scope","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n0 spawn\n{ \n    systemChat str diag_scope; // 0\n    call \n    { \n        call\n        { \n            systemChat str diag_scope; // 2\n            isNil \n            { \n                systemChat str diag_scope; // 0\n                call \n                {\n                    systemChat str diag_scope; // 1\n                };\n            };\n        };\n    };\n};\n```","code":["0 spawn\n{ \n\tsystemChat str diag_scope; // 0\n\tcall \n\t{ \n\t\tcall\n\t\t{ \n\t\t\tsystemChat str diag_scope; // 2\n\t\t\tisNil \n\t\t\t{ \n\t\t\t\tsystemChat str diag_scope; // 0\n\t\t\t\tcall \n\t\t\t\t{\n\t\t\t\t\tsystemChat str diag_scope; // 1\n\t\t\t\t};\n\t\t\t};\n\t\t};\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["exitWith","diag_fps","diag_fpsMin","diag_frameNo","diag_log","diag_tickTime","diag_deltaTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"diag_setLightNew","operator":null,"title":"diag setLightNew","type":"command","url":"https://community.bistudio.com/wiki/diag_setLightNew","revid":348341,"updated":"2023-11-08T12:59:48Z","groups":["Lights","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Overrides currently used scene lighting. The operand is config that is placed as a string (not file).\nThe changes may not be applied immediately, but can be forced by the call of simulWeatherSync.","syntaxes":[{"syntax":"diag_setLightNew config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"String","optional":false,"default":null,"description":"config in string form","types":["String"],"since":null,"text":"config: String - config in string form"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_setLightNew \"sunOrMoon = 1; diffuse[] = { 0, 0, 0, 0 }; diffuseCloud[] = { 0, 0, 0, 0 }; ambient[] = { 0, 0, 0, 0 }; ... \";\n```","code":["diag_setLightNew \"sunOrMoon = 1; diffuse[] = { 0, 0, 0, 0 }; diffuseCloud[] = { 0, 0, 0, 0 }; ambient[] = { 0, 0, 0, 0 }; ... \";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_lightNewLoad"],"notes":[{"user":"POLPOX","date":"2023-05-14T10:50:07Z","text":"The change is permanent (you can see the change even after you change the mission/terrain.) However, you can send an empty string to reset the lighting."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Lights","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"diag_setTerrainHeight","operator":null,"title":"diag setTerrainHeight","type":"command","url":"https://community.bistudio.com/wiki/diag_setTerrainHeight","revid":377518,"updated":"2026-01-02T06:52:04Z","groups":["Diagnostic"],"status":"deprecated","replaced_by":["setTerrainHeight"],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the terrain height of the cell in which given position lies. This command is only available with Arma 3: Diagnostics Exe.\n\n> [!WARNING]\n> This causes an instant CTD when *position* is out of the map! (`< 0` and/or `> worldSize`)\n\n> [!CAUTION]\n> This information is **obsolete**. This command is subject to be removed and replaced with: setTerrainHeight","syntaxes":[{"syntax":"position diag_setTerrainHeight height","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"position","types":["Position"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _fnc_flattenTerrain =\n{\n    params [\"_start\", \"_a\", \"_b\", \"_h\"];\n\n    for \"_xStep\" from 0 to _a do\n    {\n        for \"_yStep\" from 0 to _b do\n        {\n            _start vectorAdd [_xStep, _yStep, 0] diag_setTerrainHeight _h;\n        };\n    };\n};\n\nprivate _desiredTerrainHeight = 150;\n[getPosWorld player, 50, 50, _desiredTerrainHeight] spawn _fnc_flattenTerrain;\n```","code":["private _fnc_flattenTerrain =\n{\n\tparams [\"_start\", \"_a\", \"_b\", \"_h\"];\n\n\tfor \"_xStep\" from 0 to _a do\n\t{\n\t\tfor \"_yStep\" from 0 to _b do\n\t\t{\n\t\t\t_start vectorAdd [_xStep, _yStep, 0] diag_setTerrainHeight _h;\n\t\t};\n\t};\n};\n\nprivate _desiredTerrainHeight = 150;\n[getPosWorld player, 50, 50, _desiredTerrainHeight] spawn _fnc_flattenTerrain;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_getTerrainHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"diag_SQFCDebugDump","operator":null,"title":"diag SQFCDebugDump","type":"command","url":"https://community.bistudio.com/wiki/diag_SQFCDebugDump","revid":364932,"updated":"2024-07-01T10:20:08Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dumps the bytecode as Arma 3 sees it, in a diff friendly way. Useful for testing custom SQFC compilers.","syntaxes":[{"syntax":"diag_SQFCDebugDump [sourcePath, targetPath]","since":null,"effect":null,"exec":null,"params":[{"name":"sourcePath","type":"String","optional":false,"default":null,"description":"Path to file on drive that should be read","types":["String"],"since":null,"text":"sourcePath: String - Path to file on drive that should be read"},{"name":"targetPath","type":"String","optional":false,"default":null,"description":"Path to file on drive to output to","types":["String"],"since":null,"text":"targetPath: String - Path to file on drive to output to"}],"returns":{"type":"Code","types":["Code"],"description":"compiled expression (If parsing was successful)","text":"Code - compiled expression (If parsing was successful)"},"form":"unary","operator":null,"left":null,"right":{"text":"[sourcePath, targetPath]","types":["Array"]}}],"examples":[{"text":"```sqf\ndiag_SQFCDebugDump [\"P:/test.sqfc\", \"P:/dump\"];\n```","code":["diag_SQFCDebugDump [\"P:/test.sqfc\", \"P:/dump\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"diag_stacktrace","operator":null,"title":"diag stacktrace","type":"command","url":"https://community.bistudio.com/wiki/diag_stacktrace","revid":351630,"updated":"2023-12-11T19:47:32Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array containing the function name, line number, scope name and all local variables in form of a hashmap.","syntaxes":[{"syntax":"diag_stacktrace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Arrays, in format: ```sqf params [\"_functionName\", \"_lineNumber\", \"_scopeName\", \"_variablesHashmap\"]; ```","types":["Array"],"description":"_functionName: String - function name - _lineNumber: Number - line number - _scopeName: String - scope name - _variablesHashmap: HashMap - all local variables","text":"Array of Arrays, in format:\n\n```sqf\nparams [\"_functionName\", \"_lineNumber\", \"_scopeName\", \"_variablesHashmap\"];\n```\n\n- _functionName: String - function name\n- _lineNumber: Number - line number\n- _scopeName: String - scope name\n- _variablesHashmap: HashMap - all local variables"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _testvar = 1;\nprivate _testother = 2;\ncall \n{\n    _testvar = 3;\n    if (_testvar == 3) then \n    {\n        _myVariable = 4;\n        hint str diag_stacktrace;\n    };\n};\n/*\n[\n    [\"\", 3, \"\", [[\"_this\", []], [\"_testother\", 2], [\"_testvar\", 3]]],\n    [\"\", 6, \"\", []],\n    [\"\", 8, \"\", [[\"_myvariable\", 4]]]\n]\n*/\n```","code":["private _testvar = 1;\nprivate _testother = 2;\ncall \n{\n\t_testvar = 3;\n\tif (_testvar == 3) then \n\t{\n\t\t_myVariable = 4;\n\t\thint str diag_stacktrace;\n\t};\n};\n/*\n[\n\t[\"\", 3, \"\", [[\"_this\", []], [\"_testother\", 2], [\"_testvar\", 3]]],\n\t[\"\", 6, \"\", []],\n\t[\"\", 8, \"\", [[\"_myvariable\", 4]]]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["arma.RPT","diag_dumpCalltraceToLog","diag_log"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"diag_testScriptSimpleVM","operator":null,"title":"diag testScriptSimpleVM","type":"command","url":"https://community.bistudio.com/wiki/diag_testScriptSimpleVM","revid":373686,"updated":"2025-06-12T19:27:16Z","groups":["Diagnostic","Performance Profiling"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":"diag prof","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Outputs the provided SQF code's end code.","syntaxes":[{"syntax":"diag_testScriptSimpleVM code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"the code to process","types":["Code"],"since":null,"text":"code: Code - the code to process"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nprivate _result = diag_testScriptSimpleVM { leader _x == _x && { alive _x && { not captive _x } } };\nhint str _result;\n/*\n[\"Success\", 360, \"\n0000:const any\n0010:unary leader (variants 3)\n0060:const any\n0070:binary == (variants 2)\n00C8:jmpIfFalse 0160\n00D8:const any\n00E8:unary alive (variants 1)\n0108:jmpIfFalse 0160\n0118:const any\n0128:unary captive (variants 1)\n0148:unary not (variants 1)\n0160:ret(implicit)\n\"]\n*/\n```","code":["private _result = diag_testScriptSimpleVM { leader _x == _x && { alive _x && { not captive _x } } };\nhint str _result;\n/*\n[\"Success\", 360, \"\n0000:const any\n0010:unary leader (variants 3)\n0060:const any\n0070:binary == (variants 2)\n00C8:jmpIfFalse 0160\n00D8:const any\n00E8:unary alive (variants 1)\n0108:jmpIfFalse 0160\n0118:const any\n0128:unary captive (variants 1)\n0148:unary not (variants 1)\n0160:ret(implicit)\n\"]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","Performance Profiling"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Arma 3: Scripting Commands: Profiling Branch","Command Group: Diagnostic","Command Group: Performance Profiling","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"diag_tickTime","operator":null,"title":"diag tickTime","type":"command","url":"https://community.bistudio.com/wiki/diag_tickTime","revid":369360,"updated":"2024-09-03T18:43:06Z","groups":["Diagnostic","Time"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Real time in seconds spent from the start of the game. On Windows the command uses [timeGetTime](https://docs.microsoft.com/en-us/windows/win32/api/timeapi/nf-timeapi-timegettime).","syntaxes":[{"syntax":"diag_tickTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"time in seconds from game start","text":"Number - time in seconds from game start"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// Measure execution time of a script\n_start = diag_tickTime;\n// code\n_stop = diag_tickTime;\ndiag_log format [\"%1\",_stop - _start];\n```","code":["// Measure execution time of a script\n_start = diag_tickTime;\n// code\n_stop = diag_tickTime;\ndiag_log format [\"%1\",_stop - _start];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_fps","diag_fpsMin","diag_frameNo","diag_log","diag_deltaTime","time","systemTime","systemTimeUTC"],"notes":[{"user":"DreadedEntity","date":"2022-04-13T23:20:29Z","text":"This command keeps incrementing if the player has paused the game, even in singleplayer. If time spent paused should not be considered, use time"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Time","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diag_toggle","operator":null,"title":"diag toggle","type":"command","url":"https://community.bistudio.com/wiki/diag_toggle","revid":369317,"updated":"2024-09-03T18:42:56Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggles various diagnostics.","syntaxes":[{"syntax":"diag_toggle mode","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"String","optional":false,"default":null,"description":"see Arma 3: Diagnostics Exe","types":["String"],"since":null,"text":"mode: String - see Arma 3: Diagnostics Exe"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\ndiag_toggle \"Animation\"; // enable\ndiag_toggle \"Animation\"; // disable\n```","code":["diag_toggle \"Animation\"; // enable\ndiag_toggle \"Animation\"; // disable"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Diagnostics Exe","diag_enable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"dialog","operator":null,"title":"dialog","type":"command","url":"https://community.bistudio.com/wiki/dialog","revid":318841,"updated":"2022-05-13T09:21:55Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Tests whether any user dialog is open.","syntaxes":[{"syntax":"dialog","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if a dialog is open, false if not","text":"Boolean - true if a dialog is open, false if not"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (!dialog) then { createDialog \"Dialog1\"; };\n```","code":["if (!dialog) then { createDialog \"Dialog1\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDisplay","createDialog","closeDialog","Arma: GUI Configuration"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.78","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"diaryRecordNull","operator":null,"title":"diaryRecordNull","type":"command","url":"https://community.bistudio.com/wiki/diaryRecordNull","revid":340843,"updated":"2023-05-10T14:37:02Z","groups":["Briefing","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existent Diary Record. To compare non-existent objects use isNull or isEqualTo:\n\n```sqf\ndiaryRecordNull == diaryRecordNull;        // false\nisNull diaryRecordNull;                        // true\ndiaryRecordNull isEqualTo diaryRecordNull;    // true\n```\n\n> [!NOTE]\n> Before Arma 3 v2.00, isNull did not work with the diary record type and diaryRecordNull did not exist.\n> In order to verify a null record, it is possible to create a variable and compare against it:\n>\n> ```sqf\n> private _diaryRecordNull = objNull createDiaryRecord [];\n> private _createdRecord = player createDiaryRecord [\"Diary\", [\"Title\", \"Description\"]];\n> if (_createdRecord isEqualTo _diaryRecordNull) then { hint \"Failed\"; };\n> ```","syntaxes":[{"syntax":"diaryRecordNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Diary Record","types":["Diary Record"],"description":null,"text":"Diary Record"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nisNull diaryRecordNull; // true\n```","code":["isNull diaryRecordNull; // true"]},{"text":"```sqf\nisNull (objNull createDiaryRecord [\"Diary\", [\"Title\", \"Text\"]]); // true - objNull cannot take diary records\n```","code":["isNull (objNull createDiaryRecord [\"Diary\", [\"Title\", \"Text\"]]); // true - objNull cannot take diary records"]},{"text":"```sqf\nstr diaryRecordNull; // \"No diary record\"\n```","code":["str diaryRecordNull; // \"No diary record\""]},{"text":"```sqf\nprivate _diaryRecord = diaryRecordNull;\nif (damage player > 0.5) then\n{\n    _diaryRecord = player createDiaryRecord [\"Diary\", [\"Heal yourself\", \"Ask a medic\"]];\n};\n\nif (not isNull _diaryRecord) then { hint \"Diary record added.\"; };\n```","code":["private _diaryRecord = diaryRecordNull;\nif (damage player > 0.5) then\n{\n\t_diaryRecord = player createDiaryRecord [\"Diary\", [\"Heal yourself\", \"Ask a medic\"]];\n};\n\nif (not isNull _diaryRecord) then { hint \"Diary record added.\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["objNull","controlNull","displayNull","grpNull","locationNull","taskNull","teamMemberNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Variables","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"diarySubjectExists","operator":null,"title":"diarySubjectExists","type":"command","url":"https://community.bistudio.com/wiki/diarySubjectExists","revid":322992,"updated":"2022-06-28T21:42:59Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Checks whether given subject is present in the Diary of given player.","syntaxes":[{"syntax":"player diarySubjectExists name","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_exists = player diarySubjectExists \"subjectName\";\n```","code":["_exists = player diarySubjectExists \"subjectName\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["processDiaryLink","createDiaryLink","createDiaryRecord","createDiarySubject","allDiarySubjects"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"didJIP","operator":null,"title":"didJIP","type":"command","url":"https://community.bistudio.com/wiki/didJIP","revid":376937,"updated":"2025-12-31T22:33:08Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the current client Joined In Progress.","syntaxes":[{"syntax":"didJIP","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (didJIP) then\n{\n    hint \"you're late to the party!\";\n};\n```","code":["if (didJIP) then\n{\n\thint \"you're late to the party!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["didJIPOwner","exportJIPMessages"],"notes":[{"user":"Commy2","date":"2016-02-23T22:33:00Z","text":"reports false in `CfgFunctions` with `preInit = 1;` even when the client joined in progress."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"didJIPOwner","operator":null,"title":"didJIPOwner","type":"command","url":"https://community.bistudio.com/wiki/didJIPOwner","revid":318912,"updated":"2022-05-13T09:22:01Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Checks if the current owner of supplied Object Joined In Progress. Returns false on clients.","syntaxes":[{"syntax":"didJIPOwner object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_ownerDidJip = didJIPOwner tank;\n```","code":["_ownerDidJip = didJIPOwner tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["didJIP","owner","setOwner","groupOwner","remoteExecutedOwner","exportJIPMessages"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.50","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"difficulty","operator":null,"title":"difficulty","type":"command","url":"https://community.bistudio.com/wiki/difficulty","revid":353045,"updated":"2024-03-12T12:13:06Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns high-level selected difficulty mode.","syntaxes":[{"syntax":"difficulty","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"Can be one of: - 0 (Recruit) - 1 (Regular) - 2 (Veteran) - 3 (Elite)","text":"Number - Can be one of:\n- 0 (Recruit)\n- 1 (Regular)\n- 2 (Veteran)\n- 3 (Elite)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (difficulty == 0) then\n{\n    hint \"You will need to follow my lead - read the Field Manual!\";\n};\n```","code":["if (difficulty == 0) then\n{\n\thint \"You will need to follow my lead - read the Field Manual!\";\n};"]},{"text":"The command returns the index of selected difficulty as they appear in *CfgDifficulties*:\n\n```sqf\nhint str difficulty; //Result: 4\n```","code":["hint str difficulty; //Result: 4"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficultyOption","Arma 3: Difficulty Settings","missionDifficulty"],"notes":[{"user":"POLPOX","date":"2023-08-22T06:31:21Z","text":"The return value can be overwritten by the forcedDifficulty by the server if it is a MP session."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"difficultyEnabled","operator":null,"title":"difficultyEnabled","type":"command","url":"https://community.bistudio.com/wiki/difficultyEnabled","revid":348496,"updated":"2023-11-08T13:01:31Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks specific difficulty settings of the current user. Difficulty flag names can be found in the ArmA profile file under class Difficulties/xxx/Flags (xxx being regular or veteran).","syntaxes":[{"syntax":"difficultyEnabled flagName","since":null,"effect":null,"exec":null,"params":[{"name":"flagName","type":"String","optional":false,"default":null,"description":"difficulty flag name. Following values are available:\n\n- 3rdPersonView\n- armor\n- autoAim\n- autoGuideAT\n- autoSpot\n- autoTrimEnabled\n- cameraShake\n- clockIndicator\n- deathMessages\n- enemyTag\n- extendetInfoType\n- friendlyTag\n- hud\n- hudGroupInfo\n- hudPerm\n- hudWp\n- hudWpPerm\n- map\n- mineTag\n- netStats\n- roughLanding\n- stanceIndicator\n- stressDamageEnabled\n- unlimitedSaves\n- vonID\n- weaponCursor\n- windEnabled\n\n- 3rdPersonView\n- armor\n- autoSpot\n- autoGuideAT\n- autoAim\n- allowSeagull\n- clockIndicator\n- deathMessages\n- enemyTag\n- friendlyTag\n- hud\n- hudPerm\n- hudWp\n- hudWpPerm\n- map\n- netStats\n- suppressPlayer\n- tracers\n- realisticFatigue\n- ultraAI\n- unlimitedSaves\n- weaponCursor","types":["String"],"since":null,"text":"flagName: String - difficulty flag name. Following values are available:\n\n- 3rdPersonView\n- armor\n- autoAim\n- autoGuideAT\n- autoSpot\n- autoTrimEnabled\n- cameraShake\n- clockIndicator\n- deathMessages\n- enemyTag\n- extendetInfoType\n- friendlyTag\n- hud\n- hudGroupInfo\n- hudPerm\n- hudWp\n- hudWpPerm\n- map\n- mineTag\n- netStats\n- roughLanding\n- stanceIndicator\n- stressDamageEnabled\n- unlimitedSaves\n- vonID\n- weaponCursor\n- windEnabled\n\n- 3rdPersonView\n- armor\n- autoSpot\n- autoGuideAT\n- autoAim\n- allowSeagull\n- clockIndicator\n- deathMessages\n- enemyTag\n- friendlyTag\n- hud\n- hudPerm\n- hudWp\n- hudWpPerm\n- map\n- netStats\n- suppressPlayer\n- tracers\n- realisticFatigue\n- ultraAI\n- unlimitedSaves\n- weaponCursor"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"flagName","types":["String"]}}],"examples":[{"text":"```sqf\nhint str (difficultyEnabled \"armor\");\n```","code":["hint str (difficultyEnabled \"armor\");"]},{"text":"List current difficulty settings:\n\n```sqf\ncall {\n    private [\"_diff\", \"_cfg\", \"_flags\", \"_res\"];\n    _diff = [];\n    _cfg = configFile >> \"CfgDifficulties\";\n    {\n        _flags = _cfg >> configName _x >> \"Flags\";\n        for \"_i\" from 0 to count _flags - 1 do {\n            _diff pushBack configName (_flags select _i);\n        };\n    } forEach (\"true\" configClasses _cfg);\n    _diff = _diff arrayIntersect _diff;\n    _diff sort true;\n    _res = text \"\";\n    {\n        _res = composeText [_res, parseText format [\n            \"<t align='left'>%1 - %2</t>\", \n            _x, \n            [0, 1] select difficultyEnabled _x\n        ], lineBreak];\n    } forEach _diff;\n    hint _res;\n};\n```","code":["call {\n\tprivate [\"_diff\", \"_cfg\", \"_flags\", \"_res\"];\n\t_diff = [];\n\t_cfg = configFile >> \"CfgDifficulties\";\n\t{\n\t\t_flags = _cfg >> configName _x >> \"Flags\";\n\t\tfor \"_i\" from 0 to count _flags - 1 do {\n\t\t\t_diff pushBack configName (_flags select _i);\n\t\t};\n\t} forEach (\"true\" configClasses _cfg);\n\t_diff = _diff arrayIntersect _diff;\n\t_diff sort true;\n\t_res = text \"\";\n\t{\n\t\t_res = composeText [_res, parseText format [\n\t\t\t\"<t align='left'>%1 - %2</t>\", \n\t\t\t_x, \n\t\t\t[0, 1] select difficultyEnabled _x\n\t\t], lineBreak];\n\t} forEach _diff;\n\thint _res;\n};"]}],"multiplayer":"This command checks the difficulty flags of the computer (client/server) where it is executed.\n\n> [!NOTE]\n> This command is **deprecated since Arma 3 v1.58**. Since this version it always returns false. Use difficultyOption instead.\n> See Arma 3 Difficulty Overhaul for further details.\n> - Stress damage is a separate difficulty setting. There are two dedicated commands for it:\n>   - enableStressDamage\n>   - isStressDamageEnabled\n> - Auto trim is also a separate difficulty setting. There are also two dedicated commands for it:\n>   - enableAutoTrimRTD\n>   - isAutoTrimOnRTD","problems":null,"aliases":[],"see_also":["difficultyOption","difficulty","difficultyEnabledRTD","Arma 3: Difficulty Settings"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"difficultyEnabledRTD","operator":null,"title":"difficultyEnabledRTD","type":"command","url":"https://community.bistudio.com/wiki/difficultyEnabledRTD","revid":339089,"updated":"2023-04-26T10:54:08Z","groups":["RTD","Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if Advanced Flight Model is enabled.\nForcing of rotorlib simulation could be done with mission param forceRotorLibSimulation.","syntaxes":[{"syntax":"difficultyEnabledRTD","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_rtdOn = difficultyEnabledRTD;\n```","code":["_rtdOn = difficultyEnabledRTD;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficultyEnabled","isObjectRTD","Description.ext"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"difficultyOption","operator":null,"title":"difficultyOption","type":"command","url":"https://community.bistudio.com/wiki/difficultyOption","revid":369140,"updated":"2024-09-03T10:34:36Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks specific difficulty settings of the current user.\nDifficulty flag names can be found in the `CfgDifficultyPresets` config class or in ArmA profile file under class `DifficultyPresets/xxx/Options` (xxx being Recruit, Regular or Veteran).\nThis command replaces difficultyEnabled as many options have multiple values and former command only provided Boolean return.","syntaxes":[{"syntax":"difficultyOption optionName","since":null,"effect":null,"exec":null,"params":[{"name":"optionName","type":"String","optional":false,"default":null,"description":"difficulty option name; one of:\n- reducedDamage\n- groupIndicators\n- friendlyTags\n- enemyTags\n- detectedMines\n- commands\n- waypoints\n- weaponInfo\n- stanceIndicator\n- staminaBar\n- weaponCrosshair\n- visionAid\n- thirdPersonView\n- cameraShake\n- scoreTable\n- deathMessages\n- vonID\n- mapContent\n- autoReport\n- multipleSaves","types":["String"],"since":null,"text":"optionName: String - difficulty option name; one of:\n- reducedDamage\n- groupIndicators\n- friendlyTags\n- enemyTags\n- detectedMines\n- commands\n- waypoints\n- weaponInfo\n- stanceIndicator\n- staminaBar\n- weaponCrosshair\n- visionAid\n- thirdPersonView\n- cameraShake\n- scoreTable\n- deathMessages\n- vonID\n- mapContent\n- autoReport\n- multipleSaves"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"optionName","types":["String"]}},{"syntax":"difficultyOption array","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"array","type":"Array","optional":false,"default":null,"description":"any array, could be empty array []","types":["Array"],"since":null,"text":"array: Array - any array, could be empty array []"}],"returns":{"type":"Array","types":["Array"],"description":"array of all options and current values in format [[\"Option1\", value1], ...[\"OptionN\", valueN]]","text":"Array - array of all options and current values in format [[\"Option1\", value1], ...[\"OptionN\", valueN]]"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array"]}}],"examples":[{"text":"```sqf\nhint str (difficultyOption \"friendlyTags\");\n```","code":["hint str (difficultyOption \"friendlyTags\");"]},{"text":"Remember last cameraView per vehicle:\n\n```sqf\nplayer addEventHandler [\"GetOutMan\", {\n    params [\"_unit\", \"\", \"_vehicle\"];\n    _unit setVariable [_vehicle call BIS_fnc_netId, cameraView];\n}];\nplayer addEventHandler [\"GetInMan\", {\n    if (difficultyOption \"thirdPersonView\" == 2) then {\n        params [\"_unit\", \"\", \"_vehicle\"];\n        _unit switchCamera (_unit getVariable [_vehicle call BIS_fnc_netId, \"INTERNAL\"]);\n    };\n}];\n```","code":["player addEventHandler [\"GetOutMan\", {\n\tparams [\"_unit\", \"\", \"_vehicle\"];\n\t_unit setVariable [_vehicle call BIS_fnc_netId, cameraView];\n}];\nplayer addEventHandler [\"GetInMan\", {\n\tif (difficultyOption \"thirdPersonView\" == 2) then {\n\t\tparams [\"_unit\", \"\", \"_vehicle\"];\n\t\t_unit switchCamera (_unit getVariable [_vehicle call BIS_fnc_netId, \"INTERNAL\"]);\n\t};\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficulty","difficultyEnabledRTD","Arma 3: Difficulty Settings","missionDifficulty"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"direction","operator":null,"title":"direction","type":"command","url":"https://community.bistudio.com/wiki/direction","revid":376966,"updated":"2026-01-01T05:58:04Z","groups":["Object Manipulation","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the direction an object or a location is facing (differs from getDir in that this also works with locations).","syntaxes":[{"syntax":"direction object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object or Location","optional":false,"default":null,"description":null,"types":["Object","Location"],"since":null,"text":"object: Object or Location"}],"returns":{"type":"Number in range 0..360","types":["Number"],"description":"Direction in degrees","text":"Number in range 0..360 - Direction in degrees"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object","Location"]}}],"examples":[{"text":"```sqf\nplayer setDir 90;\n_d = direction player;//returns 90\n```","code":["player setDir 90;\n_d = direction player;//returns 90"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDir","getDirVisual","setDir","setDirection"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"directionStabilizationEnabled","operator":null,"title":"directionStabilizationEnabled","type":"command","url":"https://community.bistudio.com/wiki/directionStabilizationEnabled","revid":377493,"updated":"2026-01-02T06:49:17Z","groups":["Camera Control","Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get state of direction stabilization. This command returns true if the current optic mode of the selected turret has direction stabilization configured in config (`directionStabilized`) and if it is also not disabled by enableDirectionStabilization.\n\nThis command can not be used to determine if the current optic of the turret has `directionStabilized` enabled in config.","syntaxes":[{"syntax":"vehicle directionStabilizationEnabled turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"whether direction stabilization is enabled","text":"Boolean - whether direction stabilization is enabled"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nuav directionStabilizationEnabled [0];\n```","code":["uav directionStabilizationEnabled [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDirectionStabilization","lockCameraTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Turrets","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"directSay","operator":null,"title":"directSay","type":"command","url":"https://community.bistudio.com/wiki/directSay","revid":376774,"updated":"2025-11-17T00:05:11Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends given audio message to the direct channel. Command operates just like xxxxRadio commands, but the sound is played over direct channel and is independent of fadeSound. The message is defined in CfgRadio in the description.ext file or config radio protocol or a kbAddTopic. The transmission will play only on the PC where command was executed. If you need the transmission to play on all computers, you have to execute it globally (see remoteExec). Use clearRadio to clear chat history\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit directSay radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from CfgRadio","types":["String"],"since":null,"text":"radioName: String - class name from CfgRadio"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer directSay configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["player directSay configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]},{"text":"An equivalent of a ***directChat*** command:\n\n```sqf\n[player, \"Hello there\", 30] call {\n    params [\"_unit\", \"_text\", \"_distance\"];\n    [_unit, _text] remoteExec [\"globalChat\", call BIS_fnc_listPlayers select { _x distance _unit < _distance }];\n};\n```\n\nA function can be made for localisation purpose:\n\n```sqf\n/* TAG_fnc_globalChat */\nparams [\n    [\"_unit\", objNull, [objNull]],\n    [\"_text\", \"\", [\"\"]]\n];\n\n_unit globalChat (_text call BIS_fnc_localize);\n```\n\n```sqf\n// usage\n[player, \"STR_HelloThere\"] remoteExec [\"TAG_fnc_globalChat\", call BIS_fnc_listPlayers select { _x distance _unit < 30 }];\n```","code":["[player, \"Hello there\", 30] call {\n\tparams [\"_unit\", \"_text\", \"_distance\"];\n\t[_unit, _text] remoteExec [\"globalChat\", call BIS_fnc_listPlayers select { _x distance _unit < _distance }];\n};","/* TAG_fnc_globalChat */\nparams [\n\t[\"_unit\", objNull, [objNull]],\n\t[\"_text\", \"\", [\"\"]]\n];\n\n_unit globalChat (_text call BIS_fnc_localize);","// usage\n[player, \"STR_HelloThere\"] remoteExec [\"TAG_fnc_globalChat\", call BIS_fnc_listPlayers select { _x distance _unit < 30 }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideRadio","groupRadio","customRadio","vehicleRadio","globalRadio","commandRadio"],"notes":[{"user":"Killzone_Kid","date":"2016-12-03T21:32:00Z","text":"To transmit user custom sounds (see Multiplayer_Custom_Sounds_Tutorial), prefix the full filename including file extension with #.\nFor example if there is a custom user sound file called `MySound.ogg`, to play it on the radio use:\n\n```sqf\nplayer directSay \"#MySound.ogg\";\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"disableAI","operator":null,"title":"disableAI","type":"command","url":"https://community.bistudio.com/wiki/disableAI","revid":378871,"updated":"2026-07-31T15:22:58Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Disables parts of the AI behaviour to get a better control over the actions of a unit. If the unit changes locality, this command might need to be executed again at the new locality to maintain effect.\n\n> [!WARNING]\n> This command might cause unexpected behaviour when used on a player-controlled unit.","syntaxes":[{"syntax":"unit disableAI feature","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"AI unit","types":["Object"],"since":null,"text":"unit: Object - AI unit"},{"name":"feature","type":"String","optional":false,"default":null,"description":"possible values are:\n- Arma 3 v1.66  \"ALL\"\n- \"AUTOTARGET\"\n- \"MOVE\"\n- \"TARGET\"\n- \"TEAMSWITCH\"\n- \"WEAPONAIM\"\n- Operation Flashpoint v1.99 \"ANIM\"\n- Arma 2: Operation Arrowhead v1.60 \"FSM\"\n- Arma 3 v1.42  \"AIMINGERROR\"\n- Arma 3 v1.42  \"SUPPRESSION\"\n- Arma 3 v1.54  \"CHECKVISIBLE\"\n- Arma 3 v1.56  \"AUTOCOMBAT\"\n- Arma 3 v1.56  \"COVER\"\n- Arma 3 v1.62  \"PATH\"\n- Arma 3 v1.76  \"MINEDETECTION\"\n- Arma 3 v1.92  \"LIGHTS\"\n- Arma 3 v1.92  \"NVG\"\n- Arma 3 v1.96  \"RADIOPROTOCOL\"\n- Arma 3 v2.18  \"FIREWEAPON\"\n- Arma 3 v2.22  \"COMMAND\"\n- Arma 3 v2.22  \"HEARING\"\n\n| Feature | Description | Since |\n|---|---|---|\n| \"ALL\" | Disables all features. | Arma 3 v1.66 |\n| \"AIMINGERROR\" | Prevents AI's aiming from being distracted by its shooting, moving, turning, reloading, hit, injury, fatigue, suppression or concealed / lost target. | Arma 3 v1.42 |\n| \"ANIM\" | Disables all animations of the unit. Completely freezes the unit, including breathing and blinking. No move command works until the unit is unfrozen. | Operation Flashpoint v1.99 |\n| \"AUTOCOMBAT\" | Disables autonomous switching to \"COMBAT\" AI Behaviour when in danger. | Arma 3 v1.56 |\n| \"AUTOTARGET\" | Essentially makes single units without a group \"deaf\". The unit still goes prone and combat ready if it hears gunfire. It will not turn around when gunfire comes from behind, but if an enemy walks in front of it it will target the enemy and fire as normal. **Does not work for grouped units as the leader will assign targets to the units, effectively reenabling this feature.** | - |\n| \"CHECKVISIBLE\" | Disables visibility raycasts. Useful in PvP missions where these raycasts are not needed. | Arma 3 v1.54 |\n| \"COMMAND\" | AI leaders will no longer issue commands. | Arma 3 v2.22 |\n| \"FSM\" | Disables the attached FSM scripts which are responsible for the AI behaviour. Enemies react slower to enemy fire and the enemy stops using hand signals. Disabling FSM can give the impression of untrained units as they react slower and are more disorganized compared to when FSM is enabled. | Arma 2: Operation Arrowhead v1.60 |\n| \"LIGHTS\" | Stops AI from operating vehicle headlights and collision lights. | Arma 3 v1.92 |\n| \"MINEDETECTION\" | Disable AI's mine detection. | Arma 3 v1.76 |\n| \"MOVE\" | This will stop units from turning and moving, including vehicles. Units will still change stance and fire at the enemy if the enemy happens to walk right in front of the barrel. Units will watch enemies that are in their line of sight, but will not turn their bodies to face the enemy, only their head. Works for grouped units as well. Good for staging units and holding them completely still. Movement can not be controlled via script either, this feature has to be reenabled for that. The unit will still be able to aim within its cone of fire. | - |\n| \"NVG\" | Stops AI from putting on NVGs (but not from taking them off). | Arma 3 v1.92 |\n| \"PATH\" | Stops the AI's movement but not the target alignment. | Arma 3 v1.62 |\n| \"RADIOPROTOCOL\" | Stops AI from talking and texting while still being able to issue orders. | Arma 3 v1.96 |\n| \"SUPPRESSION\" | Prevents AI from being suppressed. See Arma 3: Suppression. | Arma 3 v1.42 |\n| \"TARGET\" | Prevents units from engaging targets. Units still move around for cover, but will not hunt down enemies. Works in groups as well. Excellent for keeping units inside bases or other areas without having them flank or engage anyone. They will still seek good cover if something is close by. | - |\n| \"TEAMSWITCH\" | This will disable AI unit when teamswitching. When used on vehicles they might no longer follow waypoints and appear stuck. | - |\n| \"WEAPONAIM\" | Disables weapon aiming. | - |\n| \"FIREWEAPON\" | Disables weapon firing. | Arma 3 v2.18 |\n| \"HEARING\" | Disables AI's ability to hear. | Arma 3 v2.22 |","types":["String"],"since":null,"text":"feature: String - possible values are:\n- Arma 3 v1.66  \"ALL\"\n- \"AUTOTARGET\"\n- \"MOVE\"\n- \"TARGET\"\n- \"TEAMSWITCH\"\n- \"WEAPONAIM\"\n- Operation Flashpoint v1.99 \"ANIM\"\n- Arma 2: Operation Arrowhead v1.60 \"FSM\"\n- Arma 3 v1.42  \"AIMINGERROR\"\n- Arma 3 v1.42  \"SUPPRESSION\"\n- Arma 3 v1.54  \"CHECKVISIBLE\"\n- Arma 3 v1.56  \"AUTOCOMBAT\"\n- Arma 3 v1.56  \"COVER\"\n- Arma 3 v1.62  \"PATH\"\n- Arma 3 v1.76  \"MINEDETECTION\"\n- Arma 3 v1.92  \"LIGHTS\"\n- Arma 3 v1.92  \"NVG\"\n- Arma 3 v1.96  \"RADIOPROTOCOL\"\n- Arma 3 v2.18  \"FIREWEAPON\"\n- Arma 3 v2.22  \"COMMAND\"\n- Arma 3 v2.22  \"HEARING\"\n\n| Feature | Description | Since |\n|---|---|---|\n| \"ALL\" | Disables all features. | Arma 3 v1.66 |\n| \"AIMINGERROR\" | Prevents AI's aiming from being distracted by its shooting, moving, turning, reloading, hit, injury, fatigue, suppression or concealed / lost target. | Arma 3 v1.42 |\n| \"ANIM\" | Disables all animations of the unit. Completely freezes the unit, including breathing and blinking. No move command works until the unit is unfrozen. | Operation Flashpoint v1.99 |\n| \"AUTOCOMBAT\" | Disables autonomous switching to \"COMBAT\" AI Behaviour when in danger. | Arma 3 v1.56 |\n| \"AUTOTARGET\" | Essentially makes single units without a group \"deaf\". The unit still goes prone and combat ready if it hears gunfire. It will not turn around when gunfire comes from behind, but if an enemy walks in front of it it will target the enemy and fire as normal. **Does not work for grouped units as the leader will assign targets to the units, effectively reenabling this feature.** | - |\n| \"CHECKVISIBLE\" | Disables visibility raycasts. Useful in PvP missions where these raycasts are not needed. | Arma 3 v1.54 |\n| \"COMMAND\" | AI leaders will no longer issue commands. | Arma 3 v2.22 |\n| \"FSM\" | Disables the attached FSM scripts which are responsible for the AI behaviour. Enemies react slower to enemy fire and the enemy stops using hand signals. Disabling FSM can give the impression of untrained units as they react slower and are more disorganized compared to when FSM is enabled. | Arma 2: Operation Arrowhead v1.60 |\n| \"LIGHTS\" | Stops AI from operating vehicle headlights and collision lights. | Arma 3 v1.92 |\n| \"MINEDETECTION\" | Disable AI's mine detection. | Arma 3 v1.76 |\n| \"MOVE\" | This will stop units from turning and moving, including vehicles. Units will still change stance and fire at the enemy if the enemy happens to walk right in front of the barrel. Units will watch enemies that are in their line of sight, but will not turn their bodies to face the enemy, only their head. Works for grouped units as well. Good for staging units and holding them completely still. Movement can not be controlled via script either, this feature has to be reenabled for that. The unit will still be able to aim within its cone of fire. | - |\n| \"NVG\" | Stops AI from putting on NVGs (but not from taking them off). | Arma 3 v1.92 |\n| \"PATH\" | Stops the AI's movement but not the target alignment. | Arma 3 v1.62 |\n| \"RADIOPROTOCOL\" | Stops AI from talking and texting while still being able to issue orders. | Arma 3 v1.96 |\n| \"SUPPRESSION\" | Prevents AI from being suppressed. See Arma 3: Suppression. | Arma 3 v1.42 |\n| \"TARGET\" | Prevents units from engaging targets. Units still move around for cover, but will not hunt down enemies. Works in groups as well. Excellent for keeping units inside bases or other areas without having them flank or engage anyone. They will still seek good cover if something is close by. | - |\n| \"TEAMSWITCH\" | This will disable AI unit when teamswitching. When used on vehicles they might no longer follow waypoints and appear stuck. | - |\n| \"WEAPONAIM\" | Disables weapon aiming. | - |\n| \"FIREWEAPON\" | Disables weapon firing. | Arma 3 v2.18 |\n| \"HEARING\" | Disables AI's ability to hear. | Arma 3 v2.22 |"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"feature","types":["String"]}}],"examples":[{"text":"```sqf\nMyUnit disableAI \"AUTOTARGET\";\n```","code":["MyUnit disableAI \"AUTOTARGET\";"]}],"multiplayer":"> [!IMPORTANT]\n> The locality of this command is peculiar: the disabling will be stored *locally* and will apply **if** the AI is local or becomes local (e.g taking the lead, driving, etc).\n> If the AI changes locality again, that machine's AI setup will prevail.","problems":null,"aliases":[],"see_also":["enableAI","checkAIFeature","enableAIFeature","getUnitState","disableRemoteSensors","vehicleMoveInfo"],"notes":[{"user":"Hardrock","date":"2006-08-03T14:31:00Z","text":"*Notes from before the conversion:*\n\nThe \"TARGET\" section of the AI is likely different than what you would think. Normally, when an AI group is standing still and sees an enemy, the group will break formation and start moving towards the enemy. If you disable the \"TARGET\" AI, then the AI units will stay where they are at. Even if you disable the \"MOVE\" AI, the units will still move out to attack the enemy, unless you disable the \"TARGET\" AI. Disabling both these AI sections is useful when placing units in defensive positions. This way, you can have them stay behind their cover, and not run out into the open.\n\nThis command has also a bug: after mission save or load the effect will be no longer active and you must set it again. It's also good way to detect number of saves and loads (loads can be recognized using time command)."},{"user":"GeneralCarver","date":"2009-02-07T14:31:00Z","text":"*Multiplayer Use as of ArmA v1.14:*\nContrary to the post above, using this command WILL disable A.I. movement ability if used with the \"MOVE\" parameter. Works even when the A.I. is grouped with other units. I use this command to set up stationary targets at objectives all the time. Works on a dedicated server."},{"user":"Kenoxite","date":"2015-09-19T09:00:00Z","text":"Beware that disabling \"TARGET\" AI to units in the player's group will disable the ability to execute engage orders issued by the player."},{"user":"James","date":"2016-09-26T19:34:00Z","text":"Command is buggy in version 1.64.138497 as it disables the ability to drive vehicles for players. Tested with `player disableAI \"move\"`. Entering a vehicle is possible, but not starting the engine. `player enableAI \"move\"` enables the player to drive again.\nFeedback Tracker ticket: https://feedback.bistudio.com/T120346"},{"user":"zwobot","date":"2018-06-05T19:29:00Z","text":"In **Operation Flashpoint/Cold War Assault**, the disabled units are reset after a saveGame is executed or the user manually saves the mission, i. e. the units will behave as if the disableAI command was never applied to them. Also in Operation Flashpoint there is no way to undo this command."},{"user":"Sa-Matra","date":"2023-04-30T10:12:56Z","text":"Disabled or enabled AI features have no synchronization over the network what so ever, you have to do everything yourself on each client, including JIP. This also applies to setAutonomous which is pretty much multi-call disableAI command for specific set of features."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"disableBrakes","operator":null,"title":"disableBrakes","type":"command","url":"https://community.bistudio.com/wiki/disableBrakes","revid":373894,"updated":"2025-06-26T11:02:28Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Disables autobrake, which is engaged when vehicle is stationary and stops wheels from rotating freely when vehicle is pushed.","syntaxes":[{"syntax":"transport disableBrakes disable","since":null,"effect":null,"exec":null,"params":[{"name":"transport","type":"Object","optional":false,"default":null,"description":"PhysX car or tank","types":["Object"],"since":null,"text":"transport: Object - PhysX car or tank"},{"name":"disable","type":"Boolean","optional":false,"default":null,"description":"true to disable autobrake. The autobrake is re-enabled if the driver uses brakes","types":["Boolean"],"since":null,"text":"disable: Boolean - true to disable autobrake. The autobrake is re-enabled if the driver uses brakes"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"transport","types":["Object"]},"right":{"text":"disable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyCar disableBrakes true;\n```","code":["myCar disableBrakes true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["brakesDisabled","awake","isAwake","addTorque","addForce","vectorModelToWorld","vectorModelToWorldVisual","selectionPosition","setVelocityTransformation","setVelocityModelSpace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"disableCollisionWith","operator":null,"title":"disableCollisionWith","type":"command","url":"https://community.bistudio.com/wiki/disableCollisionWith","revid":370442,"updated":"2024-12-09T20:57:09Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Disable collision between provided objects. The collision is always disabled for both objects in the arguments.\n\n> [!IMPORTANT]\n> - this command does not disable collision between PhysX objects\n> - this command has to be executed where objects are local, and as long as they do not change locality, the effect of this command will be global:\n>   - if the two objects are not local to the same computer, then it has to be executed on both computers to achieve the desired effect\n>   - if one or both objects change locality, the command needs to be executed again on the new owner's machine(s) to maintain the effect\n> - the feature works by having an object registering a reference to the other object; this command stores such reference on both objects - see #Example 3","syntaxes":[{"syntax":"vehicle1 disableCollisionWith vehicle2","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle1","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle1: Object"},{"name":"vehicle2","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle2: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle1","types":["Object"]},"right":{"text":"vehicle2","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer disableCollisionWith myWall;\n```","code":["player disableCollisionWith myWall;"]},{"text":"```sqf\n[_veh1, _veh2] remoteExecCall [\"disableCollisionWith\", 0, _veh1];\n```","code":["[_veh1, _veh2] remoteExecCall [\"disableCollisionWith\", 0, _veh1];"]},{"text":"```sqf\n// this command stores a reference to the other object on both arguments:\n_obj1 disableCollisionWith _obj2;    // _obj1 has a reference to _obj2, disabling collision with it\n                                    // _obj2 has a reference to _obj1, disabling collision with it\n\n// only one reference is required to disable collision, allowing more than one disabled collision\n_obj1 disableCollisionWith _obj3;    // _obj1 has a reference to _obj3, disabling collision with it\n                                    // _obj2 has a reference to _obj1, disabling collision with it\n                                    // _obj3 has a reference to _obj1, disabling collision with it\n                                    // factually, _obj1 has collisions disabled with _obj2 and _obj3\n\n// note that _obj1 collision can be changed without using the command on it directly\n_obj2 disableCollisionWith _obj3;    // _obj1 has no more reference to _obj3 and can collide with it\n                                    // _obj2 has a reference to _obj3, disabling collision with it\n                                    // _obj3 has a reference to _obj2, disabling collision with it\n```","code":["// this command stores a reference to the other object on both arguments:\n_obj1 disableCollisionWith _obj2;\t// _obj1 has a reference to _obj2, disabling collision with it\n\t\t\t\t\t\t\t\t\t// _obj2 has a reference to _obj1, disabling collision with it\n\n// only one reference is required to disable collision, allowing more than one disabled collision\n_obj1 disableCollisionWith _obj3;\t// _obj1 has a reference to _obj3, disabling collision with it\n\t\t\t\t\t\t\t\t\t// _obj2 has a reference to _obj1, disabling collision with it\n\t\t\t\t\t\t\t\t\t// _obj3 has a reference to _obj1, disabling collision with it\n\t\t\t\t\t\t\t\t\t// factually, _obj1 has collisions disabled with _obj2 and _obj3\n\n// note that _obj1 collision can be changed without using the command on it directly\n_obj2 disableCollisionWith _obj3;\t// _obj1 has no more reference to _obj3 and can collide with it\n\t\t\t\t\t\t\t\t\t// _obj2 has a reference to _obj3, disabling collision with it\n\t\t\t\t\t\t\t\t\t// _obj3 has a reference to _obj2, disabling collision with it"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["collisionDisabledWith","enableCollisionWith","setPhysicsCollisionFlag"],"notes":[{"user":"Ranwer","date":"2015-04-04T12:03:00Z","text":"disableCollisionWith is basically a script that when you apply it to an object, and your unit can go through it like a ghost. However, if you wish the object to be solid again, you may wish to use enableCollisionWith.\n\nAn example for this is:\n\n```sqf\n// name of unit in editor such as player1\n// name of object in editor such as barrel1\nbarrel1 disableCollisionWith player1;\n\n// to make the barrel solid again, do this as vice versa if you know what you are doing!\nbarrel1 enableCollisionWith player1;\n```\n\nOn a side note: this can come in handy a lot if you want a unit to sit on the back of a car or on top of a container"},{"user":"bloodwyn1756","date":"2018-05-29T06:58:00Z","text":"This command does not disable the roadway LOD."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"disableConversation","operator":null,"title":"disableConversation","type":"command","url":"https://community.bistudio.com/wiki/disableConversation","revid":351998,"updated":"2024-02-01T23:23:59Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"In theory disables the ability to talk to other people. In actuality, if true is given, the command increases unit's kbTell *IsSpeaking* status by 1, thus stopping unit from having a conversation. If false is given, the command decreases unit's kbTell *IsSpeaking* status by 1. The unit \"is speaking\" if *IsSpeaking > 0*.\n\n> [!IMPORTANT]\n> kbTell *IsSpeaking* is a number that is increased or decreased by 1 internally. Default is 0, but it can be any positive or negative value. disableConversation allows to increase or decrease this number. When executed multiple times this can present an unexpected problem. Use conversationDisabled which returns true if this number > 0, to reset this number to 0 if necessary:\n>\n> ```sqf\n> while {!conversationDisabled _unit} do {_unit disableConversation true}; while {conversationDisabled _unit} do {_unit disableConversation false};\n> ```","syntaxes":[{"syntax":"unitName disableConversation disable","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"disable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"disable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"disable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer disableConversation true;\n```","code":["player disableConversation true;"]},{"text":"```sqf\nsoldier1 disableConversation false;\n```","code":["soldier1 disableConversation false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["conversationDisabled","setSpeaker","enableRadio","enableSentences","showSubtitles"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"disableDebriefingStats","operator":null,"title":"disableDebriefingStats","type":"command","url":"https://community.bistudio.com/wiki/disableDebriefingStats","revid":364532,"updated":"2024-05-16T20:46:25Z","groups":["Broken Commands","Briefing"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Disable debriefing score table.\n\n> [!WARNING]\n> This command is broken.","syntaxes":[{"syntax":"disableDebriefingStats","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndisableDebriefingStats;\n```","code":["disableDebriefingStats;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDebriefingStats"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Broken Commands","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"disableMapIndicators","operator":null,"title":"disableMapIndicators","type":"command","url":"https://community.bistudio.com/wiki/disableMapIndicators","revid":364167,"updated":"2024-05-05T10:46:43Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Command allows suppressing visualization of FRIENDLY, ENEMY, MINES and/or PING map indicators from difficulty setting EXTENDED MAP CONTENT.","syntaxes":[{"syntax":"disableMapIndicators [disableFriendly, disableEnemy, disableMines, disablePing]","since":null,"effect":null,"exec":null,"params":[{"name":"disableFriendly","type":"Boolean","optional":false,"default":null,"description":"true to disable visualization of friendly units","types":["Boolean"],"since":null,"text":"disableFriendly: Boolean - true to disable visualization of friendly units"},{"name":"disableEnemy","type":"Boolean","optional":false,"default":null,"description":"true to disable visualization of enemy units","types":["Boolean"],"since":null,"text":"disableEnemy: Boolean - true to disable visualization of enemy units"},{"name":"disableMines","type":"Boolean","optional":false,"default":null,"description":"true to disable visualization of mines","types":["Boolean"],"since":null,"text":"disableMines: Boolean - true to disable visualization of mines"},{"name":"disablePing","type":"Boolean","optional":false,"default":null,"description":"true to disable visualization of all tactical pings","types":["Boolean"],"since":null,"text":"disablePing: Boolean - true to disable visualization of all tactical pings"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[disableFriendly, disableEnemy, disableMines, disablePing]","types":["Array"]}}],"examples":[{"text":"Disable visualization of friendly and enemy units:\n\n```sqf\ndisableMapIndicators [true, true, false, false];\n```","code":["disableMapIndicators [true, true, false, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficultyOption"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 1.82","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"disableNVGEquipment","operator":null,"title":"disableNVGEquipment","type":"command","url":"https://community.bistudio.com/wiki/disableNVGEquipment","revid":336380,"updated":"2022-12-31T19:13:15Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Enables or disables transport NV (Night Vision). To disable TI (Thermal Imaging) use disableTIEquipment.","syntaxes":[{"syntax":"vehicle disableNVGEquipment state","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"state: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyTank disableNVGEquipment true;\n```","code":["myTank disableNVGEquipment true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["equipmentDisabled","disableTIEquipment"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.52","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"disableRemoteSensors","operator":null,"title":"disableRemoteSensors","type":"command","url":"https://community.bistudio.com/wiki/disableRemoteSensors","revid":321256,"updated":"2022-05-13T19:00:39Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"This command will halt raycasting calculations (on the local machine only) for all groups which don't contain *any* local entities. Units, that are not in a group with at least one local member, will not check visibility of other units. This will cause, that remote units will not have updated knowsAbout and it will save some CPU time. If a group contains a single local entity then calculations will still be performed for the entire group.\n\nThese raycasts are used to determine what other entities an entity can see, and they take a lot of CPU time. This is of course a bit of a trick, because rather than a true optimization, it disables part of the simulation. However, there are certainly types of scenarios where these raycasts are not needed. An example is a fully Player-versus-Player scenario, where the visibility between every combination of player entity is not needed. So why not disable this by default? There are cases where you do require these raycasts, for example in stealth scenarios. Without them, commands like knowsAbout, nearTargets and targetKnowledge will only function for local units! The commands themselves are local, can be used on servers and clients, and the state is reset when the scenario ends. So, carefully consider whether your scenario can benefit from this method.","syntaxes":[{"syntax":"disableRemoteSensors state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to disable","types":["Boolean"],"since":null,"text":"state: Boolean - true to disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\ndisableRemoteSensors true;\n```","code":["disableRemoteSensors true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getRemoteSensorsDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.52","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"disableSerialization","operator":null,"title":"disableSerialization","type":"command","url":"https://community.bistudio.com/wiki/disableSerialization","revid":369064,"updated":"2024-09-02T20:24:56Z","groups":["Namespaces","GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Disable saving of script containing this command. After this, the script can work with data types which do not support serialization (UI types).\n\n> [!NOTE]\n> See Namespace serialization for more information.\n\n> [!IMPORTANT]\n> **In Arma 2** and up to a certain version of Arma 3, giving a Display or Control to spawned code would raise an error due to the usage of the then non-serializable `_this` variable. Using disableSerialization or uiNamespace wouldn't help; the trick here is to pass the argument inside an array:\n>\n> ```sqf\n> _display = findDisplay 46;\n>  _display  spawn { hint str _this; };                // would raise a serialization error\n> [_display] spawn { hint str (_this select 0); };    // OK\n> ```","syntaxes":[{"syntax":"disableSerialization","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndisableSerialization;\nprivate _display = findDisplay 46;\n```","code":["disableSerialization;\nprivate _display = findDisplay 46;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Display","displayAddEventHandler","displayRemoveAllEventHandlers","displayRemoveEventHandler","uiSleep"],"notes":[{"user":"Str","date":"2010-06-19T10:26:00Z","text":"Can be used to detecting load. Scope with disabled serialization is discontinued after load, even if there's endless loop inside.\n\n```sqf\n0 spawn { disableSerialization; waitUntil { false }; hint \"Game was loaded!\";};\n```\n\nWorks for all possible load types - loading user save, loading autosave and resuming mission from main menu.\n\nUse with caution, as it creates an infinite loop, having impact at overall scripting time."},{"user":"Killzone_Kid","date":"2013-10-23T02:57:00Z","text":"If you do not store UI elements (Display, Control) in variables, you do not need disableSerialization; UI elements are usually returned by scripting commands such as findDisplay or passed as params in UI event handler scripts (displayAddEventHandler, ctrlAddEventHandler).\n\nThis code will require disableSerialization:\n\n```sqf\ndisableSerialization;\n_display = findDisplay 123;\n_ctrl = _display displayCtrl -1;\n_ctrl ctrlSetText \"LOL\";\n```\n\nThis code will not:\n\n```sqf\nfindDisplay 123 displayCtrl -1 ctrlSetText \"LOL\";\n```"},{"user":"Nelis75733126","date":"2017-06-25T18:15:00Z","text":"In Arma 3 1.74, a scripted FSM is somehow incompatible with `disableSerialization`.\n\nAs a workaround, store a display inside an array. Example:\n\n```sqf\n_display = [findDisplay idd];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Namespaces","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"disableTIEquipment","operator":null,"title":"disableTIEquipment","type":"command","url":"https://community.bistudio.com/wiki/disableTIEquipment","revid":353363,"updated":"2024-03-15T17:11:56Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Disables TI (Thermal Imaging) equipment for given vehicle.\n\n> [!NOTE]\n> In older versions of Arma this command would also disable NV (Night Vision), but since Arma 3 v1.54 this command disables only TI. Use disableNVGEquipment to disable NV.","syntaxes":[{"syntax":"vehicle disableTIEquipment state","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to turn TI off, false to turn TI on","types":["Boolean"],"since":null,"text":"state: Boolean - true to turn TI off, false to turn TI on"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player disableTIEquipment true;\n```","code":["vehicle player disableTIEquipment true;"]},{"text":"```sqf\n_tank disableTIEquipment true;\n```","code":["_tank disableTIEquipment true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["equipmentDisabled","disableNVGEquipment","currentVisionMode","setCamUseTI","camUseNVG"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.54","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"disableUAVConnectability","operator":null,"title":"disableUAVConnectability","type":"command","url":"https://community.bistudio.com/wiki/disableUAVConnectability","revid":349592,"updated":"2023-11-11T23:18:11Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Disables unit's AV terminal(s) connecting to UAV.","syntaxes":[{"syntax":"object disableUAVConnectability [uav, checkAllItems]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"},{"name":"checkAllItems","type":"Boolean","optional":false,"default":null,"description":"true to disable all terminals in unit's inventory, false to only disable the currently assigned terminal.","types":["Boolean"],"since":null,"text":"checkAllItems: Boolean - true to disable all terminals in unit's inventory, false to only disable the currently assigned terminal."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[uav, checkAllItems]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyUnit disableUAVConnectability [myUav, true];\n```","code":["myUnit disableUAVConnectability [myUav, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isUAVConnectable","enableUAVConnectability"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.24","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"disableUserInput","operator":null,"title":"disableUserInput","type":"command","url":"https://community.bistudio.com/wiki/disableUserInput","revid":373274,"updated":"2025-04-13T14:35:36Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Disables or enables the keyboard and mouse input. Usually used during cutscenes.\n\n> [!WARNING]\n> Be careful and responsible with the usage of this command. Once the user input is disabled, the only option left is to restart the game. Make sure you provide scripted mechanics to resolve this, should you need to disable user input for any reason.","syntaxes":[{"syntax":"disableUserInput state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to disable, false to enable","types":["Boolean"],"since":null,"text":"state: Boolean - true to disable, false to enable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\ndisableUserInput true;\n// cutscene\ndisableUserInput false;\n```","code":["disableUserInput true;\n// cutscene\ndisableUserInput false;"]},{"text":"Reset user input if a key was pressed:\n\n```sqf\ndisableUserInput true;    // here e.g W was pressed\nsleep 2;                // the user releases keys\ndisableUserInput false;    // the game considers W is still pressed as it did not listen to a \"KeyUp\" event\n\ndisableUserInput true;\ndisableUserInput false;    // this resets released keys making the issue invisible\n\n// this workaround does not fix the mouse input that may get stuck on [[disableUserInput]] call\n```","code":["disableUserInput true;\t// here e.g W was pressed\nsleep 2;\t\t\t\t// the user releases keys\ndisableUserInput false;\t// the game considers W is still pressed as it did not listen to a \"KeyUp\" event\n\ndisableUserInput true;\ndisableUserInput false;\t// this resets released keys making the issue invisible\n\n// this workaround does not fix the mouse input that may get stuck on [[disableUserInput]] call"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["userInputDisabled","enableSimulation","enableSimulationGlobal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"displayAddEventHandler","operator":null,"title":"displayAddEventHandler","type":"command","url":"https://community.bistudio.com/wiki/displayAddEventHandler","revid":369069,"updated":"2024-09-02T20:24:59Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds an event handler to the given display. See User Interface Event Handlers for the full list of event names.\nIf applicable, see DIK_KeyCodes for a list of key code constants, which are relevant to key related user interface events like: KeyDown & KeyUp.\n\n> [!IMPORTANT]\n> Display EHs are processed from last to first added; an input override should be set up in the first added EH.\n\n> [!NOTE]\n> The event handler ID can be accessed inside the event handler code using the `_thisEventHandler` magic variable.","syntaxes":[{"syntax":"display displayAddEventHandler [eventName, code]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"eventName","type":"String","optional":false,"default":null,"description":"event name\n\n> [!IMPORTANT]\n> When using the event names listed here with the ctrlAddEventHandler, ctrlSetEventHandler, displayAddEventHandler or displaySetEventHandler commands, the prefix \"on\" in the event name must be removed (e.g. **'ButtonDown**' instead of **'onButtonDown**').","types":["String"],"since":null,"text":"eventName: String - event name\n\n> [!IMPORTANT]\n> When using the event names listed here with the ctrlAddEventHandler, ctrlSetEventHandler, displayAddEventHandler or displaySetEventHandler commands, the prefix \"on\" in the event name must be removed (e.g. **'ButtonDown**' instead of **'onButtonDown**')."},{"name":"code","type":"String or Arma 3 v1.06 Code","optional":false,"default":null,"description":"the code which gets executed when event is triggered. Returning true in event handler code will override default engine handling for keyboard events.\nSeveral Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`","types":["String","Code"],"since":null,"text":"code: String or Arma 3 v1.06 Code - the code which gets executed when event is triggered. Returning true in event handler code will override default engine handling for keyboard events.\nSeveral Magic Variables are available:\n- Event Handler parameters are accessible via `_this`\n- The Event Handler type is available as `_thisEvent`\n- The Event Handler index is available as `_thisEventHandler`"}],"returns":{"type":"Number","types":["Number"],"description":"index of the newly added event handler or `-1` if creation failed","text":"Number - index of the newly added event handler or `-1` if creation failed"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[eventName, code]","types":["Array"]}}],"examples":[{"text":"```sqf\nmoduleName_keyDownEHId = findDisplay 46 displayAddEventHandler [\"KeyDown\", \"hint str _this;\"];\n```","code":["moduleName_keyDownEHId = findDisplay 46 displayAddEventHandler [\"KeyDown\", \"hint str _this;\"];"]},{"text":"```sqf\nmoduleName_keyDownEHId = findDisplay 46 displayAddEventHandler [\"KeyDown\", { hint str _this }];\n```","code":["moduleName_keyDownEHId = findDisplay 46 displayAddEventHandler [\"KeyDown\", { hint str _this }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableSerialization","displayRemoveAllEventHandlers","displayRemoveEventHandler","displaySetEventHandler","ctrlAddEventHandler","User Interface Event Handlers","findDisplay","DIK KeyCodes","keyName"],"notes":[{"user":"Axyl","date":"2014-03-10T14:52:00Z","text":"From within an Addon, you must assign the events from a spawned script.  e.g. \n\n```sqf\n0 spawn { findDisplay 46 displayAddEventHandler [\"KeyDown\", \"_this call my_KeyDownFunctionhandler\"]; };\n```"},{"user":"Pigneedle","date":"2016-01-22T08:15:00Z","text":"Be sure to wait until the main display is initialized before using this command by using:\n\n```sqf\nwaitUntil { !isNull (findDisplay 46) };\n```"},{"user":"Nelis75733126","date":"2017-05-28T11:32:00Z","text":"use (#define) if you want `displayAddEventHandler` to use data defined in the same script. You can then integrate that data either directly, or by applying format to the second parameter."},{"user":"DrSova","date":"2017-08-07T15:08:00Z","text":"Using **KeyUp** you can't override default engine action by returning **true**"},{"user":"R3vo","date":"2021-06-26T16:17:00Z","text":"To prevent a display from getting closed by pressing ESC, add the following event handler.\n\n```sqf\n#include \"\\a3\\ui_f\\hpp\\definedikcodes.inc\"\n_display displayAddEventHandler [\"KeyDown\",\n{\n    params [\"\", \"_key\"];\n    _key == DIK_ESC; // ESC pressed while dialog is open, overwrite default behaviour\n}];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displayChild","operator":null,"title":"displayChild","type":"command","url":"https://community.bistudio.com/wiki/displayChild","revid":310334,"updated":"2022-05-05T16:57:20Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns child display of the given display.","syntaxes":[{"syntax":"displayChild display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\n_display = displayChild findDisplay 313; // display #46\n```","code":["_display = displayChild findDisplay 313; // display #46"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayParent","findDisplay","displayCtrl","createDisplay","createDialog","dialog","displayNull","ctrlCreate","controlNull","ctrlParent","ctrlParentControlsGroup","focusedCtrl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"displayCtrl","operator":null,"title":"displayCtrl","type":"command","url":"https://community.bistudio.com/wiki/displayCtrl","revid":340953,"updated":"2023-05-13T22:01:05Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return child control with specified idc.","syntaxes":[{"syntax":"display displayCtrl idc","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"idc","types":["Number"]}},{"syntax":"displayCtrl idc","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Control","types":["Control"],"description":null,"text":"Control"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}}],"examples":[{"text":"```sqf\n_displayControl = _ParentDisplay displayCtrl 101;\n```","code":["_displayControl = _ParentDisplay displayCtrl 101;"]},{"text":"```sqf\n_dialogControl = displayCtrl 101;\n```","code":["_dialogControl = displayCtrl 101;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findDisplay","ctrlCreate","ctrlDelete","ctrlModel","ctrlSetModel","ctrlPosition","ctrlSetPosition","ctrlClassName","ctrlModelScale","ctrlSetModelScale","ctrlModelDirAndUp","ctrlSetModelDirAndUp","displayParent"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displayNull","operator":null,"title":"displayNull","type":"command","url":"https://community.bistudio.com/wiki/displayNull","revid":321054,"updated":"2022-05-13T12:16:25Z","groups":["GUI Control","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Display. To compare non-existent displays use isNull or isEqualTo:\n\n```sqf\ndisplayNull == displayNull;        // false\nisNull displayNull;                    // true\ndisplayNull isEqualTo displayNull;    // true\n```","syntaxes":[{"syntax":"displayNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n!isNull displayNull; // false\n```","code":["!isNull displayNull; // false"]},{"text":"```sqf\nstr displayNull; // No display\n```","code":["str displayNull; // No display"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","grpNull","locationNull","objNull","taskNull","teamMemberNull","scriptNull","configNull","typeName","isNull","displayParent"],"notes":[{"user":"7erra","date":"2022-02-05T16:02:02Z","text":"When used in the debug console or as output in the chat or rpt it is displayed as \"No display\"."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Variables","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displayParent","operator":null,"title":"displayParent","type":"command","url":"https://community.bistudio.com/wiki/displayParent","revid":318897,"updated":"2022-05-13T09:22:00Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns parent display of the given display.","syntaxes":[{"syntax":"displayParent display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\n_display = displayParent findDisplay 49; // Display #46\n```","code":["_display = displayParent findDisplay 49; // Display #46"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayChild","findDisplay","displayCtrl","createDisplay","createDialog","dialog","displayNull","ctrlCreate","controlNull","ctrlParent","ctrlParentControlsGroup","focusedCtrl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"displayRemoveAllEventHandlers","operator":null,"title":"displayRemoveAllEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/displayRemoveAllEventHandlers","revid":319041,"updated":"2022-05-13T09:22:14Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove all event handlers from the given display.","syntaxes":[{"syntax":"display displayRemoveAllEventHandlers eventName","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"eventName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"eventName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"eventName","types":["String"]}}],"examples":[{"text":"```sqf\nfindDisplay 46 displayRemoveAllEventHandlers \"KeyDown\";\n```","code":["findDisplay 46 displayRemoveAllEventHandlers \"KeyDown\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayAddEventHandler","displayRemoveEventHandler"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displayRemoveEventHandler","operator":null,"title":"displayRemoveEventHandler","type":"command","url":"https://community.bistudio.com/wiki/displayRemoveEventHandler","revid":364901,"updated":"2024-06-29T14:38:36Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove a given event handler from the given display.","syntaxes":[{"syntax":"display displayRemoveEventHandler [handlerType, id]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"handlerType","type":"String","optional":false,"default":null,"description":"type of the event handler","types":["String"],"since":null,"text":"handlerType: String - type of the event handler"},{"name":"id","type":"Number","optional":false,"default":null,"description":"index of the event handler","types":["Number"],"since":null,"text":"id: Number - index of the event handler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[handlerType, id]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 46 displayRemoveEventHandler [\"keyDown\",5];\n```","code":["findDisplay 46 displayRemoveEventHandler [\"keyDown\",5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableSerialization","Display","displayAddEventHandler","displayRemoveAllEventHandlers"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displaySetEventHandler","operator":null,"title":"displaySetEventHandler","type":"command","url":"https://community.bistudio.com/wiki/displaySetEventHandler","revid":369398,"updated":"2024-09-03T18:43:19Z","groups":["GUI Control - Event Handlers","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets given event handler of given display.\nThe return code of the provided function should indicate whether this event was handled correctly. This implies telling the engine whether it is default code should be executed.\nSee User Interface Event Handlers for the full list of handler names.\n\nIf applicable, see DIK KeyCodes for a list of key code constants, which are relevant to key related user interface events like onKeyDown and onKeyUp.\n\n> [!IMPORTANT]\n> When using the event names listed here with the ctrlAddEventHandler, ctrlSetEventHandler, displayAddEventHandler or displaySetEventHandler commands, the prefix \"on\" in the event name must be removed (e.g. **'ButtonDown**' instead of **'onButtonDown**').","syntaxes":[{"syntax":"display displaySetEventHandler [handlerName, function]","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"},{"name":"handlerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"handlerName: String"},{"name":"function","type":"String","optional":false,"default":null,"description":"code","types":["String"],"since":null,"text":"function: String - code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"display","types":["Display"]},"right":{"text":"[handlerName, function]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control displaySetEventHandler [\"KeyDown\", \"\"];\n```","code":["_control displaySetEventHandler [\"KeyDown\", \"\"];"]},{"text":"`init.sqf`:\n\n```sqf\nKeysPressed = compile preprocessFile \"keysPressed.sqf\";\nprivate _display = findDisplay 46;\n_display displaySetEventHandler [\"KeyDown\", \"_this call KeysPressed\"];\n```\n\n`keysPressed.sqf`:\n\n```sqf\nprivate _handled = false;\nswitch (_this select 1) do {\n    // F key\n    case 33: {\n        // code here\n        _handled = true;\n    };\n};\n_handled;\n```","code":["KeysPressed = compile preprocessFile \"keysPressed.sqf\";\nprivate _display = findDisplay 46;\n_display displaySetEventHandler [\"KeyDown\", \"_this call KeysPressed\"];","private _handled = false;\nswitch (_this select 1) do {\n\t// F key\n\tcase 33: {\n\t\t// code here\n\t\t_handled = true;\n\t};\n};\n_handled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ListOfKeyCodes","displayAddEventHandler","displayRemoveEventHandler","displayRemoveAllEventHandlers","ctrlSetEventHandler","User Interface Event Handlers","DIK KeyCodes","keyName"],"notes":[{"user":"WGL.Q","date":"2009-11-25T18:02:00Z","text":"Always use displayAddEventHandler instead, as displaySetEventHandler **overwrites** other (peoples') DEH."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"displayUniqueName","operator":null,"title":"displayUniqueName","type":"command","url":"https://community.bistudio.com/wiki/displayUniqueName","revid":338365,"updated":"2023-03-01T10:17:02Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the provided display's UI On Texture unique name.\n\n> [!NOTE]\n> See findDisplay to get a Display by its unique name.","syntaxes":[{"syntax":"displayUniqueName display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"String","types":["String"],"description":"the unique display identifier","text":"String - the unique display identifier"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\nprivate _displayName = displayUniqueName _myDisplay;\n```","code":["private _displayName = displayUniqueName _myDisplay;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findDisplay","displayUpdate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"displayUpdate","operator":null,"title":"displayUpdate","type":"command","url":"https://community.bistudio.com/wiki/displayUpdate","revid":338339,"updated":"2023-02-28T14:38:10Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the provided display to update its UI On Texture render.","syntaxes":[{"syntax":"displayUpdate display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":"the display to update","types":["Display"],"since":null,"text":"display: Display - the display to update"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\ndisplayUpdate _myDisplay;\n```","code":["displayUpdate _myDisplay;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["displayUniqueName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"dissolveTeam","operator":null,"title":"dissolveTeam","type":"command","url":"https://community.bistudio.com/wiki/dissolveTeam","revid":322979,"updated":"2022-06-28T21:42:55Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Dissolves the given team. All members become members of the main team.","syntaxes":[{"syntax":"dissolveTeam teamColor","since":null,"effect":null,"exec":null,"params":[{"name":"teamColor","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"RED\"\n- \"GREEN\"\n- \"BLUE\"\n- \"YELLOW\"","types":["String"],"since":null,"text":"teamColor: String - can be one of:\n- \"RED\"\n- \"GREEN\"\n- \"BLUE\"\n- \"YELLOW\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"teamColor","types":["String"]}}],"examples":[{"text":"```sqf\ndissolveTeam \"RED\";\n```","code":["dissolveTeam \"RED\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignTeam","unassignTeam"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"distance","operator":null,"title":"distance","type":"command","url":"https://community.bistudio.com/wiki/distance","revid":377523,"updated":"2026-01-02T06:52:13Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a distance in meters between Objects, Positions or Locations.\n\n> [!IMPORTANT]\n> If positions are supplied as arguments, the coordinates are treated as PositionAGL. If Position2D is supplied, z is assumed 0. If you need distance between two Position3D coordinates, use vectorDistance.","syntaxes":[{"syntax":"param1 distance param2","since":null,"effect":null,"exec":null,"params":[{"name":"param1","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"param1: Object or PositionAGL or Position2D"},{"name":"param2","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"param2: Object or PositionAGL or Position2D"}],"returns":{"type":"Number","types":["Number"],"description":"distance in meters or 1e10 if distance cannot be calculated","text":"Number - distance in meters or 1e10 if distance cannot be calculated"},"form":"binary","operator":null,"left":{"text":"param1","types":["Object","PositionAGL","Position2D"]},"right":{"text":"param2","types":["Object","PositionAGL","Position2D"]}},{"syntax":"location1 distance location2","since":null,"effect":null,"exec":null,"params":[{"name":"location1","type":"Location or Position or Position2D","optional":false,"default":null,"description":null,"types":["Location","Position","Position2D"],"since":null,"text":"location1: Location or Position or Position2D"},{"name":"location2","type":"Location or Position or Position2D","optional":false,"default":null,"description":null,"types":["Location","Position","Position2D"],"since":null,"text":"location2: Location or Position or Position2D"}],"returns":{"type":"Number","types":["Number"],"description":"distance in meters or 1e10 if distance cannot be calculated","text":"Number - distance in meters or 1e10 if distance cannot be calculated"},"form":"binary","operator":null,"left":{"text":"location1","types":["Location","Position","Position2D"]},"right":{"text":"location2","types":["Location","Position","Position2D"]}},{"syntax":"a distance b","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":"distance c calculated as c = sqrt(a * a + b * b);","text":"Number - distance c calculated as c = sqrt(a * a + b * b);"},"form":"binary","operator":null,"left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n_meters = player distance _object;\n```","code":["_meters = player distance _object;"]},{"text":"```sqf\n_meters = player distance [1,2,3];\n```","code":["_meters = player distance [1,2,3];"]},{"text":"```sqf\n_meters = [1,2,3] distance [4,5,6];\n```","code":["_meters = [1,2,3] distance [4,5,6];"]},{"text":"```sqf\n_meters = position player distance nearestLocation [position player, \"hill\"];\n```","code":["_meters = position player distance nearestLocation [position player, \"hill\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["distanceSqr","vectorDistance","distance2D"],"notes":[{"user":"Sudden Death","date":"2007-02-14T16:47:00Z","text":"Distance to position3D (array) does not work with Operation Flashpoint, only objects\n\nArmed Assault:\nposition3D (array) and object works"},{"user":"Rommel","date":"2010-03-10T07:54:00Z","text":"This returns the map distance, not the vector distance, [0,0,0] distance [0,0,1] can be >1 or <1, not exactly 1; unlike the vector math."},{"user":"Igneous01","date":"2012-08-03T10:15:00Z","text":"If a position in format [x, y, z] is provided for both arguments, distance also checks the z dimension as well. Ie:\nplayer distance [0,0,200]\nwill return 200, if the player is at this position at ground/sea level."},{"user":"AgentRev01","date":"2014-03-23T02:52:00Z","text":"When objects are supplied as arguments, distance is calculated from their model center (object modelToWorld [0,0,0]), and not the position returned by getPos/ATL/ASL.\n\nHowever, this is not relevant for units, as their model center matches their world position."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"distance2D","operator":null,"title":"distance2D","type":"command","url":"https://community.bistudio.com/wiki/distance2D","revid":363614,"updated":"2024-04-08T11:45:05Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a 2D distance (distance projected to X,Y plane) in meters between Objects and/or Positions.","syntaxes":[{"syntax":"from distance2D to","since":null,"effect":null,"exec":null,"params":[{"name":"from","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"from: Object, Position2D or Position3D"},{"name":"to","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"to: Object, Position2D or Position3D"}],"returns":{"type":"Number","types":["Number"],"description":"distance in meters or 1e10 if distance cannot be calculated","text":"Number - distance in meters or 1e10 if distance cannot be calculated"},"form":"binary","operator":null,"left":{"text":"from","types":["Object","Position2D","Position3D"]},"right":{"text":"to","types":["Object","Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_meters = player distance2D heli;\n```","code":["_meters = player distance2D heli;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["distance","distanceSqr","vectorDistance"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"distanceSqr","operator":null,"title":"distanceSqr","type":"command","url":"https://community.bistudio.com/wiki/distanceSqr","revid":352357,"updated":"2024-02-08T14:07:32Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Computes the [squared distance](https://en.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance) between two objects or positions.\nThis command is faster than distance by saving a square root operation, useful for mass-checking distance without the need of the distance value itself.","syntaxes":[{"syntax":"var1 distanceSqr var2","since":null,"effect":null,"exec":null,"params":[{"name":"var1","type":"Object or Position","optional":false,"default":null,"description":null,"types":["Object","Position"],"since":null,"text":"var1: Object or Position"},{"name":"var2","type":"Object or Position","optional":false,"default":null,"description":null,"types":["Object","Position"],"since":null,"text":"var2: Object or Position"}],"returns":{"type":"Number","types":["Number"],"description":"distance in meters or 1e10 if distance cannot be calculated","text":"Number - distance in meters or 1e10 if distance cannot be calculated"},"form":"binary","operator":null,"left":{"text":"var1","types":["Object","Position"]},"right":{"text":"var2","types":["Object","Position"]}},{"syntax":"a distanceSqr b","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":"distance c calculated as `c = a * a + b * b`","text":"Number - distance c calculated as `c = a * a + b * b`"},"form":"binary","operator":null,"left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _distanceSquared = 5 * 5;\nif (player distanceSqr leader player < _distanceSquared) then // similar to player distance leader player < 5\n{\n    hint \"You are less than 5m from the leader!\";\n};\n```","code":["private _distanceSquared = 5 * 5;\nif (player distanceSqr leader player < _distanceSquared) then // similar to player distance leader player < 5\n{\n\thint \"You are less than 5m from the leader!\";\n};"]},{"text":"```sqf\nprivate _distance = sqrt ((x2 - x1) ^ 2 + (y2 - y1) ^ 2 + (z2 - z1) ^ 2);\nprivate _distanceSqr = (x2 - x1) ^ 2 + (y2 - y1) ^ 2 + (z2 - z1) ^ 2;\n_distance = [x1, y1, z1] distance [x2, y2, z2];\n_distanceSqr = [x1, y1, z1] distanceSqr [x2, y2, z2];\n_distance = sqrt ([x1, y1, z1] distanceSqr [x2, y2, z2]);\n_distanceSqr = ([x1, y1, z1] distance [x2, y2, z2]) ^ 2;\n```","code":["private _distance = sqrt ((x2 - x1) ^ 2 + (y2 - y1) ^ 2 + (z2 - z1) ^ 2);\nprivate _distanceSqr = (x2 - x1) ^ 2 + (y2 - y1) ^ 2 + (z2 - z1) ^ 2;\n_distance = [x1, y1, z1] distance [x2, y2, z2];\n_distanceSqr = [x1, y1, z1] distanceSqr [x2, y2, z2];\n_distance = sqrt ([x1, y1, z1] distanceSqr [x2, y2, z2]);\n_distanceSqr = ([x1, y1, z1] distance [x2, y2, z2]) ^ 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["distance","vectorDistanceSqr","distance2D"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"distributionRegion","operator":null,"title":"distributionRegion","type":"command","url":"https://community.bistudio.com/wiki/distributionRegion","revid":318977,"updated":"2022-05-13T09:22:07Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the numerical index for the distribution region of this copy of Armed Assault.\n1. USA\n1. Rest of the world","syntaxes":[{"syntax":"distributionRegion","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (distributionRegion == 1) then { hint \"miles\"; } else { hint \"kilometres\"; };\n```","code":["if (distributionRegion == 1) then { hint \"miles\"; } else { hint \"kilometres\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["productVersion"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"do","operator":null,"title":"do","type":"command","url":"https://community.bistudio.com/wiki/do","revid":311159,"updated":"2022-05-11T13:17:42Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes *code*. Used as part of a construct, such as while, with, for and switch. The *code* is always executed in missionNamespace unless do is used with with as an argument.","syntaxes":[{"syntax":"construct do code","since":null,"effect":null,"exec":null,"params":[{"name":"construct","type":null,"optional":false,"default":null,"description":"While Type (while), With Type (with), For Type (for), Switch Type (switch)","types":["While Type","while","With Type","with","For Type","for","Switch Type","switch"],"since":null,"text":"construct: While Type (while), With Type (with), For Type (for), Switch Type (switch)"},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"construct","types":["While Type","while","With Type","with","For Type","for","Switch Type","switch"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nwhile { b > a } do\n{\n    a = a + 1;\n};\n```","code":["while { b > a } do\n{\n\ta = a + 1;\n};"]},{"text":"```sqf\nwith uiNamespace do\n{\n    MyUIVar = MyUIVar + 5;\n};\n```","code":["with uiNamespace do\n{\n\tMyUIVar = MyUIVar + 5;\n};"]},{"text":"```sqf\nfor \"_i\" from 1 to 10 do\n{\n    systemChat str _i;\n    sleep 0.5;\n};\n```","code":["for \"_i\" from 1 to 10 do\n{\n\tsystemChat str _i;\n\tsleep 0.5;\n};"]},{"text":"```sqf\nswitch (50) do\n{\n    case 25: { hint \"25\" };\n    case 50: { hint \"50\" }; // hints \"50\"\n    case 75: { hint \"75\" };\n    default { hint \"nope\" };\n};\n```","code":["switch (50) do\n{\n\tcase 25: { hint \"25\" };\n\tcase 50: { hint \"50\" }; // hints \"50\"\n\tcase 75: { hint \"75\" };\n\tdefault { hint \"nope\" };\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"do3DENAction","operator":null,"title":"do3DENAction","type":"command","url":"https://community.bistudio.com/wiki/do3DENAction","revid":378238,"updated":"2026-03-20T14:10:01Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Performs given Eden Editor action.\n\n> [!WARNING]\n> Prior to Arma 3 v2.12 it was possible to use this command outside of Eden Editor.\n>\n> For example `do3DENAction \"MissionSave\";` would wipe the mission.sqm without a way to restore it when executed accidentally during preview.","syntaxes":[{"syntax":"do3DENAction action","since":null,"effect":null,"exec":null,"params":[{"name":"action","type":"String","optional":false,"default":null,"description":"see Eden Editor: Actions","types":["String"],"since":null,"text":"action: String - see Eden Editor: Actions"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"action","types":["String"]}},{"syntax":"do3DENAction [action, argument]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"action","type":"String","optional":false,"default":null,"description":"see Eden Editor: Actions","types":["String"],"since":null,"text":"action: String - see Eden Editor: Actions"},{"name":"argument","type":"Anything","optional":false,"default":null,"description":"depends on the used action","types":["Anything"],"since":null,"text":"argument: Anything - depends on the used action"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[action, argument]","types":["Array"]}}],"examples":[{"text":"```sqf\ndo3DENAction \"MissionSave\";\n```","code":["do3DENAction \"MissionSave\";"]},{"text":"```sqf\n// Since 2.22\nprivate _par = createHashMap;\n_par set [\"name\", \"testfile\"];\n_par set [\"folder\", \"subfolder\"];\n_par set [\"content\", \"R3voing\"];\n\ndo3DENAction [\"CreateTextFile\", _par];\n```","code":["// Since 2.22\nprivate _par = createHashMap;\n_par set [\"name\", \"testfile\"];\n_par set [\"folder\", \"subfolder\"];\n_par set [\"content\", \"R3voing\"];\n\ndo3DENAction [\"CreateTextFile\", _par];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENActionState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"doArtilleryFire","operator":null,"title":"doArtilleryFire","type":"command","url":"https://community.bistudio.com/wiki/doArtilleryFire","revid":377401,"updated":"2026-01-02T06:44:56Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Orders an artillery unit to fire a burst on the given position (silently).","syntaxes":[{"syntax":"unit doArtilleryFire [position, type, rounds]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"position: PositionAGL"},{"name":"type","type":"String","optional":false,"default":null,"description":"magazine class name from CfgMagazines (case sensitive).","types":["String"],"since":null,"text":"type: String - magazine class name from CfgMagazines (case sensitive)."},{"name":"rounds","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rounds: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[position, type, rounds]","types":["Array"]}}],"examples":[{"text":"```sqf\nMortar doArtilleryFire [[3000, 120, 1000], \"8Rnd_82mm_Mo_shells\", 3];\n```","code":["Mortar doArtilleryFire [[3000, 120, 1000], \"8Rnd_82mm_Mo_shells\", 3];"]}],"multiplayer":null,"problems":"The unit will fire a burst even if the **rounds** parameter is 0 or a negative number.","aliases":[],"see_also":["commandArtilleryFire","getArtilleryAmmo","getArtilleryETA","enableEngineArtillery","getArtilleryComputerSettings","shownArtilleryComputer","inRangeOfArtillery","fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandSuppressiveFire","doSuppressiveFire","isManualFire"],"notes":[{"user":"ansin11","date":"2020-04-18T14:26:00Z","text":"This command can not fire bursts consisting of more rounds than the given magazine type holds, even if there are several magazines of the same type available. The fire mission issued by this command ends once the artillery unit has to reload.\n\n**Example:**\n\nThe Mk6 Mortar comes with four \"8Rnd_82mm_Mo_shells\" magazines, giving it a total of 32 HE shells. However, `_mortar doArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 10];` will only fire 8 rounds instead of 10.\n\nSimilarly, ...\n\n```sqf\n_mortar doArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 7]; // First burst\nsleep 20; // Wait until first burst has been fired\n_mortar doArtilleryFire [_somePos, \"8Rnd_82mm_Mo_shells\", 2]; // Second burst\n```\n\n... will only fire 8 rounds total instead of 9; the second round of the second burst is never fired because the artillery unit has to reload after the first round of the second burst."},{"user":"Leopard20","date":"2022-08-25T21:05:17Z","text":"After using this command, use unitReady to see if the unit is done firing all rounds:\n\n```sqf\n_mortar doArtilleryFire [[3000, 120, 1000], \"8Rnd_82mm_Mo_shells\", 3];\nwaitUntil {sleep 1; unitReady _mortar}; // Note: make sure you run this in scheduled environment\n_mortar sideChat \"Rounds fired!\";\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"doFire","operator":null,"title":"doFire","type":"command","url":"https://community.bistudio.com/wiki/doFire","revid":378648,"updated":"2026-05-17T15:10:41Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to fire on the given target (without radio messages).\n\nThe target is set with doTarget or commandTarget.\n\nThe target can be a unit or a vehicle, but not an object.","syntaxes":[{"syntax":"unit doFire target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_ESoldier1 doFire _WSoldier1;\n```","code":["_ESoldier1 doFire _WSoldier1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire"],"notes":[{"user":"Hardrock","date":"2006-08-03T14:31:00Z","text":"*Notes from before the conversion:*\n\nIt is often helpful to use doTarget first."},{"user":"Hurricane","date":"2007-03-25T23:17:00Z","text":"A unit will not execute this command when his behaviour is set to \"careless\"."},{"user":"Sakura_chan","date":"2012-06-07T14:05:00Z","text":"`unitName doFire objNull` does not work like it does in `commandFire`.\nTarget var has to be real (Arma 2:OA) might be different in other versions."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doFollow","operator":null,"title":"doFollow","type":"command","url":"https://community.bistudio.com/wiki/doFollow","revid":353189,"updated":"2024-03-12T13:35:21Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to follow another from his own group as his formation leader (without radio messages).\n\nIt is also used to order the unit to **return to formation** after e.g doStop even if it is the leader himself that should return to formation (see Example 2).","syntaxes":[{"syntax":"unit doFollow unitLead","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects"},{"name":"unitLead","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitLead: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"unitLead","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldier1 doFollow _soldier2;\n```","code":["_soldier1 doFollow _soldier2;"]},{"text":"```sqf\nunits _group doFollow leader _group; // returns all the units to formation\n```","code":["units _group doFollow leader _group; // returns all the units to formation"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doStop","doMove","commandFollow","formationLeader","formLeader","isFormationLeader","leader","selectLeader","setLeader"],"notes":[{"user":"Mojito69","date":"2010-10-11T18:00:00Z","text":"These commands (doFollow or commandFollow) work only if the two units are in the same group."},{"user":"BaerMitUmlaut","date":"2016-08-29T23:48:00Z","text":"The name of this command is a bit misleading, it is used to make a unit return to the formation of its group or subformation."},{"user":"Leopard20","date":"2022-02-17T12:25:29Z","text":"doFollow doesn't work with player-issued commands (those issued via the commanding menus). As a workaround, it is possible to use joinSilent instead, and join the unit into its current group:\n\n```sqf\n[_unit] joinSilent group _unit; // return to formation\n```\n\nNote that the group must have **at least 2 units**, and not all units should be joined at once, otherwise the group will temporarily become empty and all its waypoints **will be lost**!"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doFSM","operator":null,"title":"doFSM","type":"command","url":"https://community.bistudio.com/wiki/doFSM","revid":377167,"updated":"2026-01-01T10:44:05Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Orders a unit to process command defined by FSM file (silently).\n\nUnlike with execFSM where *_this* is passed to the FSM, the following parameters are passed when using doFSM/commandFSM:\n\n_leader: leader of subgroup with this command\n_destination: command destination/position\n_target: command target\n_units: list of all persons in subgroup","syntaxes":[{"syntax":"unit doFSM [fsmName, position, target]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects"},{"name":"fsmName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fsmName: String"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"[fsmName, position, target]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne doFSM [\"move.fsm\", position player, player];\n```","code":["_soldierOne doFSM [\"move.fsm\", position player, player];"]},{"text":"```sqf\nunits player doFSM [\"move.fsm\", position player, player];\n```","code":["units player doFSM [\"move.fsm\", position player, player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","FSM Editor Manual","commandFSM","completedFSM","execFSM","getFSMVariable","setFSMVariable","unitReady"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"doGetOut","operator":null,"title":"doGetOut","type":"command","url":"https://community.bistudio.com/wiki/doGetOut","revid":310022,"updated":"2022-05-05T12:20:49Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Orders one or multiple units to get out from the vehicle (silently). Same as commandGetOut with latter being shown via radio chat.\n\nNotes:\n- Works for both AI and player entities\n- AI unit gets back in - unless is under player command or combined with other sqf commands (orderGetIn false, allowGetIn false or leaveVehicle)\n- Ignores vehicle's lock state - unlike action \"Eject\" and moveOut\n- AI waits for execution until vehicle has stopped/is no longer flying (unclear if any timeout exists for order to be discarded) - unlike action \"Eject\" and moveOut\n- Plays the vehicle's position's get out animation (same as action \"Eject\") - unlike moveOut\n- When execute for multiple units, it waits till the action is completed, before the next to take his turn (same as action \"Eject\") - unlike moveOut\n- AI gets back into formation afterwards\n- Works only on alive units - unlike action \"Eject\" (one after another) or moveOut (instantly)\n- Does not work on unconscious - unless the AI is under player command. Unlike moveOut or action \"Eject\" (but one after another))","syntaxes":[{"syntax":"doGetOut units","since":null,"effect":null,"exec":null,"params":[{"name":"units","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"units: Object or Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"units","types":["Object","Array"]}}],"examples":[{"text":"```sqf\ndoGetOut _unitOne;\n```","code":["doGetOut _unitOne;"]},{"text":"```sqf\ndoGetOut [_unitOne,_unitTwo];\n```","code":["doGetOut [_unitOne,_unitTwo];"]}],"multiplayer":"This command is only effective when used on local units. When used on a remote unit, this command will create radio dialogue on the machine the unit is local to, but the unit will not leave the vehicle.","problems":null,"aliases":[],"see_also":["commandGetOut","moveOut","leaveVehicle"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doMove","operator":null,"title":"doMove","type":"command","url":"https://community.bistudio.com/wiki/doMove","revid":377517,"updated":"2026-01-02T06:52:02Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to move to the given position (without radio messages). Upon reaching its destination, if it is the group leader it will order the group to form around it's new position. If it is not the leader, it will immediately be ordered to return to formation by the group leader and begin moving back to the group. Use doStop to stop units returning to formation. moveToCompleted will return true when a unit issued this command reaches its destination.","syntaxes":[{"syntax":"unit(s) doMove position","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit(s)","types":["Object","Array"]},"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\n_soldier1 doMove (position _officer);\n```","code":["_soldier1 doMove (position _officer);"]},{"text":"```sqf\nthis doMove (getMarkerPos \"Marker1\");\n```","code":["this doMove (getMarkerPos \"Marker1\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandMove","setDestination","moveTo","move","addWaypoint"],"notes":[{"user":"DreadedEntity","date":"2022-04-02T15:22:26Z","text":"The above note is only true of units which group leader is not the player. Player-squad will remain in position until given another order (A3 v2.08.149102)"},{"user":"DreadedEntity","date":"2022-04-02T20:35:58Z","text":"If you need your script to halt until the unit has reached it's destination, waitUntil and moveToCompleted will come in handy:\n\n```sqf\n_unit doMove _pos;\nwaitUntil {moveToCompleted _unit};\n```\n\nThis also works with commandMove"},{"user":"Waffle SS.","date":"2022-07-25T06:25:19Z","text":"Seems to use PositionATL, which may be important if the destination is above a building's 1st floor."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doorPhase","operator":null,"title":"doorPhase","type":"command","url":"https://community.bistudio.com/wiki/doorPhase","revid":318909,"updated":"2022-05-13T09:22:01Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return animation phase of door on vehicle.","syntaxes":[{"syntax":"object doorPhase door","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"door","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"door: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"door","types":["String"]}}],"examples":[{"text":"```sqf\n_phase = heli doorPhase \"door_L\";\n```","code":["_phase = heli doorPhase \"door_L\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animateDoor","setFaceAnimation","animate","animationPhase","animateSource","animationSourcePhase","animationNames"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"doStop","operator":null,"title":"doStop","type":"command","url":"https://community.bistudio.com/wiki/doStop","revid":336220,"updated":"2022-12-14T20:43:09Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to stop (without radio messages). The units stopped in this way will leave the groups formation. It will prevent them from moving around with their group (or formation leader), while still being able to turn around and even move to a new position if they see fit.\n\nThe units will still respond to orders from their group leader (like engage, rearm, board a vehicle), but all of their actions will be separate from the group formation. To resume group default behaviour, use doFollow command. For example: `units _group doFollow leader _group;`","syntaxes":[{"syntax":"doStop unit(s)","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit(s)","types":["Object","Array"]}}],"examples":[{"text":"```sqf\ndoStop _soldier1;\n```","code":["doStop _soldier1;"]},{"text":"```sqf\ndoStop [_soldier1, _soldier2];\n```","code":["doStop [_soldier1, _soldier2];"]},{"text":"```sqf\ndoStop (units player);\n```","code":["doStop (units player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandStop","stop","stopped","doMove","doFollow"],"notes":[{"user":"Hardrock","date":"2006-08-03T14:32:00Z","text":"*Notes from before the conversion:*\n\nThis command will make the unit stop where he is until the unit's group engages the enemy. At that time, the unit will move and fight the enemy. One good use for this is to place a bunch of units in the same group around a campfire or in some other place \"for looks\", and make them sit down or have their weapon on their back. When the enemy is spotted, they will get up and attack. Note that you cannot do something like place somebody behind sandbags and keep him there during a fight with this command. For that you will need disableAI \"move\"."},{"user":"Ceeeb","date":"2009-02-21T00:13:00Z","text":"In **ArmA 1.14**, this command will not stop a unit that has been given a move order by selecting the unit, then clicking on the in game map (or ground)."},{"user":"Katulobotomia","date":"2013-09-26T12:30:00Z","text":"doStop'ed units WILL return to formation if their leader's behaviour isn't set to \"COMBAT\". The squad leader will also order everyone to return to formation if there are no enemies nearby in a set period of time, overwriting the doStop command. doStop can be best used to simply stop the unit from doing whatever he is currently doing without radio messages."},{"user":"Killzone_Kid","date":"2016-12-23T21:22:00Z","text":"When a unit reaches position given with doMove, unitReady becomes true. If doStop command is not executed, unit will start wondering on its own soon after, especially if unit is under fire. doStop will keep unit at the given position, but watch out for unitReady as it will become false since unit is holding position indefinitely."},{"user":"Killzone_Kid","date":"2016-12-27T00:30:00Z","text":"Although it is possible to resume group default behaviour by joining units into own group like this `units _group joinSilent _group` there is a risk that the leader will change. Instead use doFollow command as explained in the description."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doSuppressiveFire","operator":null,"title":"doSuppressiveFire","type":"command","url":"https://community.bistudio.com/wiki/doSuppressiveFire","revid":377829,"updated":"2026-01-03T04:28:58Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Orders the given unit or a group of units to suppress the given position or target (without radio messages, see commandSuppressiveFire is you need messages).\n- When an Array of units is passed as param, only units from the same Group as the first unit in array are considered.\n- The unit (units) starts firing at the given target or position random amount of shots (exact formula unknown, but seems to depend on amount of ammo unit has) after which it stops.\n- currentCommand shows `\"Suppress\"` and there is no way of stopping unit before it completes random amount of rounds.\n- If position is passed as target param, it stays fixed.\n- If object is passed as target param, it depends on what kind of object. If it is considered a proper target by the unit, it is tracked by the unit dynamically. If it is not, the position gets obtained via getPosWorld, which could be different from PositionASL of the object, and it is fixed even if the target is able to change position later.","syntaxes":[{"syntax":"unit doSuppressiveFire target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":"a single unit or array of units","types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects - a single unit or array of units"},{"name":"target","type":"Object or PositionASL","optional":false,"default":null,"description":"actual target or position of the target","types":["Object","PositionASL"],"since":null,"text":"target: Object or PositionASL - actual target or position of the target"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"target","types":["Object","PositionASL"]}}],"examples":[{"text":"```sqf\n_soldier doSuppressiveFire [1869.508,5760.962,0.000];\n```","code":["_soldier doSuppressiveFire [1869.508,5760.962,0.000];"]},{"text":"```sqf\nunits player doSuppressiveFire cursorTarget;\n```","code":["units player doSuppressiveFire cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["suppressFor","fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","isManualFire"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.60","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"doTarget","operator":null,"title":"doTarget","type":"command","url":"https://community.bistudio.com/wiki/doTarget","revid":378351,"updated":"2026-04-02T16:33:07Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to target the given target (without radio messages).\nTargeting can be stopped by \n\n```sqf\n_unit doWatch objNull;\n```\n\n or\n\n```sqf\n_unit commandWatch objNull;\n```","syntaxes":[{"syntax":"unit doTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Array of Objects","optional":false,"default":null,"description":"a single unit or array of units","types":["Object","Array"],"since":null,"text":"unit: Object or Array of Objects - a single unit or array of units"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object","Array"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_ESoldier1 doTarget _WSoldier1;\n```","code":["_ESoldier1 doTarget _WSoldier1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedTarget","commandTarget","doWatch","doFire"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"doWatch","operator":null,"title":"doWatch","type":"command","url":"https://community.bistudio.com/wiki/doWatch","revid":377524,"updated":"2026-01-02T06:52:15Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order the given unit(s) to watch the given position or target (without radio messages). Use objNull as the target to order a unit to stop watching a position/target.","syntaxes":[{"syntax":"unit(s) doWatch position","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit(s)","types":["Object","Array"]},"right":{"text":"position","types":["Position"]}},{"syntax":"unit(s) doWatch target","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit(s)","types":["Object","Array"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldierOne doWatch markerPos \"MarkerMoveOne\";\n```\n\nThe unit named \"soldierOne\" will watch the position where the marker \"MarkerMoveOne\" is placed.","code":["_soldierOne doWatch markerPos \"MarkerMoveOne\";"]},{"text":"```sqf\n_soldierOne doWatch _eastSoldier;\n```\n\nThe unit named \"soldierOne\" will watch the unit named \"eastSoldier\".","code":["_soldierOne doWatch _eastSoldier;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandWatch","lookAt","glanceAt"],"notes":[],"categories":[]},{"name":"drawArrow","operator":null,"title":"drawArrow","type":"command","url":"https://community.bistudio.com/wiki/drawArrow","revid":377545,"updated":"2026-01-02T06:54:38Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws a single line arrow on the map.\nAs this command needs to be called every frame, it is preferable using the onDraw UI Event Handler.\nTo draw a color filled arrow of custom shape see BIS_fnc_drawArrow.","syntaxes":[{"syntax":"map drawArrow [from, to, color]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"from","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":"arrow start position","types":["Object","Position2D","Position3D"],"since":null,"text":"from: Object or Position2D or Position3D - arrow start position"},{"name":"to","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":"arrow end position","types":["Object","Position2D","Position3D"],"since":null,"text":"to: Object or Position2D or Position3D - arrow end position"},{"name":"color","type":"Array","optional":false,"default":null,"description":"arrow color in format [r,g,b,a]","types":["Array"],"since":null,"text":"color: Array - arrow color in format [r,g,b,a]"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[from, to, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    _this select 0 drawArrow [\n        player,\n        player getRelPos [100, 0],\n        [1,0,0,1]\n    ];\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n\t_this select 0 drawArrow [\n\t\tplayer,\n\t\tplayer getRelPos [100, 0],\n\t\t[1,0,0,1]\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawEllipse","drawIcon","drawLine","drawRectangle","drawPolygon","drawTriangle","drawXPolygon","BIS_fnc_drawArrow"],"notes":[{"user":"Waffle SS.","date":"2015-07-07T21:28:00Z","text":"Be careful when using this command. Unlike map markers, the draw commands can decrease your framerate."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawEllipse","operator":null,"title":"drawEllipse","type":"command","url":"https://community.bistudio.com/wiki/drawEllipse","revid":377551,"updated":"2026-01-02T06:54:48Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws an ellipse on the map. Just like with marker or trigger area, negative *a* and *b* will result in hexagon.","syntaxes":[{"syntax":"map drawEllipse [centre, a, b, angle, color, fill, alignWithMap]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"centre","type":"Object or Position2D, Position3D","optional":false,"default":null,"description":"ellipse's centre","types":["Object","Position2D","Position3D"],"since":null,"text":"centre: Object or Position2D, Position3D - ellipse's centre"},{"name":"a","type":"Number","optional":false,"default":null,"description":"horizontal (x) radius","types":["Number"],"since":null,"text":"a: Number - horizontal (x) radius"},{"name":"b","type":"Number","optional":false,"default":null,"description":"vertical (y) radius","types":["Number"],"since":null,"text":"b: Number - vertical (y) radius"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"angle of rotation in degrees","types":["Number"],"since":null,"text":"angle: Number - angle of rotation in degrees"},{"name":"color","type":"Color (RGBA)","optional":false,"default":null,"description":"line color","types":["Color"],"since":null,"text":"color: Color (RGBA) - line color"},{"name":"fill","type":"String","optional":false,"default":null,"description":"fill texture file or Procedural Textures. Note that the file texture will not rotate with rectangle, use drawIcon for that. If fill texture is not empty, set line color to white [1,1,1,1]","types":["String"],"since":null,"text":"fill: String - fill texture file or Procedural Textures. Note that the file texture will not rotate with rectangle, use drawIcon for that. If fill texture is not empty, set line color to white [1,1,1,1]"},{"name":"alignWithMap","type":"Boolean","optional":true,"default":"true","description":"when false the shape will not follow map rotation.","types":["Boolean"],"since":"Arma3 2.18","text":"alignWithMap: Boolean - (Optional, default true) - when false the shape will not follow map rotation."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[centre, a, b, angle, color, fill, alignWithMap]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    _this select 0 drawEllipse [\n        player, 10, 10, 0, [1, 0, 0, 1], \"\"\n    ];\n    _this select 0 drawEllipse [\n        player, -10, -10, 0, [1, 1, 1, 1], \"#(rgb,8,8,3)color(1,0.6,0,1)\"\n    ];\n    _this select 0 drawEllipse [\n        player, -10, -10, 90, [0, 0, 1, 1], \"\"\n    ];\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n\t_this select 0 drawEllipse [\n\t\tplayer, 10, 10, 0, [1, 0, 0, 1], \"\"\n\t];\n\t_this select 0 drawEllipse [\n\t\tplayer, -10, -10, 0, [1, 1, 1, 1], \"#(rgb,8,8,3)color(1,0.6,0,1)\"\n\t];\n\t_this select 0 drawEllipse [\n\t\tplayer, -10, -10, 90, [0, 0, 1, 1], \"\"\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawIcon","drawLine","drawRectangle","drawPolygon","drawTriangle","drawXPolygon"],"notes":[{"user":"Waffle SS.","date":"2015-07-07T21:28:00Z","text":"Be careful when using this command. Unlike map markers, the draw commands can decrease your framerate."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawIcon","operator":null,"title":"drawIcon","type":"command","url":"https://community.bistudio.com/wiki/drawIcon","revid":378474,"updated":"2026-04-24T11:03:12Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Draws an icon on the map.\nAs this command needs to be called every frame, it is preferable using the onDraw UI Event Handler.\n\n> [!NOTE]\n> Some useful icons can be found in `configFile >> \"CfgVehicleIcons\"`.","syntaxes":[{"syntax":"map drawIcon [texture, color, position, width, height, angle, text, shadow, textSize, font, align]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"texture","type":"String","optional":false,"default":null,"description":"icon texture","types":["String"],"since":null,"text":"texture: String - icon texture"},{"name":"color","type":"Color (RGBA)","optional":false,"default":null,"description":"text and icon color","types":["Color"],"since":null,"text":"color: Color (RGBA) - text and icon color"},{"name":"position","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"position: Object, Position2D or Position3D"},{"name":"width","type":"Number","optional":false,"default":null,"description":"width of the icon (but not the text)","types":["Number"],"since":null,"text":"width: Number - width of the icon (but not the text)"},{"name":"height","type":"Number","optional":false,"default":null,"description":"height of the icon (but not the text)","types":["Number"],"since":null,"text":"height: Number - height of the icon (but not the text)"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"rotation angle of the icon not the text (add to it ctrlMapDir to show correctly on rotating minimap)","types":["Number"],"since":null,"text":"angle: Number - rotation angle of the icon not the text (add to it ctrlMapDir to show correctly on rotating minimap)"},{"name":"text","type":"String","optional":true,"default":"\"\"","description":null,"types":["String"],"since":null,"text":"text: String - (Optional, default \"\")"},{"name":"shadow","type":"Number or Boolean","optional":true,"default":"false","description":"can be one of:\n- 0 (false): no shadow\n- 1: shadow (for text)\n- 2 (true): outline (works for text and for icon only if icon angle is 0)","types":["Number","Boolean"],"since":null,"text":"shadow: Number or Boolean - (Optional, default false) can be one of:\n- 0 (false): no shadow\n- 1: shadow (for text)\n- 2 (true): outline (works for text and for icon only if icon angle is 0)"},{"name":"textSize","type":"Number","optional":true,"default":"-1","description":"size of the text in UI units","types":["Number"],"since":"arma3 0.72","text":"textSize: Number - (Optional, default -1) size of the text in UI units"},{"name":"font","type":"String","optional":true,"default":"\"\"","description":"text's font","types":["String"],"since":"arma3 0.72","text":"font: String - (Optional, default \"\") text's font"},{"name":"align","type":"String","optional":true,"default":"\"right\"","description":"text alignment. Can be:\n- \"left\"\n- \"right\"\n- \"center\"","types":["String"],"since":"arma3 0.72","text":"align: String - (Optional, default \"right\") text alignment. Can be:\n- \"left\"\n- \"right\"\n- \"center\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[texture, color, position, width, height, angle, text, shadow, textSize, font, align]","types":["Array"]}}],"examples":[{"text":"Red icon with text:\n\n```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", {\n    _this select 0 drawIcon [\n        \"iconStaticMG\", // custom images can also be used: getMissionPath \"\\myFolder\\myIcon.paa\"\n        [1,0,0,1],\n        getPosASLVisual player,\n        24,\n        24,\n        getDirVisual player,\n        \"Player Vehicle\",\n        1,\n        0.03,\n        \"TahomaB\",\n        \"right\"\n    ]\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", {\n\t_this select 0 drawIcon [\n\t\t\"iconStaticMG\", // custom images can also be used: getMissionPath \"\\myFolder\\myIcon.paa\"\n\t\t[1,0,0,1],\n\t\tgetPosASLVisual player,\n\t\t24,\n\t\t24,\n\t\tgetDirVisual player,\n\t\t\"Player Vehicle\",\n\t\t1,\n\t\t0.03,\n\t\t\"TahomaB\",\n\t\t\"right\"\n\t]\n}];"]},{"text":"Green text only:\n\n```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", {\n    _this select 0 drawIcon [\n        \"#(rgb,1,1,1)color(1,1,1,1)\",\n        [0,1,0,1],\n        player,\n        0,\n        0,\n        0,\n        name player\n    ]\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", {\n\t_this select 0 drawIcon [\n\t\t\"#(rgb,1,1,1)color(1,1,1,1)\",\n\t\t[0,1,0,1],\n\t\tplayer,\n\t\t0,\n\t\t0,\n\t\t0,\n\t\tname player\n\t]\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawEllipse","drawLine","drawRectangle","drawPolygon","drawTriangle","drawXPolygon"],"notes":[{"user":"Benargee","date":"2016-01-04T05:41:00Z","text":"Arma 3 1.54\n\nThis command does not seem to play nice with onEachFrame. It seems to draw on the main screen while maintaing position relative to the map position\n\nExample:\n\n```sqf\nonEachFrame {\n    findDisplay 12 displayCtrl 51 drawIcon ['iconStaticMG', [1,0,0,1], getPosASL player, 24, 24, getDir player, 'Player Vehicle', 1, 0.03, 'TahomaB', 'right'];\n};\n```"},{"user":"Leopard20","date":"2022-05-09T19:34:07Z","text":"The icon size always stays the same, even after zooming in/out. To make the icon get bigger with map zoom, use this for width and height size:\n\n```sqf\nprivate _scale = 6.4 * worldSize / 8192 * ctrlMapScale _map;\nprivate _size = _sizeInMeters / _scale;\n```\n\nFor example, the following icon has an exact size of 50 meters on the map, even after zooming in/out:\n\n```sqf\nprivate _scale = 6.4 * worldSize / 8192 * ctrlMapScale _map;\nprivate _size = 50 / _scale;\n_map drawIcon [\"iconStaticMG\", [1,0,0,1], getPosASLVisual player, _size, _size, 0]\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"drawIcon3D","operator":null,"title":"drawIcon3D","type":"command","url":"https://community.bistudio.com/wiki/drawIcon3D","revid":378664,"updated":"2026-05-18T18:59:17Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Draws an icon at the given position in the game world. This command has to be executed every frame. Use the Draw3D Mission Event Handler (which is executed every frame if the user can see the icon).\n\nIn order for the results of this command to be visible through a custom camera, enable HUD with cameraEffectEnableHUD.\n\n`showHUD false` will hide the icon drawn by this command.\n\nIn order for arrows to appear, the icon texture should exist. The arrow size is proportionate to the icon size.\n\n> [!NOTE]\n> - To avoid flickering and ensure visual fidelity, always use the visual (render time scope) variant of position commands, such as getPosASLVisual.\n> - The *width* and *height* parameters are multipliers for `activeWidth` and `activeHeight` set in config. So for example, if one needs to create an icon half the screen wide (`safeZoneW / 2`) and half the screen tall (`safeZoneH / 2`), divide these by the according config values: \n>\n> ```sqf\n> private _iconWidth = (safeZoneW / 2) / getNumber (configFile >> \"CfgInGameUI\" >> \"Cursor\" >> \"activeWidth\");\n> private _iconHeight = (safeZoneH / 2) / getNumber (configFile >> \"CfgInGameUI\" >> \"Cursor\" >> \"activeHeight\");\n> ```","syntaxes":[{"syntax":"drawIcon3D [texture, color, position, width, height, angle, text, shadow, textSize, font, textAlign, drawSideArrows, offsetX, offsetY]","since":null,"effect":null,"exec":null,"params":[{"name":"texture","type":"String","optional":false,"default":null,"description":"icon texture","types":["String"],"since":null,"text":"texture: String - icon texture"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA) or Array of two Color (RGBA)\n- Color (RGBA) - icon color\n- Arma 3 v2.04 Array of two Arrays format Color (RGBA) - Icon and text color","types":["Color","Array"],"since":null,"text":"color: Color (RGBA) or Array of two Color (RGBA)\n- Color (RGBA) - icon color\n- Arma 3 v2.04 Array of two Arrays format Color (RGBA) - Icon and text color"},{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":"icon position","types":["PositionAGL"],"since":null,"text":"position: PositionAGL - icon position"},{"name":"width","type":"Number","optional":false,"default":null,"description":"icon width","types":["Number"],"since":null,"text":"width: Number - icon width"},{"name":"height","type":"Number","optional":false,"default":null,"description":"icon height","types":["Number"],"since":null,"text":"height: Number - icon height"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"icon rotation angle","types":["Number"],"since":null,"text":"angle: Number - icon rotation angle"},{"name":"text","type":"String","optional":true,"default":"\"\"","description":"text label to display next to the icon","types":["String"],"since":null,"text":"text: String - (Optional, default \"\") text label to display next to the icon"},{"name":"shadow","type":null,"optional":true,"default":"0","description":"Number:\n  - **0:** no shadow\n  - **1:** shadow (not used in this context, used in UI context)\n  - **2:** outline\n- Boolean:\n  - true - outline\n  - false - no shadow","types":[],"since":null,"text":"shadow: (Optional, default 0)\n- Number:\n  - **0:** no shadow\n  - **1:** shadow (not used in this context, used in UI context)\n  - **2:** outline\n- Boolean:\n  - true - outline\n  - false - no shadow"},{"name":"textSize","type":"Number","optional":true,"default":"size of system","description":"text size","types":["Number"],"since":null,"text":"textSize: Number - (Optional, default size of system) text size"},{"name":"font","type":"String","optional":true,"default":"\"RobotoCondensedBold\"","description":"font class name from `CfgFontFamilies` (see FXY File Format#Available Fonts)","types":["String"],"since":null,"text":"font: String - (Optional, default \"RobotoCondensedBold\") font class name from `CfgFontFamilies` (see FXY File Format#Available Fonts)"},{"name":"textAlign","type":"String","optional":true,"default":"\"center\"","description":"text alignment, can be one of:\n- \"left\" - aligns the end of text line with the given position (text appears to the left of the position)\n- \"right\" - aligns the beginning of text line with the given position (text appears to the right of the position)\n- \"center\" - aligns the middle of text line with the given position (text appears central to the position)","types":["String"],"since":null,"text":"textAlign: String - (Optional, default \"center\") text alignment, can be one of:\n- \"left\" - aligns the end of text line with the given position (text appears to the left of the position)\n- \"right\" - aligns the beginning of text line with the given position (text appears to the right of the position)\n- \"center\" - aligns the middle of text line with the given position (text appears central to the position)"},{"name":"drawSideArrows","type":"Boolean","optional":true,"default":"false","description":"true to draw arrows and the text label at edge of screen when the icon moves off the screen","types":["Boolean"],"since":null,"text":"drawSideArrows: Boolean - (Optional, default false) true to draw arrows and the text label at edge of screen when the icon moves off the screen"},{"name":"offsetX","type":"Number","optional":true,"default":"0","description":"X offset for the icon text","types":["Number"],"since":"arma3 2.04","text":"offsetX: Number - (Optional, default 0) X offset for the icon text"},{"name":"offsetY","type":"Number","optional":true,"default":"0","description":"Y offset for the icon text","types":["Number"],"since":"arma3 2.04","text":"offsetY: Number - (Optional, default 0) Y offset for the icon text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[texture, color, position, width, height, angle, text, shadow, textSize, font, textAlign, drawSideArrows, offsetX, offsetY]","types":["Array"]}},{"syntax":"drawIcon3D icon","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"icon","type":"HashMap","optional":true,"default":"0","description":"hashmap structure in the following **case-sensitive**, @-prefixed format:\n- @position: Array - the only mandatory parameter, can be one of the following formats:\n  - [x, y, (z:0)] - Position2D or PositionAGL\n  - [object, offsetZ]\n    - object: Object\n    - offsetZ: Number vertical offset\n  - [object, selection, offsetZ, lodIndex]\n    - object: Object\n    - selection: String - model selection, see animationNames, selectionNames\n    - offsetZ: Number -  vertical offset\n    - lodIndex: Number - (Optional, default Memory LOD index, see allLODs)\n- @texture: String - (Optional, default \"\") icon image\n- @size: Number - (Optional) texture sizeH, the sizeW is automatic, based on original texture dimensions (To find texture width use getTextureInfo)\n- @font: String - (Optional) global font name. Default current system font.\n- @color: Color - (Optional, default White) icon color\n- @shadow: Number - (Optional, default 0) could be one of the following:\n  - 0 - no shadow\n  - 1 - normal shadow (slight offset to the right and bottom)\n  - 2 - outline ('@shadowColor' does not work here, this outline is always black)\n  - 3 - thicker shadow (offset to the right and bottom, dynamic, approx 1.5% of the icon (w+h)/2)\n  - 4 - thicker outline (dynamic, approx 1.5% of the icon (w+h)/2)\n- @shadowColor: Color - (Optional, default [0,0,0,0]) '@shadow' color (see above)\n- @fade: Array - (Optional, default [-1, -1]) in format [distMin, distMax] start and end distance of icon fade\n- @dynamic: Boolean - (Optional, default false) true to change icon size dynamically with percieved view distance false static size\n- @offsetX: Number - (Optional, default 0) x offset in screen units. > 0 offset right, < 0 offset left (always 0 if @drawArrows true)\n- @offsetY: Number - (Optional, default 0) y offset in screen units. > 0 offset down, < 0 offset up (always 0 if @drawArrows true)\n- @hardAlpha: Number - (Optional, default -1) 0..1 global alpha override for entire icon\n- @checkVisibility: Boolean - (Optional, default false) true the icon will be obstructed by objects, smoke and vegetation\n- @drawArrows: Boolean - (Optional, default false) true to draw side out of view arrows and text for static icons only. Always false if @dynamic true\n- @arrowTexture: String - (Optional, default \"\\a3\\Ui_f\\data\\IGUI\\Cfg\\Cursors\\outArrow_ca.paa\") arrow texture\n- @arrowSize: Number - (Optional, default @size) arrow size, capped if smaller than @arrowText size\n- @arrowColor: Color - (Optional, default @color) arrow color\n- @arrowText: Array - (Optional, default []) text to draw next to side arrows for static icons only in format [text, size, offsetXCoef, offsetYCoef, color, shadow]:\n  - text: String - text to show next to arrow\n  - size: Number - (Optional, default current system font size) text height in screen units (To find text width use getTextWidth)\n  - offsetXCoef: Number - (Optional, default 1) X-spacing coefficient between arrows and text\n  - offsetYCoef: Number - (Optional, default 1) Y-spacing coefficient between arrows and text\n  - color: Color (Optional, default White) text color\n  - shadow: Boolean (Optional, default false) true to outline, false no shadow\n- @texts: Array of Arrays - (Optional, default []) multiple visible texts in format [[text, size, offsetX, offsetY, color, shadow], ...]:\n  - text: String - text to show\n  - size: Number - (Optional, default current system font size) text height in screen units (To find text width use getTextWidth)\n  - offsetX: Number - (Optional, default 0) x offset in screen units. > 0 offset right, < 0 offset left\n  - offsetY: Number - (Optional, default 0) y offset in screen units. > 0 offset down, < 0 offset up\n  - color: Color (Optional, default White) text color\n  - shadow: Boolean (Optional, default false) true to outline, false no shadow\n- @progress: Array - (Optional, default []) progress bar in format [width, height, offsetX, offsetY, colorFG, colorBG]:\n  - width: Number - width of the progress bar in screen units (width < height - vertical bar)\n  - height: Number - height of the progress bar in screen units (height <= width - horizontal bar)\n  - offsetX: Number - (Optional, default 0) x offset\n  - offsetY: Number - (Optional, default 0) y offset\n  - colorFG: Color - (Optional, default White) forground color\n  - colorBG: Color - (Optional, default Grey) background color\n- @progressValue: Number - (Optional, default -1) progress bar progress in 0...1 range. -1 - progress bar is not drawn","types":["HashMap"],"since":null,"text":"icon: HashMap - hashmap structure in the following **case-sensitive**, @-prefixed format:\n- @position: Array - the only mandatory parameter, can be one of the following formats:\n  - [x, y, (z:0)] - Position2D or PositionAGL\n  - [object, offsetZ]\n    - object: Object\n    - offsetZ: Number vertical offset\n  - [object, selection, offsetZ, lodIndex]\n    - object: Object\n    - selection: String - model selection, see animationNames, selectionNames\n    - offsetZ: Number - (Optional, default 0) vertical offset\n    - lodIndex: Number - (Optional, default Memory LOD index, see allLODs)\n- @texture: String - (Optional, default \"\") icon image\n- @size: Number - (Optional) texture sizeH, the sizeW is automatic, based on original texture dimensions (To find texture width use getTextureInfo)\n- @font: String - (Optional) global font name. Default current system font.\n- @color: Color - (Optional, default White) icon color\n- @shadow: Number - (Optional, default 0) could be one of the following:\n  - 0 - no shadow\n  - 1 - normal shadow (slight offset to the right and bottom)\n  - 2 - outline ('@shadowColor' does not work here, this outline is always black)\n  - 3 - thicker shadow (offset to the right and bottom, dynamic, approx 1.5% of the icon (w+h)/2)\n  - 4 - thicker outline (dynamic, approx 1.5% of the icon (w+h)/2)\n- @shadowColor: Color - (Optional, default [0,0,0,0]) '@shadow' color (see above)\n- @fade: Array - (Optional, default [-1, -1]) in format [distMin, distMax] start and end distance of icon fade\n- @dynamic: Boolean - (Optional, default false) true to change icon size dynamically with percieved view distance false static size\n- @offsetX: Number - (Optional, default 0) x offset in screen units. > 0 offset right, < 0 offset left (always 0 if @drawArrows true)\n- @offsetY: Number - (Optional, default 0) y offset in screen units. > 0 offset down, < 0 offset up (always 0 if @drawArrows true)\n- @hardAlpha: Number - (Optional, default -1) 0..1 global alpha override for entire icon\n- @checkVisibility: Boolean - (Optional, default false) true the icon will be obstructed by objects, smoke and vegetation\n- @drawArrows: Boolean - (Optional, default false) true to draw side out of view arrows and text for static icons only. Always false if @dynamic true\n- @arrowTexture: String - (Optional, default \"\\a3\\Ui_f\\data\\IGUI\\Cfg\\Cursors\\outArrow_ca.paa\") arrow texture\n- @arrowSize: Number - (Optional, default @size) arrow size, capped if smaller than @arrowText size\n- @arrowColor: Color - (Optional, default @color) arrow color\n- @arrowText: Array - (Optional, default []) text to draw next to side arrows for static icons only in format [text, size, offsetXCoef, offsetYCoef, color, shadow]:\n  - text: String - text to show next to arrow\n  - size: Number - (Optional, default current system font size) text height in screen units (To find text width use getTextWidth)\n  - offsetXCoef: Number - (Optional, default 1) X-spacing coefficient between arrows and text\n  - offsetYCoef: Number - (Optional, default 1) Y-spacing coefficient between arrows and text\n  - color: Color (Optional, default White) text color\n  - shadow: Boolean (Optional, default false) true to outline, false no shadow\n- @texts: Array of Arrays - (Optional, default []) multiple visible texts in format [[text, size, offsetX, offsetY, color, shadow], ...]:\n  - text: String - text to show\n  - size: Number - (Optional, default current system font size) text height in screen units (To find text width use getTextWidth)\n  - offsetX: Number - (Optional, default 0) x offset in screen units. > 0 offset right, < 0 offset left\n  - offsetY: Number - (Optional, default 0) y offset in screen units. > 0 offset down, < 0 offset up\n  - color: Color (Optional, default White) text color\n  - shadow: Boolean (Optional, default false) true to outline, false no shadow\n- @progress: Array - (Optional, default []) progress bar in format [width, height, offsetX, offsetY, colorFG, colorBG]:\n  - width: Number - width of the progress bar in screen units (width < height - vertical bar)\n  - height: Number - height of the progress bar in screen units (height <= width - horizontal bar)\n  - offsetX: Number - (Optional, default 0) x offset\n  - offsetY: Number - (Optional, default 0) y offset\n  - colorFG: Color - (Optional, default White) forground color\n  - colorBG: Color - (Optional, default Grey) background color\n- @progressValue: Number - (Optional, default -1) progress bar progress in 0...1 range. -1 - progress bar is not drawn"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"icon","types":["HashMap"]}}],"examples":[{"text":"Icon and text:\n\n```sqf\naddMissionEventHandler [\"Draw3D\", {\n    drawIcon3D [\"targetIcon.paa\", [1, 1, 1, 1], ASLToAGL getPosASLVisual cursorTarget, 1, 1, 45, \"Target\", 1, 0.05, \"TahomaB\"];\n}];\n```","code":["addMissionEventHandler [\"Draw3D\", {\n\tdrawIcon3D [\"targetIcon.paa\", [1, 1, 1, 1], ASLToAGL getPosASLVisual cursorTarget, 1, 1, 45, \"Target\", 1, 0.05, \"TahomaB\"];\n}];"]},{"text":"Just text:\n\n```sqf\naddMissionEventHandler [\"Draw3D\", {\n    drawIcon3D [\"\", [1, 0, 0, 1], ASLToAGL getPosASLVisual cursorTarget, 0, 0, 0, \"Target\", 1, 0.05, \"PuristaMedium\"];\n}];\n```","code":["addMissionEventHandler [\"Draw3D\", {\n\tdrawIcon3D [\"\", [1, 0, 0, 1], ASLToAGL getPosASLVisual cursorTarget, 0, 0, 0, \"Target\", 1, 0.05, \"PuristaMedium\"];\n}];"]},{"text":"```sqf\niconPos = player getPos [10, 0] vectorAdd [0,0,2];\naddMissionEventHandler [\"draw3D\",\n{\n    drawIcon3D\n    [\n        \"\\a3\\ui_f\\data\\IGUI\\Cfg\\Radar\\radar_ca.paa\",\n        [0, 0, 1, 1],\n        iconPos,\n        5,\n        5,\n        getDirVisual player,\n        \"COMPASS\",\n        0,\n        0.3,\n        \"PuristaMedium\",\n        \"center\",\n        true\n    ];\n}];\n```","code":["iconPos = player getPos [10, 0] vectorAdd [0,0,2];\naddMissionEventHandler [\"draw3D\",\n{\n\tdrawIcon3D\n\t[\n\t\t\"\\a3\\ui_f\\data\\IGUI\\Cfg\\Radar\\radar_ca.paa\",\n\t\t[0, 0, 1, 1],\n\t\ticonPos,\n\t\t5,\n\t\t5,\n\t\tgetDirVisual player,\n\t\t\"COMPASS\",\n\t\t0,\n\t\t0.3,\n\t\t\"PuristaMedium\",\n\t\t\"center\",\n\t\ttrue\n\t];\n}];"]},{"text":"Since Arma 3 v2.04\n\n```sqf\npos = player getPos [10, 0] vectorAdd [0,0,2];\naddMissionEventHandler [\"draw3D\",\n{\n    _k = 10 / (player distance pos);\n    drawIcon3D\n    [\n        \"\\a3\\ui_f\\data\\IGUI\\Cfg\\Radar\\radar_ca.paa\",\n        [1, 0, 0, 1],\n        pos,\n        1 * _k,\n        1 * _k,\n        0,\n        name player,\n        0,\n        0.04 * _k,\n        \"RobotoCondensed\",\n        \"right\",\n        true,\n        0.005 * _k,\n        -0.035 * _k\n    ];\n}];\n```","code":["pos = player getPos [10, 0] vectorAdd [0,0,2];\naddMissionEventHandler [\"draw3D\",\n{\n\t_k = 10 / (player distance pos);\n\tdrawIcon3D\n\t[\n\t\t\"\\a3\\ui_f\\data\\IGUI\\Cfg\\Radar\\radar_ca.paa\",\n\t\t[1, 0, 0, 1],\n\t\tpos,\n\t\t1 * _k,\n\t\t1 * _k,\n\t\t0,\n\t\tname player,\n\t\t0,\n\t\t0.04 * _k,\n\t\t\"RobotoCondensed\",\n\t\t\"right\",\n\t\ttrue,\n\t\t0.005 * _k,\n\t\t-0.035 * _k\n\t];\n}];"]},{"text":"Since Arma 3 v2.22\n\n```sqf\nremoveAllMissionEventHandlers \"Draw3D\"; \ndeleteVehicle flagA; \nflagA = createVehicle [\"Flag_AAF_F\", position player, [], 0, \"NONE\"]; \nicon = createHashMapFromArray \n[ \n    [\"@position\", [flagA, 5]], \n    [\"@texture\", \"\\A3\\Data_F\\Flags\\Flag_AAF_CO.paa\"], \n    [\"@texts\", [[\"Sector Alpha\", 0.025, 0, 0.05, [1,1,0,1]]]], \n    [\"@size\", 0.05], \n    [\"@drawArrows\", true], \n    [\"@arrowText\", [\"A\", 0.04, 0.5, 0.3, [1,1,0,1]]],\n    [\"@arrowSize\", 0.06], \n    [\"@fade\", [10, 100]], \n    [\"@arrowColor\", [0,1,0,1]], \n    [\"@progress\", [0.005, 0.05, -0.01, 0, [0.8,0.8,0,1], [0,0.6,0,0.6]]], \n    [\"@progressValue\", 0.67] \n]; \naddMissionEventHandler [\"Draw3D\", {drawIcon3D icon}];\n```","code":["removeAllMissionEventHandlers \"Draw3D\"; \ndeleteVehicle flagA; \nflagA = createVehicle [\"Flag_AAF_F\", position player, [], 0, \"NONE\"]; \nicon = createHashMapFromArray \n[ \n\t[\"@position\", [flagA, 5]], \n\t[\"@texture\", \"\\A3\\Data_F\\Flags\\Flag_AAF_CO.paa\"], \n\t[\"@texts\", [[\"Sector Alpha\", 0.025, 0, 0.05, [1,1,0,1]]]], \n\t[\"@size\", 0.05], \n\t[\"@drawArrows\", true], \n\t[\"@arrowText\", [\"A\", 0.04, 0.5, 0.3, [1,1,0,1]]],\n\t[\"@arrowSize\", 0.06], \n\t[\"@fade\", [10, 100]], \n\t[\"@arrowColor\", [0,1,0,1]], \n\t[\"@progress\", [0.005, 0.05, -0.01, 0, [0.8,0.8,0,1], [0,0.6,0,0.6]]], \n\t[\"@progressValue\", 0.67] \n]; \naddMissionEventHandler [\"Draw3D\", {drawIcon3D icon}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawLine3D","getMissionPath","showHUD","cameraEffectEnableHUD"],"notes":[{"user":"Killzone_Kid","date":"2013-08-31T09:51:00Z","text":"As command syntax indicates, this command expects icon position in format PositionAGL meaning that over the land it expects PositionATL and over the sea PositionASLW.\n\nThis command works well with addon textures, however getting it to display mission textures is a bit tricky. Follow [this guide](http://killzonekid.com/arma-scripting-tutorials-mission-root/)."},{"user":"AgentRev","date":"2014-04-19T22:35:00Z","text":"You should rely exclusively on modelToWorldVisual for a moving object's icon position if you want it to accurately stay at the correct height over the sea. It computes faster than ASLToAGL.\n\nWidth, height, and textSize are proportional to the user's interface size, which can optionally be compensated against via `size / (getResolution select 5)`\n\nAdditionally, width and height are inversely proportional to the `fovLeft` and `fovTop` parameters from the user's ArmaProfile, and AFAIK those parameters are not retrievable via scripting.\nFor example, a `fovTop` higher than the default value of 0.75 will make all 3D icons smaller vertically. I'm not sure if this is a bug or by design, however it is definitely annoying to take into account."},{"user":"DreadedEntity","date":"2014-10-23T02:42:00Z","text":"drawIcon3D and BIS_fnc_addStackedEventHandler work well together.\n\nUsing formatting commands with drawIcon3D will not work, instead, they will be added to the string.\n\n```sqf\n[\"uniqueID\", \"onEachFrame\",\n{\n    drawIcon3D [\"myIcon.jpg\", [1,1,1,0.5], getPos player, 1, 1, 0, format [\"%1\\n%2\", \"Dreaded\", \"Entity\"]];\n}] call BIS_fnc_addStackedEventHandler;\n```\n\nShown text will be **Dreaded\\nEntity**. **(A3 1.32.127785)**\n\nThe \"text\" parameter must be a string. You cannot use Structured_Text.\n\n```sqf\n[\"uniqueID\", \"onEachFrame\",\n{\n    drawIcon3D\n    [\n        \"myIcon.jpg\",\n        [1,1,1,0.5],\n        getPos player,\n        1,\n        1,\n        0,\n        parseText format [\"<t size='1.25' font='PuristaLight' color='#ff0000'>%1%2</t>\", Dreaded, Entity]\n    ];\n}] call BIS_fnc_addStackedEventHandler;\n```\n\n**(A3 1.32.127785)**\n\n> [!CAUTION]\n> This information is **obsolete**."},{"user":"PierreMGI","date":"2016-03-22T20:38:00Z","text":"If you want to use this command, on each frame, with plenty of objects or entities to mark, you can manage conditions in order to reduce the number of CPU operations.\nOne of the most demanding CPU resource is probably a DrawIcon3D treatment for these objects/entities because even if not displayed (like for objects behind player), the CPU calculates the icons in the defined radius of your nearEntities / nearestObjects command.\nDon't stay with a simple radius condition (disk selecting entities or nearestObjects) which calculates all, then useless (not displayed), icons!\n\nHere is a way to restrict this command to your screen display:\nin a onEachFramed context:\n\n```sqf\nunitsToDisplay = allUnits;\naddMissionEventHandler [\"EachFrame\", {\n    private _offset = [0,0,0];\n    {\n        private _screenPosition = worldToScreen (_x modelToWorldVisual _offset);\n        if (_screenPosition isEqualTo []) then { continue };\n        // < your drawIcon3D treatment here >\n    } foreach unitsToDisplay\n}];\n```\n\nTested with +100 units, equally spread on a disk. (Note: FPS depend also on environment in map. Choose a \"desert\" for that)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"drawLaser","operator":null,"title":"drawLaser","type":"command","url":"https://community.bistudio.com/wiki/drawLaser","revid":377735,"updated":"2026-01-03T00:22:18Z","groups":["Interaction","Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Draws a laserbeam and a lightpoint at the impact location of the laser.\n\nThis command has to be executed every frame - see Arma 3: Mission Event Handlers#Draw3D.\n\nLasers drawn with this command are subject to the same limitations as weapon attachment lasers. These limitations are defined in the `CfgIRLaserSettings` config class.","syntaxes":[{"syntax":"drawLaser [position, direction, beamColor, dotColor, dotSize, beamThickness, beamMaxLength, isIR]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"PositionASL","optional":false,"default":null,"description":"the laser's origin position","types":["PositionASL"],"since":null,"text":"position: PositionASL - the laser's origin position"},{"name":"direction","type":"Array of Vector3D","optional":false,"default":null,"description":"the laser's direction vector","types":["Array","Vector3D"],"since":null,"text":"direction: Array of Vector3D - the laser's direction vector"},{"name":"beamColor","type":"Color (RGB)","optional":false,"default":null,"description":"laser beam color. The values can go way above the usual 0..1 range as they also act as emissivity brightness","types":["Color"],"since":null,"text":"beamColor: Color (RGB) - laser beam color. The values can go way above the usual 0..1 range as they also act as emissivity brightness"},{"name":"dotColor","type":"Color (RGB) or Empty Array","optional":false,"default":null,"description":"impact dot color. Set to `[]` to use the same value as *beamColor*.","types":["Color","Array"],"since":null,"text":"dotColor: Color (RGB) or Empty Array - impact dot color. Set to `[]` to use the same value as *beamColor*."},{"name":"dotSize","type":"Number","optional":false,"default":null,"description":"impact dot size; if set to 0 the impact dot will not render","types":["Number"],"since":null,"text":"dotSize: Number - impact dot size; if set to 0 the impact dot will not render"},{"name":"beamThickness","type":"Number","optional":false,"default":null,"description":"laser beam's thickness scale; if set to 0, the beam will not render","types":["Number"],"since":null,"text":"beamThickness: Number - laser beam's thickness scale; if set to 0, the beam will not render"},{"name":"beamMaxLength","type":"Number","optional":true,"default":"-1","description":"laser beam's maximum length. `-1` means maximum length (defined in `CfgIRLaserSettings`), `0` means no length at all and the command is ignored","types":["Number"],"since":null,"text":"beamMaxLength: Number - (Optional, default -1) laser beam's maximum length. `-1` means maximum length (defined in `CfgIRLaserSettings`), `0` means no length at all and the command is ignored"},{"name":"isIR","type":"Boolean","optional":true,"default":"true","description":"whether the laser and impact dot are only visible with Night Vision / Thermal Imaging","types":["Boolean"],"since":null,"text":"isIR: Boolean - (Optional, default true) whether the laser and impact dot are only visible with Night Vision / Thermal Imaging"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, direction, beamColor, dotColor, dotSize, beamThickness, beamMaxLength, isIR]","types":["Array"]}}],"examples":[{"text":"Give the player a laser eye:\n\n```sqf\naddMissionEventHandler [\"Draw3D\", {\n    drawLaser [\n        eyePos player vectorAdd [0, 0, 0.1],\n        getCameraViewDirection player,\n        [1000, 0, 0], // Bright red\n        [],\n        5,\n        20,\n        -1,\n        false\n    ];\n}];\n```","code":["addMissionEventHandler [\"Draw3D\", {\n\tdrawLaser [\n\t\teyePos player vectorAdd [0, 0, 0.1],\n\t\tgetCameraViewDirection player,\n\t\t[1000, 0, 0], // Bright red\n\t\t[],\n\t\t5,\n\t\t20,\n\t\t-1,\n\t\tfalse\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawIcon3D","drawLine3D"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Lights","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"drawLine","operator":null,"title":"drawLine","type":"command","url":"https://community.bistudio.com/wiki/drawLine","revid":377558,"updated":"2026-01-02T06:55:00Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draw a line on the map. Can decrease framerate!","syntaxes":[{"syntax":"map drawLine [from, to, color, width]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"from","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"from: Object or Position2D or Position3D"},{"name":"to","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"to: Object or Position2D or Position3D"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"},{"name":"width","type":"Number","optional":true,"default":"3","description":null,"types":["Number"],"since":"arma3 2.18","text":"width: Number - (Optional, default 3)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[from, to, color, width]","types":["Array"]}}],"examples":[{"text":"```sqf\n(findDisplay 12 displayCtrl 51) ctrlAddEventHandler [\"Draw\",\n    \"(_this select 0) drawLine [\n        player,\n        [0,0,0],\n        [0,0,1,1]\n    ];\"\n];\n```\n\nArma 3 v2.02 toString version:\n\n```sqf\n(findDisplay 12 displayCtrl 51) ctrlAddEventHandler [\"Draw\", toString {\n    (_this select 0) drawLine [\n        player,\n        [0,0,0],\n        [0,0,1,1] // blue\n    ];\n}];\n```","code":["(findDisplay 12 displayCtrl 51) ctrlAddEventHandler [\"Draw\",\n\t\"(_this select 0) drawLine [\n\t\tplayer,\n\t\t[0,0,0],\n\t\t[0,0,1,1]\n\t];\"\n];","(findDisplay 12 displayCtrl 51) ctrlAddEventHandler [\"Draw\", toString {\n\t(_this select 0) drawLine [\n\t\tplayer,\n\t\t[0,0,0],\n\t\t[0,0,1,1] // blue\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawEllipse","drawIcon","drawRectangle","drawPolygon","drawTriangle","drawXPolygon"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawLine3D","operator":null,"title":"drawLine3D","type":"command","url":"https://community.bistudio.com/wiki/drawLine3D","revid":377395,"updated":"2026-01-02T06:44:42Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Draws a line of a given colour between two 3D positions in the current frame. To be used mostly in a \"Draw3D\" mission event handler.","syntaxes":[{"syntax":"drawLine3D [start, end, color, width]","since":null,"effect":null,"exec":null,"params":[{"name":"start","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"start: PositionAGL"},{"name":"end","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"end: PositionAGL"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"},{"name":"width","type":"Number","optional":true,"default":"3","description":null,"types":["Number"],"since":"arma3 2.18","text":"width: Number - (Optional, default 3)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[start, end, color, width]","types":["Array"]}}],"examples":[{"text":"```sqf\nonEachFrame {\n    drawLine3D [getPos player, getPos cursorTarget, [1,1,1,1]];\n};\n```","code":["onEachFrame {\n\tdrawLine3D [getPos player, getPos cursorTarget, [1,1,1,1]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawIcon3D","ASLToAGL"],"notes":[{"user":"Killzone_Kid","date":"2013-08-31T09:27:00Z","text":"As the command syntax indicates, this command expects starting and ending position in format PositionAGL meaning that over the land it expects PositionATL and over the sea PositionASLW. Use additional ASLToAGL and AGLToASL commands wherever is necessary.\n\n```sqf\naddMissionEventHandler [\"Draw3D\", {\n    drawLine3D [ASLToAGL eyePos soldier1, ASLToAGL eyePos soldier2, [1,0,0,1]];\n}];\n```"},{"user":"Waffle SS.","date":"2015-02-18T02:10:00Z","text":"Visible through fog and past draw distance."},{"user":"fusselwurm","date":"2021-11-25T21:37:10Z","text":"Caveat: lines invisible through MH-9 helicopter windows, see https://feedback.bistudio.com/T66225"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"drawLink","operator":null,"title":"drawLink","type":"command","url":"https://community.bistudio.com/wiki/drawLink","revid":363261,"updated":"2024-03-26T10:51:33Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The editor will draw a line between the two specified editor objects. Line type can be LINE or ARROW.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map drawLink [from,to,param type,line type,color]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[from,to,param type,line type,color]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[from,to,param type,line type,color]: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[from,to,param type,line type,color]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawLocation","operator":null,"title":"drawLocation","type":"command","url":"https://community.bistudio.com/wiki/drawLocation","revid":282090,"updated":"2021-06-16T21:33:04Z","groups":["GUI Control - Map","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Used to draw locations in 2D Editor.","syntaxes":[{"syntax":"control drawLocation location","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawPolygon","operator":null,"title":"drawPolygon","type":"command","url":"https://community.bistudio.com/wiki/drawPolygon","revid":377843,"updated":"2026-01-03T04:35:45Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws given polygon on the given map control with given color. The polygon must consist of at least 3 points. Unlike with other `draw*` commands and due to complexity, this command does not support filling of the polygon with color. Use drawTriangle command to construct and fill polygon shape as a workaround.","syntaxes":[{"syntax":"map drawPolygon [polygon, color]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"polygon","type":"Array of Position3D","optional":false,"default":null,"description":null,"types":["Array","Position3D"],"since":null,"text":"polygon: Array of Position3D"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[polygon, color]","types":["Array"]}}],"examples":[{"text":"```sqf\ntest_polygon = [];\nfor \"_i\" from 1 to 12 do \n{\n    test_polygon pushBack (player getPos [10 + random 100, 360 / _i]);\n};\n\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    params [\"_control\"];\n    _control drawPolygon [test_polygon, [0,0,1,1]];\n}];\n```","code":["test_polygon = [];\nfor \"_i\" from 1 to 12 do \n{\n\ttest_polygon pushBack (player getPos [10 + random 100, 360 / _i]);\n};\n\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n\tparams [\"_control\"];\n\t_control drawPolygon [test_polygon, [0,0,1,1]];\n}];"]},{"text":"Draw a polygon by adjusting the `_radius` and `_numVertices`\n\n```sqf\nvertices = [];\nprivate _numVertices = 2;\nprivate _numVertices = _numVertices max 3;\nprivate _radius = 100;\n\nfor \"_i\" from 1 to _numVertices do\n{\n    vertices pushBack (player getRelPos [_radius, 360 / _numVertices * _i]);\n};\n\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\",\n{\n    params [\"_control\"];\n    _control drawPolygon [vertices, [0,0,1,1]];\n}];\n```","code":["vertices = [];\nprivate _numVertices = 2;\nprivate _numVertices = _numVertices max 3;\nprivate _radius = 100;\n\nfor \"_i\" from 1 to _numVertices do\n{\n\tvertices pushBack (player getRelPos [_radius, 360 / _numVertices * _i]);\n};\n\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\",\n{\n\tparams [\"_control\"];\n\t_control drawPolygon [vertices, [0,0,1,1]];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawEllipse","drawIcon","drawLine","drawRectangle","drawArrow","drawTriangle","inPolygon","drawXPolygon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"drawRectangle","operator":null,"title":"drawRectangle","type":"command","url":"https://community.bistudio.com/wiki/drawRectangle","revid":377559,"updated":"2026-01-02T06:55:02Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws a rectangle on the map.","syntaxes":[{"syntax":"map drawRectangle [centre, halfWidth, halfHeight, angle, color, fill, alignWithMap]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"centre","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":"rectangle's centre","types":["Object","Position2D","Position3D"],"since":null,"text":"centre: Object or Position2D or Position3D - rectangle's centre"},{"name":"halfWidth","type":"Number","optional":false,"default":null,"description":"1/2 width of rectangle in meters","types":["Number"],"since":null,"text":"halfWidth: Number - 1/2 width of rectangle in meters"},{"name":"halfHeight","type":"Number","optional":false,"default":null,"description":"1/2 height of rectangle in meters","types":["Number"],"since":null,"text":"halfHeight: Number - 1/2 height of rectangle in meters"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"angle of rotation in degrees","types":["Number"],"since":null,"text":"angle: Number - angle of rotation in degrees"},{"name":"color","type":"Color (RGBA)","optional":false,"default":null,"description":"line color","types":["Color"],"since":null,"text":"color: Color (RGBA) - line color"},{"name":"fill","type":"String","optional":false,"default":null,"description":"fill texture file or Procedural Textures. Note that the file texture will not rotate with rectangle, use drawIcon for that. If fill texture is not empty, set line color to white `[1,1,1,1]`","types":["String"],"since":null,"text":"fill: String - fill texture file or Procedural Textures. Note that the file texture will not rotate with rectangle, use drawIcon for that. If fill texture is not empty, set line color to white `[1,1,1,1]`"},{"name":"alignWithMap","type":"Boolean","optional":true,"default":"true","description":"when false the shape will not follow map rotation.","types":["Boolean"],"since":"Arma3 2.18","text":"alignWithMap: Boolean - (Optional, default true) - when false the shape will not follow map rotation."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[centre, halfWidth, halfHeight, angle, color, fill, alignWithMap]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl drawRectangle [\n    getPos player,\n    20,\n    20,\n    getDir player,\n    [0,0,1,1],\n    \"\"\n];\n```","code":["_ctrl drawRectangle [\n\tgetPos player,\n\t20,\n\t20,\n\tgetDir player,\n\t[0,0,1,1],\n\t\"\"\n];"]},{"text":"```sqf\n_ctrl drawRectangle [\n    player,\n    10,\n    20,\n    getDir player,\n    [1,1,1,1],\n    \"#(rgb,8,8,3)color(1,0,0,1)\"\n];\n```","code":["_ctrl drawRectangle [\n\tplayer,\n\t10,\n\t20,\n\tgetDir player,\n\t[1,1,1,1],\n\t\"#(rgb,8,8,3)color(1,0,0,1)\"\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawEllipse","drawIcon","drawLine","drawPolygon","drawTriangle","drawXPolygon"],"notes":[{"user":"Waffle SS.","date":"2014-03-23T00:21:00Z","text":"Map example:\n\n```sqf\n(findDisplay 12 displayCtrl 51) ctrlAddEventHandler [\"Draw\",{\n    (_this select 0) drawRectangle [\n        getPos player,\n        20,\n        20,\n        getDir player,\n        [0,0,1,1],\n        \"\"\n    ];\n}];\n```\n\nBe careful when using this command. Unlike map markers, the draw commands can decrease your framerate."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drawTriangle","operator":null,"title":"drawTriangle","type":"command","url":"https://community.bistudio.com/wiki/drawTriangle","revid":377356,"updated":"2026-01-02T06:40:21Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.76"}],"since":{"game":"arma3","name":"Arma 3","version":"1.76"},"arma3_since":"1.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws one to multiple triangles on the map.\n\n> [!NOTE]\n> When `fill` param is absent or is an empty string \"\", the triangle is drawn with lines of the color set in `color` param.\n> In order to draw color-filled triangle of the same color as `color` param, set `fill` param to opaque white procedural texture`\"#(rgb,1,1,1)color(1,1,1,1)\"`.","syntaxes":[{"syntax":"map drawTriangle [vertices, color, fill]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"map: Control - map control"},{"name":"vertices","type":"Array of Positions","optional":false,"default":null,"description":"triangle(s) vertices in multiple of 3, see #Example 1 - if Position3D is provided for a vertex, its z value is ignored","types":["Array","Position"],"since":null,"text":"vertices: Array of Positions - triangle(s) vertices in multiple of 3, see #Example 1 - if Position3D is provided for a vertex, its z value is ignored"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"},{"name":"fill","type":"String","optional":true,"default":"`\"\"`","description":"fill texture file or Procedural Textures. See note in description for more info.","types":["String"],"since":null,"text":"fill: String - (Optional, default `\"\"`) fill texture file or Procedural Textures. See note in description for more info."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[vertices, color, fill]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    _this select 0 drawTriangle \n    [\n        [\n            // triangle 1 start\n            player getRelPos [100, 0],\n            player getRelPos [100, -135],\n            player getRelPos [100, 135]\n            // triangle 1 end\n        ],\n        [1,0,0,0.5],\n        \"#(rgb,1,1,1)color(1,1,1,1)\"        \n    ];\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n\t_this select 0 drawTriangle \n\t[\n\t\t[\n\t\t\t// triangle 1 start\n\t\t\tplayer getRelPos [100, 0],\n\t\t\tplayer getRelPos [100, -135],\n\t\t\tplayer getRelPos [100, 135]\n\t\t\t// triangle 1 end\n\t\t],\n\t\t[1,0,0,0.5],\n\t\t\"#(rgb,1,1,1)color(1,1,1,1)\"\t\t\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawEllipse","drawIcon","drawLine","drawPolygon","drawRectangle","drawXPolygon"],"notes":[{"user":"Killzone_Kid","date":"2017-07-16T15:36:00Z","text":"Example [YouTube video](https://www.youtube.com/watch?v=gSiuLdUeq0M)\n\n```sqf\nctrl = findDisplay 12 displayCtrl 51;\n_ctrl setVariable [\"data\", [1, \"#(rgb,1,1,1)color(1,1,1,1)\", 1000, position player, \n{\n    params [\"_p\", \"_r\", \"_a\", \"_sr\", \"_ba\"];\n    _sr = _r * 0.382;\n    _pb = _p getPos [_sr, _a + 180];\n    [\n        _p getPos [_r, _a], _p getPos [_sr, _a + 36], _p getPos [_sr, _a - 36],\n        _pb, _p getPos [_r, _a - 72], _p getPos [_r, _a + 72],\n        _p getPos [_r, _a - 144], _p getPos [_sr, _a - 108], _pb,\n        _p getPos [_r, _a + 144], _p getPos [_sr, _a + 108], _pb\n    ]\n}]];\n\n_ctrl ctrlRemoveAllEventHandlers \"Draw\";\n_ctrl ctrlAddEventHandler [\"Draw\", \n{\n    _map = _this select 0;\n    _data = _map getVariable \"data\";\n    _data params [\"_i\", \"_fill\", \"_dist\", \"_pos\", \"_fn\"];\n    _data set [0, _i + 1];\n    _size = _i % _dist;\n    if (_size == 0) then \n    {\n        _data set [0, 1];\n        _data set [1, [\"#(rgb,1,1,1)color(1,1,1,1)\", \"\"] select (random 1 < 0.3)];\n        _data set [2, 250 + round random 750];\n    };\n    _alpha = linearConversion [_dist, 0, _dist - _size, 1, 0];\n    _map drawEllipse [_pos, _size * 2, _size * 2, 0, [0,0,1,_alpha], _fill];\n    _map drawTriangle [[_pos getPos [_size, -_size], _size, _size] call _fn, [1,0,0,_alpha], _fill];\n    _map drawTriangle [[_pos getPos [_size, -_size + 120], _size, _size] call _fn, [0,1,0,_alpha], _fill];\n    _map drawTriangle [[_pos getPos [_size, -_size - 120], _size, _size] call _fn, [1,1,0,_alpha], _fill];\n}];\n\nopenMap true;\n```"},{"user":"Killzone_Kid","date":"2018-11-13T21:05:00Z","text":"Drawing holes ([video](https://www.youtube.com/watch?v=XZRtXsBFLAg)):\n\n```sqf\nt = time;\ni = 0;\ntex = \"#(rgb,1,1,1)color(1,1,1,0.5)\";\ncol = [1,1,1,1];\n\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    if (time > t) then\n    {\n        col = [random 1, random 1, random 1, 1];\n        tex = [    \n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\vertical_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\bdiagonal_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\cross_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\diaggrid_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\fdiagonal_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\grid_ca.paa\",\n            \"\\A3\\ui_f\\data\\map\\markerbrushes\\horizontal_ca.paa\",\n            \"#(rgb,1,1,1)color(1,1,1,0.5)\"\n        ] \n        select (i % 8);\n        \n        t = time + 0.5;\n        i = i + 1;\n    };\n    \n    _this select 0 drawTriangle \n    [\n        [\n            [0,0],[100,500],[400,400],\n            [0,0],[400,400],[500,100],\n            [0,0],[500,100],[1000,0],\n            [1000,0],[500,100],[600,400],\n            [1000,0],[600,400],[900,500],\n            [1000,0],[900,500],[1000,1000],\n            [1000,1000],[900,500],[600,600],\n            [1000,1000],[600,600],[500,900],\n            [1000,1000],[500,900],[0,1000],\n            [0,1000],[500,900],[400,600],\n            [0,1000],[400,600],[100,500],\n            [0,1000],[100,500],[0,0]\n        ],\n        col, \n        tex\n    ];\n    \n    _this select 0 drawPolygon [[[0,0,0],[0,1000,0],[1000,1000,0],[1000,0,0]], col];\n    _this select 0 drawPolygon [[[100,500,0],[400,600,0],[500,900,0],[600,600,0],[900,500,0],[600,400,0],[500,100,0],[400,400,0]], col];\n}];\n\nopenMap true;\nmapAnimAdd [0, 0.15, [500,500,0]];\nmapAnimCommit;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 1.76","Scripting Commands"]},{"name":"drawXPolygon","operator":null,"title":"drawXPolygon","type":"command","url":"https://community.bistudio.com/wiki/drawXPolygon","revid":377556,"updated":"2026-01-02T06:54:57Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Draws an N sided polygon on the map.","syntaxes":[{"syntax":"map drawXPolygon [n, centre, a, b, angle, color, fill, alignWithMap]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"n","type":"Number","optional":false,"default":null,"description":"number of sides 3..720","types":["Number"],"since":null,"text":"n: Number - number of sides 3..720"},{"name":"centre","type":"Object or Position2D, Position3D","optional":false,"default":null,"description":"ellipse's centre","types":["Object","Position2D","Position3D"],"since":null,"text":"centre: Object or Position2D, Position3D - ellipse's centre"},{"name":"a","type":"Number","optional":false,"default":null,"description":"horizontal (x) radius","types":["Number"],"since":null,"text":"a: Number - horizontal (x) radius"},{"name":"b","type":"Number","optional":false,"default":null,"description":"vertical (y) radius","types":["Number"],"since":null,"text":"b: Number - vertical (y) radius"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"angle of rotation in degrees","types":["Number"],"since":null,"text":"angle: Number - angle of rotation in degrees"},{"name":"color","type":"Color (RGBA)","optional":false,"default":null,"description":"line color","types":["Color"],"since":null,"text":"color: Color (RGBA) - line color"},{"name":"fill","type":"String","optional":false,"default":null,"description":"fill texture file or Procedural Textures. Note that the file texture will not rotate with polygon, use drawIcon for that. If fill texture is not empty, set line color to white [1,1,1,1]","types":["String"],"since":null,"text":"fill: String - fill texture file or Procedural Textures. Note that the file texture will not rotate with polygon, use drawIcon for that. If fill texture is not empty, set line color to white [1,1,1,1]"},{"name":"alignWithMap","type":"Boolean","optional":true,"default":"true","description":"when false the shape will not follow map rotation.","types":["Boolean"],"since":null,"text":"alignWithMap: Boolean - (Optional, default true) - when false the shape will not follow map rotation."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[n, centre, a, b, angle, color, fill, alignWithMap]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n    _this select 0 drawXPolygon [\n        5, player, 50, 10, 0, [1, 0, 0, 1], \"\"\n    ];\n    _this select 0 drawXPolygon [\n        3, player, 10, 50, 0, [1, 1, 1, 1], \"#(rgb,8,8,3)color(1,0.6,0,1)\"\n    ];\n    _this select 0 drawXPolygon [\n        12, player, 10, 10, 90, [0, 0, 1, 1], \"\"\n    ];\n}];\n```","code":["findDisplay 12 displayCtrl 51 ctrlAddEventHandler [\"Draw\", \n{\n\t_this select 0 drawXPolygon [\n\t\t5, player, 50, 10, 0, [1, 0, 0, 1], \"\"\n\t];\n\t_this select 0 drawXPolygon [\n\t\t3, player, 10, 50, 0, [1, 1, 1, 1], \"#(rgb,8,8,3)color(1,0.6,0,1)\"\n\t];\n\t_this select 0 drawXPolygon [\n\t\t12, player, 10, 10, 90, [0, 0, 1, 1], \"\"\n\t];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drawArrow","drawIcon","drawLine","drawRectangle","drawPolygon","drawTriangle","drawEllipse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 3 version 2.20","Scripting Commands"]},{"name":"driver","operator":null,"title":"driver","type":"command","url":"https://community.bistudio.com/wiki/driver","revid":308923,"updated":"2022-04-18T18:03:59Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the driver of a vehicle.","syntaxes":[{"syntax":"driver vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":"The unit sitting in the driver place is returned. If vehicle is not a vehicle but a person, the person is returned.","text":"Object -\nThe unit sitting in the driver place is returned. If vehicle is not a vehicle but a person, the person is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n(driver _tank) action [\"getout\", _tank];\n```","code":["(driver _tank) action [\"getout\", _tank];"]},{"text":"```sqf\ndriver vehicle player isEqualTo player // check if player is driver of current vehicle\n```","code":["driver vehicle player isEqualTo player // check if player is driver of current vehicle"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commander","gunner","crew","currentPilot"],"notes":[{"user":"Hardrock","date":"2006-08-03T14:32:00Z","text":"*Notes from before the conversion:*\n\nIt is also possible to find the driver of a vehicle by placing a **D** after the name of the vehicle so *Tank1D* and ***driver** Tank1* both refer to the same unit, providing the original driver has not got out of the tank.\n\nThe difference between the two is *Tank1D* is always the unit that was driver of the tank when the mission started, whilst ***driver** Tank1* is the driver which is now there."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"drop","operator":null,"title":"drop","type":"command","url":"https://community.bistudio.com/wiki/drop","revid":377588,"updated":"2026-01-02T06:57:08Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Creates a particle effect.\nThis command is used to create smoke, fire and similar effects.\nThe particles are single polygons with single textures that always face the player.\nThey can be set to dynamically change their position, size, direction, can be set to different weights and to be more or less dependent on the wind.","syntaxes":[{"syntax":"drop parameters","since":null,"effect":null,"exec":null,"params":[{"name":"parameters","type":"ParticleArray","optional":false,"default":null,"description":null,"types":["ParticleArray"],"since":null,"text":"parameters: ParticleArray"}],"returns":{"type":"Nothing, since Arma 3 v2.20 Object","types":["Nothing","Object"],"description":null,"text":"Nothing, since Arma 3 v2.20 Object"},"form":"unary","operator":null,"left":null,"right":{"text":"parameters","types":["ParticleArray"]}}],"examples":[{"text":"```sqf\ndrop [\"cl_basic\", \"\", \"Billboard\", 1, 1,\n    [-3.5 * (sin (direction xural)), -3.5 * (cos (direction xural)), 0],\n    [random 0.1, random 0.1, random 0.5],\n    1, 0.005, 0.0042, 0.7, [0.3,3],\n    [[0.5,0.5,0.5,0], [0.7,0.7,0.7,0.5], [0.9,0.9,0.9,0]],\n    [0,1,0,1,0,1],\n    0.2, 0.2, \"\", \"\", xural];\n```","code":["drop [\"cl_basic\", \"\", \"Billboard\", 1, 1,\n\t[-3.5 * (sin (direction xural)), -3.5 * (cos (direction xural)), 0],\n\t[random 0.1, random 0.1, random 0.5],\n\t1, 0.005, 0.0042, 0.7, [0.3,3],\n\t[[0.5,0.5,0.5,0], [0.7,0.7,0.7,0.5], [0.9,0.9,0.9,0]],\n\t[0,1,0,1,0,1],\n\t0.2, 0.2, \"\", \"\", xural];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ParticleArray","setParticleCircle","setParticleParams","setParticleRandom","ParticleTemplates","setParticleClass","particlesQuality","setParticleFire"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Particles","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands"]},{"name":"dynamicSimulationDistance","operator":null,"title":"dynamicSimulationDistance","type":"command","url":"https://community.bistudio.com/wiki/dynamicSimulationDistance","revid":348424,"updated":"2023-11-08T13:00:09Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setDynamicSimulationDistance.","syntaxes":[{"syntax":"dynamicSimulationDistance category","since":null,"effect":null,"exec":null,"params":[{"name":"category","type":"String","optional":false,"default":null,"description":"can be:\n- `\"Group\"` - Infantry units and groups\n- `\"Vehicle\"` - Vehicles with crew\n- `\"EmptyVehicle\"` - All vehicles without crew\n- `\"Prop\"` - Static objects","types":["String"],"since":null,"text":"category: String - can be:\n- `\"Group\"` - Infantry units and groups\n- `\"Vehicle\"` - Vehicles with crew\n- `\"EmptyVehicle\"` - All vehicles without crew\n- `\"Prop\"` - Static objects"}],"returns":{"type":"Number","types":["Number"],"description":"activation distance","text":"Number - activation distance"},"form":"unary","operator":null,"left":null,"right":{"text":"category","types":["String"]}}],"examples":[{"text":"```sqf\nhint str dynamicSimulationDistance \"Prop\";\n```","code":["hint str dynamicSimulationDistance \"Prop\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Dynamic Simulation","setDynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"dynamicSimulationDistanceCoef","operator":null,"title":"dynamicSimulationDistanceCoef","type":"command","url":"https://community.bistudio.com/wiki/dynamicSimulationDistanceCoef","revid":319026,"updated":"2022-05-13T09:22:12Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setDynamicSimulationDistanceCoef","syntaxes":[{"syntax":"dynamicSimulationDistanceCoef class","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"see setDynamicSimulationDistanceCoef","types":["String"],"since":null,"text":"class: String - see setDynamicSimulationDistanceCoef"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"class","types":["String"]}}],"examples":[{"text":"```sqf\nhint str dynamicSimulationDistanceCoef \"IsMoving\";\n```","code":["hint str dynamicSimulationDistanceCoef \"IsMoving\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"dynamicSimulationEnabled","operator":null,"title":"dynamicSimulationEnabled","type":"command","url":"https://community.bistudio.com/wiki/dynamicSimulationEnabled","revid":318879,"updated":"2022-05-13T09:21:58Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for enableDynamicSimulation.","syntaxes":[{"syntax":"dynamicSimulationEnabled object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"object: Object or Group"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object","Group"]}}],"examples":[{"text":"```sqf\nhint str dynamicSimulationEnabled _myObject;\n```","code":["hint str dynamicSimulationEnabled _myObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"dynamicSimulationSystemEnabled","operator":null,"title":"dynamicSimulationSystemEnabled","type":"command","url":"https://community.bistudio.com/wiki/dynamicSimulationSystemEnabled","revid":373714,"updated":"2025-06-21T11:20:59Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"A getter for enableDynamicSimulationSystem","syntaxes":[{"syntax":"dynamicSimulationSystemEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str dynamicSimulationSystemEnabled;\n```","code":["hint str dynamicSimulationSystemEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"east","operator":null,"title":"east","type":"command","url":"https://community.bistudio.com/wiki/east","revid":329500,"updated":"2022-07-29T13:31:38Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the eastern side.","syntaxes":[{"syntax":"east","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"SQS:\n\n```sqs\n? side _unit == east : hint \"This is an eastern unit!\"\n```","code":["? side _unit == east : hint \"This is an eastern unit!\""]},{"text":"SQF:\n\n```sqf\nif (side _unit == east) then\n{\n    hint \"This is an eastern unit!\";\n};\n```","code":["if (side _unit == east) then\n{\n\thint \"This is an eastern unit!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["opfor"],"see_also":["side","west","resistance","civilian","sideEmpty","sideAmbientLife"],"notes":[{"user":"Maruk","date":"2007-04-17T10:45:00Z","text":"In Armed Assault the terms OPFOR, BLUFOR, Independents and Civilians are used in the front end UI."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"echo","operator":null,"title":"echo","type":"command","url":"https://community.bistudio.com/wiki/echo","revid":321915,"updated":"2022-05-22T12:29:47Z","groups":["Diagnostic","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sends any text into the debugger console or the logfile. This command is only **present in internal version**  not in the retail version. Use diag_log instead!","syntaxes":[{"syntax":"echo text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\necho \"Text in logfile\";\n```","code":["echo \"Text in logfile\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Diagnostic","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"edit3DENMissionAttributes","operator":null,"title":"edit3DENMissionAttributes","type":"command","url":"https://community.bistudio.com/wiki/edit3DENMissionAttributes","revid":363773,"updated":"2024-04-19T09:32:17Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Open a window with scenario attribute in given section.","syntaxes":[{"syntax":"edit3DENMissionAttributes section","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"String","optional":false,"default":null,"description":"attribute section from `configFile >> \"Cfg3DEN\" >> \"Mission\"`","types":["String"],"since":null,"text":"section: String - attribute section from `configFile >> \"Cfg3DEN\" >> \"Mission\"`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"section","types":["String"]}}],"examples":[{"text":"```sqf\nedit3DENMissionAttributes \"Multiplayer\";\n```","code":["edit3DENMissionAttributes \"Multiplayer\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENAttribute","set3DENAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"editObject","operator":null,"title":"editObject","type":"command","url":"https://community.bistudio.com/wiki/editObject","revid":363246,"updated":"2024-03-26T10:51:21Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Show the edit object dialog for the given object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map editObject object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"editorSetEventHandler","operator":null,"title":"editorSetEventHandler","type":"command","url":"https://community.bistudio.com/wiki/editorSetEventHandler","revid":363579,"updated":"2024-04-07T14:46:04Z","groups":["Game 2 Editor","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets given event handler of given editor.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map editorSetEventHandler [handler name, function]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"handler name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"handler name: String"},{"name":"function","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"function: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[handler name, function]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map editorSetEventHandler [\"SelectObject\", \"\"];\n```","code":["_map editorSetEventHandler [\"SelectObject\", \"\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"effectiveCommander","operator":null,"title":"effectiveCommander","type":"command","url":"https://community.bistudio.com/wiki/effectiveCommander","revid":369524,"updated":"2024-09-15T17:56:50Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the effective commander of the vehicle. Effective commander is the player whom driver AI will listen to.\nSo if in a tank there is a gunner and a commander and AI driver, if the effectiveCommander is gunner, then gunner pressing <kbd>W</kbd> <kbd>A</kbd> <kbd>S</kbd> <kbd>D</kbd> will give AI orders to move.\nIf gunner jumps out and then enters a tank again, the effectiveCommander role most likely has changed to commander that remained in tank. Also the assignment seems to work on first come first served basis.","syntaxes":[{"syntax":"effectiveCommander vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":"commander unit","text":"Object - commander unit"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_unit = driver tank;\n_effectiveCommander = effectiveCommander _unit;                // returns the tank driver itself\n_effectiveCommander = effectiveCommander tank;                // returns the effective commander (commander or gunner or driver)\n_effectiveCommander = effectiveCommander vehicle _unit;        // identical to the one above - use [[vehicle]] if only the unit is known\n```","code":["_unit = driver tank;\n_effectiveCommander = effectiveCommander _unit;\t\t\t\t// returns the tank driver itself\n_effectiveCommander = effectiveCommander tank;\t\t\t\t// returns the effective commander (commander or gunner or driver)\n_effectiveCommander = effectiveCommander vehicle _unit;\t\t// identical to the one above - use [[vehicle]] if only the unit is known"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setEffectiveCommander","commander","driver","gunner","currentPilot","vehicleMoveInfo"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"elevatePeriscope","operator":null,"title":"elevatePeriscope","type":"command","url":"https://community.bistudio.com/wiki/elevatePeriscope","revid":377904,"updated":"2026-01-05T18:01:10Z","groups":["Object Manipulation","Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Elevates periscope of a vehicle. Vehicles in Arma 3 which are compatible with this tech are Strider, remote laser designators, the robot arm on Eddie, etc.\nPlease note that SDV submarine has a different periscope, which is just an animated selection and could be raised and lowered with animate command.\n\n> [!NOTE]\n> - a user can immediately override any elevation in progress by using assigned keyboard keys. To block user input see the *blockUserInput* parameter.\n> - a PeriscopeElevationChanged entity event handler is also provided.","syntaxes":[{"syntax":"vehicle elevatePeriscope [turret, elevation, speed, blockUserInput]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with periscope tech","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with periscope tech"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":"turret on which periscope is located","types":["Turret Path"],"since":null,"text":"turret: Turret Path - turret on which periscope is located"},{"name":"elevation","type":"Number","optional":false,"default":null,"description":"elevation range 0..1","types":["Number"],"since":null,"text":"elevation: Number - elevation range 0..1"},{"name":"speed","type":"Number or Boolean","optional":true,"default":"-1","description":"config anim speed multiplier, 2 - twice as fast, 0.5 - twice as slow, etc. -1 - default config speed. If true is used as param, the change in elevation is almost instant","types":["Number","Boolean"],"since":null,"text":"speed: Number or Boolean - (Optional, default -1) config anim speed multiplier, 2 - twice as fast, 0.5 - twice as slow, etc. -1 - default config speed. If true is used as param, the change in elevation is almost instant"},{"name":"blockUserInput","type":"Boolean","optional":true,"default":"false","description":"true to disable user ability to control periscope with keyboard. The change is persistent unless set to false again","types":["Boolean"],"since":null,"text":"blockUserInput: Boolean - (Optional, default false) true to disable user ability to control periscope with keyboard. The change is persistent unless set to false again"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turret, elevation, speed, blockUserInput]","types":["Array"]}}],"examples":[{"text":"```sqf\n_eddie elevatePeriscope [[0], 0.75, 0.1];\n```","code":["_eddie elevatePeriscope [[0], 0.75, 0.1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["periscopeElevation","animate","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"else","operator":null,"title":"else","type":"command","url":"https://community.bistudio.com/wiki/else","revid":364827,"updated":"2024-06-16T09:33:24Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes else code when if condition returns false.","syntaxes":[{"syntax":"thenCode else elseCode","since":null,"effect":null,"exec":null,"params":[{"name":"thenCode","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"thenCode: Code"},{"name":"elseCode","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"elseCode: Code"}],"returns":{"type":"Array with [thenCode, elseCode]","types":["Array"],"description":"thenCode: Code - elseCode: Code","text":"Array with [thenCode, elseCode]\n- thenCode: Code\n- elseCode: Code"},"form":"binary","operator":null,"left":{"text":"thenCode","types":["Code"]},"right":{"text":"elseCode","types":["Code"]}}],"examples":[{"text":"```sqf\nif (a > b) then { c = 0 } else { c = 1 };\n```","code":["if (a > b) then { c = 0 } else { c = 1 };"]},{"text":"```sqf\nif (a < b) then {\n    hint \"B is greater than A\";\n} else {\n    hint \"A is greater than B\";\n};\n```","code":["if (a < b) then {\n\thint \"B is greater than A\";\n} else {\n\thint \"A is greater than B\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","if","then"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"emptyPositions","operator":null,"title":"emptyPositions","type":"command","url":"https://community.bistudio.com/wiki/emptyPositions","revid":378582,"updated":"2026-05-11T11:45:50Z","groups":["Object Manipulation","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the number of given empty positions in the vehicle.\n\n> [!NOTE]\n> To return the actual units in the vehicle use fullCrew. However if only the number is desired, use emptyPositions because it is faster.","syntaxes":[{"syntax":"vehicle emptyPositions position","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"position","type":"String","optional":false,"default":null,"description":"can be one of:\n- `\"Commander\"`\n- `\"Driver\"`\n- `\"Gunner\"`\n- `\"Cargo\"` - all cargo positions, FFV or not\n- Arma 3 v2.10 `\"\"` - all empty positions\n- Arma 3 v2.10 `\"CargoNoFFV\"` - non-FFV cargo\n- Arma 3 v2.10 `\"CargoFFV\"` - FFV cargo\n- Arma 3 v2.14 `\"Turret\"` - empty turrets (no FFV turrets, they are included in \"CargoFFV\")","types":["String"],"since":null,"text":"position: String - can be one of:\n- `\"Commander\"`\n- `\"Driver\"`\n- `\"Gunner\"`\n- `\"Cargo\"` - all cargo positions, FFV or not\n- Arma 3 v2.10 `\"\"` - all empty positions\n- Arma 3 v2.10 `\"CargoNoFFV\"` - non-FFV cargo\n- Arma 3 v2.10 `\"CargoFFV\"` - FFV cargo\n- Arma 3 v2.14 `\"Turret\"` - empty turrets (no FFV turrets, they are included in \"CargoFFV\")"}],"returns":{"type":"Number","types":["Number"],"description":"the number of available positions ignoring locked positions","text":"Number - the number of available positions ignoring locked positions"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"position","types":["String"]}},{"syntax":"vehicle emptyPositions [position, ignoreLocked]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"position","type":"String","optional":false,"default":null,"description":"see moveInAny. Empty string \"\" returns number of all free positions","types":["String"],"since":null,"text":"position: String - see moveInAny. Empty string \"\" returns number of all free positions"},{"name":"ignoreLocked (Optional)","type":"Boolean","optional":false,"default":null,"description":"true to ignore locked positions. Default: false","types":["Boolean"],"since":null,"text":"ignoreLocked (Optional): Boolean - true to ignore locked positions. Default: false"}],"returns":{"type":"Number","types":["Number"],"description":"the number of available positions ignoring locked positions","text":"Number - the number of available positions ignoring locked positions"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[position, ignoreLocked]","types":["Array"]}}],"examples":[{"text":"```sqf\n_freeCargoAndFFVPositions = vehicle player emptyPositions \"Cargo\";\n```","code":["_freeCargoAndFFVPositions = vehicle player emptyPositions \"Cargo\";"]},{"text":"```sqf\n_freeCargoOnlyPositions = vehicle player emptyPositions \"CargoNoFFV\";\n```","code":["_freeCargoOnlyPositions = vehicle player emptyPositions \"CargoNoFFV\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInDriver","moveInTurret","moveInCommander","moveInGunner","moveInCargo","getCargoIndex","moveInAny"],"notes":[{"user":"DreadedEntity","date":"2022-03-20T00:08:54Z","text":"**emptyPositions** combines both turret and cargo in its output. If you must know the true count of either, you will have to use fullCrew (tested on several vehicles)\n\nI have not found a way to test for copilot in helicopters"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableAI","operator":null,"title":"enableAI","type":"command","url":"https://community.bistudio.com/wiki/enableAI","revid":369964,"updated":"2024-10-22T12:39:51Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enables parts of the AI behavior that was disabled by disableAI.\n\n> [!IMPORTANT]\n> When player switches and leaves behind AI unit, you need to enable \"TeamSwitch\" AI on it `_unit enableAI \"TeamSwitch\";` so that the unit continues with waypoints.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.96 it is possible to return the state of the given AI flag via checkAIFeature or set it using alias command enableAIFeature.","syntaxes":[{"syntax":"unit enableAI skilltype","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skilltype","type":"String","optional":false,"default":null,"description":"see disableAI for possible values.","types":["String"],"since":null,"text":"skilltype: String - see disableAI for possible values."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"skilltype","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne enableAI \"Move\";\n```","code":["_soldierOne enableAI \"Move\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableAI","checkAIFeature","enableAIFeature","vehicleMoveInfo","getUnitState"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableAIFeature","operator":null,"title":"enableAIFeature","type":"command","url":"https://community.bistudio.com/wiki/enableAIFeature","revid":369972,"updated":"2024-10-22T12:51:41Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables/disables given AI feature.","syntaxes":[{"syntax":"feature enableAIFeature enable","since":null,"effect":null,"exec":null,"params":[{"name":"feature","type":"String","optional":false,"default":null,"description":"can be:\n- `\"AwareFormationSoft\"`\n- `\"CombatFormationSoft\"`","types":["String"],"since":null,"text":"feature: String - can be:\n- `\"AwareFormationSoft\"`\n- `\"CombatFormationSoft\"`"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"true to enable, false to disable","types":["Boolean"],"since":null,"text":"enable: Boolean - true to enable, false to disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"feature","types":["String"]},"right":{"text":"enable","types":["Boolean"]}},{"syntax":"unit enableAIFeature [feature, enable]","since":"arma3 1.96","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to test AI feature for","types":["Object"],"since":null,"text":"unit: Object - unit to test AI feature for"},{"name":"feature","type":"String","optional":false,"default":null,"description":"see disableAI / enableAI for possible values","types":["String"],"since":null,"text":"feature: String - see disableAI / enableAI for possible values"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"true to enable, false to disable","types":["Boolean"],"since":null,"text":"enable: Boolean - true to enable, false to disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[feature, enable]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"AwareFormationSoft\" enableAIFeature true;\n```","code":["\"AwareFormationSoft\" enableAIFeature true;"]},{"text":"```sqf\nbob enableAIFeature [\"AUTOTARGET\", false];\n```","code":["bob enableAIFeature [\"AUTOTARGET\", false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["checkAIFeature","enableAI","disableAI","getUnitState","disableRemoteSensors","vehicleMoveInfo"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableAimPrecision","operator":null,"title":"enableAimPrecision","type":"command","url":"https://community.bistudio.com/wiki/enableAimPrecision","revid":351309,"updated":"2023-11-27T04:50:52Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set whether animation's aim precision affects weapon sway.","syntaxes":[{"syntax":"unit enableAimPrecision enable","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"true enable, false, disabled","types":["Boolean"],"since":null,"text":"enable: Boolean - true enable, false, disabled"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer enableAimPrecision false;\n```","code":["player enableAimPrecision false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"enableAttack","operator":null,"title":"enableAttack","type":"command","url":"https://community.bistudio.com/wiki/enableAttack","revid":321173,"updated":"2022-05-13T15:15:34Z","groups":["Groups","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set if leader can issue attack commands to the soldiers in his group.","syntaxes":[{"syntax":"group enableAttack enable","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_group1 enableAttack true;\n```","code":["_group1 enableAttack true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attackEnabled"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableAudioFeature","operator":null,"title":"enableAudioFeature","type":"command","url":"https://community.bistudio.com/wiki/enableAudioFeature","revid":363491,"updated":"2024-04-01T10:41:02Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Get the state of **or** enable/disable an audio feature. Available features are `\"lowpass\"` and `\"building_interior\"`.\n- Arma 3 v2.14 it is possible to enable `\"building_interior\"` on an object placed in a building.\n- Arma 3 v2.14 if 'enable' argument is omitted, the command returns the current state of the feature.","syntaxes":[{"syntax":"enableAudioFeature [feature, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"feature","type":"String","optional":false,"default":null,"description":"`\"lowpass\"` or `\"building_interior\"`","types":["String"],"since":null,"text":"feature: String - `\"lowpass\"` or `\"building_interior\"`"},{"name":"enable","type":"Boolean","optional":true,"default":null,"description":"true enable, false, disable","types":["Boolean"],"since":null,"text":"enable: Boolean - (Optional, getter if not provided) true enable, false, disable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"previous state","text":"Boolean - previous state"},"form":"unary","operator":null,"left":null,"right":{"text":"[feature, enable]","types":["Array"]}},{"syntax":"object enableAudioFeature [feature, enable]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"feature","type":"String","optional":false,"default":null,"description":"`\"building_interior\"` or `\"building_exterior\"` only (mutually exclusive)","types":["String"],"since":null,"text":"feature: String - `\"building_interior\"` or `\"building_exterior\"` only (mutually exclusive)"},{"name":"enable","type":"Boolean","optional":true,"default":null,"description":"true enable, false, disable","types":["Boolean"],"since":null,"text":"enable: Boolean - (Optional, getter if not provided) true enable, false, disable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"previous state","text":"Boolean - previous state"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[feature, enable]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _prevState = enableAudioFeature [\"lowpass\", true];\n```","code":["private _prevState = enableAudioFeature [\"lowpass\", true];"]},{"text":"```sqf\nprivate _prevState = pallet enableAudioFeature [\"building_interior\", true];\n```","code":["private _prevState = pallet enableAudioFeature [\"building_interior\", true];"]},{"text":"```sqf\nprivate _currState = pallet enableAudioFeature [\"building_interior\"];\nprivate _prevState = pallet enableAudioFeature [\"building_interior\", !_currState];\nhint str (_currState == _prevState); // true\n\nprivate _currState = pallet enableAudioFeature [\"building_interior\"];\nhint str (_currState == _prevState); // false\n```","code":["private _currState = pallet enableAudioFeature [\"building_interior\"];\nprivate _prevState = pallet enableAudioFeature [\"building_interior\", !_currState];\nhint str (_currState == _prevState); // true\n\nprivate _currState = pallet enableAudioFeature [\"building_interior\"];\nhint str (_currState == _prevState); // false"]}],"multiplayer":"To use this command on objects in multiplayer, remoteExec it globally with JIP queue enabled:\n\n```sqf\n[_obj, [\"building_interior\", true]] remoteExec [\"enableAudioFeature\", 0, _obj];\n```","problems":null,"aliases":[],"see_also":["insideBuilding"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"enableAutoStartUpRTD","operator":null,"title":"enableAutoStartUpRTD","type":"command","url":"https://community.bistudio.com/wiki/enableAutoStartUpRTD","revid":377778,"updated":"2026-01-03T01:32:32Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle availability of the automated helicopter start-up and shutdown sequences.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD enableAutoStartUpRTD enable","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"enable or disable","types":["Boolean"],"since":null,"text":"enable: Boolean - enable or disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD enableAutoStartUpRTD true;\n```","code":["myHelicopterRTD enableAutoStartUpRTD true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAutoStartUpEnabledRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableAutoTrimRTD","operator":null,"title":"enableAutoTrimRTD","type":"command","url":"https://community.bistudio.com/wiki/enableAutoTrimRTD","revid":377767,"updated":"2026-01-03T01:32:12Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle auto-trim for RTD helicopters.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD enableAutoTrimRTD enable","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"enable or disable","types":["Boolean"],"since":null,"text":"enable: Boolean - enable or disable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD enableAutoTrimRTD true;\n```","code":["myHelicopterRTD enableAutoTrimRTD true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAutoTrimOnRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableCamShake","operator":null,"title":"enableCamShake","type":"command","url":"https://community.bistudio.com/wiki/enableCamShake","revid":348800,"updated":"2023-11-08T14:33:20Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Allows camera shake effects via addCamShake. If set to false, then a currently active shake effect will stop immediately.\nBy default, shake effects are enabled, but once they have been disabled by this command, they will have to be enabled first, in order to be visible.","syntaxes":[{"syntax":"enableCamShake value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Boolean","optional":false,"default":null,"description":"if true, shake effects are visible","types":["Boolean"],"since":null,"text":"value: Boolean - if true, shake effects are visible"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableCamShake false;\n```","code":["enableCamShake false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addCamShake","setCamShakeDefParams","setCamShakeParams","resetCamShake"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableCaustics","operator":null,"title":"enableCaustics","type":"command","url":"https://community.bistudio.com/wiki/enableCaustics","revid":341142,"updated":"2023-05-13T22:12:34Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable/disable caustics drawing.","syntaxes":[{"syntax":"enableCaustics bool","since":null,"effect":null,"exec":null,"params":[{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableCaustics true;\n```","code":["enableCaustics true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"enableChannel","operator":null,"title":"enableChannel","type":"command","url":"https://community.bistudio.com/wiki/enableChannel","revid":378455,"updated":"2026-04-19T11:32:44Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enables/disables UI functionality which is responsible for sending text or voice chat to the given chat channel.\n\n> [!NOTE]\n> This command:\n> - can override Description.ext or server config's channel setting\n> - cannot disable Global channel for the admin or server host, because Global channel is always available for the admin\n> - does not disable *incoming* text or voice\n> - actively interrupts (since Arma 3 v2.02) the current communication in progress\n> - does not affect chat related scripting commands such as vehicleChat, globalRadio etc.\n\n| Channel ID number correspondence |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| Default Channels | Custom Channels |  |  |  |  |  |  |  |  |  |  |  |  |  |  |\n| Global | Side | Command | Group | Vehicle | Direct | CC 1 | CC 2 | CC 3 | CC 4 | CC 5 | CC 6 | CC 7 | CC 8 | CC 9 | CC 10 |\n| 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |","syntaxes":[{"syntax":"channelID enableChannel enable","since":null,"effect":null,"exec":null,"params":[{"name":"channelID","type":"Number","optional":false,"default":null,"description":"channel ID","types":["Number"],"since":null,"text":"channelID: Number - channel ID"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"true to enable, false to disable (both VoN and chat)","types":["Boolean"],"since":null,"text":"enable: Boolean - true to enable, false to disable (both VoN and chat)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"channelID","types":["Number"]},"right":{"text":"enable","types":["Boolean"]}},{"syntax":"channelID enableChannel [chat, VoN]","since":"arma3 1.60","effect":null,"exec":null,"params":[{"name":"channelID","type":"Number","optional":false,"default":null,"description":"channel ID","types":["Number"],"since":null,"text":"channelID: Number - channel ID"},{"name":"chat","type":"Boolean","optional":false,"default":null,"description":"true to enable text chat","types":["Boolean"],"since":null,"text":"chat: Boolean - true to enable text chat"},{"name":"VoN","type":"Boolean","optional":false,"default":null,"description":"true to enable voice chat","types":["Boolean"],"since":null,"text":"VoN: Boolean - true to enable voice chat"},{"name":"enableMapMarkers","type":"Boolean","optional":true,"default":"true","description":"true to enable map marker placement","types":["Boolean"],"since":"arma3 2.22","text":"enableMapMarkers: Boolean - (Optional, default true) true to enable map marker placement"},{"name":"enableMapDrawing","type":"Boolean","optional":true,"default":"true","description":"true to enable drawing on the map","types":["Boolean"],"since":"arma3 2.22","text":"enableMapDrawing: Boolean - (Optional, default true) true to enable drawing on the map"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"channelID","types":["Number"]},"right":{"text":"[chat, VoN]","types":["Array"]}}],"examples":[{"text":"```sqf\n0 enableChannel false; // disable user ability to send voice and text on global channel\n```","code":["0 enableChannel false; // disable user ability to send voice and text on global channel"]},{"text":"```sqf\n0 enableChannel [true, false]; // enable user ability to send text but disable voice on global channel\n```","code":["0 enableChannel [true, false]; // enable user ability to send text but disable voice on global channel"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentChannel","setCurrentChannel","getPlayerChannel","channelEnabled","radioChannelCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.42","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"enableCollisionWith","operator":null,"title":"enableCollisionWith","type":"command","url":"https://community.bistudio.com/wiki/enableCollisionWith","revid":369423,"updated":"2024-09-03T18:48:51Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Cancels the effects of disableCollisionWith. The collision is always enabled for both objects in the arguments, i.e. vehicle1 with vehicle2 and vehicle2 with vehicle1\n\n> [!WARNING]\n> Each object can contain only 1 reference to the object it disabled collision with. This command sets this reference to null. Therefore the command might not work as expected when trying to enable collisions with some objects but not other.","syntaxes":[{"syntax":"vehicle1 enableCollisionWith vehicle2","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle1","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle1: Object"},{"name":"vehicle2","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle2: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle1","types":["Object"]},"right":{"text":"vehicle2","types":["Object"]}}],"examples":[{"text":"```sqf\n[_veh1, _veh2] remoteExecCall [\"enableCollisionWith\", 0, _veh1];\n```","code":["[_veh1, _veh2] remoteExecCall [\"enableCollisionWith\", 0, _veh1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["collisionDisabledWith","disableCollisionWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"enableCopilot","operator":null,"title":"enableCopilot","type":"command","url":"https://community.bistudio.com/wiki/enableCopilot","revid":369225,"updated":"2024-09-03T10:34:55Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enables copilot actions, toggles availability of the actions related to copilots, such as taking over controls, suspending controls, etc. This command triggers the `\"ControlsShifted\"` event handler.","syntaxes":[{"syntax":"vehicle enableCopilot enable","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle on which to toggle copilot actions","types":["Object"],"since":null,"text":"vehicle: Object - vehicle on which to toggle copilot actions"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"enable or disable","types":["Boolean"],"since":null,"text":"enable: Boolean - enable or disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nif (!isCopilotEnabled myHeli) then\n{\n    myHeli enableCopilot true;\n};\n```","code":["if (!isCopilotEnabled myHeli) then\n{\n\tmyHeli enableCopilot true;\n};"]}],"multiplayer":"Execute this command globally (e.g with remoteExec) to have it synced on all clients.","problems":null,"aliases":[],"see_also":["isCopilotEnabled","currentPilot"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Take On Helicopters version 1.01","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableDebriefingStats","operator":null,"title":"enableDebriefingStats","type":"command","url":"https://community.bistudio.com/wiki/enableDebriefingStats","revid":318957,"updated":"2022-05-13T09:22:06Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable debriefing score table.","syntaxes":[{"syntax":"enableDebriefingStats [left, top, width, height]","since":null,"effect":null,"exec":null,"params":[{"name":"left","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"left: Number"},{"name":"top","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"top: Number"},{"name":"width","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"width: Number"},{"name":"height","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"height: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[left, top, width, height]","types":["Array"]}}],"examples":[{"text":"```sqf\nenableDebriefingStats [0.1, 0.1, 0.8, 0.8];\n```","code":["enableDebriefingStats [0.1, 0.1, 0.8, 0.8];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableDebriefingStats"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"enableDiagLegend","operator":null,"title":"enableDiagLegend","type":"command","url":"https://community.bistudio.com/wiki/enableDiagLegend","revid":310210,"updated":"2022-05-05T13:10:42Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable or disable the legend for diagnostics. **Internal dev only!**","syntaxes":[{"syntax":"enableDiagLegend enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableDiagLegend false;\n```","code":["enableDiagLegend false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_fpsMin","diag_frameNo","diag_log","diag_tickTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"enableDirectionStabilization","operator":null,"title":"enableDirectionStabilization","type":"command","url":"https://community.bistudio.com/wiki/enableDirectionStabilization","revid":378546,"updated":"2026-05-05T10:57:24Z","groups":["Camera Control","Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables / disables direction stabilization of turrets. This command only has an effect if the current optic mode of the selected turret has `directionStabilized` configured in config.","syntaxes":[{"syntax":"vehicle enableDirectionStabilization [enabled, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":"enable or disable turret stabilization","types":["Boolean"],"since":null,"text":"enabled: Boolean - enable or disable turret stabilization"},{"name":"turretPath","type":"Turret Path","optional":true,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[enabled, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nuav enableDirectionStabilization [false, [0]]; // Disable direction stabilization for the first turret\n```","code":["uav enableDirectionStabilization [false, [0]]; // Disable direction stabilization for the first turret"]},{"text":"```sqf\nuav enableDirectionStabilization [true, [0]];\n```","code":["uav enableDirectionStabilization [true, [0]];"]},{"text":"```sqf\nuav enableDirectionStabilization [false]; // Disable direction stabilization for the primary turret\n```","code":["uav enableDirectionStabilization [false]; // Disable direction stabilization for the primary turret"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["directionStabilizationEnabled","lockCameraTo","enableGunStabilization"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Turrets","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"enableDynamicSimulation","operator":null,"title":"enableDynamicSimulation","type":"command","url":"https://community.bistudio.com/wiki/enableDynamicSimulation","revid":378012,"updated":"2026-01-21T18:54:03Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"global","effect":"local","server_exec":true},"exec":null,"description":"Enables or disables Arma 3: Dynamic Simulation for an object or group.\n\n> [!IMPORTANT]\n> Dynamic simulation for AI units operates on Groups:\n>\n> ```sqf\n> _unit enableDynamicSimulation true; // Does not work\n> group _unit enableDynamicSimulation true; // Works\n> ```\n>\n> It is not possible to enable dynamic simulation for groups that contain a player unit.\n\n> [!NOTE]\n> This command has no effect on *mines*!","syntaxes":[{"syntax":"target enableDynamicSimulation enable","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"target: Object or Group"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Object","Group"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_myObject enableDynamicSimulation true;\n```","code":["_myObject enableDynamicSimulation true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[{"user":"ansin11","date":"2026-01-21T18:41:00Z","text":"According to Discord user Marko, dynamic simulation for vehicles has to be enabled before the vehicle is crewed. Calling `_vehicle enableDynamicSimulation true` on a vehicle that already has a crew does not enable dynamic simulation for the vehicle (even if dynamic simulation for the crew is already enabled).\n\nThe following example illustrates how a crewed vehicle with working dynamic simulation is created:\n\n```sqf\nprivate _vehicle = createVehicle [\"B_APC_Wheeled_01_cannon_F\", [0,0,0], [], 0, \"NONE\"]; \n_vehicle enableDynamicSimulation true;\n\nprivate _group = createGroup west;\n[_vehicle, _group] call BIS_fnc_spawnCrew; \n_group enableDynamicSimulation true;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Local Effect","Scripting Commands: Server Execution"]},{"name":"enableDynamicSimulationSystem","operator":null,"title":"enableDynamicSimulationSystem","type":"command","url":"https://community.bistudio.com/wiki/enableDynamicSimulationSystem","revid":373713,"updated":"2025-06-21T11:20:46Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Enables or disables the whole Arma 3: Dynamic Simulation system","syntaxes":[{"syntax":"enableDynamicSimulationSystem enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableDynamicSimulationSystem true;\n```","code":["enableDynamicSimulationSystem true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"enableEndDialog","operator":null,"title":"enableEndDialog","type":"command","url":"https://community.bistudio.com/wiki/enableEndDialog","revid":325303,"updated":"2022-07-10T22:52:51Z","groups":["Camera Control","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enables the execution of a custom camera sequence after the players death, coded in onPlayerKilled.sqs.","syntaxes":[{"syntax":"enableEndDialog","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nenableEndDialog;\n```","code":["enableEndDialog;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceEnd"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Mission Information","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableEngineArtillery","operator":null,"title":"enableEngineArtillery","type":"command","url":"https://community.bistudio.com/wiki/enableEngineArtillery","revid":310205,"updated":"2022-05-05T13:10:41Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enable/disable the artillery engine. This allows the user to use the artillery computer on mortar/artillery, and for AI to use it for indirect fire.","syntaxes":[{"syntax":"enableEngineArtillery enabled","since":null,"effect":null,"exec":null,"params":[{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enabled","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableEngineArtillery false;\n```","code":["enableEngineArtillery false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownArtilleryComputer","getArtilleryAmmo","commandArtilleryFire","doArtilleryFire","getArtilleryComputerSettings","getArtilleryETA","inRangeOfArtillery"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 2: Operation Arrowhead version 1.54","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableEnvironment","operator":null,"title":"enableEnvironment","type":"command","url":"https://community.bistudio.com/wiki/enableEnvironment","revid":349663,"updated":"2023-11-18T17:02:32Z","groups":["Environment","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enable/disable environmental effects: ambient life and/or ambient sound.\n\n> [!NOTE]\n> This command has to be executed after mission start: be sure to use e.g `sleep 0.1;` for it to take effect.\n\nInfluenced sounds among others are:\n- bird sounds\n- insect sounds\n- waves\n- wind\n- rain\n- sounds produced by air conditioners and similar\n- Arma 3 v2.06 thunder (an already started sound will not be cut but future ones will be prevented)","syntaxes":[{"syntax":"enableEnvironment enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"false to disable ambient life and ambient sounds, true to re-enable it","types":["Boolean"],"since":null,"text":"enable: Boolean - false to disable ambient life and ambient sounds, true to re-enable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}},{"syntax":"enableEnvironment [ambientLife, ambientSound, windyCoef]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"ambientLife","type":"Boolean","optional":false,"default":null,"description":"enable/disable ambient life (bees, rabbits, birds, snakes, fish)","types":["Boolean"],"since":null,"text":"ambientLife: Boolean - enable/disable ambient life (bees, rabbits, birds, snakes, fish)"},{"name":"ambientSound","type":"Boolean","optional":false,"default":null,"description":"enable/disable ambient sounds (cicadas, owls, etc)","types":["Boolean"],"since":null,"text":"ambientSound: Boolean - enable/disable ambient sounds (cicadas, owls, etc)"},{"name":"windyCoef","type":"Number","optional":true,"default":"1","description":"howling wind at heights, range 0..1","types":["Number"],"since":"arma3 2.12","text":"windyCoef: Number - (Optional, default 1) howling wind at heights, range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[ambientLife, ambientSound, windyCoef]","types":["Array"]}}],"examples":[{"text":"```sqf\nenableEnvironment false; // identical to enableEnvironment [false, false]\n```","code":["enableEnvironment false; // identical to enableEnvironment [false, false]"]},{"text":"```sqf\nenableEnvironment [false, true];\nenableEnvironment [false, true, 0.5]; // since Arma 3 v2.12\n```","code":["enableEnvironment [false, true];\nenableEnvironment [false, true, 0.5]; // since Arma 3 v2.12"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["environmentEnabled","fadeEnvironment","environmentVolume","initAmbientLife","sideAmbientLife","getAllEnvSoundControllers","getEnvSoundController","setSoundEffect","Arma 3: Animals: Ambient System"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Sounds","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableFatigue","operator":null,"title":"enableFatigue","type":"command","url":"https://community.bistudio.com/wiki/enableFatigue","revid":341014,"updated":"2023-05-13T22:06:23Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enables/Disables the person's fatigue.","syntaxes":[{"syntax":"unit enableFatigue enable","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer enableFatigue false;\n```","code":["player enableFatigue false;"]},{"text":"```sqf\n{ _x enableFatigue false; } forEach (units group player);\n```","code":["{ _x enableFatigue false; } forEach (units group player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getFatigue","setFatigue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"enableFreeLook","operator":null,"title":"enableFreeLook","type":"command","url":"https://community.bistudio.com/wiki/enableFreeLook","revid":379078,"updated":"2026-09-27T07:30:52Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables or disables the freelook toggle (2x Alt)","syntaxes":[{"syntax":"enableFreeLook enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"enable or disable the toggle","types":["Boolean"],"since":null,"text":"enable: Boolean - enable or disable the toggle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"Previous state","text":"Boolean - Previous state"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableFreeLook true;\n```","code":["enableFreeLook true;"]},{"text":"```sqf\n// a function to get the current state without making changes\nprivate _fnc_isFreeLookToggled = \n{\n  private _oldState = enableFreeLook true; // enable temporarily; get state\n  enableFreeLook _oldState;\n  _oldState; // return the state\n};\n\nprivate _isFreeLookToggled = call _fnc_isFreeLookToggled;\n\n// a function to toggle the state\nprivate _fnc_toggleFreeLook = \n{\n  enableFreeLook !enableFreeLook false;\n};\n\ncall _fnc_toggleFreeLook; // toggle it (if enabled->disable it, and vice versa)\n```","code":["// a function to get the current state without making changes\nprivate _fnc_isFreeLookToggled = \n{\n  private _oldState = enableFreeLook true; // enable temporarily; get state\n  enableFreeLook _oldState;\n  _oldState; // return the state\n};\n\nprivate _isFreeLookToggled = call _fnc_isFreeLookToggled;\n\n// a function to toggle the state\nprivate _fnc_toggleFreeLook = \n{\n  enableFreeLook !enableFreeLook false;\n};\n\ncall _fnc_toggleFreeLook; // toggle it (if enabled->disable it, and vice versa)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["freeLook"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"enableGunLights","operator":null,"title":"enableGunLights","type":"command","url":"https://community.bistudio.com/wiki/enableGunLights","revid":351992,"updated":"2024-02-01T23:23:57Z","groups":["Lights","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Toggles the target group's gun lights. disableAI \"LIGHTS\" will disable the use of gun lights.\n\n> [!IMPORTANT]\n> This command acts on each unit of the provided group or provided unit's group; there is no need to apply it on each unit.","syntaxes":[{"syntax":"target enableGunLights mode","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Group or Object","optional":false,"default":null,"description":"the group forced to use gun lights. If unit is supplied as argument, unit's group is used","types":["Group","Object"],"since":null,"text":"target: Group or Object - the group forced to use gun lights. If unit is supplied as argument, unit's group is used"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be:\n- `\"Auto\"` - Depends on combat mode\n- `\"ForceOn\"` - Always on\n- `\"ForceOff\"` - Always off","types":["String"],"since":null,"text":"mode: String - can be:\n- `\"Auto\"` - Depends on combat mode\n- `\"ForceOn\"` - Always on\n- `\"ForceOff\"` - Always off"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Group","Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_groupA enableGunLights \"Auto\";\n```","code":["_groupA enableGunLights \"Auto\";"]},{"text":"```sqf\n_unit1 enableGunLights \"ForceOff\"; // sets _unit1's GROUP behaviour to not use gun lights\n```","code":["_unit1 enableGunLights \"ForceOff\"; // sets _unit1's GROUP behaviour to not use gun lights"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isFlashlightOn","enableIRLasers"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableGunStabilization","operator":null,"title":"enableGunStabilization","type":"command","url":"https://community.bistudio.com/wiki/enableGunStabilization","revid":378545,"updated":"2026-05-05T10:44:45Z","groups":["Camera Control","Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables/disables turret gun stabilisation.","syntaxes":[{"syntax":"vehicle enableGunStabilization [mode, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"mode","type":"Number","optional":false,"default":null,"description":"can be one of:\n- -1 - clear override\n- 0 - no stabilisation\n- 1 - elevation stabilisation\n- 2 - traverse stabilisation\n- 3 - both","types":["Number"],"since":null,"text":"mode: Number - can be one of:\n- -1 - clear override\n- 0 - no stabilisation\n- 1 - elevation stabilisation\n- 2 - traverse stabilisation\n- 3 - both"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Number","types":["Number"],"description":"the previous mode, also returns -1 on error","text":"Number - the previous mode, also returns -1 on error"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[mode, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player enableGunStabilization [3, [0]];\n```","code":["vehicle player enableGunStabilization [3, [0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDirectionStabilization","directionStabilizationEnabled","lockCameraTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Turrets","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"enableInfoPanelComponent","operator":null,"title":"enableInfoPanelComponent","type":"command","url":"https://community.bistudio.com/wiki/enableInfoPanelComponent","revid":378366,"updated":"2026-04-03T16:46:18Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Controls availability of component to given object info panel.","syntaxes":[{"syntax":"unit enableInfoPanelComponent [panelID, componentClassOrType, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"},{"name":"componentClassOrType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"componentClassOrType: String"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)","text":"Boolean - true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[panelID, componentClassOrType, enable]","types":["Array"]}},{"syntax":"[unit, turretPath] enableInfoPanelComponent [panelID, componentClassOrType, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"turret index","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - turret index"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"},{"name":"componentClassOrType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"componentClassOrType: String"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)","text":"Boolean - true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)"},"form":"binary","operator":null,"left":{"text":"[unit, turretPath]","types":["Array"]},"right":{"text":"[panelID, componentClassOrType, enable]","types":["Array"]}}],"examples":[{"text":"```sqf\n// enables slingload assistant on player's vehicle right panel at driver position\n[vehicle player, [-1]] enableInfoPanelComponent [\"VehicleSystemsDisplayManagerComponentRight\", \"SlingLoadDisplay\", true];\n```","code":["// enables slingload assistant on player's vehicle right panel at driver position\n[vehicle player, [-1]] enableInfoPanelComponent [\"VehicleSystemsDisplayManagerComponentRight\", \"SlingLoadDisplay\", true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanel","infoPanels","setInfoPanel","infoPanelComponents","infoPanelComponentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"enableIRLasers","operator":null,"title":"enableIRLasers","type":"command","url":"https://community.bistudio.com/wiki/enableIRLasers","revid":310272,"updated":"2022-05-05T13:11:21Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Allows the AI to use IR lasers. Units should be in \"Combat\" behaviour.","syntaxes":[{"syntax":"unitOrGroup enableIRLasers value","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrGroup","type":"Object or Group","optional":false,"default":null,"description":"the unit or the group allowed to use IR lasers","types":["Object","Group"],"since":null,"text":"unitOrGroup: Object or Group - the unit or the group allowed to use IR lasers"},{"name":"value","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"value: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitOrGroup","types":["Object","Group"]},"right":{"text":"value","types":["Boolean"]}}],"examples":[{"text":"```sqf\ngroup player enableIRLasers true;\n```","code":["group player enableIRLasers true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isIRLaserOn","enableGunLights","isLightOn","isCollisionLightOn","setPilotLight","setCollisionLight"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableMimics","operator":null,"title":"enableMimics","type":"command","url":"https://community.bistudio.com/wiki/enableMimics","revid":310253,"updated":"2022-05-05T13:11:11Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables/disables mimics on a given unit.","syntaxes":[{"syntax":"unit enableMimics enabled","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"enabled","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncursorTarget enableMimics false;\n```","code":["cursorTarget enableMimics false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMimic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"enablePersonTurret","operator":null,"title":"enablePersonTurret","type":"command","url":"https://community.bistudio.com/wiki/enablePersonTurret","revid":377479,"updated":"2026-01-02T06:48:53Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables or disables firing from a vehicle cargo position. To get the turret path use assignedVehicleRole or getCargoIndex command.","syntaxes":[{"syntax":"vehicle enablePersonTurret [turretPath, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turretPath, enable]","types":["Array"]}}],"examples":[{"text":"```sqf\nheli enablePersonTurret [[1], true];\n```","code":["heli enablePersonTurret [[1], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedVehicleRole","allTurrets","moveInTurret","turretUnit","assignAsTurret","getCargoIndex","moveInCargo","assignAsCargoIndex","emptyPositions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"enableRadio","operator":null,"title":"enableRadio","type":"command","url":"https://community.bistudio.com/wiki/enableRadio","revid":370858,"updated":"2025-02-19T17:36:45Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enable and disable radio messages to be heard and shown in the left lower corner of the screen - the order-giving unit can still be heard direct-talking when in its vicinity. The AI will still follow orders.\nThis command can be helpful during cutscenes.","syntaxes":[{"syntax":"enableRadio state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to enable the radio, false to disable it","types":["Boolean"],"since":null,"text":"state: Boolean - true to enable the radio, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableRadio false;\nclearRadio;\n```","code":["enableRadio false;\nclearRadio;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioEnabled","setSpeaker","disableConversation","enableSentences","showSubtitles"],"notes":[{"user":"Lou Montana","date":"2008-08-07T14:50:00Z","text":"This command doesn't disable text-chat in multiplayer."},{"user":"Beita","date":"2008-09-11T23:43:00Z","text":"Does not affect VoN."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableReload","operator":null,"title":"enableReload","type":"command","url":"https://community.bistudio.com/wiki/enableReload","revid":370150,"updated":"2024-11-02T14:23:00Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enable / disable auto-reload (including AI) when magazine is empty. Default - enabled.","syntaxes":[{"syntax":"object enableReload enable","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_vehicle enableReload false;\n```","code":["_vehicle enableReload false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["reloadEnabled","reload","needReload"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableRopeAttach","operator":null,"title":"enableRopeAttach","type":"command","url":"https://community.bistudio.com/wiki/enableRopeAttach","revid":310266,"updated":"2022-05-05T13:11:17Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enables or disables the ability to be attached to a rope end for the given entity.","syntaxes":[{"syntax":"entity enableRopeAttach enable","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"given entity","types":["Object"],"since":null,"text":"entity: Object - given entity"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"false to disable rope attachment","types":["Boolean"],"since":null,"text":"enable: Boolean - false to disable rope attachment"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player enableRopeAttach false;\n```","code":["vehicle player enableRopeAttach false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"enableSatNormalOnDetail","operator":null,"title":"enableSatNormalOnDetail","type":"command","url":"https://community.bistudio.com/wiki/enableSatNormalOnDetail","revid":310242,"updated":"2022-05-05T13:11:02Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables/Disables satellite normal map or detail maps.","syntaxes":[{"syntax":"enableSatNormalOnDetail state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"state: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableSatNormalOnDetail true;\n```","code":["enableSatNormalOnDetail true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"enableSaving","operator":null,"title":"enableSaving","type":"command","url":"https://community.bistudio.com/wiki/enableSaving","revid":340305,"updated":"2023-04-28T23:04:59Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable / disable saving of the game with an optional autosave.","syntaxes":[{"syntax":"enableSaving enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}},{"syntax":"enableSaving [enable, save]","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"allow saveGame command usage and manual saving","types":["Boolean"],"since":null,"text":"enable: Boolean - allow saveGame command usage and manual saving"},{"name":"save","type":"Boolean","optional":false,"default":null,"description":"create an autosave on command execution","types":["Boolean"],"since":null,"text":"save: Boolean - create an autosave on command execution"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[enable, save]","types":["Array"]}}],"examples":[{"text":"```sqf\nenableSaving false;        // saving disabled, does autosave - same as [false, true]\nenableSaving true;        // saving enabled, does not autosave - same as [true, false]\n\nenableSaving [false, false];    // saving disabled, does not autosave\nenableSaving [false, true];        // saving disabled, does autosave\nenableSaving [true, false];        // saving enabled, doesn't autosave\nenableSaving [true, true];        // saving enabled, does autosave\n```","code":["enableSaving false;\t\t// saving disabled, does autosave - same as [false, true]\nenableSaving true;\t\t// saving enabled, does not autosave - same as [true, false]\n\nenableSaving [false, false];\t// saving disabled, does not autosave\nenableSaving [false, true];\t\t// saving disabled, does autosave\nenableSaving [true, false];\t\t// saving enabled, doesn't autosave\nenableSaving [true, true];\t\t// saving enabled, does autosave"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadGame","saveGame","savingEnabled","isSaving","BIS_fnc_enableSaving"],"notes":[{"user":"POLPOX","date":"2023-01-02T11:48:55Z","text":"Also possible to disable Save and Exit button from pause menu and replaces it with Abort. (confirmed in Arma 3 2.12)"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableSentences","operator":null,"title":"enableSentences","type":"command","url":"https://community.bistudio.com/wiki/enableSentences","revid":310190,"updated":"2022-05-05T13:10:32Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enables radio transmissions to be heard and seen on screen. It does not affect KBTell conversations.","syntaxes":[{"syntax":"enableSentences enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableSentences false;\n```","code":["enableSentences false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sentencesEnabled","setSpeaker","disableConversation","enableRadio","showSubtitles"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableSimulation","operator":null,"title":"enableSimulation","type":"command","url":"https://community.bistudio.com/wiki/enableSimulation","revid":376579,"updated":"2025-10-28T15:58:20Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enables / disables simulation for the given entity, e.g its animation and physics; it will still be able to take damage and report enemies.\nThis command will affect entity simulation only locally.\nFor a global and JIP enabled alternative, see enableSimulationGlobal.","syntaxes":[{"syntax":"entity enableSimulation state","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"state: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer enableSimulation false;\n```","code":["player enableSimulation false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableSimulationGlobal","simulationEnabled","enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation"],"notes":[{"user":"Tyrspawn","date":"2011-07-20T04:39:00Z","text":"> [!NOTE]\n> The following only applies to Arma 2 before a certain patch, in which such changes have been integrated in the game code.\n\nNou/Jaynus have discovered something quite important about the Arma 2 engine:\n\nOrient yourself to the enableSimulation command in Arma 2:\n\nIf simulation is disabled on objects (this enablesimulation false), they do not send updates across the network, drastically reducing traffic across the network by an order of magnitude. What this means in practicality is that it is possible to have huge mission maker created cities with no or negligible impact on mission performance. Mission placed objects is the most common cause of performance woes - so this is huge news, and was previously undocumented, both on the BIS wiki and elsewhere.\n\nThere are some quirks.\n\nWhile an object which has enableSimulation false set on it will take damage, it will not display any animations or damage states until enableSimulation is enabled back onto it. If you want to disable simulation on a unit and then show it as dieing once it is hit or damaged, add an eventhandler onto it which enables simulation on the object when it is hit or killed. Hit handler for best visual, killed handler for best performance.\n\nThis discovery will be the basis of a new unit caching script by Jaynus.\n\nThis also has importance in a technical sense: bandwith is the most significant factor in mission performance. The lower the server bandwith, the better the performance."},{"user":"Rocket","date":"2011-09-08T14:20:00Z","text":"Objects with disabled simulation are not calculated for lightsources beyond the global light (moon/sun), so any light sources you create will not light them."},{"user":"Killzone_Kid","date":"2014-10-21T15:33:00Z","text":"Units that have been previously subjected to enableSimulation false; or enableSimulationGlobal false; may stay unrecognised for a long time even after simulation was re-enabled, returning objNull as cursorTarget. Force revealing units with reveal command usually solves the problem. For example:\n\n```sqf\n{ player reveal _x } forEach allUnits;\n```"},{"user":"Waffle SS.","date":"2015-05-23T16:28:00Z","text":"After using **enableSimulation** false or enableSimulationGlobal false on an object, setPos will still update its position across the network in MP."},{"user":"Pierre MGI","date":"2015-12-02T18:55:00Z","text":"After using enableSimulation false or enableSimulationGlobal false on a vehicle (car, helo), don't forget to re-enable simulation on this vehicle before a player jumps into it. Otherwise, he will be stuck in it, with a black screen and no way to escape!"},{"user":"Demellion","date":"2016-09-01T16:52:00Z","text":"Since **Arma 3 1.56** the object can also be returned with cursorObject even if the simulation is not enabled."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"enableSimulationGlobal","operator":null,"title":"enableSimulationGlobal","type":"command","url":"https://community.bistudio.com/wiki/enableSimulationGlobal","revid":329206,"updated":"2022-07-25T16:01:42Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Enable or disable simulation for given entity, globally. Has the same effect as enableSimulation when used in singleplayer.","syntaxes":[{"syntax":"entity enableSimulationGlobal enable","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_myObject enableSimulationGlobal false;\n```","code":["_myObject enableSimulationGlobal false;"]},{"text":"```sqf\n[_object, false] remoteExec [\"enableSimulationGlobal\", 2];\n```","code":["[_object, false] remoteExec [\"enableSimulationGlobal\", 2];"]}],"multiplayer":"> [!NOTE]\n> Since Arma 3 v2.06 the command can also be executed client-side, with a local argument.","problems":null,"aliases":[],"see_also":["enableSimulation","simulationEnabled","enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation"],"notes":[{"user":"Killzone_Kid","date":"2014-10-21T15:33:00Z","text":"Units that have been previously subjected to `enableSimulation false` or `enableSimulationGlobal false` may stay unrecognised for a long time even after simulation was re-enabled, returning objNull as cursorTarget. Force revealing units with reveal command usually solves the problem. For example:\n\n```sqf\nplayer reveal previouslySimDisabledUnit;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.12","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"enableStamina","operator":null,"title":"enableStamina","type":"command","url":"https://community.bistudio.com/wiki/enableStamina","revid":321174,"updated":"2022-05-13T15:15:54Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enable/disable stamina system","syntaxes":[{"syntax":"unit enableStamina enabled","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"enabled","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer enableStamina true;\n```","code":["player enableStamina true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"enableStressDamage","operator":null,"title":"enableStressDamage","type":"command","url":"https://community.bistudio.com/wiki/enableStressDamage","revid":319014,"updated":"2022-05-13T09:22:11Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Toggles stress damage in Advanced Flight Model, which otherwise could be manually toggles in game setting: `Options > Game > Helicopter Flight Model > Advanced > Stress Damage`.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"enableStressDamage state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to enable stress damage, false to disable it","types":["Boolean"],"since":null,"text":"state: Boolean - true to enable stress damage, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nif (difficultyEnabledRTD) then { enableStressDamage true };\n```","code":["if (difficultyEnabledRTD) then { enableStressDamage true };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Description.ext","difficultyEnabledRTD","isStressDamageEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"enableTeamSwitch","operator":null,"title":"enableTeamSwitch","type":"command","url":"https://community.bistudio.com/wiki/enableTeamSwitch","revid":310209,"updated":"2022-05-05T13:10:42Z","groups":["Team Switch"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable / disable Team Switch. The default setting is enabled.","syntaxes":[{"syntax":"enableTeamSwitch enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableTeamSwitch true;\n```","code":["enableTeamSwitch true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Team Switch","onBriefingTeamSwitch","onTeamSwitch","teamSwitch","teamSwitchEnabled","selectPlayer"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableTraffic","operator":null,"title":"enableTraffic","type":"command","url":"https://community.bistudio.com/wiki/enableTraffic","revid":309946,"updated":"2022-05-05T12:17:00Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable ambient traffic. \n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"enableTraffic enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"enable or disable","types":["Boolean"],"since":null,"text":"enable: Boolean - enable or disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableTraffic true;\n```","code":["enableTraffic true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTrafficDensity","setTrafficDistance","setTrafficGap","setTrafficSpeed"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Environment","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"enableUAVConnectability","operator":null,"title":"enableUAVConnectability","type":"command","url":"https://community.bistudio.com/wiki/enableUAVConnectability","revid":349591,"updated":"2023-11-11T23:17:57Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enables unit's AV terminal(s) connecting to UAV.","syntaxes":[{"syntax":"object enableUAVConnectability [uav, checkAllItems]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"},{"name":"checkAllItems","type":"Boolean","optional":false,"default":null,"description":"true for enabling of all terminals in unit's inventory, false for enabling of terminal assigned to proper slot only.","types":["Boolean"],"since":null,"text":"checkAllItems: Boolean - true for enabling of all terminals in unit's inventory, false for enabling of terminal assigned to proper slot only."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[uav, checkAllItems]","types":["Array"]}}],"examples":[{"text":"```sqf\nunit enableUAVConnectability [uav, true];\n```","code":["unit enableUAVConnectability [uav, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableUAVConnectability","isUAVConnectable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.24","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"enableUAVWaypoints","operator":null,"title":"enableUAVWaypoints","type":"command","url":"https://community.bistudio.com/wiki/enableUAVWaypoints","revid":369357,"updated":"2024-09-03T18:43:05Z","groups":["Waypoints","Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables/disables the option for player to set waypoints for UAV in AV terminal.","syntaxes":[{"syntax":"uav enableUAVWaypoints enable","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"uav","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_uav enableUAVWaypoints false;\nhint str waypointsEnabledUAV _uav; // returns false\n```","code":["_uav enableUAVWaypoints false;\nhint str waypointsEnabledUAV _uav; // returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointsEnabledUAV","enableUAVConnectability","disableUAVConnectability","isUAVConnected","isUAVConnectable","allUnitsUAV","getConnectedUAV","connectTerminalToUAV"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Command Group: Waypoints","Introduced with Arma 3 version 1.40","Scripting Commands"]},{"name":"enableVehicleCargo","operator":null,"title":"enableVehicleCargo","type":"command","url":"https://community.bistudio.com/wiki/enableVehicleCargo","revid":376361,"updated":"2025-10-07T21:42:46Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable/disable option to transport other vehicles (if configured) or be transported.","syntaxes":[{"syntax":"vehicle enableVehicleCargo enable","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_vehicle enableVehicleCargo true;\n```","code":["_vehicle enableVehicleCargo true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle in Vehicle Transport","canVehicleCargo","setVehicleCargo","getVehicleCargo","isVehicleCargo","vehicleCargoEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"enableVehicleSensor","operator":null,"title":"enableVehicleSensor","type":"command","url":"https://community.bistudio.com/wiki/enableVehicleSensor","revid":349214,"updated":"2023-11-08T14:50:48Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enable/disable given sensor","syntaxes":[{"syntax":"vehicle enableVehicleSensor [componentName, enabled]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"componentName","type":"String","optional":false,"default":null,"description":"the component's name (can either be its \"real name\" or its className)","types":["String"],"since":null,"text":"componentName : String - the component's name (can either be its \"real name\" or its className)"},{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":"component status","types":["Boolean"],"since":null,"text":"enabled: Boolean - component status"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[componentName, enabled]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player enableVehicleSensor [\"PassiveRadarSensorComponent\", false]; // disables passive radar\n```","code":["vehicle player enableVehicleSensor [\"PassiveRadarSensorComponent\", false]; // disables passive radar"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["listVehicleSensors","isVehicleSensorEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"enableWeaponDisassembly","operator":null,"title":"enableWeaponDisassembly","type":"command","url":"https://community.bistudio.com/wiki/enableWeaponDisassembly","revid":338953,"updated":"2023-04-18T16:08:55Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Enables or disables disassembly of static weapons. Could be applied to local player, to another unit or to static weapon directly.","syntaxes":[{"syntax":"enableWeaponDisassembly enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"false to prevent local player from being able to disassemble static weapons","types":["Boolean"],"since":null,"text":"enable: Boolean - false to prevent local player from being able to disassemble static weapons"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}},{"syntax":"entity enableWeaponDisassembly enable","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or static weapon","types":["Object"],"since":null,"text":"entity: Object - unit or static weapon"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":"false to prevent a unit from being able to disassemble static weapons, or to prevent a static weapon from being disassembled by anyone","types":["Boolean"],"since":null,"text":"enable: Boolean  - false to prevent a unit from being able to disassemble static weapons, or to prevent a static weapon from being disassembled by anyone"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nenableWeaponDisassembly false;\n```","code":["enableWeaponDisassembly false;"]},{"text":"```sqf\nsoldier1 enableWeaponDisassembly false;\n```","code":["soldier1 enableWeaponDisassembly false;"]},{"text":"```sqf\nmortar1 enableWeaponDisassembly false;\n```","code":["mortar1 enableWeaponDisassembly false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponDisassemblyEnabled","weapons","action","inGameUISetEventHandler"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"endl","operator":null,"title":"endl","type":"command","url":"https://community.bistudio.com/wiki/endl","revid":325316,"updated":"2022-07-11T14:52:06Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a string containing a line break, similar to lineBreak for text. The name is inspired by c++ std::endl (**end** **l**ine).\nThe command returns `\"\\r\\n\"`, which contains control characters rather than printable characters:\n\n```sqf\nhint str count \"\\r\\n\";    // 4\nhint str count endl;    // 2\n```\n\nThe line break works for diag_log and ctrlSetText.\nIt does not work with the hint because hint interprets printable \"\\n\" as line break instead.\nAlternatively one can use toString command to get other characters.","syntaxes":[{"syntax":"endl","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":"line break","text":"String - line break"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ndiag_log (\"line1\" + endl + \"line2\");\n```","code":["diag_log (\"line1\" + endl + \"line2\");"]},{"text":"```sqf\n_ctrl = findDisplay 46 ctrlCreate [\"RscTextMulti\", -1];\n_ctrl ctrlSetPosition [0,0,1,1];\n_ctrl ctrlCommit 0;\n_ctrl ctrlSetText format [\"line1%1line2%1line3\", endl];\n```","code":["_ctrl = findDisplay 46 ctrlCreate [\"RscTextMulti\", -1];\n_ctrl ctrlSetPosition [0,0,1,1];\n_ctrl ctrlCommit 0;\n_ctrl ctrlSetText format [\"line1%1line2%1line3\", endl];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineBreak","str","format","toString","joinString","splitString","toArray"],"notes":[{"user":"7erra","date":"2020-07-15T11:50:00Z","text":"`toArray endl` results in `[13, 10]`. `toString [13, 10]` is therefore equivalent (or at least very similar) to endl."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"endLoadingScreen","operator":null,"title":"endLoadingScreen","type":"command","url":"https://community.bistudio.com/wiki/endLoadingScreen","revid":376713,"updated":"2025-11-10T18:45:49Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Finishes loading screen started by startLoadingScreen.\n\n> [!NOTE]\n> **Arma 3:** - Use BIS_fnc_endLoadingScreen to prevent potential usage conflicts.\n> - Arma 3 v2.18 The loading screen can be force-ended with the ENDLOAD cheat code.","syntaxes":[{"syntax":"endLoadingScreen","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nstartLoadingScreen [\"Loading My Mission\"];\n// code\nprogressLoadingScreen 0.5;\n// code\nendLoadingScreen;\n```","code":["startLoadingScreen [\"Loading My Mission\"];\n// code\nprogressLoadingScreen 0.5;\n// code\nendLoadingScreen;"]},{"text":"```sqf\n// this structure prevents error-prone or lengthy code to miss endLoadingScreen.\nprivate _maxTime = diag_tickTime + 30; // max 30s of loading\n\nstartLoadingScreen [\"Loading\"];\nprivate _handle = 0 spawn {\n    // code that may crash or take too long\n};\n\nwaitUntil { sleep .01; scriptDone _handle || diag_tickTime > _maxTime };\nendLoadingScreen;\n```","code":["// this structure prevents error-prone or lengthy code to miss endLoadingScreen.\nprivate _maxTime = diag_tickTime + 30; // max 30s of loading\n\nstartLoadingScreen [\"Loading\"];\nprivate _handle = 0 spawn {\n\t// code that may crash or take too long\n};\n\nwaitUntil { sleep .01; scriptDone _handle || diag_tickTime > _maxTime };\nendLoadingScreen;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["startLoadingScreen","progressLoadingScreen","BIS_fnc_endLoadingScreen"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"endMission","operator":null,"title":"endMission","type":"command","url":"https://community.bistudio.com/wiki/endMission","revid":338926,"updated":"2023-04-17T15:26:24Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Finish the mission.\n**Mission saves are deleted**. Use failMission if they should not be.\n\n> [!NOTE]\n> **Arma 3:** To maintain Arma 3 visual style, it is recommended to use BIS_fnc_endMission instead.","syntaxes":[{"syntax":"endMission endType","since":null,"effect":null,"exec":null,"params":[{"name":"endType","type":"String","optional":false,"default":null,"description":"can be a custom one Arma 3 v1.00, or one of:\n- \"CONTINUE\" (does nothing)\n- \"KILLED\"\n- \"LOSER\"\n- \"END1\"\n- \"END2\"\n- \"END3\"\n- \"END4\"\n- \"END5\"\n- \"END6\"","types":["String"],"since":null,"text":"endType: String - can be a custom one Arma 3 v1.00, or one of:\n- \"CONTINUE\" (does nothing)\n- \"KILLED\"\n- \"LOSER\"\n- \"END1\"\n- \"END2\"\n- \"END3\"\n- \"END4\"\n- \"END5\"\n- \"END6\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"endType","types":["String"]}}],"examples":[{"text":"```sqf\nendMission \"END1\";\n```","code":["endMission \"END1\";"]},{"text":"```sqf\n[\"END1\"] remoteExec [\"endMission\", 0, true]; // Arma 3\n```","code":["[\"END1\"] remoteExec [\"endMission\", 0, true]; // Arma 3"]}],"multiplayer":"To end mission properly so that everyone goes to debriefing at the same time, this command should be executed on every machine (see #Example 2).","problems":null,"aliases":[],"see_also":["missionEnd","failMission","forceEnd"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"engineOn","operator":null,"title":"engineOn","type":"command","url":"https://community.bistudio.com/wiki/engineOn","revid":337565,"updated":"2023-02-10T01:12:53Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Activates and deactivates the engine of a vehicle.","syntaxes":[{"syntax":"vehicle engineOn state","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to turn the engine on, false to turn it off","types":["Boolean"],"since":null,"text":"state: Boolean - true to turn the engine on, false to turn it off"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nif (!isEngineOn _jeep) then { _jeep engineOn true; };\n```","code":["if (!isEngineOn _jeep) then { _jeep engineOn true; };"]},{"text":"```sqf\nwaitUntil { player == driver _jeep; };\nvehicle player engineOn true;\n```","code":["waitUntil { player == driver _jeep; };\nvehicle player engineOn true;"]}],"multiplayer":"Executed on a remote vehicle this command may turn the engine on but then it will get turned off by itself after a short while.","problems":null,"aliases":[],"see_also":["isEngineOn"],"notes":[{"user":"Benargee","date":"2014-08-25T22:27:00Z","text":"To switch engine off can also use setFuel and fuel:\n\n```sqf\nprivate \"_gas\";\n_gas = fuel heli;\nheli setFuel 0;\nsleep 0.01;\nheli setFuel _gas;\n```\n\nAlso sets helicopter fuel back to original quantity. Works on every other vehicle."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.90","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"enginesIsOnRTD","operator":null,"title":"enginesIsOnRTD","type":"command","url":"https://community.bistudio.com/wiki/enginesIsOnRTD","revid":330055,"updated":"2022-08-15T16:03:50Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns which engines are producing some work.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"enginesIsOnRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Array of Booleans","types":["Array","Boolean"],"description":"value for each engine","text":"Array of Booleans - value for each engine"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_enginesTaru = enginesIsOnRTD _taru; // returns [true, true]\n```","code":["_enginesTaru = enginesIsOnRTD _taru; // returns [true, true]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectRTD","enginesRpmRTD","enginesTorqueRTD","wingsForcesRTD","engineOn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"enginesPowerRTD","operator":null,"title":"enginesPowerRTD","type":"command","url":"https://community.bistudio.com/wiki/enginesPowerRTD","revid":349357,"updated":"2023-11-08T15:35:08Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns power produced by engines in Watts.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"enginesPowerRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":"helicopter with advanced flight model enabled","types":["Object"],"since":null,"text":"RTD_helicopter: Object - helicopter with advanced flight model enabled"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"watts produced by the engines, to format [engine1, engine2]. Returns an empty array if Advanced Flight Model is disabled.","text":"Array of Numbers - watts produced by the engines, to format [engine1, engine2]. Returns an empty array if Advanced Flight Model is disabled."},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_array = enginesPowerRTD vehicle player;\n```","code":["_array = enginesPowerRTD vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"enginesRpmRTD","operator":null,"title":"enginesRpmRTD","type":"command","url":"https://community.bistudio.com/wiki/enginesRpmRTD","revid":377781,"updated":"2026-01-03T01:32:37Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all engines RPM.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"enginesRpmRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"ObjectRTD","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: ObjectRTD"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\nenginesRpmRTD RTD_helicopter params [\"_RPMEngine1\",\"_RPMEngine2\"];\n```","code":["enginesRpmRTD RTD_helicopter params [\"_RPMEngine1\",\"_RPMEngine2\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectRTD","enginesTorqueRTD","enginesIsOnRTD","airDensityRTD","weightRTD","wingsForcesRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"enginesTorqueRTD","operator":null,"title":"enginesTorqueRTD","type":"command","url":"https://community.bistudio.com/wiki/enginesTorqueRTD","revid":369605,"updated":"2024-09-26T20:38:08Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Torque produced by engines in **N·m** (Newton × meter).\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"enginesTorqueRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"torque per engine","text":"Array of Numbers - torque per engine"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_UH80_E1 = (enginesTorqueRTD _UH80) select 0; // engine 1 Torque\n_UH80_E2 = (enginesTorqueRTD _UH80) select 1; // engine 2 Torque\n```","code":["_UH80_E1 = (enginesTorqueRTD _UH80) select 0; // engine 1 Torque\n_UH80_E2 = (enginesTorqueRTD _UH80) select 1; // engine 2 Torque"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectRTD","enginesIsOnRTD","enginesRpmRTD","weightRTD","airDensityRTD","wingsForcesRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"entities","operator":null,"title":"entities","type":"command","url":"https://community.bistudio.com/wiki/entities","revid":377164,"updated":"2026-01-01T10:42:33Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all alive and dead entities of the given type or deriving from the given type. Units in vehicles are ignored with the primary syntax.\n\n> [!NOTE]\n> **Optimisation tip**: Keep number of types in both *includeTypes* and *excludeTypes* arrays to a minimum by possibly using parent/base classes.\n> If you have to use several types, arrange them in order so that the more common types go at the beginning of the array.","syntaxes":[{"syntax":"entities type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"if an empty string `\"\"` is provided, all entities are returned","types":["String"],"since":null,"text":"type: String - if an empty string `\"\"` is provided, all entities are returned"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}},{"syntax":"entities [typesInclude, typesExclude, includeCrews, excludeDead]","since":"arma3 1.66","effect":null,"exec":null,"params":[{"name":"typesInclude","type":"Array","optional":false,"default":null,"description":"in format [type1, type2, ...typeN], where type is a String. Empty array [] means include every entity. Method used for filtering - isKindOf","types":["Array"],"since":null,"text":"typesInclude: Array - in format [type1, type2, ...typeN], where type is a String. Empty array [] means include every entity. Method used for filtering - isKindOf"},{"name":"typesExclude","type":"Array","optional":false,"default":null,"description":"in format [type1, type2, ...typeN], where type is a String. Empty array [] means exclude no entity. Method used for filtering - isKindOf","types":["Array"],"since":null,"text":"typesExclude: Array - in format [type1, type2, ...typeN], where type is a String. Empty array [] means exclude no entity. Method used for filtering - isKindOf"},{"name":"includeCrews","type":"Boolean","optional":true,"default":"false","description":"include crews currently in vehicles","types":["Boolean"],"since":null,"text":"includeCrews: Boolean - (Optional, default false) include crews currently in vehicles"},{"name":"excludeDead","type":"Boolean","optional":true,"default":"false","description":"exclude dead entities","types":["Boolean"],"since":null,"text":"excludeDead: Boolean - (Optional, default false) exclude dead entities"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"[typesInclude, typesExclude, includeCrews, excludeDead]","types":["Array"]}}],"examples":[{"text":"```sqf\n_allCars = entities \"Car\";\n```","code":["_allCars = entities \"Car\";"]},{"text":"Return all alive entities on the map:\n\n```sqf\n_allAlive = entities [[], [], true, true];\n```","code":["_allAlive = entities [[], [], true, true];"]},{"text":"Return dead and alive entities but logic:\n\n```sqf\n_notLogic = entities [[], [\"Logic\"], true];\n```","code":["_notLogic = entities [[], [\"Logic\"], true];"]},{"text":"Return all alive west soldiers on foot:\n\n```sqf\n_footSoldiers = entities [[\"SoldierWB\"], [], false, true];\n```","code":["_footSoldiers = entities [[\"SoldierWB\"], [], false, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearEntities","allGroups","allUnits","units","vehicles","agents","playableUnits","switchableUnits","allPlayers","allDead","allDeadMen","allUnitsUAV","allCurators","allObjects","allMissionObjects","allSimpleObjects","allMines"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"environmentEnabled","operator":null,"title":"environmentEnabled","type":"command","url":"https://community.bistudio.com/wiki/environmentEnabled","revid":377680,"updated":"2026-01-02T09:02:45Z","groups":["Environment","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns status of enableEnvironment command","syntaxes":[{"syntax":"environmentEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [ambientLife, ambientSound, windyCoef]","types":["Array"],"description":"ambientLife: Boolean - ambientSound: Boolean - Arma 3 v2.12 windyCoef: Number - see enableEnvironment","text":"Array with [ambientLife, ambientSound, windyCoef]\n- ambientLife: Boolean\n- ambientSound: Boolean\n- Arma 3 v2.12 windyCoef: Number - see enableEnvironment"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _enabled = environmentEnabled;\n```","code":["private _enabled = environmentEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableEnvironment","fadeEnvironment","environmentVolume","initAmbientLife","sideAmbientLife","getAllEnvSoundControllers","getEnvSoundController","setSoundEffect"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Sounds","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"environmentVolume","operator":null,"title":"environmentVolume","type":"command","url":"https://community.bistudio.com/wiki/environmentVolume","revid":310239,"updated":"2022-05-05T13:11:01Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current environment volume (set by fadeEnvironment)","syntaxes":[{"syntax":"environmentVolume","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str environmentVolume;\n```","code":["hint str environmentVolume;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeEnvironment","musicVolume","soundVolume","radioVolume","speechVolume","getAudioOptionVolumes","environmentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"equipmentDisabled","operator":null,"title":"equipmentDisabled","type":"command","url":"https://community.bistudio.com/wiki/equipmentDisabled","revid":377613,"updated":"2026-01-02T08:51:39Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns current state for NVG and TI equipment availability.","syntaxes":[{"syntax":"equipmentDisabled vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array with [NVG, TI]","types":["Array"],"description":null,"text":"Array with [NVG, TI]"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nequipmentDisabled tank1 params [\"_nvg\", \"_ti\"];\n```","code":["equipmentDisabled tank1 params [\"_nvg\", \"_ti\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableNVGEquipment","disableTIEquipment"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"estimatedEndServerTime","operator":null,"title":"estimatedEndServerTime","type":"command","url":"https://community.bistudio.com/wiki/estimatedEndServerTime","revid":370564,"updated":"2025-01-08T22:11:23Z","groups":["Time","Mission Information","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Estimated end of MP game in seconds converted to serverTime.","syntaxes":[{"syntax":"estimatedEndServerTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"seconds left","text":"Number - seconds left"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Estimated minutes left:\n\n```sqf\n_min = ceil (estimatedEndServerTime - serverTime) / 60;\n```","code":["_min = ceil (estimatedEndServerTime - serverTime) / 60;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["estimatedTimeLeft","serverTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Multiplayer","Command Group: Time","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"estimatedTimeLeft","operator":null,"title":"estimatedTimeLeft","type":"command","url":"https://community.bistudio.com/wiki/estimatedTimeLeft","revid":370869,"updated":"2025-02-21T10:43:59Z","groups":["Time","Mission Information","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.35"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.35"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Sets the estimated time left in the game that is shown in the \"Game in progress\" screen or in the master browser.\n\n> [!NOTE]\n> This command will force the server to broadcast serverTime to all clients without waiting for the next broadcast window (usually every 5 minutes).","syntaxes":[{"syntax":"estimatedTimeLeft seconds","since":null,"effect":null,"exec":null,"params":[{"name":"seconds","type":"Number","optional":false,"default":null,"description":"estimated time in seconds, max 36000 (10 hours), 7200 (2 hours) before Arma 3 v1.70","types":["Number"],"since":null,"text":"seconds: Number - estimated time in seconds, max 36000 (10 hours), 7200 (2 hours) before Arma 3 v1.70"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"seconds","types":["Number"]}}],"examples":[{"text":"```sqf\nestimatedTimeLeft 600; // 10 min\n```","code":["estimatedTimeLeft 600; // 10 min"]},{"text":"**Operation Flashpoint:** for missions with a hard set limit adjusted via param1, the following example can be used in the init.sqs file:\n\n```sqs\nestimatedTimeLeft param1\n```","code":["estimatedTimeLeft param1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["estimatedEndServerTime","serverTime"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Multiplayer","Command Group: Time","Introduced with Operation Flashpoint version 1.35","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"evalObjectArgument","operator":null,"title":"evalObjectArgument","type":"command","url":"https://community.bistudio.com/wiki/evalObjectArgument","revid":376410,"updated":"2025-10-11T01:02:41Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return argument in mission editor of a given object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map evalObjectArgument [object, argument]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"},{"name":"argument","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"argument: String"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object, argument]","types":["Array"]}}],"examples":[{"text":"```sqf\n// returns string \"[1009.0351, 1319.4928]\"\n(findDisplay 128 displayCtrl 51) getObjectArgument [\"_unit_1\", \"POSITION\"];\n\n// returns array [1009.0351, 1319.4928]\n(findDisplay 128 displayCtrl 51) evalObjectArgument [\"_unit_1\", \"POSITION\"];\n```","code":["// returns string \"[1009.0351, 1319.4928]\"\n(findDisplay 128 displayCtrl 51) getObjectArgument [\"_unit_1\", \"POSITION\"];\n\n// returns array [1009.0351, 1319.4928]\n(findDisplay 128 displayCtrl 51) evalObjectArgument [\"_unit_1\", \"POSITION\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectArguments"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"everyBackpack","operator":null,"title":"everyBackpack","type":"command","url":"https://community.bistudio.com/wiki/everyBackpack","revid":376077,"updated":"2025-07-28T13:01:43Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of backpacks stored in given crate or vehicle. Used for accessing backpack content of a backpack on ground.","syntaxes":[{"syntax":"everyBackpack box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\neveryBackpack cursorTarget;\n```","code":["everyBackpack cursorTarget;"]},{"text":"```sqf\n_vehicleBackpacks = everyBackpack vehicle player;\n```","code":["_vehicleBackpacks = everyBackpack vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","backpackContainer","everyContainer","backpacks"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-29T17:09:00Z","text":"(Arma 3 ver 1.16), here's a quick reference to backpack command family.\n\n| Command | Operand type | Return | Example |\n|---|---|---|---|\n| firstBackpack | Object (WeaponHolder, AmmoCrate, VehicleCrate) | Object (e.g 2bba9d00# 163957: backpack_compact.p3d) | ```sqf<br>firstBackpack (getPos player nearestObject \"weaponholder\");<br>``` |\n| backpackContainer | Unit(Object) | Object (e.g 2bba9d00# 163957: backpack_compact.p3d) | ```sqf<br>backpackContainer player // currently same as [[unitBackpack]]<br>``` |\n| unitBackpack | Unit(Object) | Object (e.g 2bba9d00# 163957: backpack_compact.p3d) | ```sqf<br>unitBackpack player // currently same as [[backpackContainer]]<br>``` |\n| backpack | Unit(Object) | String (e.g 2bba9d00# 163957: backpack_compact.p3d) | ```sqf<br>backpack player // see also ([[typeOf]] [[backpackContainer]] [[player]]) or ([[typeOf]] [[unitBackpack]] [[player]])<br>``` |\n| backpackCargo | Object (WeaponHolder, AmmoCrate, VehicleCrate) | Array of String (e.g [\"Backpack0\", \"Backpack1\"]) | ```sqf<br>backpackCargo _ammoCrate<br>``` |\n| getBackpackCargo | Object (WeaponHolder, AmmoCrate, VehicleCrate) | Array of Array (e.g [[\"Backpack0\", \"Backpack1\"], [1, 1]]) | ```sqf<br>getBackpackCargo _ammoCrate<br>``` |\n| everyBackpack | Object (WeaponHolder, AmmoCrate, VehicleCrate) | Array of Object (e.g [22504f00# 163960: backpack_fast.p3d...]) | ```sqf<br>everyBackpack _ammoCrate<br>``` |"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"everyContainer","operator":null,"title":"everyContainer","type":"command","url":"https://community.bistudio.com/wiki/everyContainer","revid":378321,"updated":"2026-04-02T16:20:45Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of all containers (uniforms, vests, backpacks) stored in given crate or vehicle. Used for accessing containers content stored in ammo box or ground holder.","syntaxes":[{"syntax":"everyContainer object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"}],"returns":{"type":"Array of Arrays with [class, container]","types":["Array"],"description":"class: String - class name of the container - container: Object - container object","text":"Array of Arrays with [class, container]\n- class: String - class name of the container\n- container: Object - container object"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\neveryContainer cursorTarget;\n/*\n    returns e.g\n    [\n        [\"V_PlateCarrier1_rgr\",2bc06b00# 163955: dummyweapon.p3d],\n        [\"U_B_CombatUniform_mcam\",2bc07900# 163954: dummyweapon.p3d]\n    ]\n*/\n```","code":["everyContainer cursorTarget;\n/*\n\treturns e.g\n\t[\n\t\t[\"V_PlateCarrier1_rgr\",2bc06b00# 163955: dummyweapon.p3d],\n\t\t[\"U_B_CombatUniform_mcam\",2bc07900# 163954: dummyweapon.p3d]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["everyBackpack","uniformContainer","vestContainer","backpackContainer"],"notes":[{"user":"Yuval","date":"2017-07-20T12:07:00Z","text":"The returned array is in the following format:\n\n```sqf\n[\n    [containerClassname1, containerObject1],\n    [containerClassname2, containerObject2],\n    // ...\n    [containerClassnameN, containerObjectN]\n]\n```\n\nPlease do note that typeOf containerObjectN **does not** return containerClassnameN but rather the containerClass configured in config (usually \"supplyN\")"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"exec","operator":null,"title":"exec","type":"command","url":"https://community.bistudio.com/wiki/exec","revid":325305,"updated":"2022-07-10T22:55:34Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Execute a script using (the deprecated but still available) SQS Syntax. SQF Syntax (and execVM) is the most recent scripting language.\n\nThe magic variable _time used within the script contains the elapsed time in seconds since the script started.\n\n> [!NOTE]\n> To see the active SQS scripts currently in the scheduler, use diag_activeSQSScripts command.","syntaxes":[{"syntax":"argument exec script","since":null,"effect":null,"exec":null,"params":[{"name":"argument","type":"Anything","optional":false,"default":null,"description":"the argument passed to the script through the _this variable. To pass multiple arguments, use an Array.","types":["Anything"],"since":null,"text":"argument: Anything - the argument passed to the script through the _this variable. To pass multiple arguments, use an Array."},{"name":"script","type":"String","optional":false,"default":null,"description":"the file path to the script. It should be given relatively to the mission folder, campaign scripts subfolder or global scripts folder and is searched there in the same order.\nIf you refer to a script packed together with an addon, the path should look like this: \"\\ADDON_PBO_NAME\\script.sqs\" where ADDON_PBO_NAME is the name of the addon's PBO file without extension.","types":["String"],"since":null,"text":"script: String - the file path to the script. It should be given relatively to the mission folder, campaign scripts subfolder or global scripts folder and is searched there in the same order.\nIf you refer to a script packed together with an addon, the path should look like this: \"\\ADDON_PBO_NAME\\script.sqs\" where ADDON_PBO_NAME is the name of the addon's PBO file without extension."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"argument","types":["Anything"]},"right":{"text":"script","types":["String"]}}],"examples":[{"text":"```sqs\n[player, _jeep] exec \"getin.sqs\";\n```","code":["[player, _jeep] exec \"getin.sqs\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["execVM","call","spawn","execFSM"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"execEditorScript","operator":null,"title":"execEditorScript","type":"command","url":"https://community.bistudio.com/wiki/execEditorScript","revid":363286,"updated":"2024-03-26T10:51:56Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Execute an editor script for the specified object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map execEditorScript [object,script]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[object,script]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[object,script]: Array"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object,script]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map execEditorScript [\"_team_1\",\"create\"];\n```","code":["_map execEditorScript [\"_team_1\",\"create\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"execFSM","operator":null,"title":"execFSM","type":"command","url":"https://community.bistudio.com/wiki/execFSM","revid":363581,"updated":"2024-04-07T14:49:31Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Execute scripted FSM and return the FSM handle or 0 when failed. The FSM file is first searched in the mission folder, then in the campaign scripts folder and finally in the global scripts folder. Argument (if any) are available in `_this` variable inside FSM. Variables set inside FSMs can be read/modified externally, using setFSMVariable and getFSMVariable commands.\n\nThe return value is the FSM handle; it can be used to determine (via completedFSM) when the FSM has finished.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, the FSM handle is also available within the FSM through the `_thisFSM` variable.\n\nScripted FSMs are added into the scheduler just like exec scripts, execVM scripts and spawn scripts.\n\nTo see what FSMs are currently in the scheduler, use diag_activeMissionFSMs command.\n\n> [!IMPORTANT]\n> While the code placed into any of the sections of FSM cannot be suspended (canSuspend is false), the FSM itself is suspended every simulation between the state's `init` and `precondition` (exception is the **init state**). This is the only place where scripted FSM is suspended/resumed.\n> The usual difference between the state's `init` and `precondition` is 1 frame but if the scheduler is busy it can take longer. See FSM for more information about FSM's structure.","syntaxes":[{"syntax":"arguments execFSM fsmFilePath","since":null,"effect":null,"exec":null,"params":[{"name":"arguments","type":"Anything","optional":false,"default":null,"description":"arguments accessible as `_this` in the FSM","types":["Anything"],"since":null,"text":"arguments: Anything - arguments accessible as `_this` in the FSM"},{"name":"fsmFilePath","type":"String","optional":false,"default":null,"description":"file with FSM code","types":["String"],"since":null,"text":"fsmFilePath: String - file with FSM code"}],"returns":{"type":"Number","types":["Number"],"description":"FSM handle (also available as `_thisFSM` in the FSM)","text":"Number - FSM handle (also available as `_thisFSM` in the FSM)"},"form":"binary","operator":null,"left":{"text":"arguments","types":["Anything"]},"right":{"text":"fsmFilePath","types":["String"]}},{"syntax":"execFSM fsmFilePath","since":null,"effect":null,"exec":null,"params":[{"name":"fsmFilePath","type":"String","optional":false,"default":null,"description":"file with FSM code","types":["String"],"since":null,"text":"fsmFilePath: String - file with FSM code"}],"returns":{"type":"Number","types":["Number"],"description":"FSM handle (also available as `_thisFSM` in the FSM)","text":"Number - FSM handle (also available as `_thisFSM` in the FSM)"},"form":"unary","operator":null,"left":null,"right":{"text":"fsmFilePath","types":["String"]}},{"syntax":"arguments execFSM [fsmFilePath, allowTermination]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"arguments","type":"Anything","optional":false,"default":null,"description":"arguments accessible as `_this` in the FSM","types":["Anything"],"since":null,"text":"arguments: Anything - arguments accessible as `_this` in the FSM"},{"name":"fsmFilePath","type":"String","optional":false,"default":null,"description":"file with FSM code","types":["String"],"since":null,"text":"fsmFilePath: String - file with FSM code"},{"name":"allowTermination","type":"Boolean","optional":false,"default":null,"description":"true to allow FSM termination with terminate command. Optional, default false","types":["Boolean"],"since":null,"text":"allowTermination: Boolean - true to allow FSM termination with terminate command. Optional, default false"}],"returns":{"type":"Number","types":["Number"],"description":"FSM handle (also available as `_thisFSM` in the FSM)","text":"Number - FSM handle (also available as `_thisFSM` in the FSM)"},"form":"binary","operator":null,"left":{"text":"arguments","types":["Anything"]},"right":{"text":"[fsmFilePath, allowTermination]","types":["Array"]}},{"syntax":"execFSM [fsmFilePath, allowTermination]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"fsmFilePath","type":"String","optional":false,"default":null,"description":"file with FSM code","types":["String"],"since":null,"text":"fsmFilePath: String - file with FSM code"},{"name":"allowTermination","type":"Boolean","optional":false,"default":null,"description":"true to allow FSM termination with terminate command. Optional, default false","types":["Boolean"],"since":null,"text":"allowTermination: Boolean - true to allow FSM termination with terminate command. Optional, default false"}],"returns":{"type":"Number","types":["Number"],"description":"FSM handle (also available as `_thisFSM` in the FSM)","text":"Number - FSM handle (also available as `_thisFSM` in the FSM)"},"form":"unary","operator":null,"left":null,"right":{"text":"[fsmFilePath, allowTermination]","types":["Array"]}}],"examples":[{"text":"```sqf\n_id = player execFSM \"test.fsm\";\n```","code":["_id = player execFSM \"test.fsm\";"]},{"text":"```sqf\n_handle = [_a, _b, _c] execFSM \"test.fsm\";\n```","code":["_handle = [_a, _b, _c] execFSM \"test.fsm\";"]},{"text":"```sqf\n_handle = execFSM \"test.fsm\";\n```","code":["_handle = execFSM \"test.fsm\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","FSM Editor Manual","execVM","call","spawn","exec","commandFSM","completedFSM","doFSM","getFSMVariable","setFSMVariable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"execVM","operator":null,"title":"execVM","type":"command","url":"https://community.bistudio.com/wiki/execVM","revid":336954,"updated":"2023-01-04T16:44:15Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Compiles and adds an SQF script to the scheduler queue and returns script handle (see also #Example 4).\nThe script does not execute immediately upon running execVM command but with some delay depending on the VM's scripts queue and engine load.\n\n> [!NOTE]\n> - If the same script is to be executed more than one time, declaring it as a Function is recommended to avoid recompiling and wasting performance with every execution.\n> - The script is searched for in the following directories in that order:\n>   - mission directory\n>   - campaign scripts directory\n>   - global scripts directory.\n> - To see what VM scripts are currently in the scheduler, use diag_activeSQFScripts command.\n\n> [!IMPORTANT]\n> - The `.sqf` file extension is not mandatory but is strongly recommended as using non-standard extensions may cause problems during binarisation\n> - If the script file is not prepared using UTF-8 encoding and contains some characters with codes > 127, they might convert incorrectly.","syntaxes":[{"syntax":"arguments execVM filename","since":null,"effect":null,"exec":null,"params":[{"name":"arguments","type":"Anything","optional":false,"default":null,"description":"arguments accessible as `_this` in the script","types":["Anything"],"since":null,"text":"arguments: Anything - arguments accessible as `_this` in the script"},{"name":"filename","type":"String","optional":false,"default":null,"description":"path to the SQF script file","types":["String"],"since":null,"text":"filename: String - path to the SQF script file"}],"returns":{"type":"Script Handle","types":["Script Handle"],"description":null,"text":"Script Handle"},"form":"binary","operator":null,"left":{"text":"arguments","types":["Anything"]},"right":{"text":"filename","types":["String"]}},{"syntax":"execVM filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":"path to the SQF script file","types":["String"],"since":null,"text":"filename: String - path to the SQF script file"}],"returns":{"type":"Script Handle","types":["Script Handle"],"description":null,"text":"Script Handle"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\nexecVM \"test.sqf\";\n```","code":["execVM \"test.sqf\";"]},{"text":"```sqf\n_handle = player execVM \"test.sqf\";\nwaitUntil { scriptDone _handle };\n```\n\nThe following is also possible in Arma 3:\n\n```sqf\nprivate _handle = execVM \"123.sqf\";\nwaitUntil { isNull _handle };\n```","code":["_handle = player execVM \"test.sqf\";\nwaitUntil { scriptDone _handle };","private _handle = execVM \"123.sqf\";\nwaitUntil { isNull _handle };"]},{"text":"```sqf\n[player, 0.75] execVM \"setDamage.sqf\";\n```\n\nsetDamage.sqf:\n\n```sqf\nparams [\"_unit\", \"_damage\"];\n_unit setDamage _damage;\n```","code":["[player, 0.75] execVM \"setDamage.sqf\";","params [\"_unit\", \"_damage\"];\n_unit setDamage _damage;"]},{"text":"execVM equivalence:\n\n```sqf\nprivate _handle = _args execVM \"someFile.sqf\";\n// is practically identical to\nprivate _handle = _args spawn compile preprocessFileLineNumbers \"someFile.sqf\";\n```","code":["private _handle = _args execVM \"someFile.sqf\";\n// is practically identical to\nprivate _handle = _args spawn compile preprocessFileLineNumbers \"someFile.sqf\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["call","spawn","exec","execFSM","scriptDone","scriptNull","terminate","sleep","uiSleep","waitUntil","canSuspend","diag_activeScripts","diag_activeSQFScripts","SQF Syntax","Control Structures"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"exit","operator":null,"title":"exit","type":"command","url":"https://community.bistudio.com/wiki/exit","revid":329489,"updated":"2022-07-29T12:29:43Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Stops the execution of a SQS script.\n\nIt is ignored in SQF Scripts.","syntaxes":[{"syntax":"exit","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"SQS Syntax:\n\n```sqs\n? not alive player : exit\n```","code":["? not alive player : exit"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["exitWith","Control Structures"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"exitWith","operator":null,"title":"exitWith","type":"command","url":"https://community.bistudio.com/wiki/exitWith","revid":369326,"updated":"2024-09-03T18:42:59Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Exits the **current** code scope. Often used for exiting do, for, count, forEach or the whole script.\n\n> [!NOTE]\n> See Variables#Local Variables Scope for more information.","syntaxes":[{"syntax":"ifType exitWith code","since":null,"effect":null,"exec":null,"params":[{"name":"ifType","type":"If Type","optional":false,"default":null,"description":null,"types":["If Type"],"since":null,"text":"ifType: If Type"},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"ifType","types":["If Type"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nsystemChat \"start\";\nprivate _condition = true;\n\nif (_condition) then\n{\n    if (true) exitWith\n    {\n        systemChat \"exiting if _condition scope\";\n    };\n    systemChat \"never shown\";\n};\n\nsystemChat \"exiting #1 worked\";\n\nif (true) exitWith\n{\n    systemChat \"exiting the main scope = leaving the whole script\";\n};\n\nsystemChat \"never shown - the script has already ended\";\n```","code":["systemChat \"start\";\nprivate _condition = true;\n\nif (_condition) then\n{\n\tif (true) exitWith\n\t{\n\t\tsystemChat \"exiting if _condition scope\";\n\t};\n\tsystemChat \"never shown\";\n};\n\nsystemChat \"exiting #1 worked\";\n\nif (true) exitWith\n{\n\tsystemChat \"exiting the main scope = leaving the whole script\";\n};\n\nsystemChat \"never shown - the script has already ended\";"]},{"text":"```sqf\nfor \"_j\" from 1 to 10 do\n{\n    systemChat format [\"%1\", _j];\n\n    // the for loop will cease and code execution will continue after the end of the loop\n    if (_j == 5) exitWith\n    {\n        systemChat \"5 is enough\";\n    };\n};\nsystemChat \"Complete\";\n```","code":["for \"_j\" from 1 to 10 do\n{\n\tsystemChat format [\"%1\", _j];\n\n\t// the for loop will cease and code execution will continue after the end of the loop\n\tif (_j == 5) exitWith\n\t{\n\t\tsystemChat \"5 is enough\";\n\t};\n};\nsystemChat \"Complete\";"]},{"text":"Most loops will also terminate when their scope is exited. To exit and terminate scopes which are called every frame such as onEachFrame and waitUntil use the following examples:\n\n```sqf\nonEachFrame {\n    if (!alive player) exitWith\n    {\n        onEachFrame {};\n    };\n};\n```\n\n```sqf\n_time = time + 10;\nwaitUntil \n{\n    if (time > _time) exitWith { true };\n    false\n};\n```","code":["onEachFrame {\n\tif (!alive player) exitWith\n\t{\n\t\tonEachFrame {};\n\t};\n};","_time = time + 10;\nwaitUntil \n{\n\tif (time > _time) exitWith { true };\n\tfalse\n};"]},{"text":"```sqf\nwhile { true } do\n{\n    if (alive player) then\n    {\n        if (time > 300) exitWith // [wrong] - it will only leave the \"if alive player\" scope, remaining in the \"while true\" loop forever\n        {\n            hint \"exiting\";\n        };\n    };\n};\n```","code":["while { true } do\n{\n\tif (alive player) then\n\t{\n\t\tif (time > 300) exitWith // [wrong] - it will only leave the \"if alive player\" scope, remaining in the \"while true\" loop forever\n\t\t{\n\t\t\thint \"exiting\";\n\t\t};\n\t};\n};"]},{"text":"```sqf\nif (_condition) exitWith\n{\n    hint \"reached\";\n};\n// else { hint \"not reached\" }; // [wrong] - using else does not work and makes no sense here\n```\n\n```sqf\nif (_condition) exitWith\n{\n    hint \"reached\";\n};\nhint \"not reached\"; // [correct] - if _condition is met, the scope has already been exited by now\n```","code":["if (_condition) exitWith\n{\n\thint \"reached\";\n};\n// else { hint \"not reached\" }; // [wrong] - using else does not work and makes no sense here","if (_condition) exitWith\n{\n\thint \"reached\";\n};\nhint \"not reached\"; // [correct] - if _condition is met, the scope has already been exited by now"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["scopeName","breakOut","breakTo","else","Control Structures","then","assert","try","catch","throw"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"exp","operator":null,"title":"exp","type":"command","url":"https://community.bistudio.com/wiki/exp","revid":338163,"updated":"2023-02-23T23:48:34Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Exponential function with the base [e](https://en.wikipedia.org/wiki/E_(mathematical_constant)). Equal to `e^x`.","syntaxes":[{"syntax":"exp x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_e = exp 1; // Returns e (2.7182...)\n```","code":["_e = exp 1; // Returns e (2.7182...)"]},{"text":"```sqf\nln exp 1; // Returns 1\n```","code":["ln exp 1; // Returns 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands"],"notes":[{"user":"Franze","date":"2009-03-03T22:04:00Z","text":"Note that you cannot exponent a value greater than 88.72283554077147726999 (999 repeating), as this is beyond what the game can calculate."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"expectedDestination","operator":null,"title":"expectedDestination","type":"command","url":"https://community.bistudio.com/wiki/expectedDestination","revid":377689,"updated":"2026-01-02T09:03:08Z","groups":["Unit Control","AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Return expected destination of unit as an array.","syntaxes":[{"syntax":"expectedDestination person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Array with [destination, planningMode, forceReplan]","types":["Array"],"description":"destination: PositionAGL - planningMode: String - can be one of: - \"DoNotPlan\" - used when not moving - \"DoNotPlanFormation\" - used in formation when simple path testing is used - \"LEADER PLANNED\" - used for formation leader (full path finding used) - \"LEADER DIRECT\" - used for DirectGo (like getin, supply) - \"FORMATION PLANNED\" - used in formation when full path finding is used - \"VEHICLE PLANNED\" - used for vehicle driver - forceReplan: Boolean - specifies if path replanning was forced (through setDestination)","text":"Array with [destination, planningMode, forceReplan]\n- destination: PositionAGL\n- planningMode: String - can be one of:\n  - \"DoNotPlan\" - used when not moving\n  - \"DoNotPlanFormation\" - used in formation when simple path testing is used\n  - \"LEADER PLANNED\" - used for formation leader (full path finding used)\n  - \"LEADER DIRECT\" - used for DirectGo (like getin, supply)\n  - \"FORMATION PLANNED\" - used in formation when full path finding is used\n  - \"VEHICLE PLANNED\" - used for vehicle driver\n- forceReplan: Boolean -  specifies if path replanning was forced (through setDestination)"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_data = expectedDestination player;\n```","code":["_data = expectedDestination player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDestination","getUnitState"],"notes":[{"user":"Donnervogel","date":"2007-03-03T16:24:00Z","text":"For AI units I have found the following values: *planningMode* is \"LEADER PLANNED\" when the unit is ordered by the group leader to go somewhere or if the unit is the group leader and it follows a waypoint. Otherwise *planningMode* it is \"DoNotPlan\". Units moving in formation have \"DoNotPlan\" as long as they don't receive orders by the group leader. Units also have \"DoNotPlan\" when they don't move. Units executing special formation tasks like engaging or return to formation have \"FORMATION PLANNED\" as long they have not fulfilled the task."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"exportJIPMessages","operator":null,"title":"exportJIPMessages","type":"command","url":"https://community.bistudio.com/wiki/exportJIPMessages","revid":370220,"updated":"2024-11-10T18:07:35Z","groups":["Diagnostic","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a log file containing an overview on all JIP (network) messages currently in the JIP queue.\nThe file is created in the same directory as .rpt file.\n\n> [!NOTE]\n> BattlEye's RCON variant of this command is `1. exportJIPqueue` (see also Multiplayer Server Commands).\n\nFile name examples:\n- `jipqueue_12024_2024-10-25_11-31-11.log` (using `1. exportJIPqueue` chat command)\n- `jipqueue-12024-2024-10-25_11-31-11.fileNameParameter.log` (using exportJIPMessages sqf command)\nFile content example:\n\n```\ntime = 78814.063\n\n==================================================================================================\nObjects: \n---------------------------------------------------------------------------------------------\n    Type_96 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_107 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_109 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_113 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_118 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Unknown creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_332 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_334 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_198 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Unknown creator:4 networkId:0 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_332 creator:4 networkId:1 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_334 creator:4 networkId:2 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_96 creator:2 networkId:ID - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_109 creator:2 networkId:ID - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_113 creator:2 networkId:ID - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_118 creator:2 networkId:ID - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_195 creator:2 networkId:ID - owner __SERVER__ (2)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:3 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:4 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:5 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:6 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:7 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_99 creator:4 networkId:8 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_96 creator:4 networkId:12 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_96 creator:4 networkId:13 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_96 creator:4 networkId:15 - owner NAME (1c7f3773)\n---------------------------------------------------------------------------------------------\n    Type_96 creator:4 networkId:49 - owner NAME (1c7f3773)\n\n==================================================================================================\n_initMessages - Total: 7601\n                Type_330 :     4\n                 Type_60 :     6\n                Type_272 :    31\n                Type_273 :    31\n                Type_274 :  4481\n                 Type_64 :   435\n                Type_291 :   147\n                Type_292 :     1\n                Type_187 :    50\n                Type_248 :  1846\n                 Type_53 :    70\n                 Type_54 :   341\n                Type_294 :     3\n                 Type_10 :    69\n                Type_385 :     1\n                Type_295 :     1\n                Type_296 :    16\n                Type_328 :     4\n                Type_329 :     4\n                 Type_59 :    60\n\n==================================================================================================\n_initMessagesRE - Total: 0\n\n==================================================================================================\n_jipMarkerInfos - Total: 0\n```","syntaxes":[{"syntax":"exportJIPMessages fileName","since":null,"effect":null,"exec":null,"params":[{"name":"fileName","type":"String","optional":false,"default":null,"description":"file where to store the list","types":["String"],"since":null,"text":"fileName: String - file where to store the list"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\nexportJIPMessages \"myFileNameWithoutExtension\";\n```","code":["exportJIPMessages \"myFileNameWithoutExtension\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["didJIP","didJIPOwner","logEntities","diag_captureFrame"],"notes":[{"user":"Demellion","date":"2019-10-16T19:31:00Z","text":"*Note: this may have only applied to earlier versions of the game; as of Arma 3 v2.18 no such problems are reported.*\n\nExporting JIP might crash a populated server. This doesn't seem to be exactly related to amount of data to export, since results don't vary much against unpopulated server."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"exportLandscapeXYZ","operator":null,"title":"exportLandscapeXYZ","type":"command","url":"https://community.bistudio.com/wiki/exportLandscapeXYZ","revid":352124,"updated":"2024-02-01T23:25:06Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Exports landscape as XYZ file.\n\n> [!WARNING]\n> Not available in Retail Version!","syntaxes":[{"syntax":"exportLandscapeXYZ filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"filename: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\nexportLandscapeXYZ \"myLandscape.txt\";\n```","code":["exportLandscapeXYZ \"myLandscape.txt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"eyeDirection","operator":null,"title":"eyeDirection","type":"command","url":"https://community.bistudio.com/wiki/eyeDirection","revid":377870,"updated":"2026-01-04T11:39:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the direction object is watching (eyes, or a vehicle's primary observer).","syntaxes":[{"syntax":"eyeDirection unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"Keep a can in front of the player's *face*:\n\n```sqf\nCan = \"Land_Can_V3_F\" createVehicle getPosATL player;\nonEachFrame {\n    _eyePos = eyePos player;\n    _eyeDir = eyeDirection player;\n    Can setPosASL [\n        _eyePos select 0 + (_eyeDir select 0),\n        _eyePos select 1 + (_eyeDir select 1),\n        _eyePos select 2 + (_eyeDir select 2)\n    ]\n};\n```","code":["Can = \"Land_Can_V3_F\" createVehicle getPosATL player;\nonEachFrame {\n\t_eyePos = eyePos player;\n\t_eyeDir = eyeDirection player;\n\tCan setPosASL [\n\t\t_eyePos select 0 + (_eyeDir select 0),\n\t\t_eyePos select 1 + (_eyeDir select 1),\n\t\t_eyePos select 2 + (_eyeDir select 2)\n\t]\n};"]},{"text":"Draw AI eye direction (green) and weapon direction (red) in 3D:\n\n```sqf\nBob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nBob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame {\n    _beg = ASLToAGL eyePos Bob;\n\n    _endE = _beg vectorAdd (eyeDirection Bob vectorMultiply 100);\n    drawLine3D [_beg, _endE, [0,1,0,1]];\n\n    _endW = _beg vectorAdd (Bob weaponDirection currentWeapon Bob vectorMultiply 100);\n    drawLine3D [_beg, _endW, [1,0,0,1]];\n};\n```","code":["Bob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nBob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame {\n\t_beg = ASLToAGL eyePos Bob;\n\n\t_endE = _beg vectorAdd (eyeDirection Bob vectorMultiply 100);\n\tdrawLine3D [_beg, _endE, [0,1,0,1]];\n\n\t_endW = _beg vectorAdd (Bob weaponDirection currentWeapon Bob vectorMultiply 100);\n\tdrawLine3D [_beg, _endW, [1,0,0,1]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["positionCameraToWorld","weaponDirection","getCameraViewDirection","vectorDir","vectorDirVisual"],"notes":[{"user":"Killzone_Kid","date":"2014-05-26T19:10:00Z","text":"This command should have really been named *headDirection* instead of eyeDirection as one could mistakenly think that eyes direction of your avatar correspond to the direction of the centre of your screen.\nPlay with the script in #Example 1 to find out limitations. If you need centre of screen direction, use positionCameraToWorld instead."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"eyePos","operator":null,"title":"eyePos","type":"command","url":"https://community.bistudio.com/wiki/eyePos","revid":377435,"updated":"2026-01-02T06:46:41Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the object's eyes / main turret position.","syntaxes":[{"syntax":"eyePos object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_eyesPos = eyePos player;\n```","code":["_eyesPos = eyePos player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["eyeDirection","getPosASL","setPosASL","setPosASL2","getCameraViewDirection","positionCameraToWorld"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"face","operator":null,"title":"face","type":"command","url":"https://community.bistudio.com/wiki/face","revid":364911,"updated":"2024-06-30T09:08:15Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the face class of a person as it is written in 'CfgFaces'.","syntaxes":[{"syntax":"face person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nface player;\n```","code":["face player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFace","setIdentity","setSpeaker","hasCustomFace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands"]},{"name":"faction","operator":null,"title":"faction","type":"command","url":"https://community.bistudio.com/wiki/faction","revid":370764,"updated":"2025-02-10T08:05:51Z","groups":["Object Manipulation","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets unit faction. Factions were introduced in Arma 2 and are defined under *CfgFactionClasses*.\n\n| Side | Arma 2 v1.00 | Arma 2: Operation Arrowhead v1.50 | Arma 3 v1.96 |\n|---|---|---|---|\n| west/blufor | - `USMC`<br>- `CDF` | - `BIS_US`<br>- `BIS_CZ`<br>- `BIS_GER`<br>- `BIS_BAF` (BAF DLC) | - `BLU_F` (NATO)<br>- `BLU_G_F` (FIA)<br>- `BLU_T_F` (Pacific NATO, Apex Expansion)<br>- `BLU_CTRG_F` (Pacific CTRG, Apex Expansion)<br>- `BLU_GEN_F` (Gendarmerie, Apex Expansion)<br>- `BLU_W_F` (Woodland NATO, Contact Expansion) |\n| east/opfor | - `INS` (ChDKZ)<br>- `RU` (Russia) | - `BIS_TK` (Takistan army)<br>- `BIS_TK_INS` (TK insurgents) | - `OPF_F` (Iranian CSAT)<br>- `OPF_G_F` (FIA)<br>- `OPF_T_F` (Chinese CSAT, Apex Expansion)<br>- `OPF_R_F` (Spetznatz, Contact Expansion) |\n| resistance/<br>independent | - `GUE` (Guerilla) | - `BIS_TK_GUE`<br>- `BIS_UN` (United Nations)<br>- `PMC_BAF` (PMC DLC) | - `IND_F` (AAF)<br>- `IND_G_F` (FIA)<br>- `IND_C_F` (Syndikat, Apex Expansion)<br>- `IND_E_F` (LDF, Contact Expansion)<br>- `IND_L_F` (Looters, Contact Expansion) |\n| civilian | - `CIV`<br>- `CIV_RU` | - `BIS_TK_CIV`<br>- `BIS_CIV_special` | - `CIV_F`<br>- `CIV_IDAP_F` (Laws of War DLC) |\n\n> [!NOTE]\n> If a unit's faction is not defined in its config, an empty string is returned.","syntaxes":[{"syntax":"faction unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _playerFaction = faction player;\n```","code":["private _playerFaction = faction player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["side","Side"],"notes":[{"user":"Tankbuster","date":"2010-03-19T16:56:00Z","text":"Faction behaves slightly differently to side. Side can refer to the pilot or commander of a vehicle, but faction never changes. It always returns the 'country of manufacture'."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Sides","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fadeEnvironment","operator":null,"title":"fadeEnvironment","type":"command","url":"https://community.bistudio.com/wiki/fadeEnvironment","revid":338929,"updated":"2023-04-17T15:30:39Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the master environment volume smoothly within the given time and is different from enableEnvironment global mute option. The default volume is 1.\n\nInfluenced sounds, among others, are:\n- forest sounds (birds, crickets, ...)\n- waves\n- wind\n- rain\n- object sounds (air conditioners, ...)\n- Arma 3 v2.06 thunder","syntaxes":[{"syntax":"time fadeEnvironment volume","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"fade interval in seconds","types":["Number"],"since":null,"text":"time: Number - fade interval in seconds"},{"name":"volume","type":"Number","optional":false,"default":null,"description":"speech volume in range 0..1","types":["Number"],"since":null,"text":"volume: Number - speech volume in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n5 fadeEnvironment 0.1;\n```","code":["5 fadeEnvironment 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["environmentVolume","fadeSpeech","fadeRadio","fadeSound","fadeMusic","soundVolume","musicVolume","radioVolume","speechVolume","enableEnvironment","environmentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"fadeMusic","operator":null,"title":"fadeMusic","type":"command","url":"https://community.bistudio.com/wiki/fadeMusic","revid":376977,"updated":"2026-01-01T06:06:52Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the current music volume to the given value smoothly within the given time. \n\n> [!NOTE]\n> The player's in-game setting is not changed by this command: `Final Volume = Client Setting * Scripted Volume`.","syntaxes":[{"syntax":"time fadeMusic volume","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"fade interval in seconds","types":["Number"],"since":null,"text":"time: Number - fade interval in seconds"},{"name":"volume","type":"Number in range 0..5","optional":false,"default":null,"description":"music volume","types":["Number"],"since":null,"text":"volume: Number in range 0..5 - music volume"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n5 fadeMusic 0; // fade current music volume to 0 in 5 sec\n```","code":["5 fadeMusic 0; // fade current music volume to 0 in 5 sec"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeSound","fadeRadio","fadeSpeech","fadeEnvironment","environmentVolume","musicVolume","soundVolume","radioVolume"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"fadeRadio","operator":null,"title":"fadeRadio","type":"command","url":"https://community.bistudio.com/wiki/fadeRadio","revid":376968,"updated":"2026-01-01T05:59:29Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the radio volume smoothly within the given time. \n\n> [!NOTE]\n> The player's in-game setting is not changed by this command: `Final Volume = Client Setting * Scripted Volume`.","syntaxes":[{"syntax":"time fadeRadio volume","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"fade interval in seconds","types":["Number"],"since":null,"text":"time: Number - fade interval in seconds"},{"name":"volume","type":"Number in range 0..2","optional":false,"default":null,"description":"radio volume","types":["Number"],"since":null,"text":"volume: Number in range 0..2 - radio volume"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n5 fadeRadio 0.1;\n```","code":["5 fadeRadio 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeSound","fadeMusic","fadeSpeech","fadeEnvironment","environmentVolume","radioVolume","soundVolume","musicVolume"],"notes":[{"user":"Beita","date":"2008-09-11T17:17:00Z","text":"Does not affect VoN."},{"user":"Fusselwurm","date":"2016-09-13T15:52:00Z","text":"Also influences audibility of the missile warning in helicopters."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"fadeSound","operator":null,"title":"fadeSound","type":"command","url":"https://community.bistudio.com/wiki/fadeSound","revid":376964,"updated":"2026-01-01T05:56:16Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the sound volume smoothly within the given time. \n\n> [!NOTE]\n> The player's in-game setting is not changed by this command: `Final Volume = Client Setting * Scripted Volume`.","syntaxes":[{"syntax":"time fadeSound volume","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"fade interval in seconds","types":["Number"],"since":null,"text":"time: Number - fade interval in seconds"},{"name":"volume","type":"Number in range 0..1","optional":false,"default":null,"description":"sound volume","types":["Number"],"since":null,"text":"volume: Number in range 0..1 - sound volume"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n5 fadeSound 0;\n```","code":["5 fadeSound 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeRadio","fadeSpeech","fadeMusic","fadeEnvironment","environmentVolume","soundVolume","musicVolume","radioVolume"],"notes":[{"user":"Lou Montana","date":"2010-01-19T13:16:00Z","text":"This command doesn't work, in **Arma 2 1.05**."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"fadeSpeech","operator":null,"title":"fadeSpeech","type":"command","url":"https://community.bistudio.com/wiki/fadeSpeech","revid":376969,"updated":"2026-01-01T05:59:43Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the master speech volume smoothly within the given time. The default volume is 1.0. Some of the sounds that play through speech channel are:\n- Tactical Ping sound\n- playSound when *isSpeech* argument is true\n- say3D when *isSpeech* argument is true","syntaxes":[{"syntax":"time fadeSpeech volume","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"fade interval in seconds","types":["Number"],"since":null,"text":"time: Number - fade interval in seconds"},{"name":"volume","type":"Number in range 0..2","optional":false,"default":null,"description":"speech volume","types":["Number"],"since":null,"text":"volume: Number in range 0..2 - speech volume"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n5 fadeSpeech 0.1;\n```","code":["5 fadeSpeech 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["speechVolume","fadeRadio","fadeSound","fadeMusic","fadeEnvironment","environmentVolume","soundVolume","musicVolume","radioVolume"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"failMission","operator":null,"title":"failMission","type":"command","url":"https://community.bistudio.com/wiki/failMission","revid":363258,"updated":"2024-03-26T10:51:31Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Finish the mission. If the server is set to run persistent mission, failMission will not end the mission when last player gets kicked to the lobby. Use endMission to end the mission.\n\nThe end type can be:\n- \"CONTINUE\" - this is default type, basically an alias to do nothing\n- \"KILLED\"\n- \"LOSER\"\n- \"END1\"\n- \"END2\"\n- \"END3\"\n- \"END4\"\n- \"END5\"\n- \"END6\"\n\n**Mission saves won't be deleted**.\n\n> [!NOTE]\n> **Arma 3:** To maintain Arma 3 visual style, it is recommended to use BIS_fnc_endMission instead.","syntaxes":[{"syntax":"failMission endtype","since":null,"effect":null,"exec":null,"params":[{"name":"endtype","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"endtype: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"endtype","types":["String"]}}],"examples":[{"text":"```sqf\nfailMission \"LOSER\";\n```","code":["failMission \"LOSER\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionEnd","endMission","forceEnd"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"false","operator":null,"title":"false","type":"command","url":"https://community.bistudio.com/wiki/false","revid":321031,"updated":"2022-05-13T11:41:32Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Always false.","syntaxes":[{"syntax":"false","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_var = false;\nsystemChat str _var; // false\n```","code":["_var = false;\nsystemChat str _var; // false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["true"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fileExists","operator":null,"title":"fileExists","type":"command","url":"https://community.bistudio.com/wiki/fileExists","revid":352073,"updated":"2024-02-01T23:24:41Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if file on given path exists. Uses same path resolve code as loadFile.\n\n> [!NOTE]\n> Absolute paths are not supported, such as those generated using getMissionPath. Attempting to check an absolute path will result in this error in RPT logs:\n> `Invalid path (only relative paths supported): 'C:\\...'`","syntaxes":[{"syntax":"fileExists path","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"path to file","types":["String"],"since":null,"text":"path: String - path to file"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if it exists, otherwise false","text":"Boolean - true if it exists, otherwise false"},"form":"unary","operator":null,"left":null,"right":{"text":"path","types":["String"]}}],"examples":[{"text":"```sqf\nfileExists \"\\a3\\mySuperPath\\bestFileEver.paa\"; // returns false\n```","code":["fileExists \"\\a3\\mySuperPath\\bestFileEver.paa\"; // returns false"]},{"text":"```sqf\nprivate _path = \"a3\\functions_f_mp_mark\\revive\\_addaction_revive.inc\";\nif (fileExists _path) then { loadFile _path } else { diag_log format [\"File (%1) does not exist!\", _path] };\n```","code":["private _path = \"a3\\functions_f_mp_mark\\revive\\_addaction_revive.inc\";\nif (fileExists _path) then { loadFile _path } else { diag_log format [\"File (%1) does not exist!\", _path] };"]},{"text":"```sqf\n// Sometimes it might be better to check if a file exists instead of checking if path is empty (\"\")\nprivate _class = \"ModuleObjectiveRaceFinish_F\";\nprivate _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"editorPreview\");\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"portrait\") };\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"icon\") };\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"picture\") };\nif !(fileExists _picture) then { systemChat \"No valid picture found!\" } else { systemChat _picture };\n```","code":["// Sometimes it might be better to check if a file exists instead of checking if path is empty (\"\")\nprivate _class = \"ModuleObjectiveRaceFinish_F\";\nprivate _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"editorPreview\");\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"portrait\") };\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"icon\") };\nif !(fileExists _picture) then { _picture = getText (configFile >> \"CfgVehicles\" >> _class >> \"picture\") };\nif !(fileExists _picture) then { systemChat \"No valid picture found!\" } else { systemChat _picture };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadFile","preprocessFile","preprocessFileLineNumbers"],"notes":[{"user":"Leopard20","date":"2022-01-01T16:29:30Z","text":"Returns true for empty strings: `fileExists \"\"; // true`"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"fillWeaponsFromPool","operator":null,"title":"fillWeaponsFromPool","type":"command","url":"https://community.bistudio.com/wiki/fillWeaponsFromPool","revid":309937,"updated":"2022-05-05T12:16:59Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds magazines from the campaign pool to the given unit, depending on his weapons. Available in campaigns only.","syntaxes":[{"syntax":"fillWeaponsFromPool unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nfillWeaponsFromPool _soldier;\n```","code":["fillWeaponsFromPool _soldier;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponPool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"find","operator":null,"title":"find","type":"command","url":"https://community.bistudio.com/wiki/find","revid":376413,"updated":"2025-10-11T01:04:47Z","groups":["Strings","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"ofp","name":"Operation Flashpoint","version":"1.99"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Searches for an array element within an array or an ANSI string within an ANSI string.\n\n> [!NOTE]\n> **Arma 3:** If Unicode support is desired, see forceUnicode.\n\n> [!IMPORTANT]\n> Search is cASe-seNsItiVE!","syntaxes":[{"syntax":"array find element","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array","optional":false,"default":null,"description":"array to search in","types":["Array"],"since":null,"text":"array: Array - array to search in"},{"name":"element","type":"Anything","optional":false,"default":null,"description":"array element to find","types":["Anything"],"since":null,"text":"element: Anything - array element to find"}],"returns":{"type":"Number","types":["Number"],"description":"zero-based position of the first array element that matches x, -1 if not found","text":"Number - zero-based position of the first array element that matches x, -1 if not found"},"form":"binary","operator":null,"left":{"text":"array","types":["Array"]},"right":{"text":"element","types":["Anything"]}},{"syntax":"string find substring","since":"arma3 1.28","effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to search in","types":["String"],"since":null,"text":"string: String - string to search in"},{"name":"substring","type":"String","optional":false,"default":null,"description":"substring to find","types":["String"],"since":null,"text":"substring: String - substring to find"}],"returns":{"type":"Number","types":["Number"],"description":"zero-based position of the first sequence of characters that matches substring, -1 if not found","text":"Number - zero-based position of the first sequence of characters that matches substring, -1 if not found"},"form":"binary","operator":null,"left":{"text":"string","types":["String"]},"right":{"text":"substring","types":["String"]}},{"syntax":"string find [substring, indexStart]","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to search in","types":["String"],"since":null,"text":"string: String - string to search in"},{"name":"substring","type":"String","optional":false,"default":null,"description":"substring to find","types":["String"],"since":null,"text":"substring: String - substring to find"},{"name":"indexStart","type":"Number","optional":false,"default":null,"description":"zero-based index which defines where find starts from","types":["Number"],"since":null,"text":"indexStart: Number - zero-based index which defines where find starts from"}],"returns":{"type":"Number","types":["Number"],"description":"zero-based position of the first sequence of characters that matches substring, -1 if not found","text":"Number - zero-based position of the first sequence of characters that matches substring, -1 if not found"},"form":"binary","operator":null,"left":{"text":"string","types":["String"]},"right":{"text":"[substring, indexStart]","types":["Array"]}}],"examples":[{"text":"```sqf\n[\"Apples\", \"Oranges\", \"Pears\"] find \"Oranges\"; // returns 1\n```","code":["[\"Apples\", \"Oranges\", \"Pears\"] find \"Oranges\"; // returns 1"]},{"text":"```sqf\n[1, [2], [[3]]] find [[3]]; // returns 2 - does not work in OFP, returns -1\n```","code":["[1, [2], [[3]]] find [[3]]; // returns 2 - does not work in OFP, returns -1"]},{"text":"```sqf\nif (magazines player find \"Strela\" != -1) then { hint \"You've got Strela!\"; };\n```","code":["if (magazines player find \"Strela\" != -1) then { hint \"You've got Strela!\"; };"]},{"text":"```sqf\nhint str (\"japa is the man!\" find \"the man!\"); // returns 8\n```","code":["hint str (\"japa is the man!\" find \"the man!\"); // returns 8"]},{"text":"```sqf\n\"abc\" find \"\"; // returns 0\n```","code":["\"abc\" find \"\"; // returns 0"]},{"text":"```sqf\n\"abcdefghijklmnopqrstuvxyz\" find \"z\"; // returns 24\n\"abcdefghijklmnopqrstuvxyz\" find [\"z\", 20]; // returns 24, better performance\n```","code":["\"abcdefghijklmnopqrstuvxyz\" find \"z\"; // returns 24\n\"abcdefghijklmnopqrstuvxyz\" find [\"z\", 20]; // returns 24, better performance"]},{"text":"```sqf\n\"abcßdef\" find \"c\"; // 2\n\"abcßdef\" find \"ß\"; // 3\n\"abcßdef\" find \"d\"; // 5 - before forceUnicode\n\nforceUnicode 0; // since Arma 3 v2.02\n\"abcßdef\" find \"d\"; // 4\n```","code":["\"abcßdef\" find \"c\"; // 2\n\"abcßdef\" find \"ß\"; // 3\n\"abcßdef\" find \"d\"; // 5 - before forceUnicode\n\nforceUnicode 0; // since Arma 3 v2.02\n\"abcßdef\" find \"d\"; // 4"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["in","findIf","forceUnicode"],"notes":[{"user":"Heeeere's Johnny!","date":"2015-01-04T09:38:00Z","text":"Using **nil** on either side of **find** will make the whole statement return Nothing:\n\n```sqf\n_array = [1, 2, nil, 4, 5];\n_result = _array find nil;\nhintSilent str (isNil \"_result\"); // true\n \n_result = nil find 1;\nhintSilent str (isNil \"_result\"); // true\n```"},{"user":"R3vo","date":"2020-07-16T07:33:00Z","text":"If you want to return all occurences of a given string in a string use the following code. Thanks to *sharp.* for providing the code.\n\n```sqf\nprivate _fnc_findStringsInString =\n{\n    params [\"_string\", \"_search\"];\n    if (_string == \"\") exitWith { [] };\n    private _searchLength = count _search;\n    private _return = [];\n    private _i = 0;\n    private _index = 0;\n    while { _index = _string find _search; _index != -1 } do\n    {\n        _string = _string select [_index + _searchLength];\n        _i = _i + _index + _searchLength;\n        _return pushBack _i - _searchLength;\n    };\n    _return;\n};\n[\"Test,123,123,Test\", \"Test\"] call _fnc_findStringsInString; // returns [0, 13]\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Strings","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findAny","operator":null,"title":"findAny","type":"command","url":"https://community.bistudio.com/wiki/findAny","revid":377163,"updated":"2026-01-01T10:41:43Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the zero-based index of the first element in array A that also exists in array B. If no common elements exist it returns -1.\n\nSimilar in functionality as find's first syntax, but the second parameter is an array of elements to find.","syntaxes":[{"syntax":"searchIn findAny toFind","since":null,"effect":null,"exec":null,"params":[{"name":"searchIn","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"searchIn: Array of Anything"},{"name":"toFind","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"toFind: Array of Anything"}],"returns":{"type":"Number","types":["Number"],"description":"the index of the first found item","text":"Number - the index of the first found item"},"form":"binary","operator":null,"left":{"text":"searchIn","types":["Array","Anything"]},"right":{"text":"toFind","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n[0,1,2,3,4] findAny [2,4,6,8]; // returns 2\n```","code":["[0,1,2,3,4] findAny [2,4,6,8]; // returns 2"]},{"text":"```sqf\n[0,1,2,3,4] findAny [8,6,4,2]; // returns 2\n```","code":["[0,1,2,3,4] findAny [8,6,4,2]; // returns 2"]},{"text":"```sqf\n[0,1,2,3,4] findAny [5,7,9]; // returns -1\n```","code":["[0,1,2,3,4] findAny [5,7,9]; // returns -1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["find","findIf"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"findCover","operator":null,"title":"findCover","type":"command","url":"https://community.bistudio.com/wiki/findCover","revid":377600,"updated":"2026-01-02T07:01:58Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the object around where the unit finds cover. The minDist, visibilityPosition and ignoreObject parameters are optional.\n\n> [!IMPORTANT]\n> Not implemented in Arma 2 and later titles (always returns objNull).","syntaxes":[{"syntax":"object findCover [position, hidePosition, maxDist, minDist, visibilityPosition, ignoreObject]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"hidePosition","type":"PositionATL","optional":false,"default":null,"description":"getHideFrom-like position from which the unit should hide","types":["PositionATL"],"since":null,"text":"hidePosition: PositionATL - getHideFrom-like position from which the unit should hide"},{"name":"maxDist","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"maxDist: Number"},{"name":"minDist","type":"Number","optional":true,"default":null,"description":null,"types":["Number"],"since":null,"text":"minDist: Number - (Optional)"},{"name":"visibilityPosition","type":"Position","optional":true,"default":null,"description":"used to select cover that unit can see in that direction from","types":["Position"],"since":null,"text":"visibilityPosition: Position - (Optional) used to select cover that unit can see in that direction from"},{"name":"ignoreObject","type":"Object","optional":true,"default":null,"description":"ignore this object in visibility check","types":["Object"],"since":null,"text":"ignoreObject: Object - (Optional) ignore this object in visibility check"}],"returns":{"type":"Object","types":["Object"],"description":"always objNull","text":"Object - always objNull"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[position, hidePosition, maxDist, minDist, visibilityPosition, ignoreObject]","types":["Array"]}}],"examples":[{"text":"```sqf\nunit1 findCover [ASLToATL aimPos unit2, 30];\n```","code":["unit1 findCover [ASLToATL aimPos unit2, 30];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getHideFrom","setHideBehind","isHidden"],"notes":[{"user":"SnowSky","date":"2015-07-04T22:01:00Z","text":"An alternative function in Arma 3 might be BIS_fnc_findSafePos."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findDisplay","operator":null,"title":"findDisplay","type":"command","url":"https://community.bistudio.com/wiki/findDisplay","revid":369048,"updated":"2024-09-02T20:24:49Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Finds a display by its IDD which can either be defined in missionConfigFile (description.ext) or configFile (config.cpp) or by its UI On Texture's unique name (see displayUniqueName).\n\nIf the specified display cannot be found, displayNull is returned.\n\n> [!IMPORTANT]\n> Dedicated servers and headless clients do not have a primary display (e.g `findDisplay 46` will return displayNull).\n>\n> Detect both with the hasInterface command.\n\n> [!NOTE]\n> For a list of (almost) all Arma 3's IDDs, see Arma 3: IDD List.","syntaxes":[{"syntax":"findDisplay idd","since":null,"effect":null,"exec":null,"params":[{"name":"idd","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idd: Number"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"unary","operator":null,"left":null,"right":{"text":"idd","types":["Number"]}},{"syntax":"findDisplay displayName","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"displayName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"displayName: String"}],"returns":{"type":"Display","types":["Display"],"description":null,"text":"Display"},"form":"unary","operator":null,"left":null,"right":{"text":"displayName","types":["String"]}}],"examples":[{"text":"```sqf\n0 spawn\n{\n    waitUntil { !isNull findDisplay 46 };\n    hint \"Mission Display is now available!\";\n};\n```","code":["0 spawn\n{\n\twaitUntil { !isNull findDisplay 46 };\n\thint \"Mission Display is now available!\";\n};"]},{"text":"```sqf\n_display = findDisplay 1;\n```","code":["_display = findDisplay 1;"]},{"text":"```sqf\nprivate _display = findDisplay \"RscDisplayRenderTest\";\n```","code":["private _display = findDisplay \"RscDisplayRenderTest\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDisplays","displayCtrl","createDisplay","createDialog","dialog","displayNull","controlNull","isNull","ctrlCreate","displayParent","displayUniqueName"],"notes":[{"user":"Lou Montana","date":"2019-07-07T12:20:00Z","text":"Common IDDs:\n- 46: Mission display\n- 312: Zeus display\n- 49: Pause menu\n- 602: Inventory\n- 24: Chat box\n- 300: Weapon state\n- 12: Map\n- 160: UAV Terminal"},{"user":"Kronzky","date":"2009-06-15T19:10:00Z","text":"findDisplay does *not* find displays defined under RscTitles (even when they are visible).\n\nTo access those types of displays, either assign the resource to a global variable, or pass its this value to a script, during the onLoad event:\ne.g. \n\n```cpp\nclass RscTitles\n{\n    class MyRsc\n    {\n        onLoad = \"myDisplay = (_this select 0)\";\n        // or\n        // onLoad = \"_this execVM 'myDialog.sqf'\";\n        // ...\n    };\n};\n```\n\nYou can then use the stored value as you would for regular dialogs:\n\n```sqf\n(myDisplay displayCtrl 1111) ctrlSetText \"hello there\");\n```"},{"user":"Nelis75733126","date":"2017-06-25T09:32:00Z","text":"I have tested the behavior of this command and I found out that `findDisplay` appears to only return the display AFTER any onLoad event handler of that display is done.\n\nMeaning: using findDisplay inside the code of an onLoad event handler is useless."},{"user":"Demellion","date":"2017-08-14T12:22:00Z","text":"There are some specific cases, where findDisplay will not be able to find an existing display. Here's the cases and how to act on them:\n\n```cpp\n// Your display has IDD= -1.\nclass RscDisplayNew\n{\n    idd = -1;\n    scriptName = \"RscDisplayNew\";\n    // ...\n};\n```\n\n```cpp\n// Your display doesn't have IDD\nclass RscDisplayNew\n{\n    scriptName = \"RscDisplayNew\";\n    // ...\n};\n```\n\n```cpp\n// Your display doesn't have scriptname with IDD = -1\nclass RscDisplayNew\n{\n    idd = -1;\n    // ...\n};\n```\n\n```cpp\n// Your display doesn't have scriptname, neither IDD\nclass RscDisplayNew\n{\n    // ...\n};\n```\n\n1. You actually can find a -1 display, but this means finding a display with this IDD might be a problem, when there are a few displays marked as -1.So as you can see, theres an entry called **scriptName**. You can get a reference to this display by using uiNamespace:\n\n```sqf\n(uiNamespace getVariable \"RscDisplayNew\")\n```\n\n**NOTE**: Variables are overwritten with a reference of the last declared display under the same scriptName entry. Take a look at case 3 for solution.\n1. Displays without IDDs can actually exist. They can be manipulated only in a way described in the first case using uiNamespace.\n1. You can really have this display seeking it manually in a allDisplays return. This is experimental, but working option.\n1. You will have a problem finding this display, since this display doesn't exist even in allDisplays(?) return. Behaviour unknown."},{"user":"AVespade","date":"2023-05-07T02:55:58Z","text":"Since findDisplay is case-sensitive, and any UI On Texture unique names defined inside a p3d file will always be forced to lowercase, the unique name you search for with findDisplay will need to be lowercase.\n\n```sqf\nprivate _display = findDisplay \"rscdisplayrendertest\";\n```\n\nUse of toLower may be useful to improve legibility or flow, especially in cases where a UI On Texture's unique name is the same as the class name.\n\n```sqf\nprivate _display = findDisplay (toLower \"RscDisplayRenderTest\");\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findEditorObject","operator":null,"title":"findEditorObject","type":"command","url":"https://community.bistudio.com/wiki/findEditorObject","revid":363271,"updated":"2024-03-26T10:51:40Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return object that matches the provided reference.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map findEditorObject value","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"value","types":["Anything"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findEmptyPosition","operator":null,"title":"findEmptyPosition","type":"command","url":"https://community.bistudio.com/wiki/findEmptyPosition","revid":377837,"updated":"2026-01-03T04:32:18Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Searches for an empty area around the specified position, starting from the *center* looking for an empty *areaRadius* and looks as far away as *areaRadius* + *maxDistance*.\nThis command ignores moving objects present within the search area. The search area can be preloaded with findEmptyPositionReady command.\n\n> [!NOTE]\n> This command does not work outside of world dimensions and will always return the provided *center*.\n> Objects outside the world dimensions will not be considered in the detection either.","syntaxes":[{"syntax":"center findEmptyPosition [areaRadius, maxDistance, vehicleType]","since":null,"effect":null,"exec":null,"params":[{"name":"center","type":"Position2D or Position3D","optional":false,"default":null,"description":"search area center position in format [x,y] or [x,y,z] in which case z is ignored","types":["Position2D","Position3D"],"since":null,"text":"center: Position2D or Position3D - search area center position in format [x,y] or [x,y,z] in which case z is ignored"},{"name":"areaRadius","type":"Number","optional":false,"default":null,"description":"wanted area radius","types":["Number"],"since":null,"text":"areaRadius: Number - wanted area radius"},{"name":"maxDistance","type":"Number","optional":false,"default":null,"description":"stop searching no further than `areaRadius + maxDistance` from the center","types":["Number"],"since":null,"text":"maxDistance: Number - stop searching no further than `areaRadius + maxDistance` from the center"},{"name":"vehicleType","type":"String","optional":true,"default":null,"description":"classname of a vehicle to accommodate","types":["String"],"since":null,"text":"vehicleType: String - (Optional) classname of a vehicle to accommodate"}],"returns":{"type":"Position3D","types":["Position3D"],"description":"a suitable empty position or empty array `[]` if not found","text":"Position3D - a suitable empty position or empty array `[]` if not found"},"form":"binary","operator":null,"left":{"text":"center","types":["Position2D","Position3D"]},"right":{"text":"[areaRadius, maxDistance, vehicleType]","types":["Array"]}}],"examples":[{"text":"```sqf\n_position = getPosASL player findEmptyPosition [0, 100];\n```","code":["_position = getPosASL player findEmptyPosition [0, 100];"]},{"text":"```sqf\n_position = _center findEmptyPosition [10,100,\"UH60M_EP1\"];\n```","code":["_position = _center findEmptyPosition [10,100,\"UH60M_EP1\"];"]},{"text":"Check if exact position is empty:\n\n```sqf\n_position = _center findEmptyPosition [0, 0, \"B_Boat_Armed_01_minigun_F\"];\n```","code":["_position = _center findEmptyPosition [0, 0, \"B_Boat_Armed_01_minigun_F\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findEmptyPositionReady","selectBestPlaces","isFlatEmpty","BIS_fnc_findSafePos"],"notes":[{"user":"Killzone_Kid","date":"2013-11-06T18:10:00Z","text":"Keep search radius short and sweet, under 50 metres maybe. Searching big area takes long time and will result in your game stop responding until the search is over. isFlatEmpty is probably more suitable for a larger area search."},{"user":"old_man_auz","date":"2012-03-06T00:50:00Z","text":"I think the **radius** parameter should be treated as a 'minimum distance' from the **centre** position. I found that the parameter name **radius** was not very clear. Also, if **radius** is greater than **max distance** then the function will always return an empty array.\n\nHere is an snippet of code I use to find a safe landing zone for an extraction helicopter. It may be useful for someone.\n\n```sqf\n_centre = [getMarkerPos \"marker\", random 150, random 360] call BIS_fnc_relPos;\n_extraction_point = [];\n_max_distance = 100;\nwhile { count _extraction_point < 1 } do\n{\n    _extraction_point = _centre findEmptyPosition [30, _max_distance, \"UH60M_EP1\"];\n    _max_distance = _max_distance + 50;\n};\n```\n\nIn the above example, make sure that \"_max_distance\" is greater than 30, otherwise the while loop will go forever."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findEmptyPositionReady","operator":null,"title":"findEmptyPositionReady","type":"command","url":"https://community.bistudio.com/wiki/findEmptyPositionReady","revid":377552,"updated":"2026-01-02T06:54:51Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Preloads area to be used with findEmptyPosition command and returns true when area is ready.\nThe size of the area preloaded is from `center - radius - maxDistance` to `center + radius + maxDistance`\n\n> [!IMPORTANT]\n> Preloading large areas may take a long time, we are talking minutes. However once preloaded, it stays preloaded even after mission restart.","syntaxes":[{"syntax":"center findEmptyPositionReady [radius, maxDistance]","since":null,"effect":null,"exec":null,"params":[{"name":"center","type":"Position2D or Position3D","optional":false,"default":null,"description":"search area center position in format [x,y] or [x,y,z] in which case z is ignored","types":["Position2D","Position3D"],"since":null,"text":"center: Position2D or Position3D - search area center position in format [x,y] or [x,y,z] in which case z is ignored"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"distance from the center","types":["Number"],"since":null,"text":"radius: Number - distance from the center"},{"name":"maxDistance","type":"Number","optional":false,"default":null,"description":"distance from the end of radius","types":["Number"],"since":null,"text":"maxDistance: Number - distance from the end of radius"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when ready","text":"Boolean - true when ready"},"form":"binary","operator":null,"left":{"text":"center","types":["Position2D","Position3D"]},"right":{"text":"[radius, maxDistance]","types":["Array"]}}],"examples":[{"text":"Preload aread within 500m:\n\n```sqf\n_ready = _center findEmptyPositionReady [0, 500];\n```","code":["_ready = _center findEmptyPositionReady [0, 500];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findEmptyPosition"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"findIf","operator":null,"title":"findIf","type":"command","url":"https://community.bistudio.com/wiki/findIf","revid":376518,"updated":"2025-10-22T23:13:13Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Searches for an element within array for which the code evaluates to true. Returns the zero-based index on success or -1 if not found.\n\nCode on the right side of the command is evaluated for each element of the array, processed element can be referenced in code as _x.\n\n> [!NOTE]\n> findIf terminates as soon as it finds an element that fulfills the condition, thus it is more efficient than count in scenarios where a check for presence / absence of at least one element should be done (See #Example 2).","syntaxes":[{"syntax":"array findIf code","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array","optional":false,"default":null,"description":"array to search in","types":["Array"],"since":null,"text":"array: Array - array to search in"},{"name":"code","type":"Code","optional":false,"default":null,"description":"code defining an element to find, processed element can be referenced within the code as _x","types":["Code"],"since":null,"text":"code: Code - code defining an element to find, processed element can be referenced within the code as _x"}],"returns":{"type":"Number","types":["Number"],"description":"zero-based position of the first array element for which the code evaluate to true, -1 if not found","text":"Number - zero-based position of the first array element for which the code evaluate to true, -1 if not found"},"form":"binary","operator":null,"left":{"text":"array","types":["Array"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nprivate _firstDead = [unit1, unit2, unit3] findIf { not alive _x }; // return index of the first dead unit\n```","code":["private _firstDead = [unit1, unit2, unit3] findIf { not alive _x }; // return index of the first dead unit"]},{"text":"```sqf\n// two ways how to 'wait for all units to be dead':\nwaitUntil { [unit1, unit2, unit3] findIf { alive _x } == -1 };    // fast, terminates as soon as it finds a living unit\nwaitUntil { { alive _x } count [unit1, unit2, unit3] == 0 };    // slow, always goes through all array elements\n```","code":["// two ways how to 'wait for all units to be dead':\nwaitUntil { [unit1, unit2, unit3] findIf { alive _x } == -1 };\t// fast, terminates as soon as it finds a living unit\nwaitUntil { { alive _x } count [unit1, unit2, unit3] == 0 };\t// slow, always goes through all array elements"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["find","count"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"findNearestEnemy","operator":null,"title":"findNearestEnemy","type":"command","url":"https://community.bistudio.com/wiki/findNearestEnemy","revid":377414,"updated":"2026-01-02T06:45:18Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Finds the nearest enemy to the specified position. Returns a null object if the object's group does not know about any enemies. This command will return nearest object that is known to the unit and is considered enemy. An empty vehicle that is part of enemy group assets (see addVehicle) can be returned as valid nearest target.","syntaxes":[{"syntax":"object findNearestEnemy position","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"position","types":["Object","PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_myNearestEnemy = (units _myGroup select 0) findNearestEnemy player;\n```","code":["_myNearestEnemy = (units _myGroup select 0) findNearestEnemy player;"]},{"text":"```sqf\n_myNearestEnemy = player findNearestEnemy player;\n```","code":["_myNearestEnemy = player findNearestEnemy player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targets","targetsQuery","nearTargets","targetsAggregate","targetKnowledge","knowsAbout","reveal","forgetTarget","setTargetAge","getHideFrom","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"finishMissionInit","operator":null,"title":"finishMissionInit","type":"command","url":"https://community.bistudio.com/wiki/finishMissionInit","revid":378152,"updated":"2026-02-25T23:18:14Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Finish world initialisation before mission is launched.","syntaxes":[{"syntax":"finishMissionInit","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"finishMissionInit","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["startLoadingScreen","endLoadingScreen"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"finite","operator":null,"title":"finite","type":"command","url":"https://community.bistudio.com/wiki/finite","revid":369301,"updated":"2024-09-03T18:42:53Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the provided number is finite (not infinite and a valid number).\n\n> [!NOTE]\n> - Maximum finite Number : 3.40282e+38\n> - Minimum finite Number : -3.40282e+38","syntaxes":[{"syntax":"finite number","since":null,"effect":null,"exec":null,"params":[{"name":"number","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"number: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"number","types":["Number"]}}],"examples":[{"text":"```sqf\nfinite 123; // returns true\n```","code":["finite 123; // returns true"]},{"text":"```sqf\nfinite log -1; // returns false\n```","code":["finite log -1; // returns false"]},{"text":"```sqf\nif (not finite log -1) then { hint \"Infinite\" };\n```","code":["if (not finite log -1) then { hint \"Infinite\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["a / b"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fire","operator":null,"title":"fire","type":"command","url":"https://community.bistudio.com/wiki/fire","revid":369149,"updated":"2024-09-03T10:34:38Z","groups":["Unit Control","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Forces a unit to fire the given weapon.\n\n> [!NOTE]\n> Just like with forceWeaponFire it is possible to pass remote unit as argument, but this could be unreliable. Considering this command might need to be used in combination with selectWeapon, which takes only local arguments, it would make sense to execute the fire command where the unit is local as well.","syntaxes":[{"syntax":"unit fire muzzle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit that is supposed to fire","types":["Object"],"since":null,"text":"unit: Object - unit that is supposed to fire"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"name of the muzzle to be fired","types":["String"],"since":null,"text":"muzzle: String - name of the muzzle to be fired"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"muzzle","types":["String"]}},{"syntax":"unit fire [muzzle, mode, magazine]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"muzzle: String"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"},{"name":"magazine","type":"String","optional":true,"default":null,"description":null,"types":["String"],"since":null,"text":"magazine: String - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[muzzle, mode, magazine]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldier fire \"M16\";\n```","code":["_soldier fire \"M16\";"]},{"text":"```sqf\n_soldier fire \"SmokeShellMuzzle\";\n```","code":["_soldier fire \"SmokeShellMuzzle\";"]},{"text":"```sqf\n_soldier fire [\"SmokeShellMuzzle\", \"SmokeShellMuzzle\", \"SmokeShellRed\"];\n```","code":["_soldier fire [\"SmokeShellMuzzle\", \"SmokeShellMuzzle\", \"SmokeShellRed\"];"]},{"text":"```sqf\nplayer playActionNow \"PutDown\";\nplayer selectWeapon \"DemoChargeMuzzle\";\nplayer fire [\"DemoChargeMuzzle\", \"DemoChargeMuzzle\", \"DemoCharge_Remote_Mag\"];\nplayer setWeaponReloadingTime [player, \"DemoChargeMuzzle\", 0];\n```","code":["player playActionNow \"PutDown\";\nplayer selectWeapon \"DemoChargeMuzzle\";\nplayer fire [\"DemoChargeMuzzle\", \"DemoChargeMuzzle\", \"DemoCharge_Remote_Mag\"];\nplayer setWeaponReloadingTime [player, \"DemoChargeMuzzle\", 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire","selectWeapon","ArmA: Actions"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Command Group: Weapons","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"fireAtTarget","operator":null,"title":"fireAtTarget","type":"command","url":"https://community.bistudio.com/wiki/fireAtTarget","revid":369417,"updated":"2024-09-03T18:48:49Z","groups":["Unit Control","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remotely forces a unit to fire the given weapon. See also BIS_fnc_fire.","syntaxes":[{"syntax":"sourceVehicle fireAtTarget [targetVehicle, weaponMuzzleName]","since":null,"effect":null,"exec":null,"params":[{"name":"sourceVehicle","type":"Object","optional":false,"default":null,"description":"source vehicle to fire from","types":["Object"],"since":null,"text":"sourceVehicle: Object - source vehicle to fire from"},{"name":"targetVehicle","type":"Object","optional":false,"default":null,"description":"target vehicle to fire at","types":["Object"],"since":null,"text":"targetVehicle: Object - target vehicle to fire at"},{"name":"weaponMuzzleName","type":"String","optional":true,"default":null,"description":"weapon muzzle classname, optional parameter","types":["String"],"since":null,"text":"weaponMuzzleName: String - (Optional) weapon muzzle classname, optional parameter"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if fired, false if not","text":"Boolean - true if fired, false if not"},"form":"binary","operator":null,"left":{"text":"sourceVehicle","types":["Object"]},"right":{"text":"[targetVehicle, weaponMuzzleName]","types":["Array"]}}],"examples":[{"text":"```sqf\n_handle = this fireAtTarget [groundtarget1, \"HellfireLauncher\"];\n```","code":["_handle = this fireAtTarget [groundtarget1, \"HellfireLauncher\"];"]},{"text":"```sqf\n_handle = Igla_AA_pod_TK_EP1 fireAtTarget [_helicopter, currentWeapon Igla_AA_pod_TK_EP1];\n```","code":["_handle = Igla_AA_pod_TK_EP1 fireAtTarget [_helicopter, currentWeapon Igla_AA_pod_TK_EP1];"]},{"text":"```sqf\n_handle = Igla_AA_pod_TK_EP1 fireAtTarget [helicopter];\n```","code":["_handle = Igla_AA_pod_TK_EP1 fireAtTarget [helicopter];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","doFire","commandFire","canFire","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire","aimedAtTarget","BIS_fnc_fire"],"notes":[{"user":"Dwarden","date":"2010-09-16T08:17:00Z","text":"Most likely only for missiles and for interaction with player only."},{"user":"ffur2007slx2_5","date":"2014-04-08T16:50:00Z","text":"(Arma 3 1.14) Source vehicle is only limited to manned vehicle while any other types won’t be able to active fireAtTarget handle, e.g.\n\n```sqf\n_handle = _infantryUnit fireAtTarget [_infantryTarget, weapons _infantryUnit select 0];\n// false & no bullet shoot\n```\n\nTarget has no limitation and can be any object:\n\n```sqf\n_handle = (vehicle _veh) fireAtTarget [objNull, weapons (vehicle _veh) select 0];\n// true & a bullet shoot\n```\n\nHandle returns false if weapon class name is inaccurate, e.g.\n\n```sqf\n_handle = (vehicle _veh) fireAtTarget [ObjNull, \"UnknownWeapon\"];\n// false & no bullet shoot\n```\n\nHandle still returns true even though the vehicle is unavailable to shoot any bullet:\n\n```sqf\n_weapon = weapons (vehicle _veh) select 0;\n(vehicle _veh) setAmmo [_weapon, 0];\n_handle = (vehicle _veh) fireAtTarget [objNull, _weapon];\n// true & no bullet shoot\n```\n\n#### Difference\n\n| command | Source | Target | Behavior | Workaround templets |\n|---|---|---|---|---|\n| fire | Either unit or manned vehicle | N/A | Fired aiming at air for infantry rifle | Together with selectWeapon,<br>suggested to work with \"throw\",\"put\" weapon type<br>for infantry, or vehicle entity indeed. |\n| fireAtTarget | Manned vehicle only | Any object | Normal shoot, won’t aim at target automatically | ```sqf<br>_veh doWatch _target;<br>waitUntil { _veh aimedAtTarget [_target] > 0 };<br>_veh fireAtTarget [_target];<br>``` |\n| forceWeaponFire | Either unit or manned aircraft (weapon operator) | N/A | Normal shoot, can change fire mode | ```sqf<br>// e.g. unit won't shoot until he is facing the target<br>_unit doWatch _tar;<br>waitUntil {<br>    _dir = direction _unit;<br>    _relative = [_unit,_tar] call BIS_fnc_relativeDirTo;<br>    if (_dir == _relative) exitWith {<br>        _unit forceWeaponFire [currentWeapon _unit, \"single\"];<br>    };<br>    false<br>};<br>``` |\n| doFire | Unit only | Either unit or vehicle | automatic aiming and shooting | No special example. |\n| commandFire | Unit only | Either unit or vehicle | automatic aiming and shooting | No special example. |\n| action [\"UseWeapon\"] | Either unit or manned vehicle | N/A | unexpected behavior | N/A |"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"firstBackpack","operator":null,"title":"firstBackpack","type":"command","url":"https://community.bistudio.com/wiki/firstBackpack","revid":318966,"updated":"2022-05-13T09:22:07Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the first stored backpack.","syntaxes":[{"syntax":"firstBackpack box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nmyVariable = firstBackpack myBox;\n```","code":["myVariable = firstBackpack myBox;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"flag","operator":null,"title":"flag","type":"command","url":"https://community.bistudio.com/wiki/flag","revid":353769,"updated":"2024-03-23T14:27:22Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the original flag pole of the flag the unit is carrying.","syntaxes":[{"syntax":"flag unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":"flag pole object the flag belongs to. If the unit carries no flag, objNull is returned.","text":"Object - flag pole object the flag belongs to. If the unit carries no flag, objNull is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_flag = flag _soldier;\n```","code":["_flag = flag _soldier;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flagOwner","setFlagOwner","setFlagSide","setFlagTexture","flagSide","flagTexture","setFlagAnimationPhase","flagAnimationPhase","forceFlagTexture","getForcedFlagTexture"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"flagAnimationPhase","operator":null,"title":"flagAnimationPhase","type":"command","url":"https://community.bistudio.com/wiki/flagAnimationPhase","revid":376970,"updated":"2026-01-01T06:01:24Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns flag position on the flag pole.","syntaxes":[{"syntax":"flagAnimationPhase flag","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":"flag pole of the type `\"FlagCarrier\"`","types":["Object"],"since":null,"text":"flag: Object - flag pole of the type `\"FlagCarrier\"`"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":"flag position, where 0 is bottom of the flag pole, 1 is the top of the flag pole","text":"Number in range 0..1 - flag position, where 0 is bottom of the flag pole, 1 is the top of the flag pole"},"form":"unary","operator":null,"left":null,"right":{"text":"flag","types":["Object"]}}],"examples":[{"text":"```sqf\nflagAnimationPhase _flag1;\n```","code":["flagAnimationPhase _flag1;"]}],"multiplayer":"The result is local to the PC on which command is executed.","problems":null,"aliases":[],"see_also":["setFlagAnimationPhase","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"flagOwner","operator":null,"title":"flagOwner","type":"command","url":"https://community.bistudio.com/wiki/flagOwner","revid":353770,"updated":"2024-03-23T14:27:22Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Returns the global owner of a flag. A getter for setFlagOwner. Note that owner of a flag is Object rather than Number, as how it is usually with other owner commands","syntaxes":[{"syntax":"flagOwner flag","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"flag: Object"}],"returns":{"type":"Object","types":["Object"],"description":"the person or vehicle that owns the flag is returned. If used on anything else than a flag, the returned value is objNull. If the flag is on its pole, the return value is NULL. If the flagowner is dead, the return value is the name of the soldier model","text":"Object - the person or vehicle that owns the flag is returned. If used on anything else than a flag, the returned value is objNull. If the flag is on its pole, the return value is NULL. If the flagowner is dead, the return value is the name of the soldier model"},"form":"unary","operator":null,"left":null,"right":{"text":"flag","types":["Object"]}}],"examples":[{"text":"```sqf\n_person = flagOwner _flagOne;\n```","code":["_person = flagOwner _flagOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFlagOwner"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"flagSide","operator":null,"title":"flagSide","type":"command","url":"https://community.bistudio.com/wiki/flagSide","revid":376347,"updated":"2025-10-07T17:04:44Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns Side of the local instance of the flag. A getter for setFlagSide.","syntaxes":[{"syntax":"flagSide flag","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":"flag","types":["Object"],"since":null,"text":"flag: Object - flag"}],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"unary","operator":null,"left":null,"right":{"text":"flag","types":["Object"]}}],"examples":[{"text":"```sqf\n_flagSide =  flagSide aFlag;\n```","code":["_flagSide =  flagSide aFlag;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFlagSide","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"flagTexture","operator":null,"title":"flagTexture","type":"command","url":"https://community.bistudio.com/wiki/flagTexture","revid":349339,"updated":"2023-11-08T14:53:29Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns texture of the local instance of the flag. A getter for setFlagTexture. It will not return flag textures applied using forceFlagTexture, use getForcedFlagTexture for that.","syntaxes":[{"syntax":"flagTexture flagCarrier","since":null,"effect":null,"exec":null,"params":[{"name":"flagCarrier","type":"Object","optional":false,"default":null,"description":"vehicle, unit or flag pole","types":["Object"],"since":null,"text":"flagCarrier: Object - vehicle, unit or flag pole"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"flagCarrier","types":["Object"]}}],"examples":[{"text":"```sqf\n_flagTexture = flagTexture _flag1;\n```","code":["_flagTexture = flagTexture _flag1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFlagTexture","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"flatten","operator":null,"title":"flatten","type":"command","url":"https://community.bistudio.com/wiki/flatten","revid":377162,"updated":"2026-01-01T10:41:18Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Flattens an array.","syntaxes":[{"syntax":"flatten array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"flattened array","text":"Array of Anything - flattened array"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\nflatten [1, [2], [[3]], [[[4]]]]; // returns [1, 2, 3, 4]\n```","code":["flatten [1, [2], [[3]], [[[4]]]]; // returns [1, 2, 3, 4]"]},{"text":"```sqf\nflatten getUnitLoadout player;\n```","code":["flatten getUnitLoadout player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["arrayIntersect"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"fleeing","operator":null,"title":"fleeing","type":"command","url":"https://community.bistudio.com/wiki/fleeing","revid":349082,"updated":"2023-11-08T14:47:23Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if a unit is fleeing.\n\nNotes:\n- Fleeing only affects AI led groups.\n- Only the group as a whole can flee (or not).\n- The courage of the AI group is based on the group's leader courage subskill.\n- Each group has a max strength (summed \"armor\" of all infantry units - plus armor when inside vehicles).\n- If the group losses by injury/damage or death/destruction are higher than the max strength, multiplied by leader's courage or allowFleeing level , then the group will start fleeing.\n- As result primarily the AI flees to a nearby \"supply point\" (some friendly units - preferably with medic or engineer, or a vehicle with repair/ammo/fuel cargo). Alternatively it will try to find a safe position within a 600m radius from the initial waypoint (danger, distance, amount of cover positions are taken into account).\n- After the fleeing has been finished the group's initial strength is reset.\n- Fleeing units in combatMode red, will be set to yellow when fleeing to avoid engaging enemies while doing so.\n- While fleeing, the group leader will be set to green, to avoid giving engage or fire orders, unless in combatMode blue already. Also speedMode is set to full.\n- When reaching their flee point/destination, they will change to combatMode yellow and speedMode normal.\n- With allowFleeing one can make unit's flee earlier (or essentially never flee). Apply it, overrides the courage subskill influence.","syntaxes":[{"syntax":"fleeing unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if a unit is fleeing, false if not. Dead or empty units return false.","text":"Boolean - returns true if a unit is fleeing, false if not. **Dead** or **empty** units return false."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (fleeing soldier_1) then {player sideChat \"We have won!\"} else {player sideChat \"Keep fighting!\"};\n```","code":["if (fleeing soldier_1) then {player sideChat \"We have won!\"} else {player sideChat \"Keep fighting!\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowFleeing"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"floor","operator":null,"title":"floor","type":"command","url":"https://community.bistudio.com/wiki/floor","revid":369333,"updated":"2024-09-03T18:43:00Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the next **lowest** integer in relation to the provided number.","syntaxes":[{"syntax":"floor num","since":null,"effect":null,"exec":null,"params":[{"name":"num","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"num: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"num","types":["Number"]}}],"examples":[{"text":"```sqf\nfloor 5.1;        // result is  5\nfloor 5.999;    // result is  5\nfloor -2.01;    // result is -3\nfloor -2.99;    // result is -3\n```","code":["floor 5.1;\t\t// result is  5\nfloor 5.999;\t// result is  5\nfloor -2.01;\t// result is -3\nfloor -2.99;\t// result is -3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ceil","round","linearConversion"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"flyInHeight","operator":null,"title":"flyInHeight","type":"command","url":"https://community.bistudio.com/wiki/flyInHeight","revid":376081,"updated":"2025-08-01T17:11:58Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the flying altitude for aircraft relatively to the ground surface. Avoid too low altitudes, as helicopters and planes won't evade trees and obstacles on the ground. The default flying altitude is 100 meters. The minimum height is 20 meters.\n\n> [!NOTE]\n> Height measurement is relative to the pilot and can be approximated with `ASLToAGL eyePos driver _aircraft;`.","syntaxes":[{"syntax":"aircraft flyInHeight altitude","since":null,"effect":null,"exec":null,"params":[{"name":"aircraft","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"aircraft: Object"},{"name":"altitude","type":"Number","optional":false,"default":null,"description":"flying altitude in meters","types":["Number"],"since":null,"text":"altitude: Number - flying altitude in meters"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"aircraft","types":["Object"]},"right":{"text":"altitude","types":["Number"]}},{"syntax":"aircraft flyInHeight [altitude, forced]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"aircraft","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"aircraft: Object"},{"name":"altitude","type":"Number","optional":false,"default":null,"description":"flying altitude in meters","types":["Number"],"since":null,"text":"altitude: Number - flying altitude in meters"},{"name":"forced","type":"Boolean","optional":false,"default":null,"description":"true to force altitude in all cases, false to behave like main syntax","types":["Boolean"],"since":null,"text":"forced: Boolean - true to force altitude in all cases, false to behave like main syntax"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"aircraft","types":["Object"]},"right":{"text":"[altitude, forced]","types":["Array"]}}],"examples":[{"text":"```sqf\n_helicopter flyInHeight 40;\n```","code":["_helicopter flyInHeight 40;"]},{"text":"```sqf\n// for altitudes below 10m\n_helicopter flyInHeight 5;            // helicopter will land\n_helicopter flyInHeight [5, true];    // helicopter will hover at 5m altitude\n\n// on a landed helicopter\n_helicopter flyInHeight 50;            // helicopter will not move until a waypoint is added\n_helicopter flyInHeight [50, true];    // helicopter will start to rise immediately\n```","code":["// for altitudes below 10m\n_helicopter flyInHeight 5;\t\t\t// helicopter will land\n_helicopter flyInHeight [5, true];\t// helicopter will hover at 5m altitude\n\n// on a landed helicopter\n_helicopter flyInHeight 50;\t\t\t// helicopter will not move until a waypoint is added\n_helicopter flyInHeight [50, true];\t// helicopter will start to rise immediately"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flyInHeightASL"],"notes":[{"user":"Hardrock","date":"2006-08-04T12:50:00Z","text":"*Notes from before the conversion:*\n\nFrom Operation Flashpoint v1.80 - flyInHeight now affects not only helicopters, but also planes."},{"user":"Kronzky","date":"2008-12-16T01:34:00Z","text":"A flyInHeight of 0 will keep the chopper pinned to the ground, even when the engines have been started."},{"user":"Jtgibson","date":"2009-04-11T00:53:00Z","text":"If a helo has no waypoints, it will assume a low hover without regard to this setting.\n\n> [!IMPORTANT]\n> This comment does not apply to the alternative syntax."},{"user":"OverlordZorn","date":"2025-08-01T17:11:58Z","text":"As of 2.20:\n\n- when altitude is greater or equal 10, collision avoidance will maintain priority and the rotary airframe stays around 20~35 meters ATL, depending on nearby objects.\n\n- when altitude is lower then 10, for example, 9.99999, it seems that collision avoidance is disabled and the airframe will maintain the desired ATL."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"flyInHeightASL","operator":null,"title":"flyInHeightASL","type":"command","url":"https://community.bistudio.com/wiki/flyInHeightASL","revid":329162,"updated":"2022-07-25T12:35:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the minimal ASL height. Final height is `*flyInHeight* max *flyInHeightASL*` - the higher altitude has priority.","syntaxes":[{"syntax":"aircraft flyInHeightASL [standardAltitude, combatAltitude, stealthAltitude]","since":null,"effect":null,"exec":null,"params":[{"name":"aircraft","type":"Object","optional":false,"default":null,"description":"helicopter, airplane","types":["Object"],"since":null,"text":"aircraft: Object - helicopter, airplane"},{"name":"standardAltitude","type":"Number","optional":false,"default":null,"description":"base altitude used when behaviour is neither \"COMBAT\" or \"STEALTH\"","types":["Number"],"since":null,"text":"standardAltitude: Number - base altitude used when behaviour is neither \"COMBAT\" or \"STEALTH\""},{"name":"combatAltitude","type":"Number","optional":false,"default":null,"description":"altitude used when behaviour is \"COMBAT\"","types":["Number"],"since":null,"text":"combatAltitude: Number -  altitude used when behaviour is \"COMBAT\""},{"name":"stealthAltitude","type":"Number","optional":false,"default":null,"description":"altitude used when behaviour is \"STEALTH\"","types":["Number"],"since":null,"text":"stealthAltitude: Number - altitude used when behaviour is \"STEALTH\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"aircraft","types":["Object"]},"right":{"text":"[standardAltitude, combatAltitude, stealthAltitude]","types":["Array"]}}],"examples":[{"text":"```sqf\ncobraOne flyInHeightASL [200, 100, 400];\n```","code":["cobraOne flyInHeightASL [200, 100, 400];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flyInHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"focusedCtrl","operator":null,"title":"focusedCtrl","type":"command","url":"https://community.bistudio.com/wiki/focusedCtrl","revid":348589,"updated":"2023-11-08T13:42:42Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns display's focused control.","syntaxes":[{"syntax":"focusedCtrl display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":"parent display","types":["Display"],"since":null,"text":"display: Display - parent display"}],"returns":{"type":"Control","types":["Control"],"description":"control which has focus","text":"Control - control which has focus"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\nprivate _focusedCtrl = focusedCtrl findDisplay 12;\n```","code":["private _focusedCtrl = focusedCtrl findDisplay 12;"]},{"text":"```sqf\nprivate _isFocused = focusedCtrl _display == _ctrl;\n```","code":["private _isFocused = focusedCtrl _display == _ctrl;"]},{"text":"```sqf\nprivate _isFocused = focusedCtrl (ctrlParent _ctrl) == _ctrl;\n```","code":["private _isFocused = focusedCtrl (ctrlParent _ctrl) == _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetFocus","displayParent","ctrlParent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"focusOn","operator":null,"title":"focusOn","type":"command","url":"https://community.bistudio.com/wiki/focusOn","revid":363319,"updated":"2024-03-26T16:41:39Z","groups":["Camera Control","Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the person the camera is focused on. If you need the vehicle, see cameraOn.","syntaxes":[{"syntax":"focusOn","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":"controlled person or objNull if no unit is controlled","text":"Object - controlled person or objNull if no unit is controlled"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _currentlyControlledUnit = focusOn;\n```","code":["private _currentlyControlledUnit = focusOn;"]},{"text":"```sqf\nif (isNull player) exitWith { /* no player */ };\n\nif (player == focusOn) then\n{\n    hint \"You are controlling your player unit\";\n}\nelse\n{\n    hint \"You are remote-controlling a unit\";\n};\n```","code":["if (isNull player) exitWith { /* no player */ };\n\nif (player == focusOn) then\n{\n\thint \"You are controlling your player unit\";\n}\nelse\n{\n\thint \"You are remote-controlling a unit\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchCamera","cameraView","cameraEffect","cameraOn","remoteControl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Remote Control","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"fog","operator":null,"title":"fog","type":"command","url":"https://community.bistudio.com/wiki/fog","revid":310796,"updated":"2022-05-07T20:21:54Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setFog. Returns the current value of the fog in range 0..1.","syntaxes":[{"syntax":"fog","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_foglevel = fog;\n```","code":["_foglevel = fog;"]}],"multiplayer":"Before Arma 3, each client and the server could have different values. In Arma 3 the value is synced across network.","problems":null,"aliases":[],"see_also":["fogParams","fogForecast","setFog","nextWeatherChange"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fogForecast","operator":null,"title":"fogForecast","type":"command","url":"https://community.bistudio.com/wiki/fogForecast","revid":310773,"updated":"2022-05-07T20:21:44Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the forecast fog value. A value of 0 means no fog, 1 means maximum fog.","syntaxes":[{"syntax":"fogForecast","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_level = fogForecast;\n```","code":["_level = fogForecast;"]}],"multiplayer":"This command returns the local forcast fog value. Each client and the server can have differing values.","problems":null,"aliases":[],"see_also":["fogParams","fog","setFog","nextWeatherChange"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fogParams","operator":null,"title":"fogParams","type":"command","url":"https://community.bistudio.com/wiki/fogParams","revid":353028,"updated":"2024-03-12T11:39:48Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setFog (Alt Syntax). Returns extended params for the fog","syntaxes":[{"syntax":"fogParams","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"in setFog format: [fogValue, fogDecay, fogBase]","text":"Array of Numbers - in setFog format: [fogValue, fogDecay, fogBase]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _fog = fogParams;\n```","code":["private _fog = fogParams;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFog","fog","fogForecast","rainParams"],"notes":[{"user":"POLPOX","date":"2023-09-23T06:51:53Z","text":"To return a position (ASL Height)'s approx. fog level\n\n```sqf\nprivate _getFogPowerASL = {\n    fogParams params [\"_fogPower\",\"_fogDecay\",\"_fogHeight\"] ;\n    private _height = _this - _fogHeight;\n    (_fogPower * 0.5 ^ (_height * _fogDecay / 2.45) max 0)\n};\n\n(AGLToASL (positionCameraToWorld [0,0,0]) # 2) call _getFogPowerASL;\n```\n\nNote that, this could return >1 value if fogDecay is not 0."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"for","operator":null,"title":"for","type":"command","url":"https://community.bistudio.com/wiki/for","revid":353544,"updated":"2024-03-19T12:01:33Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This operator creates a For Type which is used in the for-constructs.\n\n> [!WARNING]\n> The alternative syntax `for _array do _code` is slower than the first syntax because the condition is checked in every iteration, and it has a few bugs.\n>\n> It is only kept for backward compatibility; always use the first syntax `for \"_i\" from 0 to _end do _code`.","syntaxes":[{"syntax":"for arguments","since":null,"effect":null,"exec":null,"params":[{"name":"arguments","type":"String","optional":false,"default":null,"description":"declares the index variable name like \"_myVar\". from and to are required, step is optional.","types":["String"],"since":null,"text":"arguments: String - declares the index variable name like \"_myVar\". from and to are required, step is optional."}],"returns":{"type":"For Type","types":["For Type"],"description":null,"text":"For Type"},"form":"unary","operator":null,"left":null,"right":{"text":"arguments","types":["String"]}},{"syntax":"for [init, condition, codeToExecute]","since":null,"effect":null,"exec":null,"params":[{"name":"init","type":"Code","optional":false,"default":null,"description":"loop variable definition","types":["Code"],"since":null,"text":"init: Code - loop variable definition"},{"name":"condition","type":"Code","optional":false,"default":null,"description":"called code returns false, leave the for-loop","types":["Code"],"since":null,"text":"condition: Code - called code returns false, leave the for-loop"},{"name":"codeToExecute","type":"Code","optional":false,"default":null,"description":"code to be run on each loop","types":["Code"],"since":null,"text":"codeToExecute: Code - code to be run on each loop"}],"returns":{"type":"For Type","types":["For Type"],"description":null,"text":"For Type"},"form":"unary","operator":null,"left":null,"right":{"text":"[init, condition, codeToExecute]","types":["Array"]}}],"examples":[{"text":"```sqf\n// will output 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 (the to value being inclusive)\nfor \"_i\" from 1 to 10 do { systemChat str _i; };\n```","code":["// will output 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 (the to value being inclusive)\nfor \"_i\" from 1 to 10 do { systemChat str _i; };"]},{"text":"```sqf\n// will output 9, 7, 5, 3, 1\nfor \"_i\" from 9 to 1 step -2 do { systemChat str _i; };\n```","code":["// will output 9, 7, 5, 3, 1\nfor \"_i\" from 9 to 1 step -2 do { systemChat str _i; };"]},{"text":"```sqf\n// will output 0, 1, 2, 3, 4, 5, 6, 7, 8, 9\nfor [{ _i = 0 }, { _i < 10 }, { _i = _i + 1 }] do { systemChat str _i };\n```","code":["// will output 0, 1, 2, 3, 4, 5, 6, 7, 8, 9\nfor [{ _i = 0 }, { _i < 10 }, { _i = _i + 1 }] do { systemChat str _i };"]},{"text":"```sqf\n// BAD CODE\n_i = 100;\nfor [{ _i = 0 }, { _i < 5 }, { _i = _i + 1 }] do { /* code */ };\nhint str _i; // 5\n\n// GOOD CODE (private keyword is recommended)\n_i = 100;\nfor [{ private _i = 0 }, { _i < 5 }, { _i = _i + 1 }] do { /* code */ };\nhint str _i; // 100\n\n// BEST CODE (primary syntax, fastest)\n_i = 100;\nfor \"_i\" from 0 to 4 do { /* code */ };\nhint str _i; // 100\n```","code":["// BAD CODE\n_i = 100;\nfor [{ _i = 0 }, { _i < 5 }, { _i = _i + 1 }] do { /* code */ };\nhint str _i; // 5\n\n// GOOD CODE (private keyword is recommended)\n_i = 100;\nfor [{ private _i = 0 }, { _i < 5 }, { _i = _i + 1 }] do { /* code */ };\nhint str _i; // 100\n\n// BEST CODE (primary syntax, fastest)\n_i = 100;\nfor \"_i\" from 0 to 4 do { /* code */ };\nhint str _i; // 100"]}],"multiplayer":null,"problems":"> [!NOTE]\n> **Arma 2:** There is an Arma 2 issue (not present in Arma 2:OA nor in Arma 3) where having a capital letter in the variable name **will** throw an error:\n>\n> ```sqf\n> for \"_i\" from 0 to 2 do { hintSilent str _i; }; // works\n> for \"_I\" from 0 to 2 do { hintSilent str _I; }; // \"variable _i is not defined\" error\n> ```","aliases":[],"see_also":["Control Structures","while","do"],"notes":[{"user":"Alef","date":"2010-04-29T16:06:00Z","text":"```sqf\nfor \"_i\" from 0 to  0 do {}; // will do once, with _i = 0\nfor \"_i\" from 0 to -1 do {}; // will not do\n```"},{"user":"ffur2007slx2_5","date":"2014-04-15T12:54:00Z","text":"- Arma 3 v1.16 Please note the difference between the two syntaxes; `for *arguments*` detects Boolean in each scope while `for *array*` doesn’t. e.g.\n\n| command | Structure | Summary |\n|---|---|---|\n| for *array* | ```sqf<br>a = 0; b = true;<br>for [{ _i = 0 }, { _i < 10 && b }, { _i = _i + 1 }] do<br>{<br>    a = a + 1;<br>    if (a >= 7) then {b = false}<br>};<br>``` | loop can be exited via Boolean control, possible workaround can be e.g BIS_fnc_areEqual |\n| for *arguments* | ```sqf<br>a = 0;<br>for \"_i\" from 0 to 10 do<br>{<br>    a = a + 1;<br>    if (a >= 7) exitwith {};<br>};<br>``` | has to be exited via exitWith |\n\n- Never try to tell a decimal number via binary number in a loop; otherwise the loop will be infinite:\n\n```sqf\nfor [{_a = 0},{_a != 1},{_a = _a + 0.1}] do {}; // an infinite loop; _a will never be 1 so the scope will always be true\n```\n\nAny binary number behind the decimal point is always the sum of 1/2, 1/4, 1/8, 1/16 etc. so decimal number with odd denominator like 1/3 or 1/10 cannot be exactly equal to each other.\n- Avoid too large factorial multiply which may loose the leading indicator in result. And 12 is the biggest accessable factor in this example.\n\n```sqf\nfor [{_a = 2; _b = 1;},{_a < 100},{_a = _a + 1}] do {_b = _b * _a}; // _b =  1.#INF\n```"},{"user":"Killzone_Kid","date":"2015-06-04T19:27:00Z","text":"Variable name doesn't have to start with _. could be:\n\n```sqf\nfor \"LAlala\" from 0 to 0 do { hint str LAlala }; // 0\n```\n\nThe variable *LAlala* will exist only inside do {} scope and will not overwrite any variable of the same name that existed before."},{"user":"Nickorr","date":"2015-06-04T19:45:00Z","text":"Dont use this notation if you plan to change the cycle ranges dynamically. The range values are checked only before the cycle started. Use `for *array*` instead.\n\nExample, that won't work correctly:\n\n```sqf\n_xy = [1,2,3,4,5,6,7,8,9,10];\nfor \"_i\" from 0 to (count _xy - 1) do\n{\n    if ( _xy select _i == 3 ) then\n    {\n        _xy deleteAt _i;\n        _i = _i - 1;\n    };\n};\n```\n\n(Here the  step will still be checked by the cycle, which will lead to \"out of the array range\" error.)\n\nThis code will work correctly:\n\n```sqf\n_xy = [1,2,3,4,5,6,7,8,9,10];\nfor [{_i = 1},{_i<=(count _xy - 1)},{_i=_i+1}] do\n{\n    if ( _xy select _i == 3 ) then\n    {\n        _xy deleteAt _i;\n        _i = _i - 1;\n    };\n};\n```\n\n(The last step here will be `_i = 8` with array looking like this: `[1,2,4,5,6,7,8,9,10]`)"},{"user":"DreadedEntity","date":"2016-01-29T05:18:00Z","text":"For loops can be safely nested. This means that there should not be any problems with recursion.\n\n```sqf\n_array = [];\nfor \"_i\" from 0 to 3 do\n{\n    for \"_i\" from 0 to 3 do\n    {\n        _array pushBack _i;\n    };\n    _array pushBack _i;\n};\nhint str _array;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forceAddUniform","operator":null,"title":"forceAddUniform","type":"command","url":"https://community.bistudio.com/wiki/forceAddUniform","revid":318837,"updated":"2022-05-13T09:21:54Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create a new uniform and hard link it into slot (without any restrictions).","syntaxes":[{"syntax":"unit forceAddUniform type","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_unit forceAddUniform \"U_B_CombatUniform_mcam\";\n```","code":["_unit forceAddUniform \"U_B_CombatUniform_mcam\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUniform","isUniformAllowed","removeUniform","uniform"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 1.22","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"forceAtPositionRTD","operator":null,"title":"forceAtPositionRTD","type":"command","url":"https://community.bistudio.com/wiki/forceAtPositionRTD","revid":376360,"updated":"2025-10-07T21:42:17Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds force generator to world.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"forceAtPositionRTD position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Array","optional":false,"default":null,"description":"position where to force generator is created.","types":["Array"],"since":null,"text":"position: Array - position where to force generator is created."}],"returns":{"type":"Number","types":["Number"],"description":"force index","text":"Number - force index"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Array"]}}],"examples":[{"text":"```sqf\nforceAtPositionRTD [0,0,0];\n```","code":["forceAtPositionRTD [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearForcesRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forceCadetDifficulty","operator":null,"title":"forceCadetDifficulty","type":"command","url":"https://community.bistudio.com/wiki/forceCadetDifficulty","revid":310147,"updated":"2022-05-05T12:46:27Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Forces `showCadetHints` and `showCadetWP` global Cadet Arma 3 difficulty, returns previous settings.","syntaxes":[{"syntax":"forceCadetDifficulty [showCadetHints, showCadetWP]","since":null,"effect":null,"exec":null,"params":[{"name":"showCadetHints","type":"Boolean","optional":false,"default":null,"description":"`showCadetHints` difficulty","types":["Boolean"],"since":null,"text":"showCadetHints: Boolean - `showCadetHints` difficulty"},{"name":"showCadetWP","type":"Boolean","optional":false,"default":null,"description":"`showCadetWP` difficulty","types":["Boolean"],"since":null,"text":"showCadetWP: Boolean - `showCadetWP` difficulty"}],"returns":{"type":"Array of Booleans","types":["Array","Boolean"],"description":"[prev_showCadetHints, prev_showCadetWP]","text":"Array of Booleans - [prev_showCadetHints, prev_showCadetWP]"},"form":"unary","operator":null,"left":null,"right":{"text":"[showCadetHints, showCadetWP]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _previousSettings = forceCadetDifficulty [true, false];\n```","code":["private _previousSettings = forceCadetDifficulty [true, false];"]},{"text":"```sqf\nprivate _fnc_forceCadetDifficulty = \n{\n    params [\"_OKButtonPressed\"];\n    if (_OKButtonPressed) then\n    {\n        forceCadetDifficulty (switch (toLowerANSI configName ((configFile >> \"CfgDifficultyPresets\") select difficulty)) do\n        {\n            case \"recruit\";\n            case \"regular\":\n            {\n                // showCadetHints = 1;\n                // showCadetWP = 1;\n                [true, true]\n            };\n            case \"veteran\":\n            {\n                // showCadetHints = 0;\n                // showCadetWP = 1;\n                [false, true]\n            };\n            default\n            {\n                // showCadetHints = 0;\n                // showCadetWP = 0;\n                [false, false]\n            };\n        });\n    };\n};\n[true] call _fnc_forceCadetDifficulty;\n[missionNamespace, \"OnGameOptionsExited\", _fnc_forceCadetDifficulty] call BIS_fnc_addScriptedEventHandler;\n```","code":["private _fnc_forceCadetDifficulty = \n{\n\tparams [\"_OKButtonPressed\"];\n\tif (_OKButtonPressed) then\n\t{\n\t\tforceCadetDifficulty (switch (toLowerANSI configName ((configFile >> \"CfgDifficultyPresets\") select difficulty)) do\n\t\t{\n\t\t\tcase \"recruit\";\n\t\t\tcase \"regular\":\n\t\t\t{\n\t\t\t\t// showCadetHints = 1;\n\t\t\t\t// showCadetWP = 1;\n\t\t\t\t[true, true]\n\t\t\t};\n\t\t\tcase \"veteran\":\n\t\t\t{\n\t\t\t\t// showCadetHints = 0;\n\t\t\t\t// showCadetWP = 1;\n\t\t\t\t[false, true]\n\t\t\t};\n\t\t\tdefault\n\t\t\t{\n\t\t\t\t// showCadetHints = 0;\n\t\t\t\t// showCadetWP = 0;\n\t\t\t\t[false, false]\n\t\t\t};\n\t\t});\n\t};\n};\n[true] call _fnc_forceCadetDifficulty;\n[missionNamespace, \"OnGameOptionsExited\", _fnc_forceCadetDifficulty] call BIS_fnc_addScriptedEventHandler;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficulty","cadetMode","hintCadet","Arma 3: Scripted Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"forcedMap","operator":null,"title":"forcedMap","type":"command","url":"https://community.bistudio.com/wiki/forcedMap","revid":377695,"updated":"2026-01-02T09:03:18Z","groups":["Map","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if map was forced by using forceMap command or openMap command with force option","syntaxes":[{"syntax":"forcedMap","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [forceMapForced, openMapForced]","types":["Array"],"description":"forceMapForced: Boolean - true if map was forced with forceMap command - openMapForced: Boolean - true if map was forced with openMap command.","text":"Array with [forceMapForced, openMapForced]\n- forceMapForced: Boolean - true if map was forced with forceMap command\n- openMapForced: Boolean - true if map was forced with openMap command."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_forceMapForced = forcedMap select 0;\n_openMapForced = forcedMap select 1;\n```","code":["_forceMapForced = forcedMap select 0;\n_openMapForced = forcedMap select 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["openMap","forceMap","showMap","visibleMap","shownMap"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Map","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"forceEnd","operator":null,"title":"forceEnd","type":"command","url":"https://community.bistudio.com/wiki/forceEnd","revid":318934,"updated":"2022-05-13T09:22:03Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Forces mission ending (set with endMission) even if a camera effect or any another condition delays the endMission (mostly in Operation Flashpoint).","syntaxes":[{"syntax":"forceEnd","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nforceEnd;// in an ending trigger to ensure no camera is delaying mission ending\n```","code":["forceEnd;// in an ending trigger to ensure no camera is delaying mission ending"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionEnd","failMission","endMission","enableEndDialog"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"forceFlagTexture","operator":null,"title":"forceFlagTexture","type":"command","url":"https://community.bistudio.com/wiki/forceFlagTexture","revid":348626,"updated":"2023-11-08T13:46:04Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Forces a flag texture onto a flag carrier (unit, vehicle or flag pole).\nNo flag holder is required. If `\"\"` is used as texture, the texture is removed.\nThis will override regularly owned flags.\nThis type of flag texture cannot be retrieved using flagTexture, but getForcedFlagTexture.\n\n> [!IMPORTANT]\n> Forced flag texture is an additional flag texture, which visually overrides original flag texture and therefore is very expensive to simulate, so use the functionality sparingly.","syntaxes":[{"syntax":"object forceFlagTexture texture","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle, unit or flag pole","types":["Object"],"since":null,"text":"object: Object - vehicle, unit or flag pole"},{"name":"texture","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"texture: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"texture","types":["String"]}}],"examples":[{"text":"```sqf\nplayer forceFlagTexture \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";\n```","code":["player forceFlagTexture \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getForcedFlagTexture","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"forceFollowRoad","operator":null,"title":"forceFollowRoad","type":"command","url":"https://community.bistudio.com/wiki/forceFollowRoad","revid":346816,"updated":"2023-08-05T12:44:00Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Forces the vehicle to stay on road.","syntaxes":[{"syntax":"vehicle forceFollowRoad state","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle","types":["Object"],"since":null,"text":"vehicle: Object - vehicle"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true: Force on road, false: default behaviour","types":["Boolean"],"since":null,"text":"state: Boolean - true: Force on road, false: default behaviour"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncar forceFollowRoad true;\n```","code":["car forceFollowRoad true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setConvoySeparation","limitSpeed","setDriveOnPath","useAISteeringComponent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"forceGeneratorRTD","operator":null,"title":"forceGeneratorRTD","type":"command","url":"https://community.bistudio.com/wiki/forceGeneratorRTD","revid":348782,"updated":"2023-11-08T14:33:16Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds force generator to world. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"forceGeneratorRTD index","since":null,"effect":null,"exec":null,"params":[{"name":"index","type":"Number","optional":false,"default":null,"description":"index","types":["Number"],"since":null,"text":"index: Number - index"}],"returns":{"type":"Number","types":["Number"],"description":"force index","text":"Number - force index"},"form":"unary","operator":null,"left":null,"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nforceGeneratorRTD 2;\n```","code":["forceGeneratorRTD 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearForcesRTD","forceAtPositionRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forceHitPointsDamageSync","operator":null,"title":"forceHitPointsDamageSync","type":"command","url":"https://community.bistudio.com/wiki/forceHitPointsDamageSync","revid":370215,"updated":"2024-11-09T23:07:51Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Synchronises hitpoints values and total damage across current network clients as well as JIP.\nPossible uses after executing script commands such as setHit, setHitIndex, setHitPointDamage or in conjunction with HandleDamage event handler (see #Example 2).","syntaxes":[{"syntax":"forceHitPointsDamageSync entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity","types":["Object"],"since":null,"text":"entity: Object - entity"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if sync was attempted","text":"Boolean - true if sync was attempted"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\nforceHitPointsDamageSync house1;\n```","code":["forceHitPointsDamageSync house1;"]},{"text":"```sqf\nhouse1 addEventHandler [\"HandleDamage\", \n{\n    if (isServer && { _this select 9 == 2 }) then { (_this select 0) spawn { forceHitPointsDamageSync _this; } };\n    if (_this select 7 find \"glass\" >= 0) then { _this select 2 } else { 0 };\n}];\n```","code":["house1 addEventHandler [\"HandleDamage\", \n{\n\tif (isServer && { _this select 9 == 2 }) then { (_this select 0) spawn { forceHitPointsDamageSync _this; } };\n\tif (_this select 7 find \"glass\" >= 0) then { _this select 2 } else { 0 };\n}];"]}],"multiplayer":"Static buildings synchronisation should be executed on the server as the server is the authority in building damage and you would want every client in MP to have the same level of damage as the server has.","problems":null,"aliases":[],"see_also":["getHit","getHitPointDamage","setHitPointDamage","damage","setDamage","setFuel","setAmmo","getHitIndex","setHitIndex"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"forceMap","operator":null,"title":"forceMap","type":"command","url":"https://community.bistudio.com/wiki/forceMap","revid":363365,"updated":"2024-03-27T23:45:43Z","groups":["Map","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Opens non-interactive main map in background that overrides user screen. To force open interactive map use openMap command.\n\n> [!WARNING]\n> When the map is forced open with this command, the user is still able to fire but cannot see the world, just the map.\n> The map cannot be closed manually and the user can get stuck requiring a game restart. Make sure you provide scripted mechanics to de-force the map at a later stage.","syntaxes":[{"syntax":"forceMap show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":"true to force, false to go back to normal map behaviour","types":["Boolean"],"since":null,"text":"show: Boolean - true to force, false to go back to normal map behaviour"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nforceMap true;\n```","code":["forceMap true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forcedMap","showMap","shownMap","openMap","visibleMap"],"notes":[{"user":"Ceeeb","date":"2007-02-02T05:28:00Z","text":"In **OFP v1.96**, the mapAnim series of commands, together with forceMap can only be used in the intro and mission, as it is not possible to access the map from the outro.\n*(not checked, sourced from an old copy of the OFPEC comref)*"},{"user":"Manny","date":"2007-05-05T15:43:00Z","text":"Manually opening the map afterwards won't close the map.\nActually it will open the \"real\" map on top of the forced map, and closing the (top) map with the <kbd>M</kbd> key again will still show the forcefully opened map."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Map","Introduced with Operation Flashpoint version 1.27","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"forceRespawn","operator":null,"title":"forceRespawn","type":"command","url":"https://community.bistudio.com/wiki/forceRespawn","revid":320952,"updated":"2022-05-13T10:04:47Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Forces the unit to respawn. The effect is as if the player pressed the RESPAWN button in the game pause menu; the unit is killed but there is no \"X was killed\" message and no score adjustment.","syntaxes":[{"syntax":"forceRespawn unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nforceRespawn player;\n```","code":["forceRespawn player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playerRespawnTime","setPlayerRespawnTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"forceSpeed","operator":null,"title":"forceSpeed","type":"command","url":"https://community.bistudio.com/wiki/forceSpeed","revid":378638,"updated":"2026-05-15T15:15:33Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Force the speed limit on given object (object will never attempt to move faster than given by forceSpeed). Use negative value to return to default behaviour.\n\n> [!IMPORTANT]\n> This has no effect on players.","syntaxes":[{"syntax":"object forceSpeed speed","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"speed","type":"Number","optional":false,"default":null,"description":"in metre per second","types":["Number"],"since":null,"text":"speed: Number - in metre per second"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"speed","types":["Number"]}}],"examples":[{"text":"```sqf\n_helicopter forceSpeed 150;\n```","code":["_helicopter forceSpeed 150;"]},{"text":"```sqf\n_vtol forceSpeed 0; // vtol stop and hover\n```","code":["_vtol forceSpeed 0; // vtol stop and hover "]},{"text":"```sqf\n_vtol forceSpeed -1; // vtol resume\n```","code":["_vtol forceSpeed -1; // vtol resume "]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getForcedSpeed","forceWalk","isWalking","isForcedWalk","getSpeed","limitSpeed"],"notes":[{"user":"Leopard20","date":"2021-11-17T06:49:26Z","text":"In the case of infantry units, it is recommended to use getSpeed for better and more accurate results:\n\n```sqf\n_unit forceSpeed (_unit getSpeed \"NORMAL\"); // force the unit to run\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forceUnicode","operator":null,"title":"forceUnicode","type":"command","url":"https://community.bistudio.com/wiki/forceUnicode","revid":377708,"updated":"2026-01-02T09:03:46Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"List of the commands that work with forceUnicode\n- copyFromClipboard\n- copyToClipboard\n- count\n- find\n- in\n- insert\n- reverse\n- select\n- splitString\n- trim\n- regexFind\n- regexMatch\n- regexReplace\n\nSets the Unicode flag which forces some of the string manipulation commands to switch to <https://en.wikipedia.org/wiki/Unicode>.\nThe Unicode flag is always set right after forceUnicode command execution, but is reset depending on the command mode (see *mode*).\n\nWhen the flag is set it will also affect all scopes within the script including child scopes (see diag_scope).\nThere are many other string manipulation commands like ctrlSetText, getTextWidth, etc. that support Unicode by design so no additional forcing is needed.","syntaxes":[{"syntax":"forceUnicode mode","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"Number","optional":false,"default":null,"description":"mode of operation, can be:\n- -1 - resets previously set Unicode flag\n-  0 - sets Unicode flag until the end of script\n-  1 - sets Unicode flag until after next supported command or until the end of script, whichever comes earlier","types":["Number"],"since":null,"text":"mode: Number - mode of operation, can be:\n- -1 - resets previously set Unicode flag\n-  0 - sets Unicode flag until the end of script\n-  1 - sets Unicode flag until after next supported command or until the end of script, whichever comes earlier"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"unary","operator":null,"left":null,"right":{"text":"mode","types":["Number"]}}],"examples":[{"text":"```sqf\ncopyToClipboard \"д\"; // copies \"Ð´\" to clipboard\nforceUnicode 1;\ncopyToClipboard \"д\"; // copies \"д\" to clipboard\n```","code":["copyToClipboard \"д\"; // copies \"Ð´\" to clipboard\nforceUnicode 1;\ncopyToClipboard \"д\"; // copies \"д\" to clipboard"]},{"text":"```sqf\nprivate _string = \"привет\";            // a string that uses Unicode characters\nsystemChat str count _string;        // 12 - the character count is wrong without forceUnicode\n\ncall {\n    systemChat str count _string;    // 12 - identical result\n    forceUnicode 0;\n    systemChat str count _string;    // 6 - correct result\n};\n\nsystemChat str count _string;        // 6 - outer scope is affected by forceUnicode as well, because the command mode is 0\n\nforceUnicode -1; // cancelled\n\ncall {\n    systemChat str count _string;    // 12 - wrong count\n    forceUnicode 1;\n    systemChat str count _string;    // 6 - correct result, but Unicode it reset after this operation, because command mode is 1\n};\n\nsystemChat str count _string;        // 12 - outer scope is not affected as it was reset right after count\n```","code":["private _string = \"привет\";\t\t\t// a string that uses Unicode characters\nsystemChat str count _string;\t\t// 12 - the character count is wrong without forceUnicode\n\ncall {\n\tsystemChat str count _string;\t// 12 - identical result\n\tforceUnicode 0;\n\tsystemChat str count _string;\t// 6 - correct result\n};\n\nsystemChat str count _string;\t\t// 6 - outer scope is affected by forceUnicode as well, because the command mode is 0\n\nforceUnicode -1; // cancelled\n\ncall {\n\tsystemChat str count _string;\t// 12 - wrong count\n\tforceUnicode 1;\n\tsystemChat str count _string;\t// 6 - correct result, but Unicode it reset after this operation, because command mode is 1\n};\n\nsystemChat str count _string;\t\t// 12 - outer scope is not affected as it was reset right after count"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["copyToClipboard","copyFromClipboard","select","count","in","insert","find","splitString","reverse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"forceWalk","operator":null,"title":"forceWalk","type":"command","url":"https://community.bistudio.com/wiki/forceWalk","revid":310282,"updated":"2022-05-05T13:11:25Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Forces unit to walk even if run or sprint is selected.","syntaxes":[{"syntax":"unit forceWalk value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the unit forced to walk","types":["Object"],"since":null,"text":"unit: Object - the unit forced to walk"},{"name":"value","type":"Boolean","optional":false,"default":null,"description":"true/false","types":["Boolean"],"since":null,"text":"value: Boolean - true/false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer forceWalk true;\n```","code":["player forceWalk true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isForcedWalk","isWalking","forceSpeed","getSpeed"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forceWeaponFire","operator":null,"title":"forceWeaponFire","type":"command","url":"https://community.bistudio.com/wiki/forceWeaponFire","revid":369347,"updated":"2024-09-03T18:43:03Z","groups":["Unit Control","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"The unit will be forced to fire weapon from the given muzzle. The weapon will not fire if firemode passed as parameter is not supported by the given muzzle. The muzzle could belong to a vehicle weapon and unit in this case will be the unit operating this weapon. Doesnt't seem to work for units in FFV positions. Works on player. See also: BIS_fnc_fire","syntaxes":[{"syntax":"unit forceWeaponFire [muzzle, firemode]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit alone or in vehicle","types":["Object"],"since":null,"text":"unit: Object - unit alone or in vehicle"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"muzzle: String"},{"name":"firemode","type":"String","optional":false,"default":null,"description":"common options are \"Single\", \"Burst\", \"FullAuto\". For the full list of a weapon firemodes:\n\n```sqf\nhint str (getArray (configFile >> \"CfgWeapons\" >> currentWeapon player >> \"modes\"));\n```\n\n If *modes[]* param in config for the weapon says *{\"this\"}*, then the same classname as for the weapon param (currentWeapon player) should be used as firemode param.","types":["String"],"since":null,"text":"firemode: String - common options are \"Single\", \"Burst\", \"FullAuto\". For the full list of a weapon firemodes:\n\n```sqf\nhint str (getArray (configFile >> \"CfgWeapons\" >> currentWeapon player >> \"modes\"));\n```\n\n If *modes[]* param in config for the weapon says *{\"this\"}*, then the same classname as for the weapon param (currentWeapon player) should be used as firemode param."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[muzzle, firemode]","types":["Array"]}}],"examples":[{"text":"```sqf\n_unit forceWeaponFire [\"arifle_MX_F\", \"Single\"];\n_unit forceWeaponFire [\"hgun_ACPC2_F\", \"hgun_ACPC2_F\"];\n_unit forceWeaponFire [\"HandGrenadeMuzzle\",\"HandGrenadeMuzzle\"];\n_unit forceWeaponFire [\"MiniGrenadeMuzzle\",\"MiniGrenadeMuzzle\"];\n_unit forceWeaponFire [\"HandGrenade_Stone\",\"HandGrenade_Stone\"];\n_unit forceWeaponFire [\"SmokeShellMuzzle\",\"SmokeShellMuzzle\"];\n_unit forceWeaponFire [\"ChemlightGreenMuzzle\",\"ChemlightGreenMuzzle\"];\n_unit forceWeaponFire [\"IRGrenade\",\"IRGrenade\"];\n_unit forceWeaponFire [\"Laserdesignator\",\"Laserdesignator\"];\n```","code":["_unit forceWeaponFire [\"arifle_MX_F\", \"Single\"];\n_unit forceWeaponFire [\"hgun_ACPC2_F\", \"hgun_ACPC2_F\"];\n_unit forceWeaponFire [\"HandGrenadeMuzzle\",\"HandGrenadeMuzzle\"];\n_unit forceWeaponFire [\"MiniGrenadeMuzzle\",\"MiniGrenadeMuzzle\"];\n_unit forceWeaponFire [\"HandGrenade_Stone\",\"HandGrenade_Stone\"];\n_unit forceWeaponFire [\"SmokeShellMuzzle\",\"SmokeShellMuzzle\"];\n_unit forceWeaponFire [\"ChemlightGreenMuzzle\",\"ChemlightGreenMuzzle\"];\n_unit forceWeaponFire [\"IRGrenade\",\"IRGrenade\"];\n_unit forceWeaponFire [\"Laserdesignator\",\"Laserdesignator\"];"]},{"text":"```sqf\ngunner blackfoot forceWeaponFire [\"gatling_20mm\", \"close\"];\n```","code":["gunner blackfoot forceWeaponFire [\"gatling_20mm\", \"close\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentWeapon","currentWeaponMode","setWeaponReloadingTime","selectWeapon","fire","doFire","commandFire","canFire","fireAtTarget","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire","isManualFire","BIS_fnc_fire"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Command Group: Weapons","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"forceWeatherChange","operator":null,"title":"forceWeatherChange","type":"command","url":"https://community.bistudio.com/wiki/forceWeatherChange","revid":369386,"updated":"2024-09-03T18:43:16Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Forcibly applies previously set weather settings. Skips smooth transitions. This might cause lag.\n\n> [!NOTE]\n> To prevent the engine from overwriting custom weather settings, enable the *Manual Control* settings in Eden Editor's intel section.","syntaxes":[{"syntax":"forceWeatherChange","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n0 setOvercast 1;\n0 setRain 1;\nforceWeatherChange; // Force immediate change overriding smooth transitions\n```","code":["0 setOvercast 1;\n0 setRain 1;\nforceWeatherChange; // Force immediate change overriding smooth transitions"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fog","fogForecast","setFog","overcast","setOvercast","overcastForecast","nextWeatherChange","rain","setRain","setWind","simulWeatherSync"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"forEach","operator":null,"title":"forEach","type":"command","url":"https://community.bistudio.com/wiki/forEach","revid":378167,"updated":"2026-03-02T16:49:17Z","groups":["Program Flow","Arrays","HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given command(s) on every item of an Array or a HashMap.\n\n> [!NOTE]\n> **Arma 2:** Since Arma 2, the variable _x is always private to the forEach block so it is safe to nest them (see #Example 8).","syntaxes":[{"syntax":"code forEach array","since":null,"effect":null,"exec":null,"params":[{"name":"|  |  |  |  |  |  |  |  |","type":null,"optional":false,"default":null,"description":"|  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|\n| Game | Operation Flashpoint v1.00 | Operation Flashpoint v1.85 | Armed Assault v1.00 | Arma 2 v1.00 | Arma 2: Operation Arrowhead v1.50 | Arma 3 v1.00 | Take On Helicopters v1.00 |\n| String support | ✓ | ✗ |  |  |  |  |  |\n| Code support | ✗ | ✓ |  |  |  |  |  |\n\ncode: String only in Operation Flashpoint until v1.85 or Arma: Cold War Assault v1.85 Code - available variables:\n- `_x`: iterated item\n- Arma 2: Operation Arrowhead v1.55 `_forEachIndex`: item's index","types":[],"since":null,"text":"|  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|\n| Game | Operation Flashpoint v1.00 | Operation Flashpoint v1.85 | Armed Assault v1.00 | Arma 2 v1.00 | Arma 2: Operation Arrowhead v1.50 | Arma 3 v1.00 | Take On Helicopters v1.00 |\n| String support | ✓ | ✗ |  |  |  |  |  |\n| Code support | ✗ | ✓ |  |  |  |  |  |\n\ncode: String only in Operation Flashpoint until v1.85 or Arma: Cold War Assault v1.85 Code - available variables:\n- `_x`: iterated item\n- Arma 2: Operation Arrowhead v1.55 `_forEachIndex`: item's index"},{"name":"array","type":"Array","optional":false,"default":null,"description":"the array to iterate over","types":["Array"],"since":null,"text":"array: Array - the array to iterate over"}],"returns":{"type":"Anything","types":["Anything"],"description":"will return the value of last executed statement","text":"Anything - will return the value of last executed statement"},"form":"binary","operator":null,"left":{"text":"code","types":[]},"right":{"text":"array","types":["Array"]}},{"syntax":"code forEach hashMap","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"code applied to each key-value pair - available variables:\n- `_x`: key\n- `_y`: value\n- `_forEachIndex`: iteration number","types":["Code"],"since":null,"text":"code: Code - code applied to each key-value pair - available variables:\n- `_x`: key\n- `_y`: value\n- `_forEachIndex`: iteration number"},{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":"the HashMap to iterate over","types":["HashMap"],"since":null,"text":"hashMap : HashMap - the HashMap to iterate over"}],"returns":{"type":"Anything","types":["Anything"],"description":"will return the value of last executed statement","text":"Anything - will return the value of last executed statement"},"form":"binary","operator":null,"left":{"text":"code","types":["Code"]},"right":{"text":"hashMap","types":["HashMap"]}}],"examples":[{"text":"```sqf\n// SQF\n{ _x setDamage 1 } forEach units player;\n```\n\n```sqs\n; SQS\n\"_x setDammage 1\" forEach units player\n```","code":["// SQF\n{ _x setDamage 1 } forEach units player;","; SQS\n\"_x setDammage 1\" forEach units player"]},{"text":"This command can also easily be used to execute a single command multiple times without respect to the array items - see also for\n\n```sqf\n{ player addMagazine \"30Rnd_556x45_Stanag\" } forEach [1, 2, 3, 4];\n// equivalent to\nfor \"_i\" from 1 to 4 do { player addMagazine \"30Rnd_556x45_Stanag\" };\n```","code":["{ player addMagazine \"30Rnd_556x45_Stanag\" } forEach [1, 2, 3, 4];\n// equivalent to\nfor \"_i\" from 1 to 4 do { player addMagazine \"30Rnd_556x45_Stanag\" };"]},{"text":"You can also use multiple commands in the same block:\n\n```sqf\n{\n    _x setCaptive true;\n    removeAllWeapons _x;\n    doStop _x;\n} forEach units group this;\n```","code":["{\n\t_x setCaptive true;\n\tremoveAllWeapons _x;\n\tdoStop _x;\n} forEach units group this;"]},{"text":"To get the index of a forEach loop, use _forEachIndex:\n\n```sqf\n{ systemChat str _forEachIndex; } forEach [\"a\", \"b\", \"c\"]; // will return: \"0\", \"1\", \"2\" in systemChat messages\n```","code":["{ systemChat str _forEachIndex; } forEach [\"a\", \"b\", \"c\"]; // will return: \"0\", \"1\", \"2\" in systemChat messages"]},{"text":"Iterating a HashMap's _forEachIndex:\n\n```sqf\n// shows \"0, k1, v1\", \"1, k2, v2\" in systemChat messages\n{\n    systemChat format [\"%1, %2, %3\", _forEachIndex, _x, _y];\n} forEach createHashMapFromArray [\n    [\"k1\", \"v1\"],\n    [\"k2\", \"v2\"]\n];\n```","code":["// shows \"0, k1, v1\", \"1, k2, v2\" in systemChat messages\n{\n\tsystemChat format [\"%1, %2, %3\", _forEachIndex, _x, _y];\n} forEach createHashMapFromArray [\n\t[\"k1\", \"v1\"],\n\t[\"k2\", \"v2\"]\n];"]},{"text":"findIf equivalent for HashMap:\n\n```sqf\nprivate _resultKey = {\n    if (_y isEqualTo \"wantedValue\") exitWith { _x };\n    \"\"\n} forEach _hashmap;\n```","code":["private _resultKey = {\n\tif (_y isEqualTo \"wantedValue\") exitWith { _x };\n\t\"\"\n} forEach _hashmap;"]},{"text":"Array is edited by reference:\n\n```sqf\n_arr1 = [1,2,3];\n_arr2 = [6,7,8];\n_arr3 = [0];\n{ _x set [1, \"changed\"] } forEach [_arr1, _arr2, _arr3];\n// _arr1 = [1, \"changed\", 3]\n// _arr2 = [6, \"changed\", 8]\n// _arr3 = [0, \"changed\"]\n```","code":["_arr1 = [1,2,3];\n_arr2 = [6,7,8];\n_arr3 = [0];\n{ _x set [1, \"changed\"] } forEach [_arr1, _arr2, _arr3];\n// _arr1 = [1, \"changed\", 3]\n// _arr2 = [6, \"changed\", 8]\n// _arr3 = [0, \"changed\"]"]},{"text":"```sqf\n{\n    private _verticalValue = _x; // needed, otherwise _horizontalValues' _x made this one inaccessible\n    {\n        [_x, _verticalValue] call TAG_fnc_doSomething;\n    } forEach _horizontalValues;\n} forEach _verticalValues;\n```","code":["{\n\tprivate _verticalValue = _x; // needed, otherwise _horizontalValues' _x made this one inaccessible\n\t{\n\t\t[_x, _verticalValue] call TAG_fnc_doSomething;\n\t} forEach _horizontalValues;\n} forEach _verticalValues;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","for","apply","while","select","findIf","count","forEachReversed"],"notes":[{"user":"Dedmen","date":"2017-11-28T13:46:00Z","text":"Be careful when deleting (deleteAt) elements from an Array while you iterate over it.\n\n_forEachIndex will not move to reflect your change.\n\nThe forEach code is doing the same as\n\n```sqf\nprivate _forEachIndex = 0;\nwhile { _forEachIndex < count _array } do\n{\n    (_array select _forEachIndex) call code;\n    _forEachIndex = _forEachIndex + 1;\n};\n```\n\nSo if you delete your current element from the array the other elements will shift forward. Meaning you skip one element.\n\nExample:\n\n```sqf\n_array = [1,2,3,4,5,6];\n{ _array deleteAt _forEachIndex } forEach _array;\n```\n\nAfter the first iteration your Array will be [2,3,4,5,6] and the _forEachIndex will be 1.\n\nSo on next iteration you get the element at index 1 which will be 3. So you've just skipped the 2.\n\nSo in the end you will only iterate over 1, 3 and 6."},{"user":"Sa-Matra","date":"2023-04-02T09:04:28Z","text":"Use new forEachReversed command for deleting array items with deleteAt. Check its examples for details."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forEachMember","operator":null,"title":"forEachMember","type":"command","url":"https://community.bistudio.com/wiki/forEachMember","revid":330644,"updated":"2022-10-03T11:04:22Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given command recursively for both teams and agents that are members of the given team. For teams only use forEachMemberTeam. For agents only use forEachMemberAgent.","syntaxes":[{"syntax":"command forEachMember team","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"command: Code"},{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"command","types":["Code"]},"right":{"text":"team","types":["Team Member"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","teamType","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forEachMemberAgent","operator":null,"title":"forEachMemberAgent","type":"command","url":"https://community.bistudio.com/wiki/forEachMemberAgent","revid":330640,"updated":"2022-10-03T11:04:22Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given command recursively for each agent that is a member of the given team. For just teams use forEachMemberTeam. For both teams and agents use forEachMember.","syntaxes":[{"syntax":"command forEachMemberAgent team","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"command: Code"},{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"command","types":["Code"]},"right":{"text":"team","types":["Team Member"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["agent","agents","createAgent","isAgent","addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","teamType","forEachMember"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forEachMemberTeam","operator":null,"title":"forEachMemberTeam","type":"command","url":"https://community.bistudio.com/wiki/forEachMemberTeam","revid":330646,"updated":"2022-10-03T11:04:22Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given command recursively for each team that is a member of the given team. For just agents use forEachMemberAgent. For both teams and agents use forEachMember.","syntaxes":[{"syntax":"command forEachMemberTeam team","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"command: Code"},{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"command","types":["Code"]},"right":{"text":"team","types":["Team Member"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","removeTeamMember","teamMember","teamName","teams","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"forEachReversed","operator":null,"title":"forEachReversed","type":"command","url":"https://community.bistudio.com/wiki/forEachReversed","revid":353029,"updated":"2024-03-12T11:42:13Z","groups":["Program Flow","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given command(s) on every item of an Array in reversed order, compared to forEach.","syntaxes":[{"syntax":"code forEachReversed array","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code to execute on each array item","optional":false,"default":null,"description":"available variables:\n- `_x`: iterated item\n- `_forEachIndex`: item's index","types":["Code"],"since":null,"text":"code: Code to execute on each array item - available variables:\n- `_x`: iterated item\n- `_forEachIndex`: item's index"},{"name":"array","type":"Array","optional":false,"default":null,"description":"the array to iterate over","types":["Array"],"since":null,"text":"array: Array - the array to iterate over"}],"returns":{"type":"Anything","types":["Anything"],"description":"will return the value of last executed statement","text":"Anything - will return the value of last executed statement"},"form":"binary","operator":null,"left":{"text":"code","types":["Code"]},"right":{"text":"array","types":["Array"]}}],"examples":[{"text":"This command lets you easily iterate through an array from last to first element without modifying the array itself with reverse or using for loop with negative step.\n\n```sqf\n// Will show numbers from 5 to 1 in the chat\n{ systemChat str _x } forEachReversed [1, 2, 3, 4, 5];\n```","code":["// Will show numbers from 5 to 1 in the chat\n{ systemChat str _x } forEachReversed [1, 2, 3, 4, 5];"]},{"text":"Can be useful to walk through array while also deleting items from it, which you couldn't do with forEach as easily:\n\n```sqf\nprivate _array = [1, 1, 2, 2, 1, 1, 2, 2];\n{\n    if (_x == 2) then { _array deleteAt _forEachIndex };\n} forEachReversed _array;\n// _array will be [1,1,1,1] here\n```\n\nWill not work with forEach as you might expect it:\n\n```sqf\nprivate _array = [1, 1, 2, 2, 1, 1, 2, 2];\n{\n    if (_x == 2) then { _array deleteAt _forEachIndex };\n} forEach _array;\n// _array will be [1, 1, 2, 1, 1, 2] here\n```","code":["private _array = [1, 1, 2, 2, 1, 1, 2, 2];\n{\n\tif (_x == 2) then { _array deleteAt _forEachIndex };\n} forEachReversed _array;\n// _array will be [1,1,1,1] here","private _array = [1, 1, 2, 2, 1, 1, 2, 2];\n{\n\tif (_x == 2) then { _array deleteAt _forEachIndex };\n} forEach _array;\n// _array will be [1, 1, 2, 1, 1, 2] here"]},{"text":"Deleting items from array with more complex condition than just comparison.\n\n```sqf\n{\n    if (!alive _x) then { _vehicles deleteAt _forEachIndex };\n} forEachReversed _vehicles;\n```","code":["{\n\tif (!alive _x) then { _vehicles deleteAt _forEachIndex };\n} forEachReversed _vehicles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","forEach","for","apply","while","select","findIf","count","deleteAt","reverse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Program Flow","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"forgetTarget","operator":null,"title":"forgetTarget","type":"command","url":"https://community.bistudio.com/wiki/forgetTarget","revid":332529,"updated":"2022-12-01T12:21:06Z","groups":["Unit Control","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Resets the info a group has about a target, forcing knowsAbout value to 0.","syntaxes":[{"syntax":"group forgetTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group or Object","optional":false,"default":null,"description":"group itself or unit in a group","types":["Group","Object"],"since":null,"text":"group: Group or Object - group itself or unit in a group"},{"name":"target","type":"Object","optional":false,"default":null,"description":"group target","types":["Object"],"since":null,"text":"target: Object - group target"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group","Object"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\nsoldier1 forgetTarget soldier2;\n```","code":["soldier1 forgetTarget soldier2;"]},{"text":"Give enemyBob some amnesia:\n\n```sqf\nonEachFrame { enemyBob forgetTarget player };\n```","code":["onEachFrame { enemyBob forgetTarget player };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["knowsAbout","targetsQuery","targetsAggregate","nearTargets","reveal","getHideFrom","targetKnowledge"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Unit Control","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"format","operator":null,"title":"format","type":"command","url":"https://community.bistudio.com/wiki/format","revid":378210,"updated":"2026-03-13T14:09:11Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Composes a string containing other variables or other variable types. Converts any variable type to a string.\n\n> [!IMPORTANT]\n> - To convert a string back to a number, see parseNumber.\n> - joinString can be a bit faster, without string length limitation.\n\n> [!NOTE]\n> - the maximum length of the string is 8,388,608 characters (was *8191* before)\n> - two consecutive percent symbols will be formatted to a single percent symbol in the final string (see #Example 3)\n> Since Arma 3 v2.18","syntaxes":[{"syntax":"format [formatString, var1, var2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"formatString","type":"String","optional":false,"default":null,"description":"a string containing text and/or references to the variables listed below in the array. The references appear in the form of %1, %2 etc.","types":["String"],"since":null,"text":"formatString: String - a string containing text and/or references to the variables listed below in the array. The references appear in the form of %1, %2 etc."},{"name":"varN","type":"Anything","optional":false,"default":null,"description":"variable referenced by %N","types":["Anything"],"since":null,"text":"varN: Anything - variable referenced by %N"}],"returns":{"type":"String","types":["String"],"description":"the full string (up to 8kb, see above) is returned.","text":"String - the full string (up to 8kb, see above) is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"[formatString, var1, var2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\nformat [\"Player:%1, player's side:%2\", player, side player]; // returns \"Player:WEST 1-1-A:1 (Username), player's side:WEST\"\n```","code":["format [\"Player:%1, player's side:%2\", player, side player]; // returns \"Player:WEST 1-1-A:1 (Username), player's side:WEST\""]},{"text":"```sqf\nplayer addEventHandler [\"HandleDamage\", {\n    hint format [\"You just sustained %1%2 damage!\", ceil ((_this select 2) * 100), \"%\"];\n}]; // Shows \"You just sustained 20% damage!\"\n```","code":["player addEventHandler [\"HandleDamage\", {\n\thint format [\"You just sustained %1%2 damage!\", ceil ((_this select 2) * 100), \"%\"];\n}]; // Shows \"You just sustained 20% damage!\""]},{"text":"```sqf\n// Since Arma 3 v2.18 two consecutive percent symbols will be formatted to a single percent symbol in the final string (%% -> %)\nplayer addEventHandler [\"HandleDamage\", {\n    hint format [\"You just sustained %1%% damage!\", ceil ((_this select 2) * 100)];\n}]; // Shows \"You just sustained 20% damage!\"\n```","code":["// Since Arma 3 v2.18 two consecutive percent symbols will be formatted to a single percent symbol in the final string (%% -> %)\nplayer addEventHandler [\"HandleDamage\", {\n\thint format [\"You just sustained %1%% damage!\", ceil ((_this select 2) * 100)];\n}]; // Shows \"You just sustained 20% damage!\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["formatText","endl","str","toString","joinString"],"notes":[{"user":"Worldeater","date":"2009-03-02T15:12:00Z","text":"The maximum number of characters returned by the *format* command seems to depend on the total byte count. For plain ASCII strings the limit is 2048 characters."},{"user":"Heeeere's Johnny!","date":"2015-03-28T09:22:00Z","text":"In addition to the note above, formatTexted strings are Structured Text, hence cannot be used like formatted strings (with most scripting commands). A workaround to get strings of type String with more than 8191 characters is:\n\n```sqf\nstr formatText [\"%1\", _string]\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formation","operator":null,"title":"formation","type":"command","url":"https://community.bistudio.com/wiki/formation","revid":348443,"updated":"2023-11-08T13:00:16Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the current formation of a group.","syntaxes":[{"syntax":"formation target","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"target: Object or Group"}],"returns":{"type":"String","types":["String"],"description":"can return: - \"COLUMN\" - \"STAG COLUMN\" - \"WEDGE\" - \"ECH LEFT\" - \"ECH RIGHT\" - \"VEE\" - \"LINE\" - \"FILE\" - \"DIAMOND\"","text":"String - can return:\n- \"COLUMN\"\n- \"STAG COLUMN\"\n- \"WEDGE\"\n- \"ECH LEFT\"\n- \"ECH RIGHT\"\n- \"VEE\"\n- \"LINE\"\n- \"FILE\"\n- \"DIAMOND\""},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object","Group"]}}],"examples":[{"text":"```sqf\nif (formation group player == \"wedge\") then { hint \"this is the default formation\" };\n```","code":["if (formation group player == \"wedge\") then { hint \"this is the default formation\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["2D Editor: Waypoints","formLeader","setFormation"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formationDirection","operator":null,"title":"formationDirection","type":"command","url":"https://community.bistudio.com/wiki/formationDirection","revid":310863,"updated":"2022-05-07T20:24:09Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Return the direction in degrees of the 'unit' watching in formation.","syntaxes":[{"syntax":"formationDirection unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_degrees = formationDirection _unit;\n```","code":["_degrees = formationDirection _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFormDir","formation","setFormation"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formationLeader","operator":null,"title":"formationLeader","type":"command","url":"https://community.bistudio.com/wiki/formationLeader","revid":369160,"updated":"2024-09-03T10:34:40Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return leader of the formation.","syntaxes":[{"syntax":"formationLeader unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nif (formationLeader player != leader player) then\n{\n    hint \"Formation leader is not the group leader.\";\n};\n```","code":["if (formationLeader player != leader player) then\n{\n\thint \"Formation leader is not the group leader.\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFollow","doFollow","formLeader","isFormationLeader","leader","selectLeader","setLeader"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formationMembers","operator":null,"title":"formationMembers","type":"command","url":"https://community.bistudio.com/wiki/formationMembers","revid":377161,"updated":"2026-01-01T10:40:57Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return list of units (drivers) in the formation.","syntaxes":[{"syntax":"formationMembers person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_drivers = formationMembers _person;\n```","code":["_drivers = formationMembers _person;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["formation","setFormation","driver"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formationPosition","operator":null,"title":"formationPosition","type":"command","url":"https://community.bistudio.com/wiki/formationPosition","revid":309288,"updated":"2022-05-05T01:47:09Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return position of unit in the formation.","syntaxes":[{"syntax":"formationPosition unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Position","types":["Position"],"description":null,"text":"Position"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_pos = formationPosition _unit;\n```","code":["_pos = formationPosition _unit;"]},{"text":"```sqf\n// Reposition entire group to a new position (ground level)\nprivate _group = group player;\nprivate _leader = leader _group;\n\n// Set the leader to the spawn position\n_leader setPosATL markerPos \"spawn_position\";\n\n// Reposition all units of the group except the leader\n{\n    private _formationPos = formationPosition _x;\n    _formationPos set [2, 0];\n    _x setPosATL _formationPos;\n} forEach (units _group - [_leader]);\n```","code":["// Reposition entire group to a new position (ground level)\nprivate _group = group player;\nprivate _leader = leader _group;\n\n// Set the leader to the spawn position\n_leader setPosATL markerPos \"spawn_position\";\n\n// Reposition all units of the group except the leader\n{\n\tprivate _formationPos = formationPosition _x;\n\t_formationPos set [2, 0];\n\t_x setPosATL _formationPos;\n} forEach (units _group - [_leader]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["formation"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formationTask","operator":null,"title":"formationTask","type":"command","url":"https://community.bistudio.com/wiki/formationTask","revid":310864,"updated":"2022-05-07T20:24:09Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current task of the unit in the formation.","syntaxes":[{"syntax":"formationTask unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String: \"EXCLUDED\", \"MOVE\", \"COVER\", \"LEADER\", \"NOTHING\"","types":["String"],"description":null,"text":"String: \"EXCLUDED\", \"MOVE\", \"COVER\", \"LEADER\", \"NOTHING\""},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_currentTask = formationTask _unit;\n```","code":["_currentTask = formationTask _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFormationTask"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formatText","operator":null,"title":"formatText","type":"command","url":"https://community.bistudio.com/wiki/formatText","revid":351276,"updated":"2023-11-27T02:21:39Z","groups":["Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a Structured Text similar to format command.","syntaxes":[{"syntax":"formatText [format, argument1, argument2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"format","type":"String","optional":false,"default":null,"description":"a string containing text and/or references to the variables listed below in the array. The references appear in the form of %1, %2 etc.","types":["String"],"since":null,"text":"format: String - a string containing text and/or references to the variables listed below in the array. The references appear in the form of %1, %2 etc."},{"name":"argumentN","type":"Anything","optional":false,"default":null,"description":"use Structured Text where necessary (see Example 2)","types":["Anything"],"since":null,"text":"argumentN: Anything - use Structured Text where necessary (see Example 2)"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"[format, argument1, argument2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\nhint formatText [\"Image: %1\", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];\n```","code":["hint formatText [\"Image: %1\", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];"]},{"text":"```sqf\nhint formatText [\"%1%2%3\", \"line1\", \"<br/>\", \"line2\"];        // result displayed in one line\nhint formatText [\"%1%2%3\", \"line1\", lineBreak, \"line2\"];    // result displayed in two lines\n```","code":["hint formatText [\"%1%2%3\", \"line1\", \"<br/>\", \"line2\"];\t\t// result displayed in one line\nhint formatText [\"%1%2%3\", \"line1\", lineBreak, \"line2\"];\t// result displayed in two lines"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Structured Text","format","composeText","text","parseText"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: Structured Text","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"formLeader","operator":null,"title":"formLeader","type":"command","url":"https://community.bistudio.com/wiki/formLeader","revid":369162,"updated":"2024-09-03T10:34:40Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the formation leader of a given unit.\nThis is often the same as the group leader, but not always, for example in cases when a unit is ordered to follow another unit.","syntaxes":[{"syntax":"formLeader unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Object","types":["Object"],"description":"the leader of the formation is returned. If used on a dead unit, the returned value is objNull","text":"Object - the leader of the formation is returned. If used on a dead unit, the returned value is objNull"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nif (formLeader player != leader player) then\n{\n    hint \"The formation leader is different to the group leader!\";\n};\n```","code":["if (formLeader player != leader player) then\n{\n\thint \"The formation leader is different to the group leader!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFollow","doFollow","formationLeader","isFormationLeader","leader","selectLeader","setLeader"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"freeExtension","operator":null,"title":"freeExtension","type":"command","url":"https://community.bistudio.com/wiki/freeExtension","revid":370269,"updated":"2024-11-19T18:00:17Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unloads given extension loaded previously with callExtension so that extension developer could rapidly tweak developed extension without restarting the game.\n\n> [!IMPORTANT]\n> This command was introduced in Arma 3 dev v2.11.149751 and for security reasons is only effective in DevBranch; it does nothing in stable branch.","syntaxes":[{"syntax":"freeExtension extension","since":null,"effect":null,"exec":null,"params":[{"name":"extension","type":"String","optional":false,"default":null,"description":"extension name (see callExtension)","types":["String"],"since":null,"text":"extension: String - extension name (see callExtension)"}],"returns":{"type":"Boolean or Nothing","types":["Boolean","Nothing"],"description":"false if extension unloading attempt failed, true otherwise - Nothing if not dev branch","text":"Boolean or Nothing\n- false if extension unloading attempt failed, true otherwise\n- Nothing if not dev branch"},"form":"unary","operator":null,"left":null,"right":{"text":"extension","types":["String"]}}],"examples":[{"text":"```sqf\nfreeExtension \"myExt\";\n```","code":["freeExtension \"myExt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["callExtension"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"freeLook","operator":null,"title":"freeLook","type":"command","url":"https://community.bistudio.com/wiki/freeLook","revid":369220,"updated":"2024-09-03T10:34:54Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if freelook is active on the current machine's controlled character.","syntaxes":[{"syntax":"freeLook","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if freelook is active, false otherwise","text":"Boolean - true if freelook is active, false otherwise"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif freeLook then\n{\n    systemChat \"Quit looking around, soldier!\";\n};\n```","code":["if freeLook then\n{\n\tsystemChat \"Quit looking around, soldier!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lookAt"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"from","operator":null,"title":"from","type":"command","url":"https://community.bistudio.com/wiki/from","revid":311162,"updated":"2022-05-12T09:47:42Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Continue sequence of for construct. It sets the start value of the index variable.","syntaxes":[{"syntax":"for from b","since":null,"effect":null,"exec":null,"params":[{"name":"for","type":"For Type","optional":false,"default":null,"description":null,"types":["For Type"],"since":null,"text":"for: For Type"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"For Type","types":["For Type"],"description":null,"text":"For Type"},"form":"binary","operator":null,"left":{"text":"for","types":["For Type"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nfor \"_i\" from 10 to 20 do\n{\n    hint str _i; // will hint from 10 to 20, spaced by 1 second\n    sleep 1;\n};\n```","code":["for \"_i\" from 10 to 20 do\n{\n\thint str _i; // will hint from 10 to 20, spaced by 1 second\n\tsleep 1;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fromEditor","operator":null,"title":"fromEditor","type":"command","url":"https://community.bistudio.com/wiki/fromEditor","revid":323010,"updated":"2022-06-28T21:43:06Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return if given team was inserted directly from mission editor.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"fromEditor teamMember","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"teamMember","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_fromEditor = fromEditor _member;\n```","code":["_fromEditor = fromEditor _member;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fromJSON","operator":null,"title":"fromJSON","type":"command","url":"https://community.bistudio.com/wiki/fromJSON","revid":373363,"updated":"2025-04-29T02:36:28Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Obtain the game value from the provided [JSON](https://en.wikipedia.org/wiki/JSON)-formatted string.","syntaxes":[{"syntax":"fromJSON jsonValue","since":null,"effect":null,"exec":null,"params":[{"name":"jsonValue","type":"String","optional":false,"default":null,"description":"JSON data","types":["String"],"since":null,"text":"jsonValue: String - JSON data"}],"returns":{"type":"Can be one of:","types":[],"description":"HashMap - Array - Number - String - Boolean - nil","text":"Can be one of:\n- HashMap\n- Array\n- Number\n- String\n- Boolean\n- nil"},"form":"unary","operator":null,"left":null,"right":{"text":"jsonValue","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _myNumber = fromJSON \"42\";                                            // _myNumber is 42\nprivate _myString = fromJSON \"\"\"Hello there\"\"\";                                // _myString is \"Hello there\"\nprivate _myArray = fromJSON \"[42, \"\"Hello there\"\", true]\";                    // _myArray is [42, \"Hello there\", true]\nprivate _myHash = fromJSON \"{\"\"key1\"\": \"\"value1\"\", \"\"key2\"\": \"\"value2\"\"}\"    // _myHash is [[\"key2\", \"value2\"], [\"key1\", \"value1\"]]\n\n// Important: [] indicates array, {} and : indicates hash\n```","code":["private _myNumber = fromJSON \"42\";\t\t\t\t\t\t\t\t\t\t\t// _myNumber is 42\nprivate _myString = fromJSON \"\"\"Hello there\"\"\";\t\t\t\t\t\t\t\t// _myString is \"Hello there\"\nprivate _myArray = fromJSON \"[42, \"\"Hello there\"\", true]\";\t\t\t\t\t// _myArray is [42, \"Hello there\", true]\nprivate _myHash = fromJSON \"{\"\"key1\"\": \"\"value1\"\", \"\"key2\"\": \"\"value2\"\"}\"\t// _myHash is [[\"key2\", \"value2\"], [\"key1\", \"value1\"]]\n\n// Important: [] indicates array, {} and : indicates hash"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toJSON","parseSimpleArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"fuel","operator":null,"title":"fuel","type":"command","url":"https://community.bistudio.com/wiki/fuel","revid":376958,"updated":"2026-01-01T05:49:41Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks how much fuel is left in the gas tank of a vehicle.","syntaxes":[{"syntax":"fuel vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":"0 (empty tank) to 1 (full tank).","text":"Number in range 0..1 - 0 (empty tank) to 1 (full tank)."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (fuel vehicle player == 0) then { hint \"The vehicle is out of fuel!\" };\n```","code":["if (fuel vehicle player == 0) then { hint \"The vehicle is out of fuel!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFuel","setFuelCargo","getFuelCargo"],"notes":[{"user":"UNN","date":"2006-08-13T12:36:00Z","text":"Vehicles refuelled in game with the Fuel trucks e.t.c never get completely refuelled. After refuelling, rather than returning a value of 1 when the fuel command is called.\nThey return a value greater than 0.98 and less than 1."},{"user":"fusselwurm","date":"2020-12-19T19:10:00Z","text":"returns\n- *1* for units (dead or alive)\n- *0* for *objNull*"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"fullCrew","operator":null,"title":"fullCrew","type":"command","url":"https://community.bistudio.com/wiki/fullCrew","revid":377160,"updated":"2026-01-01T10:40:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an array with all crew inside given vehicle, with or without empty seats.\n\n> [!IMPORTANT]\n> With the introduction of person turrets (FFV), the returned *cargoIndex* works with moveInCargo but does not with actions such as \"GetInCargo\" and \"MoveToCargo\".\n> To find out indexes for actions, use the \"cargo\" filter (See #Example 3).","syntaxes":[{"syntax":"fullCrew vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array","types":["Array"],"description":"list of arrays in format [unit, role, cargoIndex, turretPath, personTurret, assignedUnit, positionName]: - unit: Object - role: String - not always lowercase before Arma 3 v2.04 - cargoIndex: Number - turretPath: Turret Path - personTurret: Boolean - Arma 3 v2.12 assignedUnit: Object - see assignAsXXX commands, assignAsDriver for example - Arma 3 v2.12 positionName: String - unlocalized entry for turret's `gunnerName`, for example \"$STR_A3_TURRETS_CARGOTURRET_R2\"","text":"Array - list of arrays in format [unit, role, cargoIndex, turretPath, personTurret, assignedUnit, positionName]:\n- unit: Object\n- role: String - not always lowercase before Arma 3 v2.04\n- cargoIndex: Number\n- turretPath: Turret Path\n- personTurret: Boolean\n- Arma 3 v2.12 assignedUnit: Object - see *assignAsXXX* commands, assignAsDriver for example\n- Arma 3 v2.12 positionName: String - unlocalized entry for turret's `gunnerName`, for example \"$STR_A3_TURRETS_CARGOTURRET_R2\""},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"fullCrew [vehicle, type, includeEmpty]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":"role filter (case-insensitive). An invalid value (e.g \"\") will return all positions. Available values:\n- \"driver\"\n- \"commander\"\n- \"gunner\"\n- \"turret\"\n- \"cargo\"","types":["String"],"since":null,"text":"type: String - role filter (case-insensitive). An invalid value (e.g \"\") will return all positions. Available values:\n- \"driver\"\n- \"commander\"\n- \"gunner\"\n- \"turret\"\n- \"cargo\""},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"include empty crew seats","types":["Boolean"],"since":"arma3 1.56","text":"includeEmpty: Boolean - (Optional, default false) include empty crew seats"}],"returns":{"type":"Array","types":["Array"],"description":"list of arrays in format [unit, role, cargoIndex, turretPath, personTurret, assignedUnit, positionName]: - unit: Object - role: String - not always lowercase before Arma 3 v2.04 - cargoIndex: Number - turretPath: Turret Path - personTurret: Boolean - Arma 3 v2.12 assignedUnit: Object - see assignAsXXX commands, assignAsDriver for example - Arma 3 v2.12 positionName: String - unlocalized entry for turret's `gunnerName`, for example \"$STR_A3_TURRETS_CARGOTURRET_R2\"","text":"Array - list of arrays in format [unit, role, cargoIndex, turretPath, personTurret, assignedUnit, positionName]:\n- unit: Object\n- role: String - not always lowercase before Arma 3 v2.04\n- cargoIndex: Number\n- turretPath: Turret Path\n- personTurret: Boolean\n- Arma 3 v2.12 assignedUnit: Object - see *assignAsXXX* commands, assignAsDriver for example\n- Arma 3 v2.12 positionName: String - unlocalized entry for turret's `gunnerName`, for example \"$STR_A3_TURRETS_CARGOTURRET_R2\""},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, type, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\n_list = fullCrew vehicle player;\n/*\n    returns for example (on an armed WY-55 Hellcat):\n    [\n        [R Alpha 1-1:1, \"driver\", -1, [], false, R Alpha 1-1:1, \"$STR_POSITION_DRIVER\"],\n        [R Alpha 1-1:2, \"turret\", -1, [0], false, R Alpha 1-1:2, \"$STR_A3_COPILOT\"]\n    ]\n*/\n```","code":["_list = fullCrew vehicle player;\n/*\n\treturns for example (on an armed WY-55 Hellcat):\n\t[\n\t\t[R Alpha 1-1:1, \"driver\", -1, [], false, R Alpha 1-1:1, \"$STR_POSITION_DRIVER\"],\n\t\t[R Alpha 1-1:2, \"turret\", -1, [0], false, R Alpha 1-1:2, \"$STR_A3_COPILOT\"]\n\t]\n*/"]},{"text":"```sqf\n_list = fullCrew [vehicle player, \"turret\"];\n/*\n    returns for example (on an armed WY-55 Hellcat):\n    [\n        [R Alpha 1-1:2, \"turret\", -1, [0], false, R Alpha 1-1:2, \"$STR_A3_COPILOT\"]\n    ]\n*/\n```","code":["_list = fullCrew [vehicle player, \"turret\"];\n/*\n\treturns for example (on an armed WY-55 Hellcat):\n\t[\n\t\t[R Alpha 1-1:2, \"turret\", -1, [0], false, R Alpha 1-1:2, \"$STR_A3_COPILOT\"]\n\t]\n*/"]},{"text":"```sqf\nprivate _actionCompatibleCargoIndexes = fullCrew [heli, \"cargo\", true];\n/*\n    returns for example (on an empty armed WY-55 Hellcat):\n    [\n        [objNull, \"cargo\", 2, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n        [objNull, \"cargo\", 3, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n        [objNull, \"cargo\", 4, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n        [objNull, \"cargo\", 5, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"]\n    ]\n    using the element's index is compatible with action cargo commands - see below\n*/\n\n// the following commands will put the player in the same seat:\nplayer moveInCargo [heli, 2];\nplayer action [\"GetInCargo\", heli, 0];\n```","code":["private _actionCompatibleCargoIndexes = fullCrew [heli, \"cargo\", true];\n/*\n\treturns for example (on an empty armed WY-55 Hellcat):\n\t[\n\t\t[objNull, \"cargo\", 2, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n\t\t[objNull, \"cargo\", 3, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n\t\t[objNull, \"cargo\", 4, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"],\n\t\t[objNull, \"cargo\", 5, [], false, objNull, \"$STR_GETIN_POS_PASSENGER\"]\n\t]\n\tusing the element's index is compatible with action cargo commands - see below\n*/\n\n// the following commands will put the player in the same seat:\nplayer moveInCargo [heli, 2];\nplayer action [\"GetInCargo\", heli, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["crew","createVehicleCrew","assignedVehicleRole","allTurrets","emptyPositions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"gearIDCAmmoCount","operator":null,"title":"gearIDCAmmoCount","type":"command","url":"https://community.bistudio.com/wiki/gearIDCAmmoCount","revid":363874,"updated":"2024-04-23T21:04:42Z","groups":["Unit Inventory","GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ammo count of assigned magazine.","syntaxes":[{"syntax":"gearIDCAmmoCount idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of control type CT_ITEMSLOT 103","types":["Number"],"since":null,"text":"idc: Number - idc of control type CT_ITEMSLOT 103"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}}],"examples":[{"text":"```sqf\n_ammoCount = gearIDCAmmoCount _control;\n```","code":["_ammoCount = gearIDCAmmoCount _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["gearSlotData","gearSlotAmmoCount"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Unit Inventory","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"gearSlotAmmoCount","operator":null,"title":"gearSlotAmmoCount","type":"command","url":"https://community.bistudio.com/wiki/gearSlotAmmoCount","revid":376113,"updated":"2025-08-26T21:33:41Z","groups":["Unit Inventory","GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ammo count of assigned magazine.","syntaxes":[{"syntax":"gearSlotAmmoCount control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"`CT_ITEMSLOT 103`","types":["Control"],"since":null,"text":"control: Control - `CT_ITEMSLOT 103`"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _ammoCount = gearSlotAmmoCount _control;\n```","code":["private _ammoCount = gearSlotAmmoCount _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["gearSlotData","gearIDCAmmoCount"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Unit Inventory","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"gearSlotData","operator":null,"title":"gearSlotData","type":"command","url":"https://community.bistudio.com/wiki/gearSlotData","revid":347667,"updated":"2023-10-09T11:05:57Z","groups":["Unit Inventory","GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns gear slot item name.","syntaxes":[{"syntax":"gearSlotData control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"CT_ITEMSLOT 103","types":["Control"],"since":null,"text":"control: Control - CT_ITEMSLOT 103"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\ngearSlotData _myControl;\n```","code":["gearSlotData _myControl;"]},{"text":"Open any ammobox and click by any gear slots:\n\n```sqf\nprivate \"_display\";\ndisableSerialization;\n\nwaitUntil {\n    _display = findDisplay 106;\n    ! isNull _display;\n};\n\nuiNamespace setVariable [\"/TAG/RscDisplayGear/SlotDataEH\", {\n    _weaponName = gearSlotData (_this select 0);\n    _conf = configFile >> _confSection >> _weaponName;\n    _name = getText (_conf >> \"displayName\");\n    _desc = getText (_conf >> \"Library\" >> \"libTextDesc\");\n    _image = getText (_conf >> \"picture\");\n    hint parseText format [\n        \"<t size='1.3' align='center' shadow='true' shadowColor='#000000'>%1</t><br><img image='%2' size='6' align='center' /><br>%3<br>%4\",\n        _name, _image, _desc\n    ];\n}];\n\nfor \"_i\" from 107 to 145 do {\n    _display displayCtrl _i ctrlAddEventHandler [\"ButtonClick\",\n        format [\n            \"_confSection = '%1'; _this call (uiNamespace getVariable '/TAG/RscDisplayGear/SlotDataEH');\",\n            if (_i >= 109 && _i <= 129) then { \"CfgMagazines\" } else { \"CfgWeapons\" }\n        ]\n    ];\n};\n```","code":["private \"_display\";\ndisableSerialization;\n\nwaitUntil {\n\t_display = findDisplay 106;\n\t! isNull _display;\n};\n\nuiNamespace setVariable [\"/TAG/RscDisplayGear/SlotDataEH\", {\n\t_weaponName = gearSlotData (_this select 0);\n\t_conf = configFile >> _confSection >> _weaponName;\n\t_name = getText (_conf >> \"displayName\");\n\t_desc = getText (_conf >> \"Library\" >> \"libTextDesc\");\n\t_image = getText (_conf >> \"picture\");\n\thint parseText format [\n\t\t\"<t size='1.3' align='center' shadow='true' shadowColor='#000000'>%1</t><br><img image='%2' size='6' align='center' /><br>%3<br>%4\",\n\t\t_name, _image, _desc\n\t];\n}];\n\nfor \"_i\" from 107 to 145 do {\n\t_display displayCtrl _i ctrlAddEventHandler [\"ButtonClick\",\n\t\tformat [\n\t\t\t\"_confSection = '%1'; _this call (uiNamespace getVariable '/TAG/RscDisplayGear/SlotDataEH');\",\n\t\t\tif (_i >= 109 && _i <= 129) then { \"CfgMagazines\" } else { \"CfgWeapons\" }\n\t\t]\n\t];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["gearSlotAmmoCount","gearIDCAmmoCount"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Unit Inventory","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"gestureState","operator":null,"title":"gestureState","type":"command","url":"https://community.bistudio.com/wiki/gestureState","revid":352842,"updated":"2024-02-26T11:36:18Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the name of a unit's current gesture. Seems to be forced to lower case in Arma 3.\n\n> [!NOTE]\n> This command is only for a man unit, other units such as animals cannot use this command.","syntaxes":[{"syntax":"gestureState unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"String","types":["String"],"description":"empty string if not available","text":"String - empty string if not available"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _state = gestureState player;\n```","code":["private _state = gestureState player;"]}],"multiplayer":"When executed on a client, this command only returns accurate results when the target unit is within sight of the client. When executed on a dedicated server, the returned value is accurate.","problems":null,"aliases":[],"see_also":["switchAction","playAction","BIS_fnc_ambientAnimGetParams","animationState","getUnitMovesInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"get","operator":null,"title":"get","type":"command","url":"https://community.bistudio.com/wiki/get","revid":348437,"updated":"2023-11-08T13:00:13Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieves a value out of a HashMap after looking it up by its key.","syntaxes":[{"syntax":"hashMap get key","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":"case sensitive key","types":["HashMapKey"],"since":null,"text":"key: HashMapKey - case sensitive key"}],"returns":{"type":"Anything, or Nothing if key is not found","types":["Anything","Nothing"],"description":null,"text":"Anything, or Nothing if *key* is not found"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"key","types":["HashMapKey"]}}],"examples":[{"text":"```sqf\nprivate _myValue = _myHashMap get \"a\";\n```","code":["private _myValue = _myHashMap get \"a\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["HashMap","getOrDefault"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"get3DENActionState","operator":null,"title":"get3DENActionState","type":"command","url":"https://community.bistudio.com/wiki/get3DENActionState","revid":349130,"updated":"2023-11-08T14:49:44Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns state of given Eden Editor action.","syntaxes":[{"syntax":"get3DENActionState action","since":null,"effect":null,"exec":null,"params":[{"name":"action","type":"String","optional":false,"default":null,"description":"see Eden Editor: Actions","types":["String"],"since":null,"text":"action: String - see Eden Editor: Actions"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nif (get3DENActionState \"ToggleMap\" == 1) then {systemChat \"Editor map is open!\"};\n```","code":["if (get3DENActionState \"ToggleMap\" == 1) then {systemChat \"Editor map is open!\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["do3DENAction"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENAttribute","operator":null,"title":"get3DENAttribute","type":"command","url":"https://community.bistudio.com/wiki/get3DENAttribute","revid":379086,"updated":"2026-09-27T08:41:51Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the value of the given entity's attribute in Eden Editor.\n\nAn attribute is identified by its `property` (`data` when it is engine-drive attribute) value in config. For the list of all attributes with their properties, see Setting Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. You cannot access them in scenario preview or exported scenario!","syntaxes":[{"syntax":"entity get3DENAttribute attribute","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Eden Entity","Eden ID"],"since":null,"text":"entity: Eden Entity or Eden ID"},{"name":"attribute","type":"String","optional":false,"default":null,"description":"attribute property","types":["String"],"since":null,"text":"attribute: String - attribute property"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":null,"text":"Array of Anything"},"form":"binary","operator":null,"left":{"text":"entity","types":["Eden Entity","Eden ID"]},"right":{"text":"attribute","types":["String"]}}],"examples":[{"text":"```sqf\n// returns variable name of the object under cursor\nsystemChat str ((get3DENMouseOver select 1) get3DENAttribute \"name\");\n```","code":["// returns variable name of the object under cursor\nsystemChat str ((get3DENMouseOver select 1) get3DENAttribute \"name\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENAttribute","set3DENAttributes","set3DENMissionAttributes","get3DENMissionAttribute","clear3DENAttribute"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENAttributes","operator":null,"title":"get3DENAttributes","type":"command","url":"https://community.bistudio.com/wiki/get3DENAttributes","revid":370464,"updated":"2024-12-15T11:56:46Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieve all attributes and their values of the specified (optional) category.","syntaxes":[{"syntax":"entity get3DENAttributes category","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"category","type":null,"optional":false,"default":null,"description":"String (\"\" to get all attributes, typeOf to get Object Specific attributes)","types":["String","typeOf"],"since":null,"text":"category: String (\"\" to get all attributes, typeOf to get Object Specific attributes)"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"category","types":["String","typeOf"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENAttributes","set3DENAttribute","get3DENMissionAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"get3DENCamera","operator":null,"title":"get3DENCamera","type":"command","url":"https://community.bistudio.com/wiki/get3DENCamera","revid":369318,"updated":"2024-09-03T18:42:56Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the camera Object used by the Eden Editor.","syntaxes":[{"syntax":"get3DENCamera","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":"Eden Editor camera","text":"Object - Eden Editor camera"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n// set exact yaw, pitch, and roll\n_y = 45; _p = -80; _r = 0;\nget3DENCamera setVectorDirAndUp [\n    [sin _y * cos _p,cos _y * cos _p,sin _p],\n    [[sin _r,-sin _p,cos _r * cos _p],-_y] call BIS_fnc_rotateVector2D\n];\n```","code":["// set exact yaw, pitch, and roll\n_y = 45; _p = -80; _r = 0;\nget3DENCamera setVectorDirAndUp [\n\t[sin _y * cos _p,cos _y * cos _p,sin _p],\n\t[[sin _r,-sin _p,cos _r * cos _p],-_y] call BIS_fnc_rotateVector2D\n];"]},{"text":"```sqf\n//Look at player\n_a = positionCameraToWorld [0,0,0] vectorFromTo (getPosATL player);\n_y = asin(_a select 0);\n_b = [_a,_y] call BIS_fnc_rotateVector2D;\n_z = _b select 2;\n_p = asin(_z / sqrt((_b select 1)^2 + _z^2));\nget3DENCamera setVectorDirAndUp [\n    _a,\n    [[0,-sin _p,cos _p],-_y] call BIS_fnc_rotateVector2D\n];\n```","code":["//Look at player\n_a = positionCameraToWorld [0,0,0] vectorFromTo (getPosATL player);\n_y = asin(_a select 0);\n_b = [_a,_y] call BIS_fnc_rotateVector2D;\n_z = _b select 2;\n_p = asin(_z / sqrt((_b select 1)^2 + _z^2));\nget3DENCamera setVectorDirAndUp [\n\t_a,\n\t[[0,-sin _p,cos _p],-_y] call BIS_fnc_rotateVector2D\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["move3DENCamera","set3DENAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENConnections","operator":null,"title":"get3DENConnections","type":"command","url":"https://community.bistudio.com/wiki/get3DENConnections","revid":379087,"updated":"2026-09-27T08:45:35Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all connections currently present on an entity.","syntaxes":[{"syntax":"get3DENConnections entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Eden Entity","Eden ID"],"since":null,"text":"entity: Eden Entity or Eden ID"}],"returns":{"type":"Array of Arrays with [type, to]","types":["Array"],"description":"type: String - connection class from Cfg3DEN >> Connections - to: Eden Entity: Entitiy the connection leads to","text":"Array of Arrays with [type, to]\n- type: String - connection class from *Cfg3DEN >> Connections*\n- to: Eden Entity: Entitiy the connection leads to"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\nget3DENConnections _trigger; // Can return [[\"WaypointActivation\",[B Alpha 4-5,0]]]\n```","code":["get3DENConnections _trigger; // Can return [[\"WaypointActivation\",[B Alpha 4-5,0]]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENConnection","remove3DENConnection"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENEntity","operator":null,"title":"get3DENEntity","type":"command","url":"https://community.bistudio.com/wiki/get3DENEntity","revid":378362,"updated":"2026-04-03T16:26:44Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Eden Entity based on its Eden ID.","syntaxes":[{"syntax":"get3DENEntity ID","since":null,"effect":null,"exec":null,"params":[{"name":"ID","type":"Number","optional":false,"default":null,"description":"Eden ID","types":["Number"],"since":null,"text":"ID: Number - Eden ID"}],"returns":{"type":"Eden Entity or Number","types":["Eden Entity","Number"],"description":"If the ID points to an Eden Entity the entity is returned - If it points to a Eden Editor: Layer or Eden Editor: Comment the ID is returned - If no entity with given ID exists `-1` is returned","text":"Eden Entity or Number\n- If the *ID* points to an Eden Entity the entity is returned\n- If it points to a Eden Editor: Layer or Eden Editor: Comment the *ID* is returned\n- If no entity with given *ID* exists `-1` is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"ID","types":["Number"]}}],"examples":[{"text":"```sqf\nmyEntity = get3DENEntity 1;\n```","code":["myEntity = get3DENEntity 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENEntityID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENEntityID","operator":null,"title":"get3DENEntityID","type":"command","url":"https://community.bistudio.com/wiki/get3DENEntityID","revid":378236,"updated":"2026-03-20T13:50:55Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unique index of an Eden Entity. This number remains the same even after saving and loading the scenario. ´\n\n> [!NOTE]\n> Since Arma 3 v2.22 this command also returns the IDs of Eden Entities of type Object, Trigger, Group and Logic during preview.","syntaxes":[{"syntax":"get3DENEntityID entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Eden Entity","Eden ID"],"since":null,"text":"entity: Eden Entity or Eden ID"}],"returns":{"type":"Number","types":["Number"],"description":"Eden ID If ID is not available, -1 is returned","text":"Number - Eden ID If ID is not available, -1 is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\nmyID = get3DENEntityID player;\n```","code":["myID = get3DENEntityID player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENEntity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENGrid","operator":null,"title":"get3DENGrid","type":"command","url":"https://community.bistudio.com/wiki/get3DENGrid","revid":348872,"updated":"2023-11-08T14:39:45Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the grid increment for the given transformation type.","syntaxes":[{"syntax":"get3DENGrid type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"name of transformation type. Can be:\n- `\"r\"` - Rotation\n- `\"t\"` - Translation\n- `\"s\"` - Scale","types":["String"],"since":null,"text":"type: String - name of transformation type. Can be:\n- `\"r\"` - Rotation\n- `\"t\"` - Translation\n- `\"s\"` - Scale"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_currentIncrement = get3DENGrid \"t\";\n```","code":["_currentIncrement = get3DENGrid \"t\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENIconsVisible","operator":null,"title":"get3DENIconsVisible","type":"command","url":"https://community.bistudio.com/wiki/get3DENIconsVisible","revid":378129,"updated":"2026-02-22T20:20:11Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets visibility state of Eden Editor icons.","syntaxes":[{"syntax":"get3DENIconsVisible","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Booleans format [shownInMap, shownInScene]:","types":["Array","Boolean"],"description":"shownInMap: Boolean - icons's map visibility - shownInScene: Boolean - icons's scene visibility","text":"Array of Booleans format [shownInMap, shownInScene]:\n- shownInMap: Boolean - icons's map visibility\n- shownInScene: Boolean - icons's scene visibility"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (get3DENIconsVisible select 0) then { hint \"Icons are visible on the map.\" };\n```","code":["if (get3DENIconsVisible select 0) then { hint \"Icons are visible on the map.\" };"]},{"text":"```sqf\nget3DENIconsVisible params [\"_shownInMap\", \"_shownInScene\"];\n```","code":["get3DENIconsVisible params [\"_shownInMap\", \"_shownInScene\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENIconsVisible","set3DENLinesVisible","get3DENLinesVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENLayer","operator":null,"title":"get3DENLayer","type":"command","url":"https://community.bistudio.com/wiki/get3DENLayer","revid":369778,"updated":"2024-10-08T15:09:00Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the provided entity's layer ID.","syntaxes":[{"syntax":"get3DENLayer edenEntity","since":null,"effect":null,"exec":null,"params":[{"name":"edenEntity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"edenEntity: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"edenEntity","types":["Object"]}}],"examples":[{"text":"```sqf\nhint format [\"Entity %1 is in layer %2\", typeOf _entity, get3DENLayer _entity];\n```","code":["hint format [\"Entity %1 is in layer %2\", typeOf _entity, get3DENLayer _entity];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["create3DENEntity","getMissionLayerEntities","set3DENLayer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"get3DENLayerEntities","operator":null,"title":"get3DENLayerEntities","type":"command","url":"https://community.bistudio.com/wiki/get3DENLayerEntities","revid":369163,"updated":"2024-09-03T10:34:40Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return all entities and sub-layer in Eden Entity layer. In order to get all layer entities during a scenario use getMissionLayerEntities.","syntaxes":[{"syntax":"get3DENLayerEntities layerID","since":null,"effect":null,"exec":null,"params":[{"name":"layerID","type":"Number","optional":false,"default":null,"description":"layer ID as returned by add3DENLayer command","types":["Number"],"since":null,"text":"layerID: Number - layer ID as returned by add3DENLayer command"}],"returns":{"type":"Array of Eden Entities","types":["Array","Eden Entity"],"description":null,"text":"Array of Eden Entities"},"form":"unary","operator":null,"left":null,"right":{"text":"layerID","types":["Number"]}}],"examples":[{"text":"```sqf\n_myLayer = -1 add3DENLayer \"CTRG\";\nplayer set3DENLayer _myLayer;\n_entities = get3DENLayerEntities _myLayer;\n```","code":["_myLayer = -1 add3DENLayer \"CTRG\";\nplayer set3DENLayer _myLayer;\n_entities = get3DENLayerEntities _myLayer;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENLayer","remove3DENLayer","set3DENLayer","getMissionLayerEntities","getMissionLayers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENLinesVisible","operator":null,"title":"get3DENLinesVisible","type":"command","url":"https://community.bistudio.com/wiki/get3DENLinesVisible","revid":377632,"updated":"2026-01-02T08:52:24Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get visibility state of Eden Editor lines.","syntaxes":[{"syntax":"get3DENLinesVisible","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [showMap, showScene]","types":["Array"],"description":"showScene: Boolean - visibility in the scene - showMap : Boolean - visibility in the map","text":"Array with [showMap, showScene]\n- showScene: Boolean - visibility in the scene\n- showMap : Boolean - visibility in the map"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (get3DENLinesVisible select 0) then { hint \"Lines are visible in the map.\"; };\n```","code":["if (get3DENLinesVisible select 0) then { hint \"Lines are visible in the map.\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENLinesVisible","set3DENIconsVisible","get3DENIconsVisible","set3DENModelsVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENMissionAttribute","operator":null,"title":"get3DENMissionAttribute","type":"command","url":"https://community.bistudio.com/wiki/get3DENMissionAttribute","revid":341146,"updated":"2023-05-13T22:12:47Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return value of scenario attribute. For a list of all available mission attributes see Mission Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. You cannot access them in scenario preview or exported scenario!","syntaxes":[{"syntax":"section get3DENMissionAttribute class","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"String","optional":false,"default":null,"description":"attribute section. See Sections & Properties","types":["String"],"since":null,"text":"section: String - attribute section. See Sections & Properties"},{"name":"class","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"class: String - attribute name"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"section","types":["String"]},"right":{"text":"class","types":["String"]}}],"examples":[{"text":"```sqf\nsystemChat str (\"Multiplayer\" get3DENMissionAttribute \"respawn\");\n```","code":["systemChat str (\"Multiplayer\" get3DENMissionAttribute \"respawn\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENMissionAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENMissionAttributes","operator":null,"title":"get3DENMissionAttributes","type":"command","url":"https://community.bistudio.com/wiki/get3DENMissionAttributes","revid":373745,"updated":"2025-06-24T21:49:17Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieve all attributes and their values from the specified section/category (category is optional).","syntaxes":[{"syntax":"section get3DENMissionAttributes category","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"section: String"},{"name":"category","type":"String Category name or `\"\"` to return all attributes","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"category: String Category name or `\"\"` to return all attributes"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"section","types":["String"]},"right":{"text":"category","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _result = \"Multiplayer\" get3DENMissionAttributes \"\";\n```","code":["private _result = \"Multiplayer\" get3DENMissionAttributes \"\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENMissionAttributes","get3DENMissionAttribute","get3DENAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"get3DENMouseOver","operator":null,"title":"get3DENMouseOver","type":"command","url":"https://community.bistudio.com/wiki/get3DENMouseOver","revid":377713,"updated":"2026-01-02T09:03:54Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the Eden Entity the mouse is hovering over in Eden Editor.","syntaxes":[{"syntax":"get3DENMouseOver","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [type, entity]","types":["Array"],"description":"type: String - can be one of: - \"Object\" - \"Group\" - \"Trigger\" - \"Logic\" - \"Waypoint\" - \"Marker\" - entity: Eden Entity","text":"Array with [type, entity]\n\n- type: String - can be one of:\n  - \"Object\"\n  - \"Group\"\n  - \"Trigger\"\n  - \"Logic\"\n  - \"Waypoint\"\n  - \"Marker\"\n- entity: Eden Entity"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsystemChat str get3DENMouseOver; // returns e.g [\"Object\", B Alpha 1-1:1]\n```","code":["systemChat str get3DENMouseOver; // returns e.g [\"Object\", B Alpha 1-1:1]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENConnection","add3DENEventHandler","all3DENEntities","collect3DENHistory","create3DENComposition","create3DENEntity","current3DENOperation","delete3DENEntities","do3DENAction","get3DENActionState","get3DENAttribute","get3DENCamera","get3DENConnections","get3DENEntityID","get3DENGrid","get3DENIconsVisible","get3DENLinesVisible","get3DENSelected","is3DEN","is3DENMultiplayer","move3DENCamera","remove3DENConnection","remove3DENEventHandler","removeAll3DENEventHandlers","set3DENAttributes","set3DENGrid","set3DENIconsVisible","set3DENLinesVisible","set3DENObjectType"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"get3DENParent","operator":null,"title":"get3DENParent","type":"command","url":"https://community.bistudio.com/wiki/get3DENParent","revid":370441,"updated":"2024-12-09T16:33:11Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Obtains the provided entity's parent.","syntaxes":[{"syntax":"get3DENParent entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object, Group, Array, Number, String","optional":false,"default":null,"description":"Eden Entity","types":["Object","Group","Array","Number","String"],"since":null,"text":"entity: Object, Group, Array, Number, String - Eden Entity"}],"returns":{"type":"Object, Array, Number","types":["Object","Array","Number"],"description":"Returns Eden Entity or the Eden ID representing it. -1 for system layers such as BLUFOR, OPFOR etc.","text":"Object, Array, Number - Returns Eden Entity or the Eden ID representing it. -1 for system layers such as *BLUFOR*, *OPFOR* etc."},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object","Group","Array","Number","String"]}}],"examples":[{"text":"```sqf\nprivate _parent = get3DENParent _myObject;\n```","code":["private _parent = get3DENParent _myObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["create3DENEntity","delete3DENEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"get3DENSelected","operator":null,"title":"get3DENSelected","type":"command","url":"https://community.bistudio.com/wiki/get3DENSelected","revid":377086,"updated":"2026-01-01T09:45:11Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all selected Eden Editor Entities of the given type.\n\nIf a wrong type is provided, `[[], [], [], [], [], []]` is returned and an error message is shown.","syntaxes":[{"syntax":"get3DENSelected type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"entity type, can be one of:\n- `\"object\"`\n- `\"group\"`\n- `\"trigger\"`\n- `\"logic\"`\n- `\"waypoint\"`\n- `\"marker\"`\n- `\"layer\"`\n- `\"comment\"`\n- `\"\"` - everything but \"layer\" and \"comment\"","types":["String"],"since":null,"text":"type: String - entity type, can be one of:\n- `\"object\"`\n- `\"group\"`\n- `\"trigger\"`\n- `\"logic\"`\n- `\"waypoint\"`\n- `\"marker\"`\n- `\"layer\"`\n- `\"comment\"`\n- `\"\"` - everything but \"layer\" and \"comment\""}],"returns":{"type":"Array of Eden Entity","types":["Array","Eden Entity"],"description":null,"text":"Array of Eden Entity"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nget3DENSelected \"\";\n\n/*\n[\n    [B Alpha 2-1:1],                // objects\n    [B Alpha 2-1],                    // groups\n    [164494: <no shape>],            // triggers\n    [<No center> Charlie 1-2:4],    // logic\n    [[B Alpha 2-1,0]],                // waypoints\n    [\"Hotel_Whiskey\"]                // markers\n]\n*/\n```","code":["get3DENSelected \"\";\n\n/*\n[\n\t[B Alpha 2-1:1],\t\t\t\t// objects\n\t[B Alpha 2-1],\t\t\t\t\t// groups\n\t[164494: <no shape>],\t\t\t// triggers\n\t[<No center> Charlie 1-2:4],\t// logic\n\t[[B Alpha 2-1,0]],\t\t\t\t// waypoints\n\t[\"Hotel_Whiskey\"]\t\t\t\t// markers\n]\n*/"]},{"text":"```sqf\nget3DENSelected \"object\"; // [B Alpha 2-1:1]\n```","code":["get3DENSelected \"object\"; // [B Alpha 2-1:1]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["all3DENEntities","get3DENMouseOver","delete3DENEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getAimDirectionAndUp","operator":null,"title":"getAimDirectionAndUp","type":"command","url":"https://community.bistudio.com/wiki/getAimDirectionAndUp","revid":378285,"updated":"2026-03-31T10:14:52Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the aim direction and up vectors of a soldier in model space. It returns where the weapon aim is wanted from the eyePos, not the actual weapon direction. For actual weapon direction, see weaponDirection.","syntaxes":[{"syntax":"getAimDirectionAndUp [soldier, isRenderScope]","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":"The soldier entity. The soldier must either be on foot or in a turret.","types":["Object"],"since":null,"text":"soldier: Object - The soldier entity. The soldier must either be on foot or in a turret."},{"name":"isRenderScope","type":"Boolean","optional":true,"default":"false","description":"Whether to use render scope to get the vector. (render scope is smoother for visualizing the vector in 3D)","types":["Boolean"],"since":null,"text":"isRenderScope: Boolean - (Optional, default false) Whether to use render scope to get the vector. (render scope is smoother for visualizing the vector in 3D)"}],"returns":{"type":"Array","types":["Array"],"description":"in format [directionForward, directionUp] in soldier's model space","text":"Array - in format [directionForward, directionUp] in soldier's model space"},"form":"unary","operator":null,"left":null,"right":{"text":"[soldier, isRenderScope]","types":["Array"]}}],"examples":[{"text":"```sqf\nonEachFrame\n{\n    getAimDirectionAndUp [player] params [\"_dir\", \"_up\"];\n    private _dirWS = player vectorModelToWorld _dir;\n    private _upWS = player vectorModelToWorld _up;\n    private _eyePos = eyePos player;\n    drawLine3D [ASLtoAGL _eyePos, ASLtoAGL (_eyePos vectorAdd _dirWS), [1,0,0,1]];\n}\n```","code":["onEachFrame\n{\n    getAimDirectionAndUp [player] params [\"_dir\", \"_up\"];\n    private _dirWS = player vectorModelToWorld _dir;\n    private _upWS = player vectorModelToWorld _up;\n    private _eyePos = eyePos player;\n    drawLine3D [ASLtoAGL _eyePos, ASLtoAGL (_eyePos vectorAdd _dirWS), [1,0,0,1]];\n}"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponDirection","eyeDirection","positionCameraToWorld","eyePos"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"getAimingCoef","operator":null,"title":"getAimingCoef","type":"command","url":"https://community.bistudio.com/wiki/getAimingCoef","revid":351281,"updated":"2023-11-27T02:47:48Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get current aiming coefficient (higher ~ less precise, default is 1)","syntaxes":[{"syntax":"getAimingCoef unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"_coef = getAimingCoef player","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCustomAimingCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getAllEnv3DSoundControllers","operator":null,"title":"getAllEnv3DSoundControllers","type":"command","url":"https://community.bistudio.com/wiki/getAllEnv3DSoundControllers","revid":377625,"updated":"2026-01-02T08:52:04Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array containing the names and values of environmental 3D sound controllers, variables that can be used in simple expressions when configuring sounds.\n\n> [!IMPORTANT]\n> - Controller names are case sensitive\n> - Wind param difference:\n>   - `wind` is for **3D** controller\n>   - `wind**y**` is for **2D** controller (getAllEnvSoundControllers)","syntaxes":[{"syntax":"getAllEnv3DSoundControllers object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"environmental sound source like a tree or a house, see allEnv3DSoundSources","types":["Object"],"since":null,"text":"object: Object - environmental sound source like a tree or a house, see allEnv3DSoundSources"}],"returns":{"type":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:","types":["Array"],"description":"`\"rain\"` - `\"night\"` - `\"wind\"` - `\"daytime\"` - `\"distance\"` - `\"shooting\"` - `\"meadows\"` - `\"trees\"` - `\"houses\"` - `\"forest\"` - `\"sea\"` - `\"altitudeSea\"` - `\"altitudeGround\"` - `\"rainDrops\"` - `\"yearTime\"` - `\"ambientTemp\"` - `\"snow\"`","text":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:\n- `\"rain\"`\n- `\"night\"`\n- `\"wind\"`\n- `\"daytime\"`\n- `\"distance\"`\n- `\"shooting\"`\n- `\"meadows\"`\n- `\"trees\"`\n- `\"houses\"`\n- `\"forest\"`\n- `\"sea\"`\n- `\"altitudeSea\"`\n- `\"altitudeGround\"`\n- `\"rainDrops\"`\n- `\"yearTime\"`\n- `\"ambientTemp\"`\n- `\"snow\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetAllEnv3DSoundControllers _thatTreeOverThere;\n/*\n    returns e.g\n    [\n        [\"rain\",0],\n        [\"night\",0],\n        [\"wind\",0.161588],\n        ...\n    ]\n*/\n```","code":["getAllEnv3DSoundControllers _thatTreeOverThere;\n/*\n\treturns e.g\n\t[\n\t\t[\"rain\",0],\n\t\t[\"night\",0],\n\t\t[\"wind\",0.161588],\n\t\t...\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllEnvSoundControllers","getEnv3DSoundController","allEnv3DSoundSources","selectBestPlaces","getSoundController","getSoundControllerResult","getEnvSoundController","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount","Arma 3: Sound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"getAllEnvSoundControllers","operator":null,"title":"getAllEnvSoundControllers","type":"command","url":"https://community.bistudio.com/wiki/getAllEnvSoundControllers","revid":377626,"updated":"2026-01-02T08:52:06Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array containing the names and values of environmental 2D sound controllers, variables that can be used in simple expressions when configuring sounds.\n\n> [!IMPORTANT]\n> - Controller names are case sensitive\n> - Please note that the name for the wind param for **2D** controller is 'windy', 'wind' being the name for the **3D** controller getAllEnv3DSoundControllers.","syntaxes":[{"syntax":"getAllEnvSoundControllers position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:","types":["Array"],"description":"`\"rain\"` - `\"night\"` - `\"windy\"` - `\"daytime\"` - `\"meadows\"` - `\"trees\"` - `\"houses\"` - `\"forest\"` - `\"sea\"` - `\"coast\"` - `\"altitudeGround\"` - `\"altitudeSea\"` - `\"shooting\"` - `\"deadbody\"` - `\"fog\"` - Arma 3 v2.08 `\"yearTime\"` - Arma 3 v2.08 `\"ambientTemp\"` - Arma 3 v2.08 `\"snow\"`","text":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:\n- `\"rain\"`\n- `\"night\"`\n- `\"windy\"`\n- `\"daytime\"`\n- `\"meadows\"`\n- `\"trees\"`\n- `\"houses\"`\n- `\"forest\"`\n- `\"sea\"`\n- `\"coast\"`\n- `\"altitudeGround\"`\n- `\"altitudeSea\"`\n- `\"shooting\"`\n- `\"deadbody\"`\n- `\"fog\"`\n- Arma 3 v2.08 `\"yearTime\"`\n- Arma 3 v2.08 `\"ambientTemp\"`\n- Arma 3 v2.08 `\"snow\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\ngetAllEnvSoundControllers position player;\n/*\n    returns e.g\n    [\n        [\"rain\",0],\n        [\"night\",0],\n        [\"windy\",0.161588],\n        ...\n    ]\n*/\n```","code":["getAllEnvSoundControllers position player;\n/*\n\treturns e.g\n\t[\n\t\t[\"rain\",0],\n\t\t[\"night\",0],\n\t\t[\"windy\",0.161588],\n\t\t...\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllEnv3DSoundControllers","getEnv3DSoundController","allEnv3DSoundSources","selectBestPlaces","getSoundController","getSoundControllerResult","getEnvSoundController","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount","Arma 3: Sound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getAllHitPointsDamage","operator":null,"title":"getAllHitPointsDamage","type":"command","url":"https://community.bistudio.com/wiki/getAllHitPointsDamage","revid":376957,"updated":"2026-01-01T05:46:28Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get provided object's hit points damage.","syntaxes":[{"syntax":"getAllHitPointsDamage entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"object to be queried","types":["Object"],"since":null,"text":"entity: Object - object to be queried"}],"returns":{"type":"Array","types":["Array"],"description":"[] if entity is null or has no shape, otherwise [hitpointNames, selectionNames, damageValues]: - hitpointNames: Array of Strings - selectionNames: Array of Strings - damageValues: Array of Numbers in range 0..1 - where 0 = no damage, 1 = full damage All values in all arrays are ordered accordingly to hit part index for convenience and for use in setHitIndex and getHitIndex.","text":"Array - [] if entity is null or has no shape, otherwise [hitpointNames, selectionNames, damageValues]:\n- hitpointNames: Array of Strings\n- selectionNames: Array of Strings\n- damageValues: Array of Numbers in range 0..1 - where 0 = no damage, 1 = full damage\nAll values in all arrays are ordered accordingly to hit part index for convenience and for use in setHitIndex and getHitIndex."},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str getAllHitPointsDamage player;\n/*\n[\n    [\"hitface\",\"hitneck\",\"hithead\",\"hitpelvis\",\"hitabdomen\",\"hitdiaphragm\",\"hitchest\",\"hitbody\",\"hitarms\",\"hithands\",\"hitlegs\",\"incapacitated\"],\n    [\"face_hub\",\"neck\",\"head\",\"pelvis\",\"spine1\",\"spine2\",\"spine3\",\"body\",\"arms\",\"hands\",\"legs\",\"body\"],\n    [0,0,0,0,0,0,0,0,0,0,0,0]\n]\n*/\n```","code":["hint str getAllHitPointsDamage player;\n/*\n[\n\t[\"hitface\",\"hitneck\",\"hithead\",\"hitpelvis\",\"hitabdomen\",\"hitdiaphragm\",\"hitchest\",\"hitbody\",\"hitarms\",\"hithands\",\"hitlegs\",\"incapacitated\"],\n\t[\"face_hub\",\"neck\",\"head\",\"pelvis\",\"spine1\",\"spine2\",\"spine3\",\"body\",\"arms\",\"hands\",\"legs\",\"body\"],\n\t[0,0,0,0,0,0,0,0,0,0,0,0]\n]\n*/"]},{"text":"```sqf\nhint str getAllHitPointsDamage vehicle player;\n/*\n[\n    [\"hithull\",\"hitengine\",\"hitengine2\",\"hitavionics\",\"hitfuel\",\"hitfuel2\",\"hitglass1\",\"hitlaileron\",\"hitraileron\",\"hitlcrudder\",\"hitrrudder\",\"hitlcelevator\",\"hitrelevator\",\"#gear_f_lights\"],\n    [\"hithull\",\"hitengine\",\"hitengine2\",\"hitavionics\",\"hitfuel\",\"hitfuel2\",\"hitglass1\",\"hitlaileron\",\"hitraileron\",\"hitlcrudder\",\"hitrrudder\",\"hitlcelevator\",\"hitrelevator\",\" \"],\n    [0,0,0,0,0,0,0,0,0,0,0,0,0,0]\n]\n*/\n```","code":["hint str getAllHitPointsDamage vehicle player;\n/*\n[\n\t[\"hithull\",\"hitengine\",\"hitengine2\",\"hitavionics\",\"hitfuel\",\"hitfuel2\",\"hitglass1\",\"hitlaileron\",\"hitraileron\",\"hitlcrudder\",\"hitrrudder\",\"hitlcelevator\",\"hitrelevator\",\"#gear_f_lights\"],\n\t[\"hithull\",\"hitengine\",\"hitengine2\",\"hitavionics\",\"hitfuel\",\"hitfuel2\",\"hitglass1\",\"hitlaileron\",\"hitraileron\",\"hitlcrudder\",\"hitrrudder\",\"hitlcelevator\",\"hitrelevator\",\" \"],\n\t[0,0,0,0,0,0,0,0,0,0,0,0,0,0]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setHitPointDamage","getHitPointDamage","setHitIndex","getHitIndex","setHit","getHit","setDamage","damage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"getAllOwnedMines","operator":null,"title":"getAllOwnedMines","type":"command","url":"https://community.bistudio.com/wiki/getAllOwnedMines","revid":347576,"updated":"2023-09-28T10:10:09Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets all mine objects this unit has ownership over.","syntaxes":[{"syntax":"getAllOwnedMines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_mines = getAllOwnedMines player;\n```","code":["_mines = getAllOwnedMines player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","createMine","detectedMines","mineActive","removeOwnedMine","addOwnedMine","removeAllOwnedMines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getAllPylonsInfo","operator":null,"title":"getAllPylonsInfo","type":"command","url":"https://community.bistudio.com/wiki/getAllPylonsInfo","revid":378172,"updated":"2026-03-03T11:43:19Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return an array with the vehicle's all pylons info.\n\nNote that the podObject can only be used for very few operations. It is not a real Entity.\n\nNote until Arma 3 v2.22 the relativeDir orientation was inverted.","syntaxes":[{"syntax":"getAllPylonsInfo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":null,"types":["Array","currentMagazineDetail"],"description":null,"text":"Array of Arrays in format [Pylon index, Pylon name, Assigned turret, Magazine className, Magazine ammo count, Magazine detail, Arma 3 v2.20 [relativePos, relativeDir, relativeUp], Arma 3 v2.22 podObject]"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetAllPylonsInfo vehicle player;\n/*\n    Executed on an Mi-48 Kajman:\n    [\n        [1, \"PylonLeft1\", [0], \"PylonRack_4Rnd_LG_scalpel\", 4, \"0:10000048\", [[2.50423, -0.214772, -1.37952], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_4x_missile_lg_scalpel_f.p3d],\n        [2, \"PylonLeft2\", [0], \"PylonRack_19Rnd_Rocket_Skyfire\", 19, \"0:10000050\", [[1.8108, -0.15553, -1.32298], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_rocket_skyfire_f.p3d],\n        [3, \"PylonRight2\", [0], \"PylonRack_19Rnd_Rocket_Skyfire\", 19, \"0:10000051\", [[-1.81321, -0.15553, -1.32298], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_rocket_skyfire_f.p3d],\n        [4, \"PylonRight1\", [0], \"PylonRack_4Rnd_LG_scalpel\", 4, \"0:10000052\", [[-2.50664, -0.214772, -1.37952], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_4x_missile_lg_scalpel_f.p3d]\n    ]\n*/\n```","code":["getAllPylonsInfo vehicle player;\n/*\n\tExecuted on an Mi-48 Kajman:\n\t[\n\t\t[1, \"PylonLeft1\", [0], \"PylonRack_4Rnd_LG_scalpel\", 4, \"0:10000048\", [[2.50423, -0.214772, -1.37952], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_4x_missile_lg_scalpel_f.p3d],\n\t\t[2, \"PylonLeft2\", [0], \"PylonRack_19Rnd_Rocket_Skyfire\", 19, \"0:10000050\", [[1.8108, -0.15553, -1.32298], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_rocket_skyfire_f.p3d],\n\t\t[3, \"PylonRight2\", [0], \"PylonRack_19Rnd_Rocket_Skyfire\", 19, \"0:10000051\", [[-1.81321, -0.15553, -1.32298], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_rocket_skyfire_f.p3d],\n\t\t[4, \"PylonRight1\", [0], \"PylonRack_4Rnd_LG_scalpel\", 4, \"0:10000052\", [[-2.50664, -0.214772, -1.37952], [0, 0.997732, 0.0673187], [-0, -0.0673187, 0.997732]], NOID pylonpod_4x_missile_lg_scalpel_f.p3d]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ammoOnPylon","getCompatiblePylonMagazines","getPylonMagazines","setAmmoOnPylon","setPylonLoadout","setPylonsPriority"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"getAllSoundControllers","operator":null,"title":"getAllSoundControllers","type":"command","url":"https://community.bistudio.com/wiki/getAllSoundControllers","revid":377631,"updated":"2026-01-02T08:52:23Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array containing names and values of the sound controllers that can be used in simple expressions when configuring sounds.","syntaxes":[{"syntax":"getAllSoundControllers vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a **vehicle** - this does not work on humans","types":["Object"],"since":null,"text":"vehicle: Object - a **vehicle** - this does not work on humans"}],"returns":{"type":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:","types":["Array"],"description":"`\"rpm\"` - `\"randomizer\"` - `\"speed\"` - `\"thrust\"` - `\"campos\"` - `\"engineon\"` - `\"rotorspeed\"` - `\"rotorthrust\"` - `\"angvelocity\"` - `\"gmeterz\"` - `\"roughness\"` - `\"dustness\"` - `\"damper0\"` - `\"damper1\"` - `\"damper2\"` - `\"damper3\"` - `\"rock\"` - `\"sand\"` - `\"grass\"` - `\"mud\"` - `\"gravel\"` - `\"asphalt\"` - `\"gear\"` - `\"flaps\"` - `\"rotpos\"` - `\"water\"` - `\"apu\"` - `\"batteries\"` - `\"rpmstarter\"` - `\"rpm1\"` - `\"rpmstarter1\"` - `\"motordamage\"` - `\"transmissiondamage\"` - `\"rotorbrake\"` - `\"slingloadactive\"` - `\"latslip\"` - `\"latslipdrive\"` - `\"longslip\"` - `\"longslipdrive\"` - `\"scrubland\"` - `\"scrubobject\"` - `\"scrubtree\"` - `\"scrubbuilding\"` - `\"scrubarmor\"` - `\"engineeffectivity\"` - `\"rain\"` - `\"wind\"` - `\"lateralmovement\"` - `\"playerpos\"` - `\"rotordamage\"` - `\"distance\"` - `\"machcone\"` - `\"camint\"` - `\"camext\"` - `\"houses\"` - `\"meadow\"` - `\"forest\"` - `\"trees\"` - `\"altRadar\"` - `\"acceleration\"` - `\"CustomSoundController1\"` - `\"CustomSoundController2\"` - `\"CustomSoundController3\"` - `\"CustomSoundController4\"` - `\"CustomSoundController5\"` - `\"CustomSoundController6\"` - `\"CustomSoundController7\"` - `\"CustomSoundController8\"` - `\"CustomSoundController9\"` - `\"CustomSoundController10\"` - `\"CustomSoundController11\"` - `\"CustomSoundController12\"` - `\"CustomSoundController13\"` - `\"CustomSoundController14\"` - `\"CustomSoundController15\"` - `\"CustomSoundController16\"` - `\"CustomSoundController17\"` - `\"CustomSoundController18\"` - `\"CustomSoundController19\"` - `\"CustomSoundController20\"` - `\"CustomSoundController21\"` - `\"CustomSoundController22\"` - `\"CustomSoundController23\"` - `\"CustomSoundController24\"` - `\"CustomSoundController25\"` - `\"CustomSoundController26\"` - `\"CustomSoundController27\"` - `\"CustomSoundController28\"` - `\"CustomSoundController29\"` - `\"CustomSoundController30\"` - `\"CustomSoundController31\"` - `\"CustomSoundController32\"`","text":"Array with [[\"controllerA\", valueA], [\"controllerB\", valueB], ...], controllers being, in order:\n- `\"rpm\"`\n- `\"randomizer\"`\n- `\"speed\"`\n- `\"thrust\"`\n- `\"campos\"`\n- `\"engineon\"`\n- `\"rotorspeed\"`\n- `\"rotorthrust\"`\n- `\"angvelocity\"`\n- `\"gmeterz\"`\n- `\"roughness\"`\n- `\"dustness\"`\n- `\"damper0\"`\n- `\"damper1\"`\n- `\"damper2\"`\n- `\"damper3\"`\n- `\"rock\"`\n- `\"sand\"`\n- `\"grass\"`\n- `\"mud\"`\n- `\"gravel\"`\n- `\"asphalt\"`\n- `\"gear\"`\n- `\"flaps\"`\n- `\"rotpos\"`\n- `\"water\"`\n- `\"apu\"`\n- `\"batteries\"`\n- `\"rpmstarter\"`\n- `\"rpm1\"`\n- `\"rpmstarter1\"`\n- `\"motordamage\"`\n- `\"transmissiondamage\"`\n- `\"rotorbrake\"`\n- `\"slingloadactive\"`\n- `\"latslip\"`\n- `\"latslipdrive\"`\n- `\"longslip\"`\n- `\"longslipdrive\"`\n- `\"scrubland\"`\n- `\"scrubobject\"`\n- `\"scrubtree\"`\n- `\"scrubbuilding\"`\n- `\"scrubarmor\"`\n- `\"engineeffectivity\"`\n- `\"rain\"`\n- `\"wind\"`\n- `\"lateralmovement\"`\n- `\"playerpos\"`\n- `\"rotordamage\"`\n- `\"distance\"`\n- `\"machcone\"`\n- `\"camint\"`\n- `\"camext\"`\n- `\"houses\"`\n- `\"meadow\"`\n- `\"forest\"`\n- `\"trees\"`\n- `\"altRadar\"`\n- `\"acceleration\"`\n- `\"CustomSoundController1\"`\n- `\"CustomSoundController2\"`\n- `\"CustomSoundController3\"`\n- `\"CustomSoundController4\"`\n- `\"CustomSoundController5\"`\n- `\"CustomSoundController6\"`\n- `\"CustomSoundController7\"`\n- `\"CustomSoundController8\"`\n- `\"CustomSoundController9\"`\n- `\"CustomSoundController10\"`\n- `\"CustomSoundController11\"`\n- `\"CustomSoundController12\"`\n- `\"CustomSoundController13\"`\n- `\"CustomSoundController14\"`\n- `\"CustomSoundController15\"`\n- `\"CustomSoundController16\"`\n- `\"CustomSoundController17\"`\n- `\"CustomSoundController18\"`\n- `\"CustomSoundController19\"`\n- `\"CustomSoundController20\"`\n- `\"CustomSoundController21\"`\n- `\"CustomSoundController22\"`\n- `\"CustomSoundController23\"`\n- `\"CustomSoundController24\"`\n- `\"CustomSoundController25\"`\n- `\"CustomSoundController26\"`\n- `\"CustomSoundController27\"`\n- `\"CustomSoundController28\"`\n- `\"CustomSoundController29\"`\n- `\"CustomSoundController30\"`\n- `\"CustomSoundController31\"`\n- `\"CustomSoundController32\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetAllSoundControllers vehicle player;\n/*\n    returns e.g\n    [\n        [\"rpm\",0],\n        [\"randomizer\",0.874332],\n        [\"speed\",0],\n        [\"thrust\",0],\n        ...\n    ]\n*/\n```","code":["getAllSoundControllers vehicle player;\n/*\n\treturns e.g\n\t[\n\t\t[\"rpm\",0],\n\t\t[\"randomizer\",0.874332],\n\t\t[\"speed\",0],\n\t\t[\"thrust\",0],\n\t\t...\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","getSoundController","getSoundControllerResult","getEnvSoundController","getAllEnvSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getAllUnitTraits","operator":null,"title":"getAllUnitTraits","type":"command","url":"https://community.bistudio.com/wiki/getAllUnitTraits","revid":379083,"updated":"2026-09-27T08:11:53Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unit traits (native or set by setUnitTrait).","syntaxes":[{"syntax":"getAllUnitTraits unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object or Arma 3 v2.18 String","optional":false,"default":null,"description":"a unit or a class name","types":["Object","String"],"since":null,"text":"unit: Object or Arma 3 v2.18 String - a unit or a class name"}],"returns":{"type":"Array of Arrays with [name, value]","types":["Array"],"description":"name: String - trait's name - value: String or Boolean - trait's value","text":"Array of Arrays with [name, value]\n- name: String - trait's name\n- value: String or Boolean - trait's value"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object","String"]}}],"examples":[{"text":"```sqf\nprivate _playerTraits = getAllUnitTraits player;\n/*\nCould return something like this:\n[\n    [\"Medic\", false],\n    [\"Engineer\", false],\n    [\"ExplosiveSpecialist\", false],\n    [\"UavHacker\", false],\n    [\"CamouflageCoef\", 1],\n    [\"AudibleCoef\", 1],\n    [\"LoadCoef\", 1],\n    [\"test\", \"custom\"]\n]\n*/\n```","code":["private _playerTraits = getAllUnitTraits player;\n/*\nCould return something like this:\n[\n\t[\"Medic\", false],\n\t[\"Engineer\", false],\n\t[\"ExplosiveSpecialist\", false],\n\t[\"UavHacker\", false],\n\t[\"CamouflageCoef\", 1],\n\t[\"AudibleCoef\", 1],\n\t[\"LoadCoef\", 1],\n\t[\"test\", \"custom\"]\n]\n*/"]},{"text":"```sqf\nprivate _unitTraits = getAllUnitTraits _unit;\nprivate _indexes = [_unitTraits, \"Medic\"] call BIS_fnc_findNestedElement;\nprivate _unitCanHeal = _unitTraits select (_indexes select 0) select 1;\n```","code":["private _unitTraits = getAllUnitTraits _unit;\nprivate _indexes = [_unitTraits, \"Medic\"] call BIS_fnc_findNestedElement;\nprivate _unitCanHeal = _unitTraits select (_indexes select 0) select 1;"]},{"text":"Since Arma 3 v2.18:\n\n```sqf\nhint str getAllUnitTraits \"O_Engineer_F\";\n/*\n[\n    [\"Medic\", false],\n    [\"Engineer\", true],\n    [\"ExplosiveSpecialist\", true],\n    [\"UavHacker\", false],\n    [\"CamouflageCoef\", 1],\n    [\"AudibleCoef\", 1],\n    [\"LoadCoef\", 1]\n]\n*/\n```","code":["hint str getAllUnitTraits \"O_Engineer_F\";\n/*\n[\n\t[\"Medic\", false],\n\t[\"Engineer\", true],\n\t[\"ExplosiveSpecialist\", true],\n\t[\"UavHacker\", false],\n\t[\"CamouflageCoef\", 1],\n\t[\"AudibleCoef\", 1],\n\t[\"LoadCoef\", 1]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUnitTrait","setUnitTrait"],"notes":[{"user":"BrettMayson","date":"2023-11-27T02:54:00Z","text":"Local argument assumed, needs confirmation"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getAmmoCargo","operator":null,"title":"getAmmoCargo","type":"command","url":"https://community.bistudio.com/wiki/getAmmoCargo","revid":370851,"updated":"2025-02-18T00:20:05Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the amount (1 is full) of ammo resources in the cargo space of a rearm vehicle.","syntaxes":[{"syntax":"getAmmoCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Number","types":["Number"],"description":"ammo cargo value between 0 (empty, destroyed or null Object) and 1 (full), -1 if ammo cargo is not supported before Arma 3 v1.96 -inf was be returned if vehicle did not support ammo cargo before Arma 3 v1.94 Nothing was be returned if vehicle was not alive","text":"Number - ammo cargo value between 0 (empty, destroyed or null Object) and 1 (full), -1 if ammo cargo is not supported\n\nbefore Arma 3 v1.96 -inf was be returned if *vehicle* did not support ammo cargo\n\nbefore Arma 3 v1.94 Nothing was be returned if *vehicle* was not alive"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvalue = getAmmoCargo myVehicleName;\n```","code":["value = getAmmoCargo myVehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAmmoCargo","getFuelCargo","getRepairCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"getAnimAimPrecision","operator":null,"title":"getAnimAimPrecision","type":"command","url":"https://community.bistudio.com/wiki/getAnimAimPrecision","revid":321924,"updated":"2022-05-22T12:44:17Z","groups":["Animations","Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns aim precision for current animation","syntaxes":[{"syntax":"getAnimAimPrecision unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _aimPrecision = getAnimAimPrecision player;\n```","code":["private _aimPrecision = getAnimAimPrecision player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"getAnimationsQueue","operator":null,"title":"getAnimationsQueue","type":"command","url":"https://community.bistudio.com/wiki/getAnimationsQueue","revid":378279,"updated":"2026-03-31T10:03:56Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the primary and secondary animations queue of the entity. The primary queue contains the full motion path from current animation (animationState) to a target animation, while the secondary queue contains animations that are queued to be played after the target animation in primaryQueue is reached, e.g. due to using playMove or playAction.","syntaxes":[{"syntax":"getAnimationsQueue entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"Man or animal object.","types":["Object"],"since":null,"text":"entity: Object - Man or animal object."}],"returns":{"type":"Array","types":["Array"],"description":"in format [primaryQueue, secondaryQueue] where each queue is an Array of Strings, the animation state names (all lower case).","text":"Array - in format [primaryQueue, secondaryQueue] where each queue is an Array of Strings, the animation state names (all lower case)."},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\ngetAnimationsQueue player params [\"_primaryQueue\", \"_secondaryQueue\"];\nif (_secondaryQueue isNotEqualTo []) then { \n    private _targetAnim = _primaryQueue param [count _primaryQueue - 1, animationState player];\n    private _nextAnim = _secondaryQueue#0;\n    systemChat format [\"Will play '%1' after completing '%2'\", _nextAnim, _targetAnim]; \n};\n```","code":["getAnimationsQueue player params [\"_primaryQueue\", \"_secondaryQueue\"];\nif (_secondaryQueue isNotEqualTo []) then { \n    private _targetAnim = _primaryQueue param [count _primaryQueue - 1, animationState player];\n    private _nextAnim = _secondaryQueue#0;\n    systemChat format [\"Will play '%1' after completing '%2'\", _nextAnim, _targetAnim]; \n};"]},{"text":"```sqf\nplayer playMove _myMove; // push an animation state to the secondary queue\nplayer playAction \"WalkF\"; // an action that gets mapped to an animation state and pushed to queue\ngetAnimationsQueue player params [\"_primaryQueue\", \"_secondaryQueue\"];\n// _secondaryQueue will contain _myMove and the animation that the \"WalkF\" action maps to\n```","code":["player playMove _myMove; // push an animation state to the secondary queue\nplayer playAction \"WalkF\"; // an action that gets mapped to an animation state and pushed to queue\ngetAnimationsQueue player params [\"_primaryQueue\", \"_secondaryQueue\"];\n// _secondaryQueue will contain _myMove and the animation that the \"WalkF\" action maps to"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationState","getUnitMovesInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"getAnimSpeedCoef","operator":null,"title":"getAnimSpeedCoef","type":"command","url":"https://community.bistudio.com/wiki/getAnimSpeedCoef","revid":321925,"updated":"2022-05-22T12:45:16Z","groups":["Animations","Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get coefficient for animation speed.","syntaxes":[{"syntax":"getAnimSpeedCoef unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getAnimSpeedCoef player > 1) then { hint \"Speedy Gonzales!\" };\n```","code":["if (getAnimSpeedCoef player > 1) then { hint \"Speedy Gonzales!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","setAnimSpeedCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"getArray","operator":null,"title":"getArray","type":"command","url":"https://community.bistudio.com/wiki/getArray","revid":377159,"updated":"2026-01-01T10:40:02Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Extract array from config entry.","syntaxes":[{"syntax":"getArray config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":null,"text":"Array of Anything"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_array = getArray (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"threat\");\n```","code":["_array = getArray (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"threat\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getText","getNumber","inheritsFrom","isArray","isClass","isNumber","isText","select"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-28T07:52:00Z","text":"(Arma 3 1.14) It's recommended to use BIS_fnc_getCfgData or BIS_fnc_returnConfigEntry to get variable cfg data rather than conditioning via isNumber, isText, isArray, getNumber, getText and getArray combination.\n\nTraditional workaround:\n\n```sqf\n_cfg = configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\";\nswitch ( true ) do\n{\n    case (isNumber _cfg): {getNumber _cfg};\n    case (isText _cfg): {getText _cfg};\n    case (isArray _cfg): {getArray _cfg;};\n    default { nil };\n};\n```\n\n**Recommended workaround:**\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgData;\n```\n\nTo return default value once entry was not found, we can use BIS_fnc_returnConfigEntry instead of BIS_fnc_getCfgData.\n\n```sqf\n[(configFile >> \"CannonFire\" >> \"LightExp\"),\"lifeTime\",0] call BIS_fnc_returnConfigEntry; // 0.5\n```"},{"user":"demellion","date":"2018-01-12T19:48:00Z","text":"There is special behaviour if you try to read a description.ext config entry Array that contains a Boolean.\n\nGetting array in **MP** will result in Number, while **SP** will return String.\n\n```sqf\n// SP with false in array\ngetArray (missionConfigFile >> \"someClass\" >> \"someArray\") // -> \"false\"\n\n// MP with false in array\ngetArray (missionConfigFile >> \"someClass\" >> \"someArray\") // -> 0\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getArtilleryAmmo","operator":null,"title":"getArtilleryAmmo","type":"command","url":"https://community.bistudio.com/wiki/getArtilleryAmmo","revid":369189,"updated":"2024-09-03T10:34:46Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get list of all available magazines of artillery units on the list. Command returns only unique magazine types and doesn't contain any information about which unit has which magazine.","syntaxes":[{"syntax":"getArtilleryAmmo artilleryList","since":null,"effect":null,"exec":null,"params":[{"name":"artilleryList","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"artilleryList: Array of Objects"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"artilleryList","types":["Array","Object"]}}],"examples":[{"text":"```sqf\nif (\"8Rnd_82mm_Mo_Flare_white\" in getArtilleryAmmo [\n    _mortar1,\n    _mortar2,\n    _mortar3, \n    _mortar4\n]) then\n{\n    hint \"Sir, we have white flares, Sir!\";\n};\n```","code":["if (\"8Rnd_82mm_Mo_Flare_white\" in getArtilleryAmmo [\n\t_mortar1,\n\t_mortar2,\n\t_mortar3, \n\t_mortar4\n]) then\n{\n\thint \"Sir, we have white flares, Sir!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getArtilleryETA","commandArtilleryFire","doArtilleryFire","enableEngineArtillery","getArtilleryComputerSettings","shownArtilleryComputer","inRangeOfArtillery"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getArtilleryComputerSettings","operator":null,"title":"getArtilleryComputerSettings","type":"command","url":"https://community.bistudio.com/wiki/getArtilleryComputerSettings","revid":377650,"updated":"2026-01-02T09:01:56Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns settings from current vehicle weapon manned by player.","syntaxes":[{"syntax":"getArtilleryComputerSettings","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [fireMode, ammo, zero]","types":["Array"],"description":"fireMode: String - fire mode's display name - ammo: String - used ammo display name (not class name) - zero: Number - always 0","text":"Array with [fireMode, ammo, zero]\n- fireMode: String - fire mode's display name\n- ammo: String - used ammo display name (**not** class name)\n- zero: Number - always 0"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str getArtilleryComputerSettings; // [\"Semi (medium)\", \"HE Mortar Shells\", 0]\n```","code":["hint str getArtilleryComputerSettings; // [\"Semi (medium)\", \"HE Mortar Shells\", 0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownArtilleryComputer","enableEngineArtillery","commandArtilleryFire","doArtilleryFire","getArtilleryETA","inRangeOfArtillery","getArtilleryAmmo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getArtilleryETA","operator":null,"title":"getArtilleryETA","type":"command","url":"https://community.bistudio.com/wiki/getArtilleryETA","revid":377528,"updated":"2026-01-02T06:52:51Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns ETA to the target in seconds for given artillery unit based on target position and used magazine, -1 if target can't be hit.","syntaxes":[{"syntax":"unit getArtilleryETA [targetPosition, magazineType]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"artillery unit","types":["Object"],"since":null,"text":"unit: Object - artillery unit"},{"name":"targetPosition","type":"PositionAGLS","optional":false,"default":null,"description":"position of the target","types":["PositionAGLS"],"since":null,"text":"targetPosition: PositionAGLS - position of the target"},{"name":"magazineType","type":"String","optional":false,"default":null,"description":"type of magazine used","types":["String"],"since":null,"text":"magazineType: String - type of magazine used"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[targetPosition, magazineType]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mortar getArtilleryETA [getPos _target, getArtilleryAmmo [_mortar] select 0];\n```","code":["_mortar getArtilleryETA [getPos _target, getArtilleryAmmo [_mortar] select 0];"]},{"text":"```sqf\n_mortar getArtilleryETA [position _target, currentMagazine _mortar];\n```","code":["_mortar getArtilleryETA [position _target, currentMagazine _mortar];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getArtilleryAmmo","commandArtilleryFire","doArtilleryFire","enableEngineArtillery","getArtilleryComputerSettings","shownArtilleryComputer","inRangeOfArtillery"],"notes":[{"user":"Killzone_Kid","date":"2013-08-26T01:00:00Z","text":"To avoid wrong ETA readings, position of the target should only be obtained via position or getPos"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"getAssetDLCInfo","operator":null,"title":"getAssetDLCInfo","type":"command","url":"https://community.bistudio.com/wiki/getAssetDLCInfo","revid":377656,"updated":"2026-01-02T09:02:05Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns DLC information about given object or model.","syntaxes":[{"syntax":"getAssetDLCInfo asset","since":null,"effect":null,"exec":null,"params":[{"name":"asset","type":"Object or String","optional":false,"default":null,"description":"object reference or path to the model","types":["Object","String"],"since":null,"text":"asset: Object or String - object reference or path to the model"}],"returns":{"type":"Array with [isDlc, isOwned, isInstalled, isAvailable, appID, DLCName]","types":["Array"],"description":"isDlc: Boolean - the asset belongs to a DLC - isOwned: Boolean - isInstalled: Boolean - isAvailable: Boolean - appID: String - actual steam item ID or \"0\" for none or \"-1\" for unknown - DLCName: String - actual DLC name or \"\"","text":"Array with [isDlc, isOwned, isInstalled, isAvailable, appID, DLCName]\n- isDlc: Boolean - the asset belongs to a DLC\n- isOwned: Boolean\n- isInstalled: Boolean\n- isAvailable: Boolean\n- appID: String - actual steam item ID or \"0\" for none or \"-1\" for unknown\n- DLCName: String - actual DLC name or \"\""},"form":"unary","operator":null,"left":null,"right":{"text":"asset","types":["Object","String"]}},{"syntax":"getAssetDLCInfo [class, config]","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"class name of the asset","types":["String"],"since":null,"text":"class: String - class name of the asset"},{"name":"config","type":"Config","optional":true,"default":"`configFile >> \"CfgVehicles\"`","description":"config in which to search","types":["Config"],"since":null,"text":"config: Config - (Optional, default `configFile >> \"CfgVehicles\"`) config in which to search"}],"returns":{"type":"Array with [isDlc, isOwned, isInstalled, isAvailable, appID, DLCName]","types":["Array"],"description":"isDlc: Boolean - the asset belongs to a DLC - isOwned: Boolean - isInstalled: Boolean - isAvailable: Boolean - appID: String - actual steam item ID or \"0\" for none or \"-1\" for unknown - DLCName: String - actual DLC name or \"\"","text":"Array with [isDlc, isOwned, isInstalled, isAvailable, appID, DLCName]\n- isDlc: Boolean - the asset belongs to a DLC\n- isOwned: Boolean\n- isInstalled: Boolean\n- isAvailable: Boolean\n- appID: String - actual steam item ID or \"0\" for none or \"-1\" for unknown\n- DLCName: String - actual DLC name or \"\""},"form":"unary","operator":null,"left":null,"right":{"text":"[class, config]","types":["Array"]}}],"examples":[{"text":"```sqf\ngetAssetDLCInfo player;\n```","code":["getAssetDLCInfo player;"]},{"text":"```sqf\ngetAssetDLCInfo \"a3\\Weapons_F_Enoch\\Rifles\\MSBS\\MSBS65_F\";\n```","code":["getAssetDLCInfo \"a3\\Weapons_F_Enoch\\Rifles\\MSBS\\MSBS65_F\";"]},{"text":"```sqf\ngetAssetDLCInfo [\"C_Van_01_transport_F\"];\n```","code":["getAssetDLCInfo [\"C_Van_01_transport_F\"];"]},{"text":"```sqf\ngetAssetDLCInfo [\"arifle_AK12_F\", configFile >> \"CfgWeapons\"];\n```","code":["getAssetDLCInfo [\"arifle_AK12_F\", configFile >> \"CfgWeapons\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getAssignedCuratorLogic","operator":null,"title":"getAssignedCuratorLogic","type":"command","url":"https://community.bistudio.com/wiki/getAssignedCuratorLogic","revid":340929,"updated":"2023-05-13T21:59:54Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns curator logic to which given player has access.","syntaxes":[{"syntax":"getAssignedCuratorLogic player","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"player","types":["Object"]}}],"examples":[{"text":"```sqf\n(getAssignedCuratorLogic player) removeCuratorEditableObjects [allDead, true];\n```","code":["(getAssignedCuratorLogic player) removeCuratorEditableObjects [allDead, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allCurators","getAssignedCuratorUnit"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getAssignedCuratorUnit","operator":null,"title":"getAssignedCuratorUnit","type":"command","url":"https://community.bistudio.com/wiki/getAssignedCuratorUnit","revid":369128,"updated":"2024-09-03T10:34:33Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unit assigned to curator logic.","syntaxes":[{"syntax":"getAssignedCuratorUnit curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\n_curatorUnit = getAssignedCuratorUnit (allCurators select 0);\n_curatorUnit joinAs [createGroup civilian, 0];\n```","code":["_curatorUnit = getAssignedCuratorUnit (allCurators select 0);\n_curatorUnit joinAs [createGroup civilian, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAssignedCuratorLogic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getAttackTarget","operator":null,"title":"getAttackTarget","type":"command","url":"https://community.bistudio.com/wiki/getAttackTarget","revid":309248,"updated":"2022-05-04T10:46:28Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the target given unit is engaging.","syntaxes":[{"syntax":"getAttackTarget unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _unitsTarget = getAttackTarget _unit;\n```","code":["private _unitsTarget = getAttackTarget _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getAudioOptionVolumes","operator":null,"title":"getAudioOptionVolumes","type":"command","url":"https://community.bistudio.com/wiki/getAudioOptionVolumes","revid":377864,"updated":"2026-01-04T11:30:15Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns profile audio volumes.","syntaxes":[{"syntax":"getAudioOptionVolumes","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"[effects, music, radio, von, UI, map] - effects: Number - fx volume factor - music: Number - music volume factor - radio: Number - speech volume factor - von: Number - Voice over Network (VoN) volume factor - Arma 3 v2.10 UI: Number - UI volume factor - Arma 3 v2.12 map: Number - map volume factor","text":"Array - [effects, music, radio, von, UI, map]\n- effects: Number - fx volume factor\n- music: Number - music volume factor\n- radio: Number - speech volume factor\n- von: Number - Voice over Network (VoN) volume factor\n- Arma 3 v2.10 UI: Number - UI volume factor\n- Arma 3 v2.12 map: Number - map volume factor"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ngetAudioOptionVolumes params [\"_effects\", \"_music\", \"_radio\", \"_von\", \"_ui\", \"_map\"];\n```","code":["getAudioOptionVolumes params [\"_effects\", \"_music\", \"_radio\", \"_von\", \"_ui\", \"_map\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSubtitleOptions","soundVolume","musicVolume","radioVolume","setPlayerVoNVolume","getPlayerVoNVolume"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.94","Scripting Commands"]},{"name":"getBackpackCargo","operator":null,"title":"getBackpackCargo","type":"command","url":"https://community.bistudio.com/wiki/getBackpackCargo","revid":378356,"updated":"2026-04-02T16:38:51Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all backpack types and count from the cargo space.","syntaxes":[{"syntax":"getBackpackCargo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to check","types":["Object"],"since":null,"text":"object: Object - object to check"}],"returns":{"type":"Array with [classes, counts]","types":["Array"],"description":"classes: Array of Strings - Backpack class names - counts: Array of Numbers - Backpack counts","text":"Array with [classes, counts]\n- classes: Array of Strings - Backpack class names\n- counts: Array of Numbers - Backpack counts"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetBackpackCargo cursorTarget;\n/*\n    returns e.g\n    [\n        [\"5BackpackA\", \"10BackpackB\"]\n        [5, 10]\n    ]\n*/\n```","code":["getBackpackCargo cursorTarget;\n/*\n\treturns e.g\n\t[\n        [\"5BackpackA\", \"10BackpackB\"]\n        [5, 10]\n\t]\n*/"]},{"text":"```sqf\n_content = getBackpackCargo carName;\n```","code":["_content = getBackpackCargo carName;"]},{"text":"```sqf\n_content = getBackpackCargo ammoBoxName;\n```","code":["_content = getBackpackCargo ammoBoxName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getBleedingRemaining","operator":null,"title":"getBleedingRemaining","type":"command","url":"https://community.bistudio.com/wiki/getBleedingRemaining","revid":320933,"updated":"2022-05-13T10:04:40Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how many seconds injured unit will continue leaving blood trail. If unit damage is < 0.1, the return value is 0 and unit doesn't leave any blood trail. Use setBleedingRemaining to set different remaining time.","syntaxes":[{"syntax":"getBleedingRemaining unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_bleedingRemaining = getBleedingRemaining _unit;\n```","code":["_bleedingRemaining = getBleedingRemaining _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isBurning","setBleedingRemaining","isBleeding"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getBoneNames","operator":null,"title":"getBoneNames","type":"command","url":"https://community.bistudio.com/wiki/getBoneNames","revid":369763,"updated":"2024-10-08T15:08:57Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of bone names and their parents.","syntaxes":[{"syntax":"getBoneNames object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"bone names and bone parents in separate arrays, in format: [[bone1, bone2,...], [parent1, parent2, ....]]","text":"Array of Strings - bone names and bone parents in separate arrays, in format: [[bone1, bone2,...], [parent1, parent2, ....]]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectionPosition","selectionNames","getSelectionBones"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getBurningValue","operator":null,"title":"getBurningValue","type":"command","url":"https://community.bistudio.com/wiki/getBurningValue","revid":319274,"updated":"2022-05-13T09:23:29Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how much the unit is exposed to fire damage.","syntaxes":[{"syntax":"getBurningValue unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _fireDamage = getBurningValue player;\n```","code":["private _fireDamage = getBurningValue player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inflame","inflamed","damage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getCalculatePlayerVisibilityByFriendly","operator":null,"title":"getCalculatePlayerVisibilityByFriendly","type":"command","url":"https://community.bistudio.com/wiki/getCalculatePlayerVisibilityByFriendly","revid":309211,"updated":"2022-05-03T22:25:32Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.84"}],"since":{"game":"arma3","name":"Arma 3","version":"1.84"},"arma3_since":"1.84","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if visibility of player by friendly units is calculated.","syntaxes":[{"syntax":"getCalculatePlayerVisibilityByFriendly","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if visibility is calculated, false if not","text":"Boolean - true if visibility is calculated, false if not"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (!getCalculatePlayerVisibilityByFriendly) then\n{\n    calculatePlayerVisibilityByFriendly true;\n};\n```","code":["if (!getCalculatePlayerVisibilityByFriendly) then\n{\n\tcalculatePlayerVisibilityByFriendly true;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["calculatePlayerVisibilityByFriendly","knowsAbout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.84","Scripting Commands"]},{"name":"getCameraViewDirection","operator":null,"title":"getCameraViewDirection","type":"command","url":"https://community.bistudio.com/wiki/getCameraViewDirection","revid":349460,"updated":"2023-11-08T16:48:37Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the direction unit is looking in render time scope. While for AI the origin for the view direction vector can be taken from `eyePos unit`, for human player the origin should be taken from player camera position `positionCameraToWorld [0,0,0]`","syntaxes":[{"syntax":"getCameraViewDirection unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array","types":["Array"],"description":"3D Vector","text":"Array - 3D Vector"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"Draw AI eye direction (green), weapon direction (red) and camera direction (blue) in 3D:\n\n```sqf\nBob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nBob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame {\n    _beg = ASLToAGL eyePos Bob;\n    _endE = (_beg vectorAdd (eyeDirection Bob vectorMultiply 100));\n    drawLine3D [_beg, _endE, [0,1,0,1]];\n    _endW = (_beg vectorAdd (Bob weaponDirection currentWeapon Bob vectorMultiply 100));\n    drawLine3D [_beg, _endW, [1,0,0,1]];\n    _endV = (_beg vectorAdd (getCameraViewDirection Bob vectorMultiply 100));\n    drawLine3D [_beg, _endV, [0,0,1,1]];\n};\n```","code":["Bob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nBob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame {\n\t_beg = ASLToAGL eyePos Bob;\n\t_endE = (_beg vectorAdd (eyeDirection Bob vectorMultiply 100));\n\tdrawLine3D [_beg, _endE, [0,1,0,1]];\n\t_endW = (_beg vectorAdd (Bob weaponDirection currentWeapon Bob vectorMultiply 100));\n\tdrawLine3D [_beg, _endW, [1,0,0,1]];\n\t_endV = (_beg vectorAdd (getCameraViewDirection Bob vectorMultiply 100));\n\tdrawLine3D [_beg, _endV, [0,0,1,1]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["positionCameraToWorld","weaponDirection","eyeDirection","vectorDir","vectorDirVisual"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"getCargoIndex","operator":null,"title":"getCargoIndex","type":"command","url":"https://community.bistudio.com/wiki/getCargoIndex","revid":369168,"updated":"2024-09-03T10:34:42Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns index of the unit in cargo. -1 if not in cargo.","syntaxes":[{"syntax":"vehicle getCargoIndex unit","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer moveInCargo heli;\nhint str (heli getCargoIndex player);\n```","code":["player moveInCargo heli;\nhint str (heli getCargoIndex player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInCargo","assignAsCargoIndex","emptyPositions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"getCenterOfMass","operator":null,"title":"getCenterOfMass","type":"command","url":"https://community.bistudio.com/wiki/getCenterOfMass","revid":377796,"updated":"2026-01-03T03:53:42Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns center of mass of an object.","syntaxes":[{"syntax":"getCenterOfMass object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"PhysX object","types":["Object"],"since":null,"text":"object: Object - PhysX object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"relative to the model centre","text":"PositionRelative - relative to the model centre"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_com = getCenterOfMass _myCar;\n```","code":["_com = getCenterOfMass _myCar;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMass","setCenterOfMass","setMass","addTorque","addForce"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"getClientState","operator":null,"title":"getClientState","type":"command","url":"https://community.bistudio.com/wiki/getClientState","revid":348401,"updated":"2023-11-08T13:00:04Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns client state in network game. Works on both, client and dedicated server. The following states are possible:\n\n| getClientStateNumber | getClientState | Description |\n|---|---|---|\n| 0 | \"NONE\" | No client (or singleplayer) |\n| 1 | \"CREATED\" | Client is created |\n| 2 | \"CONNECTED\" | Client is connected to server, message formats are registered |\n| 3 | \"LOGGED IN\" | Identity is created |\n| 4 | \"MISSION SELECTED\" | Mission is selected |\n| 5 | \"MISSION ASKED\" | Server was asked to send / not send mission |\n| 6 | \"ROLE ASSIGNED\" | Role was assigned (and confirmed) |\n| 7 | \"MISSION RECEIVED\" | Mission received |\n| 8 | \"GAME LOADED\" | Island loaded, vehicles received |\n| 9 | \"BRIEFING SHOWN\" | Briefing was displayed |\n| 10 | \"BRIEFING READ\" | Ready to play mission |\n| 11 | \"GAME FINISHED\" | Game was finished |\n| 12 | \"DEBRIEFING READ\" | Debriefing read, ready to continue with next mission |","syntaxes":[{"syntax":"getClientState","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":"client state (see table above)","text":"String - client state (see table above)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_state = getClientState;\n```","code":["_state = getClientState;"]},{"text":"```sqf\nif (getClientState == \"BRIEFING READ\") then { hint \"Let the show begin!\" };\n```","code":["if (getClientState == \"BRIEFING READ\") then { hint \"Let the show begin!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getClientStateNumber","getPlayerUID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"getClientStateNumber","operator":null,"title":"getClientStateNumber","type":"command","url":"https://community.bistudio.com/wiki/getClientStateNumber","revid":348456,"updated":"2023-11-08T13:00:18Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns client state in network game. Works on both, client and dedicated server. The following states are possible:\n\n| getClientStateNumber | getClientState | Description |\n|---|---|---|\n| 0 | \"NONE\" | No client (or singleplayer) |\n| 1 | \"CREATED\" | Client is created |\n| 2 | \"CONNECTED\" | Client is connected to server, message formats are registered |\n| 3 | \"LOGGED IN\" | Identity is created |\n| 4 | \"MISSION SELECTED\" | Mission is selected |\n| 5 | \"MISSION ASKED\" | Server was asked to send / not send mission |\n| 6 | \"ROLE ASSIGNED\" | Role was assigned (and confirmed) |\n| 7 | \"MISSION RECEIVED\" | Mission received |\n| 8 | \"GAME LOADED\" | Island loaded, vehicles received |\n| 9 | \"BRIEFING SHOWN\" | Briefing was displayed |\n| 10 | \"BRIEFING READ\" | Ready to play mission |\n| 11 | \"GAME FINISHED\" | Game was finished |\n| 12 | \"DEBRIEFING READ\" | Debriefing read, ready to continue with next mission |","syntaxes":[{"syntax":"getClientStateNumber","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"client state (see table above)","text":"Number - client state (see table above)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_state = getClientStateNumber;\n```","code":["_state = getClientStateNumber;"]},{"text":"```sqf\n_inGame = getClientStateNumber > 8;\n```","code":["_inGame = getClientStateNumber > 8;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getClientState","getPlayerUID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getCompatiblePylonMagazines","operator":null,"title":"getCompatiblePylonMagazines","type":"command","url":"https://community.bistudio.com/wiki/getCompatiblePylonMagazines","revid":310717,"updated":"2022-05-07T19:43:40Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array of compatible pylon magazines","syntaxes":[{"syntax":"vehicle getCompatiblePylonMagazines pylon","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object or String","optional":false,"default":null,"description":"aircraft object or config class","types":["Object","String"],"since":null,"text":"vehicle: Object or String - aircraft object or config class"},{"name":"pylon","type":"Number or String","optional":false,"default":null,"description":"Number or String\n- If String - pylon class name from `TransportPylonsComponent >> pylons` class\n- If Number - pylon ID\n- If an invalid pylon ID or class name is provided, such as 0 or \"\", all compatible magazines from all pylons are returned.","types":["Number","String"],"since":null,"text":"pylon: Number or String\n- If String - pylon class name from `TransportPylonsComponent >> pylons` class\n- If Number - pylon ID\n- If an invalid pylon ID or class name is provided, such as 0 or \"\", all compatible magazines from all pylons are returned."}],"returns":{"type":"Array of Strings, or Array of Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings, or Array of Array of Strings"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object","String"]},"right":{"text":"pylon","types":["Number","String"]}}],"examples":[{"text":"```sqf\n// returns array of arrays containing all compatible magazines\nvehicle player getCompatiblePylonMagazines 0;\n```","code":["// returns array of arrays containing all compatible magazines\nvehicle player getCompatiblePylonMagazines 0;"]},{"text":"```sqf\n// returns array of compatible magazines for the 3rd pylon if it exists; otherwise returns array of arrays (see above)\njet1 getCompatiblePylonMagazines 3;\n```","code":["// returns array of compatible magazines for the 3rd pylon if it exists; otherwise returns array of arrays (see above)\njet1 getCompatiblePylonMagazines 3;"]},{"text":"```sqf\n// returns array of compatible magazines for \"pylon1\" class, defined in\n// configFile >> \"CfgVehicles\" >> \"B_Plane_CAS_01_dynamicLoadout_F\" >> \"Components\" >> \"TransportPylonsComponent\" >> \"Pylons\"\n\"B_Plane_CAS_01_dynamicLoadout_F\" getCompatiblePylonMagazines \"pylon1\";\n```","code":["// returns array of compatible magazines for \"pylon1\" class, defined in\n// configFile >> \"CfgVehicles\" >> \"B_Plane_CAS_01_dynamicLoadout_F\" >> \"Components\" >> \"TransportPylonsComponent\" >> \"Pylons\"\n\"B_Plane_CAS_01_dynamicLoadout_F\" getCompatiblePylonMagazines \"pylon1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getPylonMagazines","setAmmoOnPylon","ammoOnPylon","animatePylon","animateBay","setPylonsPriority","setPylonLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"getConnectedUAV","operator":null,"title":"getConnectedUAV","type":"command","url":"https://community.bistudio.com/wiki/getConnectedUAV","revid":363203,"updated":"2024-03-25T20:22:07Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns UAV/UGV vehicle if person has connection to some UAV. To return the AI unit which player controls, see getConnectedUAVUnit.","syntaxes":[{"syntax":"getConnectedUAV person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"player controlling UAV/UGV","types":["Object"],"since":null,"text":"person: Object - player controlling UAV/UGV"}],"returns":{"type":"Object","types":["Object"],"description":"the UAV/UGV object or objNull if no UAV is connected or if the connected unit is remote.","text":"Object - the UAV/UGV object or objNull if no UAV is connected or if the connected unit is remote."},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\ngetConnectedUAV player;\n```","code":["getConnectedUAV player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getConnectedUAVUnit","showUAVFeed","shownUAVFeed","allUnitsUAV","UAVControl","connectTerminalToUAV","isUAVConnected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 0.76","Scripting Commands"]},{"name":"getConnectedUAVUnit","operator":null,"title":"getConnectedUAVUnit","type":"command","url":"https://community.bistudio.com/wiki/getConnectedUAVUnit","revid":363204,"updated":"2024-03-25T20:23:08Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns UAV/UGV AI unit, which player is controlling. To return UAV vehicle, see getConnectedUAV","syntaxes":[{"syntax":"getConnectedUAVUnit person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit controlling the UAV/UGV","types":["Object"],"since":null,"text":"person: Object - unit controlling the UAV/UGV"}],"returns":{"type":"Object","types":["Object"],"description":"UAV unit (AI driver or AI gunner) or objNull otherwise including if the connected person is remote","text":"Object - UAV unit (AI driver or AI gunner) or objNull otherwise including if the connected person is remote"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _playersDrone = getConnectedUAVUnit player;\n```","code":["private _playersDrone = getConnectedUAVUnit player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getConnectedUAV","isUAVConnected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"getContainerMaxLoad","operator":null,"title":"getContainerMaxLoad","type":"command","url":"https://community.bistudio.com/wiki/getContainerMaxLoad","revid":376219,"updated":"2025-09-19T07:31:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns max load value of given uniform, vest or backpack container. For other types of containers, use maxLoad command","syntaxes":[{"syntax":"getContainerMaxLoad containerClass","since":null,"effect":null,"exec":null,"params":[{"name":"containerClass","type":"String","optional":false,"default":null,"description":"uniform, vest or backpack class","types":["String"],"since":null,"text":"containerClass: String - uniform, vest or backpack class"}],"returns":{"type":"Number","types":["Number"],"description":"load value, -1 if not available.","text":"Number - load value, -1 if not available."},"form":"unary","operator":null,"left":null,"right":{"text":"containerClass","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _maxLoadUniform        = getContainerMaxLoad uniform player;\nprivate _maxLoadVest        = getContainerMaxLoad vest player;\nprivate _maxLoadBackpack    = getContainerMaxLoad backpack player;\n```","code":["private _maxLoadUniform\t\t= getContainerMaxLoad uniform player;\nprivate _maxLoadVest\t\t= getContainerMaxLoad vest player;\nprivate _maxLoadBackpack\t= getContainerMaxLoad backpack player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["load","loadAbs","loadUniform","loadBackpack","loadVest","getMass","weightRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getCorpse","operator":null,"title":"getCorpse","type":"command","url":"https://community.bistudio.com/wiki/getCorpse","revid":352960,"updated":"2024-03-07T14:49:08Z","groups":["Unit Inventory","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the corpse associated with given weaponholder. When unit is killed and had a weapon, the weapon is placed inside \"WeaponHolderSimulated\" and dropped together with the unit. This command returns the dead body associated with this weaponholder.","syntaxes":[{"syntax":"getCorpse weaponholder","since":null,"effect":null,"exec":null,"params":[{"name":"weaponholder","type":"Object","optional":false,"default":null,"description":"weaponholder dropped by the dead unit","types":["Object"],"since":null,"text":"weaponholder: Object - weaponholder dropped by the dead unit"}],"returns":{"type":"Object","types":["Object"],"description":"dead unit","text":"Object - dead unit"},"form":"unary","operator":null,"left":null,"right":{"text":"weaponholder","types":["Object"]}}],"examples":[{"text":"```sqf\nsystemChat str getCorpse cursorObject;\n```","code":["systemChat str getCorpse cursorObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCorpseWeaponholders","nearSupplies","allDeadMen"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Inventory","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getCorpseWeaponholders","operator":null,"title":"getCorpseWeaponholders","type":"command","url":"https://community.bistudio.com/wiki/getCorpseWeaponholders","revid":369742,"updated":"2024-10-08T15:06:00Z","groups":["Unit Inventory","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns primary and secondary weapon holders of a dead unit. If a unit had weapons at the moment of death, primary weapon is dropped into primary weaponholder and secondary weapon is dropped into secondary.","syntaxes":[{"syntax":"getCorpseWeaponholders corpse","since":null,"effect":null,"exec":null,"params":[{"name":"corpse","type":"Object","optional":false,"default":null,"description":"dead unit","types":["Object"],"since":null,"text":"corpse: Object - dead unit"}],"returns":{"type":null,"types":["Array","Object"],"description":null,"text":"Array of Objects in format [primaryWeaponHolder, secondaryWeaponHolder]"},"form":"unary","operator":null,"left":null,"right":{"text":"corpse","types":["Object"]}}],"examples":[{"text":"```sqf\nsystemChat str getCorpseWeaponholders cursorObject;\n```","code":["systemChat str getCorpseWeaponholders cursorObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCorpse","nearSupplies","allDeadMen"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Inventory","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getCruiseControl","operator":null,"title":"getCruiseControl","type":"command","url":"https://community.bistudio.com/wiki/getCruiseControl","revid":377878,"updated":"2026-01-04T15:56:01Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns cruise control settings set with setCruiseControl command.","syntaxes":[{"syntax":"getCruiseControl vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"the vehicle","types":["Object"],"since":null,"text":"vehicle: Object - the vehicle"}],"returns":{"type":"Array with [speedLimit, cruiseControlActive]","types":["Array"],"description":"speedLimit: Number - defined speed limit - cruiseControlActive: Boolean - true if cruise control is enabled, false if only speed was limited","text":"Array with [speedLimit, cruiseControlActive]\n- speedLimit: Number - defined speed limit\n- cruiseControlActive: Boolean - true if cruise control is enabled, false if only speed was limited"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetCruiseControl vehicle player params [\"_speedLimit\", \"_cruiseControlActive\"];\n```","code":["getCruiseControl vehicle player params [\"_speedLimit\", \"_cruiseControlActive\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCruiseControl","limitSpeed","forceSpeed","setAirplaneThrottle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"getCursorObjectParams","operator":null,"title":"getCursorObjectParams","type":"command","url":"https://community.bistudio.com/wiki/getCursorObjectParams","revid":364830,"updated":"2024-06-16T09:59:43Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns object and named selections under cursor and distance to object's surface (to the point cursor points at). If object surface is further away than 50 meters, selections are always an empty array and distance is 1e10 (10^10).","syntaxes":[{"syntax":"getCursorObjectParams","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [cursorObject, selections, distance]","types":["Array"],"description":"cursorObject: Object - selections: Array of Strings - distance: Number - distance to object's surface (to the point cursor points at)","text":"Array with [cursorObject, selections, distance]\n- cursorObject: Object\n- selections: Array of Strings\n- distance: Number - distance to object's surface (to the point cursor points at)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str getCursorObjectParams;\n```","code":["hint str getCursorObjectParams;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cursorObject","cursorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"getCustomAimCoef","operator":null,"title":"getCustomAimCoef","type":"command","url":"https://community.bistudio.com/wiki/getCustomAimCoef","revid":338293,"updated":"2023-02-26T18:30:34Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns aimPrecision from animation state with custom value that will directly affects weapon sway size and speed.","syntaxes":[{"syntax":"getCustomAimCoef unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_coef = getCustomAimCoef player;\n```","code":["_coef = getCustomAimCoef player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","setCustomAimCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"getCustomSoundController","operator":null,"title":"getCustomSoundController","type":"command","url":"https://community.bistudio.com/wiki/getCustomSoundController","revid":364165,"updated":"2024-05-05T10:46:42Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.86"}],"since":{"game":"arma3","name":"Arma 3","version":"1.86"},"arma3_since":"1.86","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current value set to the controller (see setCustomSoundController).","syntaxes":[{"syntax":"getCustomSoundController [vehicle, controller]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a transport type vehicle. Does not work on characters or buildings","types":["Object"],"since":null,"text":"vehicle: Object - a transport type vehicle. Does not work on characters or buildings"},{"name":"controller","type":"String","optional":false,"default":null,"description":"name of custom sound controller - needs to be full string e.g \"CustomSoundController1\". It goes from \"CustomSoundController1\" to \"CustomSoundController32\"","types":["String"],"since":null,"text":"controller: String - name of custom sound controller - needs to be full string e.g \"CustomSoundController1\". It goes from \"CustomSoundController1\" to \"CustomSoundController32\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, controller]","types":["Array"]}}],"examples":[{"text":"```sqf\ngetCustomSoundController [vehicle player, \"CustomSoundController1\"];\n```","code":["getCustomSoundController [vehicle player, \"CustomSoundController1\"];"]},{"text":"```sqf\nprivate _allCustomSoundControllers = [];\nfor \"_i\" from 1 to (getCustomSoundControllerCount vehicle player) do\n{\n    _allCustomSoundControllers pushBack getCustomSoundController [vehicle player, format [\"CustomSoundController%1\", _i]];\n};\n```","code":["private _allCustomSoundControllers = [];\nfor \"_i\" from 1 to (getCustomSoundControllerCount vehicle player) do\n{\n\t_allCustomSoundControllers pushBack getCustomSoundController [vehicle player, format [\"CustomSoundController%1\", _i]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","setCustomSoundController","getCustomSoundControllerCount","getSoundController","getSoundControllerResult","getAllSoundControllers","getEnvSoundController","getAllEnvSoundControllers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.86","Scripting Commands"]},{"name":"getCustomSoundControllerCount","operator":null,"title":"getCustomSoundControllerCount","type":"command","url":"https://community.bistudio.com/wiki/getCustomSoundControllerCount","revid":309206,"updated":"2022-05-03T18:49:18Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.86"}],"since":{"game":"arma3","name":"Arma 3","version":"1.86"},"arma3_since":"1.86","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current number of custom sound controllers supported by the engine for the given vehicle (currently 32)","syntaxes":[{"syntax":"getCustomSoundControllerCount vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a transport type vehicle. Does not work on characters or buildings","types":["Object"],"since":null,"text":"vehicle: Object - a transport type vehicle. Does not work on characters or buildings"}],"returns":{"type":"Number","types":["Number"],"description":"number of custom controllers","text":"Number - number of custom controllers"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetCustomSoundControllerCount vehicle player;\n```","code":["getCustomSoundControllerCount vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","setCustomSoundController","getCustomSoundController","getSoundController","getSoundControllerResult","getAllSoundControllers","getEnvSoundController","getAllEnvSoundControllers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.86","Scripting Commands"]},{"name":"getDammage","operator":null,"title":"getDammage","type":"command","url":"https://community.bistudio.com/wiki/getDammage","revid":376971,"updated":"2026-01-01T06:02:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the object damage.","syntaxes":[{"syntax":"getDammage object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _damage = getDammage player;\n```","code":["private _damage = getDammage player;"]}],"multiplayer":null,"problems":null,"aliases":["damage"],"see_also":["damage","setDamage","setDammage","setHit","getHit","getHitIndex","setHitIndex","getHitPointDamage","setHitPointDamage"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getDebriefingText","operator":null,"title":"getDebriefingText","type":"command","url":"https://community.bistudio.com/wiki/getDebriefingText","revid":377320,"updated":"2026-01-02T06:38:51Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setDebriefingText.","syntaxes":[{"syntax":"getDebriefingText end","since":null,"effect":null,"exec":null,"params":[{"name":"end","type":"String","optional":false,"default":null,"description":"end type","types":["String"],"since":null,"text":"end: String - end type"}],"returns":{"type":"Array format:","types":["Array"],"description":"[text, title] if old syntax of setDebriefingText was used) - [text, title, subtitle, picture, background] if setDebriefingText's alternative syntax was used - empty array if setDebriefingText was not used","text":"Array format:\n- [text, title] if old syntax of setDebriefingText was used)\n- [text, title, subtitle, picture, background] if setDebriefingText's alternative syntax was used\n- empty array if setDebriefingText was not used"},"form":"unary","operator":null,"left":null,"right":{"text":"end","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _debriefingTextDeath = getDebriefingText \"endDeath\";\n```","code":["private _debriefingTextDeath = getDebriefingText \"endDeath\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDebriefingText","disableDebriefingStats","enableDebriefingStats","endMission","failMission","missionEnd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"getDescription","operator":null,"title":"getDescription","type":"command","url":"https://community.bistudio.com/wiki/getDescription","revid":340864,"updated":"2023-05-12T17:13:00Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the string representation of unit as an four slots array.","syntaxes":[{"syntax":"getDescription unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":null,"types":["Array","String"],"description":null,"text":"Array of Strings format `[unit**Class**, uniform**Name**, vest**Name**, backpack**Class**]`"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ngetDescription player; // UAV Operator\n// returns [\"B_soldier_UAV_F\", \"Combat Fatigues (MTP)\", \"Carrier Special Rig (Green)\", \"B_UAV_01_backpack_F\"]\n```","code":["getDescription player; // UAV Operator\n// returns [\"B_soldier_UAV_F\", \"Combat Fatigues (MTP)\", \"Carrier Special Rig (Green)\", \"B_UAV_01_backpack_F\"]"]},{"text":"```sqf\ngetDescription objNull; // returns [\"ERROR\", \"ERROR\", \"ERROR\", \"ERROR\"]\n```","code":["getDescription objNull; // returns [\"ERROR\", \"ERROR\", \"ERROR\", \"ERROR\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["roleDescription","vehicleVarName"],"notes":[{"user":"Druid","date":"2013-03-19T15:54:00Z","text":"Return value fixed in revision 0.51.103185."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getDir","operator":null,"title":"getDir","type":"command","url":"https://community.bistudio.com/wiki/getDir","revid":364132,"updated":"2024-05-04T22:14:16Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the object heading in the range 0..360.\n\n> [!NOTE]\n> **Arma 3:** The alternative syntax gets heading from one object or position to another object or position, and should be used instead of BIS_fnc_dirTo.","syntaxes":[{"syntax":"getDir object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"pos1 getDir pos2","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"pos1","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":"from where","types":["Object","Position2D","Position3D"],"since":null,"text":"pos1: Object, Position2D or Position3D - from where"},{"name":"pos2","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":"to where","types":["Object","Position2D","Position3D"],"since":null,"text":"pos2: Object, Position2D or Position3D - to where"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"pos1","types":["Object","Position2D","Position3D"]},"right":{"text":"pos2","types":["Object","Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_azimuth = getDir player;\n```","code":["_azimuth = getDir player;"]},{"text":"```sqf\n_azimuth = player getDir tank;\n```","code":["_azimuth = player getDir tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDirVisual","direction","getRelDir"],"notes":[{"user":"AgentRev01","date":"2013-10-23T10:31:00Z","text":"Be careful when using this command in conjunction with BIS_fnc_rotateVector2D, which rotates vectors counterclockwise as per trigonometric conventions, while getDir returns a clockwise angle.\n\nTo counter this, simply negate the output of getDir:\n\n```sqf\n[[0,1,0], -(getDir _object)] call BIS_fnc_rotateVector2D;\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getDirVisual","operator":null,"title":"getDirVisual","type":"command","url":"https://community.bistudio.com/wiki/getDirVisual","revid":330392,"updated":"2022-09-06T17:01:40Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns object's heading in the range from 0 to 360 in render time scope.\n\n> [!NOTE]\n> **Arma 3:** The alternative syntax gets heading from one object or position to another object or position in render time scope, and should be used instead of BIS_fnc_dirTo.","syntaxes":[{"syntax":"getDirVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"pos1 getDirVisual pos2","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"pos1","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":"from where","types":["Object","Position2D","Position3D"],"since":null,"text":"pos1: Object, Position2D or Position3D - from where"},{"name":"pos2","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":"to where","types":["Object","Position2D","Position3D"],"since":null,"text":"pos2: Object, Position2D or Position3D - to where"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"pos1","types":["Object","Position2D","Position3D"]},"right":{"text":"pos2","types":["Object","Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_dir = getDirVisual player;\n```","code":["_dir = getDirVisual player;"]},{"text":"```sqf\n_azimuth = player getDirVisual tank;\n```","code":["_azimuth = player getDirVisual tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDir","direction"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getDiverState","operator":null,"title":"getDiverState","type":"command","url":"https://community.bistudio.com/wiki/getDiverState","revid":309148,"updated":"2022-05-03T14:10:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true when object is in diver state - e.g when the unit would put diving goggles on.\n\n> [!NOTE]\n> Diving goggles remove blurriness underwater, however when assigned, they do not appear on the face of the unit until the unit steps into the water.\n> This command allows to detect the moment when the goggles are visible.\n> If the unit doesn't have diving goggles assigned, this command would still return true at appropriate time if the unit steps into the water.","syntaxes":[{"syntax":"getDiverState unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when diving goggles are visible","text":"Boolean - true when diving goggles are visible"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _gogglesOn = getDiverState player;\n```","code":["private _gogglesOn = getDiverState player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["goggles","removeGoggles","addGoggles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"getDLCAssetsUsage","operator":null,"title":"getDLCAssetsUsage","type":"command","url":"https://community.bistudio.com/wiki/getDLCAssetsUsage","revid":310760,"updated":"2022-05-07T20:21:35Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of the DLC usage times.","syntaxes":[{"syntax":"getDLCAssetsUsage","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"array of DLC usage information, containing DLC items in format: [[name, dlcAppId, sessionTime, totalTime], [name, dlcAppId, sessionTime, totalTime], (…)] NOTE: unused assets won't appear in the result (usage time = 0).","text":"Array - array of DLC usage information, containing DLC items in format:\n\n[[name, dlcAppId, sessionTime, totalTime], [name, dlcAppId, sessionTime, totalTime], (…)]\n\n**NOTE:** unused assets won't appear in the result (usage time = 0)."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_dlcAssetsUsageInfo = getDLCAssetsUsage;\n```","code":["_dlcAssetsUsageInfo = getDLCAssetsUsage;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsageByName","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getDLCAssetsUsageByName","operator":null,"title":"getDLCAssetsUsageByName","type":"command","url":"https://community.bistudio.com/wiki/getDLCAssetsUsageByName","revid":319132,"updated":"2022-05-13T09:23:14Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with the session and global time the asset has been used.","syntaxes":[{"syntax":"getDLCAssetsUsageByName assetName","since":null,"effect":null,"exec":null,"params":[{"name":"assetName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"assetName: String"}],"returns":{"type":"Array","types":["Array"],"description":"array in format: [sessionTime, totalTime].","text":"Array - array in format: [sessionTime, totalTime]."},"form":"unary","operator":null,"left":null,"right":{"text":"assetName","types":["String"]}}],"examples":[{"text":"```sqf\n_dlcAssetUsage = getDLCAssetsUsageByName \"C_IDAP_Heli_Transport_02_F\";\n```","code":["_dlcAssetUsage = getDLCAssetsUsageByName \"C_IDAP_Heli_Transport_02_F\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getDLCs","operator":null,"title":"getDLCs","type":"command","url":"https://community.bistudio.com/wiki/getDLCs","revid":377087,"updated":"2026-01-01T09:46:01Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of app IDs of DLCs.","syntaxes":[{"syntax":"getDLCs filter","since":null,"effect":null,"exec":null,"params":[{"name":"filter","type":"Number one of:","optional":false,"default":null,"description":"Number one of:\n- 0 - all\n- 1 - owned\n- 2 - not owned","types":["Number"],"since":null,"text":"filter: Number one of:\n- 0 - all\n- 1 - owned\n- 2 - not owned"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":"App IDs","text":"Array of Numbers - App IDs"},"form":"unary","operator":null,"left":null,"right":{"text":"filter","types":["Number"]}}],"examples":[{"text":"```sqf\n_ownedDLCs = getDLCs 1;\n```","code":["_ownedDLCs = getDLCs 1;"]},{"text":"```sqf\n_hasKarts = (288520 in (getDLCs 1));\n```","code":["_hasKarts = (288520 in (getDLCs 1));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectDLC","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[{"user":"Benargee","date":"2015-04-07T20:27:00Z","text":"App ID can be found in CfgMods. Here is an example path from zeus using the Splendid Config Viewer:\n\n```sqf\nconfigFile >> \"CfgMods\" >> \"Curator\" >> \"appId\"\n```\n\nThis method can be used to find app IDs without having to find a list like the one above.\n\nI am also pretty sure you are able to define your own app ID for your own mods using this method."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getDLCUsageTime","operator":null,"title":"getDLCUsageTime","type":"command","url":"https://community.bistudio.com/wiki/getDLCUsageTime","revid":319195,"updated":"2022-05-13T09:23:21Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns total time the assets of the given DLC have been used. See Arma 3 DLCs & Expansions for a list of DLCs and ids.","syntaxes":[{"syntax":"getDLCUsageTime appId","since":null,"effect":null,"exec":null,"params":[{"name":"appId","type":"Number","optional":false,"default":null,"description":"DLC's Steam appId","types":["Number"],"since":null,"text":"appId: Number - DLC's Steam appId"}],"returns":{"type":"Number","types":["Number"],"description":"DLC assets usage time in seconds","text":"Number - DLC assets usage time in seconds"},"form":"unary","operator":null,"left":null,"right":{"text":"appId","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _kartsUsage = getDLCUsageTime 288520;\n```","code":["private _kartsUsage = getDLCUsageTime 288520;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"getEditorCamera","operator":null,"title":"getEditorCamera","type":"command","url":"https://community.bistudio.com/wiki/getEditorCamera","revid":363288,"updated":"2024-03-26T10:51:57Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Fetches a reference to the mission editor camera.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"getEditorCamera map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getEditorMode","operator":null,"title":"getEditorMode","type":"command","url":"https://community.bistudio.com/wiki/getEditorMode","revid":363233,"updated":"2024-03-26T10:51:08Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current mode of the editor.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"getEditorMode map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getEditorObjectScope","operator":null,"title":"getEditorObjectScope","type":"command","url":"https://community.bistudio.com/wiki/getEditorObjectScope","revid":363276,"updated":"2024-03-26T10:51:48Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the editor object scope of the specified editor object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map getEditorObjectScope object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getElevationOffset","operator":null,"title":"getElevationOffset","type":"command","url":"https://community.bistudio.com/wiki/getElevationOffset","revid":310776,"updated":"2022-05-07T20:21:45Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the map elevation offset from [map]/config.cpp.\n\nReturns 0 if there is no elevationOffset defined in the config of the current world.","syntaxes":[{"syntax":"getElevationOffset","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"elevation offset of the map","text":"Number - elevation offset of the map"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_offset = getElevationOffset;\n```","code":["_offset = getElevationOffset;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTerrainHeightASL"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getEngineTargetRPMRTD","operator":null,"title":"getEngineTargetRPMRTD","type":"command","url":"https://community.bistudio.com/wiki/getEngineTargetRPMRTD","revid":348667,"updated":"2023-11-08T13:51:28Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns RPM of all engines. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"getEngineTargetRPMRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Array of Numbers with the RPM of each engine","types":["Array","Number"],"description":null,"text":"Array of Numbers with the RPM of each engine"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _rpm = getEngineTargetRPMRTD _helicopter;\n```","code":["private _rpm = getEngineTargetRPMRTD _helicopter;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWantedRPMRTD","rotorsRpmRTD","enginesRpmRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getEntityInfo","operator":null,"title":"getEntityInfo","type":"command","url":"https://community.bistudio.com/wiki/getEntityInfo","revid":379101,"updated":"2026-10-03T12:00:10Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns various properties for the given entity. Most properties should be checked where entity is local","syntaxes":[{"syntax":"getEntityInfo entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"}],"returns":{"type":"Array with [isMan, isAnimal, isDeadSet, deadSetTime, lastEntityCausingDamage, lastDamageTime, isUpsideDown, upsideDownTime, isStopped, canFloat, hasTerminalOpened, isWeaponholder, isWreck, isSmoking, isSetForDeletion]","types":["Array"],"description":"0 - isMan: Boolean - true if the entity is a man - 1 - isAnimal: Boolean - true if the entity is an animal - 2 - isDeadSet: Boolean - true if the entity has dead flag set. Often has the same value as !alive, but is not the same, as alive checks the total damage. - 3 - deadSetTime: Number - for how long the entity was dead - 4 - lastEntityCausingDamage: Object - objNull or the entity that last caused damage to this entity. Is not the same as the killer but could be the same. Killed entity might not have this set either. The entity does not have to be dead in order to have last entity that caused damage assigned. - 5 - lastDamageTime: Number - how long ago was lastEntityCausingDamage assigned - 6 - isUpsideDown: Boolean - true if the entity is upside down. The engine considers this to be `vectorUp ent select 2 < 0.3` - 7 - upsideDownTime: Number - how long the entity was upside down. - 8 - isStopped: Boolean - true when the entity does not need to be actively simulated. - 9 - canFloat: Boolean - true if the entity is able to float on water. - 10 - hasTerminalOpened: Boolean - true if the UAV terminal is opened for the given entity. - 11 - isWeaponholder: Boolean - true if the entity is weaponholder. - 12 - isWreck: Boolean - true if the entity is wreck. - 13 - isSmoking: Boolean - true if the entity has smoke and fire destruction effect active. - 14 - isSetForDeletion: Boolean - true if the entity was set for deletion, but is not yet removed from the simulation. Simple Object is supported. - 15 - Arma 3 v2.24 isParachute: Boolean - true if the entity is either Steerable or Non-Steerable parachute. > [!NOTE] > In multiplayer, following values update properly only when entity is local: > - lastEntityCausingDamage > - lastDamageTime > - isStopped > Other values are either static or update depending on how your client sees the entity right now. > > Timer values are never exact between clients and vary slightly depending on latency, JIP clients end up with large timer values close to game's time but get normal once associated value changes again: > - `deadSetTime` > - `lastDamageTime` > - `upsideDownTime`","text":"Array with [isMan, isAnimal, isDeadSet, deadSetTime, lastEntityCausingDamage, lastDamageTime, isUpsideDown, upsideDownTime, isStopped, canFloat, hasTerminalOpened, isWeaponholder, isWreck, isSmoking, isSetForDeletion]\n- 0 - isMan: Boolean - true if the entity is a man\n- 1 - isAnimal: Boolean - true if the entity is an animal\n- 2 - isDeadSet: Boolean - true if the entity has dead flag set. Often has the same value as !alive, but is not the same, as alive checks the total damage.\n- 3 - deadSetTime: Number - for how long the entity was dead\n- 4 - lastEntityCausingDamage: Object - objNull or the entity that last caused damage to this entity. Is not the same as the killer but could be the same. Killed entity might not have this set either. The entity does not have to be dead in order to have last entity that caused damage assigned.\n- 5 - lastDamageTime: Number - how long ago was *lastEntityCausingDamage* assigned\n- 6 - isUpsideDown: Boolean - true if the entity is upside down. The engine considers this to be `vectorUp ent select 2 < 0.3`\n- 7 - upsideDownTime: Number - how long the entity was upside down.\n- 8 - isStopped: Boolean - true when the entity does not need to be actively simulated.\n- 9 - canFloat: Boolean - true if the entity is able to float on water.\n- 10 - hasTerminalOpened: Boolean - true if the UAV terminal is opened for the given entity.\n- 11 - isWeaponholder: Boolean - true if the entity is weaponholder.\n- 12 - isWreck: Boolean - true if the entity is wreck.\n- 13 - isSmoking: Boolean - true if the entity has smoke and fire destruction effect active.\n- 14 - isSetForDeletion: Boolean - true if the entity was set for deletion, but is not yet removed from the simulation. Simple Object is supported.\n- 15 - Arma 3 v2.24 isParachute: Boolean - true if the entity is either Steerable or Non-Steerable parachute.\n\n> [!NOTE]\n> In multiplayer, following values update properly only when entity is local:\n> - lastEntityCausingDamage\n> - lastDamageTime\n> - isStopped\n> Other values are either static or update depending on how your client sees the entity right now.\n>\n> Timer values are never exact between clients and vary slightly depending on latency, JIP clients end up with large timer values close to game's time but get normal once associated value changes again:\n> - `deadSetTime`\n> - `lastDamageTime`\n> - `upsideDownTime`"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"entity getEntityInfo index","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":"property index (see main syntax)","types":["Number"],"since":null,"text":"index: Number - property index (see main syntax)"}],"returns":{"type":"Anything","types":["Anything"],"description":"depends on the requested property, or Nothing","text":"Anything - depends on the requested property, or Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _entityInfo = getEntityInfo ent1;\n_entityInfo params [\n    \"_isMan\",\n    \"_isAnimal\",\n    \"_isDeadSet\",\n    \"_deadSetTime\",\n    \"_lastEntityCausingDamage\",\n    \"_lastDamageTime\",\n    \"_isUpsideDown\",\n    \"_upsideDownTime\",\n    \"_isStopped\",\n    \"_canFloat\",\n    \"_hasTerminalOpened\",\n    \"_isWeaponholder\",\n    \"_isWreck\",\n    \"_isSmoking\",\n    \"_isSetForDeletion\",\n    \"_isParachute\"\n];\n```","code":["private _entityInfo = getEntityInfo ent1;\n_entityInfo params [\n\t\"_isMan\",\n\t\"_isAnimal\",\n\t\"_isDeadSet\",\n\t\"_deadSetTime\",\n\t\"_lastEntityCausingDamage\",\n\t\"_lastDamageTime\",\n\t\"_isUpsideDown\",\n\t\"_upsideDownTime\",\n\t\"_isStopped\",\n\t\"_canFloat\",\n\t\"_hasTerminalOpened\",\n\t\"_isWeaponholder\",\n\t\"_isWreck\",\n\t\"_isSmoking\",\n\t\"_isSetForDeletion\",\n\t\"_isParachute\"\n];"]},{"text":"```sqf\nprivate _isMan = ent1 getEntityInfo 0;\n```","code":["private _isMan = ent1 getEntityInfo 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cursorObject","cursorTarget","createSimpleObject","getObjectType","getObjectTextures","objectParent","setVelocityTransformation","getUnitFreefallInfo","getModelInfo","getShotInfo","getRespawnVehicleInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getEnv3DSoundController","operator":null,"title":"getEnv3DSoundController","type":"command","url":"https://community.bistudio.com/wiki/getEnv3DSoundController","revid":309132,"updated":"2022-05-03T11:42:40Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns value of the specified 3D controller, see getAllEnv3DSoundControllers.","syntaxes":[{"syntax":"object getEnv3DSoundController controller","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"environmental sound source like a tree or a house - see allEnv3DSoundSources","types":["Object"],"since":null,"text":"object: Object - environmental sound source like a tree or a house - see allEnv3DSoundSources"},{"name":"controller","type":"String","optional":false,"default":null,"description":"name of environmental variable like \"trees\" or \"houses\"","types":["String"],"since":null,"text":"controller: String - name of environmental variable like \"trees\" or \"houses\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"controller","types":["String"]}}],"examples":[{"text":"```sqf\n_thatTreeOverThere getEnv3DSoundController \"rainDrops\"; // returns 1\n```","code":["_thatTreeOverThere getEnv3DSoundController \"rainDrops\"; // returns 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getEnvSoundController","getAllEnv3DSoundControllers","allEnv3DSoundSources","selectBestPlaces","getSoundController","getSoundControllerResult","getAllEnvSoundControllers","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount","Arma 3: Sound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"getEnvSoundController","operator":null,"title":"getEnvSoundController","type":"command","url":"https://community.bistudio.com/wiki/getEnvSoundController","revid":319197,"updated":"2022-05-13T09:23:21Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns value of the specified controller, see getAllEnvSoundControllers","syntaxes":[{"syntax":"position getEnvSoundController controller","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"controller","type":"String","optional":false,"default":null,"description":"name of environmental variable like \"trees\" or \"houses\"","types":["String"],"since":null,"text":"controller: String - name of environmental variable like \"trees\" or \"houses\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"position","types":["Position"]},"right":{"text":"controller","types":["String"]}}],"examples":[{"text":"```sqf\nposition player getEnvSoundController \"trees\"; //0.3333\n```","code":["position player getEnvSoundController \"trees\"; //0.3333"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllEnv3DSoundControllers","getEnv3DSoundController","allEnv3DSoundSources","selectBestPlaces","getSoundController","getSoundControllerResult","getAllEnvSoundControllers","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount","Arma 3: Sound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getEventHandlerInfo","operator":null,"title":"getEventHandlerInfo","type":"command","url":"https://community.bistudio.com/wiki/getEventHandlerInfo","revid":377682,"updated":"2026-01-02T09:02:48Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Queries given event handler's information.","syntaxes":[{"syntax":"oper getEventHandlerInfo [type, id]","since":null,"effect":null,"exec":null,"params":[{"name":"oper","type":"Object, Group, Control or Display","optional":false,"default":null,"description":"subject to which event handler is assigned","types":["Object","Group","Control","Display"],"since":null,"text":"oper: Object, Group, Control or Display - subject to which event handler is assigned"},{"name":"type","type":"String","optional":false,"default":null,"description":"event handler name","types":["String"],"since":null,"text":"type: String - event handler name"},{"name":"id","type":"Number","optional":false,"default":null,"description":"event handler id returned by addEventHandler, ctrlAddEventHandler, displayAddEventHandler, or addMPEventHandler - **not** any other EH system (e.g add3DENEventHandler or addUserActionEventHandler)","types":["Number"],"since":null,"text":"id: Number - event handler id returned by addEventHandler, ctrlAddEventHandler, displayAddEventHandler, or addMPEventHandler - **not** any other EH system (e.g add3DENEventHandler or addUserActionEventHandler)"}],"returns":{"type":"Array with [exists, isLast, total] or empty array []","types":["Array"],"description":"exists: Boolean - event handler exists - isLast: Boolean - will be executed last (relevant if last event handler modifies default engine behaviour) - total: Number - total number of event handlers added to the same event","text":"Array with [exists, isLast, total] or empty array []\n- exists: Boolean - event handler exists\n- isLast: Boolean - will be executed last (relevant if last event handler modifies default engine behaviour)\n- total: Number - total number of event handlers added to the same event"},"form":"binary","operator":null,"left":{"text":"oper","types":["Object","Group","Control","Display"]},"right":{"text":"[type, id]","types":["Array"]}},{"syntax":"getEventHandlerInfo [type, id]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"event handler name","types":["String"],"since":null,"text":"type: String - event handler name"},{"name":"id","type":"Number","optional":false,"default":null,"description":"event handler id returned by addMissionEventHandler or addMusicEventHandler **only**","types":["Number"],"since":null,"text":"id: Number - event handler id returned by addMissionEventHandler or addMusicEventHandler **only**"}],"returns":{"type":"Array with [exists, isLast, total] or empty array []","types":["Array"],"description":"exists: Boolean - event handler exists - isLast: Boolean - will be executed last (relevant if last event handler modifies default engine behaviour) - total: Number - total number of event handlers added to the same event","text":"Array with [exists, isLast, total] or empty array []\n- exists: Boolean - event handler exists\n- isLast: Boolean - will be executed last (relevant if last event handler modifies default engine behaviour)\n- total: Number - total number of event handlers added to the same event"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, id]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _info = player getEventHandlerInfo [\"MPKilled\", 1];            // object EH\n```","code":["private _info = player getEventHandlerInfo [\"MPKilled\", 1];\t\t\t// object EH"]},{"text":"```sqf\nprivate _info = getEventHandlerInfo [\"EachFrame\", 0];                // mission EH\n```","code":["private _info = getEventHandlerInfo [\"EachFrame\", 0];\t\t\t\t// mission EH"]},{"text":"```sqf\nprivate _info = _bullet getEventHandlerInfo [\"Deflected\", 0];        // projectile EH\n```","code":["private _info = _bullet getEventHandlerInfo [\"Deflected\", 0];\t\t// projectile EH"]},{"text":"```sqf\nprivate _info = _group getEventHandlerInfo [\"EnemyDetected\", 1];    // group EH\n```","code":["private _info = _group getEventHandlerInfo [\"EnemyDetected\", 1];\t// group EH"]},{"text":"```sqf\nprivate _info = _control getEventHandlerInfo [\"ButtonClick\", 1];    // control (UI) EH\n```","code":["private _info = _control getEventHandlerInfo [\"ButtonClick\", 1];\t// control (UI) EH"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addEventHandler","ctrlAddEventHandler","displayAddEventHandler","addMPEventHandler","addMissionEventHandler","addMusicEventHandler"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getFatigue","operator":null,"title":"getFatigue","type":"command","url":"https://community.bistudio.com/wiki/getFatigue","revid":363589,"updated":"2024-04-07T18:18:03Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns fatigue of given unit.","syntaxes":[{"syntax":"getFatigue unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getFatigue player < 0.5) then { player sideChat \"I'm good to go!\" };\n```","code":["if (getFatigue player < 0.5) then { player sideChat \"I'm good to go!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFatigue","enableFatigue","getStamina"],"notes":[{"user":"Killzone_Kid","date":"2014-04-05T09:30:00Z","text":"getFatigue can be applied to remote unit however it will not read the changes made to unit's fatigue with setFatigue command. Only natural changes resulting from unit moving will be counted.\nWhen applied to local unit, it will read resulting value of natural fatigue combined with artificial changes added locally by setFatigue.\nIn short, the server wouldn't know the correct value of remote unit's fatigue if you used setFatigue on the unit prior."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getFieldManualStartPage","operator":null,"title":"getFieldManualStartPage","type":"command","url":"https://community.bistudio.com/wiki/getFieldManualStartPage","revid":377874,"updated":"2026-01-04T13:13:54Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of the starting topic and hint the given field manual should display.","syntaxes":[{"syntax":"getFieldManualStartPage display","since":null,"effect":null,"exec":null,"params":[{"name":"display","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"display: Display"}],"returns":{"type":"Array with [startingTopic, hint]","types":["Array"],"description":"startingTopic: String - hint: String","text":"Array with [startingTopic, hint]\n\n- startingTopic: String\n- hint: String"},"form":"unary","operator":null,"left":null,"right":{"text":"display","types":["Display"]}}],"examples":[{"text":"```sqf\ngetFieldManualStartPage (findDisplay 46); // returns [\"\", \"\"]\n```","code":["getFieldManualStartPage (findDisplay 46); // returns [\"\", \"\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.18","Scripting Commands"]},{"name":"getForcedFlagTexture","operator":null,"title":"getForcedFlagTexture","type":"command","url":"https://community.bistudio.com/wiki/getForcedFlagTexture","revid":348629,"updated":"2023-11-08T13:46:06Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for forceFlagTexture. Forced texture is different from your normal flag texture, which can be retrieved with flagTexture","syntaxes":[{"syntax":"getForcedFlagTexture object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle, unit or flag pole","types":["Object"],"since":null,"text":"object: Object - vehicle, unit or flag pole"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetForcedFlagTexture player;\n```","code":["getForcedFlagTexture player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceFlagTexture","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"getForcedSpeed","operator":null,"title":"getForcedSpeed","type":"command","url":"https://community.bistudio.com/wiki/getForcedSpeed","revid":338349,"updated":"2023-02-28T14:44:10Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns forced speed set with forceSpeed or -1 if not set.","syntaxes":[{"syntax":"getForcedSpeed entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\n_spd = getForcedSpeed _heli;\n```","code":["_spd = getForcedSpeed _heli;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceSpeed","getSpeed","forceWalk"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getFriend","operator":null,"title":"getFriend","type":"command","url":"https://community.bistudio.com/wiki/getFriend","revid":348505,"updated":"2023-11-08T13:01:33Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns if sides are friendly or hostile. For a value smaller than 0.6 it results in being enemy, otherwise it is friendly. See also Side Relations.","syntaxes":[{"syntax":"side1 getFriend side2","since":null,"effect":null,"exec":null,"params":[{"name":"side1","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side1: Side"},{"name":"side2","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side2: Side"}],"returns":{"type":"Number","types":["Number"],"description":"decimal value between 0.0 to 1.0","text":"Number - decimal value between 0.0 to 1.0"},"form":"binary","operator":null,"left":{"text":"side1","types":["Side"]},"right":{"text":"side2","types":["Side"]}}],"examples":[{"text":"```sqf\nvalue = west getFriend east;\n```","code":["value = west getFriend east;"]},{"text":"```sqf\n_isEnemy = side _killer getFriend side _victim < 0.6;\n```","code":["_isEnemy = side _killer getFriend side _victim < 0.6;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFriend","BIS_fnc_sideIsFriendly","BIS_fnc_sideIsEnemy","Side Relations"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getFSMVariable","operator":null,"title":"getFSMVariable","type":"command","url":"https://community.bistudio.com/wiki/getFSMVariable","revid":330370,"updated":"2022-09-04T20:25:49Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the value of variable in the variable space of given FSM. The FSM handle is the number returned by the execFSM command.","syntaxes":[{"syntax":"FSMhandle getFSMVariable name","since":null,"effect":null,"exec":null,"params":[{"name":"FSMhandle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"FSMhandle: Number"},{"name":"name","type":"String","optional":false,"default":null,"description":"name of the variable","types":["String"],"since":null,"text":"name: String - name of the variable"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"FSMhandle","types":["Number"]},"right":{"text":"name","types":["String"]}},{"syntax":"FSMhandle getFSMVariable [name, defaultValue]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"FSMhandle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"FSMhandle: Number"},{"name":"name","type":"String","optional":false,"default":null,"description":"name of the variable","types":["String"],"since":null,"text":"name: String - name of the variable"},{"name":"defaultValue","type":"Anything","optional":false,"default":null,"description":"value to return if variable is nil","types":["Anything"],"since":null,"text":"defaultValue: Anything - value to return if variable is nil"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"FSMhandle","types":["Number"]},"right":{"text":"[name, defaultValue]","types":["Array"]}}],"examples":[{"text":"```sqf\n_handle getFSMVariable \"_foo\";\n```","code":["_handle getFSMVariable \"_foo\";"]},{"text":"```sqf\n_handle getFSMVariable [\"_foo\", 123];\n```","code":["_handle getFSMVariable [\"_foo\", 123];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","commandFSM","completedFSM","doFSM","execFSM","setFSMVariable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getFuelCargo","operator":null,"title":"getFuelCargo","type":"command","url":"https://community.bistudio.com/wiki/getFuelCargo","revid":364121,"updated":"2024-05-04T22:07:43Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the fuel amount (1 is full) in the cargo space of a refueling vehicle.\n\n> [!NOTE]\n> Since Arma 3 v1.96 the return value for vehicles that are not configured to have ability to refuel other vehicles is -1. (Prior to that the value was negative infinity)","syntaxes":[{"syntax":"getFuelCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Number","types":["Number"],"description":"fuel cargo value, -1 if fuel cargo is not supported, 0 if the vehicle is !alive or isNull","text":"Number - fuel cargo value, -1 if fuel cargo is not supported, 0 if the vehicle is !alive or isNull"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvalue = getFuelCargo myVehicleName;\n```","code":["value = getFuelCargo myVehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFuelCargo","getAmmoCargo","getRepairCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"getFuelConsumptionCoef","operator":null,"title":"getFuelConsumptionCoef","type":"command","url":"https://community.bistudio.com/wiki/getFuelConsumptionCoef","revid":363320,"updated":"2024-03-26T16:41:39Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the fuel consumption coefficient, which is a multiplier of the fuel consumption rate in config.","syntaxes":[{"syntax":"getFuelConsumptionCoef vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle : Object"}],"returns":{"type":"Number","types":["Number"],"description":"fuel consumption coefficient","text":"Number - fuel consumption coefficient"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getFuelConsumptionCoef myCar > 1) then { hint \"You should have a mechanic look at your engine!\" }\n```","code":["if (getFuelConsumptionCoef myCar > 1) then { hint \"You should have a mechanic look at your engine!\" }"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFuelConsumptionCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"getGraphValues","operator":null,"title":"getGraphValues","type":"command","url":"https://community.bistudio.com/wiki/getGraphValues","revid":351320,"updated":"2023-11-27T05:02:35Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Generate graph y - coordinates of all input values within specific x and y range.","syntaxes":[{"syntax":"getGraphValues [[graphMinX, graphMaxX, graphMinY, graphMaxY, valueCount, randomOffset], x1, y1, x2, y2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"graphMinX","type":"Number","optional":false,"default":null,"description":"minimum x-axis value","types":["Number"],"since":null,"text":"graphMinX: Number - minimum x-axis value"},{"name":"graphMaxX","type":"Number","optional":false,"default":null,"description":"maximum x-axis value","types":["Number"],"since":null,"text":"graphMaxX: Number - maximum x-axis value"},{"name":"graphMinY","type":"Number","optional":false,"default":null,"description":"minimum y-axis value","types":["Number"],"since":null,"text":"graphMinY: Number - minimum y-axis value"},{"name":"graphMaxY","type":"Number","optional":false,"default":null,"description":"maximum y-axis value","types":["Number"],"since":null,"text":"graphMaxY: Number - maximum y-axis value"},{"name":"valueCount","type":"Number","optional":false,"default":null,"description":"number of values the returned array should have","types":["Number"],"since":null,"text":"valueCount: Number - number of values the returned array should have"},{"name":"randomOffset","type":"Number","optional":false,"default":null,"description":"random range for returned y value","types":["Number"],"since":null,"text":"randomOffset: Number - random range for returned y value"},{"name":"xN","type":"Number","optional":false,"default":null,"description":"nth x value","types":["Number"],"since":null,"text":"xN: Number - nth x value"},{"name":"yN","type":"Number","optional":false,"default":null,"description":"nth y value","types":["Number"],"since":null,"text":"yN: Number - nth y value"}],"returns":{"type":"Array of Array of Numbers","types":["Array","Number"],"description":"to format [arrayOfYvalues, arrayOfXvalues]","text":"Array of Array of Numbers - to format [arrayOfYvalues, arrayOfXvalues]"},"form":"unary","operator":null,"left":null,"right":{"text":"[[graphMinX, graphMaxX, graphMinY, graphMaxY, valueCount, randomOffset], x1, y1, x2, y2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _minX = 0;\nprivate _maxX = 10;\nprivate _minY = 0;\nprivate _maxY = 100;\nprivate _count = 11;\nprivate _random = 0;\n\ngetGraphValues [\n    [_minX, _maxX, _minY, _maxY, _count, _random],\n    0, 5,\n    1, 10,\n    2, 100,\n    3, 50,\n    4, 30,\n    5, 100,\n    6, 10,\n    7, 50,\n    8, 75,\n    9, 100,\n    10, 100\n];\n/*\n    returns [[0.05, 0.1, 1, 0.5, 0.3, 1, 0.1, 0.5, 0.75, 1, 1], [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10]]\n    supposedly [array of 1-based Y values, array of X values]\n*/\n```","code":["private _minX = 0;\nprivate _maxX = 10;\nprivate _minY = 0;\nprivate _maxY = 100;\nprivate _count = 11;\nprivate _random = 0;\n\ngetGraphValues [\n\t[_minX, _maxX, _minY, _maxY, _count, _random],\n\t0, 5,\n\t1, 10,\n\t2, 100,\n\t3, 50,\n\t4, 30,\n\t5, 100,\n\t6, 10,\n\t7, 50,\n\t8, 75,\n\t9, 100,\n\t10, 100\n];\n/*\n\treturns [[0.05, 0.1, 1, 0.5, 0.3, 1, 0.1, 0.5, 0.75, 1, 1], [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10]]\n\tsupposedly [array of 1-based Y values, array of X values]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["decayGraphValues"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"getGroupIcon","operator":null,"title":"getGroupIcon","type":"command","url":"https://community.bistudio.com/wiki/getGroupIcon","revid":376589,"updated":"2025-10-29T23:17:41Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get group icon properties. Since Arma 3 v2.22 command also returns 3d offsets.","syntaxes":[{"syntax":"group getGroupIcon id","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"id","type":"Number","optional":false,"default":null,"description":"icon id","types":["Number"],"since":null,"text":"id: Number - icon id"}],"returns":{"type":"Array","types":["Array"],"description":"[icon,[offsetx,offsety,offsetX3d,offsetY3d]]","text":"Array - [icon,[offsetx,offsety,offsetX3d,offsetY3d]]"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"id","types":["Number"]}}],"examples":[{"text":"```sqf\n_grpIconId = _group getVariable \"BIS_MARTA_ICON_TYPE\";\n_grpIcon = _group getGroupIcon _grpIconId;\n```","code":["_grpIconId = _group getVariable \"BIS_MARTA_ICON_TYPE\";\n_grpIcon = _group getGroupIcon _grpIconId;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcons","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getGroupIconParams","operator":null,"title":"getGroupIconParams","type":"command","url":"https://community.bistudio.com/wiki/getGroupIconParams","revid":377868,"updated":"2026-01-04T11:36:22Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns group icons params used for command bar drawing such as color, text, scale, visibility, waypoint visibility, waypoint color.","syntaxes":[{"syntax":"getGroupIconParams group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Array with [color, text, scale, visibility, WPvisibility, WPcolor]","types":["Array"],"description":"color: Color (RGB) - icon color - text: String - icon text - scale: Number - icon scale - visibility: Boolean - icon visibility - WPvisibility: Boolean - waypoint visibility - WPcolor: Color (RGB) - waypoint color","text":"Array with [color, text, scale, visibility, WPvisibility, WPcolor]\n- color: Color (RGB) - icon color\n- text: String - icon text\n- scale: Number - icon scale\n- visibility: Boolean - icon visibility\n- WPvisibility: Boolean - waypoint visibility\n- WPcolor: Color (RGB) - waypoint color"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_iconParams = getGroupIconParams group player;\n```","code":["_iconParams = getGroupIconParams group player;"]},{"text":"```sqf\ngetGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\", \"_WPVisibility\", \"_WPColor\"];\n```","code":["getGroupIconParams group player params [\"_color\", \"_text\", \"_scale\", \"_visibility\", \"_WPVisibility\", \"_WPColor\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getGroupIcons","operator":null,"title":"getGroupIcons","type":"command","url":"https://community.bistudio.com/wiki/getGroupIcons","revid":376588,"updated":"2025-10-29T23:16:41Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all group icons. Since Arma 3 v2.22 command also returns 3d offsets.","syntaxes":[{"syntax":"getGroupIcons group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Array","types":["Array"],"description":"[[id,icon,[offsetx,offsety,offsetX3d,offsetY3d]],..]","text":"Array - [[id,icon,[offsetx,offsety,offsetX3d,offsetY3d]],..]"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getHideFrom","operator":null,"title":"getHideFrom","type":"command","url":"https://community.bistudio.com/wiki/getHideFrom","revid":378610,"updated":"2026-05-13T16:46:20Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the Position where object believes the enemy to be.\nIf there is no direct line of sight between the object and the enemy, this position is extrapolated based on the last known position and speed of the enemy.\nA returned position of [0,0,0] implies that object does not [[knowsAbout[know about]] enemy.\nIf enemy is null it is some position in front of the object or enemy position.","syntaxes":[{"syntax":"object getHideFrom enemy","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"enemy","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"enemy: Object"}],"returns":{"type":"Array","types":["Array"],"description":"ASLToATL representation of the believed aimPos of the enemy object","text":"Array - ASLToATL representation of the believed aimPos of the enemy object"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"enemy","types":["Object"]}}],"examples":[{"text":"```sqf\n_pos = player getHideFrom _enemy;\n```","code":["_pos = player getHideFrom _enemy;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findCover","setHideBehind","isHidden","knowsAbout","forgetTarget"],"notes":[{"user":"Benargee","date":"2015-04-25T07:15:00Z","text":"This command is definitely not broken, at least not in A3 1.42. It functions exactly as the description says it does.\nThe reason why the Z value is elevated is because it represents the units torso. When the unit is prone and spotted, the Z value is much less.\nHere you can see a perfectly working example of this command Talk:getHideFrom#Operation Script Sample."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getHit","operator":null,"title":"getHit","type":"command","url":"https://community.bistudio.com/wiki/getHit","revid":340840,"updated":"2023-05-10T13:56:15Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns selection damage. Same as getHitPointDamage, only the argument is selection part instead of hit point.\n\n> [!NOTE]\n> Some part names are in Czech; see the translation table.","syntaxes":[{"syntax":"vehicle getHit selection","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be queried","types":["Object"],"since":null,"text":"vehicle : Object - vehicle to be queried"},{"name":"selection","type":"String","optional":false,"default":null,"description":"selection part name","types":["String"],"since":null,"text":"selection: String - selection part name"}],"returns":{"type":"Number","types":["Number"],"description":"before Arma 3 v1.94, Nothing was returned when an invalid selection was provided (now returns `0`)","text":"Number - before Arma 3 v1.94, Nothing was returned when an invalid *selection* was provided (now returns `0`)"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"selection","types":["String"]}}],"examples":[{"text":"```sqf\nhint str (player getHit \"head\");\n```","code":["hint str (player getHit \"head\");"]},{"text":"```sqf\nprivate _engineDamage = _car getHit \"motor\";\n```","code":["private _engineDamage = _car getHit \"motor\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setHit","getHitPointDamage","setHitPointDamage","setDamage","damage","getHitIndex","setHitIndex"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getHitIndex","operator":null,"title":"getHitIndex","type":"command","url":"https://community.bistudio.com/wiki/getHitIndex","revid":340842,"updated":"2023-05-10T13:57:50Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return current level of damage for a specific Hit Point (specified by its hit part index). All hit points can be obtained with getAllHitPointsDamage command.\n- 0: no damage\n- 1: full damage","syntaxes":[{"syntax":"vehicle getHitIndex hitPartIndex","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be queried","types":["Object"],"since":null,"text":"vehicle : Object - vehicle to be queried"},{"name":"hitPartIndex","type":"Number","optional":false,"default":null,"description":"hit part index of the Hit Point","types":["Number"],"since":null,"text":"hitPartIndex: Number - hit part index of the Hit Point"}],"returns":{"type":"Number","types":["Number"],"description":"before Arma 3 v1.94, Nothing was returned when an invalid selection was provided (now returns `0`)","text":"Number - before Arma 3 v1.94, Nothing was returned when an invalid *selection* was provided (now returns `0`)"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"hitPartIndex","types":["Number"]}}],"examples":[{"text":"```sqf\nvehicle player getHitIndex 3;\n```","code":["vehicle player getHitIndex 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllHitPointsDamage","setHitIndex","setHitPointDamage","getHitPointDamage","setHit","getHit","setDamage","damage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"getHitPointDamage","operator":null,"title":"getHitPointDamage","type":"command","url":"https://community.bistudio.com/wiki/getHitPointDamage","revid":377769,"updated":"2026-01-03T01:32:16Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return current level of damage in range 0..1 for a specific Hit Point (specified by its config class).\nIf you need to get damage of a selection instead of hit point, use getHit.","syntaxes":[{"syntax":"vehicle getHitPointDamage hitPointName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be queried","types":["Object"],"since":null,"text":"vehicle : Object - vehicle to be queried"},{"name":"hitPointName","type":"String","optional":false,"default":null,"description":"name of the Hit Point class","types":["String"],"since":null,"text":"hitPointName: String - name of the Hit Point class"}],"returns":{"type":"Number","types":["Number"],"description":"before Arma 3 v1.94, Nothing was returned when an invalid selection was provided (now returns `0`)","text":"Number - before Arma 3 v1.94, Nothing was returned when an invalid *selection* was provided (now returns `0`)"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"hitPointName","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player getHitPointDamage \"hitEngine\";\n```","code":["vehicle player getHitPointDamage \"hitEngine\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setHitPointDamage","getAllHitPointsDamage","setHit","getHit","setDamage","damage","getHitIndex","setHitIndex"],"notes":[{"user":"Joris","date":"2011-11-25T15:06:00Z","text":"Common ObjectRTD Take On Helicopters Hit Points:\n- HitEngine (engine #1)\n- HitEngine2 (engine #2)\n- HitEngine3 (engine #3)\n- HitHRotor (main rotor)\n- HitVRotor (tail rotor)\n- HitBatteries (electrical systems)\n- HitLight (landing light)\n- HitHydraulics (entire hydraulics system)\n- HitTransmission (engine transmission)\n- HitGear (landing gear)\n- HitFuel (all fuel tanks)\n- HitHStabilizerL1 (first left horizontal stabilizer)\n- HitHStabilizerR1 (first right horizontal stabilizer)\n- HitVStabilizer1 (first vertical stabilizer)\n- HitTail (tail boom)\n- HitPitotTube (all pitot tubes)\n- HitStaticPort (all static ports)\n- HitStarter1 (starter for engine #1)\n- HitStarter2 (starter for engine #2)\n- HitStarter3 (starter for engine #3)\n- HitAvionics\n- HitHull\n- HitMissiles\n- HitRGlass\n- HitLGlass\n- HitGlass1\n- HitGlass2\n- HitGlass3\n- HitGlass4\n- HitGlass5\n- HitGlass6"},{"user":"K.J.","date":"2017-03-04T01:29:00Z","text":"Note that vehicles with multiple turrets have multiple HitTurret and HitGun classes that can't be distinguished based on the Hitpoint class name. They can only be distinguished by their selection names.\nThe selection names do not necessarily correspond to a common nomenclature, especially for mod vehicles. There can also be multiple empty Hitpoint Class names on a vehicle or infantry unit.\nThey can be hitpoints for vehicle headlights or be the result of a bad config/model, as hitpoints that have an undefined named selection in their config class or are missing their named selection in the model will result in an empty HitPoint class name."},{"user":"X3KJ","date":"2018-10-05T23:12:00Z","text":"Note: Since arma3tanks DLC, Turrets of vanilla vehicles no longer have identical Hitpoint Classes for multiple Turrets.\nMod vehicles may still have the old issue, but they produces error messages in RPT if they still do (and thus should be enough motivation to fix them)."}],"categories":["Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getItemCargo","operator":null,"title":"getItemCargo","type":"command","url":"https://community.bistudio.com/wiki/getItemCargo","revid":378322,"updated":"2026-04-02T16:23:27Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all items names and count from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"getItemCargo box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Array with [classes, counts]","types":["Array"],"description":"classes: Array of Strings - Item class names - counts: Array of Numbers - Item counts","text":"Array with [classes, counts]\n- classes: Array of Strings - Item class names\n- counts: Array of Numbers - Item counts"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\ngetItemCargo cursorTarget;\n/*\n    returns e.g\n    [\n        [\"5ItemA\", \"10ItemB\"]\n        [5, 10]\n    ]\n*/\n```","code":["getItemCargo cursorTarget;\n/*\n\treturns e.g\n\t[\n        [\"5ItemA\", \"10ItemB\"]\n        [5, 10]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["itemCargo","addItemCargo","addItemCargoGlobal","clearItemCargo","clearItemCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getLeaning","operator":null,"title":"getLeaning","type":"command","url":"https://community.bistudio.com/wiki/getLeaning","revid":369757,"updated":"2024-10-08T15:08:56Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the leaning factor of the given unit.","syntaxes":[{"syntax":"getLeaning unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":"leaning factor from -1 to 1","text":"Number - leaning factor from -1 to 1"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getLeaning player < 0) then { systemChat \"player is leaning left\" };\n```","code":["if (getLeaning player < 0) then { systemChat \"player is leaning left\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationState","unitPos","stance","pose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getLightInfo","operator":null,"title":"getLightInfo","type":"command","url":"https://community.bistudio.com/wiki/getLightInfo","revid":378895,"updated":"2026-08-11T14:56:31Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns various properties for the given `1. lightpoint` or `1. lightreflector`. ConePars and VolumeShapePars are exclusive properties of `1. lightreflector` only.","syntaxes":[{"syntax":"getLightInfo light","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":"`1. lightpoint` or `1. lightreflector`","types":["Object"],"since":null,"text":"light: Object - `1. lightpoint` or `1. lightreflector`"}],"returns":{"type":"Array with [intensity, diffuseColor, ambientColor, dayLight, IR, useFlare, flareSize, flareMaxDistance, attenuationPars, attachedToPars, conePars, volumeShapePars]","types":["Array"],"description":"0 - intensity: Number - getter for setLightIntensity (setLightBrightness also sets intensity in a weird way, but it is also obsolete) - 1 - diffuseColor: Color - getter for setLightColor - 2 - ambientColor: Color - getter for setLightAmbient - 3 - dayLight: Boolean - getter for setLightDayLight - 4 - IR: Boolean - getter for setLightIR - 5 - useFlare: Boolean - getter for setLightUseFlare - 6 - flareSize: Number - getter for setLightFlareSize - 7 - flareMaxDistance: Number - getter for setLightFlareMaxDistance - 8 - attenuationPars: Array - getter for setLightAttenuation - 9 - attachedToPars: Array - getter for lightAttachObject, lightDetachObject - 10 - conePars: Array - getter for setLightConePars - 11 - volumeShapePars: Array - getter for setLightVolumeShape","text":"Array with [intensity, diffuseColor, ambientColor, dayLight, IR, useFlare, flareSize, flareMaxDistance, attenuationPars, attachedToPars, conePars, volumeShapePars]\n- 0 - intensity: Number - getter for setLightIntensity (setLightBrightness also sets intensity in a weird way, but it is also obsolete)\n- 1 - diffuseColor: Color - getter for setLightColor\n- 2 - ambientColor: Color - getter for setLightAmbient\n- 3 - dayLight: Boolean - getter for setLightDayLight\n- 4 - IR: Boolean - getter for setLightIR\n- 5 - useFlare: Boolean - getter for setLightUseFlare\n- 6 - flareSize: Number - getter for setLightFlareSize\n- 7 - flareMaxDistance: Number - getter for setLightFlareMaxDistance\n- 8 - attenuationPars: Array - getter for setLightAttenuation\n- 9 - attachedToPars: Array - getter for lightAttachObject, lightDetachObject\n- 10 - conePars: Array - getter for setLightConePars\n- 11 - volumeShapePars: Array - getter for setLightVolumeShape"},"form":"unary","operator":null,"left":null,"right":{"text":"light","types":["Object"]}},{"syntax":"light getLightInfo index","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":"`1. lightpoint` or `1. lightreflector`","types":["Object"],"since":null,"text":"light: Object - `1. lightpoint` or `1. lightreflector`"},{"name":"index","type":"Number","optional":false,"default":null,"description":"property index (see main syntax, for example 0 for light intensity)","types":["Number"],"since":null,"text":"index: Number - property index (see main syntax, for example 0 for light intensity)"}],"returns":{"type":"Anything","types":["Anything"],"description":"depends on the requested property, or Nothing","text":"Anything - depends on the requested property, or Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _lightInfo = getLightInfo light1;\n```","code":["private _lightInfo = getLightInfo light1;"]},{"text":"```sqf\nprivate _lightIntensity = light1 getLightInfo 0;\n```","code":["private _lightIntensity = light1 getLightInfo 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightIntensity","setLightColor","setLightAmbient","setLightDayLight","setLightIR","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightAttenuation","lightAttachObject","lightDetachObject","setLightConePars","getUnitFreefallInfo","getEntityInfo","getModelInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"getLighting","operator":null,"title":"getLighting","type":"command","url":"https://community.bistudio.com/wiki/getLighting","revid":377678,"updated":"2026-01-02T09:02:42Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets general environment's light settings.","syntaxes":[{"syntax":"getLighting","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [ambientLightColor, ambientLightBrightness, lightDirection, starsVisibility]","types":["Array"],"description":"ambientLightColor: Color (RGB) - ambientLightBrightness: Number - lightDirection: Vector3D - starsVisibility: Number","text":"Array with [ambientLightColor, ambientLightBrightness, lightDirection, starsVisibility]\n- ambientLightColor: Color (RGB)\n- ambientLightBrightness: Number\n- lightDirection: Vector3D\n- starsVisibility: Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ngetLighting; // returns [[0.646753,0.781818,1],28526.2,[-0.0167152,0.211598,-0.977214],0]\n```","code":["getLighting; // returns [[0.646753,0.781818,1],28526.2,[-0.0167152,0.211598,-0.977214],0]"]},{"text":"```sqf\ngetLighting params [\"_ambientLightColour\", \"_ambientLightBrightness\", \"_lightDirection\", \"_starsVisibility\"];\n```","code":["getLighting params [\"_ambientLightColour\", \"_ambientLightBrightness\", \"_lightDirection\", \"_starsVisibility\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getLightingAt","moonPhase","Light Source Tutorial"],"notes":[{"user":"POLPOX","date":"2023-09-18T13:20:29Z","text":"Possible to check if a position is in a shadow.\n\n```sqf\n[player,\"VIEW\"] checkVisibility [eyePos player,eyePos player vectorDiff ((getLighting#2) vectorMultiply 200)]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getLightingAt","operator":null,"title":"getLightingAt","type":"command","url":"https://community.bistudio.com/wiki/getLightingAt","revid":377785,"updated":"2026-01-03T01:33:52Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets provided object's lighting information.\n\n> [!NOTE]\n> The command will use local player's night vision state to determine whether to include IR lights in the result or not.\n>\n> On a dedicated server, headless client or if the player is null, the night vision state will always be off.","syntaxes":[{"syntax":"getLightingAt obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Array with [ambientLightColor, ambientLightBrightness, dynamicLightColor, dynamicLightBrightness]","types":["Array"],"description":"ambientLightColor: Color (RGB) - ambientLightBrightness: Number - dynamicLightColor: Color (RGB) - dynamicLightBrightness: Number","text":"Array with [ambientLightColor, ambientLightBrightness, dynamicLightColor, dynamicLightBrightness]\n- ambientLightColor: Color (RGB)\n- ambientLightBrightness: Number\n- dynamicLightColor: Color (RGB)\n- dynamicLightBrightness: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\ngetLightingAt player; // returns [[1,1,1], 0.5, [0,0,0], 0]\n```","code":["getLightingAt player; // returns [[1,1,1], 0.5, [0,0,0], 0]"]},{"text":"```sqf\ngetLightingAt player params [\"_ambientLightColour\", \"_ambientLightBrightness\", \"_dynamicLightColour\", \"_dynamicLightBrightness\"];\n```","code":["getLightingAt player params [\"_ambientLightColour\", \"_ambientLightBrightness\", \"_dynamicLightColour\", \"_dynamicLightBrightness\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getLighting","Light Source Tutorial"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getLoadedModsInfo","operator":null,"title":"getLoadedModsInfo","type":"command","url":"https://community.bistudio.com/wiki/getLoadedModsInfo","revid":373357,"updated":"2025-04-23T11:27:20Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns information about all loaded modifications.\n\n> [!NOTE]\n> The first 7 values are equal to what is printed in RPT on game startup in the  category.","syntaxes":[{"syntax":"getLoadedModsInfo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Arrays in format [modName, modDir, isDefault, isOfficial, origin, hash, hashShort, itemID]:","types":["Array"],"description":"modName: String - user-friendly mod name - modDir: String - mod directory name - isDefault: Boolean - true for base DLC, false for optional - isOfficial: Boolean - true for official content, false for user-generated content - origin: String - either \"GAME DIR\" or \"NOT FOUND\" (for the base game or on error) - hash: String - hashShort: String - itemID: String - either DLC appId or Steam Workshop itemID, \"0\" for the base game","text":"Array of Arrays in format [modName, modDir, isDefault, isOfficial, origin, hash, hashShort, itemID]:\n- modName: String - user-friendly mod name\n- modDir: String - mod directory name\n- isDefault: Boolean - true for base DLC, false for optional\n- isOfficial: Boolean - true for official content, false for user-generated content\n- origin: String - either \"GAME DIR\" or \"NOT FOUND\" (for the base game or on error)\n- hash: String\n- hashShort: String\n- itemID: String - either DLC appId or Steam Workshop itemID, \"0\" for the base game"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _loadedMods = getLoadedModsInfo;\n/*\n    [\n        [\"Community Base Addons v3.18.1\",\"@cba_a3\",false,false,\"GAME DIR\",\"b256a972cc3a9bde93988e243ad5db85887dece0\",\"7de4bd5c\",\"450814997\"],\n        [\"Arma 3 Art of War\",\"aow\",true,true,\"GAME DIR\",\"c6afb04056f1cea283c60e13b6d5ac8049140341\",\"2ed2ccad\",\"1325500\"],\n        [\"Arma 3 Contact (Platform)\",\"enoch\",true,true,\"GAME DIR\",\"72172fe806a8cd128d5dd5f224dbf754b69af881\",\"32ed0446\",\"1021790\"],\n        [\"Arma 3 Tanks\",\"tank\",true,true,\"GAME DIR\",\"35ef3b19b5ebd31d7da21565717f6d5c768edd59\",\"9c4a0882\",\"798390\"],\n        [\"Arma 3 Tac-Ops\",\"tacops\",true,true,\"GAME DIR\",\"e03d923a8391d527d34c3a2d311e6f2554df18c8\",\"e6729774\",\"744950\"],\n        [\"Arma 3 Laws of War\",\"orange\",true,true,\"GAME DIR\",\"71940c7021e27b4ae72cd6a527ff56784725850a\",\"d27bf111\",\"571710\"],\n        [\"Arma 3 Malden\",\"argo\",true,true,\"GAME DIR\",\"230aad2992427ef22b803e177bdedda7b3f1727d\",\"2e502f53\",\"639600\"],\n        [\"Arma 3 Jets\",\"jets\",true,true,\"GAME DIR\",\"d58526aaa24a73aa53d11b82f00cf49dc3ef3216\",\"d39b144d\",\"601670\"],\n        [\"Arma 3 Apex\",\"expansion\",true,true,\"GAME DIR\",\"dded307173ad9bb62fe09a5084bb7d70c81639d3\",\"57f2ccad\",\"395180\"],\n        [\"Arma 3 Marksmen\",\"mark\",true,true,\"GAME DIR\",\"eb956eb99f1a33cef4f825f8d52bc9ca9ef3d4cd\",\"d605b72\",\"332350\"],\n        [\"Arma 3 Helicopters\",\"heli\",true,true,\"GAME DIR\",\"0e14ac1e91df7c56725b1dc9a939c50c5d93fd4c\",\"a6e7077f\",\"304380\"],\n        [\"Arma 3 Karts\",\"kart\",true,true,\"GAME DIR\",\"f9bac1340520fc3a25c3c4c7b6c48efdba32d535\",\"9b1d75e8\",\"288520\"],\n        [\"Arma 3 Zeus\",\"curator\",true,true,\"GAME DIR\",\"5cfb449d86e7b7e8529909ec1c0656d70e2cfda0\",\"4ccdcca0\",\"275700\"],\n        [\"Arma 3\",\"A3\",true,true,\"GAME DIR\",\"\",\"\",\"0\"]]\n    ]\n*/\n```","code":["private _loadedMods = getLoadedModsInfo;\n/*\n\t[\n\t\t[\"Community Base Addons v3.18.1\",\"@cba_a3\",false,false,\"GAME DIR\",\"b256a972cc3a9bde93988e243ad5db85887dece0\",\"7de4bd5c\",\"450814997\"],\n\t\t[\"Arma 3 Art of War\",\"aow\",true,true,\"GAME DIR\",\"c6afb04056f1cea283c60e13b6d5ac8049140341\",\"2ed2ccad\",\"1325500\"],\n\t\t[\"Arma 3 Contact (Platform)\",\"enoch\",true,true,\"GAME DIR\",\"72172fe806a8cd128d5dd5f224dbf754b69af881\",\"32ed0446\",\"1021790\"],\n\t\t[\"Arma 3 Tanks\",\"tank\",true,true,\"GAME DIR\",\"35ef3b19b5ebd31d7da21565717f6d5c768edd59\",\"9c4a0882\",\"798390\"],\n\t\t[\"Arma 3 Tac-Ops\",\"tacops\",true,true,\"GAME DIR\",\"e03d923a8391d527d34c3a2d311e6f2554df18c8\",\"e6729774\",\"744950\"],\n\t\t[\"Arma 3 Laws of War\",\"orange\",true,true,\"GAME DIR\",\"71940c7021e27b4ae72cd6a527ff56784725850a\",\"d27bf111\",\"571710\"],\n\t\t[\"Arma 3 Malden\",\"argo\",true,true,\"GAME DIR\",\"230aad2992427ef22b803e177bdedda7b3f1727d\",\"2e502f53\",\"639600\"],\n\t\t[\"Arma 3 Jets\",\"jets\",true,true,\"GAME DIR\",\"d58526aaa24a73aa53d11b82f00cf49dc3ef3216\",\"d39b144d\",\"601670\"],\n\t\t[\"Arma 3 Apex\",\"expansion\",true,true,\"GAME DIR\",\"dded307173ad9bb62fe09a5084bb7d70c81639d3\",\"57f2ccad\",\"395180\"],\n\t\t[\"Arma 3 Marksmen\",\"mark\",true,true,\"GAME DIR\",\"eb956eb99f1a33cef4f825f8d52bc9ca9ef3d4cd\",\"d605b72\",\"332350\"],\n\t\t[\"Arma 3 Helicopters\",\"heli\",true,true,\"GAME DIR\",\"0e14ac1e91df7c56725b1dc9a939c50c5d93fd4c\",\"a6e7077f\",\"304380\"],\n\t\t[\"Arma 3 Karts\",\"kart\",true,true,\"GAME DIR\",\"f9bac1340520fc3a25c3c4c7b6c48efdba32d535\",\"9b1d75e8\",\"288520\"],\n\t\t[\"Arma 3 Zeus\",\"curator\",true,true,\"GAME DIR\",\"5cfb449d86e7b7e8529909ec1c0656d70e2cfda0\",\"4ccdcca0\",\"275700\"],\n\t\t[\"Arma 3\",\"A3\",true,true,\"GAME DIR\",\"\",\"\",\"0\"]]\n\t]\n*/"]},{"text":"```sqf\nprivate _modInfo = getLoadedModsInfo select 0;\n_modInfo params [\"_modname\", \"_modDir\", \"_isDefault\", \"_isOfficial\", \"_origin\", \"_hash\", \"_hashShort\", \"_itemID\"];\n```","code":["private _modInfo = getLoadedModsInfo select 0;\n_modInfo params [\"_modname\", \"_modDir\", \"_isDefault\", \"_isOfficial\", \"_origin\", \"_hash\", \"_hashShort\", \"_itemID\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allAddonsInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getMagazineCargo","operator":null,"title":"getMagazineCargo","type":"command","url":"https://community.bistudio.com/wiki/getMagazineCargo","revid":348622,"updated":"2023-11-08T13:46:04Z","groups":["Vehicle Inventory","Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all magazines types and count from the cargo space","syntaxes":[{"syntax":"getMagazineCargo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"}],"returns":{"type":"Array of arrays. [[\"5MagsType1\",\"10MagsType2\"],[5,10]]","types":["Array"],"description":null,"text":"Array of arrays. [[\"5MagsType1\",\"10MagsType2\"],[5,10]]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_content = getMagazineCargo carName;\n```","code":["_content = getMagazineCargo carName;"]},{"text":"```sqf\n_content = getMagazineCargo ammoBoxName;\n```","code":["_content = getMagazineCargo ammoBoxName;"]},{"text":"```sqf\nhint str getMagazineCargo unitBackpack cursorTarget;\n```","code":["hint str getMagazineCargo unitBackpack cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmoCargo","magazineCargo","addMagazineCargo","addMagazineCargoGlobal","clearMagazineCargo","clearMagazineCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Vehicle Inventory","Introduced with Arma 2: Operation Arrowhead version 1.54","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getMarkerColor","operator":null,"title":"getMarkerColor","type":"command","url":"https://community.bistudio.com/wiki/getMarkerColor","revid":369401,"updated":"2024-09-03T18:43:21Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns marker color for given marker.\n\n> [!NOTE]\n> This command is identical to markerColor.","syntaxes":[{"syntax":"getMarkerColor markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":"marker name","types":["String"],"since":null,"text":"markerName: String - marker name"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerColor \"ColorBlack\";\n_color = getMarkerColor \"MarkerOne\"; // returns \"ColorBlack\"\n```","code":["\"MarkerOne\" setMarkerColor \"ColorBlack\";\n_color = getMarkerColor \"MarkerOne\"; // returns \"ColorBlack\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerColor","setMarkerColorLocal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getMarkerPos","operator":null,"title":"getMarkerPos","type":"command","url":"https://community.bistudio.com/wiki/getMarkerPos","revid":377402,"updated":"2026-01-02T06:44:58Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Returns marker position.","syntaxes":[{"syntax":"getMarkerPos markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"format [x,y,0]","text":"PositionAGL - format [x,y,0]"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}},{"syntax":"getMarkerPos [markerName, preserveElevation]","since":"arma3 1.94","effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"preserveElevation","type":"Boolean","optional":true,"default":"false","description":null,"types":["Boolean"],"since":null,"text":"preserveElevation: Boolean - (Optional, default false)"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"if preserveElevation is true or [x,y,0] if preserveElevation is false","text":"PositionAGL - if *preserveElevation* is true or [x,y,0] if *preserveElevation* is false"},"form":"unary","operator":null,"left":null,"right":{"text":"[markerName, preserveElevation]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mPos1 = getMarkerPos \"markerOne\";\n```","code":["_mPos1 = getMarkerPos \"markerOne\";"]},{"text":"```sqf\n_mPos2 = getMarkerPos [\"markerTwo\", true];\n```","code":["_mPos2 = getMarkerPos [\"markerTwo\", true];"]}],"multiplayer":null,"problems":null,"aliases":["markerPos"],"see_also":["setMarkerPos","setMarkerPosLocal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"getMarkerSize","operator":null,"title":"getMarkerSize","type":"command","url":"https://community.bistudio.com/wiki/getMarkerSize","revid":377676,"updated":"2026-01-02T09:02:39Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the size of the given marker. A getter for setMarkerSize and an alias of markerSize.","syntaxes":[{"syntax":"getMarkerSize markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Array with [a_axis, b_axis]","types":["Array"],"description":"a_axis: Number - 1/2 width of marker - b_axis: Number - 1/2 height of marker","text":"Array with [a_axis, b_axis]\n- a_axis: Number - 1/2 width of marker\n- b_axis: Number - 1/2 height of marker"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerSize [100,200];\n_size = getMarkerSize \"MarkerOne\"; //returns [100,200]\n```","code":["\"MarkerOne\" setMarkerSize [100,200];\n_size = getMarkerSize \"MarkerOne\"; //returns [100,200]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerSize","setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","createMarker","setMarkerText","setMarkerType","setMarkerAlpha"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getMarkerType","operator":null,"title":"getMarkerType","type":"command","url":"https://community.bistudio.com/wiki/getMarkerType","revid":348864,"updated":"2023-11-08T14:39:13Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets type of marker. See CfgMarkers for a list of standard markers.","syntaxes":[{"syntax":"getMarkerType markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"String","types":["String"],"description":"marker class name. See CfgMarkers.","text":"String - marker class name. See CfgMarkers."},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nif (getMarkerType \"Marker1\" == \"\") then { hint \"Marker1 is not an icon!\" };\n```","code":["if (getMarkerType \"Marker1\" == \"\") then { hint \"Marker1 is not an icon!\" };"]}],"multiplayer":null,"problems":null,"aliases":["markerType"],"see_also":["setMarkerType","setMarkerTypeLocal","markerType"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getMass","operator":null,"title":"getMass","type":"command","url":"https://community.bistudio.com/wiki/getMass","revid":373891,"updated":"2025-06-26T11:00:13Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns mass of a PhysX object.","syntaxes":[{"syntax":"getMass object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_mass = getMass _myCar;\n```","code":["_mass = getMass _myCar;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCenterOfMass","setCenterOfMass","setMass","load","weightRTD","getModelInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"getMissionConfig","operator":null,"title":"getMissionConfig","type":"command","url":"https://community.bistudio.com/wiki/getMissionConfig","revid":341696,"updated":"2023-06-18T12:18:00Z","groups":["Config","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Config entry for the given scenario attribute from the 1st tier. The attribute can be config class or config property. If it is defined in multiple places, the command checks them in the following order:\n1. External *Description.ext* file\n1. Eden Editor scenario attribute\nSo if attribute exists in both places, attribute from description.ext is used. Previously, scenario attributes were extracted from *Description.ext* using missionConfigFile. That still works, but it ignores attributes set directly in the editor and it should not be used anymore.","syntaxes":[{"syntax":"getMissionConfig attribute","since":null,"effect":null,"exec":null,"params":[{"name":"attribute","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"attribute: String - attribute name"}],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"unary","operator":null,"left":null,"right":{"text":"attribute","types":["String"]}}],"examples":[{"text":"```sqf\n_header = getMissionConfig \"Header\";\n```\n\nReturns scenario header config. Replaces the previous approach which would scan only the external *Description.ext* file, but ignore the value set in the Eden Editor:\n\n```sqf\n_header = missionConfigFile >> \"Header\"; // Old approach\n```","code":["_header = getMissionConfig \"Header\";","_header = missionConfigFile >> \"Header\"; // Old approach"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMissionConfigValue","missionConfigFile","BIS_fnc_getParamValue","Mission Parameters"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Command Group: Mission Information","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getMissionConfigValue","operator":null,"title":"getMissionConfigValue","type":"command","url":"https://community.bistudio.com/wiki/getMissionConfigValue","revid":352827,"updated":"2024-02-22T21:48:04Z","groups":["Config","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns value of the given scenario attribute from the 1st tier. Since only config properties have values, the attribute should be config property.\nIf it is not found or config class is given, the return is nil. If the attribute defined in multiple places, the command checks them in the following order:\n1. Description.ext entry\n1. Eden Editor scenario attribute\n\nSo if an attribute exists in both places, the Description.ext value is used.\nPreviously, scenario attributes were extracted from Description.ext using missionConfigFile.\nThat still works, but it ignores attributes set directly in the editor and should not be used anymore.\n\n> [!IMPORTANT]\n> This command cannot force return type, it will return the value of the type given in config. Use isEqualType to additionally reaffirm the correct type if necessary to account for human error.","syntaxes":[{"syntax":"getMissionConfigValue attribute","since":null,"effect":null,"exec":null,"params":[{"name":"attribute","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"attribute: String - attribute name"}],"returns":{"type":null,"types":["Number","String","Boolean","Array","nil"],"description":null,"text":"Number, String, Boolean or Array, depending on the attribute value type. Nil when the attribute is undefined."},"form":"unary","operator":null,"left":null,"right":{"text":"attribute","types":["String"]}},{"syntax":"getMissionConfigValue [attribute, defaultValue]","since":null,"effect":null,"exec":null,"params":[{"name":"attribute","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"attribute: String - attribute name"},{"name":"defaultValue","type":"Anything","optional":false,"default":null,"description":"value used when the attribute is undefined","types":["Anything"],"since":null,"text":"defaultValue: Anything - value used when the attribute is undefined"}],"returns":{"type":null,"types":["Number","String","Boolean","Array"],"description":null,"text":"Number, String, Boolean or Array, depending on the attribute value type. Default value when the attribute is undefined."},"form":"unary","operator":null,"left":null,"right":{"text":"[attribute, defaultValue]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _respawnDelay = getMissionConfigValue [\"respawnDelay\", 0];            // returns the real, defined respawn delay value\nprivate _respawnDelay = getNumber (missionConfigFile >> \"respawnDelay\");    // old approach, ignoring the Eden Editor-set value\n```","code":["private _respawnDelay = getMissionConfigValue [\"respawnDelay\", 0];\t\t\t// returns the real, defined respawn delay value\nprivate _respawnDelay = getNumber (missionConfigFile >> \"respawnDelay\");\t// old approach, ignoring the Eden Editor-set value"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMissionConfig","missionConfigFile","BIS_fnc_getParamValue","Mission Parameters"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Command Group: Mission Information","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getMissionDLCs","operator":null,"title":"getMissionDLCs","type":"command","url":"https://community.bistudio.com/wiki/getMissionDLCs","revid":379079,"updated":"2026-09-27T07:33:06Z","groups":["Mission Information","DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of DLCs that are used in the mission.\n\n> [!IMPORTANT]\n> The list is created from units listed in mission.sqm and does **not** detect units later created by scripts.","syntaxes":[{"syntax":"getMissionDLCs","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"list of DLCs detected for the mission","text":"Array of Strings - list of DLCs detected for the mission"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_usedDLCs = getMissionDLCs; // returns e.g [\"Orange\",\"Enoch\",\"Expansion\",\"Heli\",\"Contact\",\"Mark\",\"Argo\",\"Jets\"]\n```","code":["_usedDLCs = getMissionDLCs; // returns e.g [\"Orange\",\"Enoch\",\"Expansion\",\"Heli\",\"Contact\",\"Mark\",\"Argo\",\"Jets\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Command Group: Mission Information","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getMissionLayerEntities","operator":null,"title":"getMissionLayerEntities","type":"command","url":"https://community.bistudio.com/wiki/getMissionLayerEntities","revid":377616,"updated":"2026-01-02T08:51:45Z","groups":["Eden Editor","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Returns all entities within the specific Eden Editor layer and its sub-layers.\nTo be used when the scenario is running, not in the editor workspace.\nUseful to disable/enable whole parts of the scenario if layers are used during mission design.\n\n> [!NOTE]\n> Default layers are not returned.","syntaxes":[{"syntax":"getMissionLayerEntities layerName","since":null,"effect":null,"exec":null,"params":[{"name":"layerName","type":"can be one of:","optional":false,"default":null,"description":"can be one of:\n- String - case-insensitive; layer name in the editor. If multiple layers with the same name are present in the scenario, the first found one is used\n- Number - layer ID in the editor","types":[],"since":null,"text":"layerName: can be one of:\n- String - case-insensitive; layer name in the editor. If multiple layers with the same name are present in the scenario, the first found one is used\n- Number - layer ID in the editor"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array with [objects, markers, Arma 3 v2.14 groups] (or empty array if the layer does not exist)"},"form":"unary","operator":null,"left":null,"right":{"text":"layerName","types":[]}}],"examples":[{"text":"```sqf\nprivate _base = getMissionLayerEntities \"Base\";\n```","code":["private _base = getMissionLayerEntities \"Base\";"]},{"text":"delete all objects within that layer after the player is over 800m away from _someObject:\n\n```sqf\nwaitUntil { sleep 1; (player distance _someObject) > 800 };\nprivate _simpleObjects = (getMissionLayerEntities \"Simple Objects\") select 0;\n{\n    deleteVehicle _x;\n} forEach _simpleObjects;\n```","code":["waitUntil { sleep 1; (player distance _someObject) > 800 };\nprivate _simpleObjects = (getMissionLayerEntities \"Simple Objects\") select 0;\n{\n\tdeleteVehicle _x;\n} forEach _simpleObjects;"]},{"text":"```sqf\nprivate _layer1337Entities = getMissionLayerEntities 1337;\n```","code":["private _layer1337Entities = getMissionLayerEntities 1337;"]},{"text":"```sqf\ngetMissionLayerEntities 42 params [[\"_objects\", []], [\"_markers\", []], [\"_groups\", []]];\n```","code":["getMissionLayerEntities 42 params [[\"_objects\", []], [\"_markers\", []], [\"_groups\", []]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENLayerEntities"],"notes":[{"user":"R3vo","date":"2016-10-26T15:27:00Z","text":"After an object was deleted from a layer, getMissionLayerEntities will return `<NULL-object>` for the deleted object."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Command Group: Mission Information","Introduced with Arma 3 version 1.56","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"getMissionLayers","operator":null,"title":"getMissionLayers","type":"command","url":"https://community.bistudio.com/wiki/getMissionLayers","revid":377088,"updated":"2026-01-01T09:46:21Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all layers created in Eden Editor. Designed to be used during a scenario. Default layers (BLUFOR, OPFOR...) are not returned.","syntaxes":[{"syntax":"getMissionLayers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"names of layers","text":"Array of Strings - names of layers"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ngetMissionLayers; // [\"Electronics\",\"Camp Endurance\",\"UGV Workstation\",\"Comments\",\"Extraction Air\",\"Comments\",\"Extraction Ground\",\"Extraction\",\"test\"]\n```","code":["getMissionLayers; // [\"Electronics\",\"Camp Endurance\",\"UGV Workstation\",\"Comments\",\"Extraction Air\",\"Comments\",\"Extraction Ground\",\"Extraction\",\"test\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMissionLayerEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getMissionOptions","operator":null,"title":"getMissionOptions","type":"command","url":"https://community.bistudio.com/wiki/getMissionOptions","revid":369753,"updated":"2024-10-08T15:08:55Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns various mission options","syntaxes":[{"syntax":"getMissionOptions","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"HashMap","types":["HashMap"],"description":"Containing the names and values of all options (see setMissionOptions)","text":"HashMap - Containing the names and values of all options (see setMissionOptions)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _missionOptions = getMissionOptions;\n```","code":["private _missionOptions = getMissionOptions;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMissionOptions","getResolution","getAudioOptionVolumes","getSubtitleOptions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getMissionPath","operator":null,"title":"getMissionPath","type":"command","url":"https://community.bistudio.com/wiki/getMissionPath","revid":339107,"updated":"2023-04-26T10:54:34Z","groups":["System","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns mission root plus the filename in a form of filepath to be used with commands requiring absolute path such as playSound3D, drawIcon3D, createSimpleObject, etc.\nAny leading \"\\\" in the filename will be stripped as the mission root includes one already.","syntaxes":[{"syntax":"getMissionPath filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"filename: String"}],"returns":{"type":"String","types":["String"],"description":"absolute path","text":"String - absolute path"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\n// returns e.g \"C:\\Users\\Username\\Documents\\Arma 3\\missions\\MissionName.Altis\\icons\\myIcon.paa\"\nprivate _path = getMissionPath \"icons\\myIcon.paa\";\nprivate _path = getMissionPath \"\\icons\\myIcon.paa\"; // leading \\ is also fine\n```","code":["// returns e.g \"C:\\Users\\Username\\Documents\\Arma 3\\missions\\MissionName.Altis\\icons\\myIcon.paa\"\nprivate _path = getMissionPath \"icons\\myIcon.paa\";\nprivate _path = getMissionPath \"\\icons\\myIcon.paa\"; // leading \\ is also fine"]},{"text":"```sqf\n// returns e.g \"C:\\Users\\Username\\Documents\\Arma 3\\missions\\MissionName.Altis\\\" with the trailing \\\nprivate _root = getMissionPath \"\";\n```","code":["// returns e.g \"C:\\Users\\Username\\Documents\\Arma 3\\missions\\MissionName.Altis\\\" with the trailing \\\nprivate _root = getMissionPath \"\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionConfigFile","playSound3D","drawIcon3D","createSimpleObject","Description.ext","playSoundUI"],"notes":[{"user":"Lou Montana","date":"2023-04-18T20:54:40Z","text":"Before the introduction of getMissionPath, absolute mission directory could be obtained as follow in config:\n\n```cpp\n__EXEC(MISSION_DIRECTORY = __FILE__ select [0, count __FILE__ - 15])\n// ...\ntexture = __EVAL(MISSION_DIRECTORY + \"subDirectory\\texture.paa\");\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: System","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"getModelInfo","operator":null,"title":"getModelInfo","type":"command","url":"https://community.bistudio.com/wiki/getModelInfo","revid":352365,"updated":"2024-02-08T14:09:28Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns object's model info. Model path is suitable for use with createSimpleObject command.","syntaxes":[{"syntax":"getModelInfo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array","types":["Array"],"description":"array in format [modelName, modelPath, hasSkeleton, placingPoint, mass] - modelName: String - For example \"car.p3d\" - modelPath: String - Full path to model. For example: \"a3\\data\\models\\car.p3d\" - hasSkeleton: Boolean - Returns whether the model has a skeleton (which usually means it's also animated) - Arma 3 v2.08 placingPoint: Vector3D - Placing point of the model in model coordinates. Placing point is always in format [0,0,z]. - Arma 3 v2.18 mass: Number - Mass defined in the p3d model","text":"Array - array in format [modelName, modelPath, hasSkeleton, placingPoint, mass]\n- modelName: String - For example \"car.p3d\"\n- modelPath: String - Full path to model. For example: \"a3\\data\\models\\car.p3d\"\n- hasSkeleton: Boolean - Returns whether the model has a skeleton (which usually means it's also animated)\n- Arma 3 v2.08 placingPoint: Vector3D - Placing point of the model in model coordinates. Placing point is always in format [0,0,z].\n- Arma 3 v2.18 mass: Number - Mass defined in the p3d model"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_modelInfo = getModelInfo player; // [\"b_soldier_03.p3d\", \"a3\\characters_f\\blufor\\b_soldier_03.p3d\", true, [0,0,0]]\n```","code":["_modelInfo = getModelInfo player; // [\"b_soldier_03.p3d\", \"a3\\characters_f\\blufor\\b_soldier_03.p3d\", true, [0,0,0]]"]},{"text":"```sqf\n_modelInfo = getModelInfo cursorObject;\n```","code":["_modelInfo = getModelInfo cursorObject;"]},{"text":"Get Z ASL using placing point:\n\n```sqf\n_zASL = (heli modelToWorldWorld (getModelInfo heli select 3)) select 2;\n```","code":["_zASL = (heli modelToWorldWorld (getModelInfo heli select 3)) select 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cursorObject","cursorTarget","createSimpleObject","getObjectType","getObjectTextures","objectParent","setVelocityTransformation","getUnitFreefallInfo","getEntityInfo","getMass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"getMousePosition","operator":null,"title":"getMousePosition","type":"command","url":"https://community.bistudio.com/wiki/getMousePosition","revid":378523,"updated":"2026-05-04T01:55:30Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns mouse position in UI coordinates.","syntaxes":[{"syntax":"getMousePosition","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Position2D","types":["Position2D"],"description":"x and y UI coordinates of the mouse position","text":"Position2D - x and y UI coordinates of the mouse position"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ngetMousePosition params [\"_mouseX\", \"_mouseY\"];\n```","code":["getMousePosition params [\"_mouseX\", \"_mouseY\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMousePosition","ctrlSetMousePosition","ctrlMousePosition","ctrlMapCursor","reversedMouseY"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"getMusicPlayedTime","operator":null,"title":"getMusicPlayedTime","type":"command","url":"https://community.bistudio.com/wiki/getMusicPlayedTime","revid":309232,"updated":"2022-05-04T10:20:06Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns elapsed time in seconds for currently playing music track.","syntaxes":[{"syntax":"getMusicPlayedTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nplayMusic [\"LeadTrack06_F_Tank\", 0];\nonEachFrame {hintSilent str getMusicPlayedTime};\n```","code":["playMusic [\"LeadTrack06_F_Tank\", 0];\nonEachFrame {hintSilent str getMusicPlayedTime};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMusicEventHandler","playMusic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.78","Scripting Commands"]},{"name":"getNumber","operator":null,"title":"getNumber","type":"command","url":"https://community.bistudio.com/wiki/getNumber","revid":322306,"updated":"2022-05-30T13:22:38Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Extract number from config entry.","syntaxes":[{"syntax":"getNumber config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_value = getNumber (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"maxSpeed\");\n```","code":["_value = getNumber (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"maxSpeed\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getText","inheritsFrom","isArray","isClass","isNumber","isText","select"],"notes":[{"user":"Donnervogel","date":"2007-03-03T04:45:00Z","text":"Use getNumber to get boolean values from a config entry. 1 equals true, 0 equals false."},{"user":"Loki","date":"2011-09-13T00:44:00Z","text":"With an not existing entry, getNumber returns 0."},{"user":"ffur2007slx2_5","date":"2014-03-28T07:53:00Z","text":"(Arma 3 1.14), It's recommended to use BIS_fnc_getCfgData or BIS_fnc_returnConfigEntry to get variable cfg data rather than conditioning via isNumber, isText, isArray, getNumber, getText and getArray combination.\n\nTraditional workaround:\n\n```sqf\nprivate _cfg = configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\";\nswitch (true) do\n{\n    case (isNumber _cfg):    { getNumber _cfg };\n    case (isText _cfg):        { getText _cfg };\n    case (isArray _cfg):    { getArray _cfg };\n    default                    { nil };\n};\n```\n\n**Recommended workaround:**\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgData;\n```\n\nTo return default value once entry was not found, we can use BIS_fnc_returnConfigEntry instead of BIS_fnc_getCfgData.\n\n```sqf\n[(configFile >> \"CannonFire\" >> \"LightExp\"),\"lifeTime\",0] call BIS_fnc_returnConfigEntry; // 0.5\n```\n\nTo compose collected Number into Array, use BIS_fnc_getCfgDataArray instead.\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgDataArray;\n```\n\nTo retype collected Number into Boolean, use BIS_fnc_getCfgDataBool. Anything bigger than 0 is true, otherwise false.\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgDataBool;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getObjectArgument","operator":null,"title":"getObjectArgument","type":"command","url":"https://community.bistudio.com/wiki/getObjectArgument","revid":376411,"updated":"2025-10-11T01:03:00Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return name of object argument in mission editor.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map getObjectArgument [object, argument]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"argument","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"argument: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object, argument]","types":["Array"]}}],"examples":[{"text":"```sqf\n// returns string \"[1009.0351, 1319.4928]\"\n(findDisplay 128 displayCtrl 51) getObjectArgument [\"_unit_1\", \"POSITION\"];\n\n// returns array [1009.0351, 1319.4928]\n(findDisplay 128 displayCtrl 51) evalObjectArgument [\"_unit_1\", \"POSITION\"];\n```","code":["// returns string \"[1009.0351, 1319.4928]\"\n(findDisplay 128 displayCtrl 51) getObjectArgument [\"_unit_1\", \"POSITION\"];\n\n// returns array [1009.0351, 1319.4928]\n(findDisplay 128 displayCtrl 51) evalObjectArgument [\"_unit_1\", \"POSITION\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getObjectChildren","operator":null,"title":"getObjectChildren","type":"command","url":"https://community.bistudio.com/wiki/getObjectChildren","revid":363237,"updated":"2024-03-26T10:51:15Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of all the children of the specified object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map getObjectChildren object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getObjectDLC","operator":null,"title":"getObjectDLC","type":"command","url":"https://community.bistudio.com/wiki/getObjectDLC","revid":369364,"updated":"2024-09-03T18:43:08Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.36"}],"since":{"game":"arma3","name":"Arma 3","version":"1.36"},"arma3_since":"1.36","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns appID of the DLC the object belongs to or nil if object is vanilla.","syntaxes":[{"syntax":"getObjectDLC obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Number (or Nothing if vanilla item)","types":["Number","Nothing"],"description":null,"text":"Number (or Nothing if vanilla item)"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\n_appID = getObjectDLC cursorTarget;\nif (!isNil \"_appID\") then {\n    hint format [\"This object belongs to DLC with id: %1\", _appID];\n} else {\n    hint \"This object is vanilla\";\n};\n```","code":["_appID = getObjectDLC cursorTarget;\nif (!isNil \"_appID\") then {\n\thint format [\"This object belongs to DLC with id: %1\", _appID];\n} else {\n\thint \"This object is vanilla\";\n};"]},{"text":"```sqf\n_akm = createSimpleObject [\"A3\\Weapons_F_Exp\\Rifles\\AKM\\AKM_F.p3d\",getPosASL player];\ngetObjectDLC _akm;    // 395180\n```","code":["_akm = createSimpleObject [\"A3\\Weapons_F_Exp\\Rifles\\AKM\\AKM_F.p3d\",getPosASL player];\ngetObjectDLC _akm;\t// 395180"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getPersonUsedDLCs","getMissionDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.36","Scripting Commands"]},{"name":"getObjectFOV","operator":null,"title":"getObjectFOV","type":"command","url":"https://community.bistudio.com/wiki/getObjectFOV","revid":309149,"updated":"2022-05-03T14:11:55Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Field of View of the given object in radians. Static objects return default value, which is 1.\nFOV of objNull is 0.\nObject FOV is indirectly connected with optics magnification or player view zoom, the narrower the angle the greater the zoom.\n\n> [!NOTE]\n> The FOV returned by this command doesn't change if user has custom FOV set in profile. Use it in combination with getResolution to adjust for the difference if required.","syntaxes":[{"syntax":"getObjectFOV object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"for units it queries unit weapon optics/zoom, for vehicles - vehicle optics/zoom","types":["Object"],"since":null,"text":"object: Object - for units it queries unit weapon optics/zoom, for vehicles - vehicle optics/zoom"}],"returns":{"type":"Number","types":["Number"],"description":"FOV in radians","text":"Number - FOV in radians"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _objFOV = getObjectFOV player;\n```","code":["private _objFOV = getObjectFOV player;"]},{"text":"```sqf\nprivate _objFOVinDegrees = deg getObjectFOV cursorObject;\n```","code":["private _objFOVinDegrees = deg getObjectFOV cursorObject;"]},{"text":"Perceived distance to an object:\n\n```sqf\nprivate _vdist = (player distance _obj) * (getObjectFOV player / 0.75);\n```","code":["private _vdist = (player distance _obj) * (getObjectFOV player / 0.75);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectType","getResolution"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"getObjectID","operator":null,"title":"getObjectID","type":"command","url":"https://community.bistudio.com/wiki/getObjectID","revid":365078,"updated":"2024-07-19T18:20:06Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Visitor ID of the given object. Visitor IDs of static map objects can change if map is in development and updated with new static objects.","syntaxes":[{"syntax":"getObjectID object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"String","types":["String"],"description":"Visitor ID","text":"String - Visitor ID"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetObjectID _tree;\n```","code":["getObjectID _tree;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUsers","getUserInfo","createMarker","createMarkerLocal","getPlayerID","nearestObject"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getObjectMaterials","operator":null,"title":"getObjectMaterials","type":"command","url":"https://community.bistudio.com/wiki/getObjectMaterials","revid":370528,"updated":"2025-01-01T23:24:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets all custom materials associated with the object.","syntaxes":[{"syntax":"getObjectMaterials obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of materials","text":"Array of Strings - array of materials"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}},{"syntax":"obj getObjectMaterials sels","since":"Arma3 2.20","effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"entity","types":["Object"],"since":null,"text":"obj: Object - entity"},{"name":"sels","type":"Array","optional":false,"default":null,"description":"array of index(es) and/or selection(s). If array is empty [] - default object materials are returned (see example 3)","types":["Array"],"since":null,"text":"sels: Array - array of index(es) and/or selection(s). If array is empty [] - default object materials are returned (see example 3)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of materials in order of 'sels'. Non existing materials filled with nils.","text":"Array of Strings - array of materials in order of 'sels'. Non existing materials filled with nils."},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"sels","types":["Array"]}}],"examples":[{"text":"```sqf\n_materials = getObjectMaterials car;\n```","code":["_materials = getObjectMaterials car;"]},{"text":"```sqf\nplayer setObjectMaterial [\"insignia\", \"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\nplayer getObjectMaterials [\"insignia\", 0, 1, player, \"dskjhkjhsad\"]; \n// [\"a3\\structures_f\\data\\windows\\window_set.rvmat\",\"\",\"a3\\structures_f\\data\\windows\\window_set.rvmat\",<null>,<null>]\n```","code":["player setObjectMaterial [\"insignia\", \"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\nplayer getObjectMaterials [\"insignia\", 0, 1, player, \"dskjhkjhsad\"]; \n// [\"a3\\structures_f\\data\\windows\\window_set.rvmat\",\"\",\"a3\\structures_f\\data\\windows\\window_set.rvmat\",<null>,<null>]"]},{"text":"```sqf\nplayer setObjectMaterial [0, \"a3\\structures_f\\data\\windows\\window_set.rvmat\"];\ngetObjectMaterials player; // [\"a3\\structures_f\\data\\windows\\window_set.rvmat\",\"\"]\nplayer getObjectMaterials []; // [\"\",\"\"]\n```","code":["player setObjectMaterial [0, \"a3\\structures_f\\data\\windows\\window_set.rvmat\"];\ngetObjectMaterials player; // [\"a3\\structures_f\\data\\windows\\window_set.rvmat\",\"\"]\nplayer getObjectMaterials []; // [\"\",\"\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectMaterial","setObjectTextureGlobal","getObjectTextures","setObjectTexture","setObjectMaterialGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"getObjectProxy","operator":null,"title":"getObjectProxy","type":"command","url":"https://community.bistudio.com/wiki/getObjectProxy","revid":369337,"updated":"2024-09-03T18:43:00Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the proxy object associated with the given editor object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map getObjectProxy object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"```sqf\n(findDisplay 128 displayCtrl 51) getObjectProxy \"_unit_1\"\n// returns the object 'B 1-1-A:1 (Sean Johnson)'\n```","code":["(findDisplay 128 displayCtrl 51) getObjectProxy \"_unit_1\"\n// returns the object 'B 1-1-A:1 (Sean Johnson)'"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectProxy"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getObjectScale","operator":null,"title":"getObjectScale","type":"command","url":"https://community.bistudio.com/wiki/getObjectScale","revid":364985,"updated":"2024-07-04T19:58:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the render scale of an object relative to the original model.","syntaxes":[{"syntax":"getObjectScale object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to return scale of. Can also be a terrain object.","types":["Object"],"since":null,"text":"object: Object - object to return scale of. Can also be a terrain object."}],"returns":{"type":"Number","types":["Number"],"description":"scale relative to the original model","text":"Number - scale relative to the original model"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _objectScale = getObjectScale MyObject;\n\nif (_objectScale == 1) exitWith { systemChat \"Original scale\"; };\n\nif (_objectScale > 1) then\n{\n    systemChat \"Scaled up\";\n}\nelse\n{\n    systemChat \"Scaled down\";\n};\n```","code":["private _objectScale = getObjectScale MyObject;\n\nif (_objectScale == 1) exitWith { systemChat \"Original scale\"; };\n\nif (_objectScale > 1) then\n{\n\tsystemChat \"Scaled up\";\n}\nelse\n{\n\tsystemChat \"Scaled down\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectScale"],"notes":[{"user":"Sa-Matra","date":"2024-06-10T12:26:52Z","text":"Some objects can be scaled by XYZ individually by the engine. Rope segments are one example, they only scale by Z and this command returns average of all dimensions giving no real picture of the scale. You can get real scale of each dimension with:\n\n```sqf\n[vectorMagnitude vectorSideVisual _seg, vectorMagnitude vectorDirVisual _seg, vectorMagnitude vectorUpVisual _seg]\n```\n\nfor rope segment it will be something like `[1,1,1.54066]`"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"getObjectTextures","operator":null,"title":"getObjectTextures","type":"command","url":"https://community.bistudio.com/wiki/getObjectTextures","revid":370025,"updated":"2024-10-27T20:33:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets all custom textures (hiddenSelectionsTextures) associated with the object. \n\n> [!IMPORTANT]\n> Prior to Arma 3 v2.20 it will return an empty Array when executed on simple objects.","syntaxes":[{"syntax":"getObjectTextures obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of textures","text":"Array of Strings - array of textures"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}},{"syntax":"obj getObjectTextures sels","since":"Arma3 2.20","effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"entity","types":["Object"],"since":null,"text":"obj: Object - entity"},{"name":"sels","type":"Array","optional":false,"default":null,"description":"array of index(es) and/or selection(s). If array is empty [] - default object textures are returned (see example 3)","types":["Array"],"since":null,"text":"sels: Array - array of index(es) and/or selection(s). If array is empty [] - default object textures are returned (see example 3)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of textures in order of 'sels'. Non existing textures filled with nils.","text":"Array of Strings - array of textures in order of 'sels'. Non existing textures filled with nils."},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"sels","types":["Array"]}}],"examples":[{"text":"```sqf\n_textures = getObjectTextures player;\n```","code":["_textures = getObjectTextures player;"]},{"text":"```sqf\nplayer setObjectTexture [\"clan\", \"\\a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\"];\nplayer getObjectTextures [\"clan\", 1, 0, player, \"dskjhkjhsad\"]; \n// [\"a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\",\"\",\"a3\\characters_f\\blufor\\data\\clothing1_co.paa\",<null>,<null>]\n```","code":["player setObjectTexture [\"clan\", \"\\a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\"];\nplayer getObjectTextures [\"clan\", 1, 0, player, \"dskjhkjhsad\"]; \n// [\"a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\",\"\",\"a3\\characters_f\\blufor\\data\\clothing1_co.paa\",<null>,<null>]"]},{"text":"```sqf\nplayer setObjectTexture [0, \"\"];\nplayer getObjectTextures []; // [\"a3\\characters_f\\blufor\\data\\clothing1_co.paa\",\"\"]\n```","code":["player setObjectTexture [0, \"\"];\nplayer getObjectTextures []; // [\"a3\\characters_f\\blufor\\data\\clothing1_co.paa\",\"\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectTexture","setObjectTextureGlobal","getObjectMaterials","setObjectMaterial","setObjectMaterialGlobal","getModelInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.38","Scripting Commands"]},{"name":"getObjectType","operator":null,"title":"getObjectType","type":"command","url":"https://community.bistudio.com/wiki/getObjectType","revid":348931,"updated":"2023-11-08T14:44:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns object type as a number:\n- 1 - Primary - Normal object placed in Visitor, part of landscape\n- 2 - Network - Road placed in Visitor, part of landscape\n- 4 - Temporary - Temporary object (like tracks)\n- 8 - TypeVehicle - Some entity added by game\n- 16 - TypeTempVehicle - Temporary entity\n- 32 - LandDecal - Land decal","syntaxes":[{"syntax":"getObjectType object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":"object type","text":"Number - object type"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_objType = getObjectType player;\n```","code":["_objType = getObjectType player;"]},{"text":"```sqf\n_objType = getObjectType cursorObject;\n```","code":["_objType = getObjectType cursorObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allObjects","getObjectFOV","cursorObject","cursorTarget","createSimpleObject","allMissionObjects","setObjectViewDistance","getObjectViewDistance","objectParent","object"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"getObjectViewDistance","operator":null,"title":"getObjectViewDistance","type":"command","url":"https://community.bistudio.com/wiki/getObjectViewDistance","revid":310797,"updated":"2022-05-07T20:21:54Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the values of rendering distances of objects and shadows.","syntaxes":[{"syntax":"getObjectViewDistance","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"in format [objectDistance, shadowDistance]","text":"Array - in format [objectDistance, shadowDistance]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_arr = getObjectViewDistance;\n```","code":["_arr = getObjectViewDistance;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectViewDistance","setViewDistance","viewDistance","setDetailMapBlendPars","setTerrainGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"getOpticsMode","operator":null,"title":"getOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/getOpticsMode","revid":348464,"updated":"2023-11-08T13:00:19Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the class name of the current optic mode of the current weapon.","syntaxes":[{"syntax":"unit getOpticsMode slot","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"slot","type":"Number","optional":false,"default":null,"description":"can be one of:\n- 0 - Current weapon\n- 1 - Primary weapon\n- 2 - Secondary weapon\n- 3 - Handgun","types":["Number"],"since":null,"text":"slot: Number - can be one of:\n- 0 - Current weapon\n- 1 - Primary weapon\n- 2 - Secondary weapon\n- 3 - Handgun"}],"returns":{"type":"String","types":["String"],"description":"class name of the current optic mode of the current weapon","text":"String - class name of the current optic mode of the current weapon"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"slot","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer getOpticsMode 0; // get current weapon's optic mode\nplayer getOpticsMode 1; // get primary weapon's optic mode\nplayer getOpticsMode 2; // get launcher's optic mode\nplayer getOpticsMode 3; // get handgun's optic mode\n```","code":["player getOpticsMode 0; // get current weapon's optic mode\nplayer getOpticsMode 1; // get primary weapon's optic mode\nplayer getOpticsMode 2; // get launcher's optic mode\nplayer getOpticsMode 3; // get handgun's optic mode"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getOrDefault","operator":null,"title":"getOrDefault","type":"command","url":"https://community.bistudio.com/wiki/getOrDefault","revid":348340,"updated":"2023-11-08T12:59:48Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieves a value out of a HashMap after looking it up by its key. When the HashMap doesn't contain the key, the default value is returned","syntaxes":[{"syntax":"hashMap getOrDefault [key, defaultValue, setDefault]","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":"case sensitive key","types":["HashMapKey"],"since":null,"text":"key: HashMapKey - case sensitive key"},{"name":"defaultValue","type":"Anything","optional":true,"default":"nil","description":null,"types":["Anything"],"since":null,"text":"defaultValue: Anything - (Optional, default nil)"},{"name":"setDefault","type":"Boolean","optional":true,"default":"false","description":"if set to true and value does not exist in provided hash map, *defaultValue* will be added to the hash map","types":["Boolean"],"since":"arma3 2.04","text":"setDefault: Boolean - (Optional, default false) if set to true and value does not exist in provided hash map, *defaultValue* will be added to the hash map"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"[key, defaultValue, setDefault]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _myValue = _myHashMap getOrDefault [\"a\", \"Not Found!\"];\n```","code":["private _myValue = _myHashMap getOrDefault [\"a\", \"Not Found!\"];"]},{"text":"```sqf\nprivate _myValue = _hashMap getOrDefault [\"a\", \"Not Found!\", true]; // will add default value to the hash map if it does not exist\n```","code":["private _myValue = _hashMap getOrDefault [\"a\", \"Not Found!\", true]; // will add default value to the hash map if it does not exist"]},{"text":"```sqf\nprivate _array = _hashmap getOrDefault [_key, [], true]; // a new array will be created if it doesn't exist\n_array pushBack _item; // _item will be added to the array (the one in the hashmap is updated by reference)\n```","code":["private _array = _hashmap getOrDefault [_key, [], true]; // a new array will be created if it doesn't exist\n_array pushBack _item; // _item will be added to the array (the one in the hashmap is updated by reference)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getOrDefaultCall","HashMap","get"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"getOrDefaultCall","operator":null,"title":"getOrDefaultCall","type":"command","url":"https://community.bistudio.com/wiki/getOrDefaultCall","revid":378259,"updated":"2026-03-26T00:21:49Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieves a value from the HashMap for the given 'key', executes given 'code' if key was not found and returns result.\nAdditionally sets key to the code result value if *set* is true.","syntaxes":[{"syntax":"hashMap getOrDefaultCall [key, code, set]","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":"case-sensitive key","types":["HashMapKey"],"since":null,"text":"key: HashMapKey - case-sensitive key"},{"name":"code","type":"Code","optional":true,"default":"nil","description":"code to execute if the key does not exist","types":["Code"],"since":null,"text":"code: Code - (Optional, default nil) code to execute if the key does not exist"},{"name":"set","type":"Boolean","optional":true,"default":"false","description":"if true and value does not exist in the provided hash map, the result of the *code* execution is added to the hash map","types":["Boolean"],"since":null,"text":"set: Boolean - (Optional, default false) if true and value does not exist in the provided hash map, the result of the *code* execution is added to the hash map"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"[key, code, set]","types":["Array"]}}],"examples":[{"text":"```sqf\n_hashmap getOrDefaultCall [123, { systemChat \"The key 123 does not exist and will be created and assigned 345\"; 345 }, true];\n```","code":["_hashmap getOrDefaultCall [123, { systemChat \"The key 123 does not exist and will be created and assigned 345\"; 345 }, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getOrDefault","HashMap","get"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getOxygenRemaining","operator":null,"title":"getOxygenRemaining","type":"command","url":"https://community.bistudio.com/wiki/getOxygenRemaining","revid":341133,"updated":"2023-05-13T22:12:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns amount of remaining oxygen.","syntaxes":[{"syntax":"getOxygenRemaining unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_oxygen = getOxygenRemaining player;\n```","code":["_oxygen = getOxygenRemaining player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setOxygenRemaining"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getPersonUsedDLCs","operator":null,"title":"getPersonUsedDLCs","type":"command","url":"https://community.bistudio.com/wiki/getPersonUsedDLCs","revid":352086,"updated":"2024-02-01T23:24:46Z","groups":["Broken Commands","DLC"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.36"}],"since":{"game":"arma3","name":"Arma 3","version":"1.36"},"arma3_since":"1.36","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a list of all DLCs objects the unit is currently using. For example if a unit is inside a vehicle from DLC, it will return the code of that DLC.","syntaxes":[{"syntax":"getPersonUsedDLCs unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_objects = getPersonUsedDLCs player;\n```","code":["_objects = getPersonUsedDLCs player;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command does not work on a dedicated server.","aliases":[],"see_also":["getDLCs","getObjectDLC","getMissionDLCs","getDLCAssetsUsageByName","getDLCAssetsUsage","getAssetDLCInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: DLC","Introduced with Arma 3 version 1.36","Scripting Commands"]},{"name":"getPhysicsCollisionFlag","operator":null,"title":"getPhysicsCollisionFlag","type":"command","url":"https://community.bistudio.com/wiki/getPhysicsCollisionFlag","revid":373902,"updated":"2025-06-26T12:11:11Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the currently set physics collision flags.","syntaxes":[{"syntax":"getPhysicsCollisionFlag object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array of Booleans","types":["Array","Boolean"],"description":"array of collision flags (only one value is returned for now)","text":"Array of Booleans - array of collision flags (only one value is returned for now)"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideObject","isObjectHidden","setPhysicsCollisionFlag","disableCollisionWith","enableCollisionWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getPilotCameraDirection","operator":null,"title":"getPilotCameraDirection","type":"command","url":"https://community.bistudio.com/wiki/getPilotCameraDirection","revid":377256,"updated":"2026-01-02T06:32:48Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns model space vector of the object airplane or helicopter pilotCamera .","syntaxes":[{"syntax":"getPilotCameraDirection object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"relative to the model centre (In a similar fashion to PositionRelative). Returns [0,0,0] if object has no pilotCamera.","text":"Vector3D - relative to the model centre (In a similar fashion to PositionRelative). Returns [0,0,0] if object has no pilotCamera."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_pilotCamVector = getPilotCameraDirection vehicle player;\n```","code":["_pilotCamVector = getPilotCameraDirection vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getPilotCameraOpticsMode","operator":null,"title":"getPilotCameraOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/getPilotCameraOpticsMode","revid":349193,"updated":"2023-11-08T14:50:40Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the optics mode index (zoom) for the pilotCamera","syntaxes":[{"syntax":"getPilotCameraOpticsMode object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":"the index of the optic mode","text":"Number - the index of the optic mode"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetPilotCameraOpticsMode vehicle player\n```","code":["getPilotCameraOpticsMode vehicle player"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPilotCameraOpticsMode","hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget","getPilotCameraTarget","getTurretOpticsMode","setTurretOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"getPilotCameraPosition","operator":null,"title":"getPilotCameraPosition","type":"command","url":"https://community.bistudio.com/wiki/getPilotCameraPosition","revid":377379,"updated":"2026-01-02T06:43:43Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns model space coordinates of the object airplane or helicopter pilotCamera.","syntaxes":[{"syntax":"getPilotCameraPosition object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"offset relative to the model centre. Returns [0,0,0] if object has no pilotCamera.","text":"PositionRelative - offset relative to the model centre. Returns [0,0,0] if object has no pilotCamera."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_pilotCamPos = getPilotCameraPosition vehicle player;\n```","code":["_pilotCamPos = getPilotCameraPosition vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraDirection","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getPilotCameraRotation","operator":null,"title":"getPilotCameraRotation","type":"command","url":"https://community.bistudio.com/wiki/getPilotCameraRotation","revid":348962,"updated":"2023-11-08T14:45:40Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns rotation (relative to the centered camera position) of the object airplane or helicopter pilotCamera .","syntaxes":[{"syntax":"getPilotCameraRotation object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array of Numbers in format [yaw (turn), pitch (elevation)]","types":["Array","Number"],"description":"positive values are left yaw and down pitch from the center. Returns [0,0] when camera is centered but also if object has no pilotCamera.","text":"Array of Numbers in format [yaw (turn), pitch (elevation)] - positive values are left yaw and down pitch from the center. Returns [0,0] when camera is centered but also if object has no pilotCamera."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_pilotCamRot = getPilotCameraRotation vehicle player;\n```","code":["_pilotCamRot = getPilotCameraRotation vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getPilotCameraTarget","operator":null,"title":"getPilotCameraTarget","type":"command","url":"https://community.bistudio.com/wiki/getPilotCameraTarget","revid":378360,"updated":"2026-04-03T16:01:12Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the target of the object airplane or helicopter pilotCamera tracking. Returns `[false, [0,0,0], objNull]` if camera is not in a tracking mode or if object has no pilotCamera.","syntaxes":[{"syntax":"getPilotCameraTarget object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array with [isTracking, targetPosition, targetObject]","types":["Array"],"description":"isTracking: Boolean - returns whether the camera is in a tracking mode - targetPosition: PositionASL - returns the position of the tracked area or object - targetObject: Object - returns the tracked object, objNull if camera is only tracking an area","text":"Array with [isTracking, targetPosition, targetObject]\n- isTracking: Boolean - returns whether the camera is in a tracking mode\n- targetPosition: PositionASL - returns the position of the tracked area or object\n- targetObject: Object - returns the tracked object, objNull if camera is only tracking an area"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\ngetPilotCameraTarget vehicle player params [\"_pilotCamTracking\", \"_pilotCamTargetPos\", \"_pilotCamTarget\"];\n```","code":["getPilotCameraTarget vehicle player params [\"_pilotCamTracking\", \"_pilotCamTargetPos\", \"_pilotCamTarget\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getPiPViewDistance","operator":null,"title":"getPiPViewDistance","type":"command","url":"https://community.bistudio.com/wiki/getPiPViewDistance","revid":309130,"updated":"2022-05-03T11:41:51Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Get the set PiP (Picture-in-Picture) view distance (that can be set by setPiPViewDistance).","syntaxes":[{"syntax":"getPiPViewDistance","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _pipViewDistance = getPiPViewDistance;\n```","code":["private _pipViewDistance = getPiPViewDistance;"]},{"text":"```sqf\nprivate _pipViewDistanceRatio = getPiPViewDistance / viewDistance;\n```","code":["private _pipViewDistanceRatio = getPiPViewDistance / viewDistance;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPiPViewDistance","setViewDistance","setObjectViewDistance","viewDistance","getObjectViewDistance"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"getPlateNumber","operator":null,"title":"getPlateNumber","type":"command","url":"https://community.bistudio.com/wiki/getPlateNumber","revid":309220,"updated":"2022-05-03T22:51:33Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the license plates from any vehicle which has plates configured.","syntaxes":[{"syntax":"getPlateNumber vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getPlateNumber vehicle player != \"H4X0RZ\") then { hint \"u no 1337 bro\" };\n```","code":["if (getPlateNumber vehicle player != \"H4X0RZ\") then { hint \"u no 1337 bro\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPlateNumber"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.82","Scripting Commands"]},{"name":"getPlayerChannel","operator":null,"title":"getPlayerChannel","type":"command","url":"https://community.bistudio.com/wiki/getPlayerChannel","revid":376827,"updated":"2025-11-23T01:44:27Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns channel number for given player, **provided that player is SPEAKING**, otherwise -1. Having mic on is not enough, player has to make a sound. There are several limitations to this command:\n- It does not work on dedicated server, the return is always -1, only client can detect other client talking.\n- Prior to Arma 3 v2.01.146856 did not detect when someone talked on direct chat at all anywhere.\n- The client on which command is executed has to able to receive transmission before the transmission channel can be detected. For example if a player is not in the same group as a speaker and the speaker speaks on Group Channel, the player cannot hear the speaker and therefore cannot detect what channel the speaker is on.\nIn short, this command mimics the speaking icon from the UI. Correspondence between channel and number:\n\n| channel ID number correspondence |  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| N/A | Global | Side | Command | Group | Vehicle | Direct | Custom1 | .. | Custom10 | Arma 3 v2.22 Custom11 | .. | Custom50 |\n| -1 | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 15 | 26 | 65 |  |  |","syntaxes":[{"syntax":"getPlayerChannel player","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"}],"returns":{"type":"Number","types":["Number"],"description":"channel ID","text":"Number - channel ID"},"form":"unary","operator":null,"left":null,"right":{"text":"player","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _channelID = getPlayerChannel player;\n```","code":["private _channelID = getPlayerChannel player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCurrentChannel","currentChannel","enableChannel","channelEnabled","radioChannelCreate","radioChannelInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"getPlayerID","operator":null,"title":"getPlayerID","type":"command","url":"https://community.bistudio.com/wiki/getPlayerID","revid":310153,"updated":"2022-05-05T12:55:18Z","groups":["Multiplayer","Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns user DirectPlay ID, which can be used with getUserInfo, and is found in allMapMarkers results and in some mission event handlers such as PlayerConnected.","syntaxes":[{"syntax":"getPlayerID unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"\"-1\" if object is not a player","text":"String - \"-1\" if object is not a player"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ngetPlayerID player;\n```","code":["getPlayerID player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUsers","getUserInfo","createMarker","createMarkerLocal","getObjectID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Command Group: Multiplayer","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"getPlayerScores","operator":null,"title":"getPlayerScores","type":"command","url":"https://community.bistudio.com/wiki/getPlayerScores","revid":376996,"updated":"2026-01-01T08:04:57Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the unit's table of scores (infantry kills, soft vehicle kills, armor kills, air kills, deaths, total score) **in multiplayer** or an empty array in singleplayer.\n\n> [!IMPORTANT]\n> This command does not work (returns empty array) if the unit's side has been changed (e.g `[player] joinSilent createGroup east`).","syntaxes":[{"syntax":"getPlayerScores unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Array with [killsInfantry, killsSoft, killsArmor, killsAir, score]","types":["Array"],"description":"killsInfantry: Number - number of infantry units killed - killsSoft: Number - number of soft vehicles killed - killsArmor: Number - number of armored vehicles killed - killsAir: Number - number of air vehicles killed - score: Number - total score","text":"Array with [killsInfantry, killsSoft, killsArmor, killsAir, score]\n- killsInfantry: Number - number of infantry units killed\n- killsSoft: Number - number of soft vehicles killed\n- killsArmor: Number - number of armored vehicles killed\n- killsAir: Number - number of air vehicles killed\n- score: Number - total score"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\ngetPlayerScores BIS_player1;    // e.g [4, 0, 3, 1, 2, 16]\n                                // or in SP: []\n```","code":["getPlayerScores BIS_player1;\t// e.g [4, 0, 3, 1, 2, 16]\n\t\t\t\t\t\t\t\t// or in SP: []"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["score","addScore","scoreSide","addScoreSide","addPlayerScores"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getPlayerUID","operator":null,"title":"getPlayerUID","type":"command","url":"https://community.bistudio.com/wiki/getPlayerUID","revid":353295,"updated":"2024-03-15T17:11:43Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.02"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.02"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return a UniqueID of the given unit (player).\n\n> [!NOTE]\n> **Arma 3:** The returned string is the player's steamID64: `private _steamProfileUrl = \"http://steamcommunity.com/profiles/\" + (getPlayerUID player);`\n\n> [!IMPORTANT]\n> Prior to Arma 2: Operation Arrowhead v1.60, the result always consisted of a stringified number (see getPlayerUIDOld), but always had to be considered and processed as a String. Converting it to a Number could cause precision problems, as Number cannot accurately represent integers above 16777216 (224). Moreover, games since Arma 2: Operation Arrowhead v1.61 provide a value that is not all-numeric.\n\n> [!NOTE]\n> Prior to Arma 3 v2.02, in some cases the identity of certain player units could fail to propagate to other clients and the server, which caused isPlayer and getPlayerUID to incorrectly return `false` and `\"\"` respectively, where the affected units were not local. See [this bug report (GitHub)](https://github.com/michail-nikolaev/task-force-arma-3-radio/issues/1096) for more info. This was supposedly fixed, but you should remain vigilant toward false negatives nonetheless.","syntaxes":[{"syntax":"getPlayerUID unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"can be \"_SP_AI_\" or \"_SP_PLAYER_\" in SP, \"\" or UID in MP - The unique ID may be up to 100 characters long and may contain numbers, uppercase letters and underscores - The value can be used to construct a valid variable name by appending to another valid variable name, e.g `missionNamespace setVariable [\"TAG_player\" + _uid, _unit];`","text":"String - can be \"_SP_AI_\" or \"_SP_PLAYER_\" in SP, \"\" or UID in MP\n- The unique ID may be up to 100 characters long and may contain numbers, uppercase letters and underscores\n- The value can be used to construct a valid variable name by appending to another valid variable name, e.g `missionNamespace setVariable [\"TAG_player\" + _uid, _unit];`"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _uid = getPlayerUID player;\n```","code":["private _uid = getPlayerUID player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_getUnitByUID","getPlayerUIDOld","getClientState","getClientStateNumber"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.02","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getPlayerVoNVolume","operator":null,"title":"getPlayerVoNVolume","type":"command","url":"https://community.bistudio.com/wiki/getPlayerVoNVolume","revid":309253,"updated":"2022-05-04T10:54:22Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets provided player's Voice over Network (VoN) volume.","syntaxes":[{"syntax":"getPlayerVoNVolume unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the other player's unit","types":["Object"],"since":null,"text":"unit: Object - the other player's unit"}],"returns":{"type":null,"types":["Number"],"description":null,"text":"Number in range 0..1, -1 in case of error (e.g provided a non-human)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _volume = getPlayerVoNVolume (units player select 1);\n```","code":["private _volume = getPlayerVoNVolume (units player select 1);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPlayerVoNVolume","soundVolume","radioVolume","musicVolume"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getPos","operator":null,"title":"getPos","type":"command","url":"https://community.bistudio.com/wiki/getPos","revid":377527,"updated":"2026-01-02T06:52:50Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns object or location position. If the argument is an object, the return value is in format PositionAGLS.\n\nThe alternative syntax gets the position given distance and heading away from provided object or position - the command equivalent of BIS_fnc_relPos.\n\n> [!IMPORTANT]\n> Do **not** use this command's first syntax to get an object's position in 3D format:\n> - the Z value from this command is **relative** to the surface underneath, and there is no compatible setter command to use it with;\n> the commonly misused code: `_obj1 setPos getPos _obj2` is **absolutely wrong**\n> - this command is significantly **slower** than other position commands because it has to calculate the surface below a position from objects in the (2D) area; its performance therefore suffers from areas with a high density of objects such as cities, and can easily be ~20x slower than other, simpler position commands - see this benchmark.\n> The **only** correct usage of this command is to determine the altitude of an object **from the surface below it** (see #Example 4).","syntaxes":[{"syntax":"getPos object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionAGLS","types":["PositionAGLS"],"description":"where Z is the height over the surface underneath","text":"PositionAGLS - where Z is the height over the surface underneath"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"getPos location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"see locationPosition","text":"PositionAGL - see locationPosition"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}},{"syntax":"origin getPos [distance, heading]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"origin","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"origin: Object, Position2D or Position3D"},{"name":"distance","type":"Number","optional":false,"default":null,"description":"distance from position","types":["Number"],"since":null,"text":"distance: Number - distance from position"},{"name":"heading","type":"Number","optional":false,"default":null,"description":"in which compass direction","types":["Number"],"since":null,"text":"heading: Number - in which compass direction"}],"returns":{"type":"PositionAGLS","types":["PositionAGLS"],"description":"the Z value is terrain level Above Ground Level, either 0 over land or getTerrainHeightASL (negative value) over water","text":"PositionAGLS - the Z value is **terrain level Above Ground Level**, either 0 over land or getTerrainHeightASL (negative value) over water"},"form":"binary","operator":null,"left":{"text":"origin","types":["Object","Position2D","Position3D"]},"right":{"text":"[distance, heading]","types":["Array"]}}],"examples":[{"text":"```sqf\nhintSilent str getPos player;\n```","code":["hintSilent str getPos player;"]},{"text":"getPos vs. other methods (over sea). Pay attention to Z values:\n\n```sqf\ngetPos ship;                // [2412.01, 6036.33, -0.839965]\ngetPosATL ship;                // [2412.01, 6036.33, 19.4266]\ngetPosASL ship;                // [2412.01, 6036.33, -0.920066]\ngetPosASLW ship;            // [2412.01, 6036.33, -0.865981]\nvisiblePosition ship;        // [2412.02, 6036.33, -0.837952]\nvisiblePositionASL ship;    // [2412.02, 6036.33, -0.91798]\nposition ship;                // [2412.01, 6036.33, -0.839965]\n```","code":["getPos ship;\t\t\t\t// [2412.01, 6036.33, -0.839965]\ngetPosATL ship;\t\t\t\t// [2412.01, 6036.33, 19.4266]\ngetPosASL ship;\t\t\t\t// [2412.01, 6036.33, -0.920066]\ngetPosASLW ship;\t\t\t// [2412.01, 6036.33, -0.865981]\nvisiblePosition ship;\t\t// [2412.02, 6036.33, -0.837952]\nvisiblePositionASL ship;\t// [2412.02, 6036.33, -0.91798]\nposition ship;\t\t\t\t// [2412.01, 6036.33, -0.839965]"]},{"text":"getPos vs. other methods (over land, on top of a 100m high building). Pay attention to Z values:\n\n```sqf\ngetPos car;                    // [2508.64, 5681.47, 0.0609589]\ngetPosATL car;                // [2508.64, 5681.47, 100.0356369]\ngetPosASL car;                // [2508.64, 5681.47, 171.718]\ngetPosASLW car;                // [2508.64, 5681.47, 171.718]\nvisiblePosition car;        // [2508.64, 5681.47, 0.0609512]\nvisiblePositionASL car;        // [2508.64, 5681.47, 171.718]\nposition car;                // [2508.64, 5681.47, 0.0609589]\n```","code":["getPos car;\t\t\t\t\t// [2508.64, 5681.47, 0.0609589]\ngetPosATL car;\t\t\t\t// [2508.64, 5681.47, 100.0356369]\ngetPosASL car;\t\t\t\t// [2508.64, 5681.47, 171.718]\ngetPosASLW car;\t\t\t\t// [2508.64, 5681.47, 171.718]\nvisiblePosition car;\t\t// [2508.64, 5681.47, 0.0609512]\nvisiblePositionASL car;\t\t// [2508.64, 5681.47, 171.718]\nposition car;\t\t\t\t// [2508.64, 5681.47, 0.0609589]"]},{"text":"Determine if a free-falling unit is close enough to the surface (including buildings, aircraft carriers etc) below to deploy the parachute:\n\n```sqf\nwaitUntil { sleep 1; getPos player select 2 < 200 };\nhint \"Deploying a parachute might be a good idea\";\n```","code":["waitUntil { sleep 1; getPos player select 2 < 200 };\nhint \"Deploying a parachute might be a good idea\";"]},{"text":"Find position 100 metres and 45 degrees from player position:\n\n```sqf\nplayer getPos [100, 45];    // e.g [1834, 2230, 0] if resulting pos is over land\n                            // or [120, 256, -271] if resulting pos is over water\n```","code":["player getPos [100, 45];\t// e.g [1834, 2230, 0] if resulting pos is over land\n\t\t\t\t\t\t\t// or [120, 256, -271] if resulting pos is over water"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosVisual","getRelPos","setPos","Position","position","getPosATL","getPosASL","getPosASLW","visiblePosition","visiblePositionASL","getMarkerPos"],"notes":[{"user":"Dr_Eyeball","date":"2007-02-17T13:43:00Z","text":"`getPos obj select 2` might return the vertical position above ground level, but for a stacked object, it returns the vertical position above the object beneath it. The same problem existed for getPosASL (**pre-Arma 2 games only**). There was a  thread in the BIS forums which suggested the use of the command modelToWorld instead to get around this issue where an absolute vertical position is required. ArmA Ver **1.02**."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getPosASL","operator":null,"title":"getPosASL","type":"command","url":"https://community.bistudio.com/wiki/getPosASL","revid":377441,"updated":"2026-01-02T06:46:51Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"},{"game":"ofp","name":"Operation Flashpoint","version":"1.99"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the object position height above sea level.","syntaxes":[{"syntax":"getPosASL object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_aslPos = getPosASL player;\n```","code":["_aslPos = getPosASL player;"]},{"text":"```sqf\nhint format [\"position above sea level: %1\", (getPosASL player) select 2];\n```","code":["hint format [\"position above sea level: %1\", (getPosASL player) select 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosASLVisual","setPosASL","setPosASL2","position","getPos","getPosATL","getPosASLW","visiblePosition","visiblePositionASL","getTerrainHeightASL","setUnitFreefallHeight"],"notes":[{"user":"Dr Eyeball","date":"2007-02-23T07:38:00Z","text":"`getPosASL _obj select 2;` might sometimes return the vertical position above sea level, but over land for stacked objects, it returns the vertical position above the object beneath it or at least affected by this offset.\nThe same problem exists for getPos. There was a  thread in the BIS forums which suggested the use of the command modelToWorld instead to get around this issue where an absolute vertical position is required. ArmA Ver **1.02**."},{"user":"SilentKiller","date":"2014-03-27T19:19:00Z","text":"According to Code Optimisation, this command is among the fastest (2x) and should be used (or getPosATL or, best performance-wise, getPosWorld) instead of getPos/position."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getPosASLVisual","operator":null,"title":"getPosASLVisual","type":"command","url":"https://community.bistudio.com/wiki/getPosASLVisual","revid":377445,"updated":"2026-01-02T06:46:58Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's rendered ASL position (z value above sea level) in render time scope.","syntaxes":[{"syntax":"getPosASLVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"name of the object","types":["Object"],"since":null,"text":"object: Object - name of the object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _playerRenderedPosASL = getPosASLVisual player;\n```","code":["private _playerRenderedPosASL = getPosASLVisual player;"]}],"multiplayer":null,"problems":null,"aliases":["visiblePositionASL"],"see_also":["getPosVisual","getPosATLVisual","getPosWorldVisual","visiblePositionASL","visiblePosition","position","getPos","getPosATL","getPosASL","getPosASLW"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getPosASLW","operator":null,"title":"getPosASLW","type":"command","url":"https://community.bistudio.com/wiki/getPosASLW","revid":377793,"updated":"2026-01-03T01:42:08Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the object position height above water surface (waves and pond objects included).","syntaxes":[{"syntax":"getPosASLW obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"PositionASLW","types":["PositionASLW"],"description":null,"text":"PositionASLW"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\n_pos = getPosASLW _diver;\n```","code":["_pos = getPosASLW _diver;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPosASLW","position","getPos","getPosATL","getPosASL","visiblePosition","visiblePositionASL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"getPosATL","operator":null,"title":"getPosATL","type":"command","url":"https://community.bistudio.com/wiki/getPosATL","revid":377531,"updated":"2026-01-02T06:53:14Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.03"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.03"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the position of an object relative to the terrain.","syntaxes":[{"syntax":"getPosATL object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionATL","types":["PositionATL"],"description":null,"text":"PositionATL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_objPosition = getPosATL player;\n```","code":["_objPosition = getPosATL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosATLVisual","setPosATL","position","getPos","getPosASL","getPosASLW","visiblePosition","visiblePositionASL"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.03","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getPosATLVisual","operator":null,"title":"getPosATLVisual","type":"command","url":"https://community.bistudio.com/wiki/getPosATLVisual","revid":377529,"updated":"2026-01-02T06:53:11Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's rendered ATL position (z value above ground) in render time scope.","syntaxes":[{"syntax":"getPosATLVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionATL","types":["PositionATL"],"description":null,"text":"PositionATL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerRenderedPosATL = getPosATLVisual player;\n```","code":["_playerRenderedPosATL = getPosATLVisual player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosVisual","getPosASLVisual","getPosWorldVisual","visiblePositionASL","visiblePosition","position","getPos","getPosATL","getPosASL","getPosASLW"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getPosVisual","operator":null,"title":"getPosVisual","type":"command","url":"https://community.bistudio.com/wiki/getPosVisual","revid":377526,"updated":"2026-01-02T06:52:47Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's AGLS position in render time scope. Alias of visiblePosition.\n\n> [!IMPORTANT]\n> This command must **not** be used for actual 3D calculations. See getPos for more details.","syntaxes":[{"syntax":"getPosVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"name of the object","types":["Object"],"since":null,"text":"object: Object - name of the object"}],"returns":{"type":"PositionAGLS","types":["PositionAGLS"],"description":null,"text":"PositionAGLS"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerRenderedPos = getPosVisual player;\n```","code":["_playerRenderedPos = getPosVisual player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosASLVisual","getPosATLVisual","visiblePositionASL","visiblePosition","position","getPos","getPosATL","getPosASL","getPosASLW"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getPosWorld","operator":null,"title":"getPosWorld","type":"command","url":"https://community.bistudio.com/wiki/getPosWorld","revid":377455,"updated":"2026-01-02T06:47:19Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the provided object's model centre position ([0,0,0]) in PositionASL, rather than the transformed boundingCenter or LandContact vertices.","syntaxes":[{"syntax":"getPosWorld object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":"the model's centre","text":"PositionASL - **the model's centre**"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_obj setPosWorld getPosWorld _obj;\n```","code":["_obj setPosWorld getPosWorld _obj;"]},{"text":"```sqf\nATLToASL (_groundObj modelToWorld [0,0,0]) isEqualTo getPosWorld _groundObj; // true\n```","code":["ATLToASL (_groundObj modelToWorld [0,0,0]) isEqualTo getPosWorld _groundObj; // true"]},{"text":"Wave height under a boat:\n\n```sqf\nprivate _h = ((boat modelToWorld [0,0,0]) vectorDiff getPosWorld boat) select 2;\n```","code":["private _h = ((boat modelToWorld [0,0,0]) vectorDiff getPosWorld boat) select 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosWorldVisual","setPosWorld","position","getPosATL","getPosASL","getPosASLW","visiblePosition","visiblePositionASL","getMarkerPos","modelToWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"getPosWorldVisual","operator":null,"title":"getPosWorldVisual","type":"command","url":"https://community.bistudio.com/wiki/getPosWorldVisual","revid":377439,"updated":"2026-01-02T06:46:47Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the provided object's, model centre position in render version in format PositionASL, rather than transformed boundingCenter or LandContact vertices.","syntaxes":[{"syntax":"getPosWorldVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":"the model centre's position (see getPosWorld) in render scope","text":"PositionASL  - **the model centre**'s position (see getPosWorld) in render scope"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_obj setPosWorld getPosWorldVisual _obj;\n```","code":["_obj setPosWorld getPosWorldVisual _obj;"]},{"text":"```sqf\n_groundObj modelToWorldVisualWorld [0,0,0] isEqualTo getPosWorldVisual _groundObj; // true\n```","code":["_groundObj modelToWorldVisualWorld [0,0,0] isEqualTo getPosWorldVisual _groundObj; // true"]},{"text":"```sqf\nprivate _waveHeight = ((boat modelToWorldVisual [0,0,0]) vectorDiff getPosWorldVisual boat) select 2;\n```","code":["private _waveHeight = ((boat modelToWorldVisual [0,0,0]) vectorDiff getPosWorldVisual boat) select 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosWorld","setPosWorld","visiblePosition","getPosATLVisual","getPosASLVisual","visiblePositionASL","modelToWorldVisual","modelToWorldVisualWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"getPylonMagazines","operator":null,"title":"getPylonMagazines","type":"command","url":"https://community.bistudio.com/wiki/getPylonMagazines","revid":364988,"updated":"2024-07-04T19:58:05Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return array of magazines on pylons.","syntaxes":[{"syntax":"getPylonMagazines vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"magazine names","text":"Array of Strings - magazine names"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetPylonMagazines vehicle player;\n```","code":["getPylonMagazines vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","setAmmoOnPylon","ammoOnPylon","animatePylon","animateBay","setPylonsPriority","setPylonLoadout","magazinesAllTurrets"],"notes":[{"user":"Sa-Matra","date":"2024-05-04T05:13:58Z","text":"Just like getAllPylonsInfo this command returns last pylon state which can include non-existent magazine that was deleted with removeMagazineTurret"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"getRelDir","operator":null,"title":"getRelDir","type":"command","url":"https://community.bistudio.com/wiki/getRelDir","revid":364385,"updated":"2024-05-12T02:06:56Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns direction, which is relative to object's current direction, from given object to another object or position in the range from 0 to 360, the equivalent of BIS_fnc_relativeDirTo.\nTaking the current direction of the object into account.","syntaxes":[{"syntax":"object getRelDir position","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"Object, Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"position: Object, Position2D or Position3D"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"position","types":["Object","Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_reldir = player getRelDir tank;\n```","code":["_reldir = player getRelDir tank;"]},{"text":"```sqf\n// Set object's direction towards any given position\n_object setDir (getDir _object + (_object getRelDir [_x, _y, _z]))\n```","code":["// Set object's direction towards any given position\n_object setDir (getDir _object + (_object getRelDir [_x, _y, _z]))"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDir","direction","getDirVisual"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getRelPos","operator":null,"title":"getRelPos","type":"command","url":"https://community.bistudio.com/wiki/getRelPos","revid":377397,"updated":"2026-01-02T06:44:48Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns position that is given distance and relative direction away from original object. The alternative syntax available from Arma 3 v 2.14, returns the position offset of the attached object. If the animated memory point is used for attachment, the offset is calculated in render scope.","syntaxes":[{"syntax":"object getRelPos [distance, direction]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object","types":["Object"],"since":null,"text":"object: Object - object"},{"name":"distance","type":"Number","optional":false,"default":null,"description":"distance from object","types":["Number"],"since":null,"text":"distance: Number - distance from object"},{"name":"direction","type":"Number","optional":false,"default":null,"description":"direction relative to object's current direction","types":["Number"],"since":null,"text":"direction: Number - direction relative to object's current direction"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":null,"text":"PositionAGL"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[distance, direction]","types":["Array"]}},{"syntax":"obj1 getRelPos obj2","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"obj1","type":"Object","optional":false,"default":null,"description":"parent object","types":["Object"],"since":null,"text":"obj1: Object - parent object"},{"name":"obj2","type":"Object","optional":false,"default":null,"description":"attached object","types":["Object"],"since":null,"text":"obj2: Object - attached object"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":null,"text":"PositionRelative"},"form":"binary","operator":null,"left":{"text":"obj1","types":["Object"]},"right":{"text":"obj2","types":["Object"]}}],"examples":[{"text":"Find position 100 metres away at player's 3 o'clock:\n\n```sqf\n_relpos = player getRelPos [100, 90];\n```","code":["_relpos = player getRelPos [100, 90];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPos","getPosASLVisual","getPosATLVisual","visiblePositionASL","visiblePosition","position","getPosATL","getPosASL","getPosASLW"],"notes":[{"user":"talkingtoaj","date":"2016-03-03T15:53:00Z","text":"getPos vs getRelPos: getRelPos operates similarly to getPos except in getRelPos the direction is calculated 'relative' to the current object direction whereas getPos's direction is from North. Thus while getPos can take a position array as it is starting point, getRelPos requires an object with its own azimut heading."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"getRemoteSensorsDisabled","operator":null,"title":"getRemoteSensorsDisabled","type":"command","url":"https://community.bistudio.com/wiki/getRemoteSensorsDisabled","revid":310752,"updated":"2022-05-07T20:21:31Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get status of disabled raycasts for remote entities. See disableRemoteSensors for detailed description.","syntaxes":[{"syntax":"getRemoteSensorsDisabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_status = getRemoteSensorsDisabled;\n```","code":["_status = getRemoteSensorsDisabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableRemoteSensors"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.52","Scripting Commands"]},{"name":"getRepairCargo","operator":null,"title":"getRepairCargo","type":"command","url":"https://community.bistudio.com/wiki/getRepairCargo","revid":364120,"updated":"2024-05-04T22:07:42Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.56"}],"since":{"game":"arma3","name":"Arma 3","version":"0.56"},"arma3_since":"0.56","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the amount (1 is full) of repair resources in the cargo space of a repair vehicle. \n\n> [!NOTE]\n> Since Arma 3 v1.96 the return value for vehicles that are not configured to have ability to repair other vehicles is -1. (Prior to that the value was negative infinity)","syntaxes":[{"syntax":"getRepairCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Number","types":["Number"],"description":"repair cargo value, -1 if repair cargo is not supported, 0 if the vehicle is !alive or isNull","text":"Number - repair cargo value, -1 if repair cargo is not supported, 0 if the vehicle is !alive or isNull"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvalue = getRepairCargo vehicleName;\n```","code":["value = getRepairCargo vehicleName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setRepairCargo","getAmmoCargo","getFuelCargo"],"notes":[{"user":"DreadedEntity","date":"2022-04-24T06:13:18Z","text":"The repair cargo does actually reduce when a repair truck repairs something, however, the default cargo amount of 1 is so high it is functionally infinite. It's inconceivable that you would drain the pool. You would need to set the cargo to 10^-5 or 10^-6 (0.000001 or 0.0000001) before it is low enough to \"realistically\" run out given how physically large the storage pods on the trucks are"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.56","Scripting Commands"]},{"name":"getResolution","operator":null,"title":"getResolution","type":"command","url":"https://community.bistudio.com/wiki/getResolution","revid":378509,"updated":"2026-05-03T17:11:30Z","groups":["System","GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array containing all information about current client screen resolution.\n\n> [!NOTE]\n> **Arma 3:** **Render resolution** is not returned by this command.\n>\n> A sampling setting of **50%** means half of native width *and* half of native height, resulting in a render resolution of ***25%*** the original resolution.\n\n> [!IMPORTANT]\n> The engine default value for `fovTop` is **0.75** in case it is needed to calculate difference with custom FOV.\n\n> [!NOTE]\n> The `aspectRatio` is calculated as `fovLeft / fovTop` and should be the same as `screenW / screenH` for undistorted image if the FOV is custom. Some of the common values:\n>\n> | 16/9 | 16/10 | 5/4 | 4/3 | 16/9 triple screen |\n> |---|---|---|---|---|\n> | 1.777777(…) | 1.6 | 1.25 | 1.333333(…) | 5.333333(…) |","syntaxes":[{"syntax":"getResolution","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [screenW, screenH, viewPortW, viewPortH, aspectRatio, uiScale, fovTop, fovLeft, tripleHead, textureQuality]","types":["Array"],"description":"screenW: Number - width of the screen in pixels - screenH: Number - height of the screen in pixels - viewPortW: Number - width of the 4:3 view port in pixels - viewPortH: Number - height of the 4:3 view port in pixels - aspectRatio: Number - screen aspect ratio - uiScale: Number - the scale of the UI, which affects view port size: | | | | | | | |---|---|---|---|---|---| | + Arma 3 | Very Small | Small | Normal | Large | Very Large | | 0.47 | 0.55 | 0.7 | 0.85 | 1 | | - Arma 3 v1.94 fovTop: Number - vertical FOV in radians, the same as `fovTop` value from the user profile - Arma 3 v1.94 fovLeft: Number - horizontal FOV in radians, the same as`fovLeft` value from the user profile - Arma 3 v1.94 tripleHead: Boolean - true if user has triple head screen (see also safeZoneXAbs, safeZoneWAbs) - Arma 3 v2.10 textureQuality: Number - current texture quality set in user preferences in 0..1 range, where 0 is lowest, 1 is highest","text":"Array with [screenW, screenH, viewPortW, viewPortH, aspectRatio, uiScale, fovTop, fovLeft, tripleHead, textureQuality]\n- screenW: Number - width of the screen in pixels\n- screenH: Number - height of the screen in pixels\n- viewPortW: Number - width of the **4:3** view port in pixels\n- viewPortH: Number - height of the **4:3** view port in pixels\n- aspectRatio: Number - screen aspect ratio\n- uiScale: Number - the scale of the UI, which affects view port size:\n\n|  |  |  |  |  |  |\n|---|---|---|---|---|---|\n| + Arma 3 | Very Small | Small | Normal | Large | Very Large |\n| 0.47 | 0.55 | 0.7 | 0.85 | 1 |  |\n\n- Arma 3 v1.94 fovTop: Number - vertical FOV in radians, the same as `fovTop` value from the user profile\n- Arma 3 v1.94 fovLeft: Number - horizontal FOV in radians, the same as`fovLeft` value from the user profile\n- Arma 3 v1.94 tripleHead: Boolean - true if user has triple head screen (see also safeZoneXAbs, safeZoneWAbs)\n- Arma 3 v2.10 textureQuality: Number - current texture quality set in user preferences in 0..1 range, where 0 is lowest, 1 is highest"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _res = getResolution;\n```\n\nExample result with a single 16:9 monitor:\n\n```sqf\n[\n    1920,        // width\n    1080,        // height\n    792,        // 2D viewport width\n    594,        // 2D viewport height\n    1.77778,    // aspect ratio\n    0.55,        // UI scale\n    0.75,        // fovTop\n    1.33333,    // fovLeft\n    false        // tripleHead\n]\n```\n\nExample result with a triple 16:9 monitor setup:\n\n```sqf\n[\n    5760,        // width\n    1080,        // height\n    792,        // 2D viewport width\n    594,        // 2D viewport height\n    5.33333,    // aspect ratio\n    0.55        // UI scale\n]\n```\n\nExample result on a dedicated server:\n\n```sqf\n[\n    160,        // width\n    120,        // height\n    136,        // 2D viewport width\n    102,        // 2D viewport height\n    1.33333,    // aspect ratio\n    0.85        // UI scale\n]\n```","code":["private _res = getResolution;","[\n\t1920,\t\t// width\n\t1080,\t\t// height\n\t792,\t\t// 2D viewport width\n\t594,\t\t// 2D viewport height\n\t1.77778,\t// aspect ratio\n\t0.55,\t\t// UI scale\n\t0.75,\t\t// fovTop\n\t1.33333,\t// fovLeft\n\tfalse\t\t// tripleHead\n]","[\n\t5760,\t\t// width\n\t1080,\t\t// height\n\t792,\t\t// 2D viewport width\n\t594,\t\t// 2D viewport height\n\t5.33333,\t// aspect ratio\n\t0.55\t\t// UI scale\n]","[\n\t160,\t\t// width\n\t120,\t\t// height\n\t136,\t\t// 2D viewport width\n\t102,\t\t// 2D viewport height\n\t1.33333,\t// aspect ratio\n\t0.85\t\t// UI scale\n]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectFOV","worldToScreen","screenToWorld","safeZoneX","safeZoneY","safeZoneW","safeZoneH"],"notes":[{"user":"Tom_48_97","date":"2010-12-20T05:38:00Z","text":"This command can be useful to play a video (see this function BIS_fnc_playVideo) in the given format if you have compiled it for different UI scale."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Command Group: System","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getRespawnVehicleInfo","operator":null,"title":"getRespawnVehicleInfo","type":"command","url":"https://community.bistudio.com/wiki/getRespawnVehicleInfo","revid":377795,"updated":"2026-01-03T03:52:04Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns various properties for the respawning vehicle (see Vehicle Respawn). All properties are synched over the network and should be the same on every client including JIP.","syntaxes":[{"syntax":"getRespawnVehicleInfo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"}],"returns":{"type":"Array with [respawnDelay, respawnCount, deleteOldWreck, respawnOnServer, respawnFlying, respawnUnit, respawnMode, respawnSide, useRespawnMarkerDir, canRespawn, isRespawning, respawnMarkerName, respawnTimeRemaining, missionRespawnDelay, missionRespawnMode]","types":["Array"],"description":"respawnDelay: Number - how long the vehicle will be in respawn queue after death. -1 - 'missionRespawnDelay' value is used. - respawnCount: Number - how many times left for the vehicle to respawn. -1 - indefinite, 0 - no more respawns - deleteOldWreck: Boolean - if true then the old wreck will be deleted when vehicle respawns. - respawnOnServer: Boolean - if true the wreck will be transfered to the server and vehicle will respawn on server. - respawnFlying: Boolean - if true vehicle will not be forced to the ground and if can fly and has pilot will be spawned flying. - respawnUnit: Object - pilot/driver unit that will be placed into the new vehicle. - respawnMode: Number - individual respawn mode for this vehicle. Any mode other than 2,3 or -1 means disabled respawn. -1 - use 'missionRespawnMode' - respawnSide: Side - what side markers to use for respawn. For example if 'respawnSide' set to east the markers with names 'respawn_vehicle_eastXXX' and 'respawn_eastXXX' will be used. - useRespawnMarkerDir: Boolean - align respawned vehicle with respawn marker direction or with wreck direction if no marker found or \"INSTANT\" mode is used. Otherwise, direction is random. - canRespawn: Boolean - true if vehicle is respawnable (all conditions for respawn are ok) - isRespawning: Boolean - true if vehicle is currently in the respawn queue awaiting respawn. - respawnMarkerName: String - Chosen vehicle respawn marker, when vehicle respawns it will use the marker params. The respawn marker is processed instantly uppon vehicle's death. - respawnTimeRemaining: Number - how long left before the respawn. -1 after vehicle has respawned or has respawn disabled. - missionRespawnDelay: Number - global mission vehicle respawn delay. script command > mission param > 3DEN param - missionRespawnMode: Number - global mission vehicle respawn mode. script command > mission param > 3DEN param","text":"Array with [respawnDelay, respawnCount, deleteOldWreck, respawnOnServer, respawnFlying, respawnUnit, respawnMode, respawnSide, useRespawnMarkerDir, canRespawn, isRespawning, respawnMarkerName, respawnTimeRemaining, missionRespawnDelay, missionRespawnMode]\n- respawnDelay: Number - how long the vehicle will be in respawn queue after death. -1 - 'missionRespawnDelay' value is used.\n- respawnCount: Number - how many times left for the vehicle to respawn. -1 - indefinite, 0 - no more respawns\n- deleteOldWreck: Boolean - if true then the old wreck will be deleted when vehicle respawns.\n- respawnOnServer: Boolean - if true the wreck will be transfered to the server and vehicle will respawn on server.\n- respawnFlying: Boolean - if true vehicle will not be forced to the ground and if can fly and has pilot will be spawned flying.\n- respawnUnit: Object - pilot/driver unit that will be placed into the new vehicle.\n- respawnMode: Number - individual respawn mode for this vehicle. Any mode other than 2,3 or -1 means disabled respawn. -1 - use 'missionRespawnMode'\n- respawnSide: Side - what side markers to use for respawn. For example if 'respawnSide' set to east the markers with names 'respawn_vehicle_eastXXX' and 'respawn_eastXXX' will be used.\n- useRespawnMarkerDir: Boolean - align respawned vehicle with respawn marker direction or with wreck direction if no marker found or \"INSTANT\" mode is used. Otherwise, direction is random.\n- canRespawn: Boolean - true if vehicle is respawnable (all conditions for respawn are ok)\n- isRespawning: Boolean - true if vehicle is currently in the respawn queue awaiting respawn.\n- respawnMarkerName: String - Chosen vehicle respawn marker, when vehicle respawns it will use the marker params. The respawn marker is processed instantly uppon vehicle's death.\n- respawnTimeRemaining: Number - how long left before the respawn. -1 after vehicle has respawned or has respawn disabled.\n- missionRespawnDelay: Number - global mission vehicle respawn delay. script command > mission param > 3DEN param\n- missionRespawnMode: Number - global mission vehicle respawn mode. script command > mission param > 3DEN param"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"vehicle getRespawnVehicleInfo index","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"index","type":"Number","optional":false,"default":null,"description":"property index (see main syntax, for example 10 for isRespawning)","types":["Number"],"since":null,"text":"index: Number - property index (see main syntax, for example 10 for isRespawning)"}],"returns":{"type":"Anything","types":["Anything"],"description":"depends on the requested property, or Nothing","text":"Anything - depends on the requested property, or Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _vehInfo = getRespawnVehicleInfo veh1;\n```","code":["private _vehInfo = getRespawnVehicleInfo veh1;"]},{"text":"```sqf\nprivate _isRespawning = veh1 getRespawnVehicleInfo 10;\n```","code":["private _isRespawning = veh1 getRespawnVehicleInfo 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Vehicle Respawn","respawnVehicle","playerRespawnTime","getEntityInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getRoadInfo","operator":null,"title":"getRoadInfo","type":"command","url":"https://community.bistudio.com/wiki/getRoadInfo","revid":377688,"updated":"2026-01-02T09:03:05Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns road piece information.\n\n> [!NOTE]\n> - Bridges are special case. Only large bridges are part of Road Net. Small pedestrian bridges are not recognized as roads. Bridge \"mapType\" is `\"ROAD\"` so the best way to detect bridges is to check \"isBridge\" value. Bridges are not part of new roads and don't have the same info as other new roads, so only \"mapType\", \"texture\" (maybe \"textureEnd\"), \"begPos\", \"endPos\" and \"isBridge\" are  updated.\n> - Pedestrian roads \"mapType\" is usually `\"TRAIL\"`. They are part of Road Net but excluded from path finding. Use roadsConnectedTo with alternative flag to find the connections between pedestrian roads.","syntaxes":[{"syntax":"getRoadInfo road","since":null,"effect":null,"exec":null,"params":[{"name":"road","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"road: Object"}],"returns":{"type":"Array with [mapType, width, isPedestrian, texture, textureEnd, material, begPos, endPos, isBridge, AIpathOffset]","types":["Array"],"description":"mapType: String - road segment type, could be `\"HIDE\"`, `\"ROAD\"`, `\"MAIN ROAD\"`, `\"TRACK\"`, `\"TRAIL\"` (see nearestTerrainObjects) - width: Number - road segment width - isPedestrian: Boolean - when true road is for pedestrian use only - texture: String - road segment surface texture - textureEnd: String - road segment surface texture - material: String - road segment surface material - begPos: PositionASL - start of the road segment - endPos: PositionASL - finish of the road segment - isBridge: Boolean - when true road segment is a bridge - Arma 3 v2.12 AIpathOffset: Number - config value of `AIpathOffset`","text":"Array with [mapType, width, isPedestrian, texture, textureEnd, material, begPos, endPos, isBridge, AIpathOffset]\n- mapType: String - road segment type, could be `\"HIDE\"`, `\"ROAD\"`, `\"MAIN ROAD\"`, `\"TRACK\"`, `\"TRAIL\"` (see nearestTerrainObjects)\n- width: Number - road segment width\n- isPedestrian: Boolean - when true road is for pedestrian use only\n- texture: String - road segment surface texture\n- textureEnd: String - road segment surface texture\n- material: String - road segment surface material\n- begPos: PositionASL - start of the road segment\n- endPos: PositionASL - finish of the road segment\n- isBridge: Boolean - when true road segment is a bridge\n- Arma 3 v2.12 AIpathOffset: Number - config value of `AIpathOffset`"},"form":"unary","operator":null,"left":null,"right":{"text":"road","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _info = getRoadInfo _road;\n_info params [\"_mapType\", \"_width\", \"_isPedestrian\", \"_texture\", \"_textureEnd\", \"_material\", \"_begPos\", \"_endPos\", \"_isBridge\"];\nprivate _roadDirection = _begPos getDir _endPos;\n```","code":["private _info = getRoadInfo _road;\n_info params [\"_mapType\", \"_width\", \"_isPedestrian\", \"_texture\", \"_textureEnd\", \"_material\", \"_begPos\", \"_endPos\", \"_isBridge\"];\nprivate _roadDirection = _begPos getDir _endPos;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearRoads","roadsConnectedTo","isOnRoad","roadAt","nearestTerrainObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getRotorBrakeRTD","operator":null,"title":"getRotorBrakeRTD","type":"command","url":"https://community.bistudio.com/wiki/getRotorBrakeRTD","revid":310829,"updated":"2022-05-07T20:23:51Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if rotor break is on.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"getRotorBrakeRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter : Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if on, otherwise false","text":"Boolean - true if on, otherwise false"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_isOn = getRotorBrakeRTD _heli;\n```","code":["_isOn = getRotorBrakeRTD _heli;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setRotorBrakeRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getSelectionBones","operator":null,"title":"getSelectionBones","type":"command","url":"https://community.bistudio.com/wiki/getSelectionBones","revid":369782,"updated":"2024-10-08T15:09:02Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of bone names to which the specified selection is attached.\n\n> [!IMPORTANT]\n> This command is relatively slow because it searches in all vertices of every bone.","syntaxes":[{"syntax":"object getSelectionBones [selectionName, LOD]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selectionName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"selectionName: String"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the same LOD resolution","types":["String","Number"],"since":null,"text":"LOD: String or Number - can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the same LOD resolution"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"array of bone names","text":"Array of Strings - array of bone names"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selectionName, LOD]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectionPosition","selectionNames","getBoneNames"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getSensorTargets","operator":null,"title":"getSensorTargets","type":"command","url":"https://community.bistudio.com/wiki/getSensorTargets","revid":310341,"updated":"2022-05-05T17:07:32Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns vehicle sensors' potential targets.","syntaxes":[{"syntax":"getSensorTargets vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"the sensors-equipped vehicle","types":["Object"],"since":null,"text":"vehicle: Object - the sensors-equipped vehicle"}],"returns":{"type":"Array of Arrays format [[target, type, relationship, sensor], ...]:","types":["Array"],"description":"target: Object - type: String - can be one of: - \"unknown\" - \"footmobile\" - \"air\" - \"ground\" - \"laserTarget\" - \"irTarget\" - \"radarTarget\" - relationship: String - can be one of: - \"friendly\" - \"enemy\" - \"destroyed\" - \"unknown\" - sensor: Array of Strings - among the following values: - \"ir\" - \"nv\" - \"laser\" - \"activeradar\" - \"passiveradar\" - \"man\" - \"visual\" - \"datalink\"","text":"Array of Arrays format [[target, type, relationship, sensor], ...]:\n- target: Object\n- type: String - can be one of:\n  - \"unknown\"\n  - \"footmobile\"\n  - \"air\"\n  - \"ground\"\n  - \"laserTarget\"\n  - \"irTarget\"\n  - \"radarTarget\"\n- relationship: String - can be one of:\n  - \"friendly\"\n  - \"enemy\"\n  - \"destroyed\"\n  - \"unknown\"\n- sensor: Array of Strings - among the following values:\n  - \"ir\"\n  - \"nv\"\n  - \"laser\"\n  - \"activeradar\"\n  - \"passiveradar\"\n  - \"man\"\n  - \"visual\"\n  - \"datalink\""},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _radarTargets = getSensorTargets vehicle player;\n/*\n    returns e.g\n    [\n        [O Alpha 1-3:1, \"air\", \"unknown\", [\"ir\", \"activeradar\", \"visual\"]],\n        [17750112040# 163957: apc_tracked_01_aa_f.p3d, \"ground\", \"unknown\", [\"datalink\"]]\n    ]\n*/\n```","code":["private _radarTargets = getSensorTargets vehicle player;\n/*\n\treturns e.g\n\t[\n\t\t[O Alpha 1-3:1, \"air\", \"unknown\", [\"ir\", \"activeradar\", \"visual\"]],\n\t\t[17750112040# 163957: apc_tracked_01_aa_f.p3d, \"ground\", \"unknown\", [\"datalink\"]]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSensorThreats","listVehicleSensors","listRemoteTargets"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"getSensorThreats","operator":null,"title":"getSensorThreats","type":"command","url":"https://community.bistudio.com/wiki/getSensorThreats","revid":373682,"updated":"2025-06-12T15:41:21Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns vehicle sensors' threats.","syntaxes":[{"syntax":"getSensorThreats vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"the sensors-equipped vehicle","types":["Object"],"since":null,"text":"vehicle: Object - the sensors-equipped vehicle"}],"returns":{"type":"Array of Arrays","types":["Array"],"description":"format [[object, type, sensor], ...]: - object: Object - type: String - can be one of: - \"missile\" - \"marked\" - \"locked\" - sensors: Array of Strings - values can be: - \"ir\" - \"laser\" - \"missile\" - \"radar\" (not \"activeradar\"/\"passiveradar\") - \"visual\"","text":"Array of Arrays - format [[object, type, sensor], ...]:\n- object: Object\n- type: String - can be one of:\n  - \"missile\"\n  - \"marked\"\n  - \"locked\"\n- sensors: Array of Strings - values can be:\n  - \"ir\"\n  - \"laser\"\n  - \"missile\"\n  - \"radar\" (**not** \"activeradar\"/\"passiveradar\")\n  - \"visual\""},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _dangers = getSensorThreats vehicle player;\n/*\n    returns e.g\n    [\n        [164230: titan_missile_atl_fly.p3d, \"missile\", [\"visual\"]],\n        [164233: titan_missile_atl_fly.p3d, \"threatmissile\", [\"radar\"]]\n    ]\n*/\n```","code":["private _dangers = getSensorThreats vehicle player;\n/*\n\treturns e.g\n\t[\n\t\t[164230: titan_missile_atl_fly.p3d, \"missile\", [\"visual\"]],\n\t\t[164233: titan_missile_atl_fly.p3d, \"threatmissile\", [\"radar\"]]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSensorTargets","listVehicleSensors","listRemoteTargets"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"getServerInfo","operator":null,"title":"getServerInfo","type":"command","url":"https://community.bistudio.com/wiki/getServerInfo","revid":373696,"updated":"2025-06-17T13:55:14Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Get the current server instance's settings from server config.\n\n> [!NOTE]\n> Player-hosted (non-dedicated) servers have fewer entries as they do not use a server config file.","syntaxes":[{"syntax":"getServerInfo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _serverInfo = getServerInfo;\n\n// example result:\n/*\n[\n    [\"admins\", [\"01234\", \"56789\"]],\n    [\"autoSelectMission\", false],\n    [\"battlEye\", false],\n    [\"disconnectTimeout\", 0],\n    [\"estimateTimeLeft\", 15],\n    [\"forcedDifficulty\", \"Wolf\"],\n    [\"hasPasswordAdmin\", true],\n    [\"hostname\", \"Test Server\"],\n    [\"isLocked\", false],\n    [\"maxDesync\", 90000],\n    [\"maxPacketLoss\", 2000],\n    [\"maxPing\", 8000],\n    [\"maxPlayers\", 64],\n    [\"missionHeader\", [[\"fileName\", \"DbgZeus4P.VR\"], [\"name\", \"DbgConsole4PZeus\"], [\"description\", \"\"], [\"fileSize\", \"7461\"], [\"steamId\", \"0\"], [\"fileCRC\", \"99816a4\"]]],\n    [\"motd\", []],\n    [\"overrideHazeQuality\", 0],\n    [\"password\", \"\"],\n    [\"persistent\", true],\n    [\"randomMissionOrder\", false],\n    [\"requiredBuild\", 0],\n    [\"verifySignatures\", 0],\n    [\"zeusCompositionScriptLevel\", 2]\n]\n*/\n```","code":["private _serverInfo = getServerInfo;\n\n// example result:\n/*\n[\n\t[\"admins\", [\"01234\", \"56789\"]],\n\t[\"autoSelectMission\", false],\n\t[\"battlEye\", false],\n\t[\"disconnectTimeout\", 0],\n\t[\"estimateTimeLeft\", 15],\n\t[\"forcedDifficulty\", \"Wolf\"],\n\t[\"hasPasswordAdmin\", true],\n\t[\"hostname\", \"Test Server\"],\n\t[\"isLocked\", false],\n\t[\"maxDesync\", 90000],\n\t[\"maxPacketLoss\", 2000],\n\t[\"maxPing\", 8000],\n\t[\"maxPlayers\", 64],\n\t[\"missionHeader\", [[\"fileName\", \"DbgZeus4P.VR\"], [\"name\", \"DbgConsole4PZeus\"], [\"description\", \"\"], [\"fileSize\", \"7461\"], [\"steamId\", \"0\"], [\"fileCRC\", \"99816a4\"]]],\n\t[\"motd\", []],\n\t[\"overrideHazeQuality\", 0],\n\t[\"password\", \"\"],\n\t[\"persistent\", true],\n\t[\"randomMissionOrder\", false],\n\t[\"requiredBuild\", 0],\n\t[\"verifySignatures\", 0],\n\t[\"zeusCompositionScriptLevel\", 2]\n]\n*/"]},{"text":"```sqf\nif (!isServer) exitWith {};\n\nif (getServerInfo get \"password\" != \"\") then\n{\n    [\"Welcome, I see you had the password ready!\"] remoteExec [\"hint\"];\n};\n```","code":["if (!isServer) exitWith {};\n\nif (getServerInfo get \"password\" != \"\") then\n{\n\t[\"Welcome, I see you had the password ready!\"] remoteExec [\"hint\"];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["admin","allUsers","estimatedTimeLeft"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 2.20","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"getShadowDistance","operator":null,"title":"getShadowDistance","type":"command","url":"https://community.bistudio.com/wiki/getShadowDistance","revid":319175,"updated":"2022-05-13T09:23:19Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the shadows rendering distance.","syntaxes":[{"syntax":"getShadowDistance","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_value = getShadowDistance;\n```","code":["_value = getShadowDistance;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setShadowDistance","isPipEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"getShotInfo","operator":null,"title":"getShotInfo","type":"command","url":"https://community.bistudio.com/wiki/getShotInfo","revid":377707,"updated":"2026-01-02T09:03:44Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns various properties for the given shot.","syntaxes":[{"syntax":"getShotInfo shot","since":null,"effect":null,"exec":null,"params":[{"name":"shot","type":"Object","optional":false,"default":null,"description":"shot projectile","types":["Object"],"since":null,"text":"shot: Object - shot projectile"}],"returns":{"type":"Array with [effectiveTimeToLive, fuseDistanceLeft, timeToExplosion, triggerIsForced, shownTracer, isReal, isSubmunitionTriggered, isSetForDeletion, shotParent, shotInstigator]","types":["Array"],"description":"0 - effectiveTimeToLive: Number - how much more shot has to live. - 1 - fuseDistanceLeft: Number - how long shot has to travel more to get fused (undebarrel grenade for example). - 2 - timeToExplosion: Number - how long before shot fuse explodes (hand grenade for example) Arma 3 v2.20 works on mines too. - 3 - triggerIsForced: Boolean - true if shot ammo was triggered with triggerAmmo. - 4 - shownTracer: Boolean - true if the shot shown as tracer. - 5 - isReal: Boolean - true if the shot is considered in damage events. - 6 - isSubmunitionTriggered: Boolean - true if the shot contains submunition and it is triggered. - 7 - isSetForDeletion: Boolean - true if the shot is already set for deletion but not yet removed from the scene. - 8 - Arma 3 v2.22 shotParent: Object - the vehicle that produced shot. - 9 - Arma 3 v2.22 shotInstigator: Object - the person who pulled the trigger.","text":"Array with [effectiveTimeToLive, fuseDistanceLeft, timeToExplosion, triggerIsForced, shownTracer, isReal, isSubmunitionTriggered, isSetForDeletion, shotParent, shotInstigator]\n- 0 - effectiveTimeToLive: Number - how much more shot has to live.\n- 1 - fuseDistanceLeft: Number - how long shot has to travel more to get fused (undebarrel grenade for example).\n- 2 - timeToExplosion: Number - how long before shot fuse explodes (hand grenade for example) Arma 3 v2.20 works on mines too.\n- 3 - triggerIsForced: Boolean - true if shot ammo was triggered with triggerAmmo.\n- 4 - shownTracer: Boolean - true if the shot shown as tracer.\n- 5 - isReal: Boolean - true if the shot is considered in damage events.\n- 6 - isSubmunitionTriggered: Boolean - true if the shot contains submunition and it is triggered.\n- 7 - isSetForDeletion: Boolean - true if the shot is already set for deletion but not yet removed from the scene.\n- 8 - Arma 3 v2.22 shotParent: Object - the vehicle that produced shot.\n- 9 - Arma 3 v2.22 shotInstigator: Object - the person who pulled the trigger."},"form":"unary","operator":null,"left":null,"right":{"text":"shot","types":["Object"]}},{"syntax":"shot getShotInfo index","since":null,"effect":null,"exec":null,"params":[{"name":"shot","type":"Object","optional":false,"default":null,"description":"shot projectile","types":["Object"],"since":null,"text":"shot: Object - shot projectile"},{"name":"index","type":"Number","optional":false,"default":null,"description":"property index (see main syntax, for example 1 for fuseDistanceLeft)","types":["Number"],"since":null,"text":"index: Number - property index (see main syntax, for example 1 for fuseDistanceLeft)"}],"returns":{"type":"Anything","types":["Anything"],"description":"depends on the requested property, or Nothing","text":"Anything - depends on the requested property, or Nothing"},"form":"binary","operator":null,"left":{"text":"shot","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _shotInfo = getShotInfo shot1;\n```","code":["private _shotInfo = getShotInfo shot1;"]},{"text":"```sqf\nprivate _fuseDistanceLeft = shot1 getShotInfo 1;\n```","code":["private _fuseDistanceLeft = shot1 getShotInfo 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getShotParents","missileTarget","triggerAmmo","getObjectType","getObjectTextures","objectParent","setVelocityTransformation","getUnitFreefallInfo","getEntityInfo","getModelInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getShotParents","operator":null,"title":"getShotParents","type":"command","url":"https://community.bistudio.com/wiki/getShotParents","revid":378943,"updated":"2026-08-27T16:27:34Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns shot information for the given projectile.\nIf shot was fired by a soldier on foot or in FFV position in vehicle, the soldier is returned for the vehicle.","syntaxes":[{"syntax":"getShotParents projectile","since":null,"effect":null,"exec":null,"params":[{"name":"projectile","type":"Object","optional":false,"default":null,"description":"the actual projectile shot","types":["Object"],"since":null,"text":"projectile: Object - the actual projectile shot"}],"returns":{"type":"Array","types":["Array"],"description":"[vehicle, instigator] - Where vehicle is the vehicle the shot was fired from, and the instigator is the person who pulled the trigger","text":"Array - [vehicle, instigator] - Where vehicle is the vehicle the shot was fired from, and the instigator is the person who pulled the trigger"},"form":"unary","operator":null,"left":null,"right":{"text":"projectile","types":["Object"]}}],"examples":[{"text":"```sqf\n_shotParents = getShotParents myProjectile;\n```","code":["_shotParents = getShotParents myProjectile;"]},{"text":"```sqf\nbatmobile addEventHandler [\"Fired\", { systemChat str getShotParents (_this select 6) }];\n```","code":["batmobile addEventHandler [\"Fired\", { systemChat str getShotParents (_this select 6) }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setShotParents"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getSlingLoad","operator":null,"title":"getSlingLoad","type":"command","url":"https://community.bistudio.com/wiki/getSlingLoad","revid":319143,"updated":"2022-05-13T09:23:15Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return object which is sling loaded by vehicle","syntaxes":[{"syntax":"getSlingLoad vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":"the sling loaded vehicle. objNull if nothing is sling loaded.","text":"Object - the sling loaded vehicle. objNull if nothing is sling loaded."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_cargo = getSlingLoad heli1;\n```","code":["_cargo = getSlingLoad heli1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"getSlotItemName","operator":null,"title":"getSlotItemName","type":"command","url":"https://community.bistudio.com/wiki/getSlotItemName","revid":353032,"updated":"2024-03-12T11:47:36Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of assigned item in given slot or the empty string.","syntaxes":[{"syntax":"unit getSlotItemName slot","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"slot","type":"Number","optional":false,"default":null,"description":"can be one of:\n- 603 - Goggles\n- 605 - Headgear\n- 608 - Map\n- 609 - Compass\n- 610 - Watch\n- 611 - Radio\n- 612 - GPS\n- 616 - HMD\n- 617 - Binoculars\n- 701 - Vest\n- 801 - Uniform\n- 901 - Backpack","types":["Number"],"since":null,"text":"slot: Number - can be one of:\n- 603 - Goggles\n- 605 - Headgear\n- 608 - Map\n- 609 - Compass\n- 610 - Watch\n- 611 - Radio\n- 612 - GPS\n- 616 - HMD\n- 617 - Binoculars\n- 701 - Vest\n- 801 - Uniform\n- 901 - Backpack"}],"returns":{"type":"String","types":["String"],"description":"item name","text":"String - item name"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"slot","types":["Number"]}}],"examples":[{"text":"```sqf\nhint (player getSlotItemName 610);\n```","code":["hint (player getSlotItemName 610);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedItems","assignItem","unassignItem","linkItem","unlinkItem","addItem","removeItem","removeAllAssignedItems","items","itemsWithMagazines","backpacks"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"getSoundController","operator":null,"title":"getSoundController","type":"command","url":"https://community.bistudio.com/wiki/getSoundController","revid":319094,"updated":"2022-05-13T09:23:11Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns value of the given sound controller.","syntaxes":[{"syntax":"vehicle getSoundController controller","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"must be a vehicle (does not work on soldiers)","types":["Object"],"since":null,"text":"vehicle: Object - must be a vehicle (does not work on soldiers)"},{"name":"controller","type":"String","optional":false,"default":null,"description":"name of sound controller, for example \"rpm\" or \"thrust\".","types":["String"],"since":null,"text":"controller: String - name of sound controller, for example \"rpm\" or \"thrust\"."}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"controller","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player getSoundController \"rpm\"; //600\n```","code":["vehicle player getSoundController \"rpm\"; //600"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","getAllSoundControllers","getSoundControllerResult","getEnvSoundController","getAllEnvSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getSoundControllerResult","operator":null,"title":"getSoundControllerResult","type":"command","url":"https://community.bistudio.com/wiki/getSoundControllerResult","revid":323118,"updated":"2022-06-29T22:09:10Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the calculated value of simple expression defined in config. Config could be any config entry, even mission config entry. It is more important that the vehicle is a transport and not any object. If the expression contains sound controllers, the controller values will be taken from the given vehicle.","syntaxes":[{"syntax":"vehicle getSoundControllerResult config","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport vehicle","types":["Object"],"since":null,"text":"vehicle: Object - transport vehicle"},{"name":"config","type":"Config","optional":false,"default":null,"description":"path to config entry containing the expression","types":["Config"],"since":null,"text":"config: Config - path to config entry containing the expression"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_result = (vehicle player) getSoundControllerResult (configFile >> \"cfgVehicles\" >> typeOf (vehicle player) >> \"sounds\" >> \"idle_ext\" >> \"volume\");\n```","code":["_result = (vehicle player) getSoundControllerResult (configFile >> \"cfgVehicles\" >> typeOf (vehicle player) >> \"sounds\" >> \"idle_ext\" >> \"volume\");"]},{"text":"```sqf\n// mission config entry to reverse rain strength:\n// myExpression = \"rain factor [1,0]\";\n_result = \"PaperCar\" createVehicleLocal position player getSoundControllerResult (missionConfigFile >> \"myExpression\");\n```","code":["// mission config entry to reverse rain strength:\n// myExpression = \"rain factor [1,0]\";\n_result = \"PaperCar\" createVehicleLocal position player getSoundControllerResult (missionConfigFile >> \"myExpression\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","getSoundController","getEnvSoundController","getAllEnvSoundControllers","getAllSoundControllers","getCustomSoundController","setCustomSoundController","getCustomSoundControllerCount"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"getSpeed","operator":null,"title":"getSpeed","type":"command","url":"https://community.bistudio.com/wiki/getSpeed","revid":347558,"updated":"2023-09-28T09:45:46Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get the speed for the given speed mode.\n\nSpeedMode can be:\n- \"AUTO\"\n- \"SLOW\"\n- \"NORMAL\"\n- \"FAST\"","syntaxes":[{"syntax":"object getSpeed speedMode","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"speedMode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"speedMode: String"}],"returns":{"type":"Number","types":["Number"],"description":"m/s","text":"Number - m/s"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"speedMode","types":["String"]}}],"examples":[{"text":"```sqf\n_spd = player getSpeed \"FAST\";\n```","code":["_spd = player getSpeed \"FAST\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWalk","isWalking","forceSpeed","isForcedWalk"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getStamina","operator":null,"title":"getStamina","type":"command","url":"https://community.bistudio.com/wiki/getStamina","revid":363462,"updated":"2024-03-31T00:52:30Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get current stamina (~ seconds until depletion)","syntaxes":[{"syntax":"getStamina unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ngetStamina player;\n```","code":["getStamina player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","setStamina","setFatigue","getFatigue"],"notes":[{"user":"Hypoxic125","date":"2024-03-31T00:52:30Z","text":"A naked player unit has 60 seconds of stamina."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"getStatValue","operator":null,"title":"getStatValue","type":"command","url":"https://community.bistudio.com/wiki/getStatValue","revid":347571,"updated":"2023-09-28T10:03:14Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns value of the given stat.\n\nA list of possible StatNames can be found here: Arma 3: Stat Names","syntaxes":[{"syntax":"getStatValue name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Number","types":["Number"],"description":"(can return Nothing)","text":"Number - (can return Nothing)"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\ngetStatValue \"ExpWarlockDown\"; // Checks if the \"Warlock Down\" Achivement was already aquired\n```","code":["getStatValue \"ExpWarlockDown\"; // Checks if the \"Warlock Down\" Achivement was already aquired"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setStatValue","Arma 3: Stat Names"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.18","Scripting Commands"]},{"name":"getSteamFriendsServers","operator":null,"title":"getSteamFriendsServers","type":"command","url":"https://community.bistudio.com/wiki/getSteamFriendsServers","revid":309225,"updated":"2022-05-04T10:08:28Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns servers information of Steam friends currently playing the game.","syntaxes":[{"syntax":"getSteamFriendsServers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Array","String"],"description":null,"text":"Array of Array of Strings in format [ipAndPort, steamFriendName]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ngetSteamFriendsServers; // returns e.g [[\"127.42.33.8:2302\", \"MyFriend\"], [\"127.84.66.16:4604\", \"My Best Friend\"]]\n```","code":["getSteamFriendsServers; // returns e.g [[\"127.42.33.8:2302\", \"MyFriend\"], [\"127.84.66.16:4604\", \"My Best Friend\"]]"]}],"multiplayer":"> [!IMPORTANT]\n> Does **not** work in multiplayer - returns an empty array.","problems":null,"aliases":[],"see_also":["isMultiplayer","connectToServer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getSubtitleOptions","operator":null,"title":"getSubtitleOptions","type":"command","url":"https://community.bistudio.com/wiki/getSubtitleOptions","revid":309170,"updated":"2022-05-03T14:55:20Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns subtitles settings.","syntaxes":[{"syntax":"getSubtitleOptions","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Booleans","types":["Array","Boolean"],"description":"options in format [subtitlesEnabled, radioSubtitlesEnabled]","text":"Array of Booleans - options in format [subtitlesEnabled, radioSubtitlesEnabled]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _subtitleSettings = getSubtitleOptions;\n```","code":["private _subtitleSettings = getSubtitleOptions;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAudioOptionVolumes","soundVolume","musicVolume","radioVolume","radioEnabled","shownSubtitles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.94","Scripting Commands"]},{"name":"getSuppression","operator":null,"title":"getSuppression","type":"command","url":"https://community.bistudio.com/wiki/getSuppression","revid":320943,"updated":"2022-05-13T10:04:43Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Gets the suppression value for the given unit. Returns varying Number between 0 and 1, or -1 if suppression is disabled (`disableAI \"SUPPRESSION\"`) or the suppression value is not available. Suppression is not calculated for player entities and is always 0, unless it is set with setSuppression. In this case the return value is the set value. Before Arma 3 v1.92 this command could return nil.\n\n> [!IMPORTANT]\n> The unit must not be objNull, must be local and alive","syntaxes":[{"syntax":"getSuppression unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":"from 0 to 1, or -1 if suppression is not available.","text":"Number - from 0 to 1, or -1 if suppression is not available."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ngetSuppression AI_unit_1;\n```","code":["getSuppression AI_unit_1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSuppression","suppressFor","disableAI","enableAI"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"getTerrainGrid","operator":null,"title":"getTerrainGrid","type":"command","url":"https://community.bistudio.com/wiki/getTerrainGrid","revid":353047,"updated":"2024-03-12T12:19:53Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setTerrainGrid, returns the current terrain grid.","syntaxes":[{"syntax":"getTerrainGrid","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"terrain grid value","text":"Number - terrain grid value"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_terrainGrid = getTerrainGrid;\n```","code":["_terrainGrid = getTerrainGrid;"]},{"text":"```sqf\nif (getTerrainGrid < 50) then\n{\n    hint \"Grass is enabled\";\n};\n```","code":["if (getTerrainGrid < 50) then\n{\n\thint \"Grass is enabled\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTerrainGrid","viewDistance","diag_getTerrainGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"getTerrainHeight","operator":null,"title":"getTerrainHeight","type":"command","url":"https://community.bistudio.com/wiki/getTerrainHeight","revid":377555,"updated":"2026-01-02T06:54:55Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns terrain height at the specified location.\n\n> [!NOTE]\n> Unlike getTerrainHeightASL which returns the exact position's height, this command returns the height at the closest terrain grid pixel to the provided position:\n>\n> ```sqf\n> private _cellWidth = getTerrainInfo # 2;\n> getTerrainHeightASL (_pos apply { _cellWidth * round (_x / _cellWidth) });\n> ```","syntaxes":[{"syntax":"getTerrainHeight positionWorld","since":null,"effect":null,"exec":null,"params":[{"name":"positionWorld","type":"Position2D or Position3D","optional":false,"default":null,"description":"world coordinates","types":["Position2D","Position3D"],"since":null,"text":"positionWorld: Position2D or Position3D - world coordinates"}],"returns":{"type":"Number","types":["Number"],"description":"terrain height","text":"Number - terrain height"},"form":"unary","operator":null,"left":null,"right":{"text":"positionWorld","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\nprivate _gridCellHeight = getTerrainHeight getPosWorld player;\n```","code":["private _gridCellHeight = getTerrainHeight getPosWorld player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTerrainHeight","getTerrainHeightASL","getTerrainInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getTerrainHeightASL","operator":null,"title":"getTerrainHeightASL","type":"command","url":"https://community.bistudio.com/wiki/getTerrainHeightASL","revid":377799,"updated":"2026-01-03T03:59:49Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the terrain height above the sea for the given position.","syntaxes":[{"syntax":"getTerrainHeightASL position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"Position3D the Z value is ignored","types":["Position2D","Position3D"],"since":null,"text":"position: Position2D or Position3D - Position3D the Z value is ignored"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_height = getTerrainHeightASL (getPosATL player);\n```","code":["_height = getTerrainHeightASL (getPosATL player);"]},{"text":"```sqf\n_height = getTerrainHeightASL [5213,3245];\n```","code":["_height = getTerrainHeightASL [5213,3245];"]},{"text":"```sqf\n_seaDepth = abs (getTerrainHeightASL getPosATL player); // sea depth at player's position\n```","code":["_seaDepth = abs (getTerrainHeightASL getPosATL player); // sea depth at player's position"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPosASL","getPosASL","getPosATL","ASLToATL","ATLToASL","getElevationOffset"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getTerrainInfo","operator":null,"title":"getTerrainInfo","type":"command","url":"https://community.bistudio.com/wiki/getTerrainInfo","revid":377882,"updated":"2026-01-04T16:22:56Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the terrain heightmap information, as well as sea level offset (due to tides, if available).","syntaxes":[{"syntax":"getTerrainInfo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [landGridWidth, landGridSize, terrainGridWidth, terrainGridSize, seaLevel]","types":["Array"],"description":"landGridWidth: Number - width of each land grid, in meters - landGridSize: Number - number of land grid pixels - terrainGridWidth: Number width of each terrain grid, in meters (also known as \"cell size\") - terrainGridSize: Number - number of terrain grid pixels (also known as \"heightmap resolution\") - seaLevel: Number - sea level without waves. The value is `0` if tides are disabled. > [!NOTE] > - The result of `landGridWidth * landGridSize` and `terrainGridWidth * terrainGridSize` is always equal to the worldSize. > - \"land grid\" is used by the game for object placement (e.g. finding the nearestObject), dynamic simulation, etc. > - \"terrain grid\" is the actual terrain, used to display the terrain, calculate terrain height, surface normal, etc.","text":"Array with [landGridWidth, landGridSize, terrainGridWidth, terrainGridSize, seaLevel]\n- landGridWidth: Number - width of each land grid, in meters\n- landGridSize: Number - number of land grid pixels\n- terrainGridWidth: Number width of each terrain grid, in meters (also known as \"cell size\")\n- terrainGridSize: Number - number of terrain grid pixels (also known as \"heightmap resolution\")\n- seaLevel: Number - sea level without waves. The value is `0` if tides are disabled.\n\n> [!NOTE]\n> - The result of `landGridWidth * landGridSize` and `terrainGridWidth * terrainGridSize` is always equal to the worldSize.\n> - \"land grid\" is used by the game for object placement (e.g. finding the nearestObject), dynamic simulation, etc.\n> - \"terrain grid\" is the actual terrain, used to display the terrain, calculate terrain height, surface normal, etc."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _terrainInfo = getTerrainInfo; // Stratis: [32,256,4,2048,0]; Altis: [30,1024,7.5,4096,0]\n```","code":["private _terrainInfo = getTerrainInfo; // Stratis: [32,256,4,2048,0]; Altis: [30,1024,7.5,4096,0] "]},{"text":"```sqf\n// Draws a 20x20 terrain grid when clicking on the map\n// Each triangle of the terrain is formed by a diagonal\n// that starts from the top-left corner of the cell and ends at the bottom-right corner.\n// The green lines show the cell diagonals \nonMapSingleClick {\n    getTerrainInfo params [\"\", \"\", \"_cellsize\", \"_resolution\"];\n    gridLines = [];\n    _pos apply { floor (_x / _cellsize) } params [\"_x0\", \"_y0\"];\n    for \"_x\" from ((_x0 - 10) max 0) to ((_x0 + 10) min _resolution) do\n    {\n        for \"_y\" from ((_y0 - 10) max 0) to ((_y0 + 10) min _resolution) do\n        {\n            private _p1 = [_x, _y] vectorMultiply _cellsize;        // bottom-left corner\n            private _p2 = [_x, _y + 1] vectorMultiply _cellsize;    // top-left corner\n            private _p3 = [_x + 1, _y] vectorMultiply _cellsize;    // bottom-right corner\n            // Positions are AGL, and Z value of 0 is already at the terrain surface (except on water surface). \n            // Just move them up a few centimeters so they're visible.\n            _p1 set [2, 0.1];\n            _p2 set [2, 0.1];\n            _p3 set [2, 0.1];\n\n            gridLines pushBack [_p1, _p2, [1,0,0,1]];\n            gridLines pushBack [_p1, _p3, [1,0,0,1]];\n            gridLines pushBack [_p2, _p3, [0,1,0,1]];\n        };\n    };\n\n    onEachFrame {\n        {\n            drawLine3D _x;\n        } forEach gridLines;\n    }\n};\n```","code":["// Draws a 20x20 terrain grid when clicking on the map\n// Each triangle of the terrain is formed by a diagonal\n// that starts from the top-left corner of the cell and ends at the bottom-right corner.\n// The green lines show the cell diagonals \nonMapSingleClick {\n\tgetTerrainInfo params [\"\", \"\", \"_cellsize\", \"_resolution\"];\n\tgridLines = [];\n\t_pos apply { floor (_x / _cellsize) } params [\"_x0\", \"_y0\"];\n\tfor \"_x\" from ((_x0 - 10) max 0) to ((_x0 + 10) min _resolution) do\n\t{\n\t\tfor \"_y\" from ((_y0 - 10) max 0) to ((_y0 + 10) min _resolution) do\n\t\t{\n\t\t\tprivate _p1 = [_x, _y] vectorMultiply _cellsize;\t\t// bottom-left corner\n\t\t\tprivate _p2 = [_x, _y + 1] vectorMultiply _cellsize;\t// top-left corner\n\t\t\tprivate _p3 = [_x + 1, _y] vectorMultiply _cellsize;\t// bottom-right corner\n\t\t\t// Positions are AGL, and Z value of 0 is already at the terrain surface (except on water surface). \n\t\t\t// Just move them up a few centimeters so they're visible.\n\t\t\t_p1 set [2, 0.1];\n\t\t\t_p2 set [2, 0.1];\n\t\t\t_p3 set [2, 0.1];\n\n\t\t\tgridLines pushBack [_p1, _p2, [1,0,0,1]];\n\t\t\tgridLines pushBack [_p1, _p3, [1,0,0,1]];\n\t\t\tgridLines pushBack [_p2, _p3, [0,1,0,1]];\n\t\t};\n\t};\n\n\tonEachFrame {\n\t\t{\n\t\t\tdrawLine3D _x;\n\t\t} forEach gridLines;\n\t}\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTerrainHeight","setTerrainHeight","worldSize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getText","operator":null,"title":"getText","type":"command","url":"https://community.bistudio.com/wiki/getText","revid":341205,"updated":"2023-05-13T22:31:13Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Extracts localized text from config entry, if entry is subject to localization, otherwise returns text value.\nTo obtain the translation key itself, see getTextRaw.","syntaxes":[{"syntax":"getText config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"String","types":["String"],"description":"text value","text":"String - text value"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_text = getText (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"icon\"); // \"Get in %1 as Driver\"\n```","code":["_text = getText (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"icon\"); // \"Get in %1 as Driver\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getNumber","inheritsFrom","isArray","isClass","isNumber","isText","select","getTextRaw"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-28T07:52:00Z","text":"(Arma 3 1.14) It's recommended to use BIS_fnc_getCfgData or BIS_fnc_returnConfigEntry to get variable cfg data rather than conditioning via isNumber, isText, isArray, getNumber, getText and getArray combination.\n\nTraditional workaround:\n\n```sqf\n_cfg = configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\";\nswitch ( true ) do\n{\n    case (isNumber _cfg): {getNumber _cfg};\n    case (isText _cfg): {getText _cfg};\n    case (isArray _cfg): {getArray _cfg;};\n    default { nil };\n};\n```\n\n**Recommended workaround:**\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgData;\n```\n\nTo return default value once entry was not found, we can use BIS_fnc_returnConfigEntry instead of BIS_fnc_getCfgData. e.g.\n\n```sqf\n[(configFile >> \"CannonFire\" >> \"LightExp\"),\"lifeTime\",0] call BIS_fnc_returnConfigEntry;//0.5\n```\n\nTo compose collected String into Array, use BIS_fnc_getCfgDataArray instead. E.g.\n\n```sqf\n(configFile >> \"CfgVehicles\" >> _SomeAddonClassName >> \"DestructionEffects\" >> \"Smoke1\" >> \"type\") call BIS_fnc_getCfgDataArray;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getTextRaw","operator":null,"title":"getTextRaw","type":"command","url":"https://community.bistudio.com/wiki/getTextRaw","revid":347409,"updated":"2023-09-18T13:18:49Z","groups":["Config","Localization"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns raw text from config entry. If entry is subject to localization, the translation key is returned. To obtain the localized text, see getText.","syntaxes":[{"syntax":"getTextRaw config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"String","types":["String"],"description":"raw text value","text":"String - raw text value"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\nprivate _text = getText (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"displayName\");            // \"Get in %1 as Driver\"\nprivate _rawText = getTextRaw (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"displayName\");    // \"$STR_ACTION_GETIN_DRIVER\"\nprivate _localized = localize _text;                                                        // \"Get in %1 as Driver\"\n_localized == _text; // true\n```","code":["private _text = getText (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"displayName\");\t\t\t// \"Get in %1 as Driver\"\nprivate _rawText = getTextRaw (configFile >> \"CfgVehicles\" >> \"Thing\" >> \"displayName\");\t// \"$STR_ACTION_GETIN_DRIVER\"\nprivate _localized = localize _text;\t\t\t\t\t\t\t\t\t\t\t\t\t\t// \"Get in %1 as Driver\"\n_localized == _text; // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Stringtable.xml","localize","isLocalized","diag_localized","BIS_fnc_localize","getText","getNumber","getArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Command Group: Localization","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"getTextureInfo","operator":null,"title":"getTextureInfo","type":"command","url":"https://community.bistudio.com/wiki/getTextureInfo","revid":378510,"updated":"2026-05-03T17:13:34Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return texture information - resolution in pixels (mipmap level 0) and average colour. Multiply the pixel values by pixelW and pixelH to get screen coordinates.","syntaxes":[{"syntax":"getTextureInfo texture","since":null,"effect":null,"exec":null,"params":[{"name":"texture","type":"String","optional":false,"default":null,"description":"texture path (.paa, .jpg, .ogv)","types":["String"],"since":null,"text":"texture: String - texture path (.paa, .jpg, .ogv)"}],"returns":{"type":"Array with [width, height, rgbaAverageColour]","types":["Array"],"description":"width: Number - height: Number - Arma 3 v2.08 rgbaAverageColour: Color (RGBA)","text":"Array with [width, height, rgbaAverageColour]\n- width: Number\n- height: Number\n- Arma 3 v2.08 rgbaAverageColour: Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"texture","types":["String"]}},{"syntax":"getTextureInfo [texture, sizeH]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"texture","type":"String","optional":false,"default":null,"description":"texture path (.paa, .jpg, .ogv)","types":["String"],"since":null,"text":"texture: String - texture path (.paa, .jpg, .ogv)"},{"name":"sizeH","type":"Number","optional":false,"default":null,"description":"texture height in screen size","types":["Number"],"since":null,"text":"sizeH: Number - texture height in screen size"}],"returns":{"type":"Array with [width, height]","types":["Array"],"description":"width: Number - width of the texture in screen units - height: Number - height of the texture in screen units","text":"Array with [width, height]\n- width: Number - width of the texture in screen units\n- height: Number - height of the texture in screen units"},"form":"unary","operator":null,"left":null,"right":{"text":"[texture, sizeH]","types":["Array"]}}],"examples":[{"text":"```sqf\ngetTextureInfo \"a3\\characters_f\\blufor\\data\\clothing1_co.paa\"; // [2048, 2048, [0.458824, 0.427451, 0.34902, 1]]\n```","code":["getTextureInfo \"a3\\characters_f\\blufor\\data\\clothing1_co.paa\"; // [2048, 2048, [0.458824, 0.427451, 0.34902, 1]]"]},{"text":"```sqf\ngetTextureInfo [\"\\A3\\UI_f\\Data\\Logos\\arma3_shadow_ca.paa\", 0.1]; // [0.150111, 0.1]\n```","code":["getTextureInfo [\"\\A3\\UI_f\\Data\\Logos\\arma3_shadow_ca.paa\", 0.1]; // [0.150111, 0.1]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelW","pixelH","getModelInfo","supportInfo","getObjectType","getObjectTextures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"getTextWidth","operator":null,"title":"getTextWidth","type":"command","url":"https://community.bistudio.com/wiki/getTextWidth","revid":376640,"updated":"2025-11-01T20:58:51Z","groups":["GUI Control","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.98"}],"since":{"game":"arma3","name":"Arma 3","version":"1.98"},"arma3_since":"1.98","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns estimated width of the text based on font type and size. Similar to ctrlTextWidth but does not require a control and can be used to estimate text width for any control including buttons. Result does not include left and right margins (hardcoded at 0.008 each).\n\n> [!NOTE]\n> This command always uses unicode (see also forceUnicode).","syntaxes":[{"syntax":"text getTextWidth [font, size]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"text string to measure","types":["String"],"since":null,"text":"text: String - text string to measure"},{"name":"font","type":"String","optional":true,"default":"\"\" (system font)","description":"font type","types":["String"],"since":null,"text":"font: String - (Optional since Arma 3 v2.22, default \"\" (system font)) font type"},{"name":"size","type":"Number","optional":true,"default":"-1 (system font size)","description":"font size","types":["Number"],"since":null,"text":"size: Number - (Optional since Arma 3 v2.22, default -1 (system font size)) font size"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"text","types":["String"]},"right":{"text":"[font, size]","types":["Array"]}}],"examples":[{"text":"```sqf\n_textWidth = \"Hello World\" getTextWidth [\"PuristaMedium\", 0.03];\n```","code":["_textWidth = \"Hello World\" getTextWidth [\"PuristaMedium\", 0.03];"]},{"text":"```sqf\n_textWidthInclMargins = (\"Hello World\" getTextWidth [\"PuristaMedium\", 0.03]) + 0.016;\n```","code":["_textWidthInclMargins = (\"Hello World\" getTextWidth [\"PuristaMedium\", 0.03]) + 0.016;"]},{"text":"```sqf\n#define MARGINS 0.016\nprivate _ctrl = findDisplay 46 ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetText \"TestString\";\n_ctrl ctrlSetFont \"PuristaMedium\";\n_ctrl ctrlSetFontHeight 0.04;\nctrlTextWidth _ctrl == (\"TestString\" getTextWidth [\"PuristaMedium\", 0.04]) + MARGINS; // true\n```","code":["#define MARGINS 0.016\nprivate _ctrl = findDisplay 46 ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetText \"TestString\";\n_ctrl ctrlSetFont \"PuristaMedium\";\n_ctrl ctrlSetFontHeight 0.04;\nctrlTextWidth _ctrl == (\"TestString\" getTextWidth [\"PuristaMedium\", 0.04]) + MARGINS; // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlTextWidth"],"notes":[{"user":"R3vo","date":"2020-10-28T22:10:00Z","text":"When working with multiline controls ctrlTextWidth or getTextWidth will not return a proper value since the text will be treated as one long line.\n\n**Solution (Execute in Eden Editor):**\n\n```sqf\ndisableSerialization;\n\nprivate _display = findDisplay 313 createDisplay \"RscDisplayEmpty\";\n\nprivate _edit = _display ctrlCreate [\"RscEditMulti\", -1];\n_edit ctrlSetPosition [0,0,1,1];\n_edit ctrlSetBackgroundColor [0,0,0,1];\n_edit ctrlSetFont \"EtelkaMonospacePro\";\n_edit ctrlSetFontHeight 0.03;\n_edit ctrlCommit 0;\n\nprivate _longestLineWidth = 0;\nprivate _exampleString = \"abcdefghijklmnopqrstuvxyz0134567890\";\nprivate _text = \"\";\n\nfor \"_lines\" from 1 to 400 do // loop through all lines and find the longest one\n{\n    _lineText = _exampleString select [round random 35];\n    _longestLineWidth = _longestLineWidth max (_lineText getTextWidth [\"EtelkaMonospacePro\", 0.03]);\n    _text = _text + _lineText + endl;\n};\n\n_edit ctrlSetPositionW (_longestLineWidth + 2 * 0.008); // width of longest line + left and right margin set in engine\n_edit ctrlCommit 0;\n_edit ctrlSetText _text;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Strings","Introduced with Arma 3 version 1.98","Scripting Commands"]},{"name":"getTIParameters","operator":null,"title":"getTIParameters","type":"command","url":"https://community.bistudio.com/wiki/getTIParameters","revid":378062,"updated":"2026-02-05T14:11:50Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all Thermal Imaging parameters.\n\n| Parameter | Default Value | Description |\n|---|---|---|\n| `OutputRangeStart` | 0.1 | Thermal output minimal value |\n| `OutputRangeWidth` | 0.8 | Thermal output width |\n| `FilmGrain` | 1 | Film grain |\n| `Blur` | 1 | Blur |\n| `UpdateHistogram` | 1 | Histogram |\n| Arma 3 v2.20 `MaxResolution` | -1 | Maximum vertical resolution |\n\n> [!NOTE]\n> - The output formula is as follows: `OutputRangeStart + *thermalValue* × OutputRangeWidth`, making the default range 0.1..0.9.\n> - Arma 3 v2.20 The `MaxResolution` setting takes into account the aspect ratio of the screen. A value of 1080 on a 16:9 screen provides a resolution of 1920×1080.","syntaxes":[{"syntax":"getTIParameters","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["HashMap"],"description":null,"text":"HashMap format `[[\"OutputRangeStart\", 0.1], [\"OutputRangeWidth\", 0.8]]`"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (getTIParameters get \"OutputRangeStart\" == 0.1) then { hint \"default Start\" };\n```","code":["if (getTIParameters get \"OutputRangeStart\" == 0.1) then { hint \"default Start\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTIParameter","setCamUseTI","disableTIEquipment"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getTotalDLCUsageTime","operator":null,"title":"getTotalDLCUsageTime","type":"command","url":"https://community.bistudio.com/wiki/getTotalDLCUsageTime","revid":310770,"updated":"2022-05-07T20:21:43Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns total DLC usage time in this game session","syntaxes":[{"syntax":"getTotalDLCUsageTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"time (in seconds?)","text":"Number - time (in seconds?)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_dlcTime = getTotalDLCUsageTime;\n```","code":["_dlcTime = getTotalDLCUsageTime;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"getTowParent","operator":null,"title":"getTowParent","type":"command","url":"https://community.bistudio.com/wiki/getTowParent","revid":377973,"updated":"2026-01-19T17:39:21Z","groups":["PhysX","Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Get the vehicle towing the provided one.","syntaxes":[{"syntax":"getTowParent towedVehicle","since":null,"effect":null,"exec":null,"params":[{"name":"towedVehicle","type":"Object","optional":false,"default":null,"description":"the towed vehicle","types":["Object"],"since":null,"text":"towedVehicle: Object - the towed vehicle"}],"returns":{"type":"Object","types":["Object"],"description":"the object towing the provided object - objNull if not towed","text":"Object - the object towing the provided object - objNull if not towed"},"form":"unary","operator":null,"left":null,"right":{"text":"towedVehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _towParent = getTowParent _towedVehicle;\n```","code":["private _towParent = getTowParent _towedVehicle;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTowParent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getTrimOffsetRTD","operator":null,"title":"getTrimOffsetRTD","type":"command","url":"https://community.bistudio.com/wiki/getTrimOffsetRTD","revid":348915,"updated":"2023-11-08T14:44:04Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns controls trim offset.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"getTrimOffsetRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":"helicopter with advanced flight model enabled","types":["Object"],"since":null,"text":"RTD_helicopter: Object - helicopter with advanced flight model enabled"}],"returns":{"type":"Array","types":["Array"],"description":"offsets in format [x,y,z]","text":"Array - offsets in format [x,y,z]"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_array = getTrimOffsetRTD vehicle player;\n```","code":["_array = getTrimOffsetRTD vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Advanced Helicopter Flight Model in Arma3"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"getTurretLimits","operator":null,"title":"getTurretLimits","type":"command","url":"https://community.bistudio.com/wiki/getTurretLimits","revid":377851,"updated":"2026-01-03T11:52:28Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the rotation and elevation limits for the given turret.","syntaxes":[{"syntax":"vehicle getTurretLimits turret","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle the turret belongs to","types":["Object"],"since":null,"text":"vehicle: Object - vehicle the turret belongs to"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turret: Turret Path"}],"returns":{"type":"Array with [minTurn, maxTurn, minElev, maxElev, overridden]","types":["Array"],"description":"minTurn: Number - from 0 to -angle in degrees (left) - maxTurn: Number - from 0 to +angle in degrees (right) - minElev: Number - from 0 to -angle in degrees (down) - maxElev: Number - from 0 to +angle in degrees (up) - overridden: Boolean - if custom limits were applied","text":"Array with [minTurn, maxTurn, minElev, maxElev, overridden]\n- minTurn: Number - from 0 to -angle in degrees (left)\n- maxTurn: Number - from 0 to +angle in degrees (right)\n- minElev: Number - from 0 to -angle in degrees (down)\n- maxElev: Number - from 0 to +angle in degrees (up)\n- overridden: Boolean - if custom limits were applied"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turret","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nprivate _turretLimits = m2 getTurretLimits [0];\n_turretLimits params [\"_minTurn\", \"_maxTurn\", \"_minElev\", \"_maxElev\", \"_overridden\"];\n```","code":["private _turretLimits = m2 getTurretLimits [0];\n_turretLimits params [\"_minTurn\", \"_maxTurn\", \"_minElev\", \"_maxElev\", \"_overridden\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTurretLimits","setTurretOpticsMode","turretLocal","selectWeaponTurret"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getTurretOpticsMode","operator":null,"title":"getTurretOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/getTurretOpticsMode","revid":377480,"updated":"2026-01-02T06:48:55Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Get the current optics mode of the optics in the turret occupied by the specified unit. The alternative syntax allows a vehicle and turret path to be specified without needing a unit. Optic modes refer to the different fields of view (FOV) or zoom levels of an optic.","syntaxes":[{"syntax":"getTurretOpticsMode obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}},{"syntax":"obj getTurretOpticsMode turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\ngetTurretOpticsMode player;\n```","code":["getTurretOpticsMode player;"]},{"text":"```sqf\nmyTank getTurretOpticsMode [-1];\n```","code":["myTank getTurretOpticsMode [-1];"]},{"text":"```sqf\nmyAircraft getTurretOpticsMode [0, 0];\n```","code":["myAircraft getTurretOpticsMode [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTurretOpticsMode","turretOwner","getPilotCameraOpticsMode","setPilotCameraOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getUnitFreefallInfo","operator":null,"title":"getUnitFreefallInfo","type":"command","url":"https://community.bistudio.com/wiki/getUnitFreefallInfo","revid":377879,"updated":"2026-01-04T16:08:21Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns a unit's freefall information.","syntaxes":[{"syntax":"getUnitFreefallInfo unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"}],"returns":{"type":"Array with [isFalling, isInFreefallPose, minFreefallHeight]","types":["Array"],"description":"isFalling: Boolean - true if unit is falling - isInFreefallPose: Boolean - true if unit is in freefall pose - minFreefallHeight: Number - current minimum freefall height (see setUnitFreefallHeight)","text":"Array with [isFalling, isInFreefallPose, minFreefallHeight]\n- isFalling: Boolean - true if unit is falling\n- isInFreefallPose: Boolean - true if unit is in freefall pose\n- minFreefallHeight: Number - current minimum freefall height (see setUnitFreefallHeight)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\ngetUnitFreefallInfo player;\n```","code":["getUnitFreefallInfo player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitFreefallHeight","getUserInfo","getModelInfo"],"notes":[{"user":"Sa-Matra","date":"2023-05-08T04:26:25Z","text":"Note that command is supposed to be used on local units. When used  on a remote unit, its return (isFalling) is unreliable and sometimes returns wrong values."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"getUnitLoadout","operator":null,"title":"getUnitLoadout","type":"command","url":"https://community.bistudio.com/wiki/getUnitLoadout","revid":377568,"updated":"2026-01-02T06:55:51Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a **Unit Loadout Array** with all assigned items, weapons, containers and their stored items.\n\n> [!NOTE]\n> The config should contain the following standard entries:\n>\n> ```cpp\n> class MyLoadout\n> {\n>     uniformClass = \"U_B_CombatUniform_mcam\";\n>     backpack = \"B_AssaultPack_mcamo\";\n>     linkedItems[] = { \"V_PlateCarrier1_rgr\", \"H_HelmetB\", \"ItemCompass\", \"ItemWatch\", \"ItemRadio\", \"NVGoggles\" };\n>     weapons[] = { \"arifle_MX_ACO_pointer_F\", \"hgun_P07_F\" };\n>     items[] = { \"FirstAidKit\", \"FirstAidKit\", \"FirstAidKit\" };\n>     magazines[] = {\n>         \"30Rnd_65x39_caseless_mag\", \"16Rnd_9x21_Mag\",\n>         \"SmokeShell\",\n>         \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n>         \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n>         \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\"\n>     };\n> };\n> ```","syntaxes":[{"syntax":"getUnitLoadout unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Unit Loadout Array","types":["Unit Loadout Array"],"description":null,"text":"Unit Loadout Array"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"getUnitLoadout [unit, fullMagazines]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"fullMagazines","type":"Boolean","optional":false,"default":null,"description":"true to top up used magazines","types":["Boolean"],"since":null,"text":"fullMagazines: Boolean - true to top up used magazines"}],"returns":{"type":"Unit Loadout Array","types":["Unit Loadout Array"],"description":null,"text":"Unit Loadout Array"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, fullMagazines]","types":["Array"]}},{"syntax":"getUnitLoadout name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"`CfgVehicles` classname from which to extract the loadout","types":["String"],"since":null,"text":"name: String - `CfgVehicles` classname from which to extract the loadout"}],"returns":{"type":"Unit Loadout Array","types":["Unit Loadout Array"],"description":null,"text":"Unit Loadout Array"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}},{"syntax":"getUnitLoadout config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"loadout config class","types":["Config"],"since":null,"text":"config: Config - loadout config class"}],"returns":{"type":"Unit Loadout Array","types":["Unit Loadout Array"],"description":null,"text":"Unit Loadout Array"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\ngetUnitLoadout player;\n```","code":["getUnitLoadout player;"]},{"text":"```sqf\ngetUnitLoadout [player, true];\n```","code":["getUnitLoadout [player, true];"]},{"text":"```sqf\ngetUnitLoadout \"B_Soldier_F\";\n```","code":["getUnitLoadout \"B_Soldier_F\";"]},{"text":"```sqf\ngetUnitLoadout (configFile >> \"CfgVehicles\" >> \"B_Soldier_F\");\n```","code":["getUnitLoadout (configFile >> \"CfgVehicles\" >> \"B_Soldier_F\");"]},{"text":"```sqf\ngetUnitLoadout (missionConfigFile >> \"MyLoadout\");\n```","code":["getUnitLoadout (missionConfigFile >> \"MyLoadout\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"getUnitMovesInfo","operator":null,"title":"getUnitMovesInfo","type":"command","url":"https://community.bistudio.com/wiki/getUnitMovesInfo","revid":378281,"updated":"2026-03-31T10:06:54Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns various information about the unit moves (primary animation) and gestures (masked animation)\n\n> [!NOTE]\n> Up until Arma 3 v2.20 this command only worked for a man unit, and other units such as animals couldn't use this command. As of Arma 3 v2.22 animals are supported as well.","syntaxes":[{"syntax":"getUnitMovesInfo unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array format:","types":["Array"],"description":"0 - moveProgress: Number - move progress in range 0-1 - 1 - moveTime: Number - move elapsed time (`move progress * move duration`) - 2 - moveDuration: Number - move duration in seconds - 3 - moveFactor: Number - move blend factor - 4 - rtmStep: Vector3D - rtm step (how many meters the unit will move after finishing the animation) - 5 - gestureProgress: Number - gesture progress in range 0-1 - 6 - gestureTime: Number - gesture elapsed time (`gesture progress * gesture duration`) - 7 - gestureDuration: Number - gesture duration in seconds - 8 - gestureFactor: Number - gesture blend factor","text":"Array format:\n- 0 - moveProgress: Number - move progress in range 0-1\n- 1 - moveTime: Number - move elapsed time (`move progress * move duration`)\n- 2 - moveDuration: Number - move duration in seconds\n- 3 - moveFactor: Number - move blend factor\n- 4 - rtmStep: Vector3D - rtm step (how many meters the unit will move after finishing the animation)\n- 5 - gestureProgress: Number - gesture progress in range 0-1\n- 6 - gestureTime: Number - gesture elapsed time (`gesture progress * gesture duration`)\n- 7 - gestureDuration: Number - gesture duration in seconds\n- 8 - gestureFactor: Number - gesture blend factor"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"unit getUnitMovesInfo index","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index of property from the main syntax","types":["Number"],"since":null,"text":"index: Number - index of property from the main syntax"}],"returns":{"type":"Anything","types":["Anything"],"description":"Value of the requested property, or Nothing if index is invalid. See the main syntax.","text":"Anything - Value of the requested property, or Nothing if index is invalid. See the main syntax."},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n// Getting the move velocity of the animation\nprivate _animInfo = getUnitMovesInfo player;\n// velocity = displacement / time\nprivate _animVelocity = _animInfo # 4 vectorMultiply -1 / _animInfo # 2;    // -1 is because man model is reversed\n                                                                            // so the rtm animation moves \"backwards\"\n```","code":["// Getting the move velocity of the animation\nprivate _animInfo = getUnitMovesInfo player;\n// velocity = displacement / time\nprivate _animVelocity = _animInfo # 4 vectorMultiply -1 / _animInfo # 2;\t// -1 is because man model is reversed\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// so the rtm animation moves \"backwards\""]},{"text":"```sqf\ngetUnitMovesInfo player params [\n    \"_moveProgress\",\n    \"_moveTime\",\n    \"_moveDuration\",\n    \"_moveFactor\",\n    \"_rtmStep\",\n    \"_gestureProgress\",\n    \"_gestureTime\",\n    \"_gestureDuration\",\n    \"_gestureFactor\"\n];\n```","code":["getUnitMovesInfo player params [\n\t\"_moveProgress\",\n\t\"_moveTime\",\n\t\"_moveDuration\",\n\t\"_moveFactor\",\n\t\"_rtmStep\",\n\t\"_gestureProgress\",\n\t\"_gestureTime\",\n\t\"_gestureDuration\",\n\t\"_gestureFactor\"\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchMove","switchGesture","moveTime","gestureState","animationState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getUnitState","operator":null,"title":"getUnitState","type":"command","url":"https://community.bistudio.com/wiki/getUnitState","revid":369978,"updated":"2024-10-22T13:15:33Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns current state of the given AI unit, which could be one of the following:\n- \"WAIT\" - another plan is needed (current partial plan was done or is not present)\n- \"INIT\" - operative planing should start, endpoint is set\n- \"INITFAILED\" - init failed because data are not ready\n- \"BUSY\" - operative plan ready and valid\n- \"OK\" - completed whole strategic plan\n- \"DELAY\" - repeat search, usually when failed\n- \"CARGO\" - unit is in vehicle cargo, no planning needed\n- \"STOPPING\" - unit is stopping (usually because of getin/getout request/landing)\n- \"REPLAN\" - we have a plan, but we would like to search a new one\n- \"STOPPED\" - unit is stopped, no planning needed (also landed. Different from stop command)\n- \"PLANNING\" - operative planning pending","syntaxes":[{"syntax":"getUnitState unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"unit state (see description)","text":"String - unit state (see description)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_state = getUnitState bob; //\"WAIT\"\n```","code":["_state = getUnitState bob; //\"WAIT\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableAI","enableAI","checkAIFeature","enableAIFeature","vehicleMoveInfo","expectedDestination"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"getUnitTrait","operator":null,"title":"getUnitTrait","type":"command","url":"https://community.bistudio.com/wiki/getUnitTrait","revid":347973,"updated":"2023-11-08T09:46:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets the current value of a trait of the given unit.\n\n> [!NOTE]\n> For the default values see setUnitTrait.","syntaxes":[{"syntax":"unit getUnitTrait skillName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skillName","type":"String","optional":false,"default":null,"description":"name of the skill","types":["String"],"since":null,"text":"skillName: String - name of the skill"}],"returns":{"type":"- Boolean or Number","types":["Boolean","Number"],"description":"trait's value - Nothing - if unit is invalid, e.g an empty vehicle","text":"- Boolean or Number - trait's value\n- Nothing - if *unit* is invalid, e.g an empty vehicle"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"skillName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer getUnitTrait \"Medic\";\n```","code":["player getUnitTrait \"Medic\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitTrait","getAllUnitTraits"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"getUnloadInCombat","operator":null,"title":"getUnloadInCombat","type":"command","url":"https://community.bistudio.com/wiki/getUnloadInCombat","revid":377617,"updated":"2026-01-02T08:51:47Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setUnloadInCombat. To return global config value see canUnloadInCombat","syntaxes":[{"syntax":"getUnloadInCombat vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array with [cargo, turrets]","types":["Array"],"description":null,"text":"Array with [cargo, turrets]"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetUnloadInCombat _vehicle params [\"_cargo\", \"_turrets\"];\n```","code":["getUnloadInCombat _vehicle params [\"_cargo\", \"_turrets\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnloadInCombat","canUnloadInCombat"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getUserInfo","operator":null,"title":"getUserInfo","type":"command","url":"https://community.bistudio.com/wiki/getUserInfo","revid":378191,"updated":"2026-03-10T18:34:18Z","groups":["Multiplayer","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Returns extended information about given server user.","syntaxes":[{"syntax":"getUserInfo playerID","since":null,"effect":null,"exec":null,"params":[{"name":"playerID","type":"String","optional":false,"default":null,"description":"user DirectPlay ID (see getPlayerID, PlayerConnected)","types":["String"],"since":null,"text":"playerID: String - user DirectPlay ID (see getPlayerID, PlayerConnected)"}],"returns":{"type":"Array with [playerID, owner, playerUID, soldierName, displayName, steamProfileName, clientStateNumber, isHeadless, adminState, networkInfo, playerObject]","types":["Array"],"description":"0 - playerID: String - user DirectPlay ID (see getPlayerID, PlayerConnected) - 1 - owner: Number - user owner (see owner) - 2 - playerUID: String - player UID (see getPlayerUID) - 3 - soldierName: String - player name (see profileName) - 4 - displayName: String - player name including squad (see name, squadParams) - 5 - steamProfileName: String - returns the current machine's Steam profile name (see profileNameSteam), not the targeted player's Steam profile name - 6 - clientStateNumber: String user client state (see getClientStateNumber) - 7 - isHeadless: Boolean - whether or not this is a headless client (see hasInterface, isServer) - 8 - adminState: Number - admin status of the user (see admin) - 9 - networkInfo: Array of Numbers - format [ping, bandwidth, desync] - 10 - playerObject: Object - user player entity (see player, selectPlayer) > [!NOTE] > Returns an empty array if said player is not found.","text":"Array with [playerID, owner, playerUID, soldierName, displayName, steamProfileName, clientStateNumber, isHeadless, adminState, networkInfo, playerObject]\n- 0 - playerID: String - user DirectPlay ID (see getPlayerID, PlayerConnected)\n- 1 - owner: Number - user owner (see owner)\n- 2 - playerUID: String - player UID (see getPlayerUID)\n- 3 - soldierName: String - player name (see profileName)\n- 4 - displayName: String - player name including squad (see name, squadParams)\n- 5 - steamProfileName: String - returns the *current machine's* Steam profile name (see profileNameSteam), **not** the targeted player's Steam profile name\n- 6 - clientStateNumber: String user client state (see getClientStateNumber)\n- 7 - isHeadless: Boolean - whether or not this is a headless client (see hasInterface, isServer)\n- 8 - adminState: Number - admin status of the user (see admin)\n- 9 - networkInfo: Array of Numbers - format [ping, bandwidth, desync]\n- 10 - playerObject: Object - user player entity (see player, selectPlayer)\n\n> [!NOTE]\n> Returns an empty array if said player is not found."},"form":"unary","operator":null,"left":null,"right":{"text":"playerID","types":["String"]}},{"syntax":"playerID getUserInfo infoIndex","since":"Arma3 2.18","effect":null,"exec":null,"params":[{"name":"playerID","type":"String","optional":false,"default":null,"description":"user DirectPlay ID (see getPlayerID, PlayerConnected)","types":["String"],"since":null,"text":"playerID: String - user DirectPlay ID (see getPlayerID, PlayerConnected)"},{"name":"infoIndex","type":"Number","optional":false,"default":null,"description":"the index of the data in the return array (see main syntax)","types":["Number"],"since":null,"text":"infoIndex: Number - the index of the data in the return array (see main syntax)"}],"returns":{"type":"Anything","types":["Anything"],"description":"depends on the requested index (see main syntax) or Nothing","text":"Anything - depends on the requested index (see main syntax) or Nothing"},"form":"binary","operator":null,"left":{"text":"playerID","types":["String"]},"right":{"text":"infoIndex","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _randomUserInfo = getUserInfo selectRandom allUsers;\n```","code":["private _randomUserInfo = getUserInfo selectRandom allUsers;"]},{"text":"```sqf\n_userInfo params [\"_playerID\", \"_ownerId\", \"_playerUID\", \"_profileName\", \"_displayName\", \"_steamName\", \"_clientState\", \"_isHC\", \"_adminState\", \"_networkInfo\", \"_unit\"];\n_networkInfo params [\"_avgPing\", \"_avgBandwidth\", \"_desync\"];\n```","code":["_userInfo params [\"_playerID\", \"_ownerId\", \"_playerUID\", \"_profileName\", \"_displayName\", \"_steamName\", \"_clientState\", \"_isHC\", \"_adminState\", \"_networkInfo\", \"_unit\"];\n_networkInfo params [\"_avgPing\", \"_avgBandwidth\", \"_desync\"];"]},{"text":"```sqf\nprivate _myInfo = getUserInfo getPlayerID player; // this particular example only works if player is server host\n```","code":["private _myInfo = getUserInfo getPlayerID player; // this particular example only works if player is server host"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUsers","getPlayerID","getUnitFreefallInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Detection","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"getUserMFDText","operator":null,"title":"getUserMFDText","type":"command","url":"https://community.bistudio.com/wiki/getUserMFDText","revid":309231,"updated":"2022-05-04T10:19:29Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of user text variables used in MFD.","syntaxes":[{"syntax":"getUserMFDText vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetUserMFDText _vehicle;\n```","code":["getUserMFDText _vehicle;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUserMFDText","setUserMFDValue","getUserMFDValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.78","Scripting Commands"]},{"name":"getUserMFDValue","operator":null,"title":"getUserMFDValue","type":"command","url":"https://community.bistudio.com/wiki/getUserMFDValue","revid":310918,"updated":"2022-05-07T20:39:37Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of user text variables used in MFD.","syntaxes":[{"syntax":"getUserMFDValue vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a vehicle with MFD","types":["Object"],"since":null,"text":"vehicle: Object - a vehicle with MFD"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetUserMFDValue vehicle player; // user0 in MFD will return 1\n```","code":["getUserMFDValue vehicle player; // user0 in MFD will return 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUserMFDValue","setUserMFDText","getUserMFDText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"getVariable","operator":null,"title":"getVariable","type":"command","url":"https://community.bistudio.com/wiki/getVariable","revid":369203,"updated":"2024-09-03T10:34:50Z","groups":["Variables","Namespaces","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the value of variable in the variable space assigned to various data types.\nAll available data types combinations:\n\n| Primary syntax (String) | Alternative syntax (Array) |  |  |\n|---|---|---|---|\n| **Code** | **Since** | **Code** | **Since** |\n| Namespace getVariable String | - | Namespace getVariable Array | Arma 2: Operation Arrowhead v1.60 |\n| Object getVariable String | - | Object getVariable Array | - |\n| Group getVariable String | - | Group getVariable Array | - |\n| Team Member getVariable String | - | Team Member getVariable Array | - |\n| Task getVariable String | - | Task getVariable Array | Arma 3 v1.68 |\n| Location getVariable String | - | Location getVariable Array | Arma 3 v1.68 |\n| Control getVariable String | - | Control getVariable Array | Arma 3 v1.56 |\n| Display getVariable String | Arma 3 v1.56 | Display getVariable Array | Arma 3 v1.56 |\n\n> [!IMPORTANT]\n> When variable is set on a Task, it is not actually set on the task itself, but on the FSM attached to the task.\n>\n> If there is no FSM, getVariable will not work.\n\n> [!NOTE]\n> **Arma 3:** In the case of Alt Syntax usage in Arma 3, *defaultValue* will be returned if:\n> - Requested variable is either undefined or nil\n> - Variable namespace is null (objNull, grpNull, etc.)","syntaxes":[{"syntax":"varspace getVariable name","since":null,"effect":null,"exec":null,"params":[{"name":"varspace","type":null,"optional":false,"default":null,"description":"Namespace, Object, Display, Control, Group, Location, Task, Team Member, Display, Control","types":["Namespace","Object","Display","Control","Group","Location","Task","Team Member"],"since":null,"text":"varspace: Namespace, Object, Display, Control, Group, Location, Task, Team Member, Display, Control"},{"name":"name","type":"String","optional":false,"default":null,"description":"variable name in given namespace","types":["String"],"since":null,"text":"name: String - variable name in given namespace"}],"returns":{"type":"Anything or Nothing if the variable doesn't exist","types":["Anything","Nothing"],"description":null,"text":"Anything or Nothing if the variable doesn't exist"},"form":"binary","operator":null,"left":{"text":"varspace","types":["Namespace","Object","Display","Control","Group","Location","Task","Team Member"]},"right":{"text":"name","types":["String"]}},{"syntax":"varspace getVariable [name, defaultValue]","since":null,"effect":null,"exec":null,"params":[{"name":"varspace","type":null,"optional":false,"default":null,"description":"Namespace, Object, Display, Control, Group, Location, Task, Team Member, Display, Control","types":["Namespace","Object","Display","Control","Group","Location","Task","Team Member"],"since":null,"text":"varspace: Namespace, Object, Display, Control, Group, Location, Task, Team Member, Display, Control"},{"name":"name","type":"String","optional":false,"default":null,"description":"variable name in given namespace","types":["String"],"since":null,"text":"name: String - variable name in given namespace"},{"name":"defaultValue","type":"Anything","optional":false,"default":null,"description":"value to return if variable doesn't exist \n\n> [!WARNING]\n> A dynamic *defaultValue* e.g `random 500` will always be executed, even if the variable is defined.","types":["Anything"],"since":null,"text":"defaultValue: Anything - value to return if variable doesn't exist \n\n> [!WARNING]\n> A dynamic *defaultValue* e.g `random 500` will always be executed, even if the variable is defined."}],"returns":{"type":"Anything","types":["Anything"],"description":"current value of the variable or defaultValue if the variable doesn't exist.","text":"Anything - current value of the variable or *defaultValue* if the variable doesn't exist."},"form":"binary","operator":null,"left":{"text":"varspace","types":["Namespace","Object","Display","Control","Group","Location","Task","Team Member"]},"right":{"text":"[name, defaultValue]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _variable = myTruck getVariable \"myVariable\"; // returns nil if \"myVariable\" is not set\n```","code":["private _variable = myTruck getVariable \"myVariable\"; // returns nil if \"myVariable\" is not set"]},{"text":"```sqf\nprivate _variable = myTruck getVariable [\"myVariable\", 50]; // returns 50 if \"myVariable\" is not set\n```","code":["private _variable = myTruck getVariable [\"myVariable\", 50]; // returns 50 if \"myVariable\" is not set"]},{"text":"```sqf\nfor \"_i\" from 0 to 5 do\n{\n    _car = missionNamespace getVariable (\"car\" + str _i);\n    _car setDamage 0;\n}; // Set damage of car0..car5 to 0\n```","code":["for \"_i\" from 0 to 5 do\n{\n\t_car = missionNamespace getVariable (\"car\" + str _i);\n\t_car setDamage 0;\n}; // Set damage of car0..car5 to 0"]},{"text":"```sqf\nmyMissionVar = 2015;\nmissionNamespace getVariable \"myMissionVar\"; // returns 2015\n```","code":["myMissionVar = 2015;\nmissionNamespace getVariable \"myMissionVar\"; // returns 2015"]},{"text":"Get current value of a variable and if it is undefined, define it and get the defined value:\n\n```sqf\nprivate _var = missionNamespace getVariable \"varName\";\nif (isNil \"_var\") then\n{\n    missionNamespace setVariable [\"varName\", 123];\n    _var = 123;\n};\n// _var here will contain current value of the variable varName\n```","code":["private _var = missionNamespace getVariable \"varName\";\nif (isNil \"_var\") then\n{\n\tmissionNamespace setVariable [\"varName\", 123];\n\t_var = 123;\n};\n// _var here will contain current value of the variable varName"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVariable","allVariables","getFSMVariable"],"notes":[{"user":"Ebay","date":"2016-08-13T17:13:00Z","text":"**NOTE: Arma 2 only! In Arma 3 this will return default value:**\nWarning: the alternative syntax returns undefined when the namespace is an object and that object is null. Example:\n\n```sqf\n_test = objNull getVariable [\"test\", \"0\"];\nsystemChat _test;\n```\n\nErrors because _test is undefined. Tested in Arma 2: Operation Arrowhead 1.63.131129"},{"user":"AgentRev","date":"2017-08-31T03:29:00Z","text":"You can do typechecking using param:\n\n```sqf\nprivate _myVar = [player getVariable \"myVar\"] param [0, \"\", [\"\"]];\n```\n\nand params:\n\n```sqf\n[player getVariable \"myVar\"] params [[\"_myVar\", \"\", [\"\"]]];\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Namespaces","Command Group: Variables","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getVehicleCargo","operator":null,"title":"getVehicleCargo","type":"command","url":"https://community.bistudio.com/wiki/getVehicleCargo","revid":330010,"updated":"2022-08-14T12:55:01Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Get a list of vehicles loaded as cargo inside this vehicle. The returned array is in the order the cargo vehicles were added to containing vehicle.","syntaxes":[{"syntax":"getVehicleCargo storingVehicle","since":null,"effect":null,"exec":null,"params":[{"name":"storingVehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"storingVehicle: Object"}],"returns":{"type":"Array","types":["Array"],"description":"vehicles loaded in storingVehicle, in order of their loading","text":"Array - vehicles loaded in storingVehicle, in order of their loading"},"form":"unary","operator":null,"left":null,"right":{"text":"storingVehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_vehicleCargo = getVehicleCargo blackfish; // returns [] if empty\n```","code":["_vehicleCargo = getVehicleCargo blackfish; // returns [] if empty"]},{"text":"```sqf\n_vehicleCargo = getVehicleCargo blackfish; // returns [quad_3, quad_1, quad_2] as they were loaded in this order\n```","code":["_vehicleCargo = getVehicleCargo blackfish; // returns [quad_3, quad_1, quad_2] as they were loaded in this order"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle in Vehicle Transport","canVehicleCargo","setVehicleCargo","enableVehicleCargo","isVehicleCargo","vehicleCargoEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"getVehicleTIPars","operator":null,"title":"getVehicleTIPars","type":"command","url":"https://community.bistudio.com/wiki/getVehicleTIPars","revid":377635,"updated":"2026-01-02T08:52:29Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns TI parameters of a vehicle.","syntaxes":[{"syntax":"getVehicleTIPars vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array with [aliveFactor, movementFactor, metabolismFactor]","types":["Array"],"description":null,"text":"Array with [aliveFactor, movementFactor, metabolismFactor]"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngetVehicleTIPars _veh;\n```","code":["getVehicleTIPars _veh;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleTIPars"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"getVideoOptions","operator":null,"title":"getVideoOptions","type":"command","url":"https://community.bistudio.com/wiki/getVideoOptions","revid":376476,"updated":"2025-10-17T09:37:32Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Obtain the current system's video settings.","syntaxes":[{"syntax":"getVideoOptions","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"HashMap","types":["HashMap"],"description":"all video settings, the key is always a String, the value can be a String, Number, Boolean or Array (see #Example 1). > [!IMPORTANT] > `vramInfo` and `monitorResolution` keys presence is not guaranteed.","text":"HashMap - all video settings, the key is always a String, the value can be a String, Number, Boolean or Array (see #Example 1).\n\n> [!IMPORTANT]\n> `vramInfo` and `monitorResolution` keys presence is not guaranteed."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _videoOptions = getVideoOptions;\n/*\n[\n    [\"aspectRatioName\", \"Auto (Stretch)\"],\n    [\"brightness\", 1.1],\n    [\"cloudQualityName\", \"VeryHigh\"],\n    [\"displayModeName\", \"FullScreenWindow\"],\n    [\"dynLightsCount\", 32],\n    [\"dynLightsQualityName\", \"VeryHigh\"],\n    [\"gamma\", 1],\n    [\"guiScale\", 0.7],\n    [\"guiScaleName\", \"Normal\"],\n    [\"hdrQuality\", 16],\n    [\"hdrQualityName\", \"Normal\"],\n    [\"monitorResolution\", [0, 0, 2304, 1440]],                            // presence not guaranteed [x, y, width, height]\n    [\"objectVisibility\", 6000],\n    [\"objQualityName\", \"VeryHigh\"],\n    [\"overallPresetName\", \"Custom\"],\n    [\"overallVisibility\", 8000],\n    [\"overrideHazeQuality\", -1],\n    [\"particleQualityName\", \"High\"],\n    [\"pipQuality\", 2048],\n    [\"pipQualityName\", \"VeryHigh\"],\n    [\"pipVisibility\", 3000],\n    [\"ppBloom\", 1],\n    [\"ppBrightness\", 1],\n    [\"ppCausticsQualityName\",\"Enabled\"],                                // fixed in 2.18\n    [\"anisotropicFiltering\",\"VeryHigh\"],                                // fixed in 2.18\n    [\"atocQuality\",\"All\"],                                                // fixed in 2.18\n    [\"ppColorPresetName\", \"Custom\"],\n    [\"ppContrast\", 1],\n    [\"ppDOF\", 1],\n    [\"ppFSAA\", 1],\n    [\"ppHazeQualityName\", \"Standard\"],\n    [\"ppPPAAQualityName\", \"CMAANormal\"],\n    [\"ppRadialBlur\", 1],\n    [\"ppRotationBlur\", 1],\n    [\"ppSaturation\", 1.25],\n    [\"ppSharpenFilter\", 0.75],\n    [\"ppSSAOQualityName\", \"\"],\n    [\"refreshRate\", 60],\n    [\"samplingPercentage\", 100],\n    [\"shadowQualityName\", \"VeryHigh\"],\n    [\"shadowVisibility\", 200],\n    [\"terrainQuality\", 3.125],\n    [\"terrainQualityName\", \"VeryHigh\"],\n    [\"texQualityName\", \"VeryHigh\"],\n    [\"vramInfo\", [\"5.9 GiB\", \"16 GiB\", \"0 B\", \"978 MiB\", \"5.6 GiB\"]],    // presence not guaranteed [installedVram, sharedVram, systemVram(, used, max)]\n    [\"vsync\", true],\n    [\"waterReflectionQualityName\", \"High\"]\n]\n*/\n```","code":["private _videoOptions = getVideoOptions;\n/*\n[\n\t[\"aspectRatioName\", \"Auto (Stretch)\"],\n\t[\"brightness\", 1.1],\n\t[\"cloudQualityName\", \"VeryHigh\"],\n\t[\"displayModeName\", \"FullScreenWindow\"],\n\t[\"dynLightsCount\", 32],\n\t[\"dynLightsQualityName\", \"VeryHigh\"],\n\t[\"gamma\", 1],\n\t[\"guiScale\", 0.7],\n\t[\"guiScaleName\", \"Normal\"],\n\t[\"hdrQuality\", 16],\n\t[\"hdrQualityName\", \"Normal\"],\n\t[\"monitorResolution\", [0, 0, 2304, 1440]],\t\t\t\t\t\t\t// presence not guaranteed [x, y, width, height]\n\t[\"objectVisibility\", 6000],\n\t[\"objQualityName\", \"VeryHigh\"],\n\t[\"overallPresetName\", \"Custom\"],\n\t[\"overallVisibility\", 8000],\n\t[\"overrideHazeQuality\", -1],\n\t[\"particleQualityName\", \"High\"],\n\t[\"pipQuality\", 2048],\n\t[\"pipQualityName\", \"VeryHigh\"],\n\t[\"pipVisibility\", 3000],\n\t[\"ppBloom\", 1],\n\t[\"ppBrightness\", 1],\n\t[\"ppCausticsQualityName\",\"Enabled\"],\t\t\t\t\t\t\t\t// fixed in 2.18\n\t[\"anisotropicFiltering\",\"VeryHigh\"],\t\t\t\t\t\t\t\t// fixed in 2.18\n\t[\"atocQuality\",\"All\"],\t\t\t\t\t\t\t\t\t\t\t\t// fixed in 2.18\n\t[\"ppColorPresetName\", \"Custom\"],\n\t[\"ppContrast\", 1],\n\t[\"ppDOF\", 1],\n\t[\"ppFSAA\", 1],\n\t[\"ppHazeQualityName\", \"Standard\"],\n\t[\"ppPPAAQualityName\", \"CMAANormal\"],\n\t[\"ppRadialBlur\", 1],\n\t[\"ppRotationBlur\", 1],\n\t[\"ppSaturation\", 1.25],\n\t[\"ppSharpenFilter\", 0.75],\n\t[\"ppSSAOQualityName\", \"\"],\n\t[\"refreshRate\", 60],\n\t[\"samplingPercentage\", 100],\n\t[\"shadowQualityName\", \"VeryHigh\"],\n\t[\"shadowVisibility\", 200],\n\t[\"terrainQuality\", 3.125],\n\t[\"terrainQualityName\", \"VeryHigh\"],\n\t[\"texQualityName\", \"VeryHigh\"],\n\t[\"vramInfo\", [\"5.9 GiB\", \"16 GiB\", \"0 B\", \"978 MiB\", \"5.6 GiB\"]],\t// presence not guaranteed [installedVram, sharedVram, systemVram(, used, max)]\n\t[\"vsync\", true],\n\t[\"waterReflectionQualityName\", \"High\"]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getResolution","getAudioOptionVolumes","getSubtitleOptions","getMissionOptions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"getWaterFillPercentage","operator":null,"title":"getWaterFillPercentage","type":"command","url":"https://community.bistudio.com/wiki/getWaterFillPercentage","revid":363321,"updated":"2024-03-26T16:41:39Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Get an object's water filling.","syntaxes":[{"syntax":"getWaterFillPercentage obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"object to manipulate","types":["Object"],"since":null,"text":"obj: Object - object to manipulate"}],"returns":{"type":"Number","types":["Number"],"description":"water level in range 0..1 (empty to full)","text":"Number - water level in range 0..1 (empty to full)"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getWaterFillPercentage _myCar > 0) then\n{\n    hint \"My feet are wet.\";\n};\n```","code":["if (getWaterFillPercentage _myCar > 0) then\n{\n\thint \"My feet are wet.\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaterLeakiness","getWaterLeakiness","setWaterFillPercentage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"getWaterLeakiness","operator":null,"title":"getWaterLeakiness","type":"command","url":"https://community.bistudio.com/wiki/getWaterLeakiness","revid":378411,"updated":"2026-04-04T08:32:46Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get an object's water intake ratio when immersed.","syntaxes":[{"syntax":"getWaterLeakiness obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"object to check","types":["Object"],"since":null,"text":"obj: Object - object to check"}],"returns":{"type":"Number in range 0..1","types":["Number"],"description":"0 is waterproof and 1 is full leak","text":"Number in range 0..1 - 0 is waterproof and 1 is full leak"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nif (getWaterLeakiness _myCar > 0) then\n{\n    hint \"don't go in the water with it!\";\n};\n```","code":["if (getWaterLeakiness _myCar > 0) then\n{\n\thint \"don't go in the water with it!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaterLeakiness","setWaterFillPercentage","getWaterFillPercentage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands"]},{"name":"getWeaponCargo","operator":null,"title":"getWeaponCargo","type":"command","url":"https://community.bistudio.com/wiki/getWeaponCargo","revid":319293,"updated":"2022-05-13T09:23:30Z","groups":["Vehicle Inventory","Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.54"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all weapons types and count from the cargo space","syntaxes":[{"syntax":"getWeaponCargo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to check","types":["Object"],"since":null,"text":"object: Object - object to check"}],"returns":{"type":"Array","types":["Array"],"description":"format [all_types_array, all_counts_array]. Eg: [[\"a\", \"b\"], [3, 2]]","text":"Array - format [all_types_array, all_counts_array]. Eg: [[\"a\", \"b\"], [3, 2]]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_content = getWeaponCargo carName;\n```","code":["_content = getWeaponCargo carName;"]},{"text":"```sqf\n_content = getWeaponCargo ammoBoxName;\n```","code":["_content = getWeaponCargo ammoBoxName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponCargo","addWeaponCargo","addWeaponCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Vehicle Inventory","Introduced with Arma 2: Operation Arrowhead version 1.54","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getWeaponSway","operator":null,"title":"getWeaponSway","type":"command","url":"https://community.bistudio.com/wiki/getWeaponSway","revid":376211,"updated":"2025-09-15T15:00:52Z","groups":["Stamina System","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current size of weapon sway of a given unit, in radians. This command may still return a value greater 0 even if sway was effectively set to 0 with `player setCustomAimCoef 0;`.","syntaxes":[{"syntax":"getWeaponSway unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":"weapon sway","text":"Number - weapon sway"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_sway = getWeaponSway player;\n```","code":["_sway = getWeaponSway player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponInertia","getCustomAimCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Command Group: Weapons","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"getWingsOrientationRTD","operator":null,"title":"getWingsOrientationRTD","type":"command","url":"https://community.bistudio.com/wiki/getWingsOrientationRTD","revid":319254,"updated":"2022-05-13T09:23:27Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns orientation of horizontal stabilizers.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"getWingsOrientationRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_orientation = getWingsOrientationRTD myHelicopter;\n```","code":["_orientation = getWingsOrientationRTD myHelicopter;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getWingsPositionRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getWingsPositionRTD","operator":null,"title":"getWingsPositionRTD","type":"command","url":"https://community.bistudio.com/wiki/getWingsPositionRTD","revid":319210,"updated":"2022-05-13T09:23:22Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns position of stabilizers.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"getWingsPositionRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_position = getWingsPositionRTD myHelicopter;\n```","code":["_position = getWingsPositionRTD myHelicopter;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getWingsOrientationRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"getWPPos","operator":null,"title":"getWPPos","type":"command","url":"https://community.bistudio.com/wiki/getWPPos","revid":377567,"updated":"2026-01-02T06:55:33Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the position of a selected waypoint of a given group. Waypoints include only those which were placed in the mission editor.","syntaxes":[{"syntax":"getWPPos [groupOrUnit, index]","since":null,"effect":null,"exec":null,"params":[{"name":"groupOrUnit","type":"Group or Object","optional":false,"default":null,"description":"the group (or unit) of which to select a waypoint","types":["Group","Object"],"since":null,"text":"groupOrUnit: Group or Object - the group (or unit) of which to select a waypoint"},{"name":"index","type":"Number","optional":false,"default":null,"description":"0 equals the starting position of the group.\n\nThe number used in this and other waypoint commands is *one more* than the one displayed in the waypoint window in the editor: e.g if the editor labeled a waypoint `\"0:MOVE\"` then it can be accessed using `getWPPos [grp, 1]`","types":["Number"],"since":null,"text":"index: Number - 0 equals the starting position of the group.\n\nThe number used in this and other waypoint commands is *one more* than the one displayed in the waypoint window in the editor: e.g if the editor labeled a waypoint `\"0:MOVE\"` then it can be accessed using `getWPPos [grp, 1]`"}],"returns":{"type":"Position3D","types":["Position3D"],"description":"the returned position equals [0,0,0] if the selected waypoint does not exist.","text":"Position3D - the returned position equals [0,0,0] if the selected waypoint does not exist."},"form":"unary","operator":null,"left":null,"right":{"text":"[groupOrUnit, index]","types":["Array"]}}],"examples":[{"text":"```sqf\n[_group1, 1] setWPPos [200,600,0];\n_pos = getWPPos [_group1, 1]; // returns [200, 600, 0]\n```","code":["[_group1, 1] setWPPos [200,600,0];\n_pos = getWPPos [_group1, 1]; // returns [200, 600, 0]"]}],"multiplayer":null,"problems":null,"aliases":["waypointPosition"],"see_also":["setWPPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"glanceAt","operator":null,"title":"glanceAt","type":"command","url":"https://community.bistudio.com/wiki/glanceAt","revid":377158,"updated":"2026-01-01T10:39:40Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Control what the unit(s) is/are glancing at (target or Position). If target is used, it will get revealed fully.\n\nHow frequently the unit(s) is/are glancing there depends on behaviour.","syntaxes":[{"syntax":"unit(s) glanceAt position","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"},{"name":"position","type":"Object or Position","optional":false,"default":null,"description":null,"types":["Object","Position"],"since":null,"text":"position: Object or Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit(s)","types":["Object","Array"]},"right":{"text":"position","types":["Object","Position"]}}],"examples":[{"text":"```sqf\n_someSoldier glanceAt _otherSoldier;\n```","code":["_someSoldier glanceAt _otherSoldier;"]},{"text":"```sqf\n[_someSoldier, _otherSoldier] glanceAt markerPos \"markerOne\";\n```","code":["[_someSoldier, _otherSoldier] glanceAt markerPos \"markerOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lookAt","commandWatch","doWatch"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"globalChat","operator":null,"title":"globalChat","type":"command","url":"https://community.bistudio.com/wiki/globalChat","revid":376771,"updated":"2025-11-17T00:04:34Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Types text to the global radio channel. The text will be visible only on the PC where command was executed. If you need the message to show on all computers, you have to execute it globally (see remoteExec). Use clearRadio to clear chat history","syntaxes":[{"syntax":"unit globalChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit transmitting message","types":["Object"],"since":null,"text":"unit: Object - unit transmitting message"},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"chatText","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne globalChat \"Show this text\";\n```","code":["_soldierOne globalChat \"Show this text\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideChat","groupChat","vehicleChat","commandChat","customChat","systemChat","globalRadio"],"notes":[{"user":"Ceeeb","date":"2007-01-31T04:47:00Z","text":"In **OFP 1.96**, this command can be used by a Game_Logic unit, which will result in the text being displayed on screen without any  indication of the side of radio source, or quotation marks. For example : *gamelogic1 globalchat \"hello world\"* will create the text *hello world* in the radio log."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"globalRadio","operator":null,"title":"globalRadio","type":"command","url":"https://community.bistudio.com/wiki/globalRadio","revid":353329,"updated":"2024-03-15T17:11:49Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the audio message to the global radio channel. The message is defined in CfgRadio in the description.ext file or config radio protocol. The transmission will play only on the PC where command was executed. If you need the transmission to play on all computers, you have to execute it globally (see remoteExec).\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit globalRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from CfgRadio","types":["String"],"since":null,"text":"radioName: String - class name from CfgRadio"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne globalRadio \"messageOne\";\n```","code":["_soldierOne globalRadio \"messageOne\";"]},{"text":"```sqf\nplayer globalRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["player globalRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideRadio","groupRadio","customRadio","vehicleRadio","globalChat","directSay","commandRadio"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"goggles","operator":null,"title":"goggles","type":"command","url":"https://community.bistudio.com/wiki/goggles","revid":320934,"updated":"2022-05-13T10:04:40Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns name of currently used goggles (for NVGoggles use hmd).","syntaxes":[{"syntax":"goggles unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_goggles = goggles assaultDiver; //G_Diving\n```","code":["_goggles = goggles assaultDiver; //G_Diving"]},{"text":"```sqf\n_goggles = goggles reconTeamLeader; //G_Shades_Black\n```","code":["_goggles = goggles reconTeamLeader; //G_Shades_Black"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeGoggles","addGoggles","hmd","headgear","binocular","getDiverState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"goto","operator":null,"title":"goto","type":"command","url":"https://community.bistudio.com/wiki/goto","revid":364521,"updated":"2024-05-16T20:46:23Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Break script flow and go to given label (defined by **#** - **NOT** to be confused with SQF's hash sign!)\n\n> [!WARNING]\n> This command only works in SQS Syntax.\n\n> [!NOTE]\n> Note that labels are not case sensitive and are searched for from the top of the script, so multiple occurrences of a label will only result in the topmost one ever being found.","syntaxes":[{"syntax":"goto label","since":null,"effect":null,"exec":null,"params":[{"name":"label","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"label: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"label","types":["String"]}}],"examples":[{"text":"```sqs\ngoto \"myLabel\"\nplayer setDamage 1\n\n#myLabel\nhint \"you successfully avoided death!\"\n```","code":["goto \"myLabel\"\nplayer setDamage 1\n\n#myLabel\nhint \"you successfully avoided death!\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","SQS to SQF conversion"],"notes":[{"user":"Hardrock","date":"2006-08-04T10:52:00Z","text":"*Notes from before the conversion:*\n\n- This function works only inside of SQS script.\n- The search for labels always begins at the top of the script so that if there are multiple occurrences of a label the first occurrence will always be the one found.\n- Because of the searching order, it is faster to place loops which are executed often at the top of a script.\n- Labels are not case sensitive.\n- Loops which look something like the example below should be avoided as many of them could cause the mission to slow down:\n\n```sqs\n#wait\nif (condition) then { goto \"wait\" }\n```\n\nIt is better to use the **@** command to wait for a condition to be true, or put a small delay into the wait loop.\n\nExample:\n- While it is not required to include a delay in a loop, such a loop without a delay can cause the script to slow the game down, as the loop will be executed many times before the game engine interrupts the script.\n- Unless you really want the loop to execute multiple times during a frame, you should include a small delay.\n- You would need to have many scripts running for this to be a significant issue.\n- Deciding whether to use a script with a loop or a trigger or even a **@** statement to detect a condition is a complicated matter and should be subject to experimentation."},{"user":"UNN","date":"2006-08-04T12:17:00Z","text":"A goto command called within a forEach loop will only execute a single jump to goto, once the forEach loop has finished:\n\n```sqs\n{ goto \"wait\" } forEach [0, 1, 2, 3, 4]\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"group","operator":null,"title":"group","type":"command","url":"https://community.bistudio.com/wiki/group","revid":377962,"updated":"2026-01-18T09:47:05Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the group a unit is assigned to.","syntaxes":[{"syntax":"group object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Group","types":["Group"],"description":"for dead units, the returned group equals grpNull.","text":"Group - for dead units, the returned group equals grpNull."},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerGrp = group player;\n```","code":["_playerGrp = group player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["local","join","leader","units","allGroups","groups","groupID","setGroupId","setGroupIdGlobal"],"notes":[{"user":"jafarin","date":"2006-08-19T12:00:00Z","text":"Few rules about group in OFP:R:\n1. When last man in group die or is moved to other group, group will be destroyed, and it can't be used anymore.\n1. First man joined to empty group will be group leader."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"groupChat","operator":null,"title":"groupChat","type":"command","url":"https://community.bistudio.com/wiki/groupChat","revid":376775,"updated":"2025-11-17T00:05:36Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Types text to the group radio channel. The text will be visible only on the PC where command was executed. If you need the message to show on all computers, you have to execute it globally (see remoteExec). Use clearRadio to clear chat history\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.","syntaxes":[{"syntax":"unit groupChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit transmitting message","types":["Object"],"since":null,"text":"unit: Object - unit transmitting message"},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"chatText","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne groupChat \"Show this text\";\n```","code":["_soldierOne groupChat \"Show this text\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","sideChat","vehicleChat","commandChat","customChat","systemChat","groupRadio"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"groupFromNetId","operator":null,"title":"groupFromNetId","type":"command","url":"https://community.bistudio.com/wiki/groupFromNetId","revid":364977,"updated":"2024-07-04T17:39:28Z","groups":["Groups","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get group from the provided unique ID. For objects, use objectFromNetId.","syntaxes":[{"syntax":"groupFromNetId id","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"id: String"}],"returns":{"type":"Group","types":["Group"],"description":null,"text":"Group"},"form":"unary","operator":null,"left":null,"right":{"text":"id","types":["String"]}}],"examples":[{"text":"```sqf\n_group = groupFromNetId \"4:45\";\n```","code":["_group = groupFromNetId \"4:45\";"]}],"multiplayer":"- In singleplayer: Arma 3 v2.18 works as described (returned grpNull before v2.18 - see BIS_fnc_groupFromNetId)\n- In multiplayer: works as described","problems":null,"aliases":[],"see_also":["objectFromNetId","netId","BIS_fnc_objectFromNetId","BIS_fnc_netId","BIS_fnc_groupFromNetId"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Multiplayer","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"groupIconSelectable","operator":null,"title":"groupIconSelectable","type":"command","url":"https://community.bistudio.com/wiki/groupIconSelectable","revid":310231,"updated":"2022-05-05T13:10:57Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether or not group icons raise onGroupIconClick, onGroupIconOverEnter and onGroupIconOverLeave events.","syntaxes":[{"syntax":"groupIconSelectable","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true is selectable","text":"Boolean - true is selectable"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str groupIconSelectable;\n```","code":["hint str groupIconSelectable;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"groupIconsVisible","operator":null,"title":"groupIconsVisible","type":"command","url":"https://community.bistudio.com/wiki/groupIconsVisible","revid":310247,"updated":"2022-05-05T13:11:07Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with group icons visibility. A getter for setGroupIconsVisible","syntaxes":[{"syntax":"groupIconsVisible","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"[visibleOnMap, visibleOnHUD]","text":"Array - [visibleOnMap, visibleOnHUD]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str groupIconsVisible;\n```","code":["hint str groupIconsVisible;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hcShownBar","addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"groupId","operator":null,"title":"groupId","type":"command","url":"https://community.bistudio.com/wiki/groupId","revid":337336,"updated":"2023-01-18T11:45:01Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a group's name or a unit's group ID number.","syntaxes":[{"syntax":"groupId group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"String","types":["String"],"description":"the group's name (e.g \"Alpha Red\")","text":"String - the group's name (e.g \"Alpha Red\")"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}},{"syntax":"groupId unit","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"a group's unit","types":["Object"],"since":null,"text":"unit: Object - a group's unit"}],"returns":{"type":"Number","types":["Number"],"description":"the unit's group ID (e.g \"2, taking command\")","text":"Number - the unit's group ID (e.g \"**2**, taking command\")"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_name = groupId group player;            // e.g \"B Alpha 1-1\"\n```","code":["_name = groupId group player;\t\t\t// e.g \"B Alpha 1-1\""]},{"text":"```sqf\nprivate _unitGroupId = groupId player;    // e.g 3 (number, not a string)\n```","code":["private _unitGroupId = groupId player;\t// e.g 3 (number, not a string)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setGroupId","setGroupIdGlobal","group"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"groupOwner","operator":null,"title":"groupOwner","type":"command","url":"https://community.bistudio.com/wiki/groupOwner","revid":363282,"updated":"2024-03-26T10:51:53Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":"global","effect":null,"server_exec":true},"exec":null,"description":"Returns the machine network ID of the client to which the group is local. This command only works when called from the server. When called from a client, it always returns 0.","syntaxes":[{"syntax":"groupOwner group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_clientID = groupOwner _someGroup;\n```","code":["_clientID = groupOwner _someGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["owner","setOwner","setGroupOwner","local","group","didJIPOwner","remoteExecutedOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.40","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"groupRadio","operator":null,"title":"groupRadio","type":"command","url":"https://community.bistudio.com/wiki/groupRadio","revid":363908,"updated":"2024-04-24T22:08:47Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the audio message to the group radio channel. The message is defined in CfgRadio in the description.ext file or config radio protocol.\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages.\n> A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.\n\n> [!NOTE]\n> When the transmitting unit gets killed, the transmission is interrupted. However when the receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit groupRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from `CfgRadio`","types":["String"],"since":null,"text":"radioName: String - class name from `CfgRadio`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne groupRadio \"messageOne\";\n```","code":["_soldierOne groupRadio \"messageOne\";"]},{"text":"```sqf\nplayer groupRadio (configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\")));\n```","code":["player groupRadio (configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\")));"]}],"multiplayer":"If you need the transmission to play on all computers, you have to execute it globally (see remoteExec).","problems":null,"aliases":[],"see_also":["sideRadio","groupChat","customRadio","vehicleRadio","globalRadio","directSay","commandRadio"],"notes":[{"user":"Killzone_Kid","date":"2016-12-03T21:34:00Z","text":"To transmit user custom sounds (see Multiplayer Custom Sounds Tutorial), prefix the full filename including file extension with `1.`.\nFor example if there is a custom user sound file called `MySound.ogg`, to play it on the radio use:\n\n```sqf\nplayer groupRadio \"#MySound.ogg\";\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"groups","operator":null,"title":"groups","type":"command","url":"https://community.bistudio.com/wiki/groups","revid":338341,"updated":"2023-02-28T14:38:39Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with all groups of given side.","syntaxes":[{"syntax":"groups side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Array of Groups","types":["Array","Group"],"description":null,"text":"Array of Groups"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\nprivate _allBluforGroups = groups blufor; // equivalent of allGroups select { side _x == blufor };\n```","code":["private _allBluforGroups = groups blufor; // equivalent of allGroups select { side _x == blufor };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["group","allGroups","units","allUnits"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"groupSelectedUnits","operator":null,"title":"groupSelectedUnits","type":"command","url":"https://community.bistudio.com/wiki/groupSelectedUnits","revid":377896,"updated":"2026-01-05T17:44:14Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns selected units in source group for normal commanding mode (individual units). For the High Command equivalent, see hcSelected.","syntaxes":[{"syntax":"groupSelectedUnits unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_selectedUnits = groupSelectedUnits player;\n```","code":["_selectedUnits = groupSelectedUnits player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["groupSelectUnit"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"groupSelectUnit","operator":null,"title":"groupSelectUnit","type":"command","url":"https://community.bistudio.com/wiki/groupSelectUnit","revid":330040,"updated":"2022-08-15T15:25:02Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects a unit from player's group. If player is the leader, the effect of this command is similar to player pressing <kbd>F1</kbd>, <kbd>F2</kbd>, <kbd>F3</kbd> etc to highlight units in his squad, after which the unit command menu is shown.\nIf leader is AI, player will get usual communication menu to interact with the leader.","syntaxes":[{"syntax":"player groupSelectUnit [unit, select]","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"select","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"select: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"[unit, select]","types":["Array"]}}],"examples":[{"text":"After leaving menu, deselect all units (command menu is not opened → no selection)\n\n```sqf\n{\n    player groupSelectUnit [_x, false];\n} forEach (groupSelectedUnits player);\n```","code":["{\n\tplayer groupSelectUnit [_x, false];\n} forEach (groupSelectedUnits player);"]},{"text":"Select all units when player is the leader:\n\n```sqf\n{\n    player groupSelectUnit [_x, true];\n} forEach units player;\n```","code":["{\n\tplayer groupSelectUnit [_x, true];\n} forEach units player;"]},{"text":"Open communication with group leader:\n\n```sqf\nplayer groupSelectUnit [leader player, true];\n```","code":["player groupSelectUnit [leader player, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["groupSelectedUnits"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"grpNull","operator":null,"title":"grpNull","type":"command","url":"https://community.bistudio.com/wiki/grpNull","revid":321055,"updated":"2022-05-13T12:17:13Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Group. To compare non-existent groups use isNull or isEqualTo:\n\n```sqf\ngrpNull == grpNull;            // false\nisNull grpNull;                // true\ngrpNull isEqualTo grpNull;    // true\n```","syntaxes":[{"syntax":"grpNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Group","types":["Group"],"description":null,"text":"Group"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n!isNull grpNull; // false\n```","code":["!isNull grpNull; // false"]},{"text":"```sqf\nstr grpNull; // <NULL-group>\n```","code":["str grpNull; // <NULL-group>"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","locationNull","objNull","taskNull","teamMemberNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"gunner","operator":null,"title":"gunner","type":"command","url":"https://community.bistudio.com/wiki/gunner","revid":348608,"updated":"2023-11-08T13:45:17Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the gunner of a vehicle.","syntaxes":[{"syntax":"gunner vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Object","types":["Object"],"description":"the person sitting in the gunner place is returned. If vehicle is not a vehicle but a person, the person is returned.","text":"Object - the person sitting in the gunner place is returned. If vehicle is not a vehicle but a person, the person is returned."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\ngunner _tank action [\"getout\", _tank];\n```","code":["gunner _tank action [\"getout\", _tank];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commander","driver","crew","currentPilot"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"gusts","operator":null,"title":"gusts","type":"command","url":"https://community.bistudio.com/wiki/gusts","revid":376953,"updated":"2026-01-01T05:39:26Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current gusts value.","syntaxes":[{"syntax":"gusts","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_gustsValue = gusts;\n```","code":["_gustsValue = gusts;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setGusts","windStr","wind"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"halt","operator":null,"title":"halt","type":"command","url":"https://community.bistudio.com/wiki/halt","revid":377978,"updated":"2026-01-19T18:48:19Z","groups":["Program Flow","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command was meant to break the script into debugger, however currently **it does not do anything** except displaying and logging the following error: `Error Debugger breakpoint hit`.","syntaxes":[{"syntax":"halt","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"always returns false","text":"Boolean - always returns false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (_displayAnError) then {halt};\n```","code":["if (_displayAnError) then {halt};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assert","terminate"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"handgunItems","operator":null,"title":"handgunItems","type":"command","url":"https://community.bistudio.com/wiki/handgunItems","revid":321090,"updated":"2022-05-13T13:46:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns array with all items assigned to the handgunWeapon except magazines. Use handgunMagazine command for the latter. This command is used for infantry weapons only.","syntaxes":[{"syntax":"handgunItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array","types":["Array"],"description":"[silencer, laserpointer/flashlight, optics, bipod]","text":"Array - [silencer, laserpointer/flashlight, optics, bipod]"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhandgunItems player;\n/*\n[\n    \"muzzle_snds_L\",    // silencer\n    \"\",                    // laser\n    \"\",                    // optics\n    \"\"                    // bipod\n]\n*/\n```","code":["handgunItems player;\n/*\n[\n\t\"muzzle_snds_L\",\t// silencer\n\t\"\",\t\t\t\t\t// laser\n\t\"\",\t\t\t\t\t// optics\n\t\"\"\t\t\t\t\t// bipod\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addHandgunItem","removeHandgunItem","removeAllHandgunItems","weaponAccessories","weaponAccessoriesCargo","primaryWeaponItems","secondaryWeaponItems","weaponsItems","binocularItems","weaponsItemsCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"handgunMagazine","operator":null,"title":"handgunMagazine","type":"command","url":"https://community.bistudio.com/wiki/handgunMagazine","revid":377157,"updated":"2026-01-01T10:38:51Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Collects all loaded magazines from all handgunWeapon muzzles and returns them in Array, otherwise it returns []. This command is used for infantry weapons only.","syntaxes":[{"syntax":"handgunMagazine unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str handgunMagazine player; // [\"16Rnd_9x21_Mag\"]\n```","code":["hint str handgunMagazine player; // [\"16Rnd_9x21_Mag\"]"]},{"text":"```sqf\n_array = handgunMagazine player;\nif (count _array > 0) then {\n    hint (\"Handgun is loaded with \" + (_array select 0) + \"!\");\n} else {\n    if (handgunWeapon player != \"\") then {\n        hint \"Handgun is not loaded!\";\n    } else {\n        hint \"Player doesn't have a handgun!\";\n    };\n};\n```","code":["_array = handgunMagazine player;\nif (count _array > 0) then {\n\thint (\"Handgun is loaded with \" + (_array select 0) + \"!\");\n} else {\n\tif (handgunWeapon player != \"\") then {\n\t\thint \"Handgun is not loaded!\";\n\t} else {\n\t\thint \"Player doesn't have a handgun!\";\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["handgunWeapon","handgunItems","addHandgunItem","removeHandgunItem","removeAllHandgunItems","primaryWeaponMagazine","secondaryWeaponMagazine","binocularMagazine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands"]},{"name":"handgunWeapon","operator":null,"title":"handgunWeapon","type":"command","url":"https://community.bistudio.com/wiki/handgunWeapon","revid":320951,"updated":"2022-05-13T10:04:47Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the name of a unit's handgun (an empty string if there is none).","syntaxes":[{"syntax":"handgunWeapon unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint handgunWeapon player; //\"hgun_P07_F\"\n```","code":["hint handgunWeapon player; //\"hgun_P07_F\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["handgunMagazine","handgunItems","addHandgunItem","removeHandgunItem","removeAllHandgunItems","primaryWeapon","secondaryWeapon","currentWeapon","weapons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"handsHit","operator":null,"title":"handsHit","type":"command","url":"https://community.bistudio.com/wiki/handsHit","revid":329502,"updated":"2022-07-29T13:32:42Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if a soldier's hands are hit, which results in inaccurate aiming.","syntaxes":[{"syntax":"handsHit unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Number","types":["Number"],"description":"if the hands are not damaged, the returned value is 0. If the hands are hit or the unit is dead, the returned value is 1.","text":"Number - if the hands are not damaged, the returned value is 0. If the hands are hit or the unit is dead, the returned value is 1."},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqs\n? (handsHit player == 1) : player globalChat \"Ouch! Don't shoot at my hands dammit!\"\n```","code":["? (handsHit player == 1) : player globalChat \"Ouch! Don't shoot at my hands dammit!\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["damage"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hasCustomFace","operator":null,"title":"hasCustomFace","type":"command","url":"https://community.bistudio.com/wiki/hasCustomFace","revid":369746,"updated":"2024-10-08T15:07:09Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get whether or not a player has an available custom face file.\n\n> [!NOTE]\n> To check if this custom face is currently being used, use face (returns \"Custom\" in that case).","syntaxes":[{"syntax":"hasCustomFace person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if player has a `face.paa/jpg` file in their current profile and it is usable","text":"Boolean - true if player has a `face.paa/jpg` file in their current profile and it is usable"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isPlayer _thisUnit && hasCustomFace _thisUnit && face _thisUnit != \"Custom\") then\n{\n    [_thisUnit, \"Custom\"] remoteExec [\"setFace\", 0, true];\n};\n```","code":["if (isPlayer _thisUnit && hasCustomFace _thisUnit && face _thisUnit != \"Custom\") then\n{\n\t[_thisUnit, \"Custom\"] remoteExec [\"setFace\", 0, true];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["face","setFace","setIdentity","setSpeaker"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"hashValue","operator":null,"title":"hashValue","type":"command","url":"https://community.bistudio.com/wiki/hashValue","revid":373375,"updated":"2025-05-04T09:05:03Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Processes provided *value*'s hash, and encodes it using [Base64](https://en.wikipedia.org/wiki/Base64). The hash algorithm is [FNV-1A 64bit](https://en.wikipedia.org/wiki/Fowler%E2%80%93Noll%E2%80%93Vo_hash_function).\n\n> [!NOTE]\n> A hash value remains the same between game restarts but for Object and Group type, their hash being based on their netId.","syntaxes":[{"syntax":"hashValue value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":null,"optional":false,"default":null,"description":"Array, Boolean, Code, Config, Group, Namespace, NaN, Number, Object, Side or String","types":["Array","Boolean","Code","Config","Group","Namespace","NaN","Number","Object","Side","String"],"since":null,"text":"value: Array, Boolean, Code, Config, Group, Namespace, NaN, Number, Object, Side or String"}],"returns":{"type":"String","types":["String"],"description":"base64-encoded 64 bits hash","text":"String - base64-encoded 64 bits hash"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Array","Boolean","Code","Config","Group","Namespace","NaN","Number","Object","Side","String"]}}],"examples":[{"text":"```sqf\nprivate _valueHash = hashValue \"Hello There\";\n```","code":["private _valueHash = hashValue \"Hello There\";"]},{"text":"```sqf\nprivate _isCorrectPW = hashValue _enteredPassword == \"eWkXUUqiinE\";\n```","code":["private _isCorrectPW = hashValue _enteredPassword == \"eWkXUUqiinE\";"]},{"text":"```sqf\nhashValue (systemTime joinString \"\"); // Returns a unique hash value such as \"xoMQ9qd7S60\"\n```","code":["hashValue (systemTime joinString \"\"); // Returns a unique hash value such as \"xoMQ9qd7S60\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createHashMap","values"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"hasInterface","operator":null,"title":"hasInterface","type":"command","url":"https://community.bistudio.com/wiki/hasInterface","revid":369395,"updated":"2024-09-03T18:43:19Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the computer has an interface (a real player). False for a dedicated server or for a headless client.","syntaxes":[{"syntax":"hasInterface","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_isHC = !(hasInterface || isDedicated);\n```","code":["_isHC = !(hasInterface || isDedicated);"]},{"text":"```sqf\n_isHC = !hasInterface && !isDedicated;\n```","code":["_isHC = !hasInterface && !isDedicated;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isDedicated","isServer"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.63","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hasPilotCamera","operator":null,"title":"hasPilotCamera","type":"command","url":"https://community.bistudio.com/wiki/hasPilotCamera","revid":310236,"updated":"2022-05-05T13:10:59Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if the object airplane or helicopter has a pilotCamera.","syntaxes":[{"syntax":"hasPilotCamera object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nhasPilotCamera vehicle player;\n```","code":["hasPilotCamera vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"hasWeapon","operator":null,"title":"hasWeapon","type":"command","url":"https://community.bistudio.com/wiki/hasWeapon","revid":318541,"updated":"2022-05-13T09:14:18Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if a unit has the given weapon in hands or on back/in holster. Weapons inside unit containers such as vest and backpack are not counted.","syntaxes":[{"syntax":"unitName hasWeapon weaponName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":"the name of the weapon to check for.","types":["String"],"since":null,"text":"weaponName: String - the name of the weapon to check for."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if the unit has the weapon, false if not.","text":"Boolean - returns true if the unit has the weapon, false if not."},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"weaponName","types":["String"]}}],"examples":[{"text":"```sqf\nif !(player hasWeapon \"arifle_MX_ACO_pointer_F\") then { player addWeapon \"arifle_MX_ACO_pointer_F\" };\n```","code":["if !(player hasWeapon \"arifle_MX_ACO_pointer_F\") then { player addWeapon \"arifle_MX_ACO_pointer_F\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weapons"],"notes":[{"user":"Benargee","date":"2014-09-11T10:49:00Z","text":"This command doesn't work for Items in Arma 3, use this instead (e.g ItemGPS).\n\n```sqf\n\"ItemGPS\" in (items player + assignedItems player)\n```\n\nReturns true if unit has gps in inventory, assigned or not."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcAllGroups","operator":null,"title":"hcAllGroups","type":"command","url":"https://community.bistudio.com/wiki/hcAllGroups","revid":377156,"updated":"2026-01-01T10:38:32Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns selected groups in high command.","syntaxes":[{"syntax":"hcAllGroups unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"commander","types":["Object"],"since":null,"text":"unit: Object - commander"}],"returns":{"type":"Array of Groups","types":["Array","Group"],"description":null,"text":"Array of Groups"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhcAllGroups player;\n```","code":["hcAllGroups player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcGroupParams","operator":null,"title":"hcGroupParams","type":"command","url":"https://community.bistudio.com/wiki/hcGroupParams","revid":319122,"updated":"2022-05-13T09:23:13Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns parameters describing group in high command bar. Return value is array in format [groupName, teamName] or [] if error. Possible values for team name:\n- `\"teammain\"` (default)\n- `\"teamred\"`\n- `\"teamgreen\"`\n- `\"teamblue\"`\n- `\"teamyellow\"`","syntaxes":[{"syntax":"unit hcGroupParams group","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"commander","types":["Object"],"since":null,"text":"unit: Object - commander"},{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\nplayer hcGroupParams someGroup;\n```","code":["player hcGroupParams someGroup;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcLeader","operator":null,"title":"hcLeader","type":"command","url":"https://community.bistudio.com/wiki/hcLeader","revid":363257,"updated":"2024-03-26T10:51:31Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns group's high command commander.","syntaxes":[{"syntax":"hcLeader group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_leader = hcLeader groupName;\n```","code":["_leader = hcLeader groupName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcRemoveAllGroups","operator":null,"title":"hcRemoveAllGroups","type":"command","url":"https://community.bistudio.com/wiki/hcRemoveAllGroups","revid":363244,"updated":"2024-03-26T10:51:19Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove all groups from unit's high command bar.","syntaxes":[{"syntax":"hcRemoveAllGroups unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhcRemoveAllGroups player;\n```","code":["hcRemoveAllGroups player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcRemoveGroup","operator":null,"title":"hcRemoveGroup","type":"command","url":"https://community.bistudio.com/wiki/hcRemoveGroup","revid":363247,"updated":"2024-03-26T10:51:22Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes group from unit's high command bar.","syntaxes":[{"syntax":"unit hcRemoveGroup group","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\nplayer hcRemoveGroup BIS_group;\n```","code":["player hcRemoveGroup BIS_group;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcSelected","operator":null,"title":"hcSelected","type":"command","url":"https://community.bistudio.com/wiki/hcSelected","revid":377155,"updated":"2026-01-01T10:38:13Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns selected groups in high command.","syntaxes":[{"syntax":"hcSelected unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"commander","types":["Object"],"since":null,"text":"unit: Object - commander"}],"returns":{"type":"Array of Groups","types":["Array","Group"],"description":null,"text":"Array of Groups"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\narray = hcSelected unit;\n```","code":["array = hcSelected unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcSelectGroup","operator":null,"title":"hcSelectGroup","type":"command","url":"https://community.bistudio.com/wiki/hcSelectGroup","revid":347546,"updated":"2023-09-28T09:23:04Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select given group in high command bar.","syntaxes":[{"syntax":"unit hcSelectGroup array","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"HC Owner","types":["Object"],"since":null,"text":"unit: Object - HC Owner"},{"name":"array","type":"Array of Groups","optional":false,"default":null,"description":null,"types":["Array","Group"],"since":null,"text":"array: Array of Groups"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"array","types":["Array","Group"]}}],"examples":[{"text":"```sqf\nplayer hcSelectGroup [group_1,group_2];\n```","code":["player hcSelectGroup [group_1,group_2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcSetGroup","operator":null,"title":"hcSetGroup","type":"command","url":"https://community.bistudio.com/wiki/hcSetGroup","revid":376359,"updated":"2025-10-07T21:40:53Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add group to unit's high command bar.\n\n> [!NOTE]\n> The previous HC leader should be removed before adding the new one (see **#Example 3**).","syntaxes":[{"syntax":"unit hcSetGroup [group, groupName, team]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the leader","types":["Object"],"since":null,"text":"unit: Object - the leader"},{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"groupName","type":"String","optional":true,"default":null,"description":null,"types":["String"],"since":null,"text":"groupName: String - (Optional)"},{"name":"team","type":"String","optional":true,"default":"\"teamMain\"","description":"can be one of:\n- \"teamMain\"\n- \"teamRed\"\n- \"teamGreen\"\n- \"teamBlue\"\n- \"teamYellow\"","types":["String"],"since":null,"text":"team: String - (Optional, default \"teamMain\") can be one of:\n- \"teamMain\"\n- \"teamRed\"\n- \"teamGreen\"\n- \"teamBlue\"\n- \"teamYellow\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[group, groupName, team]","types":["Array"]}}],"examples":[{"text":"```sqf\nunit hcSetGroup [_group, \"HQ\", \"teamred\"];\n```","code":["unit hcSetGroup [_group, \"HQ\", \"teamred\"];"]},{"text":"```sqf\nplayer hcSetGroup [_group];\n```","code":["player hcSetGroup [_group];"]},{"text":"```sqf\nif (player != hcLeader _group) then\n{\n    hcLeader _group hcRemoveGroup _group;\n    player hcSetGroup [_group];\n};\n```","code":["if (player != hcLeader _group) then\n{\n\thcLeader _group hcRemoveGroup _group;\n\tplayer hcSetGroup [_group];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcShowBar","operator":null,"title":"hcShowBar","type":"command","url":"https://community.bistudio.com/wiki/hcShowBar","revid":347544,"updated":"2023-09-28T09:12:35Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides high command bar. There must be some groups under HC command to show HC bar.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.94 this command returns Nothing as it should","syntaxes":[{"syntax":"hcShowBar bool","since":null,"effect":null,"exec":null,"params":[{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":"(before Arma 3 v1.94 this command returned Object of null value)","text":"Nothing - (before Arma 3 v1.94 this command returned Object of null value)"},"form":"unary","operator":null,"left":null,"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nhcShowBar true;\n```","code":["hcShowBar true;"]},{"text":"```sqf\nhcShowBar false;\n```","code":["hcShowBar false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"hcShownBar","operator":null,"title":"hcShownBar","type":"command","url":"https://community.bistudio.com/wiki/hcShownBar","revid":319103,"updated":"2022-05-13T09:23:11Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return whether the High Command bar is shown/active.","syntaxes":[{"syntax":"hcShownBar","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if HC bar is shown, otherwise false","text":"Boolean - true if HC bar is shown, otherwise false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (hcShownBar) then { hint \"HC bar is active\"; };\n```","code":["if (hcShownBar) then { hint \"HC bar is active\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"headgear","operator":null,"title":"headgear","type":"command","url":"https://community.bistudio.com/wiki/headgear","revid":319125,"updated":"2022-05-13T09:23:14Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns headgear of unit.","syntaxes":[{"syntax":"headgear unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint headgear player; //H_HelmetB\n```","code":["hint headgear player; //H_HelmetB"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addHeadgear","removeHeadgear","goggles","hmd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"hiddenActions","operator":null,"title":"hiddenActions","type":"command","url":"https://community.bistudio.com/wiki/hiddenActions","revid":378901,"updated":"2026-08-11T14:56:33Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!IMPORTANT]\n> This command is a work in progress and can evolve until release on stable branch.\n\nGetter for hideActions, see also shownAction.","syntaxes":[{"syntax":"hiddenActions filter","since":null,"effect":null,"exec":null,"params":[{"name":"filter","type":"Array","optional":false,"default":null,"description":"Array of Numbers - actions to check if hidden or [] to check all. See shownAction for numbers meaning","types":["Array"],"since":null,"text":"filter: Array - Array of Numbers - actions to check if hidden or [] to check all. See shownAction for numbers meaning"}],"returns":{"type":"Array","types":["Array"],"description":"Array of Numbers - actions that are hidden or [] if none is hidden. See shownAction for numbers meaning","text":"Array - Array of Numbers - actions that are hidden or [] if none is hidden. See shownAction for numbers meaning"},"form":"unary","operator":null,"left":null,"right":{"text":"filter","types":["Array"]}}],"examples":[{"text":"```sqf\nif (hiddenActions [] isEqualTo []) then { hint \"No actions have been harmed during script execution\" };\n```","code":["if (hiddenActions [] isEqualTo []) then { hint \"No actions have been harmed during script execution\" };"]},{"text":"```sqf\nif (hiddenActions [91] isEqualTo [91]) then { hint \"User actions have been hidden\" };\n```","code":["if (hiddenActions [91] isEqualTo [91]) then { hint \"User actions have been hidden\" };"]},{"text":"```sqf\nhiddenActions []; // [2] - GetInDriver is hidden\n```","code":["hiddenActions []; // [2] - GetInDriver is hidden"]},{"text":"```sqf\nhiddenActions [1, 2, 4]; // [1,4] - from GetInCommander/Driver/Gunner only Commander and Gunner are hidden\n```","code":["hiddenActions [1, 2, 4]; // [1,4] - from GetInCommander/Driver/Gunner only Commander and Gunner are hidden"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideActions","shownAction","visibleMap","shownGPS","shownWatch","shownCompass","shownUAVFeed","shownHUD","addAction","action","isActionMenuVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"hideActions","operator":null,"title":"hideActions","type":"command","url":"https://community.bistudio.com/wiki/hideActions","revid":378963,"updated":"2026-09-06T22:42:03Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!IMPORTANT]\n> This command is a work in progress and can evolve until release on stable branch.\n\nHides/unhides user UI actions given by their enum number (see shownAction).\n\n> [!NOTE]\n> This command hides actions for the current player (focusOn), a respawned player will have all actions unhidden so it must be reapplied.","syntaxes":[{"syntax":"hideActions [mode, actions]","since":null,"effect":null,"exec":null,"params":[{"name":"mode","type":"Number or String or Boolean mode of operation, could be one of:","optional":false,"default":null,"description":"Number or String or Boolean mode of operation, could be one of:\n- 0 or \"UnhideSelected\" or false - only given actions (if previously hidden) would be unhidden\n- 1 or \"HideSelected\" or true - only given actions would be hidden\n- 2 or \"UnhideAllButSelected\" - all hidden actions will be unhidden except for the given actions\n- 3 or \"HideAllButSelected\" - all actions will be hidden except for the given actions","types":["Number","String","Boolean"],"since":null,"text":"mode: Number or String or Boolean mode of operation, could be one of:\n- 0 or \"UnhideSelected\" or false - only given actions (if previously hidden) would be unhidden\n- 1 or \"HideSelected\" or true - only given actions would be hidden\n- 2 or \"UnhideAllButSelected\" - all hidden actions will be unhidden except for the given actions\n- 3 or \"HideAllButSelected\" - all actions will be hidden except for the given actions"},{"name":"actions","type":null,"optional":false,"default":null,"description":"Array of Numbers (see shownAction)","types":["Array","Number","shownAction"],"since":null,"text":"actions: Array of Numbers (see shownAction)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[mode, actions]","types":["Array"]}}],"examples":[{"text":"```sqf\nhideActions [true, [1, 2]]; //hide GetInCommander and GetInDriver actions\n```","code":["hideActions [true, [1, 2]]; //hide GetInCommander and GetInDriver actions"]},{"text":"```sqf\nhideActions [\"UnhideSelected\", [1, 2]]; //unhide GetInCommander and GetInDriver actions\n```","code":["hideActions [\"UnhideSelected\", [1, 2]]; //unhide GetInCommander and GetInDriver actions"]},{"text":"```sqf\nhideActions [1, [91]]; //hide all user added actions\n```","code":["hideActions [1, [91]]; //hide all user added actions"]},{"text":"```sqf\nhideActions [\"HideAllButSelected\", [91]]; //hide all engine actions leaving only user added\n```","code":["hideActions [\"HideAllButSelected\", [91]]; //hide all engine actions leaving only user added"]},{"text":"```sqf\nhideActions [3, []]; //hide all actions\n```","code":["hideActions [3, []]; //hide all actions"]},{"text":"```sqf\nhideActions [\"UnhideAllButSelected\", []]; //unhide all hidden actions\n```","code":["hideActions [\"UnhideAllButSelected\", []]; //unhide all hidden actions"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hiddenActions","shownAction","visibleMap","shownGPS","shownWatch","shownCompass","shownUAVFeed","shownHUD","addAction","action","isActionMenuVisible","Arma 3: Mission Event Handlers"],"notes":[{"user":"Honger","date":"2026-08-27T20:33:24Z","text":"Hidden actions will also be unhidden once a game save is loaded/game is continued, \"Loaded\" Mission EH is therefore needed to maintain the chosen actions hidden. Actions need to be hidden again if player takes control of a UAV."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"hideBody","operator":null,"title":"hideBody","type":"command","url":"https://community.bistudio.com/wiki/hideBody","revid":309957,"updated":"2022-05-05T12:17:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Hides dead body of the given unit. After a short delay, the body slowly sinks into the ground. After awhile, when group of the unit becomes grpNull, the body gets deleted and becomes objNull. If applied to alive unit, nothing happens until unit dies, then the unit's body gets hidden. If a dead unit is human player, the body is hidden but not deleted until player respawns.","syntaxes":[{"syntax":"hideBody unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person","types":["Object"],"since":null,"text":"unit: Object - person"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhideBody player1;\n```","code":["hideBody player1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteVehicle","setDamage","addToRemainsCollector"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"hideObject","operator":null,"title":"hideObject","type":"command","url":"https://community.bistudio.com/wiki/hideObject","revid":349468,"updated":"2023-11-08T16:49:17Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.06"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.06"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Hide entity. Can be used on soldiers and vehicles, also on static objects.","syntaxes":[{"syntax":"hideObject object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"object hideObject hidden","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"hidden","type":"Boolean","optional":false,"default":null,"description":"true->hidden; false->visible","types":["Boolean"],"since":null,"text":"hidden: Boolean - true->hidden; false->visible"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"hidden","types":["Boolean"]}}],"examples":[{"text":"```sqf\nhideObject unitName;\n```","code":["hideObject unitName;"]},{"text":"```sqf\nobjectName hideObject true;\n```","code":["objectName hideObject true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectHidden","hideObjectGlobal","deleteCollection"],"notes":[{"user":"Shuko","date":"2010-07-15T20:00:00Z","text":"This command will hide a unit, but he will still shoot enemies. Unit will be invisible, but weapon muzzle are visible."},{"user":"McHide","date":"2011-02-04T08:13:00Z","text":"Use MP framework to activate this command on all players from server or any other maschine\n\n```sqf\n_nic = [nil, mantohide, \"per\", rHideObject, true] call RE; // In A3 use hideObjectGlobal instead.\n```"},{"user":"DamonDaemon","date":"2012-02-10T06:36:00Z","text":"Hidden Vehicles still emit smoke/rotor blade dust and (probably) still emit engine sounds.\nUseful for creating objects the mission maker doesn't want to be seen, like Units that protect a certain Area (like a safe-zone) against teamkillers or enemy units."},{"user":"Benargee","date":"2014-10-30T05:54:00Z","text":"When used on player, it only has an effect on third person mode. First person LOD is still visible."},{"user":"DreadedEntity","date":"2015-06-27T18:14:00Z","text":"hideObject and hideObjectGlobal disable object collision in addition to rendering.\n(tested by hiding buildings and running through, driving through, flying through, and shooting through where the building used to be)"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.06","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"hideObjectGlobal","operator":null,"title":"hideObjectGlobal","type":"command","url":"https://community.bistudio.com/wiki/hideObjectGlobal","revid":369350,"updated":"2024-09-03T18:43:03Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"This command is designed for MP. Hides object on all connected clients as well as JIP. Can be used on static objects. In singleplayer this command behaves just like hideObject.","syntaxes":[{"syntax":"hideObjectGlobal object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to hide","types":["Object"],"since":null,"text":"object: Object - object to hide"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"object hideObjectGlobal hidden","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"hidden","type":"Boolean","optional":false,"default":null,"description":"true → hidden; false → visible","types":["Boolean"],"since":null,"text":"hidden: Boolean - true → hidden; false → visible"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"hidden","types":["Boolean"]}}],"examples":[{"text":"```sqf\nhideObjectGlobal myObject; // hides myObject\nhideObjectGlobal nearestBuilding [2500, 2500, 0];\n```","code":["hideObjectGlobal myObject; // hides myObject\nhideObjectGlobal nearestBuilding [2500, 2500, 0];"]},{"text":"```sqf\nmyObject hideObjectGlobal true;    // hides myObject\nmyObject hideObjectGlobal false;    // shows myObject\n```","code":["myObject hideObjectGlobal true;\t// hides myObject\nmyObject hideObjectGlobal false;\t// shows myObject"]},{"text":"```sqf\n[myObject, true] remoteExec [\"hideObjectGlobal\", 2]; // remote-executes hideObjectGlobal from a client to the server\n```","code":["[myObject, true] remoteExec [\"hideObjectGlobal\", 2]; // remote-executes hideObjectGlobal from a client to the server"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideObject","isObjectHidden","deleteCollection"],"notes":[{"user":"DreadedEntity","date":"2015-06-27T18:14:00Z","text":"hideObject and hideObjectGlobal disable object collision in addition to rendering. **A3 1.45.131175**\n(tested by hiding buildings and running through, driving through, flying through, and shooting through where the building used to be)"},{"user":"Demellion","date":"2016-09-01T12:04:00Z","text":"As of **A3 1,62.134494** running **hideObjectGlobal** in big loop may cause some objects not to be hidden for a players already connected or passed **JIP**. To avoid players rendering desync consider running that in **preInit** schedule of a server."},{"user":"DrSova","date":"2017-08-07T12:44:00Z","text":"In **A3 1.72.142342** when you hide object via hideObjectGlobal, model sounds still be audible.\nFor e.g. if you delete apex house from map, you still hear a conditioner sound at this spot"},{"user":"Tankbuster","date":"2018-10-13T18:36:00Z","text":"Eventhandlers such as \"explosion\" will work on hidden objects"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.12","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"hideSelection","operator":null,"title":"hideSelection","type":"command","url":"https://community.bistudio.com/wiki/hideSelection","revid":330039,"updated":"2022-08-15T15:23:51Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Hides or shows the simple object's provided selection.","syntaxes":[{"syntax":"object hideSelection [selection, hidden]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"simple object","types":["Object"],"since":null,"text":"object: Object - simple object"},{"name":"selection","type":"String","optional":false,"default":null,"description":"selection name","types":["String"],"since":null,"text":"selection: String - selection name"},{"name":"hidden","type":"Boolean","optional":false,"default":null,"description":"true to hide, false to show","types":["Boolean"],"since":null,"text":"hidden: Boolean - true to hide, false to show"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selection, hidden]","types":["Array"]}}],"examples":[{"text":"```sqf\n_simpleObject hideSelection [\"some_selection\", true];\n```","code":["_simpleObject hideSelection [\"some_selection\", true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleObject","selectionNames","allLODs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"hint","operator":null,"title":"hint","type":"command","url":"https://community.bistudio.com/wiki/hint","revid":376426,"updated":"2025-10-12T22:43:43Z","groups":["Interaction","Structured Text","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Outputs a hint message to the right of the screen (left of the screen in Operation Flashpoint) with a sound (except in Armed Assault).\nTo split message in multiple lines either use Structured Text or `\\n` (in lower case).\n\n> [!NOTE]\n> **Armed Assault:** Armed Assault hints are silent. For later titles, see hintSilent.","syntaxes":[{"syntax":"hint message","since":null,"effect":null,"exec":null,"params":[{"name":"message","type":"String or Structured Text","optional":false,"default":null,"description":"the message to display.","types":["String","Structured Text"],"since":null,"text":"message: String or Structured Text - the message to display."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"message","types":["String","Structured Text"]}}],"examples":[{"text":"```sqf\n// outputs the following:\n// Press W to move forward.\n// Press S to move backwards.\nhint \"Press W to move forward.\\nPress S to move backwards.\"\n```","code":["// outputs the following:\n// Press W to move forward.\n// Press S to move backwards.\nhint \"Press W to move forward.\\nPress S to move backwards.\""]},{"text":"```sqf\nhint format [\"Hello, %1!\", name player];\n```","code":["hint format [\"Hello, %1!\", name player];"]},{"text":"```sqf\nhint str count allPlayers;\nsleep 10;\nhintSilent \"\"; // hides the previous hint display\n```","code":["hint str count allPlayers;\nsleep 10;\nhintSilent \"\"; // hides the previous hint display"]},{"text":"```sqf\nhint parseText \"<t size='2.0'>Large text</t>\"; // displays text twice as large as the default one\n```","code":["hint parseText \"<t size='2.0'>Large text</t>\"; // displays text twice as large as the default one"]},{"text":"```sqf\n_txt = text \"Red text, right align\";\n_txt setAttributes [\"color\", \"#FF0000\", \"align\", \"right\"];\nhint composeText [_txt];\n```","code":["_txt = text \"Red text, right align\";\n_txt setAttributes [\"color\", \"#FF0000\", \"align\", \"right\"];\nhint composeText [_txt];"]}],"multiplayer":null,"problems":"Operation Flashpoint v1.00 Armed Assault v1.00 Arma 2 v1.00 Hint messages that exceed the screen may lead to crashes.\n\nArma 3 v1.00 The game would not crash but suffer FPS drop / temporary freezing.","aliases":[],"see_also":["hintC","hintCadet","hintSilent","diag_log"],"notes":[{"user":"DreadedEntity","date":"2014-10-20T19:27:00Z","text":"Be careful when using hints to visualize the effects of commands using the Debug Console. Hint can accept an undefined variable and neither the error nor the hint is shown, the command simply fails. Also notice how the hint command should be `hint str _i;`:\n\n```sqf\nfor \"_i\" from 0 to 50 do\n{\n    hint _i;\n};\n```\n\n**tested in A3 1.32.127785**\n\nIn a script, an \"undefined variable\" error will be shown as expected."},{"user":"DreadedEntity","date":"2014-10-21T23:07:00Z","text":"Contrary to previous games, Arma 3 will happily display hints that far exceed screen space.\n\nHowever, as hints get longer, FPS suffers tremendously.\n\n**tested in Debug Console, A3 1.32.127785 with the following:**\n\n```sqf\nhint str ((nearestObjects [player, [\"BUILDING\"],  100]) - [player]); 0 spawn { sleep 5; systemChat str diag_fps; };\nsleep 10;\nhint str ((nearestObjects [player, [\"BUILDING\"], 1000]) - [player]); 0 spawn { sleep 5; systemChat str diag_fps; };\n```\n\nResults were: **59.7015** and **5.17297**, respectively. Drawing a hint even longer than this, such as nearestObjects with a radius of 10,000 or 100,000 reduces your FPS so much Arma 3 **appears** to crash, though it doesn't.\n\nUnrelated: Hints will stay on screen for 30 seconds, then fade away over the course of 5 seconds. **Tested with: A3 1.32.127785**"},{"user":"DreadedEntity","date":"2015-02-17T23:14:00Z","text":"An open dialog will pause the 30-second hint fade timer.\n**(A3 1.38.128937)**"},{"user":"Feint","date":"2017-03-25T20:47:00Z","text":"The hint sound is audible only when you have the music volume turned up above 0 in the audio settings.\nOtherwise, it seems to act the same as hintSilent.\n\nThis is important because if you are running a hint that fires at 30 fps or more, the hint will slow down machines that have the music volume turned up but won't slow down machines that have the music volume turned off.\n\nBest practice is to use hint for an alert to the player and use hintSilent for a makeshift display of data to the player that is updated fairly often."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Strings","Command Group: Structured Text","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"hintC","operator":null,"title":"hintC","type":"command","url":"https://community.bistudio.com/wiki/hintC","revid":369068,"updated":"2024-09-02T20:24:57Z","groups":["Interaction","Structured Text","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Displays a very basic message dialog in the center of the screen. Player control is taken away until \"Continue\" is pressed. The message dialog can be dragged around on the screen. After \"Continue\" has been pressed, the content of the hintC is repeated in a normal hint.\n\n> [!NOTE]\n> In Singleplayer, the game is paused while the message dialog is visible.","syntaxes":[{"syntax":"hintC message","since":null,"effect":null,"exec":null,"params":[{"name":"message","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"message: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"message","types":["String"]}},{"syntax":"title hintC message","since":null,"effect":null,"exec":null,"params":[{"name":"title","type":"String","optional":false,"default":null,"description":"message title","types":["String"],"since":null,"text":"title: String - message title"},{"name":"message","type":"String, Structured Text, Array of Strings or Array of Structured Text","optional":false,"default":null,"description":null,"types":["String","Structured Text","Array"],"since":null,"text":"message: String, Structured Text, Array of Strings or Array of Structured Text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"title","types":["String"]},"right":{"text":"message","types":["String","Structured Text","Array"]}}],"examples":[{"text":"```sqf\nhintC \"Press W to move forward\";\n```","code":["hintC \"Press W to move forward\";"]},{"text":"Same as the above in Arma 3 but without second hint displayed:\n\n```sqf\nhintC \"Press W to move forward\";\nhintC_EH = findDisplay 57 displayAddEventHandler [\"Unload\", {\n    _this spawn {\n        _this select 0 displayRemoveEventHandler [\"Unload\", hintC_EH];\n        hintSilent \"\";\n    };\n}];\n```","code":["hintC \"Press W to move forward\";\nhintC_EH = findDisplay 57 displayAddEventHandler [\"Unload\", {\n\t_this spawn {\n\t\t_this select 0 displayRemoveEventHandler [\"Unload\", hintC_EH];\n\t\thintSilent \"\";\n\t};\n}];"]},{"text":"```sqf\n\"Instructions\" hintC [\n    \"Press W to move forward.\",\n    \"Press S to move backwards.\",\n    \"Use the mouse to turn right or left.\",\n    \"Press V for weapon sights.\"\n];\n```","code":["\"Instructions\" hintC [\n\t\"Press W to move forward.\",\n\t\"Press S to move backwards.\",\n\t\"Use the mouse to turn right or left.\",\n\t\"Press V for weapon sights.\"\n];"]},{"text":"Same as the above in Arma 3 but without second hint displayed:\n\n```sqf\n\"Instructions\" hintC [\n    \"Press W to move forward.\",\n    \"Press S to move backwards.\",\n    \"Use the mouse to turn right or left.\",\n    \"Press V for weapon sights.\"\n];\nhintC_EH = findDisplay 72 displayAddEventHandler [\"Unload\", {\n    _this spawn {\n        _this select 0 displayRemoveEventHandler [\"Unload\", hintC_EH];\n        hintSilent \"\";\n    };\n}];\n```","code":["\"Instructions\" hintC [\n\t\"Press W to move forward.\",\n\t\"Press S to move backwards.\",\n\t\"Use the mouse to turn right or left.\",\n\t\"Press V for weapon sights.\"\n];\nhintC_EH = findDisplay 72 displayAddEventHandler [\"Unload\", {\n\t_this spawn {\n\t\t_this select 0 displayRemoveEventHandler [\"Unload\", hintC_EH];\n\t\thintSilent \"\";\n\t};\n}];"]},{"text":"```sqf\nprivate _separator = parseText \"<br/>------------------------<br/>\";\nprivate _image = \"\\ca\\ui\\textures\\aus_flag.paa\";\nprivate _message = composeText [image _image, \"Heading Text\", _separator, \"Content\"];\n\"\" hintC _message;\n```","code":["private _separator = parseText \"<br/>------------------------<br/>\";\nprivate _image = \"\\ca\\ui\\textures\\aus_flag.paa\";\nprivate _message = composeText [image _image, \"Heading Text\", _separator, \"Content\"];\n\"\" hintC _message;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hint","hintCadet","hintSilent","BIS_fnc_guiMessage"],"notes":[{"user":"Str","date":"2006-07-31T18:18:00Z","text":"This command must be executed after mission start. If you place it into init.sqs or init field of some unit, it will not work. Just add a little delay (~0.001) and the place the command."},{"user":"Worldeater","date":"2009-05-15T23:42:00Z","text":"To display multiple messages after another you have to add a small delay in between. Otherwise only the first message will be displayed.\n\n```sqf\nhintC \"foo\"; sleep 0.1; hintC \"bar\"\n```\n\nWithout a sleep statement hintC will not suspend the script it has been called from."},{"user":"Killzone_Kid","date":"2015-03-19T09:52:00Z","text":"\"Titled\" hintC uses `display #72` while \"untitled\" one uses `display #57`. If you are trying examples in Arma 3 debug console, add a little delay like this:\n\n```sqf\n0 spawn { sleep 0.5; /* your example code goes here*/ };\n```\n\n or no hintC will be displayed."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Strings","Command Group: Structured Text","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"hintCadet","operator":null,"title":"hintCadet","type":"command","url":"https://community.bistudio.com/wiki/hintCadet","revid":308950,"updated":"2022-04-18T20:23:13Z","groups":["Interaction","Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Shows a text hint only when in cadetMode.\n\nThe text can contain several lines. \\n is used to indicate the end of a line.","syntaxes":[{"syntax":"hintCadet text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\nhintCadet \"Press W to move forward\";\n```","code":["hintCadet \"Press W to move forward\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hint","hintC","hintSilent","cadetMode"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"hintSilent","operator":null,"title":"hintSilent","type":"command","url":"https://community.bistudio.com/wiki/hintSilent","revid":308951,"updated":"2022-04-18T20:23:57Z","groups":["Interaction","Structured Text","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Same as hint, but without a sound.","syntaxes":[{"syntax":"hintSilent text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String or Structured Text","optional":false,"default":null,"description":null,"types":["String","Structured Text"],"since":null,"text":"text: String or Structured Text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String","Structured Text"]}}],"examples":[{"text":"```sqf\nhintSilent format [\"Hello, %1!\", name player];\n```","code":["hintSilent format [\"Hello, %1!\", name player];"]},{"text":"```sqf\nhint \"Hello there!\";\nsleep 5;\nhintSilent \"\"; // removes message\n```","code":["hint \"Hello there!\";\nsleep 5;\nhintSilent \"\"; // removes message"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hint","hintC","hintCadet"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Strings","Command Group: Structured Text","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"hmd","operator":null,"title":"hmd","type":"command","url":"https://community.bistudio.com/wiki/hmd","revid":352035,"updated":"2024-02-01T23:24:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns class name of currently used Head Mounted Display. Returns an empty string if the slot is empty.\n\n> [!NOTE]\n> If hmd returns \"\" this doesn't immediately mean unit has no hmd, some items like Special Helmet (\"H_HelmetO_ViperSP_ghex_F\") can have built-in hmd so you might want to check the type of headgear as well","syntaxes":[{"syntax":"hmd unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_nvgs = hmd player; //NVGoggles\n```","code":["_nvgs = hmd player; //NVGoggles"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["headgear","goggles","binocular"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"hostMission","operator":null,"title":"hostMission","type":"command","url":"https://community.bistudio.com/wiki/hostMission","revid":369139,"updated":"2024-09-03T10:34:36Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Host the multiplayer mission defined in the config class and opens the lobby with the scenario loaded. Must be called in UI action from a dialog.","syntaxes":[{"syntax":"hostMission [configEntry, activeDisplay]","since":null,"effect":null,"exec":null,"params":[{"name":"configEntry","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"configEntry: Config"},{"name":"activeDisplay","type":"Display","optional":false,"default":null,"description":null,"types":["Display"],"since":null,"text":"activeDisplay: Display"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[configEntry, activeDisplay]","types":["Array"]}}],"examples":[{"text":"```sqf\nhostMission [configFile >> \"CfgMissions\" >> \"MPMissions\" >> _scenarioClassName, _currentlyActiveDisplay];\n```","code":["hostMission [configFile >> \"CfgMissions\" >> \"MPMissions\" >> _scenarioClassName, _currentlyActiveDisplay];"]},{"text":"Launch host mission dialog from a client on dedicated server in Arma 3:\n\n```sqf\nhostMission [\n    configFile >> \"CfgMissions\" >> \"MPmissions\" >> \"MP_COOP_m01\",\n    findDisplay 46\n];\n```","code":["hostMission [\n\tconfigFile >> \"CfgMissions\" >> \"MPmissions\" >> \"MP_COOP_m01\",\n\tfindDisplay 46\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playScriptedMission","playMission","createMPCampaignDisplay","createMissionDisplay"],"notes":[{"user":".kju","date":"2011-01-03T16:51:00Z","text":"The command must be called in the main menu or something similar menu it seems."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"htmlLoad","operator":null,"title":"htmlLoad","type":"command","url":"https://community.bistudio.com/wiki/htmlLoad","revid":369066,"updated":"2024-09-02T20:24:56Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Load HTML from file or URI using given control. File path is relative to current mission dir or an absolute path (with drive letter etc.).\nThe command is subject to restrictions, imposed by CfgCommands class.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v2.10 the 'title' attribute is supported within <img> and <a> html tags\n\n> [!IMPORTANT]\n> For unknown reasons, URL's length is limited to 255 characters.","syntaxes":[{"syntax":"control htmlLoad filename","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"filename","type":"String","optional":false,"default":null,"description":"local file name or remote file URL","types":["String"],"since":null,"text":"filename: String - local file name or remote file URL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\n_control htmlLoad \"briefing.html\";\n```","code":["_control htmlLoad \"briefing.html\";"]},{"text":"```sqf\n_control htmlLoad \"http://www.bistudio.com/newsfeed/arma3_news.php?build=main&language=English\";\n```","code":["_control htmlLoad \"http://www.bistudio.com/newsfeed/arma3_news.php?build=main&language=English\";"]},{"text":"Display news item:\n\n```sqf\n0 spawn {\n    disableSerialization;\n    private _html = findDisplay 46 createDisplay \"RscCredits\" ctrlCreate [\"RscHTML\", -1];\n    _html ctrlSetBackgroundColor [0,0,0,0.8];\n    _html ctrlSetPosition [safeZoneX, safeZoneY, safeZoneW, safeZoneH];\n    _html ctrlCommit 0;\n    _html htmlLoad \"http://www.bistudio.com/newsfeed/arma3_news.php?build=main&language=English\";\n};\n```","code":["0 spawn {\n\tdisableSerialization;\n\tprivate _html = findDisplay 46 createDisplay \"RscCredits\" ctrlCreate [\"RscHTML\", -1];\n\t_html ctrlSetBackgroundColor [0,0,0,0.8];\n\t_html ctrlSetPosition [safeZoneX, safeZoneY, safeZoneW, safeZoneH];\n\t_html ctrlCommit 0;\n\t_html htmlLoad \"http://www.bistudio.com/newsfeed/arma3_news.php?build=main&language=English\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlHTMLLoaded","loadFile","preprocessFile","preprocessFileLineNumbers","HTML File Format"],"notes":[{"user":"BrotherhoodOfHam","date":"2014-09-07T18:02:00Z","text":"htmlLoad works with URLs as well as html files."},{"user":"Killzone_Kid","date":"2014-09-07T19:35:00Z","text":"While htmlLoad surprisingly does work with URLs as pointed above, the operation is blocking, meaning the whole game will freeze until the operation is complete.\nIt is therefore not recommended to use this command in such way."},{"user":"Benargee","date":"2015-04-21T18:08:00Z","text":"Example use of URL can be found in BIS_fnc_GUInewsfeed with the function browser."},{"user":"Tupolov","date":"2015-10-07T22:03:00Z","text":"(Arma 3) In order to use URLs, they must be included in CfgCommands -> allowedHTMLLoadURIs. In order to use URIs with params a wildcard * character is supported:\n**Script**\n\n```sqf\n_newsOnline = \"http://alivemod.com/alive_news.php?map=\" + _map + \"&mission=\" + _mission + \"&player=\" + _player;\n_ctrlHTML htmlLoad _newsOnline;\n```\n\n**Config**\n\n```cpp\nclass CfgCommands {\n    allowedHTMLLoadURIs[] += {\n        \"http://alivemod.com/alive_news.php*\"\n    };\n};\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"HUDMovementLevels","operator":null,"title":"HUDMovementLevels","type":"command","url":"https://community.bistudio.com/wiki/HUDMovementLevels","revid":378504,"updated":"2026-05-03T16:49:48Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns movement borders for HUD","syntaxes":[{"syntax":"HUDMovementLevels","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [minSpeed, maxSpeed, minAlt, maxAlt, minDir, maxDir, positionOrTarget]","types":["Array"],"description":"minSpeed: Number - in m/s - maxSpeed: Number - in m/s - minAlt: Number - in meters - maxAlt: Number - in meters - minDir: Number - in degrees - maxDir: Number - in degrees - positionOrTarget: Position, Object","text":"Array with [minSpeed, maxSpeed, minAlt, maxAlt, minDir, maxDir, positionOrTarget]\n- minSpeed: Number - in m/s\n- maxSpeed: Number - in m/s\n- minAlt: Number - in meters\n- maxAlt: Number - in meters\n- minDir: Number - in degrees\n- maxDir: Number - in degrees\n- positionOrTarget: Position, Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nHUDMovementLevels; // returns e.g [0,0,0,0,0,0,[0,0,0]]\n```","code":["HUDMovementLevels; // returns e.g [0,0,0,0,0,0,[0,0,0]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setHUDMovementLevels"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"humidity","operator":null,"title":"humidity","type":"command","url":"https://community.bistudio.com/wiki/humidity","revid":376954,"updated":"2026-01-01T05:39:46Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current humidity value. 0 is no humidity and 1 is 100% humidity. Humidity value quickly changes from 0 to 1 when rain starts, then slowly changes from 1 to 0 when rain stops.","syntaxes":[{"syntax":"humidity","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ncurrentHumidity = humidity;\n```","code":["currentHumidity = humidity;"]},{"text":"```sqf\nskipTime -24;\n86400 setOvercast 1;\nskipTime 24;\n0 spawn {\n    10 setRain 1;\n    sleep 10;\n    10 setRain 0;\n};\nonEachFrame {\n    hintSilent str [round (rain * 10) / 10, round (humidity * 10) / 10];\n};\n```","code":["skipTime -24;\n86400 setOvercast 1;\nskipTime 24;\n0 spawn {\n\t10 setRain 1;\n\tsleep 10;\n\t10 setRain 0;\n};\nonEachFrame {\n\thintSilent str [round (rain * 10) / 10, round (humidity * 10) / 10];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setHumidity","simulSetHumidity","setOvercast","setRain","rain","overcast","fog","wind","waves"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"if","operator":null,"title":"if","type":"command","url":"https://community.bistudio.com/wiki/if","revid":369387,"updated":"2024-09-03T18:43:16Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This operator creates a If Type which is used in the if-construct as described here.","syntaxes":[{"syntax":"if condition","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"Boolean","optional":false,"default":null,"description":"if it evaluates as true, the then clause is executed.  Otherwise, the else clause (if present) is executed","types":["Boolean"],"since":null,"text":"condition: Boolean - if it evaluates as true, the then clause is executed.  Otherwise, the else clause (if present) is executed"}],"returns":{"type":"If Type","types":["If Type"],"description":"predicate which will execute 1st or 2nd option when used. This predicate is used in then or exitWith commands","text":"If Type - predicate which will execute 1st or 2nd option when used. This predicate is used in then or exitWith commands"},"form":"unary","operator":null,"left":null,"right":{"text":"condition","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_retVal = if (1 > 0) then { \"It's true\" } else { \"It's false\" };\nhint str _retVal;\n```","code":["_retVal = if (1 > 0) then { \"It's true\" } else { \"It's false\" };\nhint str _retVal;"]},{"text":"```sqf\n_val = if (true) then [{ \"true\" }, { \"false\" }];\nhint _val;\n```","code":["_val = if (true) then [{ \"true\" }, { \"false\" }];\nhint _val;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["else","exitWith","then","Control Structures","Code Optimisation"],"notes":[{"user":"Ceeeb","date":"2007-01-31T04:08:00Z","text":"Any _local variables you declare within the body of an if/then statement (ie between the curly braces) are local to that 'if' statement, and are destroyed at the end of the statement. If you know you want to use the variable outside the 'if' statement, make sure your declare it before the 'if' statement."},{"user":"Galzohar","date":"2010-01-17T02:40:00Z","text":"If the condition is nil then neither the \"then\" nor the \"else\" section get executed, but the script will proceed with no error messages.\n\nExample code:\n\n```sqf\nsystemChat \"script started\";    // will get executed\nif (nil) then\n{\n    systemChat \"true\";            // will never get executed\n}\nelse\n{\n    systemChat \"false\";            // will never get executed\n};\nsystemChat \"script ended\";        // will get executed\n```"},{"user":"AgentRev","date":"2015-06-05T09:35:00Z","text":"If you only need to choose between 2 raw values, it is possible to use the following trick to avoid using code blocks, as required by the if command, which results in greater atomicity and faster execution:\n\n```sqf\n_result = [falseValue, trueValue] select condition;\n```\n\nThe select command treats \"false\" as 0 and \"true\" as 1, therefore you can feed it a condition determining the array index of the value to be returned. Here is another example:\n\n```sqf\n_result = [1,-1] select (_this < 0); // if _this is less than 0, _result will be equal to -1, otherwise it will be 1\n```"},{"user":"DreadedEntity","date":"2022-05-19T01:11:46Z","text":"When using **if** to assign values to a variable, if you not have an else block it is treated as nil and returned, setting the variable value to nil. A3 2.08.149102\n\n```sqf\nprivate _myVar = \"value\";\nprivate _condition = false;\n_myVar = if (_condition) then { \"another value\" }; //perfectly valid sqf\nsystemChat str (isNil \"_myVar\"); //returns true\n//_myVar is now nil\n_myVar = if (_condition) then { \"another value\" } else { \"value\" };\nsystemChat _myVar; //returns \"value\"\n```\n\nThis behavior can be both desirable and undesirable depending on your needs"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ignore3DENHistory","operator":null,"title":"ignore3DENHistory","type":"command","url":"https://community.bistudio.com/wiki/ignore3DENHistory","revid":370529,"updated":"2025-01-02T11:51:16Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Ignores all history steps created by executing the given code.","syntaxes":[{"syntax":"ignore3DENHistory code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nignore3DENHistory {\n    create3DENEntity [\"Object\", \"B_Soldier_F\", screenToWorld [0.5, 0.5]]; // no Ctrl+Z available for this operation\n};\n```","code":["ignore3DENHistory {\n\tcreate3DENEntity [\"Object\", \"B_Soldier_F\", screenToWorld [0.5, 0.5]]; // no Ctrl+Z available for this operation\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["collect3DENHistory","create3DENEntity","set3DENAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"ignoreTarget","operator":null,"title":"ignoreTarget","type":"command","url":"https://community.bistudio.com/wiki/ignoreTarget","revid":369769,"updated":"2024-10-08T15:08:58Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Sets a target to be ignored by this Group. It will not appear in nearTargets and the group will not notice its presence. targetKnowledge can be used to check if a target is currently ignored. While a unit is ignored, reveal has no effect.","syntaxes":[{"syntax":"group ignoreTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":"which receives revealing information","types":["Object","Group"],"since":null,"text":"group : Object or Group - which receives revealing information"},{"name":"target","type":"Object","optional":false,"default":null,"description":"which would be ignored","types":["Object"],"since":null,"text":"target: Object - which would be ignored"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"target","types":["Object"]}},{"syntax":"group ignoreTarget [target, isIgnored]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":"which receives revealing information","types":["Object","Group"],"since":null,"text":"group : Object or Group - which receives revealing information"},{"name":"target","type":"Object","optional":false,"default":null,"description":"which would be ignored","types":["Object"],"since":null,"text":"target: Object - which would be ignored"},{"name":"isIgnored","type":"Boolean","optional":false,"default":null,"description":"whether the target should be ignored","types":["Boolean"],"since":null,"text":"isIgnored: Boolean - whether the target should be ignored"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"[target, isIgnored]","types":["Array"]}}],"examples":[{"text":"```sqf\naiGroup ignoreTarget player\n```","code":["aiGroup ignoreTarget player"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["knowsAbout","targetsQuery","targetsAggregate","nearTargets","reveal","targetKnowledge"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"image","operator":null,"title":"image","type":"command","url":"https://community.bistudio.com/wiki/image","revid":341003,"updated":"2023-05-13T22:06:20Z","groups":["Strings","GUI Control","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a structured text containing the given image. Use setAttributes to set additional attributes on the image.","syntaxes":[{"syntax":"image filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"filename: String"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\nhint composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];\n```","code":["hint composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"];"]},{"text":"```sqf\nhint str (composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"] == parseText \"Image: <img image='\\a3\\Data_f\\Flags\\flag_Altis_co.paa'/>\"); // true\n```","code":["hint str (composeText [\"Image: \", image \"\\a3\\Data_f\\Flags\\flag_Altis_co.paa\"] == parseText \"Image: <img image='\\a3\\Data_f\\Flags\\flag_Altis_co.paa'/>\"); // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAttributes","parseText","text","composeText","lineBreak"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Strings","Command Group: Structured Text","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"import","operator":null,"title":"import","type":"command","url":"https://community.bistudio.com/wiki/import","revid":369760,"updated":"2024-10-08T15:08:56Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Imports one or multiple local variables from the parent scope, and defines them as private variables in the current scope. It can bypass privateAll.\n\n> [!NOTE]\n> For the config keyword, see import (Config).","syntaxes":[{"syntax":"import variableName","since":null,"effect":null,"exec":null,"params":[{"name":"variableName","type":"String or Array of Strings","optional":false,"default":null,"description":"variable(s) to import","types":["String","Array"],"since":null,"text":"variableName: String or Array of Strings - variable(s) to import"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"variableName","types":["String","Array"]}}],"examples":[{"text":"```sqf\nprivate _myVar = 1;\ncall\n{\n    import \"_myVar\"; // similar to: private _myVar = _myVar;\n};\n```","code":["private _myVar = 1;\ncall\n{\n\timport \"_myVar\"; // similar to: private _myVar = _myVar;\n};"]},{"text":"```sqf\nprivate _a = 1;\nprivate _b = 2;\ncall\n{\n    import [\"_a\", \"_b\"]; // similar to: [_a, _b] params [\"_a\", \"_b\"];\n};\n```","code":["private _a = 1;\nprivate _b = 2;\ncall\n{\n\timport [\"_a\", \"_b\"]; // similar to: [_a, _b] params [\"_a\", \"_b\"];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["privateAll","private","params"],"notes":[{"user":"Hypoxic125","date":"2024-03-03T18:31:25Z","text":"When making local functions, the imported variable does not have to exist until the function is called.\n\n```sqf\n// Local function\nprivate _stringifyNum = {\n    import \"_num\";\n    str _num;\n};\n\nprivate _num = 5;\ncall _stringifyNum;\n// Returns \"5\"\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"importAllGroups","operator":null,"title":"importAllGroups","type":"command","url":"https://community.bistudio.com/wiki/importAllGroups","revid":363295,"updated":"2024-03-26T10:52:01Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Imports all groups into the RTE.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"importAllGroups map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"importance","operator":null,"title":"importance","type":"command","url":"https://community.bistudio.com/wiki/importance","revid":323028,"updated":"2022-06-28T21:43:08Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a location's importance value.","syntaxes":[{"syntax":"importance location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_locationImportance = importance myLocation;\n```","code":["_locationImportance = importance myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setImportance"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"in","operator":null,"title":"in","type":"command","url":"https://community.bistudio.com/wiki/in","revid":377765,"updated":"2026-01-03T01:00:35Z","groups":["Strings","Arrays","Locations","HashMap","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether value is in array, unit is in vehicle, position is inside location or ANSI string is part of other ANSI string. If Unicode support is desired, see forceUnicode.\n\n> [!NOTE]\n> String comparison is case-sensitive (see Examples **2** and **6**).","syntaxes":[{"syntax":"value in array","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Anything","optional":false,"default":null,"description":"any value (cannot  match Array before Arma 3)","types":["Anything"],"since":null,"text":"value: Anything - any value (cannot  match Array before Arma 3)"},{"name":"array","type":"Array","optional":false,"default":null,"description":"array of values","types":["Array"],"since":null,"text":"array: Array - array of values"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"value","types":["Anything"]},"right":{"text":"array","types":["Array"]}},{"syntax":"unit in vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"alive unit","types":["Object"],"since":null,"text":"unit: Object - alive unit"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"entity vehicle","types":["Object"],"since":null,"text":"vehicle: Object - entity vehicle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}},{"syntax":"position in location","since":"arma3 0.50","effect":null,"exec":null,"params":[{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":null,"types":["Position2D","Position3D"],"since":null,"text":"position: Position2D or Position3D"},{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"position","types":["Position2D","Position3D"]},"right":{"text":"location","types":["Location"]}},{"syntax":"needle in haystack","since":"arma3 1.96","effect":null,"exec":null,"params":[{"name":"needle","type":"String","optional":false,"default":null,"description":"string to search **for**","types":["String"],"since":null,"text":"needle: String - string to search **for**"},{"name":"haystack","type":"String","optional":false,"default":null,"description":"string to search **in**","types":["String"],"since":null,"text":"haystack: String - string to search **in**"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"needle","types":["String"]},"right":{"text":"haystack","types":["String"]}},{"syntax":"key in hashMap","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":null,"types":["HashMapKey"],"since":null,"text":"key: HashMapKey"},{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap : HashMap"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"key","types":["HashMapKey"]},"right":{"text":"hashMap","types":["HashMap"]}}],"examples":[{"text":"```sqf\n1 in [0, 1, 2]; // true\n```","code":["1 in [0, 1, 2]; // true"]},{"text":"```sqf\nprivate _myArray = [\"Aaa\", \"AAa\", \"AAA\"];\n\n\"aaa\" in _myArray; // false\n\"AAa\" in _myArray; // true\n\n// Case-insensitive alternatives:\n_myArray findIf { _x == \"aaa\"; } != -1; // true\n\n({\n    if (_x == \"aaa\") exitWith { _forEachIndex };\n    -1\n} forEach _myArray) != -1; // true, less performant but valid before the introduction of the findIf command\n\n{ if (_x == \"aaa\") exitWith { 1 } } count _myArray > 0; // true\n\n{ _x == \"aaa\"; } count _myArray > 0; // true, worst performance, only option available in OFP\n```","code":["private _myArray = [\"Aaa\", \"AAa\", \"AAA\"];\n\n\"aaa\" in _myArray; // false\n\"AAa\" in _myArray; // true\n\n// Case-insensitive alternatives:\n_myArray findIf { _x == \"aaa\"; } != -1; // true\n\n({\n\tif (_x == \"aaa\") exitWith { _forEachIndex };\n\t-1\n} forEach _myArray) != -1; // true, less performant but valid before the introduction of the findIf command\n\n{ if (_x == \"aaa\") exitWith { 1 } } count _myArray > 0; // true\n\n{ _x == \"aaa\"; } count _myArray > 0; // true, worst performance, only option available in OFP"]},{"text":"```sqf\n[1,2,3] in [[1,2,3], [4,5,6]]; // true - Arma 3 only\n```","code":["[1,2,3] in [[1,2,3], [4,5,6]]; // true - Arma 3 only"]},{"text":"```sqf\nprivate _isInCar = player in Car;\n```","code":["private _isInCar = player in Car;"]},{"text":"```sqf\nprivate _isInside = [1000,2000,0] in MyLocation;\n```","code":["private _isInside = [1000,2000,0] in MyLocation;"]},{"text":"```sqf\nprivate _isInString = \"foo\" in \"foobar\"; // true\n_isInString = \"Foo\" in \"foobar\"; // false\n```","code":["private _isInString = \"foo\" in \"foobar\"; // true\n_isInString = \"Foo\" in \"foobar\"; // false"]},{"text":"```sqf\nprivate _onFoot = _unit in _unit;\n```\n\nOther options:\n\n```sqf\nprivate _onFoot = vehicle _unit == _unit;\n```\n\n```sqf\nprivate _onFoot = isNull objectParent _unit;\n```","code":["private _onFoot = _unit in _unit;","private _onFoot = vehicle _unit == _unit;","private _onFoot = isNull objectParent _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inPolygon","inArea","find","findIf","toArray","forceUnicode"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Command Group: Locations","Command Group: Strings","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"inArea","operator":null,"title":"inArea","type":"command","url":"https://community.bistudio.com/wiki/inArea","revid":377541,"updated":"2026-01-02T06:54:31Z","groups":["Triggers","Markers","Locations","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether given position or object is inside given area. Use inAreaArray to check multiple positions/objects within area.\n\n> [!IMPORTANT]\n> By default all positions given as Array or as objects are treated as PositionAGL. Since Arma 3 v2.20 there is an option to force them to PositionWorld format.\n\n> [!NOTE]\n> This command also supports hexagon area which can be created from ellipse when both a and b are negative.\n> Hexagon ellipses are also supported by both marker creation and drawEllipse.","syntaxes":[{"syntax":"position inArea area","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":null,"optional":false,"default":null,"description":"Object or Position2D or Position3D (must be PositionAGL if area is checked in 3D)","types":["Object","Position2D","Position3D","PositionAGL"],"since":null,"text":"position: Object or Position2D or Position3D (must be PositionAGL if area is checked in 3D)"},{"name":"area","type":"Object, String, Location","optional":false,"default":null,"description":"Object, String, Location\n- Object - trigger\n- String - marker name\n- Location - location","types":["Object","String","Location"],"since":null,"text":"area: Object, String, Location\n- Object - trigger\n- String - marker name\n- Location - location"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"position","types":["Object","Position2D","Position3D","PositionAGL"]},"right":{"text":"area","types":["Object","String","Location"]}},{"syntax":"position inArea [center, a, b, angle, isRectangle, c, usePosWorld]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":null,"optional":false,"default":null,"description":"Object and/or Position to check. Position must be PositionAGL if area is checked in 3D (see note in description)","types":[],"since":null,"text":"position: - Object and/or Position to check. Position must be PositionAGL if area is checked in 3D (see note in description)"},{"name":"center","type":"Array or Object","optional":false,"default":null,"description":"center of the area in format Position2D, Position3D (must be PositionAGL if area is checked in 3D), Object or Group","types":["Array","Object"],"since":null,"text":"center: Array or Object - center of the area in format Position2D, Position3D (must be PositionAGL if area is checked in 3D), Object or Group"},{"name":"a","type":"Number","optional":false,"default":null,"description":"x axis (x / 2)","types":["Number"],"since":null,"text":"a: Number - x axis (x / 2)"},{"name":"b","type":"Number","optional":false,"default":null,"description":"y axis (y / 2)","types":["Number"],"since":null,"text":"b: Number - y axis (y / 2)"},{"name":"angle","type":"Number","optional":true,"default":"0","description":"rotation angle","types":["Number"],"since":null,"text":"angle: Number - (Optional since 2.20, Default: 0) rotation angle"},{"name":"isRectangle","type":"Boolean","optional":true,"default":"false","description":"true if rectangle, false if ellipse","types":["Boolean"],"since":null,"text":"isRectangle: Boolean - (Optional since 2.20, Default: false) true if rectangle, false if ellipse"},{"name":"c","type":"Number","optional":true,"default":"-1 (unlimited)","description":"z axis (z / 2)","types":["Number"],"since":"arma3 1.60","text":"c: Number - (Optional, default -1 (unlimited)) z axis (z / 2)"},{"name":"usePosWorld","type":"Boolean","optional":true,"default":"false","description":"set to true to treat all positions as PositionWorld","types":["Boolean"],"since":"Arma3 2.20","text":"usePosWorld: Boolean - (Optional, default false) set to true to treat all positions as PositionWorld"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"position","types":[]},"right":{"text":"[center, a, b, angle, isRectangle, c, usePosWorld]","types":["Array"]}}],"examples":[{"text":"```sqf\n_playerIsInside = player inArea _myTrigger;\n```","code":["_playerIsInside = player inArea _myTrigger;"]},{"text":"```sqf\n_positionIsInside = _myPosition inArea [[100, 100, 0], 20, 30, 45, false];\n```","code":["_positionIsInside = _myPosition inArea [[100, 100, 0], 20, 30, 45, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inAreaArray","triggerArea","in","inPolygon","drawEllipse","drawRectangle","createTrigger","createMarker","createLocation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Markers","Command Group: Positions","Command Group: Triggers","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"inAreaArray","operator":null,"title":"inAreaArray","type":"command","url":"https://community.bistudio.com/wiki/inAreaArray","revid":378040,"updated":"2026-01-27T13:05:40Z","groups":["Triggers","Markers","Locations","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns given list of Objects and/or Positions that are in the given area, area defined by a trigger, marker, location or array.\n\n> [!IMPORTANT]\n> By default all positions given as Array or as objects are treated as PositionAGL. Since Arma 3 v2.20 there is an option to force them to PositionWorld format.","syntaxes":[{"syntax":"positions inAreaArray area","since":null,"effect":null,"exec":null,"params":[{"name":"positions","type":"Array of Objects and/or Positions","optional":false,"default":null,"description":null,"types":["Array","Object","Position"],"since":null,"text":"positions: Array of Objects and/or Positions"},{"name":"area","type":"Object, Location or String","optional":false,"default":null,"description":"the defined area:\n- Object - trigger\n- Location - location\n- String - marker name","types":["Object","Location","String"],"since":null,"text":"area: Object, Location or String - the defined area:\n- Object - trigger\n- Location - location\n- String - marker name"}],"returns":{"type":"Array of Objects and/or Positions","types":["Array","Object","Position"],"description":null,"text":"Array of Objects and/or Positions"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array","Object","Position"]},"right":{"text":"area","types":["Object","Location","String"]}},{"syntax":"positions inAreaArray [centre, a, b, angle, isRectangle, c, usePosWorld]","since":null,"effect":null,"exec":null,"params":[{"name":"positions","type":"Array of Objects and/or Positions","optional":false,"default":null,"description":"Places to check. Positions must be PositionAGL if area is checked in 3D (see note in description)","types":["Array","Object","Position"],"since":null,"text":"positions: Array of Objects and/or Positions - Places to check. Positions must be PositionAGL if area is checked in 3D (see note in description)"},{"name":"centre","type":"Position2D, PositionAGL, Arma 3 v2.14 Object or Group","optional":false,"default":null,"description":null,"types":["Position2D","PositionAGL","Object","Group"],"since":null,"text":"centre: Position2D, PositionAGL, Arma 3 v2.14 Object or Group"},{"name":"a","type":"Number","optional":false,"default":null,"description":"x axis (x / 2)","types":["Number"],"since":null,"text":"a: Number - x axis (x / 2)"},{"name":"b","type":"Number","optional":false,"default":null,"description":"y axis (y / 2)","types":["Number"],"since":null,"text":"b: Number - y axis (y / 2)"},{"name":"angle","type":"Number","optional":true,"default":"0","description":"rotation angle","types":["Number"],"since":null,"text":"angle: Number - (Optional, default 0) rotation angle"},{"name":"isRectangle","type":"Boolean","optional":true,"default":"false","description":"true if rectangle, false if ellipse","types":["Boolean"],"since":null,"text":"isRectangle: Boolean - (Optional, default false) true if rectangle, false if ellipse"},{"name":"c","type":"Number","optional":true,"default":"-1: unlimited","description":"z axis (z / 2)","types":["Number"],"since":null,"text":"c: Number - (Optional, default -1: unlimited) z axis (z / 2)"},{"name":"usePosWorld","type":"Boolean","optional":true,"default":"false","description":"set to true to treat all positions as PositionWorld","types":["Boolean"],"since":"Arma3 2.20","text":"usePosWorld: Boolean - (Optional, default false) set to true to treat all positions as PositionWorld"}],"returns":{"type":"Array of Objects and/or Positions","types":["Array","Object","Position"],"description":null,"text":"Array of Objects and/or Positions"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array","Object","Position"]},"right":{"text":"[centre, a, b, angle, isRectangle, c, usePosWorld]","types":["Array"]}},{"syntax":"positions inAreaArray [pos1, pos2, pos3,...]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"positions","type":"Array of Objects and/or Positions","optional":false,"default":null,"description":"places to check.","types":["Array","Object","Position"],"since":null,"text":"positions: Array of Objects and/or Positions - places to check."},{"name":"posN","type":"Position","optional":false,"default":null,"description":"polygon vertices in 2d or 3d format (see inPolygon)","types":["Position"],"since":null,"text":"posN: Position - polygon vertices in 2d or 3d format (see inPolygon)"}],"returns":{"type":"Array of Objects and/or Positions","types":["Array","Object","Position"],"description":null,"text":"Array of Objects and/or Positions"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array","Object","Position"]},"right":{"text":"[pos1, pos2, pos3,...]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicles inAreaArray myTrigger;\n```","code":["vehicles inAreaArray myTrigger;"]},{"text":"```sqf\nallUnits inAreaArray \"myMarker\";\n```","code":["allUnits inAreaArray \"myMarker\";"]},{"text":"```sqf\nallPlayers inAreaArray myLocation;\n```","code":["allPlayers inAreaArray myLocation;"]},{"text":"```sqf\nallDead inAreaArray [[100, 100, 0], 20, 30, 45, false, 10];\n```","code":["allDead inAreaArray [[100, 100, 0], 20, 30, 45, false, 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inAreaArrayIndexes","inArea","triggerArea"],"notes":[{"user":"Tankbuster","date":"2017-06-11T21:33:00Z","text":"The array you send the command can be filtered. For example:\n\n```sqf\nvehicles select { _x isKindOf \"StaticWeapon\" } inAreaArray \"myMarker\"\n```\n\nWill return only the statics inside the given marker."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Markers","Command Group: Positions","Command Group: Triggers","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"inAreaArrayIndexes","operator":null,"title":"inAreaArrayIndexes","type":"command","url":"https://community.bistudio.com/wiki/inAreaArrayIndexes","revid":370140,"updated":"2024-11-01T21:37:46Z","groups":["Triggers","Markers","Locations","Positions","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns indices of positions that are within the provided area.\n\n> [!IMPORTANT]\n> Unlike inAreaArray, all positions sent to this command are treated as PositionASL but the center as PositionAGL.\n\n> [!IMPORTANT]\n> Since Arma 3 v2.20 this command is fully compatible with inAreaArray, i.e by default all positions given as Array or as objects are treated as PositionAGL. There is also an option to force them to PositionWorld format.","syntaxes":[{"syntax":"positions inAreaArrayIndexes area","since":null,"effect":null,"exec":null,"params":[{"name":"positions","type":"Array of Objects and/or Positions","optional":false,"default":null,"description":null,"types":["Array","Object","Position"],"since":null,"text":"positions: Array of Objects and/or Positions"},{"name":"area","type":"Object, Location or String","optional":false,"default":null,"description":"the defined area:\n- Object - trigger\n- Location - location\n- String - marker name","types":["Object","Location","String"],"since":null,"text":"area: Object, Location or String - the defined area:\n- Object - trigger\n- Location - location\n- String - marker name"}],"returns":{"type":"Array: Numbers","types":["Array","Number"],"description":"indexes of matched positions in positions array","text":"Array: Numbers - indexes of matched positions in positions array"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array","Object","Position"]},"right":{"text":"area","types":["Object","Location","String"]}},{"syntax":"positions inAreaArrayIndexes [centre, a, b, angle, isRectangle, c, usePosWorld]","since":null,"effect":null,"exec":null,"params":[{"name":"positions","type":"Array","optional":false,"default":null,"description":"Objects and/or Positions to check (see note in description)","types":["Array"],"since":null,"text":"positions: Array - Objects and/or Positions to check (see note in description)"},{"name":"centre","type":"Array","optional":false,"default":null,"description":"Position Object or Group (see note in description)","types":["Array"],"since":null,"text":"centre: Array - Position Object or Group (see note in description)"},{"name":"a","type":"Number","optional":false,"default":null,"description":"x axis (x / 2)","types":["Number"],"since":null,"text":"a: Number - x axis (x / 2)"},{"name":"b","type":"Number","optional":false,"default":null,"description":"y axis (y / 2)","types":["Number"],"since":null,"text":"b: Number - y axis (y / 2)"},{"name":"angle","type":"Number","optional":true,"default":"0","description":"rotation angle","types":["Number"],"since":null,"text":"angle: Number - (Optional, default 0) rotation angle"},{"name":"isRectangle","type":"Boolean","optional":true,"default":"false","description":"true if rectangle, false if ellipse","types":["Boolean"],"since":null,"text":"isRectangle: Boolean - (Optional, default false) true if rectangle, false if ellipse"},{"name":"c","type":"Number","optional":true,"default":"-1: unlimited","description":"z axis (z / 2)","types":["Number"],"since":null,"text":"c: Number - (Optional, default -1: unlimited) z axis (z / 2)"},{"name":"usePosWorld","type":"Boolean","optional":true,"default":"false","description":"set to true to treat all positions as PositionWorld","types":["Boolean"],"since":"Arma3 2.20","text":"usePosWorld: Boolean - (Optional, default false) set to true to treat all positions as PositionWorld"}],"returns":{"type":"Array: Numbers","types":["Array","Number"],"description":"indexes of matched positions in positions array","text":"Array: Numbers - indexes of matched positions in positions array"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array"]},"right":{"text":"[centre, a, b, angle, isRectangle, c, usePosWorld]","types":["Array"]}},{"syntax":"positions inAreaArrayIndexes [pos1, pos2, pos3,...]","since":null,"effect":null,"exec":null,"params":[{"name":"positions","type":"Array","optional":false,"default":null,"description":"Objects and/or Positions to check.","types":["Array"],"since":null,"text":"positions: Array - Objects and/or Positions to check."},{"name":"posN","type":"Position","optional":false,"default":null,"description":"polygon vertices in 2d or 3d format (see inPolygon)","types":["Position"],"since":null,"text":"posN: Position - polygon vertices in 2d or 3d format (see inPolygon)"}],"returns":{"type":"Array: Numbers","types":["Array","Number"],"description":"indexes of matched positions in positions array","text":"Array: Numbers - indexes of matched positions in positions array"},"form":"binary","operator":null,"left":{"text":"positions","types":["Array"]},"right":{"text":"[pos1, pos2, pos3,...]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _players = call BIS_fnc_listPlayers;\nprivate _indices = _players inAreaArrayIndexes _marker;\n{\n    private _player = _players select _x;\n    [\"You are in the marker!\"] remoteExec [\"hint\", _player];\n} forEach _indices;\n```","code":["private _players = call BIS_fnc_listPlayers;\nprivate _indices = _players inAreaArrayIndexes _marker;\n{\n\tprivate _player = _players select _x;\n\t[\"You are in the marker!\"] remoteExec [\"hint\", _player];\n} forEach _indices;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inAreaArray","inArea","triggerArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Locations","Command Group: Markers","Command Group: Positions","Command Group: Triggers","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"incapacitatedState","operator":null,"title":"incapacitatedState","type":"command","url":"https://community.bistudio.com/wiki/incapacitatedState","revid":341186,"updated":"2023-05-13T22:13:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the incapacitated sub-state of the given unit, when the lifeState of the unit is \"INCAPACITATED\". Could be one of:\n- \"UNCONSCIOUS\"\n- \"MOVING\"\n- \"SHOOTING\"","syntaxes":[{"syntax":"incapacitatedState person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"String","types":["String"],"description":"incapacitated sub-state (see description) or empty string \"\"","text":"String - incapacitated sub-state (see description) or empty string \"\""},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_result = incapacitatedState player;\n```","code":["_result = incapacitatedState player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnconscious","lifeState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"independent","operator":null,"title":"independent","type":"command","url":"https://community.bistudio.com/wiki/independent","revid":369132,"updated":"2024-09-03T10:34:34Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the independent side.","syntaxes":[{"syntax":"independent","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side _unit == independent) then\n{\n    hint \"This is a independent unit!\";\n};\n```","code":["if (side _unit == independent) then\n{\n\thint \"This is a independent unit!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["resistance"],"see_also":["side","civilian","blufor","east","opfor","resistance","west"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"inflame","operator":null,"title":"inflame","type":"command","url":"https://community.bistudio.com/wiki/inflame","revid":319281,"updated":"2022-05-13T09:23:29Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets the state of a fireplace.","syntaxes":[{"syntax":"fireplace inflame burn","since":null,"effect":null,"exec":null,"params":[{"name":"fireplace","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"fireplace: Object"},{"name":"burn","type":"Boolean","optional":false,"default":null,"description":"true to let it burn, false to extinguish it.","types":["Boolean"],"since":null,"text":"burn: Boolean - true to let it burn, false to extinguish it."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"fireplace","types":["Object"]},"right":{"text":"burn","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_fireplaceOne inflame true;\n```","code":["_fireplaceOne inflame true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inflamed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"inflamed","operator":null,"title":"inflamed","type":"command","url":"https://community.bistudio.com/wiki/inflamed","revid":310855,"updated":"2022-05-07T20:24:08Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.04"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if fireplace is inflamed (burning) or not. To check if a unit is receiving damage from fire, use isBurning command.","syntaxes":[{"syntax":"inflamed fireplace","since":null,"effect":null,"exec":null,"params":[{"name":"fireplace","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"fireplace: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"fireplace","types":["Object"]}}],"examples":[{"text":"```sqf\n_inflamed = inflamed _fireplaceOne;\n```","code":["_inflamed = inflamed _fireplaceOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inflame","isBurning"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.04","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"infoPanel","operator":null,"title":"infoPanel","type":"command","url":"https://community.bistudio.com/wiki/infoPanel","revid":378511,"updated":"2026-05-03T17:16:42Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns information about what is currently displayed on given player's info panel.","syntaxes":[{"syntax":"infoPanel infoPanelId","since":null,"effect":null,"exec":null,"params":[{"name":"infoPanelId","type":"String","optional":false,"default":null,"description":"info panel classname, or \"left\" or \"right\"","types":["String"],"since":null,"text":"infoPanelId: String - info panel classname, or \"left\" or \"right\""}],"returns":{"type":"Array with [componentClass, componentType]","types":["Array"],"description":"componentClass: String - EmptyDisplay when no panel is open - componentType: String - EmptyDisplayComponent when no panel is open","text":"Array with [componentClass, componentType]\n- componentClass: String - *EmptyDisplay* when no panel is open\n- componentType: String -  *EmptyDisplayComponent* when no panel is open"},"form":"unary","operator":null,"left":null,"right":{"text":"infoPanelId","types":["String"]}}],"examples":[{"text":"```sqf\ninfoPanel \"left\" params [\"_componentClass\", \"_componentType\"];\n```","code":["infoPanel \"left\" params [\"_componentClass\", \"_componentType\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanels","setInfoPanel","infoPanelComponents","enableInfoPanelComponent","infoPanelComponentEnabled","openGPS"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"infoPanelComponentEnabled","operator":null,"title":"infoPanelComponentEnabled","type":"command","url":"https://community.bistudio.com/wiki/infoPanelComponentEnabled","revid":377489,"updated":"2026-01-02T06:49:10Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Controls availability of component to given object info panel.","syntaxes":[{"syntax":"unit infoPanelComponentEnabled [panelID, componentClassOrType]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"},{"name":"componentClassOrType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"componentClassOrType: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)","text":"Boolean - true if component was successfully enabled on the panel, false otherwise (e.g. component is not available for the object)"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[panelID, componentClassOrType]","types":["Array"]}},{"syntax":"[unit, turretPath] infoPanelComponentEnabled [panelID, componentClassOrType]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"turret index","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - turret index"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"},{"name":"componentClassOrType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"componentClassOrType: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"[unit, turretPath]","types":["Array"]},"right":{"text":"[panelID, componentClassOrType]","types":["Array"]}}],"examples":[{"text":"```sqf\n// returns true if specific component \"SensorDisplay\" is enabled on player vehicle's left panel\n_state = [vehicle player, [-1]] infoPanelComponentEnabled [\"VehicleSystemsDisplayManagerComponentLeft\", \"SensorDisplay\"];\n```","code":["// returns true if specific component \"SensorDisplay\" is enabled on player vehicle's left panel\n_state = [vehicle player, [-1]] infoPanelComponentEnabled [\"VehicleSystemsDisplayManagerComponentLeft\", \"SensorDisplay\"];"]},{"text":"```sqf\n// returns true if all \"SensorsDisplayComponent\" components are enabled on player vehicle's left panel, otherwise returns false\n_state = [vehicle player, [-1]] infoPanelComponentEnabled [\"VehicleSystemsDisplayManagerComponentLeft\", \"SensorsDisplayComponent\"];\n```","code":["// returns true if all \"SensorsDisplayComponent\" components are enabled on player vehicle's left panel, otherwise returns false\n_state = [vehicle player, [-1]] infoPanelComponentEnabled [\"VehicleSystemsDisplayManagerComponentLeft\", \"SensorsDisplayComponent\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanel","infoPanels","setInfoPanel","infoPanelComponents","enableInfoPanelComponent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"infoPanelComponents","operator":null,"title":"infoPanelComponents","type":"command","url":"https://community.bistudio.com/wiki/infoPanelComponents","revid":378365,"updated":"2026-04-03T16:46:15Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of all components available to given object info panel.","syntaxes":[{"syntax":"unit infoPanelComponents panelID","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"}],"returns":{"type":"Array with [className, componentType, isAccessible]","types":["Array"],"description":"className: String - component classname as defined in object/vehicle config - componentType: String - componentType - component type - isAccessible: Boolean - boolean flag that shows if component is currently accessible (lack of required item can make it temporarily inaccessible)","text":"Array with [className, componentType, isAccessible]\n- className: String - component classname as defined in object/vehicle config\n- componentType: String - componentType - component type\n- isAccessible: Boolean - boolean flag that shows if component is currently accessible (lack of required item can make it temporarily inaccessible)"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"panelID","types":["String"]}},{"syntax":"[unit, turretPath] infoPanelComponents panelID","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"turret index","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - turret index"},{"name":"panelID","type":"String","optional":false,"default":null,"description":"\"left\" or \"right\" can be used as panel names","types":["String"],"since":null,"text":"panelID: String - \"left\" or \"right\" can be used as panel names"}],"returns":{"type":"Array with [className, componentType, isAccessible]","types":["Array"],"description":"className: String - component classname as defined in object/vehicle config - componentType: String - componentType - component type - isAccessible: Boolean - boolean flag that shows if component is currently accessible (lack of required item can make it temporarily inaccessible)","text":"Array with [className, componentType, isAccessible]\n- className: String - component classname as defined in object/vehicle config\n- componentType: String - componentType - component type\n- isAccessible: Boolean - boolean flag that shows if component is currently accessible (lack of required item can make it temporarily inaccessible)"},"form":"binary","operator":null,"left":{"text":"[unit, turretPath]","types":["Array"]},"right":{"text":"panelID","types":["String"]}}],"examples":[{"text":"```sqf\n// returns array of all components configured for _helicopter pilot seat\nprivate _componentsData = [_helicopter, [-1]] infoPanelComponents \"left\";\n```","code":["// returns array of all components configured for _helicopter pilot seat\nprivate _componentsData = [_helicopter, [-1]] infoPanelComponents \"left\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanel","infoPanels","setInfoPanel","enableInfoPanelComponent","infoPanelComponentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"infoPanels","operator":null,"title":"infoPanels","type":"command","url":"https://community.bistudio.com/wiki/infoPanels","revid":378367,"updated":"2026-04-03T16:46:20Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array all info panels configured for given object or object and turret path.","syntaxes":[{"syntax":"infoPanels unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"}],"returns":{"type":"Array","types":["Array"],"description":"format [[infoPanelId1, infoPanelShortcutId1], [infoPanelId2, infoPanelShortcutId2], ...]: - infoPanelId: String - name of the info panel class as defined in vehicle config - infopanelShortcutId: String - shortcut representation of infopanelId, currently are supported only shortcuts \"left\" and \"right\"","text":"Array - format [[infoPanelId1, infoPanelShortcutId1], [infoPanelId2, infoPanelShortcutId2], ...]:\n- infoPanelId: String - name of the info panel class as defined in vehicle config\n- infopanelShortcutId: String - shortcut representation of *infopanelId*, currently are supported only shortcuts \"left\" and \"right\""},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"infoPanels [unit, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the concerned vehicle","types":["Object"],"since":null,"text":"unit: Object - the concerned vehicle"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"turret index","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - turret index"}],"returns":{"type":"Array","types":["Array"],"description":"format [[infoPanelId1, infoPanelShortcutId1], [infoPanelId2, infoPanelShortcutId2], ...]: - infoPanelId: String - name of the info panel class as defined in vehicle config - infopanelShortcutId: String - shortcut representation of infopanelId, currently are supported only shortcuts \"left\" and \"right\"","text":"Array - format [[infoPanelId1, infoPanelShortcutId1], [infoPanelId2, infoPanelShortcutId2], ...]:\n- infoPanelId: String - name of the info panel class as defined in vehicle config\n- infopanelShortcutId: String - shortcut representation of *infopanelId*, currently are supported only shortcuts \"left\" and \"right\""},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\ninfoPanels [vehicle player, [0]];\n```","code":["infoPanels [vehicle player, [0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanel","setInfoPanel","infoPanelComponents","enableInfoPanelComponent","infoPanelComponentEnabled","openGPS"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"inGameUISetEventHandler","operator":null,"title":"inGameUISetEventHandler","type":"command","url":"https://community.bistudio.com/wiki/inGameUISetEventHandler","revid":378923,"updated":"2026-08-14T20:25:31Z","groups":["GUI Control - Event Handlers","Event Handlers","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets given event handler of in-game UI. If EH function returns true, performed action is overridden. Event handlers available are:\n- \"PrevAction\" - mouse scroll up\n- \"Action\" - action key press\n- \"NextAction\" - mouse scroll down\nIn order to remove a previously added event handler, set it again with an empty *code* string `\"\"`.\n\n> [!NOTE]\n> **Since Arma 3 v2.22 consider using hideActions**\n\n> [!IMPORTANT]\n> This is a \"set\" command, which means event handlers are not stackable and will replace previously set event handlers of the same type.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.50 the event handler receives an array of the selected/activated action's arguments in `_this` variable:\n>\n> ```sqf\n> params [\"_target\", \"_caller\", \"_index\", \"_engineName\", \"_text\", \"_priority\", \"_showWindow\", \"_hideOnUse\", \"_shortcut\", \"_visibleMenu\", \"_eventName\"];\n> ```\n>\n> - _target: Object - target object to which action is attached\n> - _caller: Object - caller object, basically player\n> - _index: Number - index of the action in action menu (0 - top most)\n> - _engineName: String - engine based action name (\"User\" for user added actions)\n> - _text: String - localized action plain text as seen by the caller\n> - _priority: Number - action *priority* value\n> - _showWindow: Boolean - action *showWindow* value\n> - _hideOnUse: Boolean - action *hideOnUse* value\n> - _shortcut: String - action *shortcut* name or \"\"\n> - _visibleMenu: Boolean - action menu visibility - on first scroll or action press the menu is still invisible, the menu is shown but no action is performed\n> - _eventName: String - event name","syntaxes":[{"syntax":"inGameUISetEventHandler [handlerName, code]","since":null,"effect":null,"exec":null,"params":[{"name":"handlerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"handlerName: String"},{"name":"code","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"code: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[handlerName, code]","types":["Array"]}}],"examples":[{"text":"```sqf\ninGameUISetEventHandler [\"Action\", \"hint 'Lights, Camera, Action!'; true\"];\nsleep 10;\ninGameUISetEventHandler [\"Action\", \"\"]; // removes the \"Action\" EH\n```","code":["inGameUISetEventHandler [\"Action\", \"hint 'Lights, Camera, Action!'; true\"];\nsleep 10;\ninGameUISetEventHandler [\"Action\", \"\"]; // removes the \"Action\" EH"]},{"text":"```sqf\ninGameUISetEventHandler [\"PrevAction\", \"hint str _this; false\"];\ninGameUISetEventHandler [\"NextAction\", \"hint str _this; false\"];\ninGameUISetEventHandler [\"Action\", \"hint str _this; false\"];\n```","code":["inGameUISetEventHandler [\"PrevAction\", \"hint str _this; false\"];\ninGameUISetEventHandler [\"NextAction\", \"hint str _this; false\"];\ninGameUISetEventHandler [\"Action\", \"hint str _this; false\"];"]},{"text":"Deny any weapon disassembly:\n\n```sqf\ninGameUISetEventHandler [\"Action\", \"\n    if (_this select 3 == 'DisAssemble') then {\n        hint 'You are not allowed to do this';\n        true\n    }\n\"];\n```","code":["inGameUISetEventHandler [\"Action\", \"\n\tif (_this select 3 == 'DisAssemble') then {\n\t\thint 'You are not allowed to do this';\n\t\ttrue\n\t}\n\"];"]},{"text":"Detect explosive/mine placement:\n\n```sqf\nprivate _onMagazineUse = '\n    params [\"_target\", \"\", \"\", \"_action\", \"\", \"\", \"\", \"\", \"\", \"\", \"_event\"];\n    if (_action == \"UseMagazine\") then {\n        if (_event == \"Action\") then {\n            _target spawn {\n                waitUntil {!(all_magazines isEqualTo magazines _this)};\n                {\n                    0 = all_magazines deleteAt (all_magazines find _x);\n                } count magazines _this;\n                hint format [\"Magazine Used: %1\", all_magazines select 0];\n            };\n        } else {\n            all_magazines = magazines _target;\n        };\n    };\n    false\n';\ninGameUISetEventHandler [\"PrevAction\", _onMagazineUse];\ninGameUISetEventHandler [\"NextAction\", _onMagazineUse];\ninGameUISetEventHandler [\"Action\", _onMagazineUse];\n```","code":["private _onMagazineUse = '\n\tparams [\"_target\", \"\", \"\", \"_action\", \"\", \"\", \"\", \"\", \"\", \"\", \"_event\"];\n\tif (_action == \"UseMagazine\") then {\n\t\tif (_event == \"Action\") then {\n\t\t\t_target spawn {\n\t\t\t\twaitUntil {!(all_magazines isEqualTo magazines _this)};\n\t\t\t\t{\n\t\t\t\t\t0 = all_magazines deleteAt (all_magazines find _x);\n\t\t\t\t} count magazines _this;\n\t\t\t\thint format [\"Magazine Used: %1\", all_magazines select 0];\n\t\t\t};\n\t\t} else {\n\t\t\tall_magazines = magazines _target;\n\t\t};\n\t};\n\tfalse\n';\ninGameUISetEventHandler [\"PrevAction\", _onMagazineUse];\ninGameUISetEventHandler [\"NextAction\", _onMagazineUse];\ninGameUISetEventHandler [\"Action\", _onMagazineUse];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isActionMenuVisible","addEventHandler","ctrlAddEventHandler","displayAddEventHandler","actionIDs","actionParams","addAction","setUserActionText","showHUD","inputAction","removeAction","removeAllActions","action","enableWeaponDisassembly"],"notes":[{"user":"AgentRev","date":"2016-05-12T20:51:00Z","text":"In case of the \"Action\" event, (*_showWindow* || *_visibleMenu*) also denotes if the action is performed or not. For example, if the action menu is closed or fading off, pressing Spacebar will bring it up and trigger an \"Action\" event; in that case, *_visibleMenu* is false. But if the action menu is open, and Spacebar is pressed to perform the selected action, then *_visibleMenu* will be true. If *_showWindow* is true, then it means the action was performed, regardless of *_visibleMenu*."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: GUI Control - Event Handlers","Command Group: Interaction","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"inheritsFrom","operator":null,"title":"inheritsFrom","type":"command","url":"https://community.bistudio.com/wiki/inheritsFrom","revid":349770,"updated":"2023-11-20T22:10:08Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns base entry of config entry.","syntaxes":[{"syntax":"inheritsFrom config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_base = inheritsFrom (configFile >> \"CfgVehicles\" >> \"Car\"); // returns \"LandVehicle\" Config entry\n```","code":["_base = inheritsFrom (configFile >> \"CfgVehicles\" >> \"Car\"); // returns \"LandVehicle\" Config entry"]},{"text":"Print parent tree of given config class:\n\n```sqf\nfnc_printParents =\n{\n    disableSerialization;\n    if (!isClass _this) exitWith { hint \"Argument is not a config Class\" };\n\n    private _parents = [];\n\n    while { !isNull _this } do\n    {\n        _parents pushBack configName _this;\n        _this = inheritsFrom _this;\n    };\n\n    reverse _parents;\n\n    private _tv = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscTree\", -1];\n    _tv ctrlSetPosition [0,0,1,1];\n    _tv ctrlSetBackgroundColor [0,0,0,0.5];\n    _tv ctrlCommit 0;\n\n    private _path = [];\n    {\n        _tv tvAdd [_path, _x];\n        _path pushBack 0;\n    }\n    forEach _parents;\n\n    tvExpandAll _tv;\n};\n\n// Example:\n(configFile >> \"CfgVehicles\" >> typeOf player) call fnc_printParents;\n```","code":["fnc_printParents =\n{\n\tdisableSerialization;\n\tif (!isClass _this) exitWith { hint \"Argument is not a config Class\" };\n\n\tprivate _parents = [];\n\n\twhile { !isNull _this } do\n\t{\n\t\t_parents pushBack configName _this;\n\t\t_this = inheritsFrom _this;\n\t};\n\n\treverse _parents;\n\n\tprivate _tv = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscTree\", -1];\n\t_tv ctrlSetPosition [0,0,1,1];\n\t_tv ctrlSetBackgroundColor [0,0,0,0.5];\n\t_tv ctrlCommit 0;\n\n\tprivate _path = [];\n\t{\n\t\t_tv tvAdd [_path, _x];\n\t\t_path pushBack 0;\n\t}\n\tforEach _parents;\n\n\ttvExpandAll _tv;\n};\n\n// Example:\n(configFile >> \"CfgVehicles\" >> typeOf player) call fnc_printParents;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getText","getNumber","isArray","isClass","isNumber","isText","select","configHierarchy","isKindOf"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-02T17:11:00Z","text":"(A3 1.14) Use BIS_fnc_returnParents if a parents' collection of the given entry is needed.\n\n```sqf\n[configFile >> \"CfgVehicles\" >> \"Land_Atm_02_F\", true] call BIS_fnc_returnParents;\n// return: [\"Land_Atm_02_F\", \"House_Small_F\", \"House_F\", \"House\", \"HouseBase\", \"NonStrategic\", \"Building\", \"Static\", \"All\"]\n```\n\nNot all entries have parent, and please differ parents from path.\n\n```sqf\ninheritsFrom (configFile >> \"CfgUIColors\" >> \"IGUI\" >> \"Presets\" >> \"PresetA1\" >> \"Variables\");\n// return: Nothing\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"initAmbientLife","operator":null,"title":"initAmbientLife","type":"command","url":"https://community.bistudio.com/wiki/initAmbientLife","revid":319259,"updated":"2022-05-13T09:23:27Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Initialises the ambient life on local client from `CfgWorlds >> worldName >> AmbientA3`. Has no effect on dedicated server or headless client.","syntaxes":[{"syntax":"initAmbientLife","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\ninitAmbientLife;\n```","code":["initAmbientLife;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableEnvironment","sideAmbientLife"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"inPolygon","operator":null,"title":"inPolygon","type":"command","url":"https://community.bistudio.com/wiki/inPolygon","revid":377566,"updated":"2026-01-02T06:55:31Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether position is inside given polygon. The polygon is only checked in 2 dimensions, i.e. the value of Z is ignored.","syntaxes":[{"syntax":"position inPolygon polygon","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position3D, Arma 3 v2.14 Object or Group","optional":false,"default":null,"description":null,"types":["Position3D","Object","Group"],"since":null,"text":"position: Position3D, Arma 3 v2.14 Object or Group"},{"name":"polygon","type":"Array of Position3D","optional":false,"default":null,"description":"positions in format: [position1, position2...., positionN]","types":["Array","Position3D"],"since":null,"text":"polygon: Array of Position3D - positions in format: [position1, position2...., positionN]"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"position","types":["Position3D","Object","Group"]},"right":{"text":"polygon","types":["Array","Position3D"]}}],"examples":[{"text":"```sqf\nprivate _isInside = [100, 100, 0] inPolygon [[0, 0, 0], [1000, 1000, 0], [1000, 0, 0]];\n```","code":["private _isInside = [100, 100, 0] inPolygon [[0, 0, 0], [1000, 1000, 0], [1000, 0, 0]];"]},{"text":"```sqf\nprivate _markerName = \"_USER_DEFINED #0/0/1\";\n\nprivate _xy2DPositions = markerPolyline _markerName;\nprivate _positions = [];\n\n// let's convert these x,y coordinates to \"normal\" position arrays\nfor \"_i\" from 0 to count _xy2DPositions - 1 step 2 do\n{\n    _positions pushBack [_xy2DPositions select _i, _xy2DPositions select (_i + 1), 0];\n};\n\nplayer inPolygon _positions; // true if in the drawn shape, false if not\n```","code":["private _markerName = \"_USER_DEFINED #0/0/1\";\n\nprivate _xy2DPositions = markerPolyline _markerName;\nprivate _positions = [];\n\n// let's convert these x,y coordinates to \"normal\" position arrays\nfor \"_i\" from 0 to count _xy2DPositions - 1 step 2 do\n{\n\t_positions pushBack [_xy2DPositions select _i, _xy2DPositions select (_i + 1), 0];\n};\n\nplayer inPolygon _positions; // true if in the drawn shape, false if not"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["in","inArea","inAreaArray","drawPolygon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"inputAction","operator":null,"title":"inputAction","type":"command","url":"https://community.bistudio.com/wiki/inputAction","revid":369187,"updated":"2024-09-03T10:34:46Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the state of input devices mapped to given input action.\n\nFor Arma 3 inputActions and its bindings see: inputAction/actions.\n\nFor earlier Arma editions  see Category:Key Actions.","syntaxes":[{"syntax":"inputAction name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"name of the action","types":["String"],"since":null,"text":"name: String - name of the action"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\ninputAction \"leanLeft\";\n```\n\n Returns 1 if the button mapped to \"leanLeft\" is pressed currently else 0.","code":["inputAction \"leanLeft\";"]},{"text":"```sqf\n0 spawn {\n    waitUntil {inputAction \"reloadMagazine\" > 0};\n    hint \"Reload Key Pressed\";\n};\n```","code":["0 spawn {\n\twaitUntil {inputAction \"reloadMagazine\" > 0};\n\thint \"Reload Key Pressed\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inputMouse","inputController","actionKeys","actionKeysImages","actionKeysNames","actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"inputController","operator":null,"title":"inputController","type":"command","url":"https://community.bistudio.com/wiki/inputController","revid":338923,"updated":"2023-04-17T15:23:03Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of controller inputs. The controller is a standard XBOX controller which is selected with Windows XBOX controller scheme. The input can be:\n- XBOX_A 0\n- XBOX_B 1\n- XBOX_X 2\n- XBOX_Y 3\n- XBOX_Up 4\n- XBOX_Down 5\n- XBOX_Left 6\n- XBOX_Right 7\n- XBOX_Start 8\n- XBOX_Back 9\n- XBOX_LeftBumper 10\n- XBOX_RightBumper 11\n- XBOX_LeftTrigger 12\n- XBOX_RightTrigger 13\n- XBOX_LeftThumb 14\n- XBOX_RightThumb 15\n- XBOX_LeftThumbXRight 16\n- XBOX_LeftThumbYUp 17\n- XBOX_RightThumbXRight 18\n- XBOX_RightThumbYUp 19\n- XBOX_LeftThumbXLeft 20\n- XBOX_LeftThumbYDown 21\n- XBOX_RightThumbXLeft 22\n- XBOX_RightThumbYDown 23","syntaxes":[{"syntax":"inputController input","since":null,"effect":null,"exec":null,"params":[{"name":"input","type":"Number","optional":false,"default":null,"description":"controller input 0...31 (see description) or -1 for controller detection.","types":["Number"],"since":null,"text":"input: Number - controller input 0...31 (see description) or -1 for controller detection."}],"returns":{"type":"Number","types":["Number"],"description":"value of the controller input 0...1. When input is -1, return is 1 if controller is available, 0 - if controller is unavailable","text":"Number - value of the controller input 0...1. When input is -1, return is 1 if controller is available, 0 - if controller is unavailable"},"form":"unary","operator":null,"left":null,"right":{"text":"input","types":["Number"]}}],"examples":[{"text":"State of the fire trigger:\n\n```sqf\nonEachFrame { hintSilent str inputController 13 };\n```","code":["onEachFrame { hintSilent str inputController 13 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inputMouse","inputAction","actionKeys","actionKeysImages","actionKeysNames","actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"inputMouse","operator":null,"title":"inputMouse","type":"command","url":"https://community.bistudio.com/wiki/inputMouse","revid":309128,"updated":"2022-05-03T11:40:11Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of mouse button action, alone or in combination with key presses. For more information on codes and combos see Arma_3:_Modded_Keybinding and DIK_KeyCodes but here are some examples of how codes could be hand constructed:\n\n- KEYBOARD_COMBO 16777216 (0x1000000)\n- DEVICE_MOUSE 65536 (0x10000)\n- HOLD_OFFSET 0\n- CLICK_OFFSET 128 (0x80)\n- DOUBLE_CLICK_OFFSET 256 (0x100)\n- SPECIAL_COMBINATIONS 1114112 (0x110000)\n\n```\nClick + Hold: BUTTON + DEVICE_MOUSE + HOLD_OFFSET = BUTTON + 65536 + 0\nClick: BUTTON + DEVICE_MOUSE + CLICK_OFFSET = BUTTON + 65536 + 128 \nDouble Click: BUTTON + DEVICE_MOUSE + DOUBLE_CLICK_OFFSET = BUTTON + 65536 + 256\n\nRMB Click + Hold:  1 + 65536 + 0 = 65537\nRMB Click: 1 + 65536 + 128 = 65665\nRMB Double Click: 1 + 65536 + 256 = 65793\n\nCombo + Click + Hold: DIK * KEYBOARD_COMBO + SPECIAL_COMBINATIONS + BUTTON + HOLD_OFFSET = DIK * 16777216 + 1114112 + BUTTON + 0\nCombo + Click: DIK * KEYBOARD_COMBO + SPECIAL_COMBINATIONS + BUTTON + CLICK_OFFSET = DIK * 16777216 + 1114112 + BUTTON + 128\nCombo + Double Click: DIK * KEYBOARD_COMBO + SPECIAL_COMBINATIONS + BUTTON + DOUBLE_CLICK_OFFSET = DIK * 16777216 + 1114112 + BUTTON + 256\n\nLShift + RMB Click + Hold: 42 * 16777216 + 1114112 + 1 + 0 = 705757185\nLShift + RMB Click: 42 * 16777216 + 1114112 + 1 + 128 = 705757313\nLShift + RMB Double Click: 42 * 16777216 + 1114112 + 1 + 256 = 705757441\n```","syntaxes":[{"syntax":"inputMouse button","since":null,"effect":null,"exec":null,"params":[{"name":"button","type":"Number","optional":false,"default":null,"description":"button number 0..7: 0-LMB, 1-RMB, 2-MMB","types":["Number"],"since":null,"text":"button: Number - button number 0..7: 0-LMB, 1-RMB, 2-MMB"}],"returns":{"type":"Number","types":["Number"],"description":"the state of the button: - 0 - released - 1 - click - 2 - click + hold - 3 - double click - 4 - double click + hold","text":"Number - the state of the button:\n- 0 - released\n- 1 - click\n- 2 - click + hold\n- 3 - double click\n- 4 - double click + hold"},"form":"unary","operator":null,"left":null,"right":{"text":"button","types":["Number"]}},{"syntax":"inputMouse combocode","since":null,"effect":null,"exec":null,"params":[{"name":"combocode","type":"String","optional":false,"default":null,"description":"code or combination (see actionKeys)","types":["String"],"since":null,"text":"combocode: String - code or combination (see actionKeys)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if given code/combination detected, false otherwise","text":"Boolean - true if given code/combination detected, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"combocode","types":["String"]}}],"examples":[{"text":"State of the RMB:\n\n```sqf\nonEachFrame { hintSilent str inputMouse 1 };\n```","code":["onEachFrame { hintSilent str inputMouse 1 };"]},{"text":"Detect LCtrl + 2xRMB:\n\n```sqf\nonEachFrame { hintSilent str inputMouse \"487653633\" };\n```","code":["onEachFrame { hintSilent str inputMouse \"487653633\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inputController","inputAction","actionKeys","actionKeysImages","actionKeysNames","actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"inRangeOfArtillery","operator":null,"title":"inRangeOfArtillery","type":"command","url":"https://community.bistudio.com/wiki/inRangeOfArtillery","revid":347548,"updated":"2023-09-28T09:25:36Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if all given units are able to fire at given position with given magazineType.","syntaxes":[{"syntax":"pos inRangeOfArtillery [units, magazineType]","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"},{"name":"units","type":"Array of Objects","optional":false,"default":null,"description":"array of units.","types":["Array","Object"],"since":null,"text":"units: Array of Objects - array of units."},{"name":"magazineType","type":"String","optional":false,"default":null,"description":"**case-sensitive**","types":["String"],"since":null,"text":"magazineType: String - **case-sensitive**"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"pos","types":["Position"]},"right":{"text":"[units, magazineType]","types":["Array"]}}],"examples":[{"text":"```sqf\n_isInRange = getMarkerPos \"myTarget\" inRangeOfArtillery [[myArty], \"32Rnd_155mm_Mo_shells\"];\n```","code":["_isInRange = getMarkerPos \"myTarget\" inRangeOfArtillery [[myArty], \"32Rnd_155mm_Mo_shells\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getArtilleryAmmo","commandArtilleryFire","doArtilleryFire","enableEngineArtillery","getArtilleryComputerSettings","shownArtilleryComputer","getArtilleryETA"],"notes":[{"user":"Waffle SS.","date":"2015-07-10T19:46:00Z","text":"Using an empty artillery vehicle will return false."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"insert","operator":null,"title":"insert","type":"command","url":"https://community.bistudio.com/wiki/insert","revid":377154,"updated":"2026-01-01T10:37:44Z","groups":["HashMap","Arrays","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Inserts multiple values into Array/String/HashMap.\n\nThe String variant also supports forceUnicode. In the event of a HashMap, values, if they already exist, are replaced.","syntaxes":[{"syntax":"array insert [index, valuesToInsert, onlyIfUnique]","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array : Array of Anything"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index at which the values will be inserted, -1 for append, Arma 3 v2.14 -2 for inserting at the second-to-last position, -3 before that, etc.","types":["Number"],"since":null,"text":"index: Number - index at which the values will be inserted, -1 for append, Arma 3 v2.14 -2 for inserting at the second-to-last position, -3 before that, etc."},{"name":"valuesToInsert","type":"Array of Anything","optional":false,"default":null,"description":"values to insert at the specified index","types":["Array","Anything"],"since":null,"text":"valuesToInsert: Array of Anything - values to insert at the specified index"},{"name":"onlyIfUnique","type":"Boolean","optional":true,"default":"false","description":"only insert if the value is unique in the array, like pushBackUnique","types":["Boolean"],"since":null,"text":"onlyIfUnique: Boolean - (Optional, default false) only insert if the value is unique in the array, like pushBackUnique"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"[index, valuesToInsert, onlyIfUnique]","types":["Array"]}},{"syntax":"string insert [index, substring]","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string : String"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index at which the values will be inserted, -1 for append","types":["Number"],"since":null,"text":"index: Number - index at which the values will be inserted, -1 for append"},{"name":"substring","type":"String","optional":false,"default":null,"description":"string to insert","types":["String"],"since":null,"text":"substring: String - string to insert"}],"returns":{"type":"String","types":["String"],"description":"the new string","text":"String - the new string"},"form":"binary","operator":null,"left":{"text":"string","types":["String"]},"right":{"text":"[index, substring]","types":["Array"]}},{"syntax":"hashMap insert [[key1, value1], [key2, value2], ...]","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"keyN","type":"HashMapKey","optional":false,"default":null,"description":null,"types":["HashMapKey"],"since":null,"text":"keyN: HashMapKey"},{"name":"valueN","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"valueN: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"[[key1, value1], [key2, value2], ...]","types":["Array"]}},{"syntax":"hashMap insert [splitArray, [keysAndValues]]","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"splitArray","type":"Boolean","optional":false,"default":null,"description":"determines *keysAndValues* format (see *keysAndValues*'s description)","types":["Boolean"],"since":null,"text":"splitArray: Boolean - determines *keysAndValues* format (see *keysAndValues*'s description)"},{"name":"keysAndValues","type":"Array","optional":false,"default":null,"description":"in format depending on *splitArray*'s value:\n- true - `[[key1, key2, ...], [value1, value2, ...]]`\n- false - `[[key1, value1], [key2, value2], ...]` (same as #Syntax 3, see #Example 3 for the correct format)","types":["Array"],"since":null,"text":"keysAndValues: Array - in format depending on *splitArray*'s value:\n- true - `[[key1, key2, ...], [value1, value2, ...]]`\n- false - `[[key1, value1], [key2, value2], ...]` (same as #Syntax 3, see #Example 3 for the correct format)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"[splitArray, [keysAndValues]]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"Test\" insert [0, \"Radio\"];        // returns \"RadioTest\"\n\"Test\" insert [2, \"Radio\"];        // returns \"TeRadiost\"\n\"Test\" insert [-1, \"Radio\"];    // returns \"TestRadio\"\n```","code":["\"Test\" insert [0, \"Radio\"];\t\t// returns \"RadioTest\"\n\"Test\" insert [2, \"Radio\"];\t\t// returns \"TeRadiost\"\n\"Test\" insert [-1, \"Radio\"];\t// returns \"TestRadio\""]},{"text":"```sqf\nprivate _array = [\"a\", \"b\", \"c\"];\n_array insert [0, [\"w\"]]; // _array is now [\"w\", \"a\", \"b\", \"c\"]\n\nprivate _array = [\"a\", \"b\", \"c\"];\n_array insert [-1, [\"w\"]]; // _array is now [\"a\", \"b\", \"c\", \"w\"]\n\nprivate _array = [\"a\", \"b\", \"c\"];\n_array insert [-2, [\"w\"]]; // _array is now [\"a\", \"b\", \"w\", \"c\"] // Arma 3 v2.14\n```","code":["private _array = [\"a\", \"b\", \"c\"];\n_array insert [0, [\"w\"]]; // _array is now [\"w\", \"a\", \"b\", \"c\"]\n\nprivate _array = [\"a\", \"b\", \"c\"];\n_array insert [-1, [\"w\"]]; // _array is now [\"a\", \"b\", \"c\", \"w\"]\n\nprivate _array = [\"a\", \"b\", \"c\"];\n_array insert [-2, [\"w\"]]; // _array is now [\"a\", \"b\", \"w\", \"c\"] // Arma 3 v2.14"]},{"text":"```sqf\n// Notice how the size of the right array changes depending on the format of keysAndValues format\nprivate _map = createHashMap;\n_map insert [false, [\"one\", 1]];\n\nprivate _map = createHashMap;\n_map insert [true, [\"one\"], [1]];\n```","code":["// Notice how the size of the right array changes depending on the format of keysAndValues format\nprivate _map = createHashMap;\n_map insert [false, [\"one\", 1]];\n\nprivate _map = createHashMap;\n_map insert [true, [\"one\"], [1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["HashMap","pushBack","pushBackUnique","append","+","merge"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Command Group: Strings","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"insertEditorObject","operator":null,"title":"insertEditorObject","type":"command","url":"https://community.bistudio.com/wiki/insertEditorObject","revid":363293,"updated":"2024-03-26T10:51:59Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Insert an object to the editor and assign arguments. Create script is,not called. Returns the ID of the new EditorObject. Subtype class is,optional.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map insertEditorObject [type,value,[name1,value1,...],subtype class]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[type,value,[name1,value1,...],subtype class]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[type,value,[name1,value1,...],subtype class]: Array"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[type,value,[name1,value1,...],subtype class]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"insideBuilding","operator":null,"title":"insideBuilding","type":"command","url":"https://community.bistudio.com/wiki/insideBuilding","revid":338343,"updated":"2023-02-28T14:42:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how much a man is inside a building. The value is the same as normally returned by weapons/ammo sound controller \"interior\".\nIt is possible to modify an individual object to use sound interior with enableAudioFeature.\n\n> [!NOTE]\n> The sound is considered internal when the corresponding surface sound name starts with \"int_\".\n> An object placed inside a building that does not have model `CfgSurfaces`' soundEviron [sic] parameter named this way would generate external sound inside the building, and insideBuilding on top of this object would return 0.","syntaxes":[{"syntax":"insideBuilding man","since":null,"effect":null,"exec":null,"params":[{"name":"man","type":"Object","optional":false,"default":null,"description":"entity of class Man","types":["Object"],"since":null,"text":"man: Object - entity of class Man"}],"returns":{"type":"Number","types":["Number"],"description":"in range 0..1, where 0 is outside, 1 is inside","text":"Number - in range 0..1, where 0 is outside, 1 is inside"},"form":"unary","operator":null,"left":null,"right":{"text":"man","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isFullyInside = insideBuilding player == 1;\n```","code":["private _isFullyInside = insideBuilding player == 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buildingPos","buildingExit","enableAudioFeature","BIS_fnc_buildingPositions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"intersect","operator":null,"title":"intersect","type":"command","url":"https://community.bistudio.com/wiki/intersect","revid":377413,"updated":"2026-01-02T06:45:16Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Finds named selections in object which are in specified LOD, intersected by given section of a line. Return value is in the form of [selection, distance]. Multiple returned arrays are nested within a single array. No intersection returns []. *lodName* could be one of the following:\n- \"FIRE\"\n- \"VIEW\"\n- \"GEOM\"\n- \"IFIRE\" - (\"I\" stands for Indirect, almost the same as FIRE)\n- Arma 3 v2.02 \"PHYSX\" - PhysX geometry LOD","syntaxes":[{"syntax":"[object, lodName] intersect [begPos, endPos]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"lodName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"lodName: String"},{"name":"begPos","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"begPos: PositionAGL"},{"name":"endPos","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"endPos: PositionAGL"}],"returns":{"type":"Array with [selection, distance]","types":["Array"],"description":"selection: String - name of intersected selection - distance: Number - distance from begPos The results are also sorted, closest selection first","text":"Array with [selection, distance]\n- selection: String - name of intersected selection\n- distance: Number - distance from begPos\nThe results are also sorted, closest selection first"},"form":"binary","operator":null,"left":{"text":"[object, lodName]","types":["Array"]},"right":{"text":"[begPos, endPos]","types":["Array"]}}],"examples":[{"text":"```sqf\n[_tank, \"VIEW\"] intersect [[1500, 1500, 2], [1550, 1500, 2]];\n```","code":["[_tank, \"VIEW\"] intersect [[1500, 1500, 2], [1550, 1500, 2]];"]},{"text":"```sqf\nsphere = \"Sign_Sphere10cm_F\" createVehicle [0,0,0];\nonEachFrame {\n    _begPos = positionCameraToWorld [0,0,0];\n    _begPosASL = AGLToASL _begPos;\n    _endPos = positionCameraToWorld [0,0,1000];\n    _endPosASL = AGLToASL _endPos;\n    _ins = lineIntersectsSurfaces [_begPosASL, _endPosASL, player, objNull, true, 1, \"FIRE\", \"NONE\"];\n    if (_ins isEqualTo []) exitWith {sphere setPosASL [0,0,0]};\n    _ins select 0 params [\"_pos\", \"_norm\", \"_obj\", \"_parent\"];\n    if !(getModelInfo _parent select 2) exitWith {sphere setPosASL [0,0,0]};\n    _ins2 = [_parent, \"FIRE\"] intersect [_begPos, _endPos];\n    if (_ins2 isEqualTo []) exitWith {sphere setPosASL [0,0,0]};\n    _ins2 select 0 params [\"_name\", \"_dist\"];\n    _posASL = _begPosASL vectorAdd ((_begPosASL vectorFromTo _endPosASL) vectorMultiply _dist);\n    drawIcon3D [\"\", [1,1,1,1], ASLToAGL _posASL, 0, 0, 0, _name, 1, 0.03, \"PuristaMedium\"];\n    sphere setPosASL _posASL;\n};\n```","code":["sphere = \"Sign_Sphere10cm_F\" createVehicle [0,0,0];\nonEachFrame {\n\t_begPos = positionCameraToWorld [0,0,0];\n\t_begPosASL = AGLToASL _begPos;\n\t_endPos = positionCameraToWorld [0,0,1000];\n\t_endPosASL = AGLToASL _endPos;\n\t_ins = lineIntersectsSurfaces [_begPosASL, _endPosASL, player, objNull, true, 1, \"FIRE\", \"NONE\"];\n\tif (_ins isEqualTo []) exitWith {sphere setPosASL [0,0,0]};\n\t_ins select 0 params [\"_pos\", \"_norm\", \"_obj\", \"_parent\"];\n\tif !(getModelInfo _parent select 2) exitWith {sphere setPosASL [0,0,0]};\n\t_ins2 = [_parent, \"FIRE\"] intersect [_begPos, _endPos];\n\tif (_ins2 isEqualTo []) exitWith {sphere setPosASL [0,0,0]};\n\t_ins2 select 0 params [\"_name\", \"_dist\"];\n\t_posASL = _begPosASL vectorAdd ((_begPosASL vectorFromTo _endPosASL) vectorMultiply _dist);\n\tdrawIcon3D [\"\", [1,1,1,1], ASLToAGL _posASL, 0, 0, 0, _name, 1, 0.03, \"PuristaMedium\"];\n\tsphere setPosASL _posASL;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsSurfaces","terrainIntersect","terrainIntersectASL","terrainIntersectAtASL","lineIntersects","lineIntersectsWith","lineIntersectsObjs","cursorObject","cursorTarget","checkVisibility"],"notes":[{"user":"ManDay","date":"2007-07-25T08:37:00Z","text":"The most common LOD is \"*FIRE*\", which identifies the most detailled hitbox used for ammunition."},{"user":"ffur2007slx2_5","date":"2014-03-27T14:52:00Z","text":"Example (In Arma 3 ver 1.14) display returned arrays on cursor entities:\n\n```sqf\nSto = [];\nFn = {\n    {\n        Sto set [_foreachindex,[cursorTarget, _x] intersect [ASLToAGL eyePos player, screenToWorld [0.5,0.5]]];\n    } foreach [\"FIRE\", \"VIEW\", \"GEOM\", \"IFIRE\"];\n    hintSilent format [\"FIRE: %1, VIEW: %2, GEOM: %3, IFIRE: %4\", Sto select 0, Sto select 1, Sto select 2, Sto select 3];\n};\n[\"sample_id\", \"onEachFrame\", \"Fn\"] call BIS_fnc_addStackedEventHandler;\n```\n\nReturn FIRE: [something], VIEW: [something], GEOM: [something], IFIRE: [something]."},{"user":"Killzone_Kid","date":"2015-08-20T18:34:00Z","text":"intersect will spam .rpt if passed to it object has no skeleton. Use getModelInfo to filter out those objects."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"is3DEN","operator":null,"title":"is3DEN","type":"command","url":"https://community.bistudio.com/wiki/is3DEN","revid":376878,"updated":"2025-12-15T11:17:30Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the Eden Editor is currently being used.","syntaxes":[{"syntax":"is3DEN","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when inside editor environment, false when outside of editor environment","text":"Boolean - true when inside editor environment, false when outside of editor environment"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif is3DEN then { systemChat \"Welcome to Eden Editor!\" };\n```","code":["if is3DEN then { systemChat \"Welcome to Eden Editor!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["is3DENMultiplayer","is3DENPreview"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"is3DENMultiplayer","operator":null,"title":"is3DENMultiplayer","type":"command","url":"https://community.bistudio.com/wiki/is3DENMultiplayer","revid":349042,"updated":"2023-11-08T14:47:14Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the Eden Editor is in multiplayer mode.","syntaxes":[{"syntax":"is3DENMultiplayer","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true in the following cases: - Multiplayer preview launched directly from Eden Editor - true in preview and only for the creator - MP mission is chosen for editing when creating a server: `Multiplayer - Server Browser - Host Server`. When 3D EDITOR button is clicked for selected mission and Eden Editor is launched, command returns true within the editor environment","text":"Boolean - returns true in the following cases:\n- Multiplayer preview launched directly from Eden Editor - true in preview and only for the creator\n- MP mission is chosen for editing when creating a server: `Multiplayer - Server Browser - Host Server`. When *3D EDITOR* button is clicked for selected mission and Eden Editor is launched, command returns true within the editor environment"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif is3DENMultiplayer then {systemChat \"You are hosting a test server!\"};\n```","code":["if is3DENMultiplayer then {systemChat \"You are hosting a test server!\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["is3DEN","is3DENPreview"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"is3DENPreview","operator":null,"title":"is3DENPreview","type":"command","url":"https://community.bistudio.com/wiki/is3DENPreview","revid":342107,"updated":"2023-07-09T12:26:36Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the Eden Editor is currently in mission preview mode, single player or multiplayer. (see also is3DEN, is3DENMultiplayer)","syntaxes":[{"syntax":"is3DENPreview","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif is3DENPreview then { systemChat \"Welcome to Eden Editor Preview!\" };\n```","code":["if is3DENPreview then { systemChat \"Welcome to Eden Editor Preview!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENMouseOver","add3DENConnection","add3DENEventHandler","all3DENEntities","collect3DENHistory","create3DENComposition","create3DENEntity","current3DENOperation","delete3DENEntities","do3DENAction","get3DENActionState","get3DENAttribute","get3DENCamera","get3DENConnections","get3DENEntityID","get3DENGrid","get3DENIconsVisible","get3DENLinesVisible","get3DENSelected","is3DENMultiplayer","is3DEN","move3DENCamera","remove3DENConnection","remove3DENEventHandler","removeAll3DENEventHandlers","set3DENAttributes","set3DENGrid","set3DENIconsVisible","set3DENLinesVisible","set3DENObjectType"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"isAbleToBreathe","operator":null,"title":"isAbleToBreathe","type":"command","url":"https://community.bistudio.com/wiki/isAbleToBreathe","revid":378057,"updated":"2026-02-02T20:53:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"If unit is diving and doesn't have a rebreather, it returns false.\nDiving means the unit's head is underwater. If unit is underwater and has a rebreather, the command returns true.","syntaxes":[{"syntax":"isAbleToBreathe unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_canBreath = isAbleToBreathe player;\n```","code":["_canBreath = isAbleToBreathe player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["underwater"],"notes":[{"user":"Vabene1111","date":"2019-05-06T19:43:00Z","text":"Might return false if player enters a vehicle while underwater."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isActionMenuVisible","operator":null,"title":"isActionMenuVisible","type":"command","url":"https://community.bistudio.com/wiki/isActionMenuVisible","revid":378567,"updated":"2026-05-08T21:15:48Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if scroll menu is visible.","syntaxes":[{"syntax":"isActionMenuVisible","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isActionMenuVisible) then { hint \"Scroll menu is opened\" };\n```","code":["if (isActionMenuVisible) then { hint \"Scroll menu is opened\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["inGameUISetEventHandler","commandingMenu","showCommandingMenu","shownAction","BIS_fnc_addCommMenuItem","BIS_fnc_removeCommMenuItem"],"notes":[{"user":"POLPOX","date":"2021-09-12T03:59:06Z","text":"To force close Action Menu, use showCommandingMenu.\n\n```sqf\nshowCommandingMenu \"RscGroupRootMenu\";\nshowCommandingMenu \"\";\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"isAgent","operator":null,"title":"isAgent","type":"command","url":"https://community.bistudio.com/wiki/isAgent","revid":319121,"updated":"2022-05-13T09:23:13Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if team member is an agent.","syntaxes":[{"syntax":"isAgent teamMember","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"teamMember","types":["Team Member"]}}],"examples":[{"text":"```sqf\nisAgent teamMember _unit;\n```","code":["isAgent teamMember _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["agent","agents","createAgent","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isAimPrecisionEnabled","operator":null,"title":"isAimPrecisionEnabled","type":"command","url":"https://community.bistudio.com/wiki/isAimPrecisionEnabled","revid":349310,"updated":"2023-11-08T14:52:24Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if procedural aiming precision affects weapon sway.","syntaxes":[{"syntax":"isAimPrecisionEnabled unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit which should be checked","types":["Object"],"since":null,"text":"unit: Object - unit which should be checked"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if affected, false if not","text":"Boolean - true if affected, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_isAffected = isAimPrecisionEnabled player;\n```","code":["_isAffected = isAimPrecisionEnabled player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAnimAimPrecision","Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isAISteeringComponentEnabled","operator":null,"title":"isAISteeringComponentEnabled","type":"command","url":"https://community.bistudio.com/wiki/isAISteeringComponentEnabled","revid":369774,"updated":"2024-10-08T15:08:59Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns whether the AI steering component feature is enabled for the specified vehicle.","syntaxes":[{"syntax":"isAISteeringComponentEnabled vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if AI steering component is supported by the vehicle (i.e. defined in config) and enabled, false otherwise","text":"Boolean - true if AI steering component is supported by the vehicle (i.e. defined in config) and enabled, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nisAISteeringComponentEnabled myTank;\n```","code":["isAISteeringComponentEnabled myTank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["useAISteeringComponent","isUsingAISteeringComponent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"isAllowedCrewInImmobile","operator":null,"title":"isAllowedCrewInImmobile","type":"command","url":"https://community.bistudio.com/wiki/isAllowedCrewInImmobile","revid":309127,"updated":"2022-05-03T11:11:34Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Whether or not units can be in a vehicle with broken tracks/wheels.","syntaxes":[{"syntax":"isAllowedCrewInImmobile vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true - allowed, false - not allowed","text":"Boolean - true - allowed, false - not allowed"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif !(isAllowedCrewInImmobile _tank) then\n{\n    _tank allowCrewInImmobile true;\n};\n```","code":["if !(isAllowedCrewInImmobile _tank) then\n{\n\t_tank allowCrewInImmobile true;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowCrewInImmobile"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"isArray","operator":null,"title":"isArray","type":"command","url":"https://community.bistudio.com/wiki/isArray","revid":322300,"updated":"2022-05-30T13:22:37Z","groups":["Config","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if config entry represents array.","syntaxes":[{"syntax":"isArray config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_ok = isArray (configFile >> \"CfgVehicles\") // returns false\n```","code":["_ok = isArray (configFile >> \"CfgVehicles\") // returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getText","getNumber","inheritsFrom","isClass","isNumber","isText","select"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isAutoHoverOn","operator":null,"title":"isAutoHoverOn","type":"command","url":"https://community.bistudio.com/wiki/isAutoHoverOn","revid":319208,"updated":"2022-05-13T09:23:22Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return true if vehicle has enabled auto hover. (always returns false if the vehicle can't set auto hover)","syntaxes":[{"syntax":"isAutoHoverOn vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_isOn = isAutoHoverOn vehicle player;\n```","code":["_isOn = isAutoHoverOn vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isAutonomous","operator":null,"title":"isAutonomous","type":"command","url":"https://community.bistudio.com/wiki/isAutonomous","revid":364996,"updated":"2024-07-04T19:58:06Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns whether the UAV is in autonomous mode or not.","syntaxes":[{"syntax":"isAutonomous uav","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"uav","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isAutonomous = isAutonomous uav;\n```","code":["private _isAutonomous = isAutonomous uav;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAutonomous","disableAI","enableAI","checkAIFeature"],"notes":[{"user":"Sa-Matra","date":"2023-04-30T04:01:48Z","text":"Only works on UAV vehicle, UAV crew will always return false. Check my comment @ setAutonomous for more details about this command."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"isAutoStartUpEnabledRTD","operator":null,"title":"isAutoStartUpEnabledRTD","type":"command","url":"https://community.bistudio.com/wiki/isAutoStartUpEnabledRTD","revid":377727,"updated":"2026-01-02T21:48:47Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns state of automatic start up action. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"isAutoStartUpEnabledRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if automatic start up action is enabled.","text":"Boolean - returns true if automatic start up action is enabled."},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_state = isAutoStartUpEnabledRTD _myHelicopter;\n```","code":["_state = isAutoStartUpEnabledRTD _myHelicopter;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableAutoStartUpRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isAutotest","operator":null,"title":"isAutotest","type":"command","url":"https://community.bistudio.com/wiki/isAutotest","revid":339084,"updated":"2023-04-26T10:54:05Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if game was started with autotest parameter","syntaxes":[{"syntax":"isAutotest","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_bool = isAutotest;\n```","code":["_bool = isAutotest;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3 Startup Parameters"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"isAutoTrimOnRTD","operator":null,"title":"isAutoTrimOnRTD","type":"command","url":"https://community.bistudio.com/wiki/isAutoTrimOnRTD","revid":351295,"updated":"2023-11-27T03:19:56Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns state of auto trim functionality. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"isAutoTrimOnRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if auto trim is enabled","text":"Boolean - returns true if auto trim is enabled"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_state = isAutoTrimOnRTD _myHelicopter;\n```","code":["_state = isAutoTrimOnRTD _myHelicopter;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableAutoTrimRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isAwake","operator":null,"title":"isAwake","type":"command","url":"https://community.bistudio.com/wiki/isAwake","revid":373887,"updated":"2025-06-26T10:59:02Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns resting state of a PhysX (EPE) object. Some EPE objects are deliberately put to sleep by the engine to save resources.\nThis command returns true when object is simulating and false when it is put to sleep. With units of type `Man` the behaviour is slightly different.\nAs units never get put to sleep, the command outputs ragdoll state of a unit instead. There are 6 states for the output of the command:\n- EPE object is simulating - true\n- EPE object is put to sleep - false\n- Unit is alive, ragdoll is active - false\n- Unit is alive, ragdoll is NOT active - true\n- Arma 3 v2.10 Unit is NOT alive, ragdoll is active - true\n- Arma 3 v2.10 Unit is NOT alive, ragdoll is NOT active - false","syntaxes":[{"syntax":"isAwake object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"PhysX object or unit","types":["Object"],"since":null,"text":"object: Object - PhysX object or unit"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"see description","text":"Boolean - see description"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isAwake = isAwake _object;\n```","code":["private _isAwake = isAwake _object;"]},{"text":"Arma 3 v2.10 Here is a simple formula to return ragdoll state of a unit:\n\n```sqf\nprivate _unitIsInRagdoll = alive _unit != isAwake _unit;\n```","code":["private _unitIsInRagdoll = alive _unit != isAwake _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["awake","addTorque","addForce","vectorModelToWorld","vectorModelToWorldVisual","selectionPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"isBleeding","operator":null,"title":"isBleeding","type":"command","url":"https://community.bistudio.com/wiki/isBleeding","revid":322981,"updated":"2022-06-28T21:42:55Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether the unit is bleeding.","syntaxes":[{"syntax":"isBleeding unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isBleeding player) then { player groupChat \"I'm bleeding!!\"; };\n```","code":["if (isBleeding player) then { player groupChat \"I'm bleeding!!\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getBleedingRemaining","isBurning","setBleedingRemaining"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isBurning","operator":null,"title":"isBurning","type":"command","url":"https://community.bistudio.com/wiki/isBurning","revid":323033,"updated":"2022-06-28T21:43:08Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether the unit is burning.\nThis returns true only if unit is damaged by nearby fire, it does **not** check whether a fireplace is burning, use inflamed command for that.","syntaxes":[{"syntax":"isBurning unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isBurning player) then { player groupChat \"I'm burning!!\"; };\n```","code":["if (isBurning player) then { player groupChat \"I'm burning!!\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getBleedingRemaining","setBleedingRemaining","isBleeding","inflamed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isClass","operator":null,"title":"isClass","type":"command","url":"https://community.bistudio.com/wiki/isClass","revid":341206,"updated":"2023-05-13T22:33:10Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if config entry represents config class.","syntaxes":[{"syntax":"isClass config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_ok = isClass (configFile >> \"CfgVehicles\");\n```\n\n Result is true.","code":["_ok = isClass (configFile >> \"CfgVehicles\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getText","getNumber","inheritsFrom","isArray","isNumber","isText","select"],"notes":[{"user":"Kronzky","date":"2007-03-02T01:17:00Z","text":"This command allows you to check for the presence of an addon.\n isClass (configFile >> \"cfgVehicles\" >> \"MyCustomCar\")\nwill return true if the addon \"MyCustomCar\" is installed, and false if it is not installed.\n\n*You will have to know under which class the addon is categorized (in this case \"cfgVehicles\") to be able to use the right config path.*"},{"user":"ffur2007slx2_5","date":"2014-03-31T15:45:00Z","text":"(Arma 3 ver 1.14) According to BI Dev Karel Mořický, BIS_fnc_getCfgIsClass provides a comfortable workaround with custom config under description.ext compared with isClass.\n(But as a function created specifically for A3 campaign, it is in no way intended as a replacement for isClass.\nSo it is not suggested to use it for configFile classes. But isClass instead.)\nE.g.\n\n```sqf\n[\"Something1\", \"Something2\", \"Something3\"] call BIS_fnc_getCfgIsClass; // same as isClass (missionConfigFile >> \"Something1\" >> \"Something2\" >> \"Something3\")\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isCollisionLightOn","operator":null,"title":"isCollisionLightOn","type":"command","url":"https://community.bistudio.com/wiki/isCollisionLightOn","revid":353090,"updated":"2024-03-12T12:48:19Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if vehicle collision lights are on otherwise false.","syntaxes":[{"syntax":"isCollisionLightOn vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_collisionLightOn = isCollisionLightOn heli;\n```","code":["_collisionLightOn = isCollisionLightOn heli;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEngineOn","isLightOn","setPilotLight","setCollisionLight","isIRLaserOn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"isCopilotEnabled","operator":null,"title":"isCopilotEnabled","type":"command","url":"https://community.bistudio.com/wiki/isCopilotEnabled","revid":369152,"updated":"2024-09-03T10:34:39Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if copilots actions are enabled.","syntaxes":[{"syntax":"isCopilotEnabled vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (!isCopilotEnabled myHeli) then {\n    myHeli enableCopilot true;\n};\n```","code":["if (!isCopilotEnabled myHeli) then {\n\tmyHeli enableCopilot true;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableCopilot"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isDamageAllowed","operator":null,"title":"isDamageAllowed","type":"command","url":"https://community.bistudio.com/wiki/isDamageAllowed","revid":336947,"updated":"2023-01-04T16:44:11Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"A getter for allowDamage command. The command indicates if damage is allowed at current locality, hence local effect of the command.\nFor complete solution for being able to tell whether or not an object can be damaged at current locality see #Example 1.","syntaxes":[{"syntax":"isDamageAllowed object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _canBeDamaged = local _obj && isDamageAllowed _obj;\n```","code":["private _canBeDamaged = local _obj && isDamageAllowed _obj;"]}],"multiplayer":"Always returns false when called on non-local objects","problems":null,"aliases":[],"see_also":["allowDamage","setDamage","setHit"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"isDedicated","operator":null,"title":"isDedicated","type":"command","url":"https://community.bistudio.com/wiki/isDedicated","revid":337566,"updated":"2023-02-10T01:14:00Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the machine executing the command is a dedicated multiplayer server. Returns false in single player.","syntaxes":[{"syntax":"isDedicated","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isDedicated) then { diag_log \"Dedicated Server on the run !\"; };\n```","code":["if (isDedicated) then { diag_log \"Dedicated Server on the run !\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isServer","hasInterface"],"notes":[{"user":"Killzone_Kid","date":"2014-12-21T14:54:00Z","text":"```sqf\nif (isDedicated) then {\n    // run on dedicated server only\n};\n\nif (isServer) then {\n    // run on dedicated server or player host\n};\n\nif (hasInterface) then {\n    // run on all player clients incl. player host\n};\n\nif (!isDedicated) then {\n    // run on all player clients incl. player host and headless clients\n};\n\nif (!isServer) then {\n    // run on all player clients incl. headless clients but not player host\n};\n\nif (!hasInterface) then {\n    // run on headless clients and dedicated server\n};\n\nif (!hasInterface && !isDedicated) then {\n    // run on headless clients only\n};\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isDLCAvailable","operator":null,"title":"isDLCAvailable","type":"command","url":"https://community.bistudio.com/wiki/isDLCAvailable","revid":369281,"updated":"2024-09-03T18:42:47Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the DLC (CDLC included) is marked as available on Steam.\nOfficial and Creator DLC appIds can be found on Arma 3: DLCs & Expansions and Arma 3: CDLCs pages.\n\n> [!IMPORTANT]\n> This command will return true if the DLC is owned, even if it is **not** installed!","syntaxes":[{"syntax":"isDLCAvailable appId","since":null,"effect":null,"exec":null,"params":[{"name":"appId","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"appId : Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"appId","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _karts = 288520;\nisDLCAvailable _karts; // returns true\n```","code":["private _karts = 288520;\nisDLCAvailable _karts; // returns true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDLCs","getObjectDLC","getPersonUsedDLCs","getMissionDLCs"],"notes":[{"user":"Benargee","date":"2014-10-19T02:39:00Z","text":"appId can be taken from Steam DLC url, e.g Karts url is `http://store.steampowered.com/app/**288520**/`."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"isEngineOn","operator":null,"title":"isEngineOn","type":"command","url":"https://community.bistudio.com/wiki/isEngineOn","revid":370470,"updated":"2024-12-16T18:09:58Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if engine is on, false if it is off.","syntaxes":[{"syntax":"isEngineOn vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_carEngineIsOn = isEngineOn _carOne;\n```","code":["_carEngineIsOn = isEngineOn _carOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["engineOn","setCollisionLight","isLightOn","isCollisionLightOn"],"notes":[{"user":"Sa-Matra","date":"2022-08-28T05:06:58Z","text":"If you're a client (not server) and check remote vehicle that is far away from the camera, you'll get an outdated engine state until the vehicle and client camera position are close to each other. Distance seems to be around 6km and doesn't depend on video settings."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.90","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isEqualRef","operator":null,"title":"isEqualRef","type":"command","url":"https://community.bistudio.com/wiki/isEqualRef","revid":338333,"updated":"2023-02-28T14:32:49Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares two values by reference, returns true if equal.","syntaxes":[{"syntax":"val1 isEqualRef val2","since":null,"effect":null,"exec":null,"params":[{"name":"val1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val1: Anything"},{"name":"val2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val2: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the same ref","text":"Boolean - true if the same ref"},"form":"binary","operator":null,"left":{"text":"val1","types":["Anything"]},"right":{"text":"val2","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr1 = [1,[2,[3]]];\n_arr2 = _arr1;\n_arr1 isEqualTo _arr2;    // true\n_arr1 isEqualRef _arr2;    // true\n\n_arr2 = +_arr1;            // array copy\n_arr1 isEqualTo _arr2;    // true\n_arr1 isEqualRef _arr2;    // false\n```","code":["_arr1 = [1,[2,[3]]];\n_arr2 = _arr1;\n_arr1 isEqualTo _arr2;\t// true\n_arr1 isEqualRef _arr2;\t// true\n\n_arr2 = +_arr1;\t\t\t// array copy\n_arr1 isEqualTo _arr2;\t// true\n_arr1 isEqualRef _arr2;\t// false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isNotEqualRef","isEqualTo","Operators"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"isEqualTo","operator":null,"title":"isEqualTo","type":"command","url":"https://community.bistudio.com/wiki/isEqualTo","revid":336361,"updated":"2022-12-29T09:01:58Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Performs strict comparison between var1 and var2 and returns true if equal, otherwise false. Strict means that it would check that both arguments are of the same data type and then compare the values.\n\nSome differences between isEqualTo and ==:\n- It performs case sensitive comparison on Strings\n- It doesn't throw error when comparing different types, i.e. (\"eleven\" isEqualTo 11)\n- It can compare Arrays, Script Handles and Booleans (alive player isEqualTo true)\n- It can compare non-existent game objects (grpNull isEqualTo grpNull)\n- It is slightly faster than ==, especially when comparing Strings\n- Arma 3 v1.48 It can compare Namespaces\n\n> [!NOTE]\n> A compiled code is not equal to the same compiled code made final: \n>\n> ```sqf\n> _a = compile \"123\"; _b = compileFinal \"123\"; _a isEqualTo _b; // false\n> ```\n\n> [!WARNING]\n> When comparing Arrays, if an array contains nil element, the comparison will return false. For example:\n>\n> ```sqf\n> private _array1 = [1, nil, 2];\n> private _array2 = [1, nil, 2];\n> _array1 isEqualTo _array2; // false\n> ```\n>\n> UNLESS the compared arrays are the same array:\n>\n> ```sqf\n> private _array1 = [1, nil, 2];\n> private _array2 = _array1;\n> _array1 isEqualTo _array2; // true\n> ```\n>\n> See: isEqualRef and BIS_fnc_areEqual vs BIS_fnc_areEqualNotNil","syntaxes":[{"syntax":"val1 isEqualTo val2","since":null,"effect":null,"exec":null,"params":[{"name":"val1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val1: Anything"},{"name":"val2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val2: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"val1","types":["Anything"]},"right":{"text":"val2","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr1 = [1, [2, [3]]];\n_arr2 = [1, [2, [3]]];\nif (_arr1 isEqualTo _arr2) then { hint \"Arrays match!\" };\n```","code":["_arr1 = [1, [2, [3]]];\n_arr2 = [1, [2, [3]]];\nif (_arr1 isEqualTo _arr2) then { hint \"Arrays match!\" };"]},{"text":"```sqf\nif (a isEqualTo b) then { hint \"a is equal to b\" };\nif !(a isEqualTo b) then { hint \"a is not equal to b\" };\n```","code":["if (a isEqualTo b) then { hint \"a is equal to b\" };\nif !(a isEqualTo b) then { hint \"a is not equal to b\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isNotEqualTo","isEqualRef","isEqualTypeAll","isEqualTypeAny","isEqualType","isEqualTypeParams","isEqualTypeArray","a == b","Operators"],"notes":[{"user":"Tajin","date":"","text":"Simply put, \"isEqualTo\" is a binary comparison. Therefor it is very fast but only accepts **100%** identical matches. In some other languages this is known as \"===\" instead of \"==\"."},{"user":"Dedmen","date":"","text":"When comparing with nil result is Nothing.\n\n```sqf\nnil isEqualTo player;\n```\n\nReturns Nothing instead of expected false\n\n```sqf\ndiag_log [nil isEqualTo player];\n```\n\nWill print `[bool]`"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"isEqualType","operator":null,"title":"isEqualType","type":"command","url":"https://community.bistudio.com/wiki/isEqualType","revid":325195,"updated":"2022-07-01T14:49:21Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares two values' types. A much faster alternative to `typeName a == typeName b`.","syntaxes":[{"syntax":"val1 isEqualType val2","since":null,"effect":null,"exec":null,"params":[{"name":"val1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val1: Anything"},{"name":"val2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val2: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"val1","types":["Anything"]},"right":{"text":"val2","types":["Anything"]}}],"examples":[{"text":"```sqf\nprivate _var = [1,2,3];\n_var isEqualType 0; // false\n_var isEqualType []; // true\n```","code":["private _var = [1,2,3];\n_var isEqualType 0; // false\n_var isEqualType []; // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTypeAll","isEqualTypeArray","isEqualTypeAny","isEqualTypeParams","param","params","isEqualTo","typeName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isEqualTypeAll","operator":null,"title":"isEqualTypeAll","type":"command","url":"https://community.bistudio.com/wiki/isEqualTypeAll","revid":377824,"updated":"2026-01-03T04:23:49Z","groups":["Variables","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares types of all elements of an array to the type of a single value. Since Arma 3 v2.09.149634 no additional check is needed to make sure the first argument is an Array.\n\n> [!IMPORTANT]\n> An empty array will return `false` (see #Example 2).","syntaxes":[{"syntax":"arr isEqualTypeAll val","since":null,"effect":null,"exec":null,"params":[{"name":"arr","type":"Anything","optional":false,"default":null,"description":"(was Array before Arma 3 v2.10)","types":["Anything"],"since":null,"text":"arr: Anything - (was Array before Arma 3 v2.10)"},{"name":"val","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"arr","types":["Anything"]},"right":{"text":"val","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3,4,5,6,7,8,9,0];\n_arr isEqualTypeAll \"\"; // false\n_arr isEqualTypeAll 0;    // true\n```","code":["_arr = [1,2,3,4,5,6,7,8,9,0];\n_arr isEqualTypeAll \"\"; // false\n_arr isEqualTypeAll 0;\t// true"]},{"text":"```sqf\n[] isEqualTypeAll \"\";    // false\n[\"\"] isEqualTypeAll \"\";    // true\n```","code":["[] isEqualTypeAll \"\";\t// false\n[\"\"] isEqualTypeAll \"\";\t// true"]},{"text":"```sqf\n0 isEqualTypeAll \"\";    // false\n0 isEqualTypeAll 0;        // false\n[0] isEqualTypeAll 0;    // true\n```","code":["0 isEqualTypeAll \"\";\t// false\n0 isEqualTypeAll 0;\t\t// false\n[0] isEqualTypeAll 0;\t// true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTypeArray","isEqualTypeAny","isEqualType","isEqualTypeParams","param","params","isEqualTo","typeName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Variables","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isEqualTypeAny","operator":null,"title":"isEqualTypeAny","type":"command","url":"https://community.bistudio.com/wiki/isEqualTypeAny","revid":377153,"updated":"2026-01-01T10:37:25Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares type of given value to every type in the given array and if match is found, true is returned.","syntaxes":[{"syntax":"val isEqualTypeAny types","since":null,"effect":null,"exec":null,"params":[{"name":"val","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val: Anything"},{"name":"types","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"types: Array of Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"val","types":["Anything"]},"right":{"text":"types","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_var = [1, 2, 3];\n_var isEqualTypeAny [0, \"\", objNull]; //false\n_var isEqualTypeAny [0, \"\", objNull, []]; //true\n```","code":["_var = [1, 2, 3];\n_var isEqualTypeAny [0, \"\", objNull]; //false\n_var isEqualTypeAny [0, \"\", objNull, []]; //true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualType","isEqualTypeAll","isEqualTypeArray","isEqualTypeParams","param","params","isEqualTo","typeName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isEqualTypeArray","operator":null,"title":"isEqualTypeArray","type":"command","url":"https://community.bistudio.com/wiki/isEqualTypeArray","revid":377152,"updated":"2026-01-01T10:37:00Z","groups":["Variables","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares types of all elements of one array to types of all elements of another array. Since Arma 3 v2.09.149634 no additional check is needed to make sure the first argument is an Array.","syntaxes":[{"syntax":"arr1 isEqualTypeArray arr2","since":null,"effect":null,"exec":null,"params":[{"name":"arr1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"arr1: Anything"},{"name":"arr2","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"arr2: Array of Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"arr1","types":["Anything"]},"right":{"text":"arr2","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_arr = [1,true,\"three\"];\n_arr isEqualTypeArray [0,objNull,\"\"]; // false\n_arr isEqualTypeArray [0,false,\"\"]; // true\n```","code":["_arr = [1,true,\"three\"];\n_arr isEqualTypeArray [0,objNull,\"\"]; // false\n_arr isEqualTypeArray [0,false,\"\"]; // true"]},{"text":"```sqf\n_arr = [1,2];\n_arr isEqualTypeArray [0]; // false\n_arr isEqualTypeArray [0,0]; // true\n_arr isEqualTypeArray [0,0,0]; // false\n```","code":["_arr = [1,2];\n_arr isEqualTypeArray [0]; // false\n_arr isEqualTypeArray [0,0]; // true\n_arr isEqualTypeArray [0,0,0]; // false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTypeAll","isEqualType","isEqualTypeParams","param","params","isEqualTo","typeName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Variables","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isEqualTypeParams","operator":null,"title":"isEqualTypeParams","type":"command","url":"https://community.bistudio.com/wiki/isEqualTypeParams","revid":377090,"updated":"2026-01-01T09:48:04Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares types of all elements of input array to types of all elements of template array. Similar to isEqualTypeArray however this command is designed for fast validation of functions params, so there are differences:\n- Input can be anything but will be expected to be an Array, otherwise false is returned\n- Input array can be longer but not shorter than template array, will return false if shorter\n- nil could be used in template type array as a wild card to allow any type match","syntaxes":[{"syntax":"input isEqualTypeParams template","since":null,"effect":null,"exec":null,"params":[{"name":"input","type":"Anything","optional":false,"default":null,"description":"could be value of any type, but only type Array will be validated","types":["Anything"],"since":null,"text":"input: Anything - could be value of any type, but only type Array will be validated"},{"name":"template","type":"Array of Anything","optional":false,"default":null,"description":"array of expected types","types":["Array","Anything"],"since":null,"text":"template: Array of Anything - array of expected types"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"input","types":["Anything"]},"right":{"text":"template","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n// These all return true\n[1,2,player,\"10\"] isEqualTypeParams [0,0,objNull,\"\"];\n[1,2,player,\"10\",true] isEqualTypeParams [0,0,nil,\"\"];\n[1,2,getPos player,\"10\",true] isEqualTypeParams [0,0,nil,\"\"];\n```","code":["// These all return true\n[1,2,player,\"10\"] isEqualTypeParams [0,0,objNull,\"\"];\n[1,2,player,\"10\",true] isEqualTypeParams [0,0,nil,\"\"];\n[1,2,getPos player,\"10\",true] isEqualTypeParams [0,0,nil,\"\"];"]},{"text":"```sqf\n// These all return false\n123 isEqualTypeParams [0,0,objNull,\"\"];\n[] isEqualTypeParams [0,0,objNull,\"\"];\n[1,2,player] isEqualTypeParams [0,0,objNull,\"\"];\n```","code":["// These all return false\n123 isEqualTypeParams [0,0,objNull,\"\"];\n[] isEqualTypeParams [0,0,objNull,\"\"];\n[1,2,player] isEqualTypeParams [0,0,objNull,\"\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTypeAll","isEqualTypeAny","isEqualType","isEqualTypeArray","param","params","isEqualTo","typeName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isFilePatchingEnabled","operator":null,"title":"isFilePatchingEnabled","type":"command","url":"https://community.bistudio.com/wiki/isFilePatchingEnabled","revid":310763,"updated":"2022-05-07T20:21:37Z","groups":["System","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if file patching is enabled otherwise false","syntaxes":[{"syntax":"isFilePatchingEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_state = isFilePatchingEnabled;\n```","code":["_state = isFilePatchingEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Startup Parameters"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: System","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"isFinal","operator":null,"title":"isFinal","type":"command","url":"https://community.bistudio.com/wiki/isFinal","revid":351275,"updated":"2023-11-27T02:07:26Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if Code or a variable was compiled final with compileFinal.","syntaxes":[{"syntax":"isFinal variable","since":null,"effect":null,"exec":null,"params":[{"name":"variable","type":"Code, String, Arma 3 v2.14 Array or HashMap","optional":false,"default":null,"description":"Code, String, Arma 3 v2.14 Array or HashMap\n- Code\n- String - the name of the variable holding Code\n- Arma 3 v2.14 Array - an array that is a HashMapKey, a trigger's `thisList` array, made final with compileFinal etc.\n- Arma 3 v2.14 HashMap - a hashmap made final with compileFinal","types":["Code","String","Array","HashMap"],"since":null,"text":"variable: Code, String, Arma 3 v2.14 Array or HashMap\n- Code\n- String - the name of the variable holding Code\n- Arma 3 v2.14 Array - an array that is a HashMapKey, a trigger's `thisList` array, made final with compileFinal etc.\n- Arma 3 v2.14 HashMap - a hashmap made final with compileFinal"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if final, false if not","text":"Boolean - true if final, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"variable","types":["Code","String","Array","HashMap"]}}],"examples":[{"text":"```sqf\nprivate _myCode = compileFinal \"a = a + 1\";\nsystemChat format [\"isFinal \"\"_myCode\"\": %1\", isFinal \"_myCode\"];                // true\nsystemChat format [\"isFinal _myCode: %1\", isFinal _myCode];                        // true\nsystemChat format [\"isFinal some code: %1\", isFinal { hint \"Hello there\" }];    // false\n\nprivate _myArray1 = list _myTrigger;\nsystemChat format [\"isFinal _myArray1: %1\", isFinal _myArray1];                    // true\n\nprivate _myArray2 = [1, 2, 3];\nsystemChat format [\"isFinal _myArray2: %1\", isFinal _myArray2];                    // false\n\nprivate _myHashMap = compileFinal createHashMap;\nsystemChat format [\"isFinal _myHashMap: %1\", isFinal _myHashMap];                // true\n```","code":["private _myCode = compileFinal \"a = a + 1\";\nsystemChat format [\"isFinal \"\"_myCode\"\": %1\", isFinal \"_myCode\"];\t\t\t\t// true\nsystemChat format [\"isFinal _myCode: %1\", isFinal _myCode];\t\t\t\t\t\t// true\nsystemChat format [\"isFinal some code: %1\", isFinal { hint \"Hello there\" }];\t// false\n\nprivate _myArray1 = list _myTrigger;\nsystemChat format [\"isFinal _myArray1: %1\", isFinal _myArray1];\t\t\t\t\t// true\n\nprivate _myArray2 = [1, 2, 3];\nsystemChat format [\"isFinal _myArray2: %1\", isFinal _myArray2];\t\t\t\t\t// false\n\nprivate _myHashMap = compileFinal createHashMap;\nsystemChat format [\"isFinal _myHashMap: %1\", isFinal _myHashMap];\t\t\t\t// true"]},{"text":"Avoid .rpt's overwrite warnings:\n\n```sqf\nif (!isFinal fnc_myCode) then { fnc_myCode = compileFinal str_myCode };\n```","code":["if (!isFinal fnc_myCode) then { fnc_myCode = compileFinal str_myCode };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compile","compileFinal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"isFlashlightOn","operator":null,"title":"isFlashlightOn","type":"command","url":"https://community.bistudio.com/wiki/isFlashlightOn","revid":319047,"updated":"2022-05-13T09:23:05Z","groups":["Object Manipulation","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if there is a linked and enabled flashlight on a given weapon.","syntaxes":[{"syntax":"unit isFlashlightOn weapon","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weapon","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weapon: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}}],"examples":[{"text":"```sqf\nplayer isFlashlightOn (currentWeapon player);\n```","code":["player isFlashlightOn (currentWeapon player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableGunLights"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Weapons","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isFlatEmpty","operator":null,"title":"isFlatEmpty","type":"command","url":"https://community.bistudio.com/wiki/isFlatEmpty","revid":377421,"updated":"2026-01-02T06:45:31Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks given position against given filter params. Filter includes checks for:\n- If there are any objects closer than given distance from given position (in 2D)\n- If the area around position is flat enough to match given gradient\n- If the given position is over water or land\n- If the given position is over shore line\nThe gradient seems to correlate with general hill steepness: 0.1 (10%) ~6°, 0.5 (50%) ~27°, 1.0 (100%) ~45°, etc.\n\n> [!NOTE]\n> See also BIS_fnc_findSafePos.","syntaxes":[{"syntax":"position isFlatEmpty [minDistance, mode, maxGradient, maxGradientRadius, overLandOrWater, shoreLine, ignoreObject]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"position: PositionAGL"},{"name":"minDistance","type":"Number","optional":true,"default":"-1","description":"minimum (2D) distance from other objects (range 0..50). -1 to ignore proximity check","types":["Number"],"since":null,"text":"minDistance: Number - (Optional, default -1) minimum (2D) distance from other objects (range 0..50). -1 to ignore proximity check"},{"name":"mode","type":"Number","optional":true,"default":"-1","description":"position check mode (**ALWAYS USE DEFAULT VALUE**)","types":["Number"],"since":null,"text":"mode: Number - (Optional, default -1) position check mode (**ALWAYS USE DEFAULT VALUE**)"},{"name":"maxGradient","type":"Number","optional":true,"default":"-1","description":"maximum terrain steepness allowed. -1 to ignore","types":["Number"],"since":null,"text":"maxGradient: Number - (Optional, default -1) maximum terrain steepness allowed. -1 to ignore"},{"name":"maxGradientRadius","type":"Number","optional":true,"default":"1","description":"how far to extend gradient check","types":["Number"],"since":null,"text":"maxGradientRadius: Number - (Optional, default 1) how far to extend gradient check"},{"name":"overLandOrWater","type":"Number","optional":true,"default":"0","description":"0: position cannot be over water\n- 2: position cannot be over land\n- -1 to ignore","types":["Number"],"since":null,"text":"overLandOrWater: Number - (Optional, default 0)\n- 0: position cannot be over water\n- 2: position cannot be over land\n- -1 to ignore"},{"name":"shoreLine","type":"Boolean","optional":true,"default":"false","description":"true: position is over shoreline (< ~25 m from water)\n- false to ignore","types":["Boolean"],"since":null,"text":"shoreLine: Boolean - (Optional, default false)\n- true: position is over shoreline (< ~25 m from water)\n- false to ignore"},{"name":"ignoreObject","type":"Object","optional":true,"default":"objNull","description":"object to ignore in proximity checks. objNull to ignore","types":["Object"],"since":null,"text":"ignoreObject: Object - (Optional, default objNull) object to ignore in proximity checks. objNull to ignore"}],"returns":{"type":"Array","types":["Array"],"description":"empty array [] if check failed or PositionASL if succeded. Resulting position will be original PositionAGL + getTerrainHeightASL","text":"Array - empty array [] if check failed or PositionASL if succeded. Resulting position will be original PositionAGL + getTerrainHeightASL"},"form":"binary","operator":null,"left":{"text":"position","types":["PositionAGL"]},"right":{"text":"[minDistance, mode, maxGradient, maxGradientRadius, overLandOrWater, shoreLine, ignoreObject]","types":["Array"]}}],"examples":[{"text":"Check if player position is over land:\n\n```sqf\n_overLand = !(position player isFlatEmpty [-1, -1, -1, -1, 0, false] isEqualTo []);\n```","code":["_overLand = !(position player isFlatEmpty [-1, -1, -1, -1, 0, false] isEqualTo []);"]},{"text":"Check if player position is over shore line:\n\n```sqf\n_overShore = !(position player isFlatEmpty  [-1, -1, -1, -1, 0, true] isEqualTo []);\n```","code":["_overShore = !(position player isFlatEmpty  [-1, -1, -1, -1, 0, true] isEqualTo []);"]},{"text":"Check if player position is over water:\n\n```sqf\n_overWater = !(position player isFlatEmpty  [-1, -1, -1, -1, 2, false] isEqualTo []);\n```","code":["_overWater = !(position player isFlatEmpty  [-1, -1, -1, -1, 2, false] isEqualTo []);"]},{"text":"Check if no object is closer than 5m to player position:\n\n```sqf\n_isEmpty = !(position player isFlatEmpty  [5, -1, -1, -1, -1, false, player] isEqualTo []);\n```","code":["_isEmpty = !(position player isFlatEmpty  [5, -1, -1, -1, -1, false, player] isEqualTo []);"]},{"text":"Check if area 10m around player position is relatively flat:\n\n```sqf\n_isFlat = !(position player isFlatEmpty  [-1, -1, 0.3, 10, -1] isEqualTo []);\n```","code":["_isFlat = !(position player isFlatEmpty  [-1, -1, 0.3, 10, -1] isEqualTo []);"]},{"text":"Check if area 15m around player position is very flat and empty:\n\n```sqf\n_isFlatEmpty = !(position player isFlatEmpty  [15, -1, 0.1, 15, -1, false, player] isEqualTo []);\n```","code":["_isFlatEmpty = !(position player isFlatEmpty  [15, -1, 0.1, 15, -1, false, player] isEqualTo []);"]}],"multiplayer":null,"problems":"- Objects accounted for proximity check seem to be static objects. Nearby vehicles and units do not seem to affect the output\n- Given position will be magically transferred into given position + getTerrainHeightASL value\n- The second element must be -1 (≤ 0 really) at all times, otherwise command becomes unusable\n- The command might be a bit heavy on computations so avoid frequent and large area checks","aliases":[],"see_also":["BIS_fnc_findSafePos","selectBestPlaces","findEmptyPosition"],"notes":[{"user":"Killzone_Kid","date":"2016-04-24T17:18:00Z","text":"When this command is instructed to check if area at given position is empty it takes into account the radius of the bounding sphere of surrounding objects. Because of this, the high voltage columns such as \"Land_HighVoltageColumnWire_F\" and such objects may appear extremely large to the calculations and the position will be rejected even if visually it doesn't look too bad. To avoid this, use findEmptyPosition command first to find guaranteed empty position, then pass the result to isFlatEmpty making sure you switched off proximity check by setting 1st param to -1. For example:\n\n```sqf\n// Check if given position is flat and empty within 1m radius\n[4274.66,12113,0.00139618] isFlatEmpty [1, -1, 0.1, 1, -1, false, objNull]; // []\n```\n\nThe result suggests it is not flat and empty.\n\n```sqf\n// Check if given position is flat within 1m radius\n[4274.66,12113,0.00139618] isFlatEmpty [-1, -1, 0.1, 1, -1, false, objNull]; // [4274.66,12113,48.3209]\n```\n\nThe result suggests it is.\n\n```sqf\n// Check if given position is empty within 1m radius\n[4274.66,12113,0.00139618] isFlatEmpty [1, -1, -1, -1, -1, false, objNull]; // []\n```\n\nThe result suggests it is not empty. But the position is in the middle of a road and there is nothing within 1m but there is \"Land_HighVoltageColumnWire_F\" not far.\n\n```sqf\n// Check if given position is empty within 1m radius ignoring nearest \"Land_HighVoltageColumnWire_F\"\n[4274.66,12113,0.00139618] isFlatEmpty [1, -1, -1, 1, -1, false, nearestObject [[4274.66,12113,0.00139618], \"Land_HighVoltageColumnWire_F\"]]; // [4274.66,12113,48.3209]\n```\n\nThe result now suggests it is empty. So instead of relying on internal proximity check we can combine both commands:\n\n```sqf\nfnc_isFlatEmpty =\n{\n    params [\"_pos\", \"_params\"];\n    _pos = _pos findEmptyPosition [0, _params select 0];\n    if (_pos isEqualTo []) exitWith {[]};\n    _params = +_params;\n    _params set [0, -1];\n    _pos = _pos isFlatEmpty _params;\n    if (_pos isEqualTo []) exitWith {[]};\n    _pos\n};\n\n// Test\n[[4274.66,12113,0.00139618], [1, -1, 0.1, 1, -1, false, objNull]] call fnc_isFlatEmpty; // [4274.53,12113,48.3175]\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isForcedWalk","operator":null,"title":"isForcedWalk","type":"command","url":"https://community.bistudio.com/wiki/isForcedWalk","revid":319117,"updated":"2022-05-13T09:23:13Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if player is forced to walk with forceWalk.","syntaxes":[{"syntax":"isForcedWalk unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName : Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_bool = isForcedWalk player;\n```","code":["_bool = isForcedWalk player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWalk","isWalking","forceSpeed","getSpeed"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isFormationLeader","operator":null,"title":"isFormationLeader","type":"command","url":"https://community.bistudio.com/wiki/isFormationLeader","revid":349302,"updated":"2023-11-08T14:52:18Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the specified unit is subgroup leader.","syntaxes":[{"syntax":"isFormationLeader unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit being checked.","types":["Object"],"since":null,"text":"unit: Object - unit being checked."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if unit is subgroup leader.","text":"Boolean - true if unit is subgroup leader."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_isLeader = isFormationLeader player;\n```","code":["_isLeader = isFormationLeader player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFollow","doFollow","formationLeader","formLeader","leader","selectLeader","setLeader"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isGameFocused","operator":null,"title":"isGameFocused","type":"command","url":"https://community.bistudio.com/wiki/isGameFocused","revid":309152,"updated":"2022-05-03T14:13:47Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of game focus changed by pressing <kbd>ALT</kbd>+<kbd>TAB</kbd> or similar action.","syntaxes":[{"syntax":"isGameFocused","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if game window is focused, false if not","text":"Boolean - true if game window is focused, false if not"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (!isGameFocused) then { endMission \"End\" };\n```","code":["if (!isGameFocused) then { endMission \"End\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isGamePaused"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"isGamePaused","operator":null,"title":"isGamePaused","type":"command","url":"https://community.bistudio.com/wiki/isGamePaused","revid":349063,"updated":"2023-11-08T14:47:20Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of game simulation. Simulation can get paused by pressing <kbd>Alt</kbd>+<kbd>Tab</kbd> or a system dialog opening (e.g. <kbd>Esc</kbd> menu).\nSimulation will not get paused if `-noPause` startup parameter is used.\n\n> [!NOTE]\n> onEachFrame event and `\"EachFrame\"` event handler continue to execute when the simulation is paused, which could result in undesired backlog. Use isGamePaused to skip loop if needed.","syntaxes":[{"syntax":"isGamePaused","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if game simulation is paused, false if not","text":"Boolean - returns true if game simulation is paused, false if not"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nonEachFrame \n{\n    if (isGamePaused) exitWith {};\n    // ...do stuff\n};\n```","code":["onEachFrame \n{\n\tif (isGamePaused) exitWith {};\n\t// ...do stuff\n};"]}],"multiplayer":"In multiplayer the simulation will not get paused and this command will always return false.","problems":null,"aliases":[],"see_also":["isGameFocused"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"isGroupDeletedWhenEmpty","operator":null,"title":"isGroupDeletedWhenEmpty","type":"command","url":"https://community.bistudio.com/wiki/isGroupDeletedWhenEmpty","revid":364533,"updated":"2024-05-16T20:46:45Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the given group marked for auto-deletion when empty. See deleteGroupWhenEmpty.\n\n> [!NOTE]\n> It might take up to a minute for the groups marked for auto-deletion when empty to get deleted when they become empty.\n\n> [!IMPORTANT]\n> This command is only a getter for the deleteWhenEmpty flag in createGroup command or deleteGroupWhenEmpty command. All it does is it shows what the flag was set to during group creation. True does not mean the group will be deleted but that it was suggested to the engine that it should be deleted. It is up to the engine how it manages groups. False does not mean that the group will not be deleted **at all**. It has no influence on the engine functionality whatsoever.","syntaxes":[{"syntax":"isGroupDeletedWhenEmpty group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true the group is marked for auto-deletion when empty","text":"Boolean - true the group is marked for auto-deletion when empty"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_isMarked = isGroupDeletedWhenEmpty _group;\n```","code":["_isMarked = isGroupDeletedWhenEmpty _group;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteGroup","deleteGroupWhenEmpty","createGroup","group","setGroupId","groupID","units","groupFromNetId","netId","leader","selectLeader","join","createCenter","createUnit","createVehicle","Side"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"isHidden","operator":null,"title":"isHidden","type":"command","url":"https://community.bistudio.com/wiki/isHidden","revid":353122,"updated":"2024-03-12T12:48:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns whether a person is hidden (reached the hiding position).\n\n> [!IMPORTANT]\n> Not to be confused with isObjectHidden, which is returning object visibility set with hideObject","syntaxes":[{"syntax":"isHidden person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_bobIsHidden = isHidden bob;\n```","code":["_bobIsHidden = isHidden bob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectHidden","getHideFrom","setHideBehind","findCover"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isInRemainsCollector","operator":null,"title":"isInRemainsCollector","type":"command","url":"https://community.bistudio.com/wiki/isInRemainsCollector","revid":353433,"updated":"2024-03-18T11:57:36Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if unit or vehicle is queued for disposal after death.","syntaxes":[{"syntax":"isInRemainsCollector remain","since":null,"effect":null,"exec":null,"params":[{"name":"remain","type":"Object","optional":false,"default":null,"description":"vehicle or unit","types":["Object"],"since":null,"text":"remain: Object - vehicle or unit"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"remain","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isInRemainsCollector unit1) then {hint \"unit1 is queued for disposal\"};\n```","code":["if (isInRemainsCollector unit1) then {hint \"unit1 is queued for disposal\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addToRemainsCollector","removeFromRemainsCollector","diag_remainsCollector"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"isInstructorFigureEnabled","operator":null,"title":"isInstructorFigureEnabled","type":"command","url":"https://community.bistudio.com/wiki/isInstructorFigureEnabled","revid":310274,"updated":"2022-05-05T13:11:22Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the status of INSTRUCTOR FIGURE setting in UI (OPTIONS >> GAME >> GENERAL >> INSTRUCTOR FIGURE).","syntaxes":[{"syntax":"isInstructorFigureEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str isInstructorFigureEnabled;\n```","code":["hint str isInstructorFigureEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isStreamFriendlyUIEnabled","isTutHintsEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"isIRLaserOn","operator":null,"title":"isIRLaserOn","type":"command","url":"https://community.bistudio.com/wiki/isIRLaserOn","revid":310267,"updated":"2022-05-05T13:11:19Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if there is a linked and enabled IR on the given weapon.","syntaxes":[{"syntax":"unit isIRLaserOn weapon","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weapon","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weapon: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}}],"examples":[{"text":"```sqf\nplayer isIRLaserOn currentWeapon player;\n```","code":["player isIRLaserOn currentWeapon player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableIRLasers","enableGunLights","isLightOn","isCollisionLightOn","setPilotLight","setCollisionLight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isKeyActive","operator":null,"title":"isKeyActive","type":"command","url":"https://community.bistudio.com/wiki/isKeyActive","revid":319058,"updated":"2022-05-13T09:23:07Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the given key is active in the current user profile.\n\nSee keys, keysLimit and doneKeys in the description.ext file of the missions.","syntaxes":[{"syntax":"isKeyActive keyName","since":null,"effect":null,"exec":null,"params":[{"name":"keyName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"keyName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"keyName","types":["String"]}}],"examples":[{"text":"```sqf\n_active = isKeyActive \"Mission04Key\";\n```","code":["_active = isKeyActive \"Mission04Key\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["activateKey","deActivateKey"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isKindOf","operator":null,"title":"isKindOf","type":"command","url":"https://community.bistudio.com/wiki/isKindOf","revid":341247,"updated":"2023-05-18T10:50:41Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the given object or type is (a subtype) of the given type.\n\nWhile #Syntax 1 and #Syntax 2 only support **CfgVehicles**, Arma 2 v1.00**CfgAmmo** and **CfgNonAIVehicles**, #Syntax 3 can be used with any config, including the mission config.","syntaxes":[{"syntax":"object isKindOf typeName","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"typeName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"typeName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"typeName","types":["String"]}},{"syntax":"class1 isKindOf class2","since":null,"effect":null,"exec":null,"params":[{"name":"class1","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"class1: String"},{"name":"class2","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"class2: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"class1","types":["String"]},"right":{"text":"class2","types":["String"]}},{"syntax":"class1 isKindOf [class2, targetConfig]","since":"arma3 1.48","effect":null,"exec":null,"params":[{"name":"class1","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"class1: String"},{"name":"class2","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"class2: String"},{"name":"targetConfig","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"targetConfig: Config"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"class1","types":["String"]},"right":{"text":"[class2, targetConfig]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player isKindOf \"Tank\";\n```","code":["vehicle player isKindOf \"Tank\";"]},{"text":"```sqf\n\"BMP2\" isKindOf \"Tank\";\n```","code":["\"BMP2\" isKindOf \"Tank\";"]},{"text":"```sqf\ncurrentWeapon player isKindOf [\"Rifle\", configFile >> \"CfgWeapons\"];\n```","code":["currentWeapon player isKindOf [\"Rifle\", configFile >> \"CfgWeapons\"];"]},{"text":"```sqf\nprivate _isSoldier = player isKindOf \"CAManBase\";\n```","code":["private _isSoldier = player isKindOf \"CAManBase\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["typeOf","countType","inheritsFrom","configHierarchy"],"notes":[{"user":"Kronzky","date":"2007-04-23T16:34:00Z","text":"This command can be used on the whole hierarchical class tree (i.e. when checking a HMMWV, one could test for \"HMMWV50\", \"Car\", \"LandVehicle\", etc., all of which would return true.)"},{"user":"James","date":"2015-06-16T17:54:00Z","text":"In case you cannot use isKindOf because of the reasons stated, just use BIS_fnc_returnParents with class names as return value:\n\n```sqf\n_isKindOf = \"Rifle\" in [configFile >> \"CfgWeapons\" >> \"BWA3_G36K\", true] call BIS_fnc_returnParents; // is true\n```"},{"user":"Basstard","date":"2015-09-06T22:21:00Z","text":"In Arma 3 isKindOf works well with CfgWeapons and CfgMagazines using the syntax from example 3.\n\nIt should be prefered to James' solution as it performs more than 25x faster. Tested in debug console with the following code snippets:\n\n```sqf\n\"CA_Magazine\" in ([configFile >> \"CfgMagazines\" >> \"HandGrenade\", true] call BIS_fnc_returnParents);    // 0.12111 ms\n\"HandGrenade\" isKindOf [\"CA_Magazine\", configFile >> \"CfgMagazines\"];                                    // 0.00439453 ms\n```\n\nWhen checking in CfgVehicles the syntax from #Example 2 performs a little faster."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isLaserOn","operator":null,"title":"isLaserOn","type":"command","url":"https://community.bistudio.com/wiki/isLaserOn","revid":377491,"updated":"2026-01-02T06:49:13Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Returns true if the vehicle has its laser turned on. Not to be confused with isIRLaserOn which is for units. Main syntax is for primary gunner turret.","syntaxes":[{"syntax":"isLaserOn entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when laser is on, false otherwise","text":"Boolean - true when laser is on, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"vehicle isLaserOn turret","since":"Arma3 2.12","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":"[-1] for driver turret","types":["Turret Path"],"since":null,"text":"turret: Turret Path - [-1] for driver turret"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when laser is on, false otherwise","text":"Boolean - true when laser is on, false otherwise"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turret","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nif (isLaserOn _vehicle) then { hint \"target ready\" };\n```","code":["if (isLaserOn _vehicle) then { hint \"target ready\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["laserTarget","enableIRLasers","isIRLaserOn"],"notes":[{"user":"Sa-Matra","date":"2022-12-27T08:27:27Z","text":"Does not mean there is actual laser object present. Returns laser designator weapon's toggle state. In other words isLaserOn can return `true` while laserTarget returns `<NULL-object>`, for example in case laser was turned on and unit left the vehicle, there would be no laser target entity anymore, while designator is still turned on."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.78","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"isLightOn","operator":null,"title":"isLightOn","type":"command","url":"https://community.bistudio.com/wiki/isLightOn","revid":377881,"updated":"2026-01-04T16:20:38Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if vehicle headlights are on otherwise false.","syntaxes":[{"syntax":"isLightOn vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with headlights","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with headlights"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"isLightOn [vehicle, turret]","since":"arma3 1.94","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with search light on a turret","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with search light on a turret"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turret: Turret Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, turret]","types":["Array"]}}],"examples":[{"text":"```sqf\n_headlightsOn = isLightOn vehicle player;\n```","code":["_headlightsOn = isLightOn vehicle player;"]},{"text":"```sqf\n_pilotLightOn = isLightOn heli;\n```","code":["_pilotLightOn = isLightOn heli;"]},{"text":"```sqf\n_searchLightOn = isLightOn [heli, [0]];\n```","code":["_searchLightOn = isLightOn [heli, [0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPilotLight","isCollisionLightOn","setCollisionLight","isIRLaserOn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"isLocalized","operator":null,"title":"isLocalized","type":"command","url":"https://community.bistudio.com/wiki/isLocalized","revid":349114,"updated":"2023-11-08T14:49:37Z","groups":["Strings","Localization"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether given *stringName* is localized.","syntaxes":[{"syntax":"isLocalized stringName","since":null,"effect":null,"exec":null,"params":[{"name":"stringName","type":"String","optional":false,"default":null,"description":"string which leads to localisation. Casing does not matter. Since Arma 3 v2.04 a string starting with `\"$\"` is supported as well","types":["String"],"since":null,"text":"stringName: String - string which leads to localisation. Casing does not matter. Since Arma 3 v2.04 a string starting with `\"$\"` is supported as well"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"stringName","types":["String"]}}],"examples":[{"text":"```sqf\nif (isLocalized \"STR_USRACT_ADJUST\") then \n{\n    hint localize \"STR_USRACT_ADJUST\";\n} \nelse \n{\n    hint \"STR_USRACT_ADJUST\";\n    diag_log \"ToDo: STR_USRACT_ADJUST is not localized\";\n};\n```","code":["if (isLocalized \"STR_USRACT_ADJUST\") then \n{\n\thint localize \"STR_USRACT_ADJUST\";\n} \nelse \n{\n\thint \"STR_USRACT_ADJUST\";\n\tdiag_log \"ToDo: STR_USRACT_ADJUST is not localized\";\n};"]},{"text":"```sqf\nisLocalized \"$STR_USRACT_ADJUST\"; // Since Arma v2.04\n```","code":["isLocalized \"$STR_USRACT_ADJUST\"; // Since Arma v2.04"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["localize","diag_localized","getTextRaw","WFSideText","Stringtable.csv","Stringtable.xml","BIS_fnc_localize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Localization","Command Group: Strings","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isManualFire","operator":null,"title":"isManualFire","type":"command","url":"https://community.bistudio.com/wiki/isManualFire","revid":364125,"updated":"2024-05-04T22:07:43Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if manual fire is on. Manual fire could either be selected in vehicle action menu (if available) or with action \"ManualFire\" and \"ManualFireCancel\". Always returns false for a soldier.","syntaxes":[{"syntax":"isManualFire vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n_bool = isManualFire vehicle player;\n```","code":["_bool = isManualFire vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","doFire","commandFire","canFire","fireAtTarget","forceWeaponFire","commandArtilleryFire","commandSuppressiveFire","doArtilleryFire","doSuppressiveFire"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isMarkedForCollection","operator":null,"title":"isMarkedForCollection","type":"command","url":"https://community.bistudio.com/wiki/isMarkedForCollection","revid":310851,"updated":"2022-05-07T20:24:08Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks whether the object is marked for weapons collection.","syntaxes":[{"syntax":"isMarkedForCollection object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_marked = isMarkedForCollection _truck;\n```","code":["_marked = isMarkedForCollection _truck;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isMissionProfileNamespaceLoaded","operator":null,"title":"isMissionProfileNamespaceLoaded","type":"command","url":"https://community.bistudio.com/wiki/isMissionProfileNamespaceLoaded","revid":330167,"updated":"2022-08-23T12:23:59Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The missionProfileNamespace variables are loaded at the start of a mission, before 'init.sqf' is executed. If the file with saved variables for current mission exists in user profile and is loaded, the command returns true. It also will return true after the first execution of saveMissionProfileNamespace command, which also creates the file.","syntaxes":[{"syntax":"isMissionProfileNamespaceLoaded","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if mission profile variables file exists and is loaded.","text":"Boolean - true if mission profile variables file exists and is loaded."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _isLoaded = isMissionProfileNamespaceLoaded;\n```","code":["private _isLoaded = isMissionProfileNamespaceLoaded;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionProfileNamespace","saveMissionProfileNamespace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"isMultiplayer","operator":null,"title":"isMultiplayer","type":"command","url":"https://community.bistudio.com/wiki/isMultiplayer","revid":369356,"updated":"2024-09-03T18:43:05Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return true if multiPlayer.","syntaxes":[{"syntax":"isMultiplayer","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isMultiplayer) then\n{\n    // ...block\n}\n```","code":["if (isMultiplayer) then\n{\n\t// ...block\n}"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isDedicated","isServer"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isMultiplayerSolo","operator":null,"title":"isMultiplayerSolo","type":"command","url":"https://community.bistudio.com/wiki/isMultiplayerSolo","revid":310750,"updated":"2022-05-07T20:21:31Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true when playing a game in **solo multiplayer** (for example Apex coop campaign PLAY SOLO option).","syntaxes":[{"syntax":"isMultiplayerSolo","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_state = isMultiplayerSolo;\n```","code":["_state = isMultiplayerSolo;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isMultiplayer","isDedicated","hasInterface","isServer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"isNil","operator":null,"title":"isNil","type":"command","url":"https://community.bistudio.com/wiki/isNil","revid":370850,"updated":"2025-02-18T00:01:09Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Tests whether a variable is nil or undefined from its identifier, or whether the given expression evaluates to nil or Nothing.\n\n> [!NOTE]\n> This command does not exist in Operation Flashpoint/Arma: Cold War Assault but can be emulated (see #Example 5).","syntaxes":[{"syntax":"isNil variableName","since":null,"effect":null,"exec":null,"params":[{"name":"variableName","type":"String","optional":false,"default":null,"description":"missionNamespace's or local variable's identifier (e.g \"globalVariable\", \"_localVariable\")","types":["String"],"since":null,"text":"variableName: **String** - missionNamespace's or local variable's identifier (e.g \"globalVariable\", \"_localVariable\")"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if variable is nil or undefined","text":"Boolean - true if variable is nil or undefined"},"form":"unary","operator":null,"left":null,"right":{"text":"variableName","types":["String"]}},{"syntax":"isNil code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":"code to evaluate:\n- the code **will** be executed; `isNil { player setDamage 1 };` *will* kill the player\n- the code will not be allowed to suspend while expression is evaluated, even if the parent scope allows it (see #Example 4).","types":["Code"],"since":null,"text":"code: Code - code to evaluate:\n- the code **will** be executed; `isNil { player setDamage 1 };` *will* kill the player\n- the code will not be allowed to suspend while expression is evaluated, even if the parent scope allows it (see #Example 4)."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if code returns Nothing, false otherwise","text":"Boolean - true if *code* returns Nothing, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}},{"syntax":"namespace isNil variableName","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"namespace","type":"Namespace, Object, Group, HashMap, Arma 3 v2.20 Control and Display","optional":false,"default":null,"description":null,"types":["Namespace","Object","Group","HashMap","Control","Display"],"since":null,"text":"namespace: Namespace, Object, Group, HashMap, Arma 3 v2.20 Control and Display"},{"name":"variableName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"variableName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if variable is nil or undefined","text":"Boolean - true if variable is nil or undefined"},"form":"binary","operator":null,"left":{"text":"namespace","types":["Namespace","Object","Group","HashMap","Control","Display"]},"right":{"text":"variableName","types":["String"]}}],"examples":[{"text":"```sqf\nif (isNil \"TAG_globalVariable\") then { TAG_globalVariable = 0 };\nif (isNil \"_localVariable\") then { hint \"_localVariable is nil\" };\n```","code":["if (isNil \"TAG_globalVariable\") then { TAG_globalVariable = 0 };\nif (isNil \"_localVariable\") then { hint \"_localVariable is nil\" };"]},{"text":"```sqf\nisNil { player getVariable \"someVar\" };\n```","code":["isNil { player getVariable \"someVar\" };"]},{"text":"```sqf\n_myArray = [0, 1];\nisNil { _myArray select 0 }; // returns false\nisNil { _myArray select 1 }; // returns false\nisNil { _myArray select 2 }; // returns true\nisNil { _myArray select 3 }; // throws a script error. only length+1 select is allowed\n```","code":["_myArray = [0, 1];\nisNil { _myArray select 0 }; // returns false\nisNil { _myArray select 1 }; // returns false\nisNil { _myArray select 2 }; // returns true\nisNil { _myArray select 3 }; // throws a script error. only length+1 select is allowed"]},{"text":"This trick forces executing something in Unscheduled Environment:\n\n```sqf\n0 spawn {\n    systemChat str canSuspend;        // chat shows true\n    isNil { hint str canSuspend };    // hint shows false\n};\n```","code":["0 spawn {\n\tsystemChat str canSuspend;\t\t// chat shows true\n\tisNil { hint str canSuspend };\t// hint shows false\n};"]},{"text":"Operation Flashpoint String comparison workaround\n\nSQS Syntax:\n\n```sqs\n_nil = format [\"%1\", _undefinedVariable]\n? (format [\"%1\", variableToTest] == _nil) : hint \"variableToTest is nil\"\n```\n\nSQF Syntax:\n\n```sqf\n_nil = format [\"%1\", _undefinedVariable];\nif (format [\"%1\", variableToTest] == _nil) then { hint \"variableToTest is nil\" };\n```","code":["_nil = format [\"%1\", _undefinedVariable]\n? (format [\"%1\", variableToTest] == _nil) : hint \"variableToTest is nil\"","_nil = format [\"%1\", _undefinedVariable];\nif (format [\"%1\", variableToTest] == _nil) then { hint \"variableToTest is nil\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nil","Variables","Scheduler"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isNotEqualRef","operator":null,"title":"isNotEqualRef","type":"command","url":"https://community.bistudio.com/wiki/isNotEqualRef","revid":338493,"updated":"2023-03-10T17:30:50Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Compares two values by reference, returns true if not equal.","syntaxes":[{"syntax":"val1 isNotEqualRef val2","since":null,"effect":null,"exec":null,"params":[{"name":"val1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val1: Anything"},{"name":"val2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val2: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if not the same reference","text":"Boolean - true if not the same reference"},"form":"binary","operator":null,"left":{"text":"val1","types":["Anything"]},"right":{"text":"val2","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr1 = [1,[2,[3]]];\n_arr2 = _arr1;\n_arr1 isEqualTo _arr2;        // true\n_arr1 isNotEqualRef _arr2;    // false\n\n_arr2 = +_arr1;                // array copy\n_arr1 isEqualTo _arr2;        // true\n_arr1 isNotEqualRef _arr2;    // true\n```","code":["_arr1 = [1,[2,[3]]];\n_arr2 = _arr1;\n_arr1 isEqualTo _arr2;\t\t// true\n_arr1 isNotEqualRef _arr2;\t// false\n\n_arr2 = +_arr1;\t\t\t\t// array copy\n_arr1 isEqualTo _arr2;\t\t// true\n_arr1 isNotEqualRef _arr2;\t// true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualRef","isNotEqualTo","Operators"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"isNotEqualTo","operator":null,"title":"isNotEqualTo","type":"command","url":"https://community.bistudio.com/wiki/isNotEqualTo","revid":330347,"updated":"2022-09-02T12:25:54Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Performs strict comparison between var1 and var2 and returns false if equal, otherwise true.","syntaxes":[{"syntax":"val1 isNotEqualTo val2","since":null,"effect":null,"exec":null,"params":[{"name":"val1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val1: Anything"},{"name":"val2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"val2: Anything"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"val1","types":["Anything"]},"right":{"text":"val2","types":["Anything"]}}],"examples":[{"text":"```sqf\nprivate _true = 0 isNotEqualTo 1;\n```","code":["private _true = 0 isNotEqualTo 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTo","isNotEqualRef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"isNull","operator":null,"title":"isNull","type":"command","url":"https://community.bistudio.com/wiki/isNull","revid":370892,"updated":"2025-02-21T10:44:05Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks whether the tested item is null.\n\nWhich null type the item has to be equal to depends on the type of game entity tested:\n\n|  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|\n| Type | Object | Group | Control | Display | Location | Task | Script | Config | Diary Record | Team Member |\n| Null value | objNull | grpNull | controlNull | displayNull | locationNull | taskNull | scriptNull | configNull | diaryRecordNull | teamMemberNull |\n| Since | Operation Flashpoint v1.00 | Armed Assault v1.00 | Arma 2 v1.00 | Arma 3 v1.30 | Arma 3 v1.54 | Arma 3 v2.00 | Arma 3 v2.10 |  |  |  |\n\n> [!IMPORTANT]\n>","syntaxes":[{"syntax":"isNull entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":null,"optional":false,"default":null,"description":"Object, Control, Display, Group, Location, Task, Script Handle, Config or Diary Record","types":["Object","Control","Display","Group","Location","Task","Script Handle","Config","Diary Record"],"since":null,"text":"entity: Object, Control, Display, Group, Location, Task, Script Handle, Config or Diary Record"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object","Control","Display","Group","Location","Task","Script Handle","Config","Diary Record"]}}],"examples":[{"text":"```sqf\nif (isNil \"obj\") exitWith { hint \"obj variable is undefined\" };\n\nif (isNull obj) then\n{\n    hint \"obj variable is defined but is null\";\n}\nelse\n{\n    hint \"obj variable is defined and is not null\";\n};\n```","code":["if (isNil \"obj\") exitWith { hint \"obj variable is undefined\" };\n\nif (isNull obj) then\n{\n\thint \"obj variable is defined but is null\";\n}\nelse\n{\n\thint \"obj variable is defined and is not null\";\n};"]},{"text":"Diary Record support before Arma 3 v2.00:\n\n```sqf\nprivate _nullRecord = objNull createDiaryRecord []; // wrong parameters = failure to create a record = null value\nprivate _createdRecord = player createDiaryRecord [\"Diary\", [\"title\", \"description\"]];\nif (_createdRecord isEqualTo _nullRecord) then { hint \"Failed\" };\n```\n\nTeam Member support before Arma 3 v2.10:\n\n```sqf\nprivate _isNull = _teamMember isEqualTo teamMemberNull;\n```","code":["private _nullRecord = objNull createDiaryRecord []; // wrong parameters = failure to create a record = null value\nprivate _createdRecord = player createDiaryRecord [\"Diary\", [\"title\", \"description\"]];\nif (_createdRecord isEqualTo _nullRecord) then { hint \"Failed\" };","private _isNull = _teamMember isEqualTo teamMemberNull;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","locationNull","objNull","taskNull","teamMemberNull","scriptNull","configNull","typeName"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isNumber","operator":null,"title":"isNumber","type":"command","url":"https://community.bistudio.com/wiki/isNumber","revid":323074,"updated":"2022-06-28T21:43:12Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if config entry represents number.","syntaxes":[{"syntax":"isNumber config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_ok = isNumber (configFile >> \"CfgVehicles\");\n```\n\nResult is false","code":["_ok = isNumber (configFile >> \"CfgVehicles\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","a / b","configName","count","getArray","getText","getNumber","inheritsFrom","isArray","isClass","isText","select"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isObjectHidden","operator":null,"title":"isObjectHidden","type":"command","url":"https://community.bistudio.com/wiki/isObjectHidden","revid":319236,"updated":"2022-05-13T09:23:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Checks visibility of a given object on the local machine.","syntaxes":[{"syntax":"isObjectHidden object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to test","types":["Object"],"since":null,"text":"object: Object - object to test"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if hidden, false if visible","text":"Boolean - true if hidden, false if visible"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_bobIsHidden = isObjectHidden bob;\n```","code":["_bobIsHidden = isObjectHidden bob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideObject","hideObjectGlobal","deleteCollection"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.48","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"isObjectRTD","operator":null,"title":"isObjectRTD","type":"command","url":"https://community.bistudio.com/wiki/isObjectRTD","revid":330053,"updated":"2022-08-15T16:03:49Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if RTD model is loaded.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"isObjectRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_heliRTD = isObjectRTD vehicle player;\n```","code":["_heliRTD = isObjectRTD vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weightRTD","difficultyEnabledRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"isOnRoad","operator":null,"title":"isOnRoad","type":"command","url":"https://community.bistudio.com/wiki/isOnRoad","revid":377415,"updated":"2026-01-02T06:45:20Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if given position is inside road segment. Same as roadAt, only return is boolean instead of road object.","syntaxes":[{"syntax":"isOnRoad position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":null,"optional":false,"default":null,"description":"Object or PositionAGL (especially on bridges) or Arma 3 v2.00 Position2D, in which case Z will be automatically deduced as the height of the road surface","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL (especially on bridges) or Arma 3 v2.00 Position2D, in which case Z will be automatically deduced as the height of the road surface"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Object","PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_objOnRoad = isOnRoad player;\n```","code":["_objOnRoad = isOnRoad player;"]},{"text":"```sqf\n_posOnRoad = isOnRoad ASLToAGL getPosASL player;\n```","code":["_posOnRoad = isOnRoad ASLToAGL getPosASL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearRoads","roadsConnectedTo","roadAt","surfaceIsWater","getRoadInfo","nearestTerrainObjects"],"notes":[{"user":"Tankbuster","date":"2017-11-24T21:31:00Z","text":"Some roadobjects will return false when using this command. invisibleroadway_square_f.p3d is found by the nearRoads command, yet will return false for isOnRoad."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isPiPEnabled","operator":null,"title":"isPiPEnabled","type":"command","url":"https://community.bistudio.com/wiki/isPiPEnabled","revid":310808,"updated":"2022-05-07T20:22:00Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether Picture-In-Picture video option (Render to Texture) is enabled or not.","syntaxes":[{"syntax":"isPiPEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _PiPState = isPiPEnabled;\n```","code":["private _PiPState = isPiPEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_PIP"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: System","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isPlayer","operator":null,"title":"isPlayer","type":"command","url":"https://community.bistudio.com/wiki/isPlayer","revid":363376,"updated":"2024-03-29T08:30:20Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if given person is a player. Returns true for headless clients as well.\n\n> [!NOTE]\n> Prior to Arma 3 v2.02, in some cases the identity of certain player units could fail to propagate to other clients and the server, which caused isPlayer and getPlayerUID to incorrectly return `false` and `\"\"` respectively, where the affected units were not local. See [this GitHub bug report](https://github.com/michail-nikolaev/task-force-arma-3-radio/issues/1096) for more info. Remain vigilant toward potential false negatives.\n\n> [!IMPORTANT]\n> When used on vehicles, this command will return true if effectiveCommander of the vehicle is player. Just because it returns true does not automatically mean we have a player unit. Unlike main syntax, alternative syntax always returns false when used on vehicles, even if they're controlled by a player.","syntaxes":[{"syntax":"isPlayer unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"isPlayer [person]","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"dead or alive unit","types":["Object"],"since":null,"text":"person: Object - dead or alive unit"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if is/was player and the identity still exists on the (dead) body","text":"Boolean - true if is/was player **and** the identity still exists on the (dead) body"},"form":"unary","operator":null,"left":null,"right":{"text":"[person]","types":["Array"]}}],"examples":[{"text":"```sqf\nif (isPlayer _Soldier1) then\n{\n    _soldier1 setDamage 1;\n};\n```","code":["if (isPlayer _Soldier1) then\n{\n\t_soldier1 setDamage 1;\n};"]},{"text":"```sqf\n_playerCount = { isPlayer _x } count playableUnits;\n```","code":["_playerCount = { isPlayer _x } count playableUnits;"]},{"text":"```sqf\nprivate _wasPlayer = isPlayer [_deadBody]; // returns true if _deadBody's identity still exists and was controlled by a player\n```","code":["private _wasPlayer = isPlayer [_deadBody]; // returns true if _deadBody's identity still exists and was controlled by a player"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["player","playableSlotsNumber","playableUnits","playersNumber"],"notes":[{"user":"Kronzky","date":"","text":"This is not the same as testing object == player, because in MP it tests for any player, not only for the local one. If object is a vehicle, the test is done for the vehicle commander."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isRealTime","operator":null,"title":"isRealTime","type":"command","url":"https://community.bistudio.com/wiki/isRealTime","revid":323018,"updated":"2022-06-28T21:43:07Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the mission editor is operating in real time mode.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"isRealTime map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\n_isRealTime = isRealTime _map;\n```","code":["_isRealTime = isRealTime _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isRemoteControlling","operator":null,"title":"isRemoteControlling","type":"command","url":"https://community.bistudio.com/wiki/isRemoteControlling","revid":347218,"updated":"2023-09-05T16:49:02Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns true if the given player is remote-controlling a unit.\n\n> [!IMPORTANT]\n> See also Remote Control Tutorial.","syntaxes":[{"syntax":"isRemoteControlling person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"a player","types":["Object"],"since":null,"text":"person: Object - a player"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the given player is remote controlling a unit","text":"Boolean - true if the given player is remote controlling a unit"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isRemoteControlling player) then\n{\n    hint format [\"You are controlling %1\", remoteControlled player];\n}\nelse\n{\n    hint \"Why not remote-control something?\";\n};\n```","code":["if (isRemoteControlling player) then\n{\n\thint format [\"You are controlling %1\", remoteControlled player];\n}\nelse\n{\n\thint \"Why not remote-control something?\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remoteControl","remoteControlled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"isRemoteExecuted","operator":null,"title":"isRemoteExecuted","type":"command","url":"https://community.bistudio.com/wiki/isRemoteExecuted","revid":365039,"updated":"2024-07-14T13:22:37Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the code context is being remote executed by remoteExec or remoteExecCall. In SP always returns false. See also isRemoteExecutedJIP:\n\n| command | Single Player | Multiplayer |  |\n|---|---|---|---|\n| Direct remoteExec | JIP remoteExec |  |  |\n| isRemoteExecuted | ✗ | ✓ | ✓ |\n| isRemoteExecutedJIP | ✗ | ✗ | ✓ |","syntaxes":[{"syntax":"isRemoteExecuted","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _remoteExecuted = isRemoteExecuted;\n```","code":["private _remoteExecuted = isRemoteExecuted;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isRemoteExecutedJIP","remoteExec","remoteExecCall","canSuspend","remoteExecutedOwner","isUIContext","isGamePaused","isGameFocused","remoteExecutedJIPID"],"notes":[{"user":"Demellion","date":"2017-09-11T11:16:00Z","text":"When remoteExec/remoteExecCall is called from a headless client to client, this will always return as false.\n\nThis effect also occurs with remoteExecutedOwner - it will return always return 0 from a headless client."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Remote Execution","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"isRemoteExecutedJIP","operator":null,"title":"isRemoteExecutedJIP","type":"command","url":"https://community.bistudio.com/wiki/isRemoteExecutedJIP","revid":365041,"updated":"2024-07-14T13:23:02Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the code context is being remote executed from the JIP queue by remoteExec or remoteExecCall (when JIP param was set). It is a subset of isRemoteExecuted:\n\n| command | Single Player | Multiplayer |  |\n|---|---|---|---|\n| Direct remoteExec | JIP remoteExec |  |  |\n| isRemoteExecuted | ✗ | ✓ | ✓ |\n| isRemoteExecutedJIP | ✗ | ✗ | ✓ |","syntaxes":[{"syntax":"isRemoteExecutedJIP","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isRemoteExecutedJIP) then\n{\n    waitUntil { sleep 0.1; not isNull player };\n    hint \"Welcome... the battlefield did not wait for you!\";\n}\nelse\n{\n    hint \"You are present and that's good!\";\n};\n```","code":["if (isRemoteExecutedJIP) then\n{\n\twaitUntil { sleep 0.1; not isNull player };\n\thint \"Welcome... the battlefield did not wait for you!\";\n}\nelse\n{\n\thint \"You are present and that's good!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isRemoteExecuted","remoteExec","remoteExecCall","canSuspend","remoteExecutedOwner","isUIContext","isGamePaused","isGameFocused","remoteExecutedJIPID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Remote Execution","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"isSaving","operator":null,"title":"isSaving","type":"command","url":"https://community.bistudio.com/wiki/isSaving","revid":369063,"updated":"2024-09-02T20:24:55Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the status of autosave request, made when saveGame command is executed. When request is made, the command immediately returns true. The engine then handles the saving and when it is done, the command returns false.","syntaxes":[{"syntax":"isSaving","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true autosave request is made, false autosave request is processed","text":"Boolean - true autosave request is made, false autosave request is processed"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n0 spawn\n{\n    saveGame;\n    waitUntil { !isSaving };\n    systemChat \"Game Saving Is Done!\";\n};\n```","code":["0 spawn\n{\n\tsaveGame;\n\twaitUntil { !isSaving };\n\tsystemChat \"Game Saving Is Done!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveGame","enableSaving","loadGame","savingEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"isSensorTargetConfirmed","operator":null,"title":"isSensorTargetConfirmed","type":"command","url":"https://community.bistudio.com/wiki/isSensorTargetConfirmed","revid":310733,"updated":"2022-05-07T20:04:52Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if given unit is confirmed target for given side.","syntaxes":[{"syntax":"unit isSensorTargetConfirmed side","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if confirmed target, otherwise false","text":"Boolean - true if confirmed target, otherwise false"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\nprivate _enemyConfirmed = _possibleEnemy isSensorTargetConfirmed opfor;\n```","code":["private _enemyConfirmed = _possibleEnemy isSensorTargetConfirmed opfor;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["listVehicleSensors","isVehicleSensorEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"isServer","operator":null,"title":"isServer","type":"command","url":"https://community.bistudio.com/wiki/isServer","revid":369339,"updated":"2024-09-03T18:43:01Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.99"},{"game":"arma1","name":"Armed Assault","version":"1.06"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.99"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the machine executing the command is the server in a multiplayer game or is running single player. It will return true for both dedicated and player-hosted server. See also Multiplayer Scripting/machines.","syntaxes":[{"syntax":"isServer","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (!isServer) exitWith {};\n```","code":["if (!isServer) exitWith {};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isDedicated","isMultiplayer","hasInterface","local"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint version 1.99","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isShowing3DIcons","operator":null,"title":"isShowing3DIcons","type":"command","url":"https://community.bistudio.com/wiki/isShowing3DIcons","revid":353375,"updated":"2024-03-15T17:11:58Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the editor is set to draw 3D icons.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"isShowing3DIcons map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isSimpleObject","operator":null,"title":"isSimpleObject","type":"command","url":"https://community.bistudio.com/wiki/isSimpleObject","revid":310876,"updated":"2022-05-07T20:24:10Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if given object is simple object","syntaxes":[{"syntax":"isSimpleObject object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_isSimple = isSimpleObject _obj1;\n```","code":["_isSimple = isSimpleObject _obj1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleObject","allSimpleObjects","nearestObjects","nearObjectsReady","nearObjects","nearestObject"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"isSprintAllowed","operator":null,"title":"isSprintAllowed","type":"command","url":"https://community.bistudio.com/wiki/isSprintAllowed","revid":341802,"updated":"2023-06-24T08:22:53Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns true if player is allowed to sprint","syntaxes":[{"syntax":"isSprintAllowed unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (not isSprintAllowed player) then { hint \"no running in the corridors!\" };\n```","code":["if (not isSprintAllowed player) then { hint \"no running in the corridors!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","allowSprint"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isStaminaEnabled","operator":null,"title":"isStaminaEnabled","type":"command","url":"https://community.bistudio.com/wiki/isStaminaEnabled","revid":321931,"updated":"2022-05-22T12:50:06Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if stamina depletion is enabled.","syntaxes":[{"syntax":"isStaminaEnabled unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isStaminaEnabled player) then { hint \"You can get exhausted.\" };\n```","code":["if (isStaminaEnabled player) then { hint \"You can get exhausted.\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"isSteamMission","operator":null,"title":"isSteamMission","type":"command","url":"https://community.bistudio.com/wiki/isSteamMission","revid":369183,"updated":"2024-09-03T10:34:45Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the current mission is a Steam Workshop mission.","syntaxes":[{"syntax":"isSteamMission","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isSteamMission) then\n{\n    hint \"Thank you for subscribing to my mission on Steam!\";\n}\nelse\n{\n    hint \"Thank you for downloading my mission off the Internet!\";\n};\n```","code":["if (isSteamMission) then\n{\n\thint \"Thank you for subscribing to my mission on Steam!\";\n}\nelse\n{\n\thint \"Thank you for downloading my mission off the Internet!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["markAsFinishedOnSteam"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"isSteamOverlayEnabled","operator":null,"title":"isSteamOverlayEnabled","type":"command","url":"https://community.bistudio.com/wiki/isSteamOverlayEnabled","revid":330173,"updated":"2022-08-23T12:24:04Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if Steam overlay is enabled, otherwise false.","syntaxes":[{"syntax":"isSteamOverlayEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_overlayEnabled = isSteamOverlayEnabled;\n```","code":["_overlayEnabled = isSteamOverlayEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlSetURLOverlayMode","ctrlURLOverlayMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"isStreamFriendlyUIEnabled","operator":null,"title":"isStreamFriendlyUIEnabled","type":"command","url":"https://community.bistudio.com/wiki/isStreamFriendlyUIEnabled","revid":310270,"updated":"2022-05-05T13:11:20Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the status of STREAM FRIENDLY UI setting in UI (OPTIONS >> GAME >> GENERAL >> STREAM FRIENDLY UI).","syntaxes":[{"syntax":"isStreamFriendlyUIEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str isStreamFriendlyUIEnabled;\n```","code":["hint str isStreamFriendlyUIEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isInstructorFigureEnabled","isTutHintsEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.70","Scripting Commands"]},{"name":"isStressDamageEnabled","operator":null,"title":"isStressDamageEnabled","type":"command","url":"https://community.bistudio.com/wiki/isStressDamageEnabled","revid":310782,"updated":"2022-05-07T20:21:46Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns true if stress damage is enabled in the game settings. A getter for enableStressDamage.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"isStressDamageEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean Returns true if enabled, otherwise false","types":["Boolean"],"description":null,"text":"Boolean Returns true if enabled, otherwise false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_settingEnabled = isStressDamageEnabled;\n```","code":["_settingEnabled = isStressDamageEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableStressDamage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"isSwitchingWeapon","operator":null,"title":"isSwitchingWeapon","type":"command","url":"https://community.bistudio.com/wiki/isSwitchingWeapon","revid":376101,"updated":"2025-08-20T14:10:18Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns wether or not the unit is in the process of switching weapon.","syntaxes":[{"syntax":"isSwitchingWeapon unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the unit is switching weapon.","text":"Boolean - true if the unit is switching weapon."},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nisSwitchingWeapon player;\n```","code":["isSwitchingWeapon player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["primaryWeaponMagazine","primaryWeaponItems","addPrimaryWeaponItem","removePrimaryWeaponItem","removeAllPrimaryWeaponItems","secondaryWeapon","handgunWeapon","currentWeapon","weapons","primaryWeapon","setUnitLoadout"],"notes":[{"user":"OverlordZorn","date":"2025-08-20T14:10:18Z","text":"as of 2.20, this does not return true when the unit is prone"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.20","Scripting Commands"]},{"name":"isText","operator":null,"title":"isText","type":"command","url":"https://community.bistudio.com/wiki/isText","revid":321182,"updated":"2022-05-13T15:18:34Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if config entry represents a text value.","syntaxes":[{"syntax":"isText config","since":null,"effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_isText = isText (configFile >> \"CfgVehicles\") // false\n```","code":["_isText = isText (configFile >> \"CfgVehicles\") // false"]},{"text":"```sqf\n_isText = isText (configFile >> \"CfgVehicles\" >> \"B_MRAP_01_F\" >> \"displayName\") // true\n```","code":["_isText = isText (configFile >> \"CfgVehicles\" >> \"B_MRAP_01_F\" >> \"displayName\") // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getText","getNumber","isArray","isClass","isNumber"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isThrowable","operator":null,"title":"isThrowable","type":"command","url":"https://community.bistudio.com/wiki/isThrowable","revid":369755,"updated":"2024-10-08T15:08:55Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the given magazine is a throwable.","syntaxes":[{"syntax":"isThrowable magazine","since":null,"effect":null,"exec":null,"params":[{"name":"magazine","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazine: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if throwable","text":"Boolean - true if throwable"},"form":"unary","operator":null,"left":null,"right":{"text":"magazine","types":["String"]}}],"examples":[{"text":"```sqf\nisThrowable \"HandGrenade\"; // true\n```","code":["isThrowable \"HandGrenade\"; // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectThrowable","currentThrowable","throwables","selectWeapon","currentWeapon","currentMagazine","currentMuzzle","BIS_fnc_isThrowable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"isTouchingGround","operator":null,"title":"isTouchingGround","type":"command","url":"https://community.bistudio.com/wiki/isTouchingGround","revid":376406,"updated":"2025-10-11T00:58:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if object is touching the ground.","syntaxes":[{"syntax":"isTouchingGround object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nif (isTouchingGround player) then { hint \"Terraferma!\" };\n```","code":["if (isTouchingGround player) then { hint \"Terraferma!\" };"]},{"text":"A full \"is safely parked\" method for air, ground and water vehicles:\n\n```sqf\n// get if a vehicle is properly parked - covers e.g helicopter landed on a building, boat (beached or not) and underwater or not submarine\n// return false on null, disabled or destroyed vehicle\nprivate _isSafelyParked = {\n    params [\n        [\"_vehicle\", objNull, [objNull]],                // 0: OBJECT - vehicle - a null object returns false\n        [\"_altitudeTolerance\", 0.1, [0]],                // 1: NUMBER - altitude tolerance - in metre\n        [\"_velocityTolerance\", 0.01, [0]]                // 2: NUMBER - velocity tolerance - in km/h\n    ];\n\n    if (not canMove _vehicle) exitWith { false };        // returns false for null as well\n\n    if (_vehicle isKindOf \"Ship\") then\n    {\n        // surfaceIsWater getPosASL _vehicle                        // a beached boat is fine\n        velocity _vehicle params [\"_velX\", \"_velY\"];\n        sqrt (_velX * _velX + _velY * _velY) < _velocityTolerance    // only 2D speed matters (think waves)\n        && {\n            getPosASLW _vehicle select 2 < _altitudeTolerance                // underwater submarines are OK\n            || { getPos _vehicle select 2 < _altitudeTolerance }    // beached boat\n        };\n    }\n    else\n    {\n        // over -a- ground and not over ocean\n        (isTouchingGround _vehicle || {\n            getPosASLW _vehicle select 2 >= _altitudeTolerance        // not in water\n            && { getPos _vehicle select 2 < _altitudeTolerance }\n        })\n        && { vectorMagnitude velocity _vehicle * 3.6 < _velocityTolerance }\n    }\n};\n\nobjectParent player call _isSafelyParked;\n```","code":["// get if a vehicle is properly parked - covers e.g helicopter landed on a building, boat (beached or not) and underwater or not submarine\n// return false on null, disabled or destroyed vehicle\nprivate _isSafelyParked = {\n\tparams [\n\t\t[\"_vehicle\", objNull, [objNull]],\t\t\t\t// 0: OBJECT - vehicle - a null object returns false\n\t\t[\"_altitudeTolerance\", 0.1, [0]],\t\t\t\t// 1: NUMBER - altitude tolerance - in metre\n\t\t[\"_velocityTolerance\", 0.01, [0]]\t\t\t\t// 2: NUMBER - velocity tolerance - in km/h\n\t];\n\n\tif (not canMove _vehicle) exitWith { false };\t\t// returns false for null as well\n\n\tif (_vehicle isKindOf \"Ship\") then\n\t{\n\t\t// surfaceIsWater getPosASL _vehicle\t\t\t\t\t\t// a beached boat is fine\n\t\tvelocity _vehicle params [\"_velX\", \"_velY\"];\n\t\tsqrt (_velX * _velX + _velY * _velY) < _velocityTolerance\t// only 2D speed matters (think waves)\n\t\t&& {\n\t\t\tgetPosASLW _vehicle select 2 < _altitudeTolerance\t\t\t\t// underwater submarines are OK\n\t\t\t|| { getPos _vehicle select 2 < _altitudeTolerance }\t// beached boat\n\t\t};\n\t}\n\telse\n\t{\n\t\t// over -a- ground and not over ocean\n\t\t(isTouchingGround _vehicle || {\n\t\t\tgetPosASLW _vehicle select 2 >= _altitudeTolerance\t\t// not in water\n\t\t\t&& { getPos _vehicle select 2 < _altitudeTolerance }\n\t\t})\n\t\t&& { vectorMagnitude velocity _vehicle * 3.6 < _velocityTolerance }\n\t}\n};\n\nobjectParent player call _isSafelyParked;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["underwater"],"notes":[{"user":"AgentRev","date":"2014-06-01T01:23:00Z","text":"If you are using this command as a validation method, it should not be the sole thing you are checking for, as the result is often inaccurate.\nFor example, it returns false for some helicopters when landed on the roof of certain buildings, and it always returns false for boats, even if they are beached."},{"user":"Demellion","date":"2016-09-29T08:28:00Z","text":"In addition to previous statement: That behaviour is true, simply because isTouchingGround applied to a player unit (or any unit) is frozen to a last state when unit enters vehicle.\nTo get proper return from this command you should go for units vehicle:\n\n```sqf\n_var = isTouchingGround player;                // unreliable\n_var = isTouchingGround (vehicle player);    // pretty reliable\n```"},{"user":"Pierre MGI","date":"2016-11-10T20:57:00Z","text":"This command returns always true if the falling object is attached to some other object with the attachTo command, like for vehicle air drop with parachute."},{"user":"Gippo","date":"2017-04-26T20:02:00Z","text":"Be aware: it is not reliable on remote objects."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isTurnedOut","operator":null,"title":"isTurnedOut","type":"command","url":"https://community.bistudio.com/wiki/isTurnedOut","revid":319215,"updated":"2022-05-13T09:23:23Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if given unit is turned out, otherwise false. The output changes to true after unit finished turning out, however will change to false almost immediately after unit is ordered to turn in.","syntaxes":[{"syntax":"isTurnedOut unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit on turn(in/out) enabled turret","types":["Object"],"since":null,"text":"unit: Object - unit on turn(in/out) enabled turret"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_commanderOut = isTurnedOut (tank turretUnit [0,0]);\n```","code":["_commanderOut = isTurnedOut (tank turretUnit [0,0]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveOut","moveInDriver","turretUnit"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"isTutHintsEnabled","operator":null,"title":"isTutHintsEnabled","type":"command","url":"https://community.bistudio.com/wiki/isTutHintsEnabled","revid":310279,"updated":"2022-05-05T13:11:24Z","groups":["Difficulty"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the status of TUTORIAL HINTS setting in UI (OPTIONS >> GAME >> GENERAL >> TUTORIAL HINTS).","syntaxes":[{"syntax":"isTutHintsEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str isTutHintsEnabled;\n```","code":["hint str isTutHintsEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isInstructorFigureEnabled","isStreamFriendlyUIEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"isUAVConnectable","operator":null,"title":"isUAVConnectable","type":"command","url":"https://community.bistudio.com/wiki/isUAVConnectable","revid":319168,"updated":"2022-05-13T09:23:18Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if UAV is connectable by AV terminal(s).","syntaxes":[{"syntax":"object isUAVConnectable [uav, checkAllItems]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"uav","type":"Object or Array","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"uav: Object or Array"},{"name":"checkAllItems","type":"Boolean","optional":false,"default":null,"description":"true to check all terminals in unit's inventory, false to only check assigned terminal.","types":["Boolean"],"since":null,"text":"checkAllItems: Boolean - true to check all terminals in unit's inventory, false to only check assigned terminal."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[uav, checkAllItems]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _canConnect = myUnit isUAVConnectable [myUav, true];\n```","code":["private _canConnect = myUnit isUAVConnectable [myUav, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableUAVConnectability","disableUAVConnectability"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"isUAVConnected","operator":null,"title":"isUAVConnected","type":"command","url":"https://community.bistudio.com/wiki/isUAVConnected","revid":378863,"updated":"2026-07-27T13:47:06Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns true if UAV is connected to some terminal. Terminal connection is handled locally, therefore the result of this command will be returned only for the client on which this command is executed.","syntaxes":[{"syntax":"isUAVConnected uav","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"uav","types":["Object"]}}],"examples":[{"text":"```sqf\n_isConnected = isUAVConnected cursorTarget;\n```","code":["_isConnected = isUAVConnected cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showUAVFeed","shownUAVFeed","allUnitsUAV","getConnectedUAV","UAVControl","connectTerminalToUAV"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"isUIContext","operator":null,"title":"isUIContext","type":"command","url":"https://community.bistudio.com/wiki/isUIContext","revid":310464,"updated":"2022-05-06T10:49:54Z","groups":["GUI Control","Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.76"}],"since":{"game":"arma3","name":"Arma 3","version":"1.76"},"arma3_since":"1.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the script originated from some UI control event, for example from \"onButtonDown\" EH. Exists within parent scope and immediate child scopes.","syntaxes":[{"syntax":"isUIContext","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isUIContext) then { hint \"UI control event\" };\n```","code":["if (isUIContext) then { hint \"UI control event\" };"]},{"text":"```sqf\n_button ctrlSetEventHandler [\"ButtonDown\", \"call { diag_log isUIContext }\"]; // outputs true\n```","code":["_button ctrlSetEventHandler [\"ButtonDown\", \"call { diag_log isUIContext }\"]; // outputs true"]},{"text":"```sqf\n_button ctrlSetEventHandler [\"ButtonDown\", \"0 spawn { diag_log isUIContext }\"]; // outputs false\n```","code":["_button ctrlSetEventHandler [\"ButtonDown\", \"0 spawn { diag_log isUIContext }\"]; // outputs false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canSuspend","isRemoteExecuted","isRemoteExecutedJIP","isGamePaused","isGameFocused","serverCommand"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Program Flow","Introduced with Arma 3 version 1.76","Scripting Commands"]},{"name":"isUniformAllowed","operator":null,"title":"isUniformAllowed","type":"command","url":"https://community.bistudio.com/wiki/isUniformAllowed","revid":319160,"updated":"2022-05-13T09:23:17Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check whether given uniform can be dressed by target soldier.","syntaxes":[{"syntax":"unit isUniformAllowed type","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_canUse = _unit isUniformAllowed \"U_B_CombatUniform_mcam\";\n```","code":["_canUse = _unit isUniformAllowed \"U_B_CombatUniform_mcam\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUniform","forceAddUniform","removeUniform","uniform"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"isUsingAISteeringComponent","operator":null,"title":"isUsingAISteeringComponent","type":"command","url":"https://community.bistudio.com/wiki/isUsingAISteeringComponent","revid":369751,"updated":"2024-10-08T15:08:54Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether the AI steering component setting is enabled globally.","syntaxes":[{"syntax":"isUsingAISteeringComponent","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isUsingAISteeringComponent) then\n{\n    useAISteeringComponent false;\n};\n```","code":["if (isUsingAISteeringComponent) then\n{\n\tuseAISteeringComponent false;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["useAISteeringComponent","isAISteeringComponentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"isVehicleCargo","operator":null,"title":"isVehicleCargo","type":"command","url":"https://community.bistudio.com/wiki/isVehicleCargo","revid":349517,"updated":"2023-11-08T17:15:53Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Despite a misleading name, returns the vehicle that is transporting given vehicle in cargo. If the given vehicle is not in vehicle cargo, objNull is returned.","syntaxes":[{"syntax":"isVehicleCargo cargo","since":null,"effect":null,"exec":null,"params":[{"name":"cargo","type":"Object","optional":false,"default":null,"description":"vehicle in cargo","types":["Object"],"since":null,"text":"cargo: Object - vehicle in cargo"}],"returns":{"type":"Object","types":["Object"],"description":"transporting vehicle","text":"Object - transporting vehicle"},"form":"unary","operator":null,"left":null,"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"Blackfish with given variable name blackfish, with a vehicle inside called quad\n\n```sqf\n_transportingVehicle = isVehicleCargo quad; //returns blackfish\n```","code":["_transportingVehicle = isVehicleCargo quad; //returns blackfish"]},{"text":"Vehicle called quad that is not being transported as cargo\n\n```sqf\n_transportingVehicle = isVehicleCargo quad; //returns objNull\n```","code":["_transportingVehicle = isVehicleCargo quad; //returns objNull"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle in Vehicle Transport","canVehicleCargo","setVehicleCargo","enableVehicleCargo","getVehicleCargo","vehicleCargoEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"isVehicleRadarOn","operator":null,"title":"isVehicleRadarOn","type":"command","url":"https://community.bistudio.com/wiki/isVehicleRadarOn","revid":310732,"updated":"2022-05-07T20:04:21Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if vehicle has active sensors on.","syntaxes":[{"syntax":"isVehicleRadarOn vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle on which check is performed","types":["Object"],"since":null,"text":"vehicle: Object - vehicle on which check is performed"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nisVehicleRadarOn vehicle player; // returns true if radar is turned on\n```","code":["isVehicleRadarOn vehicle player; // returns true if radar is turned on"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"isVehicleSensorEnabled","operator":null,"title":"isVehicleSensorEnabled","type":"command","url":"https://community.bistudio.com/wiki/isVehicleSensorEnabled","revid":363162,"updated":"2024-03-24T17:32:35Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns class name (to identify list based on component name) and info if given sensor is enabled.","syntaxes":[{"syntax":"vehicle isVehicleSensorEnabled componentName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"componentName","type":"String","optional":false,"default":null,"description":"the component's name (can either be it is \"real name\" or it is className)","types":["String"],"since":null,"text":"componentName : String - the component's name (can either be it is \"real name\" or it is className)"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"componentName","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player isVehicleSensorEnabled \"PassiveRadarSensorComponent\"; // [[\"PassiveRadarSensorComponent\", true]]\n```","code":["vehicle player isVehicleSensorEnabled \"PassiveRadarSensorComponent\"; // [[\"PassiveRadarSensorComponent\", true]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["listVehicleSensors","enableVehicleSensor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"isWalking","operator":null,"title":"isWalking","type":"command","url":"https://community.bistudio.com/wiki/isWalking","revid":364111,"updated":"2024-05-04T22:02:54Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if walk is **toggled** (default <kbd>W</kbd>+<kbd>S</kbd> in Arma 3).\n\n> [!NOTE]\n> This command can still return true when the unit is sprinting or stopped; it only returns the **toggle** value of walking, not if the unit is walking right now.","syntaxes":[{"syntax":"isWalking unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_bool = isWalking player;\n```","code":["_bool = isWalking player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWalk","isForcedWalk","forceSpeed","getSpeed"],"notes":[{"user":"Benargee","date":"2015-03-08T21:03:00Z","text":"To expand on the limited description, this command doesn't necessarily say whether or not the unit is currently walking. All it says is that walking is toggled on or off.\nThis command can still return true when the unit is sprinting. When walking is toggled on, the unit will return to walking pace when not sprinting.\nWhen walking is toggled off, the unit will return to jogging pace when not sprinting. This command is not intended to gauge a units current movement speed."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"isWeaponDeployed","operator":null,"title":"isWeaponDeployed","type":"command","url":"https://community.bistudio.com/wiki/isWeaponDeployed","revid":321095,"updated":"2022-05-13T13:54:06Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if weapon is currently deployed.","syntaxes":[{"syntax":"isWeaponDeployed unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"isWeaponDeployed [unit, onGround]","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"onGround","type":"Boolean","optional":true,"default":null,"description":"true to check if deployed on ground, false to check if deployed on object. Omitted - same as main syntax.","types":["Boolean"],"since":null,"text":"onGround: Boolean - (Optional) true to check if deployed on ground, false to check if deployed on object. Omitted - same as main syntax."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, onGround]","types":["Array"]}}],"examples":[{"text":"```sqf\n_dep = isWeaponDeployed player;\n```","code":["_dep = isWeaponDeployed player;"]},{"text":"```sqf\n_depOnObj = isWeaponDeployed [player, false];\n```","code":["_depOnObj = isWeaponDeployed [player, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isWeaponRested","canDeployWeapon"],"notes":[{"user":"AgentRev","date":"2015-07-01T16:44:00Z","text":"You can force a unit out of bipod or resting with:\n\n```sqf\n_unit playMove \"\";\n```"},{"user":"Beno 83au","date":"2017-03-04T03:58:00Z","text":"playMove, as well as switchMove, appears to not work when forcing a player out of being deployed. A more reliable method is:\n\n```sqf\n_player setPos (_player modelToWorld [0,0,0]);\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"isWeaponRested","operator":null,"title":"isWeaponRested","type":"command","url":"https://community.bistudio.com/wiki/isWeaponRested","revid":364113,"updated":"2024-05-04T22:05:25Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns true if weapon is currently rested.","syntaxes":[{"syntax":"isWeaponRested unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_rest = isWeaponRested player;\n```","code":["_rest = isWeaponRested player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isWeaponDeployed","canDeployWeapon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"itemCargo","operator":null,"title":"itemCargo","type":"command","url":"https://community.bistudio.com/wiki/itemCargo","revid":376929,"updated":"2025-12-31T20:24:50Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get array with items from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"itemCargo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"[\"ItemType1\",\"ItemType2\",\"ItemType3\"...]","text":"Array of Strings - [\"ItemType1\",\"ItemType2\",\"ItemType3\"...]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str itemCargo vestContainer player;\n```","code":["hint str itemCargo vestContainer player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getItemCargo","addItemCargo","addItemCargoGlobal","clearItemCargo","clearItemCargoGlobal","weaponCargo","magazineCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"items","operator":null,"title":"items","type":"command","url":"https://community.bistudio.com/wiki/items","revid":377151,"updated":"2026-01-01T10:36:00Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an array of names of all unit's stored items, including weapons but excluding magazines (see itemsWithMagazines) and assignedItems.","syntaxes":[{"syntax":"items unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_itemsPlayer = items player;\n```","code":["_itemsPlayer = items player;"]},{"text":"```sqf\nplayer sideChat format [\"%1\", items player];\n```","code":["player sideChat format [\"%1\", items player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["itemsWithMagazines","assignedItems","primaryWeaponItems","secondaryWeaponItems","backpacks"],"notes":[{"user":"comp_uter15776","date":"2022-01-19T16:01:04Z","text":"When using **items** on a player; any equipped primary/secondary weapon/launchers, as well as certain throwables i.e. chemlights, smokes, grenades etc. are *not* returned.\nFor weapons and launchers that aren't stored inside a uniform, backpack or vest use **weaponsItems**. For throwables use **magazines**."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"itemsWithMagazines","operator":null,"title":"itemsWithMagazines","type":"command","url":"https://community.bistudio.com/wiki/itemsWithMagazines","revid":377150,"updated":"2026-01-01T10:35:45Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns combined array including all unit's stored items and all unit's stored magazines and all unit's **stored** weapons. Loaded magazines such as currentMagazine, primaryWeaponMagazine, secondaryWeaponMagazine, handgunMagazine, binocularMagazine as well as assignedItems are excluded.","syntaxes":[{"syntax":"itemsWithMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _res1 = itemsWithMagazines player;\n// ... is essentially the same as ...\nprivate _res2 = items player + magazines player;\n```\n\nExample result:\n\n```sqf\n[\n    \"FirstAidKit\",            //item\n    \"30Rnd_65x39_caseless_mag\",    //magazine\n    \"16Rnd_9x21_Mag\",        //magazine\n    \"Chemlight_green\",        //magazine\n    \"HandGrenade\",            //magazine\n    \"ToolKit\",                //item\n    \"MineDetector\"            //item\n]\n```","code":["private _res1 = itemsWithMagazines player;\n// ... is essentially the same as ...\nprivate _res2 = items player + magazines player;","[\n\t\"FirstAidKit\",\t\t\t//item\n\t\"30Rnd_65x39_caseless_mag\",\t//magazine\n\t\"16Rnd_9x21_Mag\",\t\t//magazine\n\t\"Chemlight_green\",\t\t//magazine\n\t\"HandGrenade\",\t\t\t//magazine\n\t\"ToolKit\",\t\t\t\t//item\n\t\"MineDetector\"\t\t\t//item\n]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["items","removeAllItemsWithMagazines","backpacks"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"join","operator":null,"title":"join","type":"command","url":"https://community.bistudio.com/wiki/join","revid":377820,"updated":"2026-01-03T04:19:29Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"| Maximum number of<br>units per group |  |\n|---|---|\n| Operation Flashpoint | 12 |\n| Later titles | 10000+ |\n\nJoins units into a given Group.\n\nTo make a unit leave its current group, join it into grpNull (e.g. `[MyUnit] join grpNull`) - but beware: A new group is created for the leaving unit; this could result in the number of groups growing out of control.","syntaxes":[{"syntax":"unitArray join group","since":null,"effect":null,"exec":null,"params":[{"name":"unitArray","type":"Array of Objects","optional":false,"default":null,"description":"units to join group","types":["Array","Objects"],"since":null,"text":"unitArray: Array of Objects - units to join group"},{"name":"group","type":"Group or Object","optional":false,"default":null,"description":null,"types":["Group","Object"],"since":null,"text":"group: Group or Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitArray","types":["Array","Objects"]},"right":{"text":"group","types":["Group","Object"]}}],"examples":[{"text":"```sqf\n[_unitOne, _unitTwo] join player;\n```","code":["[_unitOne, _unitTwo] join player;"]},{"text":"```sqf\n[_unitOne, _unitTwo] join (group player);\n```","code":["[_unitOne, _unitTwo] join (group player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["joinAs","joinAsSilent","joinSilent","group","leader","doFollow"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"joinAs","operator":null,"title":"joinAs","type":"command","url":"https://community.bistudio.com/wiki/joinAs","revid":330016,"updated":"2022-08-15T14:38:07Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Joins the unit to the given group, if position id is available, this one is used.","syntaxes":[{"syntax":"unit joinAs [group, id]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[group, id]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer joinAs [_group, 4];\n```","code":["player joinAs [_group, 4];"]},{"text":"To get the position id:\n\n```sqf\ngetUnitPositionId = {\n    private [\"_vvn\", \"_str\"];\n    _vvn = vehicleVarName _this;\n    _this setVehicleVarName \"\";\n    _str = str _this;\n    _this setVehicleVarName _vvn;\n    parseNumber (_str select [(_str find \":\") + 1])\n};\nplayer joinAs [createGroup west, 5];\n_id = player call getUnitPositionId;\nhint str _id; // 5\n```","code":["getUnitPositionId = {\n\tprivate [\"_vvn\", \"_str\"];\n\t_vvn = vehicleVarName _this;\n\t_this setVehicleVarName \"\";\n\t_str = str _this;\n\t_this setVehicleVarName _vvn;\n\tparseNumber (_str select [(_str find \":\") + 1])\n};\nplayer joinAs [createGroup west, 5];\n_id = player call getUnitPositionId;\nhint str _id; // 5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["join","joinAsSilent","joinSilent","group"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"joinAsSilent","operator":null,"title":"joinAsSilent","type":"command","url":"https://community.bistudio.com/wiki/joinAsSilent","revid":330017,"updated":"2022-08-15T14:39:44Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Joins the unit to the given group, if position id is available, this one is used. Avoid any radio communication related to joining.","syntaxes":[{"syntax":"unit joinAsSilent [group, id]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[group, id]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer joinAsSilent [_group, 4];\n```","code":["player joinAsSilent [_group, 4];"]},{"text":"To get the position id:\n\n```sqf\ngetUnitPositionId = {\n    private [\"_vvn\", \"_str\"];\n    _vvn = vehicleVarName _this;\n    _this setVehicleVarName \"\";\n    _str = str _this;\n    _this setVehicleVarName _vvn;\n    parseNumber (_str select [(_str find \":\") + 1])\n};\nplayer joinAsSilent [createGroup west, 5];\n_id = player call getUnitPositionId;\nhint str _id; // 5\n```","code":["getUnitPositionId = {\n\tprivate [\"_vvn\", \"_str\"];\n\t_vvn = vehicleVarName _this;\n\t_this setVehicleVarName \"\";\n\t_str = str _this;\n\t_this setVehicleVarName _vvn;\n\tparseNumber (_str select [(_str find \":\") + 1])\n};\nplayer joinAsSilent [createGroup west, 5];\n_id = player call getUnitPositionId;\nhint str _id; // 5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["join","joinAs","joinSilent"],"notes":[{"user":"Mach1723","date":"2010-12-30T04:41:00Z","text":"I have not done a thorough test but this function doesn't seem to work for Civilians, use joinSilent instead."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"joinSilent","operator":null,"title":"joinSilent","type":"command","url":"https://community.bistudio.com/wiki/joinSilent","revid":377895,"updated":"2026-01-05T17:43:24Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.06"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.06"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Join all units in the array to given group silently (without radio message). To have a group member leave a group, join him with the grpNull group (e.g. `[guy1] joinSilent grpNull`), but **beware**, as brand new group is created for the leaving unit and this could result in the number of groups in a mission growing out of control.","syntaxes":[{"syntax":"unitArray joinSilent group","since":null,"effect":null,"exec":null,"params":[{"name":"unitArray","type":"Array of Objects","optional":false,"default":null,"description":"units to join group","types":["Array","Object"],"since":null,"text":"unitArray: Array of Objects - units to join group"},{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitArray","types":["Array","Object"]},"right":{"text":"group","types":["Object","Group"]}}],"examples":[{"text":"```sqf\n[_unitOne, _unitTwo] joinSilent (group player);\n```","code":["[_unitOne, _unitTwo] joinSilent (group player);"]},{"text":"```sqf\n[_unitOne, _unitTwo] joinSilent player;\n```","code":["[_unitOne, _unitTwo] joinSilent player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["join","joinAs","joinAsSilent","group","leader","doFollow"],"notes":[{"user":"Leopard20","date":"2022-02-17T12:22:29Z","text":"If the group is the same as the current group, the command will act similar to `Return To Formation` command. It is more strong than doFollow (doFollow doesn't work with player-issued commands, i.e via the commanding menu keys):\n\n```sqf\n[_unit] joinSilent group _unit; // return to formation\n```\n\nNote that the group must have **at least 2 units**, and not all units should be joined at once, otherwise the group will temporarily become empty and all its waypoints **will be lost**!"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Armed Assault version 1.06","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"joinString","operator":null,"title":"joinString","type":"command","url":"https://community.bistudio.com/wiki/joinString","revid":377091,"updated":"2026-01-01T09:48:22Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Joins *array* into String with provided *separator*. Array can be of mixed types, all elements will be converted to String prior to joining, but the fastest operation is on the array of Strings.","syntaxes":[{"syntax":"array joinString separator","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"separator","type":"String","optional":false,"default":null,"description":"separator used to join array elements.","types":["String"],"since":null,"text":"separator: String - separator used to join array elements."}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"separator","types":["String"]}}],"examples":[{"text":"```sqf\n_str = \"- This, is a sample string.\" splitString \"-,. \"; // [\"This\",\"is\",\"a\",\"sample\",\"string\"]\n_str joinString \" \"; // \"This is a sample string\"\n```","code":["_str = \"- This, is a sample string.\" splitString \"-,. \"; // [\"This\",\"is\",\"a\",\"sample\",\"string\"]\n_str joinString \" \"; // \"This is a sample string\""]},{"text":"```sqf\n[\"This\",\"is\",\"sparta\"] joinString \" ~ \"; // \"This ~ is ~ sparta\"\n```","code":["[\"This\",\"is\",\"sparta\"] joinString \" ~ \"; // \"This ~ is ~ sparta\""]},{"text":"```sqf\n[\"1\",2,text \"3\"] joinString \"\"; // \"123\"\n```","code":["[\"1\",2,text \"3\"] joinString \"\"; // \"123\""]},{"text":"```sqf\n\"Japa is the best!\" splitString \"\" joinString \" \"; // \"J a p a   i s   t h e   b e s t !\"\n```","code":["\"Japa is the best!\" splitString \"\" joinString \" \"; // \"J a p a   i s   t h e   b e s t !\""]},{"text":"Remove all \\r\\n from file:\n\n```sqf\nloadFile \"somefile.txt\" splitString toString [13,10] joinString \" \"\n```","code":["loadFile \"somefile.txt\" splitString toString [13,10] joinString \" \""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["splitString","set","resize","reverse","select","in","find","toArray","forEach","count","deleteAt","deleteRange","append","sort","param","params","arrayIntersect","toString","endl"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"kbAddDatabase","operator":null,"title":"kbAddDatabase","type":"command","url":"https://community.bistudio.com/wiki/kbAddDatabase","revid":322954,"updated":"2022-06-28T21:42:49Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Register knowledge base database to given person. See Conversations for more details.\n\n> [!IMPORTANT]\n> This command is no longer available in Arma 2 and Arma 3.","syntaxes":[{"syntax":"person kbAddDatabase fileName","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"fileName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fileName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\n_hasBeenAdded = _unit kbAddDatabase \"chat.txt\";\n```","code":["_hasBeenAdded = _unit kbAddDatabase \"chat.txt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbTell","kbWasSaid","kbReact","kbRemoveTopic","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"kbAddDatabaseTargets","operator":null,"title":"kbAddDatabaseTargets","type":"command","url":"https://community.bistudio.com/wiki/kbAddDatabaseTargets","revid":322928,"updated":"2022-06-28T21:42:40Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Register target list knowledge base database to given person. See Conversations for more details.\n\n> [!IMPORTANT]\n> This command is no longer available in Arma 2 and Arma 3.","syntaxes":[{"syntax":"person kbAddDatabaseTargets fileName","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"fileName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fileName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\n_hasBeenAdded = _unit kbAddDatabaseTargets \"chat.txt\";\n```","code":["_hasBeenAdded = _unit kbAddDatabaseTargets \"chat.txt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbTell","kbWasSaid","kbReact","kbRemoveTopic","kbAddDatabase","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"kbAddTopic","operator":null,"title":"kbAddTopic","type":"command","url":"https://community.bistudio.com/wiki/kbAddTopic","revid":353355,"updated":"2024-03-15T17:11:55Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Register conversation topic to given person. See Conversations for more details.\n\n> [!NOTE]\n> Only the speaker(s) need to have the topic added.","syntaxes":[{"syntax":"person kbAddTopic [topicName, conversationFile, fsmFile, eventHandler]","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"topicName","type":"String","optional":false,"default":null,"description":"the topic id for further reference","types":["String"],"since":null,"text":"topicName: String - the topic id for further reference"},{"name":"conversationFile","type":"String","optional":false,"default":null,"description":".bikb file path","types":["String"],"since":null,"text":"conversationFile: String - .bikb file path"},{"name":"fsmFile","type":"String","optional":true,"default":null,"description":".fsm file path. Receives the following parameters:\n- **_sentenceId:** the sentence as defined in the .bikb file\n- **_topic:** TopicName registered via kbAddTopic\n- **_this:** the person that was talked to (receiver)\n- **_from:** the person that talked to the receiver and triggered the script","types":["String"],"since":null,"text":"fsmFile: String - (Optional) .fsm file path. Receives the following parameters:\n- **_sentenceId:** the sentence as defined in the .bikb file\n- **_topic:** TopicName registered via kbAddTopic\n- **_this:** the person that was talked to (receiver)\n- **_from:** the person that talked to the receiver and triggered the script"},{"name":"eventHandler","type":"Code or String","optional":true,"default":null,"description":"code to execute - given String will be compiled. This is **not** an sqf file path.\n\nParameters: identical to *fsmFile* - see above.","types":["Code","String"],"since":null,"text":"eventHandler: Code or String - (Optional) code to execute - given String will be compiled. This is **not** an sqf file path.\n\nParameters: identical to *fsmFile* - see above."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"[topicName, conversationFile, fsmFile, eventHandler]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer kbAddTopic [\"myTest\", \"myTest.bikb\", \"myTest.fsm\", compile preprocessFileLineNumbers \"myTest.sqf\"];\n```","code":["player kbAddTopic [\"myTest\", \"myTest.bikb\", \"myTest.fsm\", compile preprocessFileLineNumbers \"myTest.sqf\"];"]},{"text":"```sqf\nplayer kbAddTopic [\"itsGettingWarm\", \"weatherTalk.bikb\"];\n```","code":["player kbAddTopic [\"itsGettingWarm\", \"weatherTalk.bikb\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbHasTopic","kbTell","kbWasSaid","kbReact","kbRemoveTopic","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"kbHasTopic","operator":null,"title":"kbHasTopic","type":"command","url":"https://community.bistudio.com/wiki/kbHasTopic","revid":319151,"updated":"2022-05-13T09:23:15Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Check if conversation topic was registered to given person. See Conversations for more details.","syntaxes":[{"syntax":"person kbHasTopic topicName","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"topicName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"topicName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"topicName","types":["String"]}}],"examples":[{"text":"```sqf\n_obiHasTopic = player kbHasTopic \"helloThereGeneralK\";\n```","code":["_obiHasTopic = player kbHasTopic \"helloThereGeneralK\";"]},{"text":"```sqf\nif (player kbHasTopic \"dontShoot\") then { player kbRemoveTopic \"dontShoot\"; };\n```","code":["if (player kbHasTopic \"dontShoot\") then { player kbRemoveTopic \"dontShoot\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbTell","kbReact","kbRemoveTopic","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"kbReact","operator":null,"title":"kbReact","type":"command","url":"https://community.bistudio.com/wiki/kbReact","revid":351315,"updated":"2023-11-27T04:58:35Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Pass a non-verbal communication to the receiver. This command does **as if** the sentence was said and triggers the reaction scripts (AI FSM or player's conversation EH). See Conversations for more details.","syntaxes":[{"syntax":"person kbReact [receiver, topicName, sentenceID, argumentArray1, argumentArray2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"receiver","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"receiver: Object"},{"name":"topicName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"topicName: String"},{"name":"sentenceID","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"sentenceID: String"},{"name":"argumentArrayN","type":"Array","optional":true,"default":null,"description":"in format [argumentName, argumentValue, argumentText, argumentSpeech]:\n- argumentName: String\n- argumentValue: Code\n- argumentText: String\n- argumentSpeech: Array of Strings - each string is an already defined word in config.","types":["Array"],"since":null,"text":"argumentArrayN: Array - (Optional) in format [argumentName, argumentValue, argumentText, argumentSpeech]:\n- argumentName: String\n- argumentValue: Code\n- argumentText: String\n- argumentSpeech: Array of Strings - each string is an already defined word in config."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"[receiver, topicName, sentenceID, argumentArray1, argumentArray2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n// will trigger AS IF unit1 said the sentence (via kbTell)\n// unit2's FSM will react accordingly.\nunit1 kbReact [unit2, \"topicName\", \"speech1\"];\n```","code":["// will trigger AS IF unit1 said the sentence (via kbTell)\n// unit2's FSM will react accordingly.\nunit1 kbReact [unit2, \"topicName\", \"speech1\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbTell","kbWasSaid","kbRemoveTopic","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"kbRemoveTopic","operator":null,"title":"kbRemoveTopic","type":"command","url":"https://community.bistudio.com/wiki/kbRemoveTopic","revid":319147,"updated":"2022-05-13T09:23:16Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unregister conversation topic from given person. See Conversations for more details.","syntaxes":[{"syntax":"person kbRemoveTopic topicName","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"topicName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"topicName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"topicName","types":["String"]}}],"examples":[{"text":"```sqf\n_unit1 kbRemoveTopic \"howsTheWeather\";\n```","code":["_unit1 kbRemoveTopic \"howsTheWeather\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbTell","kbReact","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"kbTell","operator":null,"title":"kbTell","type":"command","url":"https://community.bistudio.com/wiki/kbTell","revid":369397,"updated":"2024-09-03T18:43:19Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Make the person tell to the receiver the sentence. See Conversations for more details.","syntaxes":[{"syntax":"person kbTell [receiver, topicName, sentenceClass, argumentArray1, argumentArray2, ..., forceRadio]","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"receiver","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"receiver: Object"},{"name":"topicName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"topicName: String"},{"name":"sentenceClass","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"sentenceClass: String"},{"name":"argumentArrayN","type":"Array","optional":true,"default":null,"description":"format [argumentName, argumentValue, argumentText, argumentSpeech]:\n- argumentName: String\n- argumentValue: Code\n- argumentText: String\n- argumentSpeech: Array of Strings - each string is an already defined word in config.","types":["Array"],"since":null,"text":"argumentArrayN: Array - (Optional) format [argumentName, argumentValue, argumentText, argumentSpeech]:\n- argumentName: String\n- argumentValue: Code\n- argumentText: String\n- argumentSpeech: Array of Strings - each string is an already defined word in config."},{"name":"forceRadio","type":"Boolean, Number or String (last value of the array)","optional":true,"default":null,"description":"Boolean true/false to force use of radio\n- Number 1-10 to force use of custom radio channel\n- String name of radio channel to use, from: 'GLOBAL', 'SIDE', 'GROUP', 'VEHICLE', 'DIRECT', 'COMMAND'","types":["Boolean","Number","String"],"since":null,"text":"forceRadio: Boolean, Number or String (*last value of the array*) - (Optional)\n- Boolean true/false to force use of radio\n- Number 1-10 to force use of custom radio channel\n- String name of radio channel to use, from: 'GLOBAL', 'SIDE', 'GROUP', 'VEHICLE', 'DIRECT', 'COMMAND'"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"[receiver, topicName, sentenceClass, argumentArray1, argumentArray2, ..., forceRadio]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer kbTell [BIS_HQ, \"myTopic\", \"playerSentence1\"];\n```","code":["player kbTell [BIS_HQ, \"myTopic\", \"playerSentence1\"];"]},{"text":"```sqf\nplayer kbTell [\n    BIS_HQ,                                        // to\n    \"Airstrike\",                                // topic\n    \"AirstrikeRequest\",                            // sentence\n    [\"Team\", {}, \"Anvil\", [\"Anvil\"]],            // argument 1\n    [\"Location\", {}, \"Strelka\", [\"Strelka\"]],    // argument 2\n    true];                                        // use radio\n```\n\nin given .bikb:\n\n```cpp\nclass AirstrikeRequest \n{\n    text = \"%team requesting close air support at grid %location \";\n    speech[] = { %Team, RequestingCloseAirSupportAtGrid, %Location };\n    class Arguments \n    {\n        class Team        { type = \"simple\"; };\n        class Location    { type = \"simple\"; };\n    };\n};\n```","code":["player kbTell [\n\tBIS_HQ,\t\t\t\t\t\t\t\t\t\t// to\n\t\"Airstrike\",\t\t\t\t\t\t\t\t// topic\n\t\"AirstrikeRequest\",\t\t\t\t\t\t\t// sentence\n\t[\"Team\", {}, \"Anvil\", [\"Anvil\"]],\t\t\t// argument 1\n\t[\"Location\", {}, \"Strelka\", [\"Strelka\"]],\t// argument 2\n\ttrue];\t\t\t\t\t\t\t\t\t\t// use radio"]},{"text":"```sqf\nplayer kbTell [\n    BIS_HQ,                                        // to\n    \"Airstrike\",                                // topic\n    \"AirstrikeRequest\",                            // sentence\n    [\"argumentName\", argumentValue],            // argument 1\n    true];                                        // use radio\n```","code":["player kbTell [\n\tBIS_HQ,\t\t\t\t\t\t\t\t\t\t// to\n\t\"Airstrike\",\t\t\t\t\t\t\t\t// topic\n\t\"AirstrikeRequest\",\t\t\t\t\t\t\t// sentence\n\t[\"argumentName\", argumentValue],\t\t\t// argument 1\n\ttrue];\t\t\t\t\t\t\t\t\t\t// use radio"]}],"multiplayer":null,"problems":"Two units cannot talk on the same channel at the same time, this can lead to weird effects for non-local listeners; make sure not to use the same channel at the same time in multiplayer. Custom channels are considered as one channel for this matter.","aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbReact","kbRemoveTopic","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"kbWasSaid","operator":null,"title":"kbWasSaid","type":"command","url":"https://community.bistudio.com/wiki/kbWasSaid","revid":330038,"updated":"2022-08-15T15:23:07Z","groups":["Conversations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if given item was said by person to someone. See Conversations for more details.","syntaxes":[{"syntax":"person kbWasSaid [receiver, topic, sentenceID, maxAge]","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"who said the item","types":["Object"],"since":null,"text":"person: Object - who said the item"},{"name":"receiver","type":"Object","optional":false,"default":null,"description":"receiver of the sentence","types":["Object"],"since":null,"text":"receiver: Object - receiver of the sentence"},{"name":"topic","type":"String","optional":false,"default":null,"description":"name of the topic used in kbAddTopic","types":["String"],"since":null,"text":"topic: String - name of the topic used in kbAddTopic"},{"name":"sentenceID","type":"String","optional":false,"default":null,"description":"id of sentence that we want to check","types":["String"],"since":null,"text":"sentenceID: String - id of sentence that we want to check"},{"name":"maxAge","type":"Number","optional":false,"default":null,"description":"time in seconds. kbWasSaid will check whether the sentence was said in last **max. age** seconds","types":["Number"],"since":null,"text":"maxAge: Number - time in seconds. kbWasSaid will check whether the sentence was said in last **max. age** seconds"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"[receiver, topic, sentenceID, maxAge]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer kbWasSaid [otherUnit, \"myTopic\", \"mySentenceID\", 3];\n```","code":["player kbWasSaid [otherUnit, \"myTopic\", \"mySentenceID\", 3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Conversations","kbAddTopic","kbHasTopic","kbTell","kbReact","kbRemoveTopic","kbAddDatabase","kbAddDatabaseTargets","FSM","FSM Editor"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Conversations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"keyImage","operator":null,"title":"keyImage","type":"command","url":"https://community.bistudio.com/wiki/keyImage","revid":338908,"updated":"2023-04-17T14:33:23Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a structured text, containing an image or name (if no image is found) of the button, on the keyboard, mouse or joystick, with the given code.","syntaxes":[{"syntax":"keyImage dikCode","since":null,"effect":null,"exec":null,"params":[{"name":"dikCode","type":"Number or Arma 3 v2.08 String","optional":false,"default":null,"description":null,"types":["Number","String"],"since":null,"text":"dikCode: Number or Arma 3 v2.08 String"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"dikCode","types":["Number","String"]}}],"examples":[{"text":"```sqf\n_image = keyImage 28; // result is \"Enter\"\n```","code":["_image = keyImage 28; // result is \"Enter\""]},{"text":"From Arma 3 v2.08:\n\n```sqf\n_image = keyImage \"-1660944350\"; // result is \"Right Ctrl+G\"\n```","code":["_image = keyImage \"-1660944350\"; // result is \"Right Ctrl+G\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["keyName","actionKeys","actionKeysImages","actionKeysNames","actionKeysNamesArray","DIK KeyCodes"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"keyName","operator":null,"title":"keyName","type":"command","url":"https://community.bistudio.com/wiki/keyName","revid":338910,"updated":"2023-04-17T14:36:36Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of a button with extra quotation marks (on the keyboard, mouse or joystick) with the given code.","syntaxes":[{"syntax":"keyName dikCode","since":null,"effect":null,"exec":null,"params":[{"name":"dikCode","type":"Number or Arma 3 v2.08 String","optional":false,"default":null,"description":null,"types":["Number","String"],"since":null,"text":"dikCode: Number or Arma 3 v2.08 String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"dikCode","types":["Number","String"]}}],"examples":[{"text":"```sqf\n_name = keyName 28; // result is \"\"\"Enter\"\"\"\n```","code":["_name = keyName 28; // result is \"\"\"Enter\"\"\""]},{"text":"From Arma 3 v2.08:\n\n```sqf\nprivate _name = keyName \"-1660944350\"; // result is \"\"\"Right Ctrl+G\"\"\"\n```","code":["private _name = keyName \"-1660944350\"; // result is \"\"\"Right Ctrl+G\"\"\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["keyImage","actionKeys","actionKeysImages","actionKeysNames","actionKeysNamesArray","DIK KeyCodes"],"notes":[{"user":"POLPOX","date":"2020-04-28T15:10:00Z","text":"The return value is different per keyboard/IME settings."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"keys","operator":null,"title":"keys","type":"command","url":"https://community.bistudio.com/wiki/keys","revid":377092,"updated":"2026-01-01T09:48:45Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Retrieves a list of all keys in a HashMap.","syntaxes":[{"syntax":"keys hashMap","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap : HashMap"}],"returns":{"type":"Array of Anything","types":["Array","Anything"],"description":"array of all keys in the HashMap","text":"Array of Anything - array of all keys in the HashMap"},"form":"unary","operator":null,"left":null,"right":{"text":"hashMap","types":["HashMap"]}}],"examples":[{"text":"```sqf\nkeys _myHashMap;\n```","code":["keys _myHashMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["HashMap","values","toArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"knowsAbout","operator":null,"title":"knowsAbout","type":"command","url":"https://community.bistudio.com/wiki/knowsAbout","revid":347557,"updated":"2023-09-28T09:45:05Z","groups":["Object Manipulation","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Checks if a group or a side knows about target.\n- Enemy knowledge is instantly shared among the group units\n- Units in the same group always perfectly know about each others\n- AI knowledge cannot check beyond current viewDistance and it resets to zero as soon as the target's distance is over it\nNote: neither fog nor daylight affect this behaviour\n- Losing sight of a target for more than 120 seconds resets its knowsAbout to zero as well\n- **Magic number** is the value that must be reached for a unit to shoot at an enemy (used by \"Detected by\" triggers as well):\n\n|  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|\n| Game | Operation Flashpoint v1.46 | Operation Flashpoint: Resistance v1.96 | Armed Assault v1.18 | Arma 2 v1.11 | Arma 2: Operation Arrowhead v1.62 | Arma 3 v1.82 |\n| Magic value | 0.7 | 0.105 | ? | ? | ? | ? |","syntaxes":[{"syntax":"who knowsAbout target","since":null,"effect":null,"exec":null,"params":[{"name":"who","type":"Object, Group or Side","optional":false,"default":null,"description":"if a unit, unit's group is considered; if a vehicle, vehicle commander's group is used.","types":["Object","Group","Side"],"since":null,"text":"who: Object, Group or Side - if a unit, unit's group is considered; if a vehicle, vehicle commander's group is used."},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Number","types":["Number"],"description":"in range of 0..4, where 4 is maximum knowledge.","text":"Number - in range of 0..4, where 4 is maximum knowledge."},"form":"binary","operator":null,"left":{"text":"who","types":["Object","Group","Side"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\n_knowledge = player knowsAbout _target;\n```","code":["_knowledge = player knowsAbout _target;"]},{"text":"```sqf\n_knowledge = (group player) knowsAbout _target;\n```","code":["_knowledge = (group player) knowsAbout _target;"]},{"text":"```sqf\n_knowledge = (side player) knowsAbout _target;\n```","code":["_knowledge = (side player) knowsAbout _target;"]}],"multiplayer":"*who* **must** be local, while *target* can be remote.","problems":null,"aliases":[],"see_also":["nearTargets","reveal","getHideFrom","targetKnowledge","targetsAggregate","targetsQuery","forgetTarget"],"notes":[{"user":"Hardrock","date":"2006-08-04T10:55:00Z","text":"Operation Flashpoint: Resistance v1.91\n- As soon as An AI unit gets hit with a bullet his knowsAbout level for the unit that shot him will instantly jump to 1.5, even if the shooter is 1000m away.\nVice versa is also true. If An AI soldier's knowsAbout level for an enemy is 0.7 and the soldier fires and hits the enemy, his knowsAbout level about the enemy will instantly jump to 1.5.\n- Some editors have found, whilst using this command over the years, that the following characteristics have cropped up:\n  - AI enemies have a very limited amount of peripheral vision, it is not nearly as good as a human player's. A target must be in front of the unit for him to be noticed, so if you sprint right behind an enemy, this value doesn't increase.\n  - Depending on the unit's skill level, it can take a little time for the unit to notice a target. So if you run right past a unit, this value might not increase.\n  - Bushes between the unit and the target seem to have little effect on this value, and trees definitely have no effect. You may be in a forest and can't see the unit, but he can see you."},{"user":"Bdfy","date":"2007-01-16T16:25:00Z","text":"`the magic knowsAbout number is 0.105` It's not that simple. Maybe true for infantry but not all vehicles:\n\nReveal command sets knowsAbout to 1, but planes still won't fire at soldiers on the ground.\nThere's only one known way to pass through this - designate target with another fake infantry unit near the target.\nAs soon as this fake unit see the target knowsAbout lifts up to 2.5-4 and even single enemy soldiers are attacked from the air (of course if plane has suitable munition :))"},{"user":"Kju","date":"2012-06-14T10:01:00Z","text":"According to **Suma**:\n\nAll friendly units within a view distance to each unit [are revealed (to the player? or each friendly?)] on the mission start.\nThe code is half broken, as it does not make the units known, it only sets the \"accuracy\" value for them.\n\nNote: This is not affecting enemy units at all."},{"user":"Helling3r","date":"2013-03-27T23:25:00Z","text":"Arma 2: Operation Arrowhead v1.62 infantry tests:\nIt is still true that the command returns values between 0 (lowest) and 4 (most). Freshly Spotted units will have at least 1.5, slowly decreasing when the target disappeared.\nThe following table shows my test results on a clear day in Takistan using the Vector. Please note that the returned values vary considerably depending on weather and time. Moonlight however seems to not have any considerable effect.\n\n|  |  |  |\n|---|---|---|\n| \\|  \\|  \\|  \\|<br>\\|---\\|---\\|---\\|<br>\\| 12:00, sunlight, clear sky \\| Distance \\| knowsAbout \\|<br>\\| 1530 \\| 1.5 \\|  \\|<br>\\| 1370 \\| 1.5 \\|  \\|<br>\\| 1250 \\| 1.5 \\|  \\|<br>\\| 1135 \\| 1.5 \\|  \\|<br>\\| 1055 \\| 1.52 \\|  \\|<br>\\| 1022 \\| 1.64 \\|  \\|<br>\\| 990 \\| 1.74 \\|  \\|<br>\\| 833 \\| 2.5 \\|  \\|<br>\\| 720 \\| 3.37 \\|  \\|<br>\\| 600 \\| 3.81 \\|  \\|<br>\\| 505 \\| 3.86 \\|  \\|<br>\\| 400 \\| 3.92 \\|  \\|<br>\\| 380 \\| 4 \\|  \\|<br>\\| 365 \\| 4 \\|  \\| | \\|  \\|  \\|  \\|<br>\\|---\\|---\\|---\\|<br>\\| 21:00, bright half moon, clear sky \\| Distance \\| knowsAbout \\|<br>\\| 285 \\| 1.5 \\|  \\|<br>\\| 120 \\| 1.5 \\|  \\|<br>\\| 88 \\| 1.89 \\|  \\|<br>\\| 75 \\| 2.3 \\|  \\|<br>\\| 61 \\| 3.9 \\|  \\| | \\|  \\|  \\|  \\|<br>\\|---\\|---\\|---\\|<br>\\| 23:00, pitch black, clear sky, NVG on \\| Distance \\| knowsAbout \\|<br>\\| 600 \\| 1.5 \\|  \\|<br>\\| 487 \\| 1.5 \\|  \\|<br>\\| 390 \\| 1.5 \\|  \\|<br>\\| 289 \\| 2.22 \\|  \\|<br>\\| 278 \\| 2.4 \\|  \\| |"},{"user":"Lou Montana","date":"2018-06-03T10:46:00Z","text":"Arma 3 v1.82 knowsAbout tests, player moving towards enemy AI, facing each other:\n\n|  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|\n| + Tests executed in VR, default date (2035-05-28), with AI behaviour \"AWARE\" | Daytime | AI equipment | AI skill and rank | player stance and speed | player outfit | first detection distance | first detection value | max detection (4) |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | Standing, running | B_Soldier_F | 245.663 | 0.148076 | 132.863 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | Standing, running | **underwear only**, rifle | 246.815 | 1.19377 | 132.9 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | Standing, running | B_Soldier_F, **no uniform** | 241.885 | 1.24 | 132.56 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | Standing, running | **B_Sniper_F** | 156.715 | 2.95534 | 133.019 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | **Lying down, running** | B_Soldier_F | 105.401 | 4 | 105.401 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | **Crouching, running** | B_Soldier_F | 193.232 | 1.94615 | 134.556 |  |\n| 13:37 | Katiba + ACO (Green) | 0.5 - private | **Standing, sprinting** | B_Soldier_F | 235.001 | 1.3146 | 134.445 |  |\n| 13:37 | Katiba + ACO (Green) | **0.2 - private** | Standing, running | B_Soldier_F | 214 | 0.166763 | 124.553 |  |\n| 13:37 | Katiba + ACO (Green) | **1.0 - private** | Standing, running | B_Soldier_F | 293.065 | 1.11004 | *140.088* |  |\n| 13:37 | Katiba + ACO (Green) | **0.5 - colonel** | Standing, running | B_Soldier_F | 245.641 | 1.20426 | 132.113 |  |\n| 13:37 | **no weapon** | 0.5 - private | Standing, running | B_Soldier_F | 421.959 | 0.283476 | 109.274 |  |\n| 13:37 | **Katiba + LRPS** | 0.5 - private | Standing, running | B_Soldier_F | 244.962 | 4 | 244.962 |  |\n| **20:00** | Katiba + ACO (Green) | 0.5 - private | Standing, running | B_Soldier_F | 132.089 | 0.62443 | 49.4895 |  |\n| **20:00** | **Katiba + ACO (Green), no NVG** | 0.5 - private | Standing, running | B_Soldier_F | 10.6837 | 4 | 10.6837 |  |\n\nCode used (click on \"Expand\" to the right):\n\n```sqf\nplayer allowDamage false;\nplayer enableFatigue false;\n\nplayer setPosATL [0,0,0];\nplayer setDir 0;\nunit setPosATL [0,500,0];\nunit setDir 180;\n\nwaitUntil { speed player > 0 };\n\n[unit, player] spawn {\n    params [\"_unit1\", \"_unit2\"];\n    private _time = time;\n    private _knowsAboutData = [\n        format [\"world = %1\\ndate = %2\\nanim = %3\\nweapon/scope = %4/%5\\nskill/rank = %6/%7\\nplayerType = %8\",\n            worldName,\n            date,\n            animationState player,\n            primaryWeapon _unit1,\n            (_unit1 weaponAccessories primaryWeapon _unit1) select 2,\n            skill _unit1,\n            rank _unit1,\n            typeOf _unit2\n        ]\n    ];\n    private \"_knowsAbout\";\n    private \"_entry\";\n    while { alive _unit1 && alive _unit2 } do\n    {\n        _knowsAbout = _unit1 knowsAbout _unit2;\n        _entry = [_unit1 distance _unit2, _knowsAbout];\n        _knowsAboutData pushBack _entry;\n        systemChat format [\"time: %1 - %2\", round (time - _time), _entry];\n        copyToClipboard str _knowsAboutData;\n        sleep 1;\n    };\n};\n```"},{"user":"ComradeCheekiBreeki","date":"2021-09-01T04:16:29Z","text":"As of at least Arma 3 v2.04, all sides appear to always perfectly know about props (`knowsAbout` of 4) unless they are beyond max view distance. Direction of the observer, distance between observer and object (excluding those which are beyond the max view distance) and amount of obstructions between them do not seem to affect it. However, there is a short ~0.5 second delay after mission start before units perfectly know about props.\n\nIn addition, props appear to always have a `knowsAbout` value of 0 regardless of side or other object checked, including other props."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"land","operator":null,"title":"land","type":"command","url":"https://community.bistudio.com/wiki/land","revid":373721,"updated":"2025-06-23T00:49:43Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Forces a helicopter landing. If there is a helipad nearby, the helicopter will attempt to land on it. VTOL he other hand will just land somewhere. To make helicopter or VTOL land on a specific helipad use landAt.","syntaxes":[{"syntax":"helicopter land mode","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object helicopter or VTOL","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object helicopter or VTOL"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"LAND\" - Complete stop\n- \"GET IN\" - Hovering very low, for another unit to get in\n- \"GET OUT\" - Hovering low, for another unit to get out\n- Arma 2 v1.00 \"NONE\" - Cancel a landing","types":["String"],"since":null,"text":"mode: String - can be one of:\n- \"LAND\" - Complete stop\n- \"GET IN\" - Hovering very low, for another unit to get in\n- \"GET OUT\" - Hovering low, for another unit to get out\n- Arma 2 v1.00 \"NONE\" - Cancel a landing"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopter","types":["Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_cobraOne land \"LAND\";\n```","code":["_cobraOne land \"LAND\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["landAt","allAirports"],"notes":[{"user":"Hardrock","date":"2006-08-04T10:56:00Z","text":"*Notes from before the conversion:*\nHelos will land at the nearest \"H\" or \"Invisible H\", if there is one around (within 500m in Armed Assault)."},{"user":"SNKMAN","date":"2010-09-26T12:02:00Z","text":"To make a helicopter LAND correctly and not hovering over the landing position use unitReady to check if the helicopter already has reached his destination.\nYou can fix a landing bug by using a short delay bevore checking the unitReady command.\n\n```sqf\n_helicopter move getPosATL _destination;\nsleep 3;\nwhile { alive _helicopter && not unitReady _helicopter } do\n{\n    sleep 1;\n};\n\nif (alive _helicopter) then\n{\n    _helicopter land \"LAND\";\n};\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"landAt","operator":null,"title":"landAt","type":"command","url":"https://community.bistudio.com/wiki/landAt","revid":378376,"updated":"2026-04-03T17:00:56Z","groups":["Unit Control","Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Order an AI airplane to land at a given airport. **ID** is the number to identify which map airport you want the airplane to land at. See Arma: Airport IDs for more information. See also land.\n\n> [!NOTE]\n> **Arma 3:** - Arma 3 v1.68 it is possible to also make the airplane land at a dynamic airport object (e.g. aircraft carrier, makeshift runway...) – see #Example 2\n> - Arma 3 v2.18 it is also possible to make a helicopter land at a specific helipad.\n\n> [!NOTE]\n> Since Arma 3 v2.20 landAt command has been extended. Helicopter can now be landed not only on a helipad but also at arbitrary position, provided that it is empty and can accomodate the helicopter. In \"Land\" landing mode the helicopter lands permanently, while in \"GetIn\" and \"GetOut\" landing mode the helicopter performs a short touch down before going to the next waypoint. In order to make helicopter wait, the 'waitTime' param can be used. Landing mode \"None\" cancels both, the landing in progress and waiting in progress.\n>  Waiting time is available with landAt getter variant. When helicopter is landing, the time shown is the set time for wating, however when helicopter is landed, this time start counting down to 0, after which helicopter will take off if it has a waypoint to go to. The AI pilot state can be monitored with getUnitState command. The helicopter has to be local to the machine executing the command. VTOL waiting time is not supported","syntaxes":[{"syntax":"plane landAt ID","since":null,"effect":null,"exec":null,"params":[{"name":"plane","type":"Object","optional":false,"default":null,"description":"a plane","types":["Object"],"since":null,"text":"plane: Object - a plane"},{"name":"ID","type":"Number","optional":false,"default":null,"description":"Airport ID","types":["Number"],"since":null,"text":"ID: Number - Airport ID"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"plane","types":["Object"]},"right":{"text":"ID","types":["Number"]}},{"syntax":"plane landAt airportObject","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"plane","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"plane: Object"},{"name":"airportObject","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"airportObject: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"plane","types":["Object"]},"right":{"text":"airportObject","types":["Object"]}},{"syntax":"heli landAt [position, mode, waitTime, putOnSurface]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"heli","type":"Object","optional":false,"default":null,"description":"Helicopter/VTOL aircraft","types":["Object"],"since":null,"text":"heli: Object - Helicopter/VTOL aircraft"},{"name":"position","type":"Object or Arma 3 v2.20 PositionWorld","optional":false,"default":null,"description":"a helipad object of helipad type (can be an invisible helipad) or PositionWorld to land at.","types":["Object","PositionWorld"],"since":null,"text":"position: Object or Arma 3 v2.20 PositionWorld - a helipad object of helipad type (can be an invisible helipad) or PositionWorld to land at."},{"name":"mode","type":"String","optional":false,"default":null,"description":"one of \"None\", \"Get In\", \"Get Out\", \"Land\" and since Arma 3 v2.20 also \"GetIn\", \"GetOut\".","types":["String"],"since":null,"text":"mode: String - one of \"None\", \"Get In\", \"Get Out\", \"Land\" and since Arma 3 v2.20 also \"GetIn\", \"GetOut\"."},{"name":"waitTime","type":"Number","optional":true,"default":null,"description":"(Helicopter type only) time to wait after touch down in \"GetIn\"/\"GetOut\" mode before taking off to the next waypoint. Default: -1.","types":["Number"],"since":"arma3 2.20","text":"waitTime: Number - (Optional) (Helicopter type only) time to wait after touch down in \"GetIn\"/\"GetOut\" mode before taking off to the next waypoint. Default: -1."},{"name":"putOnSurface","type":"Boolean","optional":true,"default":null,"description":"when true, the given land position will be adjusted to the nearest surface underneath. Default: false.","types":["Boolean"],"since":"arma3 2.20","text":"putOnSurface: Boolean - (Optional) when true, the given land position will be adjusted to the nearest surface underneath. Default: false."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"Returns true if landing command was processed successfully, false if failed.","text":"Boolean - Returns true if landing command was processed successfully, false if failed."},"form":"binary","operator":null,"left":{"text":"heli","types":["Object"]},"right":{"text":"[position, mode, waitTime, putOnSurface]","types":["Array"]}},{"syntax":"landAt heli","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"heli","type":"Object","optional":false,"default":null,"description":"Helicopter/VTOL aircraft","types":["Object"],"since":null,"text":"heli: Object - Helicopter/VTOL aircraft"}],"returns":{"type":"Array with [landMode, landResult, landPosition, waitTime, autopilotState]","types":["Array"],"description":"landMode: String - one of the following: \"None\", \"Land\", \"GetIn\", \"GetOut\" or \"\". - landResult: String - one of the following: \"Found\", \"NotFound\", \"NotReady\" or \"\". - landPosition: PositionWorld - land position or [0,0,0]. - waitTime: Number - (Helicopter type only) before heli is landed - wait time set for \"GetIn\"/\"GetOut\" mode, after heli is landed - remaining time before take off to the next waypoint or -1. - autopilotState: String - one of the following: \"FAR\", \"BRAKE\", \"NEAR\", \"ALIGN\", \"REACHED\", \"LOITER\", \"FOLLOW\" or \"\".","text":"Array with [landMode, landResult, landPosition, waitTime, autopilotState]\n- landMode: String - one of the following: \"None\", \"Land\", \"GetIn\", \"GetOut\" or \"\".\n- landResult: String - one of the following: \"Found\", \"NotFound\", \"NotReady\" or \"\".\n- landPosition: PositionWorld - land position or [0,0,0].\n- waitTime: Number - (Helicopter type only) before heli is landed - wait time set for \"GetIn\"/\"GetOut\" mode, after heli is landed - remaining time before take off to the next waypoint or -1.\n- autopilotState: String - one of the following: \"FAR\", \"BRAKE\", \"NEAR\", \"ALIGN\", \"REACHED\", \"LOITER\", \"FOLLOW\" or \"\"."},"form":"unary","operator":null,"left":null,"right":{"text":"heli","types":["Object"]}}],"examples":[{"text":"```sqf\n_plane1 landAt 1;\n```","code":["_plane1 landAt 1;"]},{"text":"```sqf\n_dynamicAirport1 = \"DynamicAirport_01_F\" createVehicle position player;\n_plane1 landAt _dynamicAirport1;\n```","code":["_dynamicAirport1 = \"DynamicAirport_01_F\" createVehicle position player;\n_plane1 landAt _dynamicAirport1;"]},{"text":"```sqf\n_hpad = \"Land_HelipadEmpty_F\" createVehicle [0,0,0];\n_hpad setPosASL _pos;\nheli landAt [_hpad, \"LAND\"];\n```","code":["_hpad = \"Land_HelipadEmpty_F\" createVehicle [0,0,0];\n_hpad setPosASL _pos;\nheli landAt [_hpad, \"LAND\"];"]},{"text":"```sqf\nheli landAt [getPosWorld player vectorAdd [10,10,0], \"GetIn\", 30];\n```","code":["heli landAt [getPosWorld player vectorAdd [10,10,0], \"GetIn\", 30];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma: Airport IDs","land","setAirportSide","assignToAirport","allAirports"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Command Group: Unit Control","Introduced with Armed Assault version 1.08","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"landResult","operator":null,"title":"landResult","type":"command","url":"https://community.bistudio.com/wiki/landResult","revid":363668,"updated":"2024-04-14T20:18:01Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the result of helicopter landing position searching (performed after the land command).","syntaxes":[{"syntax":"landResult helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"String","types":["String"],"description":"result, can be: - `\"Found\"` - position found - `\"NotFound\"` - position not found - `\"NotReady\"` - position searching is still in progress - `\"\"` - empty string when the provided helicopter is invalid","text":"String - result, can be:\n- `\"Found\"` - position found\n- `\"NotFound\"` - position not found\n- `\"NotReady\"` - position searching is still in progress\n- `\"\"` - empty string when the provided *helicopter* is invalid"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_result = landResult BIS_heli;\n```","code":["_result = landResult BIS_heli;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["land"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"language","operator":null,"title":"language","type":"command","url":"https://community.bistudio.com/wiki/language","revid":365028,"updated":"2024-07-10T19:28:46Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current game language.","syntaxes":[{"syntax":"language","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":"see supported languages for possible values","text":"String - see supported languages for possible values"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_myLanguage = language; // will return \"English\" if game language is set to English\n```","code":["_myLanguage = language; // will return \"English\" if game language is set to English"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Stringtable.xml","getTextRaw","localize","isLocalized","diag_localized","BIS_fnc_localize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"laserTarget","operator":null,"title":"laserTarget","type":"command","url":"https://community.bistudio.com/wiki/laserTarget","revid":377476,"updated":"2026-01-02T06:48:48Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the laser target object created by given unit (vehicle or soldier) when using a laser targeting device. The main syntax targets the primary gunner turret.","syntaxes":[{"syntax":"laserTarget entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle"}],"returns":{"type":"Object","types":["Object"],"description":"laser target or objNull if no laser target exists","text":"Object - laser target or objNull if no laser target exists"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"vehicle laserTarget turret","since":"arma3 2.12","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turret: Turret Path"}],"returns":{"type":"Object","types":["Object"],"description":"laser target or objNull if no laser target exists","text":"Object - laser target or objNull if no laser target exists"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turret","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nprivate _target = laserTarget gunner heli;\n```","code":["private _target = laserTarget gunner heli;"]},{"text":"```sqf\nprivate _designatedPos = getPosATL laserTarget player;\n```","code":["private _designatedPos = getPosATL laserTarget player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isLaserOn","cursorTarget","setMissileTarget"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbAdd","operator":null,"title":"lbAdd","type":"command","url":"https://community.bistudio.com/wiki/lbAdd","revid":369231,"updated":"2024-09-03T10:34:56Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds an item with the given text to the CT_LISTBOX or CT_COMBO or CT_TOOLBOX.\n\n> [!NOTE]\n> If using `RscToolBox` as template with ctrlCreate, clear it first with lbClear","syntaxes":[{"syntax":"lbAdd [idc, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"text","type":"String","optional":false,"default":null,"description":"visible text","types":["String"],"since":null,"text":"text: String - visible text"}],"returns":{"type":"Number","types":["Number"],"description":"index (row) of newly added item","text":"Number - index (row) of newly added item"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, text]","types":["Array"]}},{"syntax":"control lbAdd text","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Number","types":["Number"],"description":"index (row) of newly added item","text":"Number - index (row) of newly added item"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n_index = lbAdd [101, \"First item\"];\n```","code":["_index = lbAdd [101, \"First item\"];"]},{"text":"```sqf\n_index = _control lbAdd \"First item\";\n```","code":["_index = _control lbAdd \"First item\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbDelete","lbText"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbClear","operator":null,"title":"lbClear","type":"command","url":"https://community.bistudio.com/wiki/lbClear","revid":348327,"updated":"2023-11-08T12:59:43Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Clear all items from a CT_LISTBOX or CT_COMBO control.","syntaxes":[{"syntax":"lbClear idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lbClear control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nlbClear 101;\n```","code":["lbClear 101;"]},{"text":"```sqf\nlbClear _ctrl;\n```","code":["lbClear _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbDelete"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbColor","operator":null,"title":"lbColor","type":"command","url":"https://community.bistudio.com/wiki/lbColor","revid":377362,"updated":"2026-01-02T06:40:30Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the text color of the item with the given index of the CT_LISTBOX or CT_COMBO with IDC of the topmost user dialog.","syntaxes":[{"syntax":"lbColor [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbColor index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_colour = lbColor [101, 0];\n```","code":["_colour = lbColor [101, 0];"]},{"text":"```sqf\n_color = _control lbColor 0;\n```","code":["_color = _control lbColor 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetColor"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbColorRight","operator":null,"title":"lbColorRight","type":"command","url":"https://community.bistudio.com/wiki/lbColorRight","revid":377352,"updated":"2026-01-02T06:40:15Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the text color of the item (right) with the given index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"lbColorRight [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's id","types":["Number"],"since":null,"text":"idc: Number - control's id"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbColorRight index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_colour = lbColorRight [101, 0];\n```","code":["_colour = lbColorRight [101, 0];"]},{"text":"```sqf\n_color = _control lbColorRight 0;\n```","code":["_color = _control lbColorRight 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbPictureRight","lbSelection","lbSetColor","lbSetColorRight","lbSetCurSel","lbSetData","lbSetPicture","lbSetPictureRight","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbCurSel","operator":null,"title":"lbCurSel","type":"command","url":"https://community.bistudio.com/wiki/lbCurSel","revid":349157,"updated":"2023-11-08T14:49:50Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the index of the selected item of the CT_LISTBOX, CT_LISTNBOX, CT_COMBO or CT_TOOLBOX. For CT_LISTBOX with multi selection enabled use lbSelection.","syntaxes":[{"syntax":"lbCurSel idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Number","types":["Number"],"description":"selected index (row) or -1 if nothing is selected","text":"Number - selected index (row) or -1 if nothing is selected"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lbCurSel control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":"selected index (row) or -1 if nothing is selected","text":"Number - selected index (row) or -1 if nothing is selected"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_index = lbCurSel 101;\n```","code":["_index = lbCurSel 101;"]},{"text":"```sqf\nlbCurSel _ctrl;\n```","code":["lbCurSel _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbIsSelected","lbSelection","lbSetCurSel"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbData","operator":null,"title":"lbData","type":"command","url":"https://community.bistudio.com/wiki/lbData","revid":364197,"updated":"2024-05-05T10:46:54Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the data set in given index of the CT_LISTBOX or CT_COMBO.","syntaxes":[{"syntax":"lbData [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbData index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_data = lbData [101, 0];\n```","code":["_data = lbData [101, 0];"]},{"text":"```sqf\n_data = _control lbData 0;\n```","code":["_data = _control lbData 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetData"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:28:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbDelete","operator":null,"title":"lbDelete","type":"command","url":"https://community.bistudio.com/wiki/lbDelete","revid":364178,"updated":"2024-05-05T10:46:45Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Removes the item with the given index from the CT_LISTBOX, CT_COMBO or CT_TOOLBOX.","syntaxes":[{"syntax":"lbDelete [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbDelete index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nlbDelete [101, 0];\n```","code":["lbDelete [101, 0];"]},{"text":"```sqf\n_control lbDelete 0;\n```","code":["_control lbDelete 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbIsSelected","operator":null,"title":"lbIsSelected","type":"command","url":"https://community.bistudio.com/wiki/lbIsSelected","revid":310911,"updated":"2022-05-07T20:33:32Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether or not given row of the given listbox is selected.","syntaxes":[{"syntax":"control lbIsSelected index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_selected = _control lbIsSelected 0;\n```","code":["_selected = _control lbIsSelected 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbPicture","operator":null,"title":"lbPicture","type":"command","url":"https://community.bistudio.com/wiki/lbPicture","revid":330125,"updated":"2022-08-21T20:24:57Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the picture name of the item with the given index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"lbPicture [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of control","types":["Number"],"since":null,"text":"idc: Number - idc of control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbPicture index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_picture = lbPicture [101, 0];\n```","code":["_picture = lbPicture [101, 0];"]},{"text":"```sqf\n_picture = _control lbPicture 0;\n```","code":["_picture = _control lbPicture 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetPicture"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbPictureRight","operator":null,"title":"lbPictureRight","type":"command","url":"https://community.bistudio.com/wiki/lbPictureRight","revid":319142,"updated":"2022-05-13T09:23:15Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the right picture name of the item with the given index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"lbPictureRight [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of control","types":["Number"],"since":null,"text":"idc: Number - idc of control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbPictureRight index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_picture = lbPictureRight [101, 0];\n```","code":["_picture = lbPictureRight [101, 0];"]},{"text":"```sqf\n_picture = _control lbPictureRight 0;\n```","code":["_picture = _control lbPictureRight 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSelection","operator":null,"title":"lbSelection","type":"command","url":"https://community.bistudio.com/wiki/lbSelection","revid":377149,"updated":"2026-01-01T10:35:25Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns Array of selected rows indices in the given listbox. If listbox is of style LB_MULTI (multi-selection) the array will contain multiple elements, otherwise only a single element. For single selection listbox one can also use lbCurSel. See also lbIsSelected, lbSetSelected","syntaxes":[{"syntax":"lbSelection control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_indices = lbSelection _control;\n```","code":["_indices = lbSelection _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSetColor","operator":null,"title":"lbSetColor","type":"command","url":"https://community.bistudio.com/wiki/lbSetColor","revid":319139,"updated":"2022-05-13T09:23:14Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the color of the item (left) with the given index of the listbox or combobox with id idc of the topmost user Dialog to color.","syntaxes":[{"syntax":"lbSetColor [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetColor [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetColor [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetColor [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_control lbSetColor [0, [0, 1, 0, 0.5]];\n```","code":["_control lbSetColor [0, [0, 1, 0, 0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbColor","lbSetColorRight","lbColorRight"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSetColorRight","operator":null,"title":"lbSetColorRight","type":"command","url":"https://community.bistudio.com/wiki/lbSetColorRight","revid":377346,"updated":"2026-01-02T06:40:03Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the color of the item (right) with the given index of the listbox or combobox with id idc of the topmost user dialog to color.","syntaxes":[{"syntax":"lbSetColorRight [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control id","types":["Number"],"since":null,"text":"idc: Number - control id"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetColorRight [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetColorRight [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetColorRight [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_control lbSetColorRight [0, [0, 1, 0, 0.5]];\n```","code":["_control lbSetColorRight [0, [0, 1, 0, 0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:30:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSetCurSel","operator":null,"title":"lbSetCurSel","type":"command","url":"https://community.bistudio.com/wiki/lbSetCurSel","revid":376677,"updated":"2025-11-04T00:29:50Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects the item with the given index in the listbox, listnbox, combobox, xcombobox, xlistbox\n\n> [!IMPORTANT]\n> **The following only applies to the Alternative Syntax when used with CT_LISTBOX and CT_LISTNBOX.**\n>\n> To deselect all entries, use -1: `_ctrl lbSetCurSel -1;` For listbox of style LB_MULTI use lbSetSelected instead.\n>\n> CT_COMBO does not allow deselecting entries, it will instead select the first one as it is not a combobox usual behaviour.\n> If you really need to deselect a combobox, see DreadedEntity's note. For the ComboBox you might as well want to explicitly select index 0 to avoid showing ghost row.","syntaxes":[{"syntax":"lbSetCurSel [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbSetCurSel index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nlbSetCurSel [101, 0];\n```","code":["lbSetCurSel [101, 0];"]},{"text":"```sqf\n_control lbSetCurSel 0;\n```","code":["_control lbSetCurSel 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbCurSel"],"notes":[{"user":"DreadedEntity","date":"2014-11-29T23:40:00Z","text":"**Prior to ArmA 1.90** lbSetCurSel -1 had no effect while the listbox was populated. You needed to use lbClear first, then lbSetCurSel -1, then re-populate the listbox."},{"user":"Longbow","date":"2015-03-01T18:37:00Z","text":"Keep in mind that running this command will fire the 'onLBSelChanged' event handler."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSetData","operator":null,"title":"lbSetData","type":"command","url":"https://community.bistudio.com/wiki/lbSetData","revid":319184,"updated":"2022-05-13T09:23:19Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the additional text (invisible) in the item with the given index of the listbox or combobox with id idc of the topmost user dialog to the given data.\n\n> [!NOTE]\n> See more information on the CT_LISTBOX command family here.","syntaxes":[{"syntax":"lbSetData [idc, index, data]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, data]","types":["Array"]}},{"syntax":"control lbSetData [index, data]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, data]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetData [101, 1, \"#1\"];\n```","code":["lbSetData [101, 1, \"#1\"];"]},{"text":"```sqf\n_control lbSetData [1, \"#1\"];\n```","code":["_control lbSetData [1, \"#1\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbData","lbDelete","lbSetValue","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSetPicture","operator":null,"title":"lbSetPicture","type":"command","url":"https://community.bistudio.com/wiki/lbSetPicture","revid":364161,"updated":"2024-05-05T10:46:40Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the left picture in the row with given index of CT_LISTBOX or CT_COMBO. The picture is searched for in the mission directory, the dtaExt subdirectory of the campaign directory and the dtaExt directory and the data bank (or directory).\n\n> [!NOTE]\n> **Arma 3:** In Arma 3 it might be necessary to set the color of the picture as well with lbSetPictureColor as default color `[0,0,0,0]` makes the picture invisible.","syntaxes":[{"syntax":"lbSetPicture [idc, index, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"path","type":"String","optional":false,"default":null,"description":"path to the picture","types":["String"],"since":null,"text":"path: String - path to the picture"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, path]","types":["Array"]}},{"syntax":"control lbSetPicture [index, path]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"path","type":"String","optional":false,"default":null,"description":"path to the picture","types":["String"],"since":null,"text":"path: String - path to the picture"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, path]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPicture [101, 0, \"iskoda.paa\"];\n```","code":["lbSetPicture [101, 0, \"iskoda.paa\"];"]},{"text":"```sqf\n_control lbSetPicture [0, \"iskoda.paa\"];\n```","code":["_control lbSetPicture [0, \"iskoda.paa\"];"]},{"text":"> [!NOTE]\n> Adding pictures to lists is very slow. In order to prevent a list filling's possible slowdown, add the pictures in the **scheduled** environment using spawn.\n>\n> One drawback of that method is that sorting the entries is not easily possible.\n\n```sqf\nprivate _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n[_ctrlTV, _path] spawn {\n    (_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n};\n```","code":["private _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n[_ctrlTV, _path] spawn {\n\t(_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbPicture","lbSetPictureColor","lbSetPictureRight"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:31:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSetPictureColor","operator":null,"title":"lbSetPictureColor","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureColor","revid":377805,"updated":"2026-01-03T04:08:03Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of item's picture (left) with the given index of the listbox with id idc of the topmost user dialog to the given color. Color is in format Color (RGBA). Color which consists from only zeros means disable this override.","syntaxes":[{"syntax":"lbSetPictureColor [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetPictureColor [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureColor [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetPictureColor [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_ctrl lbSetPictureColor [0, [1, 1, 1, 1]];\n```","code":["_ctrl lbSetPictureColor [0, [1, 1, 1, 1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetPictureColorSelected","lbPicture","lbSetColor","lbSetPicture","lbSetPictureRightColor","lbSetPictureRight"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:30:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"lbSetPictureColorDisabled","operator":null,"title":"lbSetPictureColorDisabled","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureColorDisabled","revid":377804,"updated":"2026-01-03T04:08:02Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.20"}],"since":{"game":"arma3","name":"Arma 3","version":"1.20"},"arma3_since":"1.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the disabled color of item's picture (left) with the given index of the listbox with id idc of the topmost user dialog to the given color. Color is in format Color (RGBA). Color which consists from only zeros means disable this override.","syntaxes":[{"syntax":"lbSetPictureColorDisabled [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetPictureColorDisabled [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureColorDisabled [101, 0, [1, 1, 1, 0.25]];\n```","code":["lbSetPictureColorDisabled [101, 0, [1, 1, 1, 0.25]];"]},{"text":"```sqf\n_ctrl lbSetPictureColorDisabled [0, [1, 1, 1, 0.25]];\n```","code":["_ctrl lbSetPictureColorDisabled [0, [1, 1, 1, 0.25]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetPictureColor","lbSetPictureRightColor","lbSetPictureRightColorDisabled"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:30:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.20","Scripting Commands"]},{"name":"lbSetPictureColorSelected","operator":null,"title":"lbSetPictureColorSelected","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureColorSelected","revid":377357,"updated":"2026-01-02T06:40:23Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.20"}],"since":{"game":"arma3","name":"Arma 3","version":"1.20"},"arma3_since":"1.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the selected color of item's picture (left) with the given index of the listbox with id idc of the topmost user dialog to the given color. Color is in format Color (RGBA). Color which consists from only zeros means disable this override.","syntaxes":[{"syntax":"lbSetPictureColorSelected [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control id","types":["Number"],"since":null,"text":"idc: Number - control id"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetPictureColorSelected [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureColorSelected [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetPictureColorSelected [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_ctrl lbSetPictureColorSelected [0, [1, 1, 1, 1]];\n```","code":["_ctrl lbSetPictureColorSelected [0, [1, 1, 1, 1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor","lbSetPictureColorDisabled"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-10T16:30:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.20","Scripting Commands"]},{"name":"lbSetPictureRight","operator":null,"title":"lbSetPictureRight","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureRight","revid":377810,"updated":"2026-01-03T04:08:11Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the second (right aligned) picture in the item with the given index of the listbox or combobox with id idc of the topmost user dialog. Name is the picture name.\nThe picture is searched for in the mission directory, the dtaExt subdirectory of the campaign directory and the dtaExt directory and the data bank (or directory).\n\nIn Arma 3 it might be necessary to set the color of the picture as well with lbSetPictureRightColor as default [0,0,0,0] color makes the picture invisible.\n\n> [!NOTE]\n> When trying to select a listBox entry by clicking at the right picture, the control in the background is focused. It seems the width of the control is not extended by adding a right picture.","syntaxes":[{"syntax":"lbSetPictureRight [idc, index, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"path","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"path: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, path]","types":["Array"]}},{"syntax":"control lbSetPictureRight [index, path]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"path","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"path: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, path]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureRight [101, 0, \"a3\\3den\\data\\cfg3den\\history\\createcomment_ca.paa\"];\n```","code":["lbSetPictureRight [101, 0, \"a3\\3den\\data\\cfg3den\\history\\createcomment_ca.paa\"];"]},{"text":"```sqf\n_control lbSetPictureRight [0, \"a3\\3den\\data\\cfg3den\\history\\createcomment_ca.paa\"];\n```","code":["_control lbSetPictureRight [0, \"a3\\3den\\data\\cfg3den\\history\\createcomment_ca.paa\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbPicture","lbSetPicture","lbSetPictureColor"],"notes":[{"user":"Ffur2007slx2_5","date":"2014-09-10T16:31:00Z","text":"More information on the CT_LISTBOX command family can be found here."},{"user":"R3vo","date":"2021-04-06T07:34:00Z","text":"Adding pictures to lists is very slow. In order to prevent the filling of the list to be slowed down, add the pictures in the **scheduled** environment.\nOne drawback of that method is, that sorting the entries is not easily possible.\n\n```sqf\nprivate _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n[_ctrlTV, _path] spawn {\n    (_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n};\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSetPictureRightColor","operator":null,"title":"lbSetPictureRightColor","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureRightColor","revid":377351,"updated":"2026-01-02T06:40:13Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of the second (right aligned) picture of the given index of the listbox with id idc of the topmost user dialog to the given color.\nColor which consists from only zeros means disable this override.","syntaxes":[{"syntax":"lbSetPictureRightColor [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control id","types":["Number"],"since":null,"text":"idc: Number - control id"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetPictureRightColor [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureRightColor [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetPictureRightColor [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_ctrl lbSetPictureRightColor [0, [1, 1, 1, 1]];\n```","code":["_ctrl lbSetPictureRightColor [0, [1, 1, 1, 1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbSetPictureColorSelected","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"lbSetPictureRightColorDisabled","operator":null,"title":"lbSetPictureRightColorDisabled","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureRightColorDisabled","revid":377803,"updated":"2026-01-03T04:08:00Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.20"}],"since":{"game":"arma3","name":"Arma 3","version":"1.20"},"arma3_since":"1.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the disabled color of second (right aligned) picture of the item with the given index of the listbox with id idc of the topmost user dialog to the given color.\nColor which consists from only zeros means disable this override.","syntaxes":[{"syntax":"lbSetPictureRightColorDisabled [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetPictureRightColorDisabled [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetPictureRightColorDisabled [101, 0, [1, 1, 1, 0.25]];\n```","code":["lbSetPictureRightColorDisabled [101, 0, [1, 1, 1, 0.25]];"]},{"text":"```sqf\n_ctrl lbSetPictureRightColorDisabled [0, [1, 1, 1, 0.25]];\n```","code":["_ctrl lbSetPictureRightColorDisabled [0, [1, 1, 1, 0.25]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor","lbSetPictureColorDisabled","lbSetPictureColorSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.20","Scripting Commands"]},{"name":"lbSetPictureRightColorSelected","operator":null,"title":"lbSetPictureRightColorSelected","type":"command","url":"https://community.bistudio.com/wiki/lbSetPictureRightColorSelected","revid":377370,"updated":"2026-01-02T06:42:16Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.20"}],"since":{"game":"arma3","name":"Arma 3","version":"1.20"},"arma3_since":"1.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the selected color of the second (right aligned) picture of the item with the given index of the listbox with id idc of the topmost user dialog to the given color.\nColor which consists from only zeros means disable this override.","syntaxes":[{"syntax":"control lbSetPictureRightColorSelected [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lbSetPictureRightColorSelected [0, [1, 1, 1, 1]];\n```","code":["_ctrl lbSetPictureRightColorSelected [0, [1, 1, 1, 1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor","lbSetPictureColorDisabled","lbSetPictureColorSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.20","Scripting Commands"]},{"name":"lbSetSelectColor","operator":null,"title":"lbSetSelectColor","type":"command","url":"https://community.bistudio.com/wiki/lbSetSelectColor","revid":377809,"updated":"2026-01-03T04:08:10Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.46"}],"since":{"game":"arma3","name":"Arma 3","version":"1.46"},"arma3_since":"1.46","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the select color of the item with the given index of the listbox or combobox with id idc of the topmost user dialog to color.","syntaxes":[{"syntax":"lbSetSelectColor [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetSelectColor [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetSelectColor [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetSelectColor [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_control lbSetSelectColor [0, [0, 1, 0, 0.5]];\n```","code":["_control lbSetSelectColor [0, [0, 1, 0, 0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetColor","lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.46","Scripting Commands"]},{"name":"lbSetSelectColorRight","operator":null,"title":"lbSetSelectColorRight","type":"command","url":"https://community.bistudio.com/wiki/lbSetSelectColorRight","revid":377808,"updated":"2026-01-03T04:08:08Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.46"}],"since":{"game":"arma3","name":"Arma 3","version":"1.46"},"arma3_since":"1.46","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the select color of the of the secondary text (right aligned) of the item with the given index of the listbox or combobox with id idc of the topmost user dialog to color.","syntaxes":[{"syntax":"lbSetSelectColorRight [idc, index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, color]","types":["Array"]}},{"syntax":"control lbSetSelectColorRight [index, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, color]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetSelectColorRight [101, 0, [0, 1, 0, 0.5]];\n```","code":["lbSetSelectColorRight [101, 0, [0, 1, 0, 0.5]];"]},{"text":"```sqf\n_control lbSetSelectColorRight [0, [0, 1, 0, 0.5]];\n```","code":["_control lbSetSelectColorRight [0, [0, 1, 0, 0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetSelectColor","lbSetColor","lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 1.46","Scripting Commands"]},{"name":"lbSetSelected","operator":null,"title":"lbSetSelected","type":"command","url":"https://community.bistudio.com/wiki/lbSetSelected","revid":352415,"updated":"2024-02-09T15:26:07Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the selection state of the given row of the given listbox of style LB_MULTI.\nThe command has to be called for every row which is needed to be selected in multi-selection listbox. Use negative index -1 to select/deselect all rows (since Arma 3 v2.12).\nFor single selection listbox use lbSetCurSel instead.","syntaxes":[{"syntax":"control lbSetSelected [index, selected, forceEH]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number or since Arma 3 v2.12 Array of Numbers","optional":false,"default":null,"description":null,"types":["Number","Array"],"since":null,"text":"index: Number or since Arma 3 v2.12 Array of Numbers"},{"name":"selected","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"selected: Boolean"},{"name":"forceEH","type":"Boolean","optional":true,"default":"false","description":"will force lbSelChanged EH to fire","types":["Boolean"],"since":"arma3 2.12","text":"forceEH: Boolean - (Optional, default false) will force lbSelChanged EH to fire"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, selected, forceEH]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control lbSetSelected [0, true];\n```","code":["_control lbSetSelected [0, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSetText","operator":null,"title":"lbSetText","type":"command","url":"https://community.bistudio.com/wiki/lbSetText","revid":377806,"updated":"2026-01-03T04:08:05Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the text on the left side of the item with the given index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"lbSetText [idc, index, name]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, name]","types":["Array"]}},{"syntax":"control lbSetText [index, name]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, name]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetText [101, 0, \"iskoda\"];\n```","code":["lbSetText [101, 0, \"iskoda\"];"]},{"text":"```sqf\n_control lbSetText [0, \"iskoda\"];\n```","code":["_control lbSetText [0, \"iskoda\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetTextRight","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSetTextRight","operator":null,"title":"lbSetTextRight","type":"command","url":"https://community.bistudio.com/wiki/lbSetTextRight","revid":330115,"updated":"2022-08-21T19:43:41Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the text on the right side of the item with the given row index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"control lbSetTextRight [row, name]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[row, name]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control lbSetTextRight [0, \"iskoda\"];\n```","code":["_control lbSetTextRight [0, \"iskoda\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetSelected","lbSetText","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue","lbSetPicture","lbSetPictureColor"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSetTooltip","operator":null,"title":"lbSetTooltip","type":"command","url":"https://community.bistudio.com/wiki/lbSetTooltip","revid":364888,"updated":"2024-06-29T14:38:30Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.58"}],"since":{"game":"arma3","name":"Arma 3","version":"0.58"},"arma3_since":"0.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip for item with given index of the listbox or combobox with id idc of the topmost user dialog to the given data.","syntaxes":[{"syntax":"lbSetTooltip [idc, index, tooltip]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"tooltip","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"tooltip: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, tooltip]","types":["Array"]}},{"syntax":"control lbSetTooltip [index, tooltip]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"tooltip","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"tooltip: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, tooltip]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetTooltip [101, 1, \"tooltip\"];\n```","code":["lbSetTooltip [101, 1, \"tooltip\"];"]},{"text":"```sqf\n_control lbSetTooltip [0, \"another tooltip\"];\n```","code":["_control lbSetTooltip [0, \"another tooltip\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbTooltip","lnbSetTooltip","lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetValue","lbSize","lbSort","lbSortByValue","lbText","lbValue"],"notes":[{"user":"Nelis75733126","date":"2017-08-09T13:03:00Z","text":"if you want to put linebreaks into a tooltip, use this method:\n\n```sqf\nformat [\"%1,%2%3\", \"Hi\", parseText \"\\n\", \"my name is Will\"];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 0.58","Scripting Commands"]},{"name":"lbSetValue","operator":null,"title":"lbSetValue","type":"command","url":"https://community.bistudio.com/wiki/lbSetValue","revid":364175,"updated":"2024-05-05T10:46:45Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the additional value in the row with the given index of a CT_LISTBOX or CT_COMBO control.","syntaxes":[{"syntax":"lbSetValue [idc, index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":"only integer values are supported","types":["Number"],"since":null,"text":"value: Number - only integer values are supported"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index, value]","types":["Array"]}},{"syntax":"control lbSetValue [index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":"only integer values are supported","types":["Number"],"since":null,"text":"value: Number - only integer values are supported"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[index, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSetValue [101, 0, 1];\n```","code":["lbSetValue [101, 0, 1];"]},{"text":"```sqf\n_control lbSetValue [0, 1];\n```","code":["_control lbSetValue [0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortByValue","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSize","operator":null,"title":"lbSize","type":"command","url":"https://community.bistudio.com/wiki/lbSize","revid":353733,"updated":"2024-03-22T10:26:54Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the number of items in a CT_LISTBOX or CT_COMBO control. For CT_TOOLBOX size see lnbSize.","syntaxes":[{"syntax":"lbSize idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's id","types":["Number"],"since":null,"text":"idc: Number - control's id"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lbSize control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_size = lbSize 101;\n```","code":["_size = lbSize 101;"]},{"text":"```sqf\n_size = lbSize _control;\n```","code":["_size = lbSize _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSort","lbSortByValue","lbText","lbValue"],"notes":[{"user":"Ffur2007slx2_5","date":"2014-09-10T16:32:00Z","text":"More information on the CT_LISTBOX command family can be found here."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbSort","operator":null,"title":"lbSort","type":"command","url":"https://community.bistudio.com/wiki/lbSort","revid":319276,"updated":"2022-05-13T09:23:28Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts listbox entries alphabetically ascending by their lbText.","syntaxes":[{"syntax":"lbSort control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}},{"syntax":"lbSort [control, sortOrder]","since":"arma3 1.18","effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"sortOrder","type":"String","optional":false,"default":null,"description":"\"ASC\": ascending, \"DESC\": descending","types":["String"],"since":null,"text":"sortOrder: String - \"ASC\": ascending, \"DESC\": descending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[control, sortOrder]","types":["Array"]}},{"syntax":"lbSort idc","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lbSort [idc, sortOrder]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"sortOrder","type":"String","optional":false,"default":null,"description":"\"ASC\": ascending, \"DESC\": descending","types":["String"],"since":null,"text":"sortOrder: String - \"ASC\": ascending, \"DESC\": descending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, sortOrder]","types":["Array"]}}],"examples":[{"text":"```sqf\nlbSort _myControl;\n```","code":["lbSort _myControl;"]},{"text":"```sqf\nlbSort [_myControl, \"DESC\"];\n```","code":["lbSort [_myControl, \"DESC\"];"]},{"text":"```sqf\nlbSort 101;\n```","code":["lbSort 101;"]},{"text":"```sqf\nlbSort [101, \"DESC\"];\n```","code":["lbSort [101, \"DESC\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","lbSortByValue","lnbSort","tvSort","tvSortByValue","lnbSortByValue","lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbText","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbSortBy","operator":null,"title":"lbSortBy","type":"command","url":"https://community.bistudio.com/wiki/lbSortBy","revid":310351,"updated":"2022-05-05T17:24:12Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts given ListBox by either lbText, lbValue or lbData in normal or reversed order, using case-sensitive or case-insensitive comparison. This command supports UNICODE characters.\nWhen sorting by `\"VALUE\"`, the rows with the same lbValue will additionally be sorted by lbText in the order specified by `reversedOrder` flag, text specified by `useTextRight` flag and case-sensitivity specified by `caseSensitive` flag.\n\n> [!IMPORTANT]\n> - This command supports referencing control via IDC as well, but as with any use of IDC in UI Control commands, a dialog should be present, i.e. UI user interaction is created with createDialog rather than createDisplay.\n> - As this command supports UNICODE by default, which may result in slower sorting, you can switch it off with `unicodeOff` param.","syntaxes":[{"syntax":"controlOrIDC lbSortBy [sortByType, reversedOrder, caseSensitive, useTextRight, unicodeOff]","since":null,"effect":null,"exec":null,"params":[{"name":"controlOrIDC","type":"Control or Number","optional":false,"default":null,"description":"the ListBox control or its IDC","types":["Control","Number"],"since":null,"text":"controlOrIDC: Control or Number - the ListBox control or its IDC"},{"name":"sortByType","type":"String","optional":true,"default":"\"TEXT\"","description":"one of:\n- `\"TEXT\"`\n- `\"VALUE\"`\n- `\"DATA\"`","types":["String"],"since":null,"text":"sortByType: String - (Optional, default \"TEXT\") one of:\n- `\"TEXT\"`\n- `\"VALUE\"`\n- `\"DATA\"`"},{"name":"reversedOrder","type":"Boolean","optional":true,"default":"false","description":"true for sorting in reversed order","types":["Boolean"],"since":null,"text":"reversedOrder: Boolean - (Optional, default false) true for sorting in reversed order"},{"name":"caseSensitive","type":"Boolean","optional":true,"default":"false","description":"true for using case-sensitive comparison","types":["Boolean"],"since":null,"text":"caseSensitive: Boolean - (Optional, default false) true for using case-sensitive comparison"},{"name":"useTextRight","type":"Boolean","optional":true,"default":"false","description":"true to sort by text right","types":["Boolean"],"since":null,"text":"useTextRight: Boolean - (Optional, default false) true to sort by text right"},{"name":"unicodeOff","type":"Boolean","optional":true,"default":"false","description":"true to switch off UNICODE conversion for faster sorting","types":["Boolean"],"since":null,"text":"unicodeOff: Boolean - (Optional, default false) true to switch off UNICODE conversion for faster sorting"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"controlOrIDC","types":["Control","Number"]},"right":{"text":"[sortByType, reversedOrder, caseSensitive, useTextRight, unicodeOff]","types":["Array"]}}],"examples":[{"text":"```sqf\nwith uiNamespace do\n{\n    private _lb = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscListBox\", -1];\n    _lb ctrlSetPosition [0,0,1,1];\n    _lb ctrlCommit 0;\n    lbClear _lb;\n    {\n        _lb lbAdd (_x select 0);\n        _lb lbSetValue [_forEachIndex, _x select 1];\n    }\n    forEach [[\"В\",1], [\"Я\",0], [\"Б\",1], [\"Ю\",0], [\"А\",1]];\n    _lb lbSortBy [\"VALUE\", false, false];\n};\n```","code":["with uiNamespace do\n{\n\tprivate _lb = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscListBox\", -1];\n\t_lb ctrlSetPosition [0,0,1,1];\n\t_lb ctrlCommit 0;\n\tlbClear _lb;\n\t{\n\t\t_lb lbAdd (_x select 0);\n\t\t_lb lbSetValue [_forEachIndex, _x select 1];\n\t}\n\tforEach [[\"В\",1], [\"Я\",0], [\"Б\",1], [\"Ю\",0], [\"А\",1]];\n\t_lb lbSortBy [\"VALUE\", false, false];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSortBy","lnbSort","lnbSortByValue","lbSort","lbSortByValue","tvSort","tvSortByValue","sort"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"lbSortByValue","operator":null,"title":"lbSortByValue","type":"command","url":"https://community.bistudio.com/wiki/lbSortByValue","revid":363604,"updated":"2024-04-08T09:49:07Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts the ListBox entries by lbValue. The entries are sorted in ascending order. Also note that this command will mix up the entries randomly if multiple entries have the same value. In Arma 3 use lbSortBy to avoid this problem.","syntaxes":[{"syntax":"lbSortByValue control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}},{"syntax":"lbSortByValue idc","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}}],"examples":[{"text":"```sqf\nlbSortByValue _control;\n```","code":["lbSortByValue _control;"]},{"text":"```sqf\nlbSortByValue 101;\n```","code":["lbSortByValue 101;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lbSort"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lbText","operator":null,"title":"lbText","type":"command","url":"https://community.bistudio.com/wiki/lbText","revid":348353,"updated":"2023-11-08T12:59:52Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the shown text of the item with the given index of the CT_LISTBOX or CT_COMBO.","syntaxes":[{"syntax":"lbText [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbText index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_text = lbText [101, 0];\n```","code":["_text = lbText [101, 0];"]},{"text":"```sqf\n_text = _control lbText 0;\n```","code":["_text = _control lbText 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbAdd","lbSetText"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbTextRight","operator":null,"title":"lbTextRight","type":"command","url":"https://community.bistudio.com/wiki/lbTextRight","revid":377807,"updated":"2026-01-03T04:08:07Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the shown right text in the item with the given index of the listbox or combobox with id idc of the topmost user dialog.","syntaxes":[{"syntax":"lbTextRight [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbTextRight index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_text = lbTextRight [101, 0];\n```","code":["_text = lbTextRight [101, 0];"]},{"text":"```sqf\n_text = _control lbTextRight 0;\n```","code":["_text = _control lbTextRight 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetTextRight","lbAdd","lbClear","lbColor","lbCurSel","lbData","lbDelete","lbIsSelected","lbPicture","lbSelection","lbSetColor","lbSetCurSel","lbSetData","lbSetPicture","lbSetSelected","lbSetTooltip","lbSetValue","lbSize","lbSort","lbSortByValue","lbValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lbTooltip","operator":null,"title":"lbTooltip","type":"command","url":"https://community.bistudio.com/wiki/lbTooltip","revid":309997,"updated":"2022-05-05T12:20:38Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns tooltip for ListBox, ComboBox and Toolbox","syntaxes":[{"syntax":"lbTooltip [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbTooltip index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nlbTooltip [1, 1];\n```","code":["lbTooltip [1, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetTooltip","ctrlTooltip"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"lbValue","operator":null,"title":"lbValue","type":"command","url":"https://community.bistudio.com/wiki/lbValue","revid":364170,"updated":"2024-05-05T10:46:44Z","groups":["GUI Control - ListBox"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the additional integer value of the item with the given index of the CT_LISTBOX or CT_COMBO.","syntaxes":[{"syntax":"lbValue [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control IDC","types":["Number"],"since":null,"text":"idc: Number - control IDC"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Number","types":["Number"],"description":"only integers","text":"Number - only integers"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"control lbValue index","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Number","types":["Number"],"description":"only integers","text":"Number - only integers"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_value = lbValue [101, 0];\n```","code":["_value = lbValue [101, 0];"]},{"text":"```sqf\n_value = _control lbValue 0;\n```","code":["_value = _control lbValue 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetValue","lbSortByValue"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListBox","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"leader","operator":null,"title":"leader","type":"command","url":"https://community.bistudio.com/wiki/leader","revid":319064,"updated":"2022-05-13T09:23:07Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the group leader for the given **unit** or **group**. For dead units, objNull is returned.","syntaxes":[{"syntax":"leader unitOrGroup","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrGroup","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"unitOrGroup: Object or Group"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unitOrGroup","types":["Object","Group"]}}],"examples":[{"text":"```sqf\nleader group player == leader player;\n```","code":["leader group player == leader player;"]},{"text":"```sqf\nleader group vehicle player;\n```","code":["leader group vehicle player;"]},{"text":"```sqf\nleader player;\n```","code":["leader player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["formationLeader","formLeader","isFormationLeader","selectLeader"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"leaderboardDeInit","operator":null,"title":"leaderboardDeInit","type":"command","url":"https://community.bistudio.com/wiki/leaderboardDeInit","revid":323055,"updated":"2022-06-28T21:43:11Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deletes internal class for the leaderboard with given name. Returns true if the board has been found and deinitialized.","syntaxes":[{"syntax":"leaderboardDeInit boardName","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"boardName","types":["String"]}}],"examples":[{"text":"```sqf\nleaderboardDeInit \"TT01\";\n```","code":["leaderboardDeInit \"TT01\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardGetRows","leaderboardInit","leaderboardRequestRowsFriends","leaderboardRequestRowsGlobal","leaderboardRequestRowsGlobalAroundUser","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"leaderboardGetRows","operator":null,"title":"leaderboardGetRows","type":"command","url":"https://community.bistudio.com/wiki/leaderboardGetRows","revid":377273,"updated":"2026-01-02T06:36:42Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns values for the given leaderboard; this can be called after the one of the row request function has been called and successfully finished!","syntaxes":[{"syntax":"leaderboardGetRows boardName","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array format: [[player1Name, score, rank], [player2Name, score, rank], [player3Name, score, rank] ...]"},"form":"unary","operator":null,"left":null,"right":{"text":"boardName","types":["String"]}}],"examples":[{"text":"```sqf\nleaderboardGetRows \"TT01\";\n```","code":["leaderboardGetRows \"TT01\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardDeInit","leaderboardInit","leaderboardRequestRowsFriends","leaderboardRequestRowsGlobal","leaderboardRequestRowsGlobalAroundUser","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"leaderboardInit","operator":null,"title":"leaderboardInit","type":"command","url":"https://community.bistudio.com/wiki/leaderboardInit","revid":323025,"updated":"2022-06-28T21:43:08Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Initialize the leaderboard structure for board with given name. Returns true if board is already initialized.","syntaxes":[{"syntax":"leaderboardInit boardName","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"boardName","types":["String"]}}],"examples":[{"text":"```sqf\nleaderboardInit \"TT01\";\n```","code":["leaderboardInit \"TT01\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardDeInit","leaderboardGetRows","leaderboardRequestRowsFriends","leaderboardRequestRowsGlobal","leaderboardRequestRowsGlobalAroundUser","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"leaderboardRequestRowsFriends","operator":null,"title":"leaderboardRequestRowsFriends","type":"command","url":"https://community.bistudio.com/wiki/leaderboardRequestRowsFriends","revid":319507,"updated":"2022-05-13T09:24:12Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Requests given leaderboard to download friends rows from the given leaderboard","syntaxes":[{"syntax":"leaderboardRequestRowsFriends boardName","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"boardName","types":["String"]}}],"examples":[{"text":"```sqf\nleaderboardRequestRowsFriends \"TT01\";\n```","code":["leaderboardRequestRowsFriends \"TT01\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardDeInit","leaderboardGetRows","leaderboardRequestRowsGlobal","leaderboardRequestRowsGlobalAroundUser","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"leaderboardRequestRowsGlobal","operator":null,"title":"leaderboardRequestRowsGlobal","type":"command","url":"https://community.bistudio.com/wiki/leaderboardRequestRowsGlobal","revid":349053,"updated":"2023-11-08T14:47:19Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Requests given leaderboard to download values from global table.","syntaxes":[{"syntax":"leaderboardRequestRowsGlobal [leaderboard, offset, rows]","since":null,"effect":null,"exec":null,"params":[{"name":"leaderboard","type":"String","optional":false,"default":null,"description":"name of the leaderboard","types":["String"],"since":null,"text":"leaderboard: String - name of the leaderboard"},{"name":"offset","type":"Number","optional":false,"default":null,"description":"defines how many rows are skipped","types":["Number"],"since":null,"text":"offset: Number - defines how many rows are skipped"},{"name":"rows","type":"Number","optional":false,"default":null,"description":"defines how many rows are requested","types":["Number"],"since":null,"text":"rows: Number - defines how many rows are requested"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if request has been started","text":"Boolean - returns true if request has been started"},"form":"unary","operator":null,"left":null,"right":{"text":"[leaderboard, offset, rows]","types":["Array"]}}],"examples":[{"text":"```sqf\n_isGettingValues = leaderboardRequestRowsGlobal [\"TT01\", 0, 10];\n```","code":["_isGettingValues = leaderboardRequestRowsGlobal [\"TT01\", 0, 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardGetRows","leaderboardInit","leaderboardRequestRowsFriends","leaderboardRequestRowsGlobalAroundUser","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"leaderboardRequestRowsGlobalAroundUser","operator":null,"title":"leaderboardRequestRowsGlobalAroundUser","type":"command","url":"https://community.bistudio.com/wiki/leaderboardRequestRowsGlobalAroundUser","revid":349073,"updated":"2023-11-08T14:47:22Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Requests given leaderboard to download values around the user position in the table.","syntaxes":[{"syntax":"leaderboardRequestRowsGlobalAroundUser [leaderboard, offset, rows]","since":null,"effect":null,"exec":null,"params":[{"name":"leaderboard","type":"String","optional":false,"default":null,"description":"name of the leaderboard","types":["String"],"since":null,"text":"leaderboard: String - name of the leaderboard"},{"name":"offset","type":"Number","optional":false,"default":null,"description":"offset from user position.","types":["Number"],"since":null,"text":"offset: Number - offset from user position."},{"name":"rows","type":"Number","optional":false,"default":null,"description":"defines how many rows are requested","types":["Number"],"since":null,"text":"rows: Number - defines how many rows are requested"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if request has been started","text":"Boolean - returns true if request has been started"},"form":"unary","operator":null,"left":null,"right":{"text":"[leaderboard, offset, rows]","types":["Array"]}}],"examples":[{"text":"```sqf\n_isGettingValues = leaderboardRequestRowsGlobalAroundUser [\"TT01\", -5, 10];\n```","code":["_isGettingValues = leaderboardRequestRowsGlobalAroundUser [\"TT01\", -5, 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardGetRows","leaderboardInit","leaderboardRequestRowsFriends","leaderboardRequestRowsGlobal","leaderboardsRequestUploadScore","leaderboardsRequestUploadScoreKeepBest","leaderboardState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"leaderboardsRequestUploadScore","operator":null,"title":"leaderboardsRequestUploadScore","type":"command","url":"https://community.bistudio.com/wiki/leaderboardsRequestUploadScore","revid":351313,"updated":"2023-11-27T04:56:07Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Starts async. operation to upload score to board with given name, value always overwrite the current value in the board. The board has to be initialized before the call.","syntaxes":[{"syntax":"leaderboardsRequestUploadScore [boardName, score, details]","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"},{"name":"score","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"score: Number"},{"name":"details","type":"Array","optional":true,"default":null,"description":null,"types":["Array"],"since":null,"text":"details: Array - (Optional)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[boardName, score, details]","types":["Array"]}}],"examples":[{"text":"```sqf\nleaderboardsRequestUploadScore [\"TT01\", 1234, [5,6,7,8]];\n```","code":["leaderboardsRequestUploadScore [\"TT01\", 1234, [5,6,7,8]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardRequestRowsGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"leaderboardsRequestUploadScoreKeepBest","operator":null,"title":"leaderboardsRequestUploadScoreKeepBest","type":"command","url":"https://community.bistudio.com/wiki/leaderboardsRequestUploadScoreKeepBest","revid":364164,"updated":"2024-05-05T10:46:42Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Starts async. operation to upload score to board with given name, value is only stored to board if it is better than one already in the board. The board has to be initialised before the call.","syntaxes":[{"syntax":"leaderboardsRequestUploadScoreKeepBest [boardName, score, details]","since":null,"effect":null,"exec":null,"params":[{"name":"boardName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardName: String"},{"name":"score","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"score: Number"},{"name":"details","type":"Array of Numbers","optional":true,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"details: Array of Numbers (Optional)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[boardName, score, details]","types":["Array"]}}],"examples":[{"text":"```sqf\nleaderboardsRequestUploadScoreKeepBest [\"TT01\", 1234, [5,6,7,8]];\n```","code":["leaderboardsRequestUploadScoreKeepBest [\"TT01\", 1234, [5,6,7,8]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardsRequestUploadScore"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"leaderboardState","operator":null,"title":"leaderboardState","type":"command","url":"https://community.bistudio.com/wiki/leaderboardState","revid":339110,"updated":"2023-04-26T10:54:35Z","groups":["Leaderboards"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of the board with the given name.","syntaxes":[{"syntax":"leaderboardState boardname","since":null,"effect":null,"exec":null,"params":[{"name":"boardname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"boardname: String"}],"returns":{"type":"Number","types":["Number"],"description":"0: Busy (async. operation in progress) - 1: Async. operation ended with success - 2: Async. operation ended with error - 3: Invalid board (bad board name, not initialised etc)","text":"Number\n- 0: Busy (async. operation in progress)\n- 1: Async. operation ended with success\n- 2: Async. operation ended with error\n- 3: Invalid board (bad board name, not initialised etc)"},"form":"unary","operator":null,"left":null,"right":{"text":"boardname","types":["String"]}}],"examples":[{"text":"```sqf\nleaderboardState \"TT01\";\n```","code":["leaderboardState \"TT01\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["leaderboardsRequestUploadScoreKeepBest","leaderboardsRequestUploadScore"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Leaderboards","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"leaveVehicle","operator":null,"title":"leaveVehicle","type":"command","url":"https://community.bistudio.com/wiki/leaveVehicle","revid":347946,"updated":"2023-11-07T05:26:00Z","groups":["Unit Control","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Ceases the using of the vehicle by a group and unassigns vehicle from the group.\nIf the argument is a single unit, the vehicle will be unassigned from unit's group.\nAfter vehicle is unassigned from the group, each individual crew member then unassigned from the vehicle.\n\nIn short the command could be hypothetically presented as:\n\n```sqf\nleaveVehicle = un-addVehicle + unassignVehicle forEach crew\n```\n\nHowever, to make it more reliable, it is best to move unit out of the vehicle manually with moveOut and force unassign the vehicle with unassignVehicle.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"group leaveVehicle vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group or Object","optional":false,"default":null,"description":"object's Group is used","types":["Group","Object"],"since":null,"text":"group: Group or Object - object's Group is used"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group","Object"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_unit leaveVehicle _vehicle;\n```","code":["_unit leaveVehicle _vehicle;"]},{"text":"```sqf\n_grp leaveVehicle _vehicle;\n```","code":["_grp leaveVehicle _vehicle;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addVehicle","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","assignedVehicle","unassignVehicle","doGetOut","commandGetOut","createVehicleCrew","assignedVehicles","assignedGroup","fullCrew"],"notes":[{"user":"Killzone_Kid","date":"2013-08-31T16:08:00Z","text":"In Arma 3 this command will not force a player to exit from a vehicle. It will unassign vehicle role for this player. AI crew however will also disembark."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"libraryCredits","operator":null,"title":"libraryCredits","type":"command","url":"https://community.bistudio.com/wiki/libraryCredits","revid":369338,"updated":"2024-09-03T18:43:01Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the credits for the libraries used by the game.","syntaxes":[{"syntax":"libraryCredits","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array","types":["Array"],"description":"[array1, array2, (..), arrayN] all under the form [libraryName, credits]","text":"Array - [array1, array2, (..), arrayN] all under the form [libraryName, credits]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str libraryCredits; // as of Arma 2 OA 1.62.95208\n\n/*\n[\n    [\n        \"Botan\",\n        \"1999-2012 Jack Lloyd, 2001 Peter J Jones, 2004-2007 Justin Karneges, 2004 Vaclav Ovsik, 2005 Matthew Gregan, 2005-2006 Matt Johnston, 2006 Luca Piccarreta, 2007 Yves Jerschow, 2007-2008 FlexSecure GmbH, 2007-2008 Technische Universitat Darmstadt, 2007-2008 Falko Strenzke, 2007-2008 Martin Doering, 2007 Manuel Hartl, 2007 Christoph Ludwig, 2007 Patrick Sona, 2010 Olivier de Gaalon\"\n    ],\n    [\n        \"rapidjson\",\n        \"2011 Milo Yip\"\n    ],\n    [\n        \"libcurl\",\n        \"Copyright (c) 1996 - 2012, Daniel Stenberg\"\n    ],\n    [\n        \"GameSpy\",\n        \"2009 GameSpy Industries, Inc.\"\n    ],\n    [\n        \"Theora\",\n        \"2002-2009 by the Xiph.Org Foundation http://www.xiph.org/\"\n    ],\n    [\n        \"OggVorbis\",\n        \"1994-2002 by the Xiph.Org Foundation http://www.xiph.org/\"\n    ],\n    [\n        \"Intel JPEG Library\",\n        \"1998 Intel Corporation\"\n    ],\n    [\n        \"Matrix Template Library\",\n        \"2001-2005 The Trustees of Indiana University\"\n    ],\n    [\n        \"Matrix Template Library\",\n        \"1998-2001 University of Notre Dame\"\n    ],\n    [\n        \"Speex\",\n        \"2002-2006 Jean-Marc Valin\"\n    ],\n    [\n        \"LZO Professional\",\n        \"1996-2011 Markus Franz Xaver Johannes Oberhumer\"\n    ],\n    [\n        \"NVIDIA FXAA by TIMOTHY LOTTES\",\n        \"2010, 2011 NVIDIA CORPORATION\"\n    ],\n    [\n        \"Jimenez's MLAA\",\n        \"2012 2011 by Jorge Jimenez, Belen Masia, Jose I. Echevarria, Fernando Navarro and Diego Gutierrez\"\n    ]\n]\n*/\n```","code":["hint str libraryCredits; // as of Arma 2 OA 1.62.95208\n\n/*\n[\n\t[\n\t\t\"Botan\",\n\t\t\"1999-2012 Jack Lloyd, 2001 Peter J Jones, 2004-2007 Justin Karneges, 2004 Vaclav Ovsik, 2005 Matthew Gregan, 2005-2006 Matt Johnston, 2006 Luca Piccarreta, 2007 Yves Jerschow, 2007-2008 FlexSecure GmbH, 2007-2008 Technische Universitat Darmstadt, 2007-2008 Falko Strenzke, 2007-2008 Martin Doering, 2007 Manuel Hartl, 2007 Christoph Ludwig, 2007 Patrick Sona, 2010 Olivier de Gaalon\"\n\t],\n\t[\n\t\t\"rapidjson\",\n\t\t\"2011 Milo Yip\"\n\t],\n\t[\n\t\t\"libcurl\",\n\t\t\"Copyright (c) 1996 - 2012, Daniel Stenberg\"\n\t],\n\t[\n\t\t\"GameSpy\",\n\t\t\"2009 GameSpy Industries, Inc.\"\n\t],\n\t[\n\t\t\"Theora\",\n\t\t\"2002-2009 by the Xiph.Org Foundation http://www.xiph.org/\"\n\t],\n\t[\n\t\t\"OggVorbis\",\n\t\t\"1994-2002 by the Xiph.Org Foundation http://www.xiph.org/\"\n\t],\n\t[\n\t\t\"Intel JPEG Library\",\n\t\t\"1998 Intel Corporation\"\n\t],\n\t[\n\t\t\"Matrix Template Library\",\n\t\t\"2001-2005 The Trustees of Indiana University\"\n\t],\n\t[\n\t\t\"Matrix Template Library\",\n\t\t\"1998-2001 University of Notre Dame\"\n\t],\n\t[\n\t\t\"Speex\",\n\t\t\"2002-2006 Jean-Marc Valin\"\n\t],\n\t[\n\t\t\"LZO Professional\",\n\t\t\"1996-2011 Markus Franz Xaver Johannes Oberhumer\"\n\t],\n\t[\n\t\t\"NVIDIA FXAA by TIMOTHY LOTTES\",\n\t\t\"2010, 2011 NVIDIA CORPORATION\"\n\t],\n\t[\n\t\t\"Jimenez's MLAA\",\n\t\t\"2012 2011 by Jorge Jimenez, Belen Masia, Jose I. Echevarria, Fernando Navarro and Diego Gutierrez\"\n\t]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["libraryDisclaimers"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"libraryDisclaimers","operator":null,"title":"libraryDisclaimers","type":"command","url":"https://community.bistudio.com/wiki/libraryDisclaimers","revid":377093,"updated":"2026-01-01T09:49:31Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the library disclaimers.","syntaxes":[{"syntax":"libraryDisclaimers","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [text]","types":["Array"],"description":"text: String - the library disclaimer","text":"Array with [text]\n- text: String - the library disclaimer"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str libraryDisclaimers;\n/*\n    returns, in Arma 2:OA 1.62.95208:\n    [\"THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\"]\n*/\n```","code":["hint str libraryDisclaimers;\n/*\n\treturns, in Arma 2:OA 1.62.95208:\n\t[\"THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\"]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["libraryCredits"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lifeState","operator":null,"title":"lifeState","type":"command","url":"https://community.bistudio.com/wiki/lifeState","revid":329358,"updated":"2022-07-27T12:23:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the life state of the given unit.\n\n| Arma 2 | Arma 3 |\n|---|---|\n| - \"ALIVE\"<br>- \"DEAD\"<br>- \"DEAD-RESPAWN\"<br>- \"DEAD-SWITCHING\"<br>- \"ASLEEP\"<br>- \"UNCONSCIOUS\" | - \"HEALTHY\"<br>- \"DEAD\"<br>- \"DEAD-RESPAWN\"<br>- \"DEAD-SWITCHING\"<br>- \"INCAPACITATED\"<br>- \"INJURED\" |\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, lifeState seems to change to \"INJURED\" when `damage aliveUnit >= 0.1` (0.1 seeming to be the value defined in config under \"InjuredTreshold\" [sic]). When the state is \"INCAPACITATED\", a sub-state is available via incapacitatedState command.","syntaxes":[{"syntax":"lifeState unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _lifeState = lifeState player;\n```","code":["private _lifeState = lifeState player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnconscious","incapacitatedState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lightAttachObject","operator":null,"title":"lightAttachObject","type":"command","url":"https://community.bistudio.com/wiki/lightAttachObject","revid":377510,"updated":"2026-01-02T06:50:14Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Attach light to given object at given position on object.","syntaxes":[{"syntax":"light lightAttachObject [object, position]","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"[object, position]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyLight lightAttachObject [myVehicle, [-0.5,-0.25,1]];\n```","code":["myLight lightAttachObject [myVehicle, [-0.5,-0.25,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightBrightness","lightDetachObject","setLightColor","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight","attachObject","attachTo","attachedObjects","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","triggerAttachVehicle","attachedObject"],"notes":[{"user":"Feersum","date":"2006-12-01T16:42:00Z","text":"Light can be created with command createVehicleLocal with special vehicle class \"#lightpoint\"\n\nfor example:\n\n```sqf\n_light = \"#lightpoint\" createVehicleLocal pos;\n_light setLightBrightness 1.0;\n_light setLightAmbient [0.0, 1.0, 0.0];\n_light setLightColor [0.0, 1.0, 0.0];\n_light lightAttachObject [_object, [0,0,0]];\n```"},{"user":"Waffle SS.","date":"2015-03-31T04:49:00Z","text":"When attached, movement is slow to update (jumpy).  Use attachTo when attaching a light to moving objects."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lightDetachObject","operator":null,"title":"lightDetachObject","type":"command","url":"https://community.bistudio.com/wiki/lightDetachObject","revid":309932,"updated":"2022-05-05T12:16:58Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Detach light from object.","syntaxes":[{"syntax":"lightDetachObject light","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"light","types":["Object"]}}],"examples":[{"text":"```sqf\nlightDetachObject _light;\n```","code":["lightDetachObject _light;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightBrightness","lightAttachObject","setLightColor","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lightIsOn","operator":null,"title":"lightIsOn","type":"command","url":"https://community.bistudio.com/wiki/lightIsOn","revid":369182,"updated":"2024-09-03T10:34:45Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.04"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if lampost is on (shining).\n\n> [!NOTE]\n> A lamp state is **local** to each client (see switchLight).\n\n> [!NOTE]\n> This command was originally designed to only work with CfgNonAIVehicles class \"StreetLamp\" only;\n> since Arma 3 v1.92 this command was extended to work with street lights.","syntaxes":[{"syntax":"lightIsOn lamppost","since":null,"effect":null,"exec":null,"params":[{"name":"lamppost","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"lamppost: Object"}],"returns":{"type":"String","types":["String"],"description":"can be one of: - \"ON\" - light is on - \"OFF\" - light is off - \"AUTO\" - applicable only to the light of type \"StreetLamp\" and is only on during the night. - \"ERROR\" - if command fails","text":"String - can be one of:\n- **\"ON\"** - light is on\n- **\"OFF\"** - light is off\n- **\"AUTO\"** - applicable only to the light of type \"StreetLamp\" and is only on during the night.\n- **\"ERROR\"** - if command fails"},"form":"unary","operator":null,"left":null,"right":{"text":"lamppost","types":["Object"]}}],"examples":[{"text":"```sqf\nif (lightIsOn nearestObject [player, \"StreetLamp\"] == \"ON\") then { hint \"nightime\"; };\n```","code":["if (lightIsOn nearestObject [player, \"StreetLamp\"] == \"ON\") then { hint \"nightime\"; };"]},{"text":"```sqf\n_it = lightIsOn object 159582;\n```","code":["_it = lightIsOn object 159582;"]},{"text":"```sqf\nif (count allMissionObjects \"StreetLamp\" == 0) then {\n    hint \"Objects compatible with 'lightIsOn' are not found.\";\n} else {\n    hint \"'lightIsOn' compatible objects are found!\";\n};\n```","code":["if (count allMissionObjects \"StreetLamp\" == 0) then {\n\thint \"Objects compatible with 'lightIsOn' are not found.\";\n} else {\n\thint \"'lightIsOn' compatible objects are found!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchLight"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint version 1.04","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands"]},{"name":"lightnings","operator":null,"title":"lightnings","type":"command","url":"https://community.bistudio.com/wiki/lightnings","revid":310753,"updated":"2022-05-07T20:21:32Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current lightnings value.","syntaxes":[{"syntax":"lightnings","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Get the current *lightnings* value:\n\n```sqf\n_lightningsVal = lightnings;\n```","code":["_lightningsVal = lightnings;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightnings"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"limitSpeed","operator":null,"title":"limitSpeed","type":"command","url":"https://community.bistudio.com/wiki/limitSpeed","revid":378640,"updated":"2026-05-15T17:05:16Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Limit the speed of an AI-driven vehicle or AI person to given value. It has continuous effect and AI will not break through the speed limitation until one is contacted, engaged or regrouped.","syntaxes":[{"syntax":"objectName limitSpeed speed","since":null,"effect":null,"exec":null,"params":[{"name":"objectName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"objectName: Object"},{"name":"speed","type":"Number (or Boolean since Arma 3 2.22)","optional":false,"default":null,"description":"in km/h; By default, it's `2 * maxSpeed` of the vehicle/unit (which is defined in config). See Example 1.","types":["Number","Boolean"],"since":null,"text":"speed: Number (or Boolean since Arma 3 2.22) - in km/h; By default, it's `2 * maxSpeed` of the vehicle/unit (which is defined in config). See Example 1."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"objectName","types":["Object"]},"right":{"text":"speed","types":["Number","Boolean"]}}],"examples":[{"text":"```sqf\nleader player limitSpeed 5;        // set to walking speed\nsleep 30;\nleader player limitSpeed (2 * getNumber(configOf leader player >> \"maxSpeed\"));    // remove the limit\n```","code":["leader player limitSpeed 5;\t\t// set to walking speed\nsleep 30;\nleader player limitSpeed (2 * getNumber(configOf leader player >> \"maxSpeed\"));\t// remove the limit"]},{"text":"```sqf\naddMissionEventHandler [\"OnEachFrame\", { hintSilent format [\"myVehicle's speed: %1 km/h\", speed myVehicle toFixed 2] }];\nsleep 5;\nmyVehicle limitSpeed 5;\n```","code":["addMissionEventHandler [\"OnEachFrame\", { hintSilent format [\"myVehicle's speed: %1 km/h\", speed myVehicle toFixed 2] }];\nsleep 5;\nmyVehicle limitSpeed 5;"]},{"text":"```sqf\n// it was necessary to use limitSpeed repeatedly before Arma 3 1.24\n_this setVariable [\"speedLimit\", 50];\n_this spawn {\n    while { sleep 0.1; canMove _this } do\n    {\n        _this limitSpeed (_this getVariable \"speedLimit\");\n    };\n};\nsleep 10;\n_this setVariable [\"speedLimit\", 100]; // update the speed limit\n```","code":["// it was necessary to use limitSpeed repeatedly before Arma 3 1.24\n_this setVariable [\"speedLimit\", 50];\n_this spawn {\n\twhile { sleep 0.1; canMove _this } do\n\t{\n\t\t_this limitSpeed (_this getVariable \"speedLimit\");\n\t};\n};\nsleep 10;\n_this setVariable [\"speedLimit\", 100]; // update the speed limit"]},{"text":"Since Arma 3 2.22: \n\n```sqf\n_heli limitSpeed false; // reset to default\n```","code":["_heli limitSpeed false; // reset to default"]}],"multiplayer":null,"problems":"Since Take On Helicopters v1.00 and as of Arma 3 v2.14, using any negative value on a helicopter will not reset the speed limit, but will force it to fly in reverse.","aliases":[],"see_also":["speed","setCruiseControl","forceSpeed"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"linearConversion","operator":null,"title":"linearConversion","type":"command","url":"https://community.bistudio.com/wiki/linearConversion","revid":364172,"updated":"2024-05-05T10:46:44Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts given value from given \"from\" range to wanted \"to\" range. If clipping is set to true, the resulting value is guaranteed to be within \"to\" range no matter what. \n\n> [!NOTE]\n> **Arma 3:** Faster alternative to BIS_fnc_linearConversion.","syntaxes":[{"syntax":"linearConversion [minFrom, maxFrom, value, minTo, maxTo, clip]","since":null,"effect":null,"exec":null,"params":[{"name":"minFrom","type":"Number","optional":false,"default":null,"description":"start \"from\" range","types":["Number"],"since":null,"text":"minFrom: Number - start \"from\" range"},{"name":"maxFrom","type":"Number","optional":false,"default":null,"description":"end \"from\" range","types":["Number"],"since":null,"text":"maxFrom: Number - end \"from\" range"},{"name":"value","type":"Number","optional":false,"default":null,"description":"given value from \"from\" range","types":["Number"],"since":null,"text":"value: Number - given value from \"from\" range"},{"name":"minTo","type":"Number","optional":false,"default":null,"description":"start \"to\" range","types":["Number"],"since":null,"text":"minTo: Number - start \"to\" range"},{"name":"maxTo","type":"Number","optional":false,"default":null,"description":"end \"to\" range","types":["Number"],"since":null,"text":"maxTo: Number - end \"to\" range"},{"name":"clip","type":"Boolean","optional":true,"default":"false","description":"if true, resulting value cannot leave \"to\" range","types":["Boolean"],"since":null,"text":"clip: Boolean - (Optional, default false) if true, resulting value cannot leave \"to\" range"}],"returns":{"type":"Number","types":["Number"],"description":"respectful value from \"to\" range","text":"Number - respectful value from \"to\" range"},"form":"unary","operator":null,"left":null,"right":{"text":"[minFrom, maxFrom, value, minTo, maxTo, clip]","types":["Array"]}}],"examples":[{"text":"```sqf\n// Say given range is 0 to 1 and wanted range is 0 to 100 (percent calculation). Given value 0.55 then will be 55\nlinearConversion [0, 1, 0.55, 0, 100];\n\n// but if given value is 1.1 it will return 110\nlinearConversion [0, 1, 1.1, 0, 100, false];\n\n// or if clipping is true it will return 100\nlinearConversion [0, 1, 1.1, 0, 100, true];\n```","code":["// Say given range is 0 to 1 and wanted range is 0 to 100 (percent calculation). Given value 0.55 then will be 55\nlinearConversion [0, 1, 0.55, 0, 100];\n\n// but if given value is 1.1 it will return 110\nlinearConversion [0, 1, 1.1, 0, 100, false];\n\n// or if clipping is true it will return 100\nlinearConversion [0, 1, 1.1, 0, 100, true];"]},{"text":"```sqf\nlinearConversion [4, 8, 5, 0, 1, false];\n```","code":["linearConversion [4, 8, 5, 0, 1, false];"]},{"text":"```sqf\n// Calculate days from 1/1/1970\nfnc_daysFromEpoc = \n{\n    private _year = param [0];\n    private _days = 0;\n    for \"_i\" from 1970 to _year - 1 do \n    {\n        _days = _days + round linearConversion [0, 1, dateToNumber [_i, 12, 31, 23, 59], 0, 365, false];\n    };\n    _days + linearConversion [0, 1, dateToNumber _this, 0, 365, false];\n};\n\nhint str (date call fnc_daysFromEpoc);\n```","code":["// Calculate days from 1/1/1970\nfnc_daysFromEpoc = \n{\n\tprivate _year = param [0];\n\tprivate _days = 0;\n\tfor \"_i\" from 1970 to _year - 1 do \n\t{\n\t\t_days = _days + round linearConversion [0, 1, dateToNumber [_i, 12, 31, 23, 59], 0, 365, false];\n\t};\n\t_days + linearConversion [0, 1, dateToNumber _this, 0, 365, false];\n};\n\nhint str (date call fnc_daysFromEpoc);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["round","floor","ceil","vectorLinearConversion","bezierInterpolation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"lineBreak","operator":null,"title":"lineBreak","type":"command","url":"https://community.bistudio.com/wiki/lineBreak","revid":321099,"updated":"2022-05-13T13:56:57Z","groups":["Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a structured text containing a line break.","syntaxes":[{"syntax":"lineBreak","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint composeText [\"First line\", lineBreak, \"Second line\"];\n```","code":["hint composeText [\"First line\", lineBreak, \"Second line\"];"]},{"text":"```sqf\nhint str (composeText [lineBreak] == parseText \"<br/>\"); // true\n```","code":["hint str (composeText [lineBreak] == parseText \"<br/>\"); // true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["composeText","parseText","Structured Text","text","image","endl"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: Structured Text","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lineIntersects","operator":null,"title":"lineIntersects","type":"command","url":"https://community.bistudio.com/wiki/lineIntersects","revid":377702,"updated":"2026-01-02T09:03:32Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks for object intersection with a virtual line between two positions. Since Arma 3 v2.20, there is an alternative syntax that does multiple checks in parallel, faster than multiple calls.\n\n> [!NOTE]\n> - Does not work under water.\n> - Max hardcoded distance is 1000m.","syntaxes":[{"syntax":"lineIntersects [begPos, endPos, objIgnore1, objIgnore2]","since":null,"effect":null,"exec":null,"params":[{"name":"begPos","type":"PositionASL","optional":false,"default":null,"description":null,"types":["PositionASL"],"since":null,"text":"begPos: PositionASL"},{"name":"endPos","type":"PositionASL","optional":false,"default":null,"description":null,"types":["PositionASL"],"since":null,"text":"endPos: PositionASL"},{"name":"objIgnore1","type":"Object","optional":true,"default":"objNull","description":"object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object","types":["Object"],"since":null,"text":"objIgnore1: Object - (Optional, default objNull) object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object"},{"name":"objIgnore2","type":"Object","optional":true,"default":"objNull","description":"another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported","types":["Object"],"since":null,"text":"objIgnore2: Object - (Optional, default objNull) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if an intersection happens with an object (not with terrain)","text":"Boolean - true if an intersection happens with an object (not with terrain)"},"form":"unary","operator":null,"left":null,"right":{"text":"[begPos, endPos, objIgnore1, objIgnore2]","types":["Array"]}},{"syntax":"lineIntersects [[element1, element2, ...]]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"elementN","type":"Array with [begPos, endPos, objIgnore1, objIgnore2]","optional":true,"default":"objNull","description":"Array with [begPos, endPos, objIgnore1, objIgnore2]\n- begPos: PositionASL\n- endPos: PositionASL\n- objIgnore1: Object -  object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object\n- objIgnore2: Object - (Optional, default objNull) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported","types":["Array"],"since":null,"text":"elementN: Array with [begPos, endPos, objIgnore1, objIgnore2]\n- begPos: PositionASL\n- endPos: PositionASL\n- objIgnore1: Object - (Optional, default objNull) object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object\n- objIgnore2: Object - (Optional, default objNull) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported"}],"returns":{"type":"Array with [result1, result2, ...]","types":["Array"],"description":"true if an intersection happens with an object (not with terrain) for the Nth element","text":"Array with [result1, result2, ...] - true if an intersection happens with an object (not with terrain) for the Nth element"},"form":"unary","operator":null,"left":null,"right":{"text":"[[element1, element2, ...]]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _hasStraightLineToChopper = lineIntersects [eyePos player, aimPos chopper, player, chopper];\n```","code":["private _hasStraightLineToChopper = lineIntersects [eyePos player, aimPos chopper, player, chopper];"]},{"text":"Alternative syntax to check intersections in parallel:\n\n```sqf\nprivate _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x] };\nprivate _result = lineIntersects [_enemyDataArray];\n```","code":["private _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x] };\nprivate _result = lineIntersects [_enemyDataArray];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsSurfaces","lineIntersectsObjs","lineIntersectsWith","terrainIntersect","terrainIntersectASL","terrainIntersectAtASL","intersect","cursorObject","cursorTarget","checkVisibility"],"notes":[{"user":"Lou Montana","date":"2012-05-31T10:46:00Z","text":"Please note the difference:\n- terrainIntersect\n- terrainIntersectASL\n- lineIntersects\n- lineIntersectsWith\n- lineIntersectsObjs\n- intersect"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lineIntersectsObjs","operator":null,"title":"lineIntersectsObjs","type":"command","url":"https://community.bistudio.com/wiki/lineIntersectsObjs","revid":377627,"updated":"2026-01-02T08:52:08Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.10"}],"since":{"game":"arma3","name":"Arma 3","version":"1.10"},"arma3_since":"1.10","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a list of objects intersected by the line from *begPos* to *endPos*. Since Arma 3 v2.20, there is an alternative syntax that does multiple checks in parallel, faster than multiple calls.","syntaxes":[{"syntax":"lineIntersectsObjs [begPos, endPos, ignoreObj1, ignoreObj2, sortByDistance, flags]","since":null,"effect":null,"exec":null,"params":[{"name":"begPos","type":"PositionASL","optional":false,"default":null,"description":"virtual line start","types":["PositionASL"],"since":null,"text":"begPos: PositionASL - virtual line start"},{"name":"endPos","type":"PositionASL","optional":false,"default":null,"description":"virtual line end","types":["PositionASL"],"since":null,"text":"endPos: PositionASL - virtual line end"},{"name":"ignoreObj1","type":"Object","optional":true,"default":null,"description":"object to ignore","types":["Object"],"since":null,"text":"ignoreObj1: Object - (Optional) - object to ignore"},{"name":"ignoreObj2","type":"Object","optional":true,"default":null,"description":"object to ignore","types":["Object"],"since":null,"text":"ignoreObj2: Object - (Optional) - object to ignore"},{"name":"sortByDistance","type":"Boolean","optional":true,"default":null,"description":"true: furthest object first, closest object last; false: unsorted","types":["Boolean"],"since":null,"text":"sortByDistance: Boolean - (Optional) - true: furthest object first, closest object last; false: unsorted"},{"name":"flags","type":"Number","optional":true,"default":null,"description":"1 - CF_ONLY_WATER\n- 2 - CF_NEAREST_CONTACT\n- 4 - CF_ONLY_STATIC\n- 8 - CF_ONLY_DYNAMIC\n- 16 - CF_FIRST_CONTACT\n- 32 - CF_ALL_OBJECTS (Usable only with CF_FIRST_CONTACT and it will check one contact per object)\nFlags can be combined: 2 + 4 = 6 is CF_NEAREST_OBJECT + CF_ONLY_STATIC","types":["Number"],"since":null,"text":"flags: Number - (Optional)\n- 1 - CF_ONLY_WATER\n- 2 - CF_NEAREST_CONTACT\n- 4 - CF_ONLY_STATIC\n- 8 - CF_ONLY_DYNAMIC\n- 16 - CF_FIRST_CONTACT\n- 32 - CF_ALL_OBJECTS (Usable only with CF_FIRST_CONTACT and it will check one contact per object)\nFlags can be combined: 2 + 4 = 6 is CF_NEAREST_OBJECT + CF_ONLY_STATIC"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"intersecting objects","text":"Array of Objects - intersecting objects"},"form":"unary","operator":null,"left":null,"right":{"text":"[begPos, endPos, ignoreObj1, ignoreObj2, sortByDistance, flags]","types":["Array"]}},{"syntax":"lineIntersectsObjs [[element1, element2, ...]]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"elementN","type":"Array with [begPos, endPos, ignoreObj1, ignoreObj2, sortByDistance, flags]","optional":true,"default":null,"description":"Array with [begPos, endPos, ignoreObj1, ignoreObj2, sortByDistance, flags]\n- begPos: PositionASL - virtual line start\n- endPos: PositionASL - virtual line end\n- ignoreObj1: Object -  - object to ignore\n- ignoreObj2: Object - (Optional) - object to ignore\n- sortByDistance: Boolean - (Optional) - true: furthest object first, closest object last; false: unsorted\n- flags: Number - (Optional)\n  - 1 - CF_ONLY_WATER\n  - 2 - CF_NEAREST_CONTACT\n  - 4 - CF_ONLY_STATIC\n  - 8 - CF_ONLY_DYNAMIC\n  - 16 - CF_FIRST_CONTACT\n  - 32 - CF_ALL_OBJECTS (Usable only with CF_FIRST_CONTACT and it will check one contact per object)\nFlags can be combined: 2 + 4 = 6 is CF_NEAREST_OBJECT + CF_ONLY_STATIC","types":["Array"],"since":null,"text":"elementN: Array with [begPos, endPos, ignoreObj1, ignoreObj2, sortByDistance, flags]\n- begPos: PositionASL - virtual line start\n- endPos: PositionASL - virtual line end\n- ignoreObj1: Object - (Optional) - object to ignore\n- ignoreObj2: Object - (Optional) - object to ignore\n- sortByDistance: Boolean - (Optional) - true: furthest object first, closest object last; false: unsorted\n- flags: Number - (Optional)\n  - 1 - CF_ONLY_WATER\n  - 2 - CF_NEAREST_CONTACT\n  - 4 - CF_ONLY_STATIC\n  - 8 - CF_ONLY_DYNAMIC\n  - 16 - CF_FIRST_CONTACT\n  - 32 - CF_ALL_OBJECTS (Usable only with CF_FIRST_CONTACT and it will check one contact per object)\nFlags can be combined: 2 + 4 = 6 is CF_NEAREST_OBJECT + CF_ONLY_STATIC"}],"returns":{"type":"Array with [result1, result2, ...]","types":["Array"],"description":"each result is an Array of intersecting objects for the Nth element","text":"Array with [result1, result2, ...] - each result is an Array of intersecting objects for the Nth element"},"form":"unary","operator":null,"left":null,"right":{"text":"[[element1, element2, ...]]","types":["Array"]}}],"examples":[{"text":"```sqf\ndata = [];\ndisplayFunction = {\n    {\n        data set [_foreachindex, lineIntersectsObjs [eyePos player, ATLToASL screenToWorld [0.5, 0.5], objNull, objNull, false, _x]];\n    } forEach [1, 2, 4, 8, 16, 32];\n\n    hintSilent format [\"ONLY_WATER: %1\\nNEAREST_CONTACT: %2\\nONLY_STATIC: %3\\nONLY_DYNAMIC: %4\\nFIRST_CONTACT: %5\\nALL_OBJECTS: %6\",\n    data select 0, data select 1, data select 2, data select 3, data select 4, data select 5];\n};\n\n[\"sample_id\", \"onEachFrame\", \"displayFunction\"] call BIS_fnc_addStackedEventHandler;\n// example display objects' array in the middle of the screen sorted by 6 flags\n```","code":["data = [];\ndisplayFunction = {\n\t{\n\t\tdata set [_foreachindex, lineIntersectsObjs [eyePos player, ATLToASL screenToWorld [0.5, 0.5], objNull, objNull, false, _x]];\n\t} forEach [1, 2, 4, 8, 16, 32];\n\n\thintSilent format [\"ONLY_WATER: %1\\nNEAREST_CONTACT: %2\\nONLY_STATIC: %3\\nONLY_DYNAMIC: %4\\nFIRST_CONTACT: %5\\nALL_OBJECTS: %6\",\n\tdata select 0, data select 1, data select 2, data select 3, data select 4, data select 5];\n};\n\n[\"sample_id\", \"onEachFrame\", \"displayFunction\"] call BIS_fnc_addStackedEventHandler;\n// example display objects' array in the middle of the screen sorted by 6 flags"]},{"text":"Alternative syntax to check intersections in parallel:\n\n```sqf\nprivate _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x, true] };\nprivate _result = lineIntersectsObjs [_enemyDataArray];\n```","code":["private _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x, true] };\nprivate _result = lineIntersectsObjs [_enemyDataArray];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsSurfaces","lineIntersectsWith","lineIntersects","terrainIntersectASL","terrainIntersectAtASL","terrainIntersect","intersect","cursorObject","cursorTarget","checkVisibility"],"notes":[{"user":"AgentRev","date":"2016-03-29T06:07:00Z","text":"Distance sorting is relative to object model center, and not intersect position."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 1.10","Scripting Commands"]},{"name":"lineIntersectsSurfaces","operator":null,"title":"lineIntersectsSurfaces","type":"command","url":"https://community.bistudio.com/wiki/lineIntersectsSurfaces","revid":377700,"updated":"2026-01-02T09:03:29Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a list of intersections with surfaces and ground from *begPosASL* to *endPosASL*. Doesn't return intersection with sea surface. Works underwater, unlike lineIntersects. Hardcoded max distance: 5000m.\n\n> [!IMPORTANT]\n> - if *begPosASL* is under the ground and *endPosASL* is above it, the command will only return intersection with the ground, this is an engine limitation and none of the intersectXXX commands will work when initiated from under the ground.\n> - only a single LOD is checked for intersection. LOD2 will only be checked if LOD1 is unavailable.\n\nSince Arma 3 v2.20, there is an alternative syntax that does multiple checks in parallel, faster than multiple calls.","syntaxes":[{"syntax":"lineIntersectsSurfaces [begPosASL, endPosASL, ignoreObj1, ignoreObj2, sortMode, maxResults, LOD1, LOD2, returnUnique]","since":null,"effect":null,"exec":null,"params":[{"name":"begPosASL","type":"PositionASL","optional":false,"default":null,"description":"virtual line start","types":["PositionASL"],"since":null,"text":"begPosASL: PositionASL - virtual line start"},{"name":"endPosASL","type":"PositionASL","optional":false,"default":null,"description":"virtual line end","types":["PositionASL"],"since":null,"text":"endPosASL: PositionASL - virtual line end"},{"name":"ignoreObj1","type":"Object","optional":true,"default":"objNull","description":"first object to ignore","types":["Object"],"since":null,"text":"ignoreObj1: Object - (Optional, default objNull) first object to ignore"},{"name":"ignoreObj2","type":"Object","optional":true,"default":"objNull","description":"second object to ignore","types":["Object"],"since":null,"text":"ignoreObj2: Object - (Optional, default objNull) second object to ignore"},{"name":"sortMode","type":"Boolean","optional":true,"default":"true","description":"true: closest to furthest, false: furthest to closest","types":["Boolean"],"since":null,"text":"sortMode: Boolean -  (Optional, default true) true: closest to furthest, false: furthest to closest"},{"name":"maxResults","type":"Number","optional":true,"default":"1","description":"max results to return. -1 to return every result","types":["Number"],"since":null,"text":"maxResults: Number - (Optional, default 1) max results to return. -1 to return every result"},{"name":"LOD1","type":"String","optional":true,"default":"\"VIEW\"","description":"primary LOD to look for intersection. Can be one of:\n- \"FIRE\"\n- \"VIEW\"\n- \"GEOM\"\n- \"IFIRE\" - (\"I\" stands for Indirect, *almost* identical to \"FIRE\")\n- \"NONE\"\n- Arma 3 v2.02 \"PHYSX\" - PhysX geometry LOD\n- Arma 3 v2.08 \"ROADWAY\" - only works from the top","types":["String"],"since":"arma3 1.52","text":"LOD1: String - (Optional, default \"VIEW\") primary LOD to look for intersection. Can be one of:\n- \"FIRE\"\n- \"VIEW\"\n- \"GEOM\"\n- \"IFIRE\" - (\"I\" stands for Indirect, *almost* identical to \"FIRE\")\n- \"NONE\"\n- Arma 3 v2.02 \"PHYSX\" - PhysX geometry LOD\n- Arma 3 v2.08 \"ROADWAY\" - only works from the top"},{"name":"LOD2","type":"String","optional":true,"default":"\"FIRE\"","description":"secondary LOD to look for intersection. See *LOD1* for possible values","types":["String"],"since":"arma3 1.52","text":"LOD2: String - (Optional, default \"FIRE\") secondary LOD to look for intersection. See *LOD1* for possible values"},{"name":"returnUnique","type":"Boolean","optional":true,"default":"true","description":"when false, all intersections in the same object are included, otherwise only the first one","types":["Boolean"],"since":"arma3 1.70","text":"returnUnique: Boolean - (Optional, default true) when false, all intersections in the same object are included, otherwise only the first one"}],"returns":{"type":"Array of Arrays with [intersectPosASL, surfaceNormal, intersectObj, parentObject, selectionNames, pathToBisurf]","types":["Array"],"description":"intersectPosASL: PositionASL - the actual position where line intersects surface - surfaceNormal: Vector - a normal to the intersected surface - intersectObject: Object - the object the surface belongs to (could be proxy object) - objNull if terrain - parentObject: Object - the object proxy object belongs to (not always the same as intersect object) - objNull if terrain - Arma 3 v2.10 selectionNames: Array of Strings - Names of the intersected selections (bones). Returns `[]` if there is no intersection with a selection. - Arma 3 v2.10 pathToBisurf: String - path to intersected surface properties (.bisurf) file. Returns `\"\"` if surface has no special properties. Terrain surface properties begin with `1.`, and the surface properties are defined in `CfgSurfaces`. For example, if it returns `1. GdtVRsurface01`, properties are defined in: `configFile >> \"CfgSurfaces\" >> \"GdtVRsurface01\"`","text":"Array of Arrays with [intersectPosASL, surfaceNormal, intersectObj, parentObject, selectionNames, pathToBisurf]\n- intersectPosASL: PositionASL - the actual position where line intersects surface\n- surfaceNormal: Vector - a normal to the intersected surface\n- intersectObject: Object - the object the surface belongs to (could be proxy object) - objNull if terrain\n- parentObject: Object - the object proxy object belongs to (not always the same as intersect object) - objNull if terrain\n- Arma 3 v2.10 selectionNames: Array of Strings - Names of the intersected selections (bones). Returns `[]` if there is no intersection with a selection.\n- Arma 3 v2.10 pathToBisurf: String - path to intersected surface properties (.bisurf) file. Returns `\"\"` if surface has no special properties. Terrain surface properties begin with `1.`, and the surface properties are defined in `CfgSurfaces`. For example, if it returns `1. GdtVRsurface01`, properties are defined in: `configFile >> \"CfgSurfaces\" >> \"GdtVRsurface01\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"[begPosASL, endPosASL, ignoreObj1, ignoreObj2, sortMode, maxResults, LOD1, LOD2, returnUnique]","types":["Array"]}},{"syntax":"lineIntersectsSurfaces [[element1, element2, ...]]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"elementN","type":null,"optional":true,"default":"objNull","description":"Array with [begPosASL, endPosASL, ignoreObj1, ignoreObj2, sortMode, maxResults, LOD1, LOD2, returnUnique]\n- begPosASL: PositionASL - virtual line start\n- endPosASL: PositionASL - virtual line end\n- ignoreObj1: Object -  first object to ignore\n- ignoreObj2: Object - (Optional, default objNull) second object to ignore\n- sortMode: Boolean -  (Optional, default true) true: closest to furthest, false: furthest to closest\n- maxResults: Number - (Optional, default 1) max results to return. -1 to return every result\n- LOD1: String - (Optional, default \"VIEW\") primary LOD to look for intersection. Can be one of:\n  - \"FIRE\"\n  - \"VIEW\"\n  - \"GEOM\"\n  - \"IFIRE\" - (\"I\" stands for Indirect, *almost* identical to \"FIRE\")\n  - \"NONE\"\n  - \"PHYSX\" - PhysX geometry LOD\n  - \"ROADWAY\" - only works from the top\n- LOD2: String - (Optional, default \"FIRE\") secondary LOD to look for intersection. See *LOD1* for possible values\n- returnUnique: Boolean - (Optional, default true) when false, all intersections in the same object are included, otherwise only the first one","types":["Array"],"since":null,"text":"elementN: Array with [begPosASL, endPosASL, ignoreObj1, ignoreObj2, sortMode, maxResults, LOD1, LOD2, returnUnique]\n- begPosASL: PositionASL - virtual line start\n- endPosASL: PositionASL - virtual line end\n- ignoreObj1: Object - (Optional, default objNull) first object to ignore\n- ignoreObj2: Object - (Optional, default objNull) second object to ignore\n- sortMode: Boolean -  (Optional, default true) true: closest to furthest, false: furthest to closest\n- maxResults: Number - (Optional, default 1) max results to return. -1 to return every result\n- LOD1: String - (Optional, default \"VIEW\") primary LOD to look for intersection. Can be one of:\n  - \"FIRE\"\n  - \"VIEW\"\n  - \"GEOM\"\n  - \"IFIRE\" - (\"I\" stands for Indirect, *almost* identical to \"FIRE\")\n  - \"NONE\"\n  - \"PHYSX\" - PhysX geometry LOD\n  - \"ROADWAY\" - only works from the top\n- LOD2: String - (Optional, default \"FIRE\") secondary LOD to look for intersection. See *LOD1* for possible values\n- returnUnique: Boolean - (Optional, default true) when false, all intersections in the same object are included, otherwise only the first one"}],"returns":{"type":"Array of Arrays with [intersectPosASL, surfaceNormal, intersectObj, parentObject, selectionNames, pathToBisurf]","types":["Array"],"description":"intersectPosASL: PositionASL - the actual position where line intersects surface - surfaceNormal: Vector - a normal to the intersected surface - intersectObject: Object - the object the surface belongs to (could be proxy object) - objNull if terrain - parentObject: Object - the object proxy object belongs to (not always the same as intersect object) - objNull if terrain - selectionNames: Array of Strings - Names of the intersected selections (bones). Returns `[]` if there is no intersection with a selection. - pathToBisurf: String - path to intersected surface properties (.bisurf) file. Returns `\"\"` if surface has no special properties. Terrain surface properties begin with `1.`, and the surface properties are defined in `CfgSurfaces`. For example, if it returns `1. GdtVRsurface01`, properties are defined in: `configFile >> \"CfgSurfaces\" >> \"GdtVRsurface01\"`","text":"Array of Arrays with [intersectPosASL, surfaceNormal, intersectObj, parentObject, selectionNames, pathToBisurf]\n- intersectPosASL: PositionASL - the actual position where line intersects surface\n- surfaceNormal: Vector - a normal to the intersected surface\n- intersectObject: Object - the object the surface belongs to (could be proxy object) - objNull if terrain\n- parentObject: Object - the object proxy object belongs to (not always the same as intersect object) - objNull if terrain\n- selectionNames: Array of Strings - Names of the intersected selections (bones). Returns `[]` if there is no intersection with a selection.\n- pathToBisurf: String - path to intersected surface properties (.bisurf) file. Returns `\"\"` if surface has no special properties. Terrain surface properties begin with `1.`, and the surface properties are defined in `CfgSurfaces`. For example, if it returns `1. GdtVRsurface01`, properties are defined in: `configFile >> \"CfgSurfaces\" >> \"GdtVRsurface01\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"[[element1, element2, ...]]","types":["Array"]}}],"examples":[{"text":"```sqf\n_intersections = lineIntersectsSurfaces [eyePos player, aimPos chopper, player, chopper, true, -1];\n```","code":["_intersections = lineIntersectsSurfaces [eyePos player, aimPos chopper, player, chopper, true, -1];"]},{"text":"```sqf\narrow = \"Sign_Arrow_F\" createVehicle [0,0,0];\nonEachFrame {\n    _ins = lineIntersectsSurfaces [\n        AGLToASL positionCameraToWorld [0,0,0], \n        AGLToASL positionCameraToWorld [0,0,1000], \n        player\n    ];\n    if (count _ins == 0) exitWith { arrow setPosASL [0,0,0] };\n    arrow setPosASL (_ins select 0 select 0);\n    arrow setVectorUp (_ins select 0 select 1);\n    hintSilent str _ins;\n};\n```","code":["arrow = \"Sign_Arrow_F\" createVehicle [0,0,0];\nonEachFrame {\n\t_ins = lineIntersectsSurfaces [\n\t\tAGLToASL positionCameraToWorld [0,0,0], \n\t\tAGLToASL positionCameraToWorld [0,0,1000], \n\t\tplayer\n\t];\n\tif (count _ins == 0) exitWith { arrow setPosASL [0,0,0] };\n\tarrow setPosASL (_ins select 0 select 0);\n\tarrow setVectorUp (_ins select 0 select 1);\n\thintSilent str _ins;\n};"]},{"text":"This should detect glass windows and wire fences (since Arma 3 v1.52):\n\n```sqf\nwirefence = \"Land_New_WiredFence_5m_F\" createVehicle position player;\narrow = \"Sign_Arrow_F\" createVehicle [0,0,0];\nonEachFrame {\n    _ins = lineIntersectsSurfaces [\n        AGLToASL positionCameraToWorld [0,0,0], \n        AGLToASL positionCameraToWorld [0,0,1000], \n        player,\n        objNull,\n        true,\n        1,\n        \"GEOM\",\n        \"NONE\"\n    ];\n    if (count _ins == 0) exitWith { arrow setPosASL [0,0,0] };\n    arrow setPosASL (_ins select 0 select 0);\n    arrow setVectorUp (_ins select 0 select 1);\n    hintSilent str _ins;\n};\n```","code":["wirefence = \"Land_New_WiredFence_5m_F\" createVehicle position player;\narrow = \"Sign_Arrow_F\" createVehicle [0,0,0];\nonEachFrame {\n\t_ins = lineIntersectsSurfaces [\n\t\tAGLToASL positionCameraToWorld [0,0,0], \n\t\tAGLToASL positionCameraToWorld [0,0,1000], \n\t\tplayer,\n\t\tobjNull,\n\t\ttrue,\n\t\t1,\n\t\t\"GEOM\",\n\t\t\"NONE\"\n\t];\n\tif (count _ins == 0) exitWith { arrow setPosASL [0,0,0] };\n\tarrow setPosASL (_ins select 0 select 0);\n\tarrow setVectorUp (_ins select 0 select 1);\n\thintSilent str _ins;\n};"]},{"text":"Alternative syntax to check intersections in parallel. Will draw a redline to the first intersecting object between the player and unit:\n\n```sqf\nprivate _handle = addMissionEventHandler [\"Draw3D\", {\n    private _enemies = units opfor;\n    private _enemyDataArray = _enemies apply { [eyePos player, eyePos _x, player, _x] };\n    \n    private _intersections = lineIntersectsSurfaces [_enemyDataArray];\n    {\n        // No intersections found, draw green '+' icon at unit\n        if (_x isEqualTo []) then {\n            drawIcon3D [\n                \"\\a3\\ui_f\\data\\gui\\cfg\\cursors\\add_gs.paa\",\n                [0, 1, 0, 1],\n                ASLToAGL (eyePos (_enemies#_forEachIndex)),\n                0.5, 0.5, 0,\n                str (_enemies#_forEachIndex)\n            ];\n        } else {\n            private _firstIntersection = _x#0;\n            // Draw red line and '+' icon to first intersecting object\n            drawIcon3D [\n                \"\\a3\\ui_f\\data\\gui\\cfg\\cursors\\add_gs.paa\",\n                [1, 0, 0, 1],\n                ASLToAGL (_firstIntersection#0),\n                0.5, 0.5, 0,\n                str (_enemies#_forEachIndex) + \"- Blocked by \" + str (_firstIntersection#2)\n            ];\n            drawLine3D [\n                ASLToAGL (eyePos player),\n                ASLToAGL (_firstIntersection#0),\n                [1, 0, 0, 1],\n                5\n            ];\n        };\n    } forEach _intersections;\n}];\n```","code":["private _handle = addMissionEventHandler [\"Draw3D\", {\n\tprivate _enemies = units opfor;\n\tprivate _enemyDataArray = _enemies apply { [eyePos player, eyePos _x, player, _x] };\n\t\n\tprivate _intersections = lineIntersectsSurfaces [_enemyDataArray];\n\t{\n\t\t// No intersections found, draw green '+' icon at unit\n\t\tif (_x isEqualTo []) then {\n\t\t\tdrawIcon3D [\n\t\t\t\t\"\\a3\\ui_f\\data\\gui\\cfg\\cursors\\add_gs.paa\",\n\t\t\t\t[0, 1, 0, 1],\n\t\t\t\tASLToAGL (eyePos (_enemies#_forEachIndex)),\n\t\t\t\t0.5, 0.5, 0,\n\t\t\t\tstr (_enemies#_forEachIndex)\n\t\t\t];\n\t\t} else {\n\t\t\tprivate _firstIntersection = _x#0;\n\t\t\t// Draw red line and '+' icon to first intersecting object\n\t\t\tdrawIcon3D [\n\t\t\t\t\"\\a3\\ui_f\\data\\gui\\cfg\\cursors\\add_gs.paa\",\n\t\t\t\t[1, 0, 0, 1],\n\t\t\t\tASLToAGL (_firstIntersection#0),\n\t\t\t\t0.5, 0.5, 0,\n\t\t\t\tstr (_enemies#_forEachIndex) + \"- Blocked by \" + str (_firstIntersection#2)\n\t\t\t];\n\t\t\tdrawLine3D [\n\t\t\t\tASLToAGL (eyePos player),\n\t\t\t\tASLToAGL (_firstIntersection#0),\n\t\t\t\t[1, 0, 0, 1],\n\t\t\t\t5\n\t\t\t];\n\t\t};\n\t} forEach _intersections;\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsObjs","lineIntersectsWith","lineIntersects","terrainIntersectASL","terrainIntersectAtASL","terrainIntersect","intersect","cursorObject","cursorTarget","checkVisibility"],"notes":[{"user":"Killzone_Kid","date":"2015-08-27T12:44:00Z","text":"Fast check if the player is in a house:\n\n```sqf\nKK_fnc_inHouse = {\n    lineIntersectsSurfaces [\n        getPosWorld _this, \n        getPosWorld _this vectorAdd [0, 0, 50], \n        _this, objNull, true, 1, \"GEOM\", \"NONE\"\n    ] select 0 params [\"\",\"\",\"\",\"_house\"];\n    if (_house isKindOf \"House\") exitWith { true };\n    false\n};\nonEachFrame { hintSilent str (player call KK_fnc_inHouse) };\n```"},{"user":"Pierre MGI","date":"2016-01-30T20:10:00Z","text":"This command is useful to place weaponholder (and then spawned weapons) on floor of houses, correcting  the spawn position (can_collide) to intersect with floor:\n\n```sqf\nMGI_fnc_setPosAGLS = {\n    params [\"_obj\", \"_pos\"];\n    _wh_pos = getPosASL _obj;\n\n    _pos set [2, (ATLToASL _pos select 2) - 10];\n    _ins = lineIntersectsSurfaces [_wh_pos, _pos,_obj, objNull, true, 1, \"VIEW\", \"FIRE\"];\n    _surface_distance = if (count _ins > 0) then [{ (_ins select 0 select 0) distance _wh_pos }, { 0 }];\n    _wh_pos set [2, (getPosASL _obj select 2) - (_surface_distance)];\n    _weaponholder setPosASL _wh_pos;\n};\n```\n\nAfter the position (_pos) obtained in BIS_fnc_buidingPositions array:\n\n```sqf\nprivate _weaponHolder = createVehicle [\"groundWeaponHolder\", _pos, [], 0, \"CAN_COLLIDE\"];\n[_weaponHolder, _pos] call MGI_fnc_setPosAGLS;\n```\n\nThen fill your weapon holder."},{"user":"Tankbuster","date":"2024-01-06T15:41:15Z","text":"Note that dome_big and dome_small objects have glass roof panels which this function can't see if it intersects those windows"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"lineIntersectsWith","operator":null,"title":"lineIntersectsWith","type":"command","url":"https://community.bistudio.com/wiki/lineIntersectsWith","revid":378359,"updated":"2026-04-03T15:54:33Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns objects intersecting with the virtual line from *begPos* to *endPos*. By default, the resulting array of intersecting objects is unsorted (see *sortByDistance*).\n\n> [!NOTE]\n> - Does not work under water.\n> - Max hardcoded distance is 1000m.\n\nSince Arma 3 v2.20, there is an alternative syntax that does multiple checks in parallel, faster than multiple calls.","syntaxes":[{"syntax":"lineIntersectsWith [begPos, endPos, objIgnore1, objIgnore2, sortByDistance]","since":null,"effect":null,"exec":null,"params":[{"name":"begPos","type":"PositionASL","optional":false,"default":null,"description":"virtual line start","types":["PositionASL"],"since":null,"text":"begPos: PositionASL - virtual line start"},{"name":"endPos","type":"PositionASL","optional":false,"default":null,"description":"virtual line end","types":["PositionASL"],"since":null,"text":"endPos: PositionASL - virtual line end"},{"name":"objIgnore1","type":"Object","optional":true,"default":null,"description":"object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object.","types":["Object"],"since":null,"text":"objIgnore1: Object - (Optional) object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object."},{"name":"objIgnore2","type":"Object","optional":true,"default":null,"description":"another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported","types":["Object"],"since":null,"text":"objIgnore2: Object - (Optional) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported"},{"name":"sortByDistance","type":"Boolean","optional":true,"default":null,"description":"true: sort by **desc**ending distance (furthermost object first, closest object last); false: unsorted","types":["Boolean"],"since":null,"text":"sortByDistance: Boolean - (Optional) true: sort by **desc**ending distance (furthermost object first, closest object last); false: unsorted"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"intersecting objects","text":"Array of Objects - intersecting objects"},"form":"unary","operator":null,"left":null,"right":{"text":"[begPos, endPos, objIgnore1, objIgnore2, sortByDistance]","types":["Array"]}},{"syntax":"lineIntersectsWith [[element1, element2, ...]]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"elementN","type":"Array with [begPos, endPos, objIgnore1, objIgnore2, sortByDistance]","optional":true,"default":null,"description":"Array with [begPos, endPos, objIgnore1, objIgnore2, sortByDistance]\n- begPos: PositionASL - virtual line start\n- endPos: PositionASL - virtual line end\n- objIgnore1: Object -  object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object.\n- objIgnore2: Object - (Optional) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported\n- sortByDistance: Boolean - (Optional) true: sort by **desc**ending distance (furthermost object first, closest object last); false: unsorted","types":["Array"],"since":null,"text":"elementN: Array with [begPos, endPos, objIgnore1, objIgnore2, sortByDistance]\n- begPos: PositionASL - virtual line start\n- endPos: PositionASL - virtual line end\n- objIgnore1: Object - (Optional) object to ignore. When testing intersections from an object/unit/vehicle, pass that object here to prevent intersections inside of the object.\n- objIgnore2: Object - (Optional) another object to ignore. When testing intersections of a line between two objects, pass the second object here to prevent intersections inside of it being reported\n- sortByDistance: Boolean - (Optional) true: sort by **desc**ending distance (furthermost object first, closest object last); false: unsorted"}],"returns":{"type":"Array with [result1, result2, ...]","types":["Array"],"description":"each result is an Array of intersecting objects for the Nth element","text":"Array with [result1, result2, ...] - each result is an Array of intersecting objects for the Nth element"},"form":"unary","operator":null,"left":null,"right":{"text":"[[element1, element2, ...]]","types":["Array"]}}],"examples":[{"text":"```sqf\n_objects = lineIntersectsWith [eyePos player, AGLToASL screenToWorld [0.5, 0.5]];\n```","code":["_objects = lineIntersectsWith [eyePos player, AGLToASL screenToWorld [0.5, 0.5]];"]},{"text":"Sort by distance:\n\n```sqf\n_objects = lineIntersectsWith [eyePos player, AGLToASL screenToWorld [0.5, 0.5], objNull, objNull, true];\n```","code":["_objects = lineIntersectsWith [eyePos player, AGLToASL screenToWorld [0.5, 0.5], objNull, objNull, true];"]},{"text":"Ignore objects:\n\n```sqf\n_objects = lineIntersectsWith [eyePos player, aimPos chopper, player, chopper];\n```","code":["_objects = lineIntersectsWith [eyePos player, aimPos chopper, player, chopper];"]},{"text":"Alternative syntax to check intersections in parallel:\n\n```sqf\nprivate _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x, true] };\nprivate _result = lineIntersectsWith [_enemyDataArray];\n```","code":["private _enemies = units opfor;\nprivate _enemyDataArray = _enemies apply { [eyePos player, aimPos _x, player, _x, true] };\nprivate _result = lineIntersectsWith [_enemyDataArray];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lineIntersectsSurfaces","lineIntersectsObjs","lineIntersects","terrainIntersect","terrainIntersectASL","terrainIntersectAtASL","intersect","cursorObject","cursorTarget","checkVisibility"],"notes":[{"user":"Lou Montana","date":"2012-05-31T10:50:00Z","text":"Please note the difference :\n- terrainIntersect\n- terrainIntersectASL\n- lineIntersect***s***\n- lineIntersect***s***With\n- lineIntersect***s***Objs\n- intersect"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"linkItem","operator":null,"title":"linkItem","type":"command","url":"https://community.bistudio.com/wiki/linkItem","revid":369226,"updated":"2024-09-03T10:34:55Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Create and assign item to the correct slot. If there is an item in the targeted slot, it gets replaced. See also assignItem.","syntaxes":[{"syntax":"unit linkItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nbluforUnit linkItem \"NVGoggles\";\nopforUnit linkItem \"NVGoggles_OPFOR\";\nindependentUnit linkItem \"NVGoggles_INDEP\";\n```","code":["bluforUnit linkItem \"NVGoggles\";\nopforUnit linkItem \"NVGoggles_OPFOR\";\nindependentUnit linkItem \"NVGoggles_INDEP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unlinkItem","addItem","assignItem","removeItem","unassignItem","assignedItems","removeAllAssignedItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"list","operator":null,"title":"list","type":"command","url":"https://community.bistudio.com/wiki/list","revid":378370,"updated":"2026-04-03T16:47:58Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"List of units that would activate given Trigger.\n\nIt returns nothing before the simulation started, i.e. in (undelayed) init.sqf files. Returns a **pointer** to the trigger's list after the simulation started.\n\nSince this is just a *reference* this means that the value in your local variable will change as the content of the trigger area changes.\nTo permanently copy the returned list to a different variable, use `_mylist = +(list triggerOne)`.\n\nThe second example can be used inside the trigger (in that case, no need to name your trigger).\n\nThe list returned for trigger of type \"Not present\" is the same as that returned for type \"present\".\n\n> [!IMPORTANT]\n> While the command can query any trigger, local or remote, the result will be only for the trigger condition set on the local client. See createTrigger for more info.","syntaxes":[{"syntax":"list trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Nothing or Array of Objects","types":["Nothing","Array","Object"],"description":null,"text":"Nothing or Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_triggerList = list _triggerOne;\n```","code":["_triggerList = list _triggerOne;"]},{"text":"```sqf\nhint format [\"%1\", thisList];\n```","code":["hint format [\"%1\", thisList];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerActivation","createTrigger","thisList"],"notes":[{"user":"TeaCup","date":"2013-03-06T14:15:00Z","text":"Calling list immediately after creating a trigger via createTrigger (and setting up activation, area, statements, timeout, etc..), will return `<null>` instead of an array. It seems the trigger needs about 1 second to initialise, after which it will behave as expected: returning an array of all the objects inside the trigger (the ones matching the criteria), or an empty array."},{"user":"7erra","date":"2021-01-06T01:58:00Z","text":"The resulting array is not modifiable. Any array related commands, that modify the original array, will fail with the error message: `Error Reserved variable in expression`."}],"categories":[]},{"name":"listObjects","operator":null,"title":"listObjects","type":"command","url":"https://community.bistudio.com/wiki/listObjects","revid":363269,"updated":"2024-03-26T10:51:38Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the list of all objects of given type.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map listObjects type","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"listRemoteTargets","operator":null,"title":"listRemoteTargets","type":"command","url":"https://community.bistudio.com/wiki/listRemoteTargets","revid":377652,"updated":"2026-01-02T09:01:59Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return list of datalink targets and time for which they will be/were known.","syntaxes":[{"syntax":"listRemoteTargets side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Array of Arrays with [remoteTarget, lastDetected]","types":["Array"],"description":"remoteTarget: Object - lastDetected: Number","text":"Array of Arrays with [remoteTarget, lastDetected]\n- remoteTarget: Object\n- lastDetected: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\nlistRemoteTargets opfor;\n```","code":["listRemoteTargets opfor;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["listVehicleSensors","enableVehicleSensor","isVehicleRadarOn","isVehicleSensorEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"listVehicleSensors","operator":null,"title":"listVehicleSensors","type":"command","url":"https://community.bistudio.com/wiki/listVehicleSensors","revid":363161,"updated":"2024-03-24T17:31:12Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of the sensors in the given vehicle's config (configFile >> \"CfgVehicles\" >> *vehicle* >> \"Components\" >> \"SensorsManagerComponent\" >> \"Components\").","syntaxes":[{"syntax":"listVehicleSensors vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":null,"types":["Array","String","enableVehicleSensor","isVehicleSensorEnabled"],"description":null,"text":"Array of Arrays of Strings format [className, componentType] (use *className* for enableVehicleSensor / isVehicleSensorEnabled)"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _sensors = listVehicleSensors _v44blackfish;\nhint str _sensors;\n/*\n    e.g for a V44 Blackfish:\n    [\n        [\"IRSensorComponent\", \"IRSensorComponent\"],\n        [\"VisualSensorComponent\", \"VisualSensorComponent\"],\n        [\"ActiveRadarSensorComponent\", \"ActiveRadarSensorComponent\"],\n        [\"PassiveRadarSensorComponent\", \"PassiveRadarSensorComponent\"],\n        [\"LaserSensorComponent\", \"LaserSensorComponent\"],\n        [\"NVSensorComponent\", \"NVSensorComponent\"]\n    ]\n*/\n```","code":["private _sensors = listVehicleSensors _v44blackfish;\nhint str _sensors;\n/*\n\te.g for a V44 Blackfish:\n\t[\n\t\t[\"IRSensorComponent\", \"IRSensorComponent\"],\n\t\t[\"VisualSensorComponent\", \"VisualSensorComponent\"],\n\t\t[\"ActiveRadarSensorComponent\", \"ActiveRadarSensorComponent\"],\n\t\t[\"PassiveRadarSensorComponent\", \"PassiveRadarSensorComponent\"],\n\t\t[\"LaserSensorComponent\", \"LaserSensorComponent\"],\n\t\t[\"NVSensorComponent\", \"NVSensorComponent\"]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["listRemoteTargets","enableVehicleSensor","isVehicleRadarOn","isVehicleSensorEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"ln","operator":null,"title":"ln","type":"command","url":"https://community.bistudio.com/wiki/ln","revid":369410,"updated":"2024-09-03T18:43:25Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the natural logarithm of x.","syntaxes":[{"syntax":"ln x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_nlog = ln 10;\n```","code":["_nlog = ln 10;"]},{"text":"```sqf\n_euler = exp 1;\n_euler = ln _euler; // Returns 1\n```","code":["_euler = exp 1;\n_euler = ln _euler; // Returns 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands"],"notes":[],"categories":[]},{"name":"lnbAddArray","operator":null,"title":"lnbAddArray","type":"command","url":"https://community.bistudio.com/wiki/lnbAddArray","revid":378641,"updated":"2026-05-16T15:03:10Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds list of rows of strings.","syntaxes":[{"syntax":"lnbAddArray [ctrl, arrayOfTextAndValues]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Number, Control since Arma 3 v2.22","optional":false,"default":null,"description":null,"types":["Number","Control"],"since":null,"text":"ctrl: Number, Control since Arma 3 v2.22"},{"name":"arrayOfTextAndValues","type":"Array of Arrays format [[text], [value], [data]]:","optional":false,"default":null,"description":"Array of Arrays format [[text], [value], [data]]:\n- text: String\n- value: Number\n- data: String","types":["Array"],"since":null,"text":"arrayOfTextAndValues: Array of Arrays format [[text], [value], [data]]:\n- text: String\n- value: Number\n- data: String"}],"returns":{"type":"Number","types":["Number"],"description":"index","text":"Number - index"},"form":"unary","operator":null,"left":null,"right":{"text":"[ctrl, arrayOfTextAndValues]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbAddArray [\n    102,\n    [\n        [\n            [\"#1\"],\n            [1],\n            [\"#1\"]\n        ],\n        [\n            [\"#2\"],\n            [2],\n            [\"#2\"]\n        ]\n    ]\n];\n```","code":["lnbAddArray [\n\t102,\n\t[\n\t\t[\n\t\t\t[\"#1\"],\n\t\t\t[1],\n\t\t\t[\"#1\"]\n\t\t],\n\t\t[\n\t\t\t[\"#2\"],\n\t\t\t[2],\n\t\t\t[\"#2\"]\n\t\t]\n\t]\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbAddColumn","operator":null,"title":"lnbAddColumn","type":"command","url":"https://community.bistudio.com/wiki/lnbAddColumn","revid":378410,"updated":"2026-04-04T08:30:26Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds a column at given position.","syntaxes":[{"syntax":"control lnbAddColumn position","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"position","type":"Number","optional":false,"default":null,"description":"position of the new column where 0 means all the way to the left and 1 all the way to the right of the control","types":["Number"],"since":null,"text":"position: Number - position of the new column where 0 means all the way to the left and 1 all the way to the right of the control"}],"returns":{"type":"Number or Nothing","types":["Number","Nothing"],"description":"returns the zero based index of the new column","text":"Number or Nothing - returns the zero based index of the new column"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"position","types":["Number"]}},{"syntax":"lnbAddColumn [controlOrIdc, position]","since":null,"effect":null,"exec":null,"params":[{"name":"controlOrIdc","type":"Control or Number","optional":false,"default":null,"description":"control or the idc of the control","types":["Control","Number"],"since":null,"text":"controlOrIdc: Control or Number - control or the idc of the control"},{"name":"position","type":"Number","optional":false,"default":null,"description":"position of the new column where 0 means all the way to the left and 1 all the way to the right of the control","types":["Number"],"since":null,"text":"position: Number - position of the new column where 0 means all the way to the left and 1 all the way to the right of the control"}],"returns":{"type":"Number or Nothing","types":["Number","Nothing"],"description":"returns the zero based index of the new column","text":"Number or Nothing - returns the zero based index of the new column"},"form":"unary","operator":null,"left":null,"right":{"text":"[controlOrIdc, position]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbAddColumn 0.8;\n```","code":["_ctrl lnbAddColumn 0.8;"]},{"text":"```sqf\nlnbAddColumn [105, 0.8];\n```","code":["lnbAddColumn [105, 0.8];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddRow","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbSetColumnsPos"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbAddRow","operator":null,"title":"lnbAddRow","type":"command","url":"https://community.bistudio.com/wiki/lnbAddRow","revid":378642,"updated":"2026-05-16T15:05:17Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds a row of strings.","syntaxes":[{"syntax":"lnbAddRow [ctrl, data]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Number, Control since Arma 3 v2.22","optional":false,"default":null,"description":null,"types":["Number","Control"],"since":null,"text":"ctrl: Number, Control since Arma 3 v2.22"},{"name":"data","type":"Array of Strings","optional":false,"default":null,"description":null,"types":["Array","String"],"since":null,"text":"data: Array of Strings"}],"returns":{"type":"Number","types":["Number"],"description":"row index","text":"Number - row index"},"form":"unary","operator":null,"left":null,"right":{"text":"[ctrl, data]","types":["Array"]}},{"syntax":"ctrl lnbAddRow data","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"data","type":"Array of Strings","optional":false,"default":null,"description":null,"types":["Array","String"],"since":null,"text":"data: Array of Strings"}],"returns":{"type":"Number","types":["Number"],"description":"row index","text":"Number - row index"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"data","types":["Array","String"]}}],"examples":[{"text":"```sqf\nlnbAddRow [1, [\"COL1\", \"COL2\"]];\n```","code":["lnbAddRow [1, [\"COL1\", \"COL2\"]];"]},{"text":"```sqf\n_ctrl lnbAddRow [\"COL1\", \"COL2\"];\n```","code":["_ctrl lnbAddRow [\"COL1\", \"COL2\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbClear","operator":null,"title":"lnbClear","type":"command","url":"https://community.bistudio.com/wiki/lnbClear","revid":309988,"updated":"2022-05-05T12:17:03Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Clears all items in the given listbox or combobox.","syntaxes":[{"syntax":"lnbClear idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lnbClear ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nlnbClear _ctrl;\n```","code":["lnbClear _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbColor","operator":null,"title":"lnbColor","type":"command","url":"https://community.bistudio.com/wiki/lnbColor","revid":377372,"updated":"2026-01-02T06:42:22Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the text color of the item with the given position of the 2D listbox. The color is returned in format Color (RGBA).","syntaxes":[{"syntax":"lnbColor [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"control lnbColor [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbColor [0,0];\n```","code":["_ctrl lnbColor [0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbColorRight","operator":null,"title":"lnbColorRight","type":"command","url":"https://community.bistudio.com/wiki/lnbColorRight","revid":377818,"updated":"2026-01-03T04:15:56Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the right color of given row.","syntaxes":[{"syntax":"lnbColorRight [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"ctrl lnbColorRight [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"Color (RGBA)","types":["Color"],"description":null,"text":"Color (RGBA)"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _result = _control lnbColorRight [0, 0];\n```","code":["private _result = _control lnbColorRight [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetColor","lnbSetColorRight","lnbColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbCurSelRow","operator":null,"title":"lnbCurSelRow","type":"command","url":"https://community.bistudio.com/wiki/lnbCurSelRow","revid":309967,"updated":"2022-05-05T12:17:01Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the index of the selected row id 2D listbox.","syntaxes":[{"syntax":"lnbCurSelRow idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"lnbCurSelRow ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nlnbCurSelRow _ctrl;\n```","code":["lnbCurSelRow _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbData","operator":null,"title":"lnbData","type":"command","url":"https://community.bistudio.com/wiki/lnbData","revid":320643,"updated":"2022-05-13T09:38:23Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the additional text (invisible) in an item with the given position of the 2D listbox.","syntaxes":[{"syntax":"lnbData [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number or Control","optional":false,"default":null,"description":null,"types":["Number","Control"],"since":null,"text":"idc: Number or Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"ctrl lnbData [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbData [lnbCurSelRow _ctrl,0]; // \"#1\"\n```","code":["_ctrl lnbData [lnbCurSelRow _ctrl,0]; // \"#1\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbDeleteColumn","operator":null,"title":"lnbDeleteColumn","type":"command","url":"https://community.bistudio.com/wiki/lnbDeleteColumn","revid":310134,"updated":"2022-05-05T12:25:45Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Removes column with given index from ListNBox control.","syntaxes":[{"syntax":"lnbDeleteColumn [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"ctrl lnbDeleteColumn index","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl lnbDeleteColumn 1;\n```","code":["_ctrl lnbDeleteColumn 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbDeleteRow","operator":null,"title":"lnbDeleteRow","type":"command","url":"https://community.bistudio.com/wiki/lnbDeleteRow","revid":310126,"updated":"2022-05-05T12:25:40Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes row with the given index from the given listbox or combobox.","syntaxes":[{"syntax":"_ctrl lnbDeleteRow row","since":null,"effect":null,"exec":null,"params":[{"name":"_ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"_ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"_ctrl","types":["Control"]},"right":{"text":"row","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrl lnbDeleteRow 1;\n```","code":["_ctrl lnbDeleteRow 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbGetColumnsPosition","operator":null,"title":"lnbGetColumnsPosition","type":"command","url":"https://community.bistudio.com/wiki/lnbGetColumnsPosition","revid":377147,"updated":"2026-01-01T10:34:03Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns relative screen X of ListNBox control columns position [0.1,0.3,0.6...]. Use lnbSetColumnsPos to set positions.","syntaxes":[{"syntax":"lnbGetColumnsPosition _ctrl","since":null,"effect":null,"exec":null,"params":[{"name":"_ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"_ctrl: Control"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"_ctrl","types":["Control"]}}],"examples":[{"text":"```sqf\nlnbGetColumnsPosition _ctrl;\n```","code":["lnbGetColumnsPosition _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbPicture","operator":null,"title":"lnbPicture","type":"command","url":"https://community.bistudio.com/wiki/lnbPicture","revid":364186,"updated":"2024-05-05T10:46:48Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the picture name or path of the item with the given position of the 2D listbox.","syntaxes":[{"syntax":"lnbPicture [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"number of Control","types":["Number"],"since":null,"text":"idc: Number - number of Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of Row","types":["Number"],"since":null,"text":"row: Number - index of Row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of Column","types":["Number"],"since":null,"text":"column: Number - index of Column"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"control lnbPicture [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of Row in given Control","types":["Number"],"since":null,"text":"row: Number - index of Row in given Control"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of Column in given Control","types":["Number"],"since":null,"text":"column: Number - index of Column in given Control"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbPicture [200, [1, 1]];\n```","code":["lnbPicture [200, [1, 1]];"]},{"text":"```sqf\n_control lnbPicture [1, 1]; // \"a3\\ui_f\\data\\gui\\cfg\\ranks\\corporal_gs.paa\"\n```","code":["_control lnbPicture [1, 1]; // \"a3\\ui_f\\data\\gui\\cfg\\ranks\\corporal_gs.paa\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbPictureRight","operator":null,"title":"lnbPictureRight","type":"command","url":"https://community.bistudio.com/wiki/lnbPictureRight","revid":348973,"updated":"2023-11-08T14:45:44Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the right picture of given row. The *column* parameter does not matter.","syntaxes":[{"syntax":"lnbPictureRight [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"String","types":["String"],"description":"path of image","text":"String - path of image"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"ctrl lnbPictureRight [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"String","types":["String"],"description":"path of image","text":"String - path of image"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_path = _control lnbPictureRight [0, 0];\n```","code":["_path = _control lnbPictureRight [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetPictureRight","lnbSetPicture","lnbPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetColor","operator":null,"title":"lnbSetColor","type":"command","url":"https://community.bistudio.com/wiki/lnbSetColor","revid":377345,"updated":"2026-01-02T06:40:01Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the color of the item with the given position of the 2D listbox. Color is in format Color (RGBA).","syntaxes":[{"syntax":"lnbSetColor [idc, [row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], color]","types":["Array"]}},{"syntax":"ctrl lnbSetColor [[row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbSetColor [[0,0], [1,0,0,1]];\n```","code":["_ctrl lnbSetColor [[0,0], [1,0,0,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetColorRight","operator":null,"title":"lnbSetColorRight","type":"command","url":"https://community.bistudio.com/wiki/lnbSetColorRight","revid":377728,"updated":"2026-01-03T00:21:09Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the right color.","syntaxes":[{"syntax":"lnbSetColorRight [idc, [row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], color]","types":["Array"]}},{"syntax":"ctrl lnbSetColorRight [[row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control lnbSetColorRight [[0, 0], [1,1,1,0.5]];\n```","code":["_control lnbSetColorRight [[0, 0], [1,1,1,0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetColor","lnbColorRight","lnbColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetColumnsPos","operator":null,"title":"lnbSetColumnsPos","type":"command","url":"https://community.bistudio.com/wiki/lnbSetColumnsPos","revid":341220,"updated":"2023-05-13T23:12:29Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets relative screen X for ListNBox control columns positions. Setter for lnbGetColumnsPosition.","syntaxes":[{"syntax":"lnbSetColumnsPos [idc, positions]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of the control","types":["Number"],"since":null,"text":"idc: Number - idc of the control"},{"name":"positions","type":"Array","optional":false,"default":null,"description":"positions of the columns","types":["Array"],"since":null,"text":"positions: Array - positions of the columns"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, positions]","types":["Array"]}},{"syntax":"ctrl lnbSetColumnsPos positions","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":"lnb control","types":["Control"],"since":null,"text":"ctrl: Control - lnb control"},{"name":"positions","type":"Array","optional":false,"default":null,"description":"positions of the columns","types":["Array"],"since":null,"text":"positions: Array - positions of the columns"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"positions","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetColumnsPos [101, [0.1,0.5,0.7]];\n```","code":["lnbSetColumnsPos [101, [0.1,0.5,0.7]];"]},{"text":"```sqf\n_ctrl lnbSetColumnsPos [0.1,0.5,0.7];\n```","code":["_ctrl lnbSetColumnsPos [0.1,0.5,0.7];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[{"user":"ffur2007slx2_5","date":"2014-09-09T16:52:00Z","text":"See: List Box#LISTNBOX"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetCurSelRow","operator":null,"title":"lnbSetCurSelRow","type":"command","url":"https://community.bistudio.com/wiki/lnbSetCurSelRow","revid":369217,"updated":"2024-09-03T10:34:53Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects the row with the given index of the 2D listbox.","syntaxes":[{"syntax":"lnbSetCurSelRow [idc, index]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, index]","types":["Array"]}},{"syntax":"ctrl lnbSetCurSelRow index","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\ndisableSerialization;\n_ctrl = (findDisplay 300) displayCtrl 304;\n_ctrl lnbSetCurSelRow 1;\n```","code":["disableSerialization;\n_ctrl = (findDisplay 300) displayCtrl 304;\n_ctrl lnbSetCurSelRow 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetData","operator":null,"title":"lnbSetData","type":"command","url":"https://community.bistudio.com/wiki/lnbSetData","revid":349203,"updated":"2023-11-08T14:50:43Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the additional text (invisible) on the item with the given position of the 2D listbox.","syntaxes":[{"syntax":"lnbSetData [idc, [row, column], data]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":"the invisible text to add","types":["String"],"since":null,"text":"data: String - the invisible text to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], data]","types":["Array"]}},{"syntax":"ctrl lnbSetData [[row, column], data]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":"the invisible text to add","types":["String"],"since":null,"text":"data: String - the invisible text to add"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], data]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetData [123, [0,0],\"#1\"];\n```","code":["lnbSetData [123, [0,0],\"#1\"];"]},{"text":"```sqf\n_ctrl lnbSetData [[0,0],\"#1\"];\n```","code":["_ctrl lnbSetData [[0,0],\"#1\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetTooltip","lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetPicture","operator":null,"title":"lnbSetPicture","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPicture","revid":352055,"updated":"2024-02-01T23:24:34Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the picture in the item with the given position of the 2D listbox.The picture is searched in the mission, directory, the dtaExt subdirectory of the campaign directory, and the dtaExt directory and the data bank (or directory).","syntaxes":[{"syntax":"lnbSetPicture [idc, [row, column], picturePathOrName]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"picturePathOrName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"picturePathOrName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], picturePathOrName]","types":["Array"]}},{"syntax":"ctrl lnbSetPicture [[row, column], picturePathOrName]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"picturePathOrName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"picturePathOrName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], picturePathOrName]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetPicture [1, [0, 0], \"Picture\"];\n```","code":["lnbSetPicture [1, [0, 0], \"Picture\"];"]},{"text":"```sqf\n_ctrl lnbSetPicture [[0, 0], \"\\A3\\Ui_f\\data\\GUI\\Cfg\\Ranks\\lieutenant_gs.paa\"];\n```","code":["_ctrl lnbSetPicture [[0, 0], \"\\A3\\Ui_f\\data\\GUI\\Cfg\\Ranks\\lieutenant_gs.paa\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbPicture","lnbSetPictureRight","lnbPictureRight"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetPictureColor","operator":null,"title":"lnbSetPictureColor","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPictureColor","revid":377350,"updated":"2026-01-02T06:40:12Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the cell picture's colour.","syntaxes":[{"syntax":"lnbSetPictureColor [idc, [row, column], colour]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"colour","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"colour: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], colour]","types":["Array"]}},{"syntax":"ctrl lnbSetPictureColor [[row, column], colour]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"colour","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"colour: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], colour]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetPictureColor [1492, [1,0], [0,0.75,0.3,0.5]];\n```","code":["lnbSetPictureColor [1492, [1,0], [0,0.75,0.3,0.5]];"]},{"text":"```sqf\nctrl lnbSetPictureColor [[0, 3], [1,0,0,1]];\n```","code":["ctrl lnbSetPictureColor [[0, 3], [1,0,0,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[{"user":"Unknown","date":"","text":"MAYBE Arma 3 1.40 (or earlier) - see https://feedback.bistudio.com/T81738"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"lnbSetPictureColorRight","operator":null,"title":"lnbSetPictureColorRight","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPictureColorRight","revid":377730,"updated":"2026-01-03T00:21:13Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets color of the right picture in a CT_LISTNBOX.","syntaxes":[{"syntax":"lnbSetPictureColorRight [idc, [row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], color]","types":["Array"]}},{"syntax":"ctrl lnbSetPictureColorRight [[row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control lnbSetPictureColorRight [[0, 0], [1,1,1,0.5]];\n```","code":["_control lnbSetPictureColorRight [[0, 0], [1,1,1,0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetColor","lnbColorRight","lnbColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetPictureColorSelected","operator":null,"title":"lnbSetPictureColorSelected","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPictureColorSelected","revid":319487,"updated":"2022-05-13T09:24:10Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the cell picture's colour on cell selection.","syntaxes":[{"syntax":"lnbSetPictureColorSelected [idc, [row, column], colour]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"colour","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"colour: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], colour]","types":["Array"]}},{"syntax":"ctrl lnbSetPictureColorSelected [[row, column], colour]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"colour","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"colour: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], colour]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetPictureColorSelected [1492, [1,0], [0,0.75,0.3,0.5]];\n```","code":["lnbSetPictureColorSelected [1492, [1,0], [0,0.75,0.3,0.5]];"]},{"text":"```sqf\nctrl lnbSetPictureColorSelected [[0, 3], [1,0,0,1]];\n```","code":["ctrl lnbSetPictureColorSelected [[0, 3], [1,0,0,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetPictureColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetPictureColorSelectedRight","operator":null,"title":"lnbSetPictureColorSelectedRight","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPictureColorSelectedRight","revid":377729,"updated":"2026-01-03T00:21:11Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of the right picture when it is selected.","syntaxes":[{"syntax":"lnbSetPictureColorSelectedRight [idc, [row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], color]","types":["Array"]}},{"syntax":"ctrl lnbSetPictureColorSelectedRight [[row, column], color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control lnbSetPictureColorSelectedRight [[0, 0], [1,1,1,0.5]];\n```","code":["_control lnbSetPictureColorSelectedRight [[0, 0], [1,1,1,0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetColor","lnbColorRight","lnbColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetPictureRight","operator":null,"title":"lnbSetPictureRight","type":"command","url":"https://community.bistudio.com/wiki/lnbSetPictureRight","revid":353377,"updated":"2024-03-15T17:11:58Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the cell's right-picture. The picture is set to the end of the **row**, the *column* parameter does not matter.\n\n> [!NOTE]\n> The picture is searched in the mission, directory, the campaign directory's dtaExt subdirectory, and the data bank (or directory).","syntaxes":[{"syntax":"lnbSetPictureRight [idc, [row, column], path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"path","type":"String","optional":false,"default":null,"description":"the picture's file path","types":["String"],"since":null,"text":"path: String - the picture's file path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], path]","types":["Array"]}},{"syntax":"ctrl lnbSetPictureRight [[row, column], path]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"path","type":"String","optional":false,"default":null,"description":"the picture's file path","types":["String"],"since":null,"text":"path: String - the picture's file path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], path]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetPictureRight [1, [0, 0], \"Picture.paa\"];\n```","code":["lnbSetPictureRight [1, [0, 0], \"Picture.paa\"];"]},{"text":"```sqf\n_ctrl lnbSetPictureRight [[0, 0], \"\\A3\\Ui_f\\data\\GUI\\Cfg\\Ranks\\lieutenant_gs.paa\"];\n```","code":["_ctrl lnbSetPictureRight [[0, 0], \"\\A3\\Ui_f\\data\\GUI\\Cfg\\Ranks\\lieutenant_gs.paa\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbPictureRight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetText","operator":null,"title":"lnbSetText","type":"command","url":"https://community.bistudio.com/wiki/lnbSetText","revid":321488,"updated":"2022-05-16T14:15:09Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the text in the item with the given position of the 2D listbox.","syntaxes":[{"syntax":"lnbSetText [idc, [row, column], data]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], data]","types":["Array"]}},{"syntax":"ctrl lnbSetText [[row, column], data]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], data]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetText [101, [0,1], \"#1\"];\n```","code":["lnbSetText [101, [0,1], \"#1\"];"]},{"text":"```sqf\n_ctrl lnbSetText [[0,1], \"#1\"];\n```","code":["_ctrl lnbSetText [[0,1], \"#1\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbSetTextRight","operator":null,"title":"lnbSetTextRight","type":"command","url":"https://community.bistudio.com/wiki/lnbSetTextRight","revid":321491,"updated":"2022-05-16T14:16:31Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets cell's right-aligned text. Does not replace cell's text.","syntaxes":[{"syntax":"lnbSetTextRight [idc, [row, column], text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], text]","types":["Array"]}},{"syntax":"ctrl lnbSetTextRight [[row, column], text]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"0-based index (first row is 0, second is 1, etc)","types":["Number"],"since":null,"text":"row: Number - 0-based index (first row is 0, second is 1, etc)"},{"name":"column","type":"Number","optional":false,"default":null,"description":"0-based index (first column is 0, second is 1, etc)","types":["Number"],"since":null,"text":"column: Number - 0-based index (first column is 0, second is 1, etc)"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], text]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetTextRight [1492, [1,0], \"right text\"];\n```","code":["lnbSetTextRight [1492, [1,0], \"right text\"];"]},{"text":"```sqf\n_ctrl lnbSetTextRight [[0, 3], \"right text\"];\n```","code":["_ctrl lnbSetTextRight [[0, 3], \"right text\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbTextRight","lnbSetColorRight","lnbColorRight","lnbText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbSetTooltip","operator":null,"title":"lnbSetTooltip","type":"command","url":"https://community.bistudio.com/wiki/lnbSetTooltip","revid":349264,"updated":"2023-11-08T14:51:08Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.94"}],"since":{"game":"arma3","name":"Arma 3","version":"1.94"},"arma3_since":"1.94","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets tooltip on the item with the given row and column of CT_LISTNBOX.\n\n> [!IMPORTANT]\n> By default, tooltips are added for all columns no matter what column index is provided.\n> This behaviour can be overwritten since Arma 3 v2.02 by setting the control's property `tooltipPerColumn` to true.\n> See CT_LISTNBOX documentation.","syntaxes":[{"syntax":"lnbSetTooltip [idc, [row, column], text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's IDC","types":["Number"],"since":null,"text":"idc: Number - control's IDC"},{"name":"row","type":"Number","optional":false,"default":null,"description":"row where the tooltip should be shown","types":["Number"],"since":null,"text":"row: Number - row where the tooltip should be shown"},{"name":"column","type":"Number","optional":false,"default":null,"description":"column where tooltip should be shown. By default it is set for every column, see description","types":["Number"],"since":null,"text":"column: Number - column where tooltip should be shown. By default it is set for every column, see description"},{"name":"text","type":"String","optional":false,"default":null,"description":"tooltip text","types":["String"],"since":null,"text":"text: String - tooltip text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], text]","types":["Array"]}},{"syntax":"ctrl lnbSetTooltip [[row, column], text]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":"control","types":["Control"],"since":null,"text":"ctrl: Control - control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"row where the tooltip should be shown","types":["Number"],"since":null,"text":"row: Number - row where the tooltip should be shown"},{"name":"column","type":"Number","optional":false,"default":null,"description":"column where tooltip should be shown. By default it is set for every column, see description","types":["Number"],"since":null,"text":"column: Number - column where tooltip should be shown. By default it is set for every column, see description"},{"name":"text","type":"String","optional":false,"default":null,"description":"tooltip text","types":["String"],"since":null,"text":"text: String - tooltip text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[[row, column], text]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSetTooltip [1234, [1,0], \"tip\"];\n```","code":["lnbSetTooltip [1234, [1,0], \"tip\"];"]},{"text":"```sqf\n_ctrl lnbSetTooltip [[3,0], \"top\"];\n```","code":["_ctrl lnbSetTooltip [[3,0], \"top\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSetTooltip","lnbSetData","lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.94","Scripting Commands"]},{"name":"lnbSetValue","operator":null,"title":"lnbSetValue","type":"command","url":"https://community.bistudio.com/wiki/lnbSetValue","revid":321489,"updated":"2022-05-16T14:15:36Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the additional **integer** value in the item with the position index of the 2D listbox.","syntaxes":[{"syntax":"lnbSetValue [idc, [row, column], value]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column], value]","types":["Array"]}},{"syntax":"control lnbSetValue [[row, column], value]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[[row, column], value]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbSetValue [[0,0],1];\n```","code":["_ctrl lnbSetValue [[0,0],1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSize","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSize","operator":null,"title":"lnbSize","type":"command","url":"https://community.bistudio.com/wiki/lnbSize","revid":377872,"updated":"2026-01-04T11:45:13Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns size of CT_LISTNBOX. This command supports CT_TOOLBOX control since Arma 3 v2.06. For CT_COMBO or CT_LISTBOX see lbSize.","syntaxes":[{"syntax":"lnbSize controlOrIDC","since":null,"effect":null,"exec":null,"params":[{"name":"controlOrIDC","type":"Control or Number","optional":false,"default":null,"description":"control or control's IDC","types":["Control","Number"],"since":null,"text":"controlOrIDC: Control or Number - control or control's IDC"}],"returns":{"type":"Array","types":["Array"],"description":"in format [rows, columns] - rows: Number - Number of rows - columns: Number - Number of columns","text":"Array - in format [rows, columns]\n- rows: Number - Number of rows\n- columns: Number - Number of columns"},"form":"unary","operator":null,"left":null,"right":{"text":"controlOrIDC","types":["Control","Number"]}}],"examples":[{"text":"```sqf\nlnbSize _control;\n```","code":["lnbSize _control;"]},{"text":"```sqf\nlnbSize _someIDC;\n```","code":["lnbSize _someIDC;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbText","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lnbSort","operator":null,"title":"lnbSort","type":"command","url":"https://community.bistudio.com/wiki/lnbSort","revid":364169,"updated":"2024-05-05T10:46:44Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts given multicolumn listbox by lnbText in given column in ascending or descending order.\n\n> [!IMPORTANT]\n> This command does not support UNICODE, use lnbSortBy if it is needed instead","syntaxes":[{"syntax":"lnbSort [idc, column, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"false: descending / true: ascending","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) false: descending / true: ascending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, column, reversed]","types":["Array"]}},{"syntax":"control lnbSort [column, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"false: descending / true: ascending","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) false: descending / true: ascending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[column, reversed]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSort [1800, 1, false];\n```","code":["lnbSort [1800, 1, false];"]},{"text":"```sqf\n_ctl lnbSort [1, true];\n```","code":["_ctl lnbSort [1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","lbSort","lnbSortByValue","tvSortByValue","lbSortByValue","tvSort"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"lnbSortBy","operator":null,"title":"lnbSortBy","type":"command","url":"https://community.bistudio.com/wiki/lnbSortBy","revid":352015,"updated":"2024-02-01T23:24:06Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts given multi-column ListNBox in the given column by either lnbText, lnbValue or lnbData in normal or reversed order, using case-sensitive or case-insensitive comparison. Unlike the older **lnbSortXXX** commands, this command supports UNICODE characters out of the box.\n\nWhen sorting by `\"VALUE\"`, the rows with the same lnbValue will additionally be sorted by lnbText in the order specified by the *reversedOrder* flag, text specified by `useTextRight` flag and case-sensitivity specified by `caseSensitive` flag.\n\n> [!IMPORTANT]\n> - This command supports referencing control via IDC as well, but as with any use of IDC in UI Control commands, a dialog should be present, i.e. UI user interaction is created with createDialog rather than createDisplay.\n> - As this command supports UNICODE by default, which may result in slower sorting, you can switch it off with `unicodeOff` param.","syntaxes":[{"syntax":"[controlOrIDC, column] lnbSortBy [sortByType, reversedOrder, caseSensitive, useTextRight, unicodeOff]","since":null,"effect":null,"exec":null,"params":[{"name":"controlOrIDC","type":"Control or Number","optional":false,"default":null,"description":"the ListNBox control or its IDC","types":["Control","Number"],"since":null,"text":"controlOrIDC: Control or Number - the ListNBox control or its IDC"},{"name":"column","type":"Number","optional":false,"default":null,"description":"column to sort (starts with 0)","types":["Number"],"since":null,"text":"column: Number - column to sort (starts with 0)"},{"name":"sortByType","type":"String","optional":true,"default":"\"TEXT\"","description":"one of:\n- `\"TEXT\"`\n- `\"VALUE\"`\n- `\"DATA\"`","types":["String"],"since":null,"text":"sortByType: String - (Optional, default \"TEXT\") one of:\n- `\"TEXT\"`\n- `\"VALUE\"`\n- `\"DATA\"`"},{"name":"reversedOrder","type":"Boolean","optional":true,"default":"false","description":"true for sorting in reversed order","types":["Boolean"],"since":null,"text":"reversedOrder: Boolean - (Optional, default false) true for sorting in reversed order"},{"name":"caseSensitive","type":"Boolean","optional":true,"default":"false","description":"true for using case-sensitive comparison","types":["Boolean"],"since":null,"text":"caseSensitive: Boolean - (Optional, default false) true for using case-sensitive comparison"},{"name":"useTextRight","type":"Boolean","optional":true,"default":"false","description":"true to sort by text right","types":["Boolean"],"since":null,"text":"useTextRight: Boolean - (Optional, default false) true to sort by text right"},{"name":"unicodeOff","type":"Boolean","optional":true,"default":"false","description":"true to switch off UNICODE conversion for faster sorting","types":["Boolean"],"since":null,"text":"unicodeOff: Boolean - (Optional, default false) true to switch off UNICODE conversion for faster sorting"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[controlOrIDC, column]","types":["Array"]},"right":{"text":"[sortByType, reversedOrder, caseSensitive, useTextRight, unicodeOff]","types":["Array"]}}],"examples":[{"text":"```sqf\nwith uiNamespace do\n{\n    private _column = 1;\n    private _lnb = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscListNBox\", -1];\n    _lnb ctrlSetPosition [0,0,1,1];\n    _lnb ctrlCommit 0;\n    lnbClear _lnb;\n    { \n        _lnb lnbAddRow [format [\"Row %1\", _forEachIndex], _x select 0];\n        _lnb lnbSetValue [[_forEachIndex, _column], _x select 1];\n    } \n    forEach [[\"В\",1], [\"Я\",0], [\"Б\",1], [\"Ю\",0], [\"А\",1]];\n    [_lnb, _column] lnbSortBy [\"VALUE\", true, false];\n};\n```","code":["with uiNamespace do\n{\n\tprivate _column = 1;\n\tprivate _lnb = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscListNBox\", -1];\n\t_lnb ctrlSetPosition [0,0,1,1];\n\t_lnb ctrlCommit 0;\n\tlnbClear _lnb;\n\t{ \n\t\t_lnb lnbAddRow [format [\"Row %1\", _forEachIndex], _x select 0];\n\t\t_lnb lnbSetValue [[_forEachIndex, _column], _x select 1];\n\t} \n\tforEach [[\"В\",1], [\"Я\",0], [\"Б\",1], [\"Ю\",0], [\"А\",1]];\n\t[_lnb, _column] lnbSortBy [\"VALUE\", true, false];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSort","lnbSortByValue","lbSort","lbSortByValue","tvSort","tvSortByValue","sort"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"lnbSortByValue","operator":null,"title":"lnbSortByValue","type":"command","url":"https://community.bistudio.com/wiki/lnbSortByValue","revid":330120,"updated":"2022-08-21T19:54:07Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts given multicolumn listbox by lnbValue in given column in ascending or descending order.","syntaxes":[{"syntax":"lnbSortByValue [idc, column, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"false: descending / true: ascending","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) false: descending / true: ascending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, column, reversed]","types":["Array"]}},{"syntax":"control lnbSortByValue [column, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"false: descending / true: ascending","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) false: descending / true: ascending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[column, reversed]","types":["Array"]}}],"examples":[{"text":"```sqf\nlnbSortByValue [1800, 1, false];\n```","code":["lnbSortByValue [1800, 1, false];"]},{"text":"```sqf\n_ctl lnbSortByValue [1, true];\n```","code":["_ctl lnbSortByValue [1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","lbSort","lnbSort","tvSortByValue","lbSortByValue","tvSort"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"lnbText","operator":null,"title":"lnbText","type":"command","url":"https://community.bistudio.com/wiki/lnbText","revid":330121,"updated":"2022-08-21T19:54:50Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns the shown text in the item with the given position of the given 2D listbox.","syntaxes":[{"syntax":"control lnbText [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_text = _ctrl lnbText [0,0];\n```","code":["_text = _ctrl lnbText [0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"lnbTextRight","operator":null,"title":"lnbTextRight","type":"command","url":"https://community.bistudio.com/wiki/lnbTextRight","revid":348794,"updated":"2023-11-08T14:33:18Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns CT_LISTNBOX's right aligned cell text.","syntaxes":[{"syntax":"lnbTextRight [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"ctrl lnbTextRight [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":"index of the row","types":["Number"],"since":null,"text":"row: Number - index of the row"},{"name":"column","type":"Number","optional":false,"default":null,"description":"index of the column","types":["Number"],"since":null,"text":"column: Number - index of the column"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_text = _control lnbTextRight [0, 0];\n```","code":["_text = _control lnbTextRight [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbSetTextRight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"lnbValue","operator":null,"title":"lnbValue","type":"command","url":"https://community.bistudio.com/wiki/lnbValue","revid":319419,"updated":"2022-05-13T09:24:03Z","groups":["GUI Control - ListNBox"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the additional integer value in the item with the given position of the 2D listbox.","syntaxes":[{"syntax":"lnbValue [idc, [row, column]]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, [row, column]]","types":["Array"]}},{"syntax":"ctrl lnbValue [row, column]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"row","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"row: Number"},{"name":"column","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"column: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[row, column]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl lnbValue [0,0]; // 1, default is 0 if value is String set by lnbSetValue\n```","code":["_ctrl lnbValue [0,0]; // 1, default is 0 if value is String set by lnbSetValue"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lnbAddArray","lnbAddColumn","lnbAddRow","lnbClear","lnbColor","lnbCurSelRow","lnbData","lnbDeleteColumn","lnbDeleteRow","lnbGetColumnsPosition","lnbPicture","lnbSetColor","lnbSetColumnsPos","lnbSetCurSelRow","lnbSetData","lnbSetPicture","lnbSetText","lnbSetValue","lnbSize","lnbText"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - ListNBox","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"load","operator":null,"title":"load","type":"command","url":"https://community.bistudio.com/wiki/load","revid":347534,"updated":"2023-09-28T08:15:16Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the percentage of fullness of a unit's cargo. Output is usually in range 0..1, but can be higher after using certain scripting commands (like addWeaponWithAttachmentsCargoGlobal) which ignore load values when adding items.\n\n> [!NOTE]\n> See #Example 2 for load calculation.","syntaxes":[{"syntax":"load unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"(before Arma 3 v2.08 the command did not support containers, ammo boxes, weapon holders, vehicle cargos)","types":["Object"],"since":null,"text":"unit: Object - (before Arma 3 v2.08 the command did not support containers, ammo boxes, weapon holders, vehicle cargos)"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nload player;\n```","code":["load player;"]},{"text":"unit load calculation formula:\n\n```sqf\nprivate _unitLoad = loadAbs _unit / getNumber (configFile >> \"CfgInventoryGlobalVariable\" >> \"maxSoldierLoad\");\n```","code":["private _unitLoad = loadAbs _unit / getNumber (configFile >> \"CfgInventoryGlobalVariable\" >> \"maxSoldierLoad\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["maxLoad","loadAbs","loadBackpack","loadUniform","loadVest","getMass","weightRTD","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"load3DENScenario","operator":null,"title":"load3DENScenario","type":"command","url":"https://community.bistudio.com/wiki/load3DENScenario","revid":369783,"updated":"2024-10-08T15:09:02Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Load the provided scenario or an empty scenario in the provided world.","syntaxes":[{"syntax":"load3DENScenario scenarioOrWorld","since":null,"effect":null,"exec":null,"params":[{"name":"scenarioOrWorld","type":"String","optional":false,"default":null,"description":"scenario name or world name","types":["String"],"since":null,"text":"scenarioOrWorld: String - scenario name or world name"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success, false otherwise","text":"Boolean - true on success, false otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"scenarioOrWorld","types":["String"]}}],"examples":[{"text":"```sqf\nload3DENScenario \"MyMission.VR\";\n```","code":["load3DENScenario \"MyMission.VR\";"]},{"text":"```sqf\nload3DENScenario \"Stratis\";\n```","code":["load3DENScenario \"Stratis\";"]},{"text":"```sqf\n//For a scenario located at ...\\Arma 3 - Other Profiles\\<PROFILENAME>\\missions\\subfolder\\myMission.VR\n//full path needs to be provided without leading \\\nload3DENScenario \"missions\\subfolder\\myMission.VR\";\n```","code":["//For a scenario located at ...\\Arma 3 - Other Profiles\\<PROFILENAME>\\missions\\subfolder\\myMission.VR\n//full path needs to be provided without leading \\\nload3DENScenario \"missions\\subfolder\\myMission.VR\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["is3DENPreview"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"loadAbs","operator":null,"title":"loadAbs","type":"command","url":"https://community.bistudio.com/wiki/loadAbs","revid":353757,"updated":"2024-03-23T13:51:29Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current sum of mass from items stored in all unit's containers, linked items and weapons.","syntaxes":[{"syntax":"loadAbs unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"(before Arma 3 v2.08 the command did not support containers, ammo boxes, weapon holders, vehicle cargos)","types":["Object"],"since":null,"text":"unit: Object - (before Arma 3 v2.08 the command did not support containers, ammo boxes, weapon holders, vehicle cargos)"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"Player weight: \n\n```sqf\n_weight = loadAbs player;\n```","code":["_weight = loadAbs player;"]},{"text":"```sqf\nprivate _loadUniform = loadAbs uniformContainer player;\nprivate _loadVest = loadAbs vestContainer player;\nprivate _loadBackpack = loadAbs backpackContainer player;\nhint format [\n    \"Player's load:\\nUniform: %1\\nVest:%2\\nBackpack: $3\\nTotal: %4\",\n    _loadUniform,\n    _loadVest,\n    _loadBackpack,\n    _loadUniform + _loadVest + _loadBackpack\n];\n```","code":["private _loadUniform = loadAbs uniformContainer player;\nprivate _loadVest = loadAbs vestContainer player;\nprivate _loadBackpack = loadAbs backpackContainer player;\nhint format [\n\t\"Player's load:\\nUniform: %1\\nVest:%2\\nBackpack: $3\\nTotal: %4\",\n\t_loadUniform,\n\t_loadVest,\n\t_loadBackpack,\n\t_loadUniform + _loadVest + _loadBackpack\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["load","maxLoad","loadBackpack","loadUniform","loadVest","getMass","weightRTD","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"loadBackpack","operator":null,"title":"loadBackpack","type":"command","url":"https://community.bistudio.com/wiki/loadBackpack","revid":321277,"updated":"2022-05-13T19:08:07Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current percentage of mass from items stored in a backpack relative to the maximum capacity of the backpack.\n\nIt is equivalent to this formula:\n\n```sqf\n_loadBackpack = massOfAllItemsInBackpack / getContainerMaxLoad backpack player;\n```","syntaxes":[{"syntax":"loadBackpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _myVariable = loadBackpack myUnit;\n```","code":["private _myVariable = loadBackpack myUnit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["load","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","removeBackpack","clearBackpackCargo","clearAllItemsFromBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","loadUniform","loadVest","getMass","weightRTD","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"loadConfig","operator":null,"title":"loadConfig","type":"command","url":"https://community.bistudio.com/wiki/loadConfig","revid":341399,"updated":"2023-05-25T14:02:22Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Loads the given file as a Config, allowing easy processing of the config file contents using commands such as configClasses, configProperties, >>, etc. It can load .rvmat, .bisurf, .cpp, .bin, .sqm, and description.ext files (both binarized and unbinarized configs are supported).\n\n> [!IMPORTANT]\n> - Config loading can be very slow; the config should only be loaded once and cached, e.g in a HashMap of `File Path → Config` pairs (see #Example 3).\n> - It is advised to store the generated config in a variable, otherwise it will get destroyed if it is not being referenced directly (see #Example 2).","syntaxes":[{"syntax":"loadConfig path","since":null,"effect":null,"exec":null,"params":[{"name":"path","type":"String","optional":false,"default":null,"description":"path to the file, which should be in a valid config format.","types":["String"],"since":null,"text":"path: String - path to the file, which should be in a valid config format."}],"returns":{"type":"Config","types":["Config"],"description":"loaded config. Returns configNull if the file doesn't exist.","text":"Config - loaded config. Returns configNull if the file doesn't exist."},"form":"unary","operator":null,"left":null,"right":{"text":"path","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _cfg = loadConfig \"a3\\data_f\\default_super.rvmat\"; // note: very slow! ~0.1200 ms on tested system\ngetText (_cfg >> \"Stage2\" >> \"uvSource\");\n```","code":["private _cfg = loadConfig \"a3\\data_f\\default_super.rvmat\"; // note: very slow! ~0.1200 ms on tested system\ngetText (_cfg >> \"Stage2\" >> \"uvSource\");"]},{"text":"```sqf\n// INCORRECT - the config is destroyed after the first operator >> accesses it\ngetNumber (loadConfig \"mission.sqm\" >> \"ScenarioData\" >> \"respawnDelay\");\n\n// CORRECT - the config is destroyed only when the variable _cfg is destroyed\n_cfg = loadConfig \"mission.sqm\";\ngetNumber (_cfg >> \"ScenarioData\" >> \"respawnDelay\");\n```","code":["// INCORRECT - the config is destroyed after the first operator >> accesses it\ngetNumber (loadConfig \"mission.sqm\" >> \"ScenarioData\" >> \"respawnDelay\");\n\n// CORRECT - the config is destroyed only when the variable _cfg is destroyed\n_cfg = loadConfig \"mission.sqm\";\ngetNumber (_cfg >> \"ScenarioData\" >> \"respawnDelay\");"]},{"text":"```sqf\n// using a hashmap to cache loaded configs, since loading configs is very slow and should be done once.\nprivate _fnc_loadConfig = {\n    params [\"_path\"];\n    // initialize cache if not initialized yet\n    if (isNil \"TAG_configCache\") then\n    {\n        TAG_configCache = createHashMap;\n    };\n    private _cfg = TAG_configCache getOrDefault [_path, configNull];\n    // if path doesn't exist in the cache or cfg is null, load the config\n    if (isNull _cfg) then\n    {\n        _cfg = loadConfig _path;\n        TAG_configCache set [_path, _cfg];\n    };\n    _cfg;\n};\n// the first call will be slow (~0.1200 ms), but subsequent calls are fast (~0.0050 ms)\n[\"a3\\data_f\\default_super.rvmat\"] call _fnc_loadConfig;\n```","code":["// using a hashmap to cache loaded configs, since loading configs is very slow and should be done once.\nprivate _fnc_loadConfig = {\n\tparams [\"_path\"];\n\t// initialize cache if not initialized yet\n\tif (isNil \"TAG_configCache\") then\n\t{\n\t\tTAG_configCache = createHashMap;\n\t};\n\tprivate _cfg = TAG_configCache getOrDefault [_path, configNull];\n\t// if path doesn't exist in the cache or cfg is null, load the config\n\tif (isNull _cfg) then\n\t{\n\t\t_cfg = loadConfig _path;\n\t\tTAG_configCache set [_path, _cfg];\n\t};\n\t_cfg;\n};\n// the first call will be slow (~0.1200 ms), but subsequent calls are fast (~0.0050 ms)\n[\"a3\\data_f\\default_super.rvmat\"] call _fnc_loadConfig;"]},{"text":"```sqf\n// converting a config into hashmap\nprivate _fnc_convertClass = {\n    params [\"_cfgClass\"];\n\n    private _result = createHashMap;\n    private _props = configProperties [_cfgClass, \"true\", true];\n    // note: Hashmaps are case-sensitive so configName cases have to be consistent (e.g. all lowercase)\n    {\n        if (isNumber _x)    then { _result set [toLowerANSI configName _x, getNumber _x];    continue; };\n        if (isText _x)        then { _result set [toLowerANSI configName _x, getText _x];        continue; };\n        if (isArray _x)        then { _result set [toLowerANSI configName _x, getArray _x];    continue; };\n    } forEach _props;\n\n    private _classes = \"true\" configClasses _cfgClass;\n    {\n        _result set [toLowerANSI configName _x, _x call _fnc_convertClass];\n    } forEach _classes;\n\n    _result;\n};\n\nprivate _cfg = loadConfig \"mission.sqm\";\nprivate _cfgMap = _cfg call _fnc_convertClass;\n\n// the following expression is similar to getNumber(_cfg >> \"EditorData\" >> \"moveGridStep\")\n// note that all strings are lowercase (which is how they were stored in hashmap)\n_cfgMap get \"editordata\" get \"movegridstep\";\n```","code":["// converting a config into hashmap\nprivate _fnc_convertClass = {\n\tparams [\"_cfgClass\"];\n\n\tprivate _result = createHashMap;\n\tprivate _props = configProperties [_cfgClass, \"true\", true];\n\t// note: Hashmaps are case-sensitive so configName cases have to be consistent (e.g. all lowercase)\n\t{\n\t\tif (isNumber _x)\tthen { _result set [toLowerANSI configName _x, getNumber _x];\tcontinue; };\n\t\tif (isText _x)\t\tthen { _result set [toLowerANSI configName _x, getText _x];\t\tcontinue; };\n\t\tif (isArray _x)\t\tthen { _result set [toLowerANSI configName _x, getArray _x];\tcontinue; };\n\t} forEach _props;\n\n\tprivate _classes = \"true\" configClasses _cfgClass;\n\t{\n\t\t_result set [toLowerANSI configName _x, _x call _fnc_convertClass];\n\t} forEach _classes;\n\n\t_result;\n};\n\nprivate _cfg = loadConfig \"mission.sqm\";\nprivate _cfgMap = _cfg call _fnc_convertClass;\n\n// the following expression is similar to getNumber(_cfg >> \"EditorData\" >> \"moveGridStep\")\n// note that all strings are lowercase (which is how they were stored in hashmap)\n_cfgMap get \"editordata\" get \"movegridstep\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadFile","config greater greater name","configFile","configClasses","isText","isNumber","isArray","isClass","configName","getText","getNumber","getArray"],"notes":[{"user":"Dedmen","date":"2022-03-22T09:14:37Z","text":"When trying to load a terrain surface name, like you get from Ammo Eventhandlers when you hit the terrain, you can simply use\n\n```sqf\nprivate _config = configFile >> \"CfgSurfaces\" >> _surfaceName;\n```\n\nYou can recognize surface names by them not having any \\ path separators in them, they usually start with gdt, for example \"gdtvrsurface01\"."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"loadCuratorSelectionPreset","operator":null,"title":"loadCuratorSelectionPreset","type":"command","url":"https://community.bistudio.com/wiki/loadCuratorSelectionPreset","revid":347228,"updated":"2023-09-05T17:11:28Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Load the given selection preset to the current selection of the curator.","syntaxes":[{"syntax":"loadCuratorSelectionPreset numkey","since":null,"effect":null,"exec":null,"params":[{"name":"numkey","type":"Number","optional":false,"default":null,"description":"the number key under which the selection preset is saved","types":["Number"],"since":null,"text":"numkey: Number - the number key under which the selection preset is saved"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"numkey","types":["Number"]}}],"examples":[{"text":"```sqf\nloadCuratorSelectionPreset 1;\n```","code":["loadCuratorSelectionPreset 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["curatorSelectionPreset","setCuratorSelectionPreset","curatorSelected","setCuratorSelected","addCuratorSelected","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"loadFile","operator":null,"title":"loadFile","type":"command","url":"https://community.bistudio.com/wiki/loadFile","revid":352208,"updated":"2024-02-01T23:26:04Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the content of given files. If you plan to compile said string, be aware that the file should not contain comments or compile will throw an error. If there are comments, use preprocessFile/preprocessFileLineNumbers instead.\n\n> [!WARNING]\n> If the file is not prepared using UTF-8 encoding and contains some characters with codes > 127, they might convert incorrectly.","syntaxes":[{"syntax":"loadFile fileName","since":null,"effect":null,"exec":null,"params":[{"name":"fileName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"fileName: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\n_contents = loadFile \"wantedString.txt\";\n```","code":["_contents = loadFile \"wantedString.txt\";"]},{"text":"```sqf\n_contents = compile loadFile \"myFunction.sqf\"; // will compile string into code\n```","code":["_contents = compile loadFile \"myFunction.sqf\"; // will compile string into code"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fileExists","preprocessFile","preprocessFileLineNumbers"],"notes":[],"categories":[]},{"name":"loadGame","operator":null,"title":"loadGame","type":"command","url":"https://community.bistudio.com/wiki/loadGame","revid":353705,"updated":"2024-03-21T18:23:51Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Loads game from the last autosave made with saveGame.\nIf no autosave exists, restarts the mission. When used in campaign it will also deduct 1 life, defined in:\n\n```sqf\ncampaignConfigFile >> \"Campaign\" / \"ChapterName\" / \"MissionName\" / \"lives\"\n```\n\n> [!NOTE]\n> A `\"Loaded\"` mission event handler is available;\n> it is important that it is added in `preInit` in order for it to fire on load from save.","syntaxes":[{"syntax":"loadGame","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nloadGame;\n```","code":["loadGame;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableSaving","saveGame","savingEnabled","isSaving"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"loadIdentity","operator":null,"title":"loadIdentity","type":"command","url":"https://community.bistudio.com/wiki/loadIdentity","revid":322977,"updated":"2022-06-28T21:42:55Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Loads person's identity from Objects.sav file in campaign directory (from entry name).","syntaxes":[{"syntax":"unit loadIdentity name","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successfull, otherwise false","text":"Boolean - true if successfull, otherwise false"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_ok = player loadIdentity \"playerIdentity\";\n```","code":["_ok = player loadIdentity \"playerIdentity\";"]}],"multiplayer":"This command does not work in Multiplayer.","problems":null,"aliases":[],"see_also":["saveIdentity","lockIdentity","setIdentity"],"notes":[],"categories":[]},{"name":"loadMagazine","operator":null,"title":"loadMagazine","type":"command","url":"https://community.bistudio.com/wiki/loadMagazine","revid":377475,"updated":"2026-01-02T06:48:47Z","groups":["Weapons","Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Initiates the loading action on given weapon of the turret of a transport. So the new magazine is not available instantly, yet according to the reloadTime.\n\nThe turret has to be manned. One can also change the magazine if its respective weapon is not selected.","syntaxes":[{"syntax":"transport loadMagazine [turretPath, weaponName, magazineName]","since":null,"effect":null,"exec":null,"params":[{"name":"transport","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"transport: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponName: String"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"transport","types":["Object"]},"right":{"text":"[turretPath, weaponName, magazineName]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player loadMagazine [[0], \"m256\", \"20Rnd_120mmHE_M1A2\"];\n```","code":["vehicle player loadMagazine [[0], \"m256\", \"20Rnd_120mmHE_M1A2\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesTurret","addMagazineTurret","reload","weaponState","setWeaponReloadingTime","weapons","magazines","Arma 3: Actions"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"loadOverlay","operator":null,"title":"loadOverlay","type":"command","url":"https://community.bistudio.com/wiki/loadOverlay","revid":353378,"updated":"2024-03-15T17:11:59Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates the load overlay dialog for the specified type of overlay.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map loadOverlay config","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"loadStatus","operator":null,"title":"loadStatus","type":"command","url":"https://community.bistudio.com/wiki/loadStatus","revid":319462,"updated":"2022-05-13T09:24:07Z","groups":["Weapon Pool","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Loads object's properties from Objects.sav file in campaign directory (from entry name).","syntaxes":[{"syntax":"object loadStatus entryName","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"entryName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"entryName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successfull, otherwise false","text":"Boolean - true if successfull, otherwise false"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"entryName","types":["String"]}}],"examples":[{"text":"```sqf\n_ok = player loadStatus \"playerState\";\n```","code":["_ok = player loadStatus \"playerState\";"]}],"multiplayer":"This command does not work in Multiplayer.","problems":null,"aliases":[],"see_also":["saveStatus"],"notes":[],"categories":[]},{"name":"loadUniform","operator":null,"title":"loadUniform","type":"command","url":"https://community.bistudio.com/wiki/loadUniform","revid":320992,"updated":"2022-05-13T10:22:04Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current percentage of mass from items stored in a uniform relative to the maximum capacity of the uniform.\n\nIt is equivalent to this formula:\n\n```sqf\nprivate _loadUniform = massOfAllItemsInUniform / getContainerMaxLoad uniform player;\n```","syntaxes":[{"syntax":"loadUniform unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _weight = loadUniform player;\n```","code":["private _weight = loadUniform player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["load","loadAbs","loadBackpack","loadVest","getMass","weightRTD","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"loadVest","operator":null,"title":"loadVest","type":"command","url":"https://community.bistudio.com/wiki/loadVest","revid":323062,"updated":"2022-06-28T21:43:11Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current percentage of mass from items stored in a vest relative to the maximum capacity of the vest.\n\nIt is equivalent to this formula:\n\n```sqf\n_loadVest = massOfAllItemsInVest / getContainerMaxLoad vest player;\n```","syntaxes":[{"syntax":"loadVest unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_weight = loadVest player;\n```","code":["_weight = loadVest player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["load","loadAbs","loadBackpack","loadUniform","getMass","weightRTD","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"local","operator":null,"title":"local","type":"command","url":"https://community.bistudio.com/wiki/local","revid":349662,"updated":"2023-11-18T17:02:32Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if given unit is local on the computer in multiplayer games - see Multiplayer Scripting#Locality.\n\nThis can be used to determine on which computer some code must be run. In single player all objects are local.","syntaxes":[{"syntax":"local object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":null,"optional":false,"default":null,"description":"Object or Group (since Arma 3 v1.32)","types":["Object","Group"],"since":null,"text":"object: Object or Group (since Arma 3 v1.32)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object","Group"]}},{"syntax":"local variable = value From Arma 2 v1.00 until Arma 3 v1.54 - see private for later versions","since":"arma2 1.00","effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"variable = value From Arma 2 v1.00 until Arma 3 v1.54 - see private for later versions","types":[]}}],"examples":[{"text":"```sqf\nif (not local _unit) then\n{\n    hint format [\"%1 is remote\", name _unit];\n};\n```","code":["if (not local _unit) then\n{\n\thint format [\"%1 is remote\", name _unit];\n};"]},{"text":"```sqf\n_isLocalGroup = local group _unit;\n```","code":["_isLocalGroup = local group _unit;"]},{"text":"Sets variable's scope:\n\n```sqf\n// from Arma 2 v1.00 until Arma 3v1.54\nlocal _myVariable = 42;\n\n// since Arma 3 v1.54\nprivate _myVariable = 42;\n```","code":["// from Arma 2 v1.00 until Arma 3v1.54\nlocal _myVariable = 42;\n\n// since Arma 3 v1.54\nprivate _myVariable = 42;"]}],"multiplayer":"A few things to note amongst others:\n- A game logic / module is always local to the server\n- Terrain objects are local to every machine","problems":null,"aliases":[],"see_also":["Arma 3: Event Handlers","owner","setOwner"],"notes":[],"categories":[]},{"name":"localize","operator":null,"title":"localize","type":"command","url":"https://community.bistudio.com/wiki/localize","revid":340342,"updated":"2023-04-30T12:39:28Z","groups":["Strings","Localization"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Used to internationalise text messages. The provided translation key is looked up in Stringtable.xml (or Stringtable.csv).","syntaxes":[{"syntax":"localize stringName","since":null,"effect":null,"exec":null,"params":[{"name":"stringName","type":"String","optional":false,"default":null,"description":"string which leads to localisation. Casing does not matter. Arma 3 v2.04 A string starting with \"$\" is supported","types":["String"],"since":null,"text":"stringName: String - string which leads to localisation. Casing does not matter. Arma 3 v2.04 A string starting with \"$\" is supported"}],"returns":{"type":"String","types":["String"],"description":"text found in corresponding entry in stringtable file. If the key could not be found an empty string `\"\"` is returned and an entry is added to .rpt file, for example `String STR_DN_SNAKE not found`","text":"String - text found in corresponding entry in stringtable file. If the key could not be found an empty string `\"\"` is returned and an entry is added to .rpt file, for example `String STR_DN_SNAKE not found`"},"form":"unary","operator":null,"left":null,"right":{"text":"stringName","types":["String"]}}],"examples":[{"text":"```sqf\nhint localize \"STR_West\";                // returns \"BLUFOR\"\nhint localize \"STR_WEST\";                // returns \"BLUFOR\"\nhint localize \"STR_weSt\";                // returns \"BLUFOR\"\nhint localize \"STR_NonExistentString\";    // returns \"\" and logs \"String STR_NonExistentString not found\"\n```","code":["hint localize \"STR_West\";\t\t\t\t// returns \"BLUFOR\"\nhint localize \"STR_WEST\";\t\t\t\t// returns \"BLUFOR\"\nhint localize \"STR_weSt\";\t\t\t\t// returns \"BLUFOR\"\nhint localize \"STR_NonExistentString\";\t// returns \"\" and logs \"String STR_NonExistentString not found\""]},{"text":"```sqf\nhint format [\"Go %1\", localize \"STR_Q_NORTH\"]; // returns \"Go North\"\n```","code":["hint format [\"Go %1\", localize \"STR_Q_NORTH\"]; // returns \"Go North\""]},{"text":"```sqf\nhint format \n[\n    localize \"STR_ACTION_DROP_WEAPON\",    // \"STR_ACTION_DROP_WEAPON\" contains \"Drop %1\"\n    localize \"STR_SN_RIFLE\"                // \"STR_SN_RIFLE\" contains \"Rifle\"\n]; // returns \"Drop Rifle\"\n```","code":["hint format \n[\n\tlocalize \"STR_ACTION_DROP_WEAPON\",\t// \"STR_ACTION_DROP_WEAPON\" contains \"Drop %1\"\n\tlocalize \"STR_SN_RIFLE\"\t\t\t\t// \"STR_SN_RIFLE\" contains \"Rifle\"\n]; // returns \"Drop Rifle\""]},{"text":"```sqf\nlocalize \"$STR_USRACT_ADJUST\"; // returns \"Adjust\" since Arma 3 v2.04\n```","code":["localize \"$STR_USRACT_ADJUST\"; // returns \"Adjust\" since Arma 3 v2.04"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isLocalized","diag_localized","getTextRaw","BIS_fnc_localize","WFSideText","parseText","Stringtable.csv","Stringtable.xml"],"notes":[{"user":"Killzone_Kid","date":"2014-09-12T11:55:00Z","text":"The command localize will strip all HTML tags from your Stringtable.xml entries, however there is a way to trick it by substituting tags with HTML code instead:\n\n```xml\n<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Key ID=\"STR_TEST_KK\">\n    <Original><![CDATA[<t color='#ff0000'>This doesn't work</t>]]></Original>\n</Key>\n<Key ID=\"STR_TEST_KK2\">\n    <Original><t color='#ff0000'>This works</t></Original>\n</Key>\n```\n\n```sqf\nhint parseText localize \"str_test_kk\";    // no change of colour\nhint parseText localize \"str_test_kk2\";    // hint content is in red\n```"}],"categories":[]},{"name":"localNamespace","operator":null,"title":"localNamespace","type":"command","url":"https://community.bistudio.com/wiki/localNamespace","revid":309258,"updated":"2022-05-04T11:01:29Z","groups":["Namespaces","Variables","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns local Namespace attached to the mission.\nHas the same lifetime as missionNamespace but variables **cannot be broadcasted** out of or into this namespace in multiplayer and will not be serialized when game is saved. UI variables can be safely stored in this namespace.\nUse allVariables command to save the variables elsewhere if required.","syntaxes":[{"syntax":"localNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":null,"text":"Namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nlocalNamespace setVariable [\"abc\", 123];\n```","code":["localNamespace setVariable [\"abc\", 123];"]},{"text":"```sqf\nwith localNamespace do { hint str abc };\n```","code":["with localNamespace do { hint str abc };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","uiNamespace","parsingNamespace","profileNamespace","currentNamespace","allVariables"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"locationNull","operator":null,"title":"locationNull","type":"command","url":"https://community.bistudio.com/wiki/locationNull","revid":321059,"updated":"2022-05-13T12:19:56Z","groups":["Locations","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Location. To compare non-existent locations use isNull or isEqualTo:\n\n```sqf\nlocationNull == locationNull;            // false\nisNull locationNull;                    // true\nlocationNull isEqualTo locationNull;    // true\n```","syntaxes":[{"syntax":"locationNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Location","types":["Location"],"description":null,"text":"Location"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n!isNull locationNull; // false\n```","code":["!isNull locationNull; // false"]},{"text":"```sqf\nstr locationNull; // No location\n```","code":["str locationNull; // No location"]},{"text":"```sqf\nposition locationNull; // [0,0,0]\n```","code":["position locationNull; // [0,0,0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","objNull","taskNull","teamMemberNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"locationPosition","operator":null,"title":"locationPosition","type":"command","url":"https://community.bistudio.com/wiki/locationPosition","revid":377416,"updated":"2026-01-02T06:45:21Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the position of a location. If the location is attached to an object, that object's position is returned.","syntaxes":[{"syntax":"locationPosition location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"as locations are placed at Z = zero ASL the returned Z is negative on land and around zero on water, see #Example 3","text":"PositionAGL - as locations are placed at Z = zero ASL the returned Z is negative on land and around zero on water, see #Example 3"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_locationPos = locationPosition myLocation;\n```","code":["_locationPos = locationPosition myLocation;"]},{"text":"```sqf\n_location = nearestLocation [getPos player, \"nameCity\"];\n_locationPos = locationPosition _location;\n```","code":["_location = nearestLocation [getPos player, \"nameCity\"];\n_locationPos = locationPosition _location;"]},{"text":"```sqf\nprivate _landLocation = locationPosition nearestLocation [[2915.2, 6164.52], \"NameCityCapital\"]; // \"Agia Marina\" [2915.2, 6164.52, -21.9009]\nprivate _waterLocation = locationPosition nearestLocation [[2647.8799, 5989.9502], \"NameMarine\"]; // \"Marina Bay\" [2647.88, 5989.95, 0.0161484]\n```","code":["private _landLocation = locationPosition nearestLocation [[2915.2, 6164.52], \"NameCityCapital\"]; // \"Agia Marina\" [2915.2, 6164.52, -21.9009]\nprivate _waterLocation = locationPosition nearestLocation [[2647.8799, 5989.9502], \"NameMarine\"]; // \"Marina Bay\" [2647.88, 5989.95, 0.0161484]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPosition","createLocation","nearestLocation","nearestLocations","position","size"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lock","operator":null,"title":"lock","type":"command","url":"https://community.bistudio.com/wiki/lock","revid":353298,"updated":"2024-03-15T17:11:43Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Lock vehicle (disable mounting / dismounting) for player.\nThis command will remove user get in/get out actions but will not stop player getting into or out of vehicle via script commands (e.g moveInCargo).\n\n> [!NOTE]\n> Alternative syntax is similar to setVehicleLock but with numbers.","syntaxes":[{"syntax":"vehicleName lock locked","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"locked","type":"Boolean","optional":false,"default":null,"description":"true to lock, false to unlock","types":["Boolean"],"since":null,"text":"locked: Boolean - true to lock, false to unlock"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"locked","types":["Boolean"]}},{"syntax":"vehicleName lock lockstate","since":"arma3 0.50","effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"lockstate","type":"Number","optional":false,"default":null,"description":"can be one of the following:\n\n0 - Unlocked\n\n1 - Default (player subordinate cannot enter until his leader says so)\n\n2 - Locked\n\n3 - Locked for player","types":["Number"],"since":null,"text":"lockstate: Number - can be one of the following:\n\n0 - Unlocked\n\n1 - Default (player subordinate cannot enter until his leader says so)\n\n2 - Locked\n\n3 - Locked for player"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"lockstate","types":["Number"]}}],"examples":[{"text":"```sqf\n_jeepOne lock true;\n```","code":["_jeepOne lock true;"]},{"text":"```sqf\nheli lock true;\nlocked heli; // 2\n\nheli lock false;\nlocked heli; // 0\n\nheli lock 1;\nlocked heli; // 1\n```","code":["heli lock true;\nlocked heli; // 2\n\nheli lock false;\nlocked heli; // 0\n\nheli lock 1;\nlocked heli; // 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["locked","setVehicleLock","lockDriver","lockCargo","lockTurret"],"notes":[{"user":"Tankbuster","date":"2010-01-09T22:48:00Z","text":"Lock prevents AI persons mounting or dismounting vehicles when ordered to do so and players are prevented from doing both too, but AI will still dismount when a vehicle is damaged."},{"user":"cali","date":"2010-09-22T04:56:00Z","text":"If an AI group (e.g Mechanized Infantry) has its vehicle locked with its crew in it, it will mount or dismount it anyway. But a player in this group won't be able to enter the vehicle."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"lockCameraTo","operator":null,"title":"lockCameraTo","type":"command","url":"https://community.bistudio.com/wiki/lockCameraTo","revid":377889,"updated":"2026-01-05T17:33:18Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Lock/Unlock stabilized camera to target. Works only on turrets which have optic mode selected with direction stabilization enabled.\n\n> [!NOTE]\n> Since Arma 3 v2.08 the command also works with non-stabilized turrets (such as main turret of a tank). See syntax 2.\n\n> [!NOTE]\n> The command is local to the **turret** gunner, not the vehicle.","syntaxes":[{"syntax":"vehicle lockCameraTo [target, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"UAV","types":["Object"],"since":null,"text":"vehicle: Object - UAV"},{"name":"target","type":"Object or PositionASL","optional":false,"default":null,"description":"use objNull to unlock","types":["Object","PositionASL"],"since":null,"text":"target: Object or PositionASL - use objNull to unlock"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"path to the turret with required camera","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - path to the turret with required camera"}],"returns":{"type":"Nothing > [!IMPORTANT] >","types":["Nothing"],"description":"This syntax only works with stabilized turrets. > - When using this syntax, if target is out of possible view, the turret will move to its limit and get stuck there, with blocked input.","text":"Nothing\n\n> [!IMPORTANT]\n> - This syntax only works with stabilized turrets.\n> - When using this syntax, if target is out of possible view, the turret will move to its limit and get stuck there, with blocked input."},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[target, turretPath]","types":["Array"]}},{"syntax":"vehicle lockCameraTo [target, turretPath, temporary]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"UAV","types":["Object"],"since":null,"text":"vehicle: Object - UAV"},{"name":"target","type":"Object or PositionASL","optional":false,"default":null,"description":"use objNull to unlock","types":["Object","PositionASL"],"since":null,"text":"target: Object or PositionASL - use objNull to unlock"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"path to the turret with required camera","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - path to the turret with required camera"},{"name":"temporary","type":"Boolean","optional":false,"default":null,"description":"if set to true, the engine will automatically remove the lock-on once the turret reaches its target.\nIf the target is out of turret's reach, once the turret reaches its limits the lock-on will be released.","types":["Boolean"],"since":null,"text":"temporary: Boolean - if set to true, the engine will automatically remove the lock-on once the turret reaches its target.\nIf the target is out of turret's reach, once the turret reaches its limits the lock-on will be released."}],"returns":{"type":null,"types":["Nothing"],"description":null,"text":"Nothing\n\n> [!NOTE]\n> This syntax also works with non-stabilized turrets, unlike #Syntax 1."},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[target, turretPath, temporary]","types":["Array"]}}],"examples":[{"text":"```sqf\nuav lockCameraTo [cursorObject, [0,0]];\n```","code":["uav lockCameraTo [cursorObject, [0,0]];"]},{"text":"```sqf\nuav lockCameraTo [objNull, [0,0]]; // unlocks the turret\n```","code":["uav lockCameraTo [objNull, [0,0]]; // unlocks the turret"]},{"text":"```sqf\nvehicle player lockCameraTo [enemyTarget, vehicle player unitTurret player, false];\n```","code":["vehicle player lockCameraTo [enemyTarget, vehicle player unitTurret player, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockedCameraTo","camTarget","camSetTarget","camPrepareTarget","directionStabilizationEnabled","enableDirectionStabilization"],"notes":[{"user":"Commy2","date":"2015-04-10T06:54:00Z","text":"The vehicle has to have a stabilized optic for this command to work with ASL position."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"lockCargo","operator":null,"title":"lockCargo","type":"command","url":"https://community.bistudio.com/wiki/lockCargo","revid":330374,"updated":"2022-09-04T20:45:50Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Lock all cargo positions of a vehicle or lock by index.\nThis command will remove user \"get in\" action (not get out) but will also stop player getting into vehicle via script commands (e.g moveInCargo) unlike lock command.","syntaxes":[{"syntax":"vehicle lockCargo lock","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"lock","types":["Boolean"]}},{"syntax":"vehicle lockCargo [index, lock]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[index, lock]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicleName lockCargo true;\n```","code":["vehicleName lockCargo true;"]},{"text":"```sqf\nvehicleName lockCargo [0, true];\n```","code":["vehicleName lockCargo [0, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lock","setVehicleLock","lockDriver","lockedCargo","lockTurret"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"lockDriver","operator":null,"title":"lockDriver","type":"command","url":"https://community.bistudio.com/wiki/lockDriver","revid":364987,"updated":"2024-07-04T19:58:05Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Lock the driver position of the vehicle. This command must be executed where vehicle is local. This command will remove user get in action (not get out) but will also stop player getting into vehicle via script commands unlike lock command","syntaxes":[{"syntax":"vehicle lockDriver lock","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"lock","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicleName lockDriver true;\n```","code":["vehicleName lockDriver true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lock","setVehicleLock","lockedDriver","lockCargo","lockTurret"],"notes":[{"user":"Sa-Matra","date":"2023-04-03T03:34:25Z","text":"Locked seats also aren't allowed to be controlled remotely through UAV terminal."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"locked","operator":null,"title":"locked","type":"command","url":"https://community.bistudio.com/wiki/locked","revid":310835,"updated":"2022-05-07T20:23:59Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if vehicle is locked. If it is locked, Persons cannot mount / dismount without order.","syntaxes":[{"syntax":"locked vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"- Number","types":["Number"],"description":"since Arma 3 v0.50 - 0: Unlocked - 1: Default - a subordinate player cannot enter without AI leader order - 2: Locked - 3: Locked for player - -1: vehicle is null - Boolean for older games","text":"- Number - since Arma 3 v0.50\n  - 0: Unlocked\n  - 1: Default - a subordinate player cannot enter without AI leader order\n  - 2: Locked\n  - 3: Locked for player\n  - -1: vehicle is null\n- Boolean for older games"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_locked = locked _jeepOne;\n```","code":["_locked = locked _jeepOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lock","setVehicleLock","lockedDriver","lockedCargo","lockedTurret"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lockedCameraTo","operator":null,"title":"lockedCameraTo","type":"command","url":"https://community.bistudio.com/wiki/lockedCameraTo","revid":378357,"updated":"2026-04-02T16:48:58Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Return the turret lock target.\n\n> [!NOTE]\n> The command is local to the **turret**, not the vehicle.","syntaxes":[{"syntax":"vehicle lockedCameraTo turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":null,"optional":false,"default":null,"description":"Turret Path. Use an empty array to select the gunner's turret by default","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path. Use an empty array to select the gunner's turret by default"}],"returns":{"type":"Can be one of:","types":[],"description":"Nothing - not locked - Object - if locked to an object - PositionASL - if locked to a position","text":"Can be one of:\n- Nothing - not locked\n- Object - if locked to an object\n- PositionASL - if locked to a position"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nvehicle player lockedCameraTo [];\n```","code":["vehicle player lockedCameraTo [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockCameraTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"lockedCargo","operator":null,"title":"lockedCargo","type":"command","url":"https://community.bistudio.com/wiki/lockedCargo","revid":321015,"updated":"2022-05-13T11:15:18Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check whether cargo position of the vehicle is locked.","syntaxes":[{"syntax":"vehicle lockedCargo cargoIndex","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"cargoIndex","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"cargoIndex: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"cargoIndex","types":["Number"]}}],"examples":[{"text":"```sqf\n_result = vehicleName lockedCargo 0;\n```","code":["_result = vehicleName lockedCargo 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockCargo"],"notes":[{"user":"AgentRev","date":"2016-05-04T23:09:00Z","text":"For some vehicles, the command returns Nothing if the cargo index is invalid (i.e. -1)"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lockedDriver","operator":null,"title":"lockedDriver","type":"command","url":"https://community.bistudio.com/wiki/lockedDriver","revid":363262,"updated":"2024-03-26T10:51:33Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check whether driver position of the vehicle turret is locked.","syntaxes":[{"syntax":"lockedDriver vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_driverLocked = lockedDriver vehicle player;\n```","code":["_driverLocked = lockedDriver vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vehicle","driver"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lockedInventory","operator":null,"title":"lockedInventory","type":"command","url":"https://community.bistudio.com/wiki/lockedInventory","revid":338797,"updated":"2023-04-07T06:40:04Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get a vehicle's inventory lock state. Can also be used on a unit's backback (see lockInventory).","syntaxes":[{"syntax":"lockedInventory vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isInventoryLocked = lockedInventory vehicle player;\n```","code":["private _isInventoryLocked = lockedInventory vehicle player;"]},{"text":"```sqf\nprivate _isBackpackLocked = lockedInventory backpackContainer player;\n```","code":["private _isBackpackLocked = lockedInventory backpackContainer player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockInventory"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"lockedTurret","operator":null,"title":"lockedTurret","type":"command","url":"https://community.bistudio.com/wiki/lockedTurret","revid":377494,"updated":"2026-01-02T06:49:19Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check whether gunner position of the vehicle turret is locked.","syntaxes":[{"syntax":"vehicle lockedTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_locked = tank lockedTurret [0];\n```","code":["_locked = tank lockedTurret [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockTurret","moveInTurret","turretUnit"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lockIdentity","operator":null,"title":"lockIdentity","type":"command","url":"https://community.bistudio.com/wiki/lockIdentity","revid":321185,"updated":"2022-05-13T15:19:51Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Locks the identity of a person. This will disable default identity.","syntaxes":[{"syntax":"lockIdentity unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true, if it was applied","text":"Boolean - true, if it was applied"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_success = lockIdentity player;\n```","code":["_success = lockIdentity player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadIdentity","setIdentity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"lockInventory","operator":null,"title":"lockInventory","type":"command","url":"https://community.bistudio.com/wiki/lockInventory","revid":370883,"updated":"2025-02-21T10:44:04Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Lock or unlock a vehicle's inventory access.\nThis command can also lock backpack a unit is wearing to prevent access by a third party.\nIf set to true (locked), the inventory cannot be accessed via hotkey or action menu.","syntaxes":[{"syntax":"vehicle lockInventory lock","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"lock","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player lockInventory true;\n```","code":["vehicle player lockInventory true;"]},{"text":"```sqf\nbackpackContainer player lockInventory true;\n```","code":["backpackContainer player lockInventory true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockedInventory"],"notes":[{"user":"PierreMGI","date":"","text":"This command works only on alive unit. No matter you run it before or after death, on due backpackContainer unit, the backpack will be accessible on corpse."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.00","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"lockTurret","operator":null,"title":"lockTurret","type":"command","url":"https://community.bistudio.com/wiki/lockTurret","revid":377482,"updated":"2026-01-02T06:48:59Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Lock the gunner position of the vehicle turret.\nThis command will remove user \"get in\" action (not \"get out\") but will also stop player getting into vehicle via script commands unlike lock command.","syntaxes":[{"syntax":"vehicle lockTurret [turretPath, lock]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turretPath, lock]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicleName lockTurret [[0,0], true];\n```","code":["vehicleName lockTurret [[0,0], true];"]},{"text":"```sqf\nvehicle player lockTurret [[0], true];\n```","code":["vehicle player lockTurret [[0], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lockedTurret","lockCargo","lockDriver","assignedVehicleRole","turretUnit","moveInTurret"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"lockWP","operator":null,"title":"lockWP","type":"command","url":"https://community.bistudio.com/wiki/lockWP","revid":321186,"updated":"2022-05-13T15:20:16Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Disable switching to next waypoint (current waypoint will never complete while lockwp is used). Sometimes used during cut-scenes.","syntaxes":[{"syntax":"groupName lockWP lock","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"groupName: Object or Group"},{"name":"lock","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"lock: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Object","Group"]},"right":{"text":"lock","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_groupOne lockWP true;\n```","code":["_groupOne lockWP true;"]},{"text":"```sqf\n_Soldier lockWP true;\n```","code":["_Soldier lockWP true;"]},{"text":"```sqf\n_MyTank lockWP false;\n```","code":["_MyTank lockWP false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"log","operator":null,"title":"log","type":"command","url":"https://community.bistudio.com/wiki/log","revid":369352,"updated":"2024-09-03T18:43:04Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Base-10 logarithm of x.","syntaxes":[{"syntax":"log x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"a positive number","types":["Number"],"since":null,"text":"x: Number - a positive number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_log = log 10;\n```","code":["_log = log 10;"]},{"text":"```sqf\n_log = log abs -10;\n```","code":["_log = log abs -10;"]},{"text":"```sqf\nfinite log -10; // Returns false\n```","code":["finite log -10; // Returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"logEntities","operator":null,"title":"logEntities","type":"command","url":"https://community.bistudio.com/wiki/logEntities","revid":369445,"updated":"2024-09-05T17:09:41Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a log file containing the list of all game entities in scene.\nThe file is created in the same directory as .rpt file.\n\n> [!NOTE]\n> BattlEye's RCON variant of this command is `1. logEntities` (see also Multiplayer Server Commands).\n\nFile name example: `logEntities_4688_12-04-2014_12-19-39.log`\n\nFile content example:\n\n```\n====================== Vehicles =======================\n\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:1, Out: 0, NetID:2:3, Pos: [2476.243896][73.782043], N:B_Soldier_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2471.500977][62.477680], N:Snake_random_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2489.192383][73.935181], N:Snake_random_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2487.953857][73.828362], N:Snake_random_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2800.174805][96.234093], N:Rabbit_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2825.378418][2.068635], N:Rabbit_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2888.919434][6.837101], N:Rabbit_F\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:0:0, Pos: [2910.756104][16.089361], N:Rabbit_F\n> Loc:0, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 1, AnyPl:0, Out: 0, NetID:2:0, Pos: [9.000000][9.000000], N:Logic\n\nTotal objects: 9\nStatistics objects: 9\n\nIsLocal: 8\nIsMarkedToDelete: 0\nIsDestroyed: 0\nIsDamageDestroyed: 0\nIsDamageDead: 0\nIsNotSimulated: 9\nIsVisible: 1\nIsAnyPlayer: 1\nIsOutsideMap: 0\n\n=================== Slow vehicles =====================\n\nTotal objects: 214\nStatistics objects: 0\n\nStatic objects are accounted in total object count but not included in statistics\n\nIsLocal: 0\nIsMarkedToDelete: 0\nIsDestroyed: 0\nIsDamageDestroyed: 0\nIsDamageDead: 0\nIsNotSimulated: 0\nIsVisible: 0\nIsAnyPlayer: 0\nIsOutsideMap: 0\n\n=================== Out vehicles ====================\n\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:2:1, Pos: [2476.243896][73.782043], N:Supply40\n> Loc:1, ForDel:0, Dstr:0, DmgDstr:0, DmgDead:0, Sim:1, Inv: 0, AnyPl:0, Out: 0, NetID:2:2, Pos: [2476.243896][73.782043], N:Supply140\n\nTotal objects: 2\nStatistics objects: 2\n\nIsLocal: 2\nIsMarkedToDelete: 0\nIsDestroyed: 0\nIsDamageDestroyed: 0\nIsDamageDead: 0\nIsNotSimulated: 2\nIsVisible: 0\nIsAnyPlayer: 0\nIsOutsideMap: 0\n```","syntaxes":[{"syntax":"logEntities","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nlogEntities;\n```","code":["logEntities;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["entities","nearEntities","diag_log","diag_fps","diag fpsmin","diag frameno","diag_tickTime","diag_captureFrame","exportJIPMessages"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.18","Scripting Commands"]},{"name":"logNetwork","operator":null,"title":"logNetwork","type":"command","url":"https://community.bistudio.com/wiki/logNetwork","revid":376352,"updated":"2025-10-07T21:20:01Z","groups":["Multiplayer","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Registers new log file recording a network traffic and returns handle of the log. The log file is saved inside the Arma 3 root folder.\n\n> [!IMPORTANT]\n> logNetwork can potentially create a large log file.","syntaxes":[{"syntax":"logNetwork [logFile, filter]","since":null,"effect":null,"exec":null,"params":[{"name":"logFile","type":"String","optional":false,"default":null,"description":"where to store the log","types":["String"],"since":null,"text":"logFile: String - where to store the log"},{"name":"filter","type":"Array of Strings","optional":true,"default":null,"description":"????","types":["Array","String"],"since":null,"text":"filter: Array of Strings - (Optional) ????"}],"returns":{"type":"Number","types":["Number"],"description":"handle for the logging","text":"Number - handle for the logging"},"form":"unary","operator":null,"left":null,"right":{"text":"[logFile, filter]","types":["Array"]}}],"examples":[{"text":"```sqf\n_handle = logNetwork [\"myLog.txt\", [\"\"]];\n```","code":["_handle = logNetwork [\"myLog.txt\", [\"\"]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["logNetworkTerminate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"logNetworkTerminate","operator":null,"title":"logNetworkTerminate","type":"command","url":"https://community.bistudio.com/wiki/logNetworkTerminate","revid":347532,"updated":"2023-09-28T06:16:33Z","groups":["Multiplayer","Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Terminates a network log file started with logNetwork with the given handle","syntaxes":[{"syntax":"logNetworkTerminate handle","since":null,"effect":null,"exec":null,"params":[{"name":"handle","type":"Number","optional":false,"default":null,"description":"handle to terminate (created with logNetwork)","types":["Number"],"since":null,"text":"handle:  Number - handle to terminate (created with logNetwork)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"handle","types":["Number"]}}],"examples":[{"text":"```sqf\nlogNetworkTerminate _someHandle;\n```","code":["logNetworkTerminate _someHandle;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["logNetwork"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Command Group: Multiplayer","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"lookAt","operator":null,"title":"lookAt","type":"command","url":"https://community.bistudio.com/wiki/lookAt","revid":369219,"updated":"2024-09-03T10:34:54Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Control what the unit(s) is/are looking at (target or Position). If target is used, it will get revealed fully.","syntaxes":[{"syntax":"unit(s) lookAt position","since":null,"effect":null,"exec":null,"params":[{"name":"unit(s)","type":"Object or Array of Objects","optional":false,"default":null,"description":null,"types":["Object","Array"],"since":null,"text":"unit(s): Object or Array of Objects"},{"name":"position","type":"Object or PositionAGL","optional":false,"default":null,"description":null,"types":["Object","PositionAGL"],"since":null,"text":"position: Object or PositionAGL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit(s)","types":["Object","Array"]},"right":{"text":"position","types":["Object","PositionAGL"]}}],"examples":[{"text":"```sqf\n_someSoldier lookAt _otherSoldier;\n```","code":["_someSoldier lookAt _otherSoldier;"]},{"text":"```sqf\n[_someSoldier, _otherSoldier] lookAt markerPos \"markerOne\";\n```","code":["[_someSoldier, _otherSoldier] lookAt markerPos \"markerOne\";"]},{"text":"```sqf\nhint \"R U N !\";\nBFG = \"B_AAA_System_01_F\" createVehicle position player;\ncreateVehicleCrew BFG;\nt = time + 10;\nonEachFrame\n{\n    BFG lookAt (unitAimPosition player vectorAdd (velocity player vectorMultiply 0.2));\n    if (time > t && alive player) then\n    {\n        [BFG,\"weapon_Cannon_Phalanx\",[0]] call BIS_fnc_fire;\n    };\n};\n```","code":["hint \"R U N !\";\nBFG = \"B_AAA_System_01_F\" createVehicle position player;\ncreateVehicleCrew BFG;\nt = time + 10;\nonEachFrame\n{\n\tBFG lookAt (unitAimPosition player vectorAdd (velocity player vectorMultiply 0.2));\n\tif (time > t && alive player) then\n\t{\n\t\t[BFG,\"weapon_Cannon_Phalanx\",[0]] call BIS_fnc_fire;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["glanceAt","commandWatch","doWatch","freeLook"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"lookAtPos","operator":null,"title":"lookAtPos","type":"command","url":"https://community.bistudio.com/wiki/lookAtPos","revid":377146,"updated":"2026-01-01T10:33:39Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Point the camera and center the map on the position.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map lookAtPos position","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\nfindDisplay 12 displayCtrl 51 lookAtPos [0,0,0];\n```","code":["findDisplay 12 displayCtrl 51 lookAtPos [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"magazineCargo","operator":null,"title":"magazineCargo","type":"command","url":"https://community.bistudio.com/wiki/magazineCargo","revid":348708,"updated":"2023-11-08T14:29:30Z","groups":["Vehicle Inventory","Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with magazines from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"magazineCargo object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"}],"returns":{"type":"Array","types":["Array"],"description":"format: [\"MagType1\",\"MagType1\",\"MagType2\"...]","text":"Array - format: [\"MagType1\",\"MagType1\",\"MagType2\"...]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str magazineCargo uniformContainer cursorTarget;\n```","code":["hint str magazineCargo uniformContainer cursorTarget;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmoCargo","getMagazineCargo","addMagazineCargo","addMagazineCargoGlobal","clearMagazineCargo","clearMagazineCargoGlobal","weaponCargo","itemCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"magazines","operator":null,"title":"magazines","type":"command","url":"https://community.bistudio.com/wiki/magazines","revid":378372,"updated":"2026-04-03T16:50:03Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of type names of all vehicle's magazines. When applied to a unit, the command behaves differently and will omit magazines already loaded into unit's weapons. Use currentMagazine to get this information for a currently loaded magazine.","syntaxes":[{"syntax":"magazines vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"magazines [vehicle, includeEmpty]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mags = magazines player;\n```","code":["_mags = magazines player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazine","magazinesTurret","magazinesDetail","magazinesAmmo","magazinesAmmoFull","ammo","weapons","backpacks"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"magazinesAllTurrets","operator":null,"title":"magazinesAllTurrets","type":"command","url":"https://community.bistudio.com/wiki/magazinesAllTurrets","revid":377649,"updated":"2026-01-02T09:01:54Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all magazines (including empty) from all vehicle turrets (including driver turret [-1]) and their ammo counts. Since Arma 3 v2.08.148327 it is possible to exclude person turrets from returned results.","syntaxes":[{"syntax":"magazinesAllTurrets vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with turrets","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with turrets"}],"returns":{"type":"Array of Arrays with [className, turretPath, ammoCount, id, creator]","types":["Array"],"description":"className: String - magazine class name - turretPath: Turret Path - ammoCount: Number - how many rounds left in the magazine - id: Number - id of the magazine object. The number starts at 10,000,000. This gives it about 6,700,000 possible ids before the number starts losing precision and cannot be used in scripts. - creator: Number - owner / clientOwner of the PC that created the object","text":"Array of Arrays with [className, turretPath, ammoCount, id, creator]\n- className: String - magazine class name\n- turretPath: Turret Path\n- ammoCount: Number - how many rounds left in the magazine\n- id: Number - id of the magazine object. The number starts at 10,000,000. This gives it about 6,700,000 possible ids before the number starts losing precision and cannot be used in scripts.\n- creator: Number - owner / clientOwner of the PC that created the object"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"magazinesAllTurrets [vehicle, excludePersonTurrets]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with turrets","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with turrets"},{"name":"excludePersonTurrets","type":"Boolean","optional":false,"default":null,"description":"when true only vehicle's turrets are queried","types":["Boolean"],"since":null,"text":"excludePersonTurrets: Boolean - when true only vehicle's turrets are queried"}],"returns":{"type":"Array of Arrays with [className, turretPath, ammoCount, id, creator]","types":["Array"],"description":"className: String - magazine class name - turretPath: Turret Path - ammoCount: Number - how many rounds left in the magazine - id: Number - id of the magazine object. The number starts at 10,000,000. This gives it about 6,700,000 possible ids before the number starts losing precision and cannot be used in scripts. - creator: Number - owner / clientOwner of the PC that created the object","text":"Array of Arrays with [className, turretPath, ammoCount, id, creator]\n- className: String - magazine class name\n- turretPath: Turret Path\n- ammoCount: Number - how many rounds left in the magazine\n- id: Number - id of the magazine object. The number starts at 10,000,000. This gives it about 6,700,000 possible ids before the number starts losing precision and cannot be used in scripts.\n- creator: Number - owner / clientOwner of the PC that created the object"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, excludePersonTurrets]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mags = magazinesAllTurrets vehicle player;\n```","code":["_mags = magazinesAllTurrets vehicle player;"]},{"text":"```sqf\n_mags = magazinesAllTurrets [vehicle player, true];\n```","code":["_mags = magazinesAllTurrets [vehicle player, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesTurret","allTurrets","addMagazineTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","loadMagazine","magazines","magazinesDetail","magazinesAmmo","magazinesAmmoFull","addWeaponTurret","removeWeaponTurret","turretLocal","getPylonMagazines","ammoOnPylon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.52","Scripting Commands"]},{"name":"magazinesAmmo","operator":null,"title":"magazinesAmmo","type":"command","url":"https://community.bistudio.com/wiki/magazinesAmmo","revid":369329,"updated":"2024-09-03T18:43:00Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all vehicle's magazines and their ammo count (also works on supply boxes). When applied to a unit (soldier), the command behaves differently and will omit magazines already loaded into unit's weapons. Use magazinesAmmoFull to return all magazines.","syntaxes":[{"syntax":"magazinesAmmo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle or container. When transport is supplied, the command returns vehicle's magazines not the cargo. When container is supplied, the command behaves identically to magazinesAmmoCargo","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle or container. When transport is supplied, the command returns vehicle's magazines not the cargo. When container is supplied, the command behaves identically to magazinesAmmoCargo"}],"returns":{"type":"Array of Arrays in format:","types":["Array"],"description":"String: magazine class name - Number: magazine ammo count","text":"Array of Arrays in format:\n- String: magazine class name\n- Number: magazine ammo count"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"magazinesAmmo [vehicle, includeEmpty]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle.","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle."},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"}],"returns":{"type":"Array of Arrays in format:","types":["Array"],"description":"String: magazine class name - Number: magazine ammo count","text":"Array of Arrays in format:\n- String: magazine class name\n- Number: magazine ammo count"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\n_magazinesAmmo = magazinesAmmo player;\n/*\n[\n    [\"30Rnd_65x39_caseless_mag\",30],\n    [\"30Rnd_65x39_caseless_mag\",30],\n    [\"16Rnd_9x21_Mag\",16],\n    [\"SmokeShellGreen\",1],\n    [\"Chemlight_green\",1],\n    [\"HandGrenade\",1]\n]\n*/\n```","code":["_magazinesAmmo = magazinesAmmo player;\n/*\n[\n\t[\"30Rnd_65x39_caseless_mag\",30],\n\t[\"30Rnd_65x39_caseless_mag\",30],\n\t[\"16Rnd_9x21_Mag\",16],\n\t[\"SmokeShellGreen\",1],\n\t[\"Chemlight_green\",1],\n\t[\"HandGrenade\",1]\n]\n*/"]},{"text":"```sqf\n_magazinesAmmo = magazinesAmmo Mi_48;\n/*\n[\n    [\"250Rnd_30mm_APDS_shells\",250],\n    [\"250Rnd_30mm_HE_shells\",250],\n    [\"8Rnd_LG_scalpel\",8],\n    [\"38Rnd_80mm_rockets\",38]\n]\n*/\n```","code":["_magazinesAmmo = magazinesAmmo Mi_48;\n/*\n[\n\t[\"250Rnd_30mm_APDS_shells\",250],\n\t[\"250Rnd_30mm_HE_shells\",250],\n\t[\"8Rnd_LG_scalpel\",8],\n\t[\"38Rnd_80mm_rockets\",38]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmoFull","magazinesAmmoCargo","magazinesDetail","magazines","magazinesTurret"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.76","Scripting Commands"]},{"name":"magazinesAmmoCargo","operator":null,"title":"magazinesAmmoCargo","type":"command","url":"https://community.bistudio.com/wiki/magazinesAmmoCargo","revid":378412,"updated":"2026-04-04T08:33:25Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of subarrays with the type names and ammo left of all the vehicle's cargo or container magazines.","syntaxes":[{"syntax":"magazinesAmmoCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array of Arrays with [class, ammo]","types":["Array"],"description":"class: String - Class name of the magazine - ammo: Number - Number of rounds loaded","text":"Array of Arrays with [class, ammo]\n- class: String - Class name of the magazine\n- ammo: Number - Number of rounds loaded"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nmagazinesAmmoCargo vehicle player;\n```","code":["magazinesAmmoCargo vehicle player;"]},{"text":"```sqf\nmagazinesAmmoCargo uniformContainer player;\n```\n\n```sqf\n// returns:\n[\n    [\"30Rnd_65x39_caseless_mag\",30],\n    [\"30Rnd_65x39_caseless_mag\",30],\n    [\"Chemlight_green\",1]\n]\n```","code":["magazinesAmmoCargo uniformContainer player;","// returns:\n[\n\t[\"30Rnd_65x39_caseless_mag\",30],\n\t[\"30Rnd_65x39_caseless_mag\",30],\n\t[\"Chemlight_green\",1]\n]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmo","magazinesAmmoFull"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"magazinesAmmoFull","operator":null,"title":"magazinesAmmoFull","type":"command","url":"https://community.bistudio.com/wiki/magazinesAmmoFull","revid":343867,"updated":"2023-07-27T15:53:37Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of arrays of all unit's or vehicle's magazines with extended information about them.\nThe magazines returned are for primary gunner. If you need magazines for all turrets, see magazinesAllTurrets.\n\n> [!IMPORTANT]\n> This command does not return empty magazines from containers, only from the weapon. Use magazinesAmmoCargo instead.","syntaxes":[{"syntax":"magazinesAmmoFull entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle"}],"returns":{"type":"Array of Arrays in format:","types":["Array"],"description":"String: magazine class name - Number: magazine ammo count - Boolean: is magazine loaded - Number: magazine type: - -1 = n/a (default if magazine is not loaded) - 0 - grenade - 1 - primary weapon mag - 2 - handgun mag - 4 - secondary weapon mag - 4096 - binocular weapon mag - 65536 - vehicle mag - String: magazine location: \"Vest\", \"Uniform\", \"Backpack\", \"\" or currentMuzzle if the magazine is loaded - Arma 3 v2.08 Number: magazine id, starts with 10000000; use `toFixed 0;` to see this number in a human readable format - Arma 3 v2.08 Number: magazine creator","text":"Array of Arrays in format:\n- String: magazine class name\n- Number: magazine ammo count\n- Boolean: is magazine loaded\n- Number: magazine type:\n  - -1 = n/a (default if magazine is not loaded)\n  - 0 - grenade\n  - 1 - primary weapon mag\n  - 2 - handgun mag\n  - 4 - secondary weapon mag\n  - 4096 - binocular weapon mag\n  - 65536 - vehicle mag\n- String: magazine location: \"Vest\", \"Uniform\", \"Backpack\", \"\" or currentMuzzle if the magazine is loaded\n- Arma 3 v2.08 Number: magazine id, starts with 10000000; use `toFixed 0;` to see this number in a human readable format\n- Arma 3 v2.08 Number: magazine creator"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"magazinesAmmoFull [vehicle, includeEmpty]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"}],"returns":{"type":"same as Primary Syntax","types":["Primary Syntax"],"description":null,"text":"same as Primary Syntax"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\ntoFixed 0;\nmagazinesAmmoFull player;\n/*\n[\n    [\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Uniform\",10000003,0],\n    [\"Chemlight_green\",1,true,0,\"ChemlightGreenMuzzle\",10000016,0],\n    [\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000008,0],\n    [\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000009,0],\n    [\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000010,0],\n    [\"HandGrenade\",1,true,0,\"HandGrenadeMuzzle\",10000018,0],\n    [\"HandGrenade\",1,false,-1,\"Vest\",10000019,0],\n    [\"30Rnd_65x39_caseless_mag\",30,true,1,\"arifle_MX_ACO_pointer_F\",10000001,0],\n    [\"16Rnd_9x21_Mag\",16,true,2,\"hgun_P07_F\",10000011,0]\n]\n*/\n```","code":["toFixed 0;\nmagazinesAmmoFull player;\n/*\n[\n\t[\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Uniform\",10000003,0],\n\t[\"Chemlight_green\",1,true,0,\"ChemlightGreenMuzzle\",10000016,0],\n\t[\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000008,0],\n\t[\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000009,0],\n\t[\"30Rnd_65x39_caseless_mag\",30,false,-1,\"Vest\",10000010,0],\n\t[\"HandGrenade\",1,true,0,\"HandGrenadeMuzzle\",10000018,0],\n\t[\"HandGrenade\",1,false,-1,\"Vest\",10000019,0],\n\t[\"30Rnd_65x39_caseless_mag\",30,true,1,\"arifle_MX_ACO_pointer_F\",10000001,0],\n\t[\"16Rnd_9x21_Mag\",16,true,2,\"hgun_P07_F\",10000011,0]\n]\n*/"]},{"text":"```sqf\ntoFixed 0;\nmagazinesAmmoFull Mi_48;\n/*\n[\n    [\"250Rnd_30mm_HE_shells_Tracer_Green\",250,true,65536,\"HE\",10000043,0],\n    [\"250Rnd_30mm_APDS_shells_Tracer_Green\",250,true,65536,\"AP\",10000044,0],\n    [\"Laserbatteries\",1,true,65536,\"Laserdesignator_mounted\",10000045,0],\n    [\"PylonRack_4Rnd_LG_scalpel\",4,false,-1,\"\",10000049,0],\n    [\"PylonRack_19Rnd_Rocket_Skyfire\",19,false,-1,\"\",10000051,0],\n    [\"PylonRack_19Rnd_Rocket_Skyfire\",19,false,-1,\"\",10000052,0],\n    [\"PylonRack_4Rnd_LG_scalpel\",4,false,-1,\"\",10000053,0]\n]\n*/\n```","code":["toFixed 0;\nmagazinesAmmoFull Mi_48;\n/*\n[\n\t[\"250Rnd_30mm_HE_shells_Tracer_Green\",250,true,65536,\"HE\",10000043,0],\n\t[\"250Rnd_30mm_APDS_shells_Tracer_Green\",250,true,65536,\"AP\",10000044,0],\n\t[\"Laserbatteries\",1,true,65536,\"Laserdesignator_mounted\",10000045,0],\n\t[\"PylonRack_4Rnd_LG_scalpel\",4,false,-1,\"\",10000049,0],\n\t[\"PylonRack_19Rnd_Rocket_Skyfire\",19,false,-1,\"\",10000051,0],\n\t[\"PylonRack_19Rnd_Rocket_Skyfire\",19,false,-1,\"\",10000052,0],\n\t[\"PylonRack_4Rnd_LG_scalpel\",4,false,-1,\"\",10000053,0]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAmmo","magazinesAmmoCargo","magazinesDetail","magazines","magazinesTurret"],"notes":[{"user":"Actium","date":"2014-12-20T14:40:00Z","text":"When used on vehicles this will only return all magazines associated with a single turretPath (which one depends on the actual armament of the vehicle, usually the first armed turretPath or alternatively turretPath [-1]).\n\nIf you want to get all turrets' magazines, use allTurrets and magazinesTurret."},{"user":"Pierre MGI","date":"2015-02-10T04:40:00Z","text":"As Actium said, this function seems to extract data from:\n\n```sqf\nconfigFile >> \"CfgVehicles\" >> _the_vehicle_you_want >> \"Turrets\" >> \"MainTurret\">> \"magazines\"\n```\n\nSome vehicles return an empty field {} because magazines are in straight in:\n\n```sqf\nconfigFile >> \"CfgVehicles\" >> _the_vehicle_you_want >> \"magazines\" // often dedicated to flares only\n```\n\nThis is the case of WY-55 Hellcat. This function returns an empty array."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.76","Scripting Commands"]},{"name":"magazinesDetail","operator":null,"title":"magazinesDetail","type":"command","url":"https://community.bistudio.com/wiki/magazinesDetail","revid":377200,"updated":"2026-01-01T11:36:18Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of strings with description of all vehicle's magazines, their ammo count (current/default) and their ids for the primary gunner.\n\nWhen applied to a unit (soldier), the command behaves differently and will omit magazines already loaded into unit's weapons. Use currentMagazineDetail to get this information for a currently loaded magazine.","syntaxes":[{"syntax":"magazinesDetail vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"magazinesDetail [vehicle, includeEmpty, includeLoaded]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"},{"name":"includeLoaded","type":"Boolean","optional":true,"default":"false","description":"true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)","types":["Boolean"],"since":null,"text":"includeLoaded: Boolean - (Optional, default false) true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, includeEmpty, includeLoaded]","types":["Array"]}}],"examples":[{"text":"```sqf\n_magazinesDetail = magazinesDetail player;\n/*\n[\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000003/0]\",\n    \"Chemlight (Green)(1/1)[id/cr:10000020/0]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/0]\",\n    \"RGO Grenade(1/1)[id/cr:10000016/0]\",\n    \"RGO Grenade(1/1)[id/cr:10000017/0]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000070/0]\",\n    \"PCML Missile(1/1)[id/cr:10000072/0]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000001/0]\",\n    \"9 mm 16Rnd Mag(16/16)[id/cr:10000013/0]\"\n]\n*/\n```","code":["_magazinesDetail = magazinesDetail player;\n/*\n[\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000003/0]\",\n\t\"Chemlight (Green)(1/1)[id/cr:10000020/0]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/0]\",\n\t\"RGO Grenade(1/1)[id/cr:10000016/0]\",\n\t\"RGO Grenade(1/1)[id/cr:10000017/0]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000070/0]\",\n\t\"PCML Missile(1/1)[id/cr:10000072/0]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000001/0]\",\n\t\"9 mm 16Rnd Mag(16/16)[id/cr:10000013/0]\"\n]\n*/"]},{"text":"```sqf\n_magazinesDetail = magazinesDetail Mi_48;\n/*\n[\n    \"30 mm HE Tracer (Green) Shells(250/250)[id/cr:10000043/0]\",\n    \"30 mm APDS Tracer (Green) Shells(250/250)[id/cr:10000044/0]\",\n    \"Designator Batteries(1/1)[id/cr:10000045/0]\",\n    \"Scalpel 4x(4/4)[id/cr:10000049/0]\",\n    \"Skyfire 19x(19/19)[id/cr:10000051/0]\",\n    \"Skyfire 19x(19/19)[id/cr:10000052/0]\",\n    \"Scalpel 4x(4/4)[id/cr:10000053/0]\"\n]\n*/\n```","code":["_magazinesDetail = magazinesDetail Mi_48;\n/*\n[\n\t\"30 mm HE Tracer (Green) Shells(250/250)[id/cr:10000043/0]\",\n\t\"30 mm APDS Tracer (Green) Shells(250/250)[id/cr:10000044/0]\",\n\t\"Designator Batteries(1/1)[id/cr:10000045/0]\",\n\t\"Scalpel 4x(4/4)[id/cr:10000049/0]\",\n\t\"Skyfire 19x(19/19)[id/cr:10000051/0]\",\n\t\"Skyfire 19x(19/19)[id/cr:10000052/0]\",\n\t\"Scalpel 4x(4/4)[id/cr:10000053/0]\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentMagazineDetail","magazines","magazinesTurret","magazinesAmmo","magazinesAmmoFull","magazinesDetailUniform","magazinesDetailVest","magazinesDetailBackpack"],"notes":[{"user":"Leopard20","date":"2021-09-12T22:06:40Z","text":"To return the ammo count in each magazine, you can use this code:\n\n```sqf\nmagazinesDetail player apply {\n    private _reverse = reverse _x;\n    private_i1 = (_reverse find \"[)\") + 1;\n    private_i2 = (_reverse find [\"/\", _id1]) + 1;\n    private_i3 = _reverse find [\"(\", _id2];\n    parseNumber reverse (_reverse select [_i2, _i3 - _i2]); // return cnt\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"magazinesDetailBackpack","operator":null,"title":"magazinesDetailBackpack","type":"command","url":"https://community.bistudio.com/wiki/magazinesDetailBackpack","revid":377201,"updated":"2026-01-01T11:36:34Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with the type names of all the unit's backpack magazines.","syntaxes":[{"syntax":"magazinesDetailBackpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"magazinesDetailBackpack [unit, includeEmpty, includeLoaded]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"},{"name":"includeLoaded","type":"Boolean","optional":true,"default":"false","description":"true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)","types":["Boolean"],"since":null,"text":"includeLoaded: Boolean - (Optional, default false) true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, includeEmpty, includeLoaded]","types":["Array"]}}],"examples":[{"text":"```sqf\nmagazinesDetailBackpack player;\n/*\n[\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000011/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/2]\",\n    \"Chemlight (Green)(1/1)[id/cr:10000027/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000013/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000014/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000015/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000016/2]\",\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000017/2]\",\n    \"9 mm 16Rnd Mag(16/16)[id/cr:10000019/2]\",\n    \"9 mm 16Rnd Mag(16/16)[id/cr:10000020/2]\",\n    \"RGO Grenade(1/1)[id/cr:10000021/2]\",\n    \"RGO Grenade(1/1)[id/cr:10000022/2]\",\n    \"IR Grenade [NATO](1/1)[id/cr:10000023/2]\",\n    \"IR Grenade [NATO](1/1)[id/cr:10000024/2]\",\n    \"Smoke Grenade (White)(1/1)[id/cr:10000025/2]\",\n    \"Smoke Grenade (Green)(1/1)[id/cr:10000026/2]\",\n    \"Chemlight (Green)(1/1)[id/cr:10000028/2]\"\n]\n*/\n```","code":["magazinesDetailBackpack player;\n/*\n[\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000011/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/2]\",\n\t\"Chemlight (Green)(1/1)[id/cr:10000027/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000013/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000014/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000015/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000016/2]\",\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000017/2]\",\n\t\"9 mm 16Rnd Mag(16/16)[id/cr:10000019/2]\",\n\t\"9 mm 16Rnd Mag(16/16)[id/cr:10000020/2]\",\n\t\"RGO Grenade(1/1)[id/cr:10000021/2]\",\n\t\"RGO Grenade(1/1)[id/cr:10000022/2]\",\n\t\"IR Grenade [NATO](1/1)[id/cr:10000023/2]\",\n\t\"IR Grenade [NATO](1/1)[id/cr:10000024/2]\",\n\t\"Smoke Grenade (White)(1/1)[id/cr:10000025/2]\",\n\t\"Smoke Grenade (Green)(1/1)[id/cr:10000026/2]\",\n\t\"Chemlight (Green)(1/1)[id/cr:10000028/2]\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesDetail","magazinesDetailUniform","magazinesDetailVest","currentMagazineDetail"],"notes":[{"user":"Leopard20","date":"2021-09-12T22:07:55Z","text":"To return the ammo count in each magazine, you can use this code:\n\n```sqf\nmagazinesDetailBackpack player apply {\n    private _reverse = reverse _x;\n    private_i1 = (_reverse find \"[)\") + 1;\n    private_i2 = (_reverse find [\"/\", _id1]) + 1;\n    private_i3 = _reverse find [\"(\", _id2];\n    parseNumber reverse (_reverse select [_i2, _i3 - _i2]); // return cnt\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"magazinesDetailUniform","operator":null,"title":"magazinesDetailUniform","type":"command","url":"https://community.bistudio.com/wiki/magazinesDetailUniform","revid":377202,"updated":"2026-01-01T11:36:50Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with the type names of all the unit's uniform magazines.","syntaxes":[{"syntax":"magazinesDetailUniform unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"magazinesDetailUniform [unit, includeEmpty, includeLoaded]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"},{"name":"includeLoaded","type":"Boolean","optional":true,"default":"false","description":"true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)","types":["Boolean"],"since":null,"text":"includeLoaded: Boolean - (Optional, default false) true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, includeEmpty, includeLoaded]","types":["Array"]}}],"examples":[{"text":"```sqf\nmagazinesDetailUniform player;\n/*\n[\n    \"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000003/0]\",\n    \"Chemlight (Green)(1/1)[id/cr:10000020/0]\"\n]\n*/\n```","code":["magazinesDetailUniform player;\n/*\n[\n\t\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000003/0]\",\n\t\"Chemlight (Green)(1/1)[id/cr:10000020/0]\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesDetail","magazinesDetailVest","magazinesDetailBackpack"],"notes":[{"user":"Leopard20","date":"2021-09-12T22:07:51Z","text":"To return the ammo count in each magazine, you can use this code:\n\n```sqf\nmagazinesDetailUniform player apply {\n    private _reverse = reverse _x;\n    private_i1 = (_reverse find \"[)\") + 1;\n    private_i2 = (_reverse find [\"/\", _id1]) + 1;\n    private_i3 = _reverse find [\"(\", _id2];\n    parseNumber reverse (_reverse select [_i2, _i3 - _i2]); // return cnt\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"magazinesDetailVest","operator":null,"title":"magazinesDetailVest","type":"command","url":"https://community.bistudio.com/wiki/magazinesDetailVest","revid":377203,"updated":"2026-01-01T11:37:09Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with the type names of all the unit's vest magazines.","syntaxes":[{"syntax":"magazinesDetailVest unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"magazinesDetailVest [unit, includeEmpty, includeLoaded]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"true to include empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default false) true to include empty magazines"},{"name":"includeLoaded","type":"Boolean","optional":true,"default":"false","description":"true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)","types":["Boolean"],"since":null,"text":"includeLoaded: Boolean - (Optional, default false) true to include magazines loaded in weapons (Since Arma 3 v2.07.148195)"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, includeEmpty, includeLoaded]","types":["Array"]}}],"examples":[{"text":"```sqf\nmagazinesDetailVest player;\n/*\n[\n    [\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/0]\",\n    \"RGO Grenade(1/1)[id/cr:10000016/0]\",\n    \"RGO Grenade(1/1)[id/cr:10000017/0]\"]\n]\n*/\n```","code":["magazinesDetailVest player;\n/*\n[\n\t[\"6.5 mm 30Rnd Sand Mag(30/30)[id/cr:10000012/0]\",\n\t\"RGO Grenade(1/1)[id/cr:10000016/0]\",\n\t\"RGO Grenade(1/1)[id/cr:10000017/0]\"]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesDetail","magazinesDetailUniform","magazinesDetailBackpack"],"notes":[{"user":"Leopard20","date":"2021-09-12T22:07:44Z","text":"To return the ammo count in each magazine, you can use this code:\n\n```sqf\nmagazinesDetailVest player apply {\n    private _reverse = reverse _x;\n    private _i1 = (_reverse find \"[)\") + 1;\n    private _i2 = (_reverse find [\"/\", _id1]) + 1;\n    private _i3 = _reverse find [\"(\", _id2];\n    parseNumber reverse (_reverse select [_i2, _i3 - _i2]); // return cnt\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"magazinesTurret","operator":null,"title":"magazinesTurret","type":"command","url":"https://community.bistudio.com/wiki/magazinesTurret","revid":377498,"updated":"2026-01-02T06:49:25Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all magazines of given turret. Use turret path [-1] for driver's turret. Alternatively, use magazinesAllTurrets.\n\n> [!NOTE]\n> When main syntax is used, command excludes empty magazines for driver turret [-1] but returns empty magazines for all the other turrets.","syntaxes":[{"syntax":"vehicle magazinesTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}},{"syntax":"vehicle magazinesTurret [turretPath, includeEmpty]","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"true","description":"true = include empty magazines (behaviour as the primary syntax, but consistent), false = exclude empty magazines","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default true) - true = include empty magazines (behaviour as the primary syntax, but consistent), false = exclude empty magazines"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turretPath, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mags = vehicle player magazinesTurret [0, 0];\n```","code":["_mags = vehicle player magazinesTurret [0, 0];"]},{"text":"```sqf\n_mags = _tank magazinesTurret [[0], false];\n```","code":["_mags = _tank magazinesTurret [[0], false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazinesAllTurrets","addMagazineTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","loadMagazine","magazines","magazinesDetail","magazinesAmmo","magazinesAmmoFull","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2: Operation Arrowhead version 1.52","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"magazineTurretAmmo","operator":null,"title":"magazineTurretAmmo","type":"command","url":"https://community.bistudio.com/wiki/magazineTurretAmmo","revid":377502,"updated":"2026-01-02T06:49:31Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns ammo count of given magazine from given turret (see setMagazineTurretAmmo for more info)","syntaxes":[{"syntax":"vehicle magazineTurretAmmo [magazineClass, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineClass","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineClass: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"[-1] for driver turret is supported","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - [-1] for driver turret is supported"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineClass, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player magazineTurretAmmo [\"cls\", [0]];\n```","code":["vehicle player magazineTurretAmmo [\"cls\", [0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMagazineTurretAmmo","magazinesAllTurrets","ammoOnPylon"],"notes":[{"user":"Sa-Matra","date":"2024-05-04T11:38:40Z","text":"Returns ammo for first magazine, not loaded magazine."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"mapAnimAdd","operator":null,"title":"mapAnimAdd","type":"command","url":"https://community.bistudio.com/wiki/mapAnimAdd","revid":377554,"updated":"2026-01-02T06:54:54Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Add next frame to map animation.","syntaxes":[{"syntax":"mapAnimAdd [time, zoom, position]","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"animation duration in seconds","types":["Number"],"since":null,"text":"time: Number - animation duration in seconds"},{"name":"zoom","type":"Number","optional":false,"default":null,"description":"range from 0.01 (max. zoom) to 1 (zoomed out)","types":["Number"],"since":null,"text":"zoom: Number - range from 0.01 (max. zoom) to 1 (zoomed out)"},{"name":"position","type":"Object or Position2D, Position3D","optional":false,"default":null,"description":null,"types":["Object","Position2D","Position3D"],"since":null,"text":"position: Object or Position2D, Position3D"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[time, zoom, position]","types":["Array"]}}],"examples":[{"text":"```sqf\nmapAnimAdd [1, 0.1, markerPos \"anim1\"];\nmapAnimCommit;\n```","code":["mapAnimAdd [1, 0.1, markerPos \"anim1\"];\nmapAnimCommit;"]},{"text":"```sqf\nmapAnimAdd [3, 0.01, player];\nmapAnimCommit;\n```","code":["mapAnimAdd [3, 0.01, player];\nmapAnimCommit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimClear","mapAnimCommit","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[{"user":"Ceeeb","date":"2007-02-02T05:26:00Z","text":"In **OFP v1.96**, the mapAnim series of commands, together with forceMap can only be used in the intro and mission, as it is not possible to access the map from the outro. *(not checked, sourced from an old copy of the OFPEC comref)*"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Introduced with Operation Flashpoint version 1.27","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"mapAnimClear","operator":null,"title":"mapAnimClear","type":"command","url":"https://community.bistudio.com/wiki/mapAnimClear","revid":319460,"updated":"2022-05-13T09:24:07Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Clear map animation.","syntaxes":[{"syntax":"mapAnimClear","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nmapAnimClear;\n```","code":["mapAnimClear;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimCommit","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Introduced with Operation Flashpoint version 1.27","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"mapAnimCommit","operator":null,"title":"mapAnimCommit","type":"command","url":"https://community.bistudio.com/wiki/mapAnimCommit","revid":319497,"updated":"2022-05-13T09:24:11Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Play map animation.","syntaxes":[{"syntax":"mapAnimCommit","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nmapAnimCommit;\n```","code":["mapAnimCommit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimClear","mapAnimDone","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands"]},{"name":"mapAnimDone","operator":null,"title":"mapAnimDone","type":"command","url":"https://community.bistudio.com/wiki/mapAnimDone","revid":310810,"updated":"2022-05-07T20:22:01Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Check if map animation is finished.","syntaxes":[{"syntax":"mapAnimDone","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _isDone = mapAnimDone;\n```","code":["private _isDone = mapAnimDone;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["mapAnimAdd","mapAnimClear","mapAnimCommit","ctrlMapAnimAdd","ctrlMapAnimClear","ctrlMapAnimCommit","ctrlMapAnimDone"],"notes":[],"categories":[]},{"name":"mapCenterOnCamera","operator":null,"title":"mapCenterOnCamera","type":"command","url":"https://community.bistudio.com/wiki/mapCenterOnCamera","revid":377461,"updated":"2026-01-02T06:47:30Z","groups":["GUI Control - Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.02"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.02"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The main syntax enables/disables continuous centering of the main map type control on the camera position. Needs to be executed once.\n\nThe alternative syntax centers mini map type control on camera. Needs to be executed each frame (preferably inside an `onDraw` event handler).","syntaxes":[{"syntax":"mainmap mapCenterOnCamera enable","since":null,"effect":null,"exec":null,"params":[{"name":"mainmap","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"mainmap: Control"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"mainmap","types":["Control"]},"right":{"text":"enable","types":["Boolean"]}},{"syntax":"mapCenterOnCamera minimap","since":"arma3 1.48","effect":null,"exec":null,"params":[{"name":"minimap","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"minimap: Control"}],"returns":{"type":null,"types":["PositionASL","getPosWorld"],"description":null,"text":"PositionASL of the map center (camera focus object's **model centre**'s position (see getPosWorld)) in render scope"},"form":"unary","operator":null,"left":null,"right":{"text":"minimap","types":["Control"]}}],"examples":[{"text":"```sqf\n// --- Minimap update\n((uiNamespace getVariable \"BIS_UAV_DISPLAY\") displayCtrl 112410) mapCenterOnCamera true;\n```","code":["// --- Minimap update\n((uiNamespace getVariable \"BIS_UAV_DISPLAY\") displayCtrl 112410) mapCenterOnCamera true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ctrlMapAnimAdd","ctrlMapAnimCommit","getPosWorld"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Introduced with Arma 2 version 1.02","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"mapGridPosition","operator":null,"title":"mapGridPosition","type":"command","url":"https://community.bistudio.com/wiki/mapGridPosition","revid":319458,"updated":"2022-05-13T09:24:06Z","groups":["Positions","Map"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.04"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the map grid position of an object or position.\n\nThe format is determined by the Grid format specified in the CfgWorlds for the current world. Eg: \"024577\" or \"De82\" or similar.","syntaxes":[{"syntax":"mapGridPosition param","since":null,"effect":null,"exec":null,"params":[{"name":"param","type":"Object or Position","optional":false,"default":null,"description":"determines reference position","types":["Object","Position"],"since":null,"text":"param: Object or Position - determines reference position"}],"returns":{"type":"String","types":["String"],"description":"grid position","text":"String - grid position"},"form":"unary","operator":null,"left":null,"right":{"text":"param","types":["Object","Position"]}}],"examples":[{"text":"```sqf\n_gridPos = mapGridPosition player;\n```","code":["_gridPos = mapGridPosition player;"]},{"text":"```sqf\n_gridPos = mapGridPosition getPos player;\n```","code":["_gridPos = mapGridPosition getPos player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_gridToPos","BIS_fnc_posToGrid"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Command Group: Positions","Introduced with Arma 2 version 1.04","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markAsFinishedOnSteam","operator":null,"title":"markAsFinishedOnSteam","type":"command","url":"https://community.bistudio.com/wiki/markAsFinishedOnSteam","revid":369150,"updated":"2024-09-03T10:34:38Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Marks current mission as finished on Steam. Returns true if Steam query is successfully started or false otherwise.","syntaxes":[{"syntax":"markAsFinishedOnSteam","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nmarkAsFinishedOnSteam;\nendMission \"END1\";\n```","code":["markAsFinishedOnSteam;\nendMission \"END1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isSteamMission"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"markerAlpha","operator":null,"title":"markerAlpha","type":"command","url":"https://community.bistudio.com/wiki/markerAlpha","revid":363255,"updated":"2024-03-26T10:51:30Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets the marker alpha. See setMarkerAlpha.","syntaxes":[{"syntax":"markerAlpha markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nAlphaMarker = markerAlpha \"myMarker\";\n```","code":["AlphaMarker = markerAlpha \"myMarker\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlpha","setMarkerAlphaLocal"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markerBrush","operator":null,"title":"markerBrush","type":"command","url":"https://community.bistudio.com/wiki/markerBrush","revid":322955,"updated":"2022-06-28T21:42:49Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the marker brush. See setMarkerBrush.","syntaxes":[{"syntax":"markerBrush name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"marker name","types":["String"],"since":null,"text":"name: String - marker name"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nif (markerBrush \"Marker1\" == \"Solid\") then { hint \"Marker1 is solid!\" };\n```","code":["if (markerBrush \"Marker1\" == \"Solid\") then { hint \"Marker1 is solid!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerBrush","setMarkerBrushLocal"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markerChannel","operator":null,"title":"markerChannel","type":"command","url":"https://community.bistudio.com/wiki/markerChannel","revid":369657,"updated":"2024-10-01T12:04:41Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the channel to which a marker belongs.","syntaxes":[{"syntax":"markerChannel marker","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"marker","types":["String"]}}],"examples":[{"text":"```sqf\nmarkerChannel \"marker_1\";\n```","code":["markerChannel \"marker_1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createMarker","Channel IDs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"markerColor","operator":null,"title":"markerColor","type":"command","url":"https://community.bistudio.com/wiki/markerColor","revid":370049,"updated":"2024-10-29T12:21:16Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.46"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.46"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns colour of the given marker. See also setMarkerColor/Local.","syntaxes":[{"syntax":"markerColor markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nif (markerColor \"Marker1\" == \"ColorRed\") then { hint \"Marker1 is red!\" };\n```","code":["if (markerColor \"Marker1\" == \"ColorRed\") then { hint \"Marker1 is red!\" };"]},{"text":"```sqf\n\"mySuperMarker\" setMarkerColor \"#(0,1000,0,0.50000)\";    // full green, 50% alpha\nprivate _colour = markerColor \"mySuperMarker\";            // return properly-formatted custom value, here #(0,1,0,0.5)\nif (_colour select [0, 1] == \"#\") then { hint \"this marker has a custom colour!\" };\n```","code":["\"mySuperMarker\" setMarkerColor \"#(0,1000,0,0.50000)\";\t// full green, 50% alpha\nprivate _colour = markerColor \"mySuperMarker\";\t\t\t// return properly-formatted custom value, here #(0,1,0,0.5)\nif (_colour select [0, 1] == \"#\") then { hint \"this marker has a custom colour!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerColor","setMarkerColorLocal"],"notes":[],"categories":[]},{"name":"markerDir","operator":null,"title":"markerDir","type":"command","url":"https://community.bistudio.com/wiki/markerDir","revid":377913,"updated":"2026-01-09T17:40:49Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get marker direction.","syntaxes":[{"syntax":"markerDir markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\n_mPos = markerDir \"markerOne\";\n```","code":["_mPos = markerDir \"markerOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerDir","setMarkerDirLocal"],"notes":[{"user":"Inkompetent","date":"2010-04-18T13:44:00Z","text":"The direction of the marker is the same as displayed in the editor, so it can both be negative, and be 360 degrees or greater."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markerDrawPriority","operator":null,"title":"markerDrawPriority","type":"command","url":"https://community.bistudio.com/wiki/markerDrawPriority","revid":351284,"updated":"2023-11-27T02:52:20Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns marker draw priority.","syntaxes":[{"syntax":"markerDrawPriority markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Number","types":["Number"],"description":"draw priority","text":"Number - draw priority"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nmarkerDrawPriority \"MarkerOne\"\n```","code":["markerDrawPriority \"MarkerOne\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerDrawPriority","setMarkerType","setMarkerTypeLocal","markerType","setMarkerAlphaLocal","setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","createMarker","CfgMarkers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"markerPolyline","operator":null,"title":"markerPolyline","type":"command","url":"https://community.bistudio.com/wiki/markerPolyline","revid":377288,"updated":"2026-01-02T06:37:29Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a polyline marker's path data.","syntaxes":[{"syntax":"markerPolyline marker","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"}],"returns":{"type":"Array format `[x1, y1, x2, y2, ... xn, yn]`","types":["Array"],"description":null,"text":"Array format `[x1, y1, x2, y2, ... xn, yn]`"},"form":"unary","operator":null,"left":null,"right":{"text":"marker","types":["String"]}}],"examples":[{"text":"```sqf\nmarkerPolyline \"_USER_DEFINED #0/0/1\"; // returns your first polyline's data in Singleplayer\n```","code":["markerPolyline \"_USER_DEFINED #0/0/1\"; // returns your first polyline's data in Singleplayer"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerPolyline","setMarkerPolylineLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"markerPos","operator":null,"title":"markerPos","type":"command","url":"https://community.bistudio.com/wiki/markerPos","revid":377420,"updated":"2026-01-02T06:45:30Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.46"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.46"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns marker position. See also setMarkerPos.","syntaxes":[{"syntax":"markerPos markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"[x, y, 0], z is always 0","text":"PositionAGL - [x, y, **0**], z is always 0"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}},{"syntax":"markerPos [markerName, preserveElevation]","since":"arma3 1.94","effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"preserveElevation","type":"Boolean","optional":true,"default":"false","description":null,"types":["Boolean"],"since":null,"text":"preserveElevation: Boolean - (Optional, default false)"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"if preserveElevation is true or [x, y, 0] if preserveElevation is false","text":"PositionAGL - if *preserveElevation* is true or [x, y, **0**] if *preserveElevation* is false"},"form":"unary","operator":null,"left":null,"right":{"text":"[markerName, preserveElevation]","types":["Array"]}}],"examples":[{"text":"```sqf\n_mPos1 = markerPos \"markerOne\";\n```","code":["_mPos1 = markerPos \"markerOne\";"]},{"text":"```sqf\n_mPos2 = markerPos [\"markerTwo\", true];\n```","code":["_mPos2 = markerPos [\"markerTwo\", true];"]}],"multiplayer":null,"problems":null,"aliases":["getMarkerPos"],"see_also":["setMarkerPos","setMarkerPosLocal"],"notes":[],"categories":[]},{"name":"markerShadow","operator":null,"title":"markerShadow","type":"command","url":"https://community.bistudio.com/wiki/markerShadow","revid":349196,"updated":"2023-11-08T14:50:41Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if the marker is drawn with shadow enabled.","syntaxes":[{"syntax":"markerShadow marker","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":"the marker","types":["String"],"since":null,"text":"marker: String - the marker"}],"returns":{"type":"Boolean: true if marker is enabled, false if not","types":["Boolean","true","false"],"description":null,"text":"Boolean: true if marker is enabled, false if not"},"form":"unary","operator":null,"left":null,"right":{"text":"marker","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _shadowEnabled = markerShadow _myMarker;\n```","code":["private _shadowEnabled = markerShadow _myMarker;"]}],"multiplayer":null,"problems":"setMarkerType will reset the shadow value to the one defined in marker type.","aliases":[],"see_also":["setMarkerShadow","setMarkerShadowLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"markerShape","operator":null,"title":"markerShape","type":"command","url":"https://community.bistudio.com/wiki/markerShape","revid":378609,"updated":"2026-05-13T15:29:58Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the shape of given marker. markerShape#Example_2\n\n> [!NOTE]\n> This command can be used as a fast way to check if a marker exists. See #Example 2.","syntaxes":[{"syntax":"markerShape name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"name of the marker","types":["String"],"since":null,"text":"name: String - name of the marker"}],"returns":{"type":"String","types":["String"],"description":"shape of given marker. Can be return: - `\"\"` - if the marker does not exist - `\"ICON\"` - `\"RECTANGLE\"` - `\"ELLIPSE\"` - Arma 3 v1.60 `\"POLYLINE\"` - hand drawn markers - Arma 3 v2.20 `\"TRIANGLE\"` - Arma 3 v2.20 `\"PENTAGON\"` - Arma 3 v2.20 `\"HEXAGON\"` - Arma 3 v2.20 `\"HEPTAGON\"` - Arma 3 v2.20 `\"OCTAGON\"` - Arma 3 v2.20 `\"NONAGON\"` - Arma 3 v2.20 `\"DECAGON\"`","text":"String - shape of given marker. Can be return:\n- `\"\"` - if the marker does not exist\n- `\"ICON\"`\n- `\"RECTANGLE\"`\n- `\"ELLIPSE\"`\n- Arma 3 v1.60 `\"POLYLINE\"` - hand drawn markers\n- Arma 3 v2.20 `\"TRIANGLE\"`\n- Arma 3 v2.20 `\"PENTAGON\"`\n- Arma 3 v2.20 `\"HEXAGON\"`\n- Arma 3 v2.20 `\"HEPTAGON\"`\n- Arma 3 v2.20 `\"OCTAGON\"`\n- Arma 3 v2.20 `\"NONAGON\"`\n- Arma 3 v2.20 `\"DECAGON\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nif (markerShape \"Marker1\" == \"RECTANGLE\") then { hint \"Marker1 is a rectangle!\" };\n```","code":["if (markerShape \"Marker1\" == \"RECTANGLE\") then { hint \"Marker1 is a rectangle!\" };"]},{"text":"```sqf\nif (markerShape \"Marker1\" == \"\") then { hint \"Marker1 does not exist!\" };\n```","code":["if (markerShape \"Marker1\" == \"\") then { hint \"Marker1 does not exist!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerShape","setMarkerShapeLocal"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markerSize","operator":null,"title":"markerSize","type":"command","url":"https://community.bistudio.com/wiki/markerSize","revid":377691,"updated":"2026-01-02T09:03:12Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns marker size. This command is identical to getMarkerSize.","syntaxes":[{"syntax":"markerSize markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"Array with [a_axis, b_axis]","types":["Array"],"description":"a_axis: Number - 1/2 width of marker - b_axis: Number - 1/2 height of marker","text":"Array with [a_axis, b_axis]\n- a_axis: Number - 1/2 width of marker\n- b_axis: Number - 1/2 height of marker"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\n_mSize = markerSize \"Marker1\";\n```","code":["_mSize = markerSize \"Marker1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerSize","setMarkerSizeLocal"],"notes":[],"categories":[]},{"name":"markerText","operator":null,"title":"markerText","type":"command","url":"https://community.bistudio.com/wiki/markerText","revid":308978,"updated":"2022-04-22T13:12:44Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Get marker text.","syntaxes":[{"syntax":"markerText markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nhint format [\"Marker Text: %1\", markerText \"Marker1\"];\n```","code":["hint format [\"Marker Text: %1\", markerText \"Marker1\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerText","setMarkerTextLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"markerType","operator":null,"title":"markerType","type":"command","url":"https://community.bistudio.com/wiki/markerType","revid":348839,"updated":"2023-11-08T14:39:09Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Gets type of marker. See CfgMarkers for a list of standard markers.","syntaxes":[{"syntax":"markerType markerName","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"}],"returns":{"type":"String","types":["String"],"description":"marker class name. See CfgMarkers.","text":"String - marker class name. See CfgMarkers."},"form":"unary","operator":null,"left":null,"right":{"text":"markerName","types":["String"]}}],"examples":[{"text":"```sqf\nif (markerType \"Marker1\" == \"\") then { hint \"Marker1 is not an icon!\" };\n```","code":["if (markerType \"Marker1\" == \"\") then { hint \"Marker1 is not an icon!\" };"]}],"multiplayer":null,"problems":null,"aliases":["getMarkerType"],"see_also":["setMarkerType","setMarkerTypeLocal"],"notes":[],"categories":[]},{"name":"matrixMultiply","operator":null,"title":"matrixMultiply","type":"command","url":"https://community.bistudio.com/wiki/matrixMultiply","revid":364807,"updated":"2024-06-15T13:13:13Z","groups":["Math","Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns resulting matrix from the [multiplication](https://en.wikipedia.org/wiki/Matrix_multiplication) of two matrices. First matrix must be of the size n × **k**, while the second must be of the size **k** × m, i.e `columns` matrix1 == `rows` matrix2. The resulting matrix will be of the size n × m. If the shapes do not match, empty array [] will be returned.","syntaxes":[{"syntax":"matrix1 matrixMultiply matrix2","since":null,"effect":null,"exec":null,"params":[{"name":"matrix1","type":"Array of Array of Numbers","optional":false,"default":null,"description":"matrix of the size `n`*(rows)* × `k`*(columns)*","types":["Array","Number"],"since":null,"text":"matrix1: Array of Array of Numbers - matrix of the size `n`*(rows)* × `k`*(columns)*"},{"name":"matrix2","type":"Array of Array of Numbers","optional":false,"default":null,"description":"matrix of the size `k`*(rows)* × `m`*(columns)*","types":["Array","Number"],"since":null,"text":"matrix2: Array of Array of Numbers - matrix of the size `k`*(rows)* × `m`*(columns)*"}],"returns":{"type":"Array of Array of Numbers","types":["Array","Number"],"description":"resulting matrix of the size `n`(rows) × `m`(columns)","text":"Array of Array of Numbers - resulting matrix of the size `n`*(rows)* × `m`*(columns)*"},"form":"binary","operator":null,"left":{"text":"matrix1","types":["Array","Number"]},"right":{"text":"matrix2","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n[\n    [2],\n    [2]\n] \nmatrixMultiply \n[\n    [3] \n]\n/* returns \n[\n    [6],\n    [6]\n] */\n```","code":["[\n\t[2],\n\t[2]\n] \nmatrixMultiply \n[\n\t[3] \n]\n/* returns \n[\n\t[6],\n\t[6]\n] */"]},{"text":"```sqf\n[\n    [-1,0,0],\n    [0,-1,0]\n] \nmatrixMultiply \n[\n    [1,2],\n    [3,1],\n    [2,3]\n] \n/* returns \n[\n    [-1,-2],\n    [-3,-1]\n] */\n```","code":["[\n\t[-1,0,0],\n\t[0,-1,0]\n] \nmatrixMultiply \n[\n\t[1,2],\n\t[3,1],\n\t[2,3]\n] \n/* returns \n[\n\t[-1,-2],\n\t[-3,-1]\n] */"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["matrixTranspose","vectorAdd","vectorMagnitude","vectorNormalized","vectorMultiply","vectorDotProduct","vectorCrossProduct","vectorDistance","vectorLinearConversion","vectorCos","vectorFromTo","vectorModelToWorld","vectorWorldToModel","BIS_fnc_transformVectorDirAndUp"],"notes":[{"user":"oOKexOo","date":"2019-06-30T03:53:00Z","text":"Note that this command won't automatically transform a 1D array into a column vector\n\n```sqf\n[[-1,0,0],[0,-1,0],[0,0,-1]] matrixMultiply [1,2,3] // wrong, syntax error\n[[-1,0,0],[0,-1,0],[0,0,-1]] matrixMultiply [[1,2,3]] // wrong, will return []\n[[-1,0,0],[0,-1,0],[0,0,-1]] matrixMultiply [[1], [2], [3]] // correct, will return [[-1], [-2], [-3]]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Math - Vectors","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"matrixTranspose","operator":null,"title":"matrixTranspose","type":"command","url":"https://community.bistudio.com/wiki/matrixTranspose","revid":364808,"updated":"2024-06-15T13:13:33Z","groups":["Math","Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns [transposed](https://en.wikipedia.org/wiki/Transpose) version of the given matrix.\nThe matrix is an Array of rows.\nEach row is an Array of corresponding column values for the row. The minimum number of rows is 1.","syntaxes":[{"syntax":"matrixTranspose matrix","since":null,"effect":null,"exec":null,"params":[{"name":"matrix","type":"Array of Array of Numbers","optional":false,"default":null,"description":"given matrix","types":["Array","Number"],"since":null,"text":"matrix: Array of Array of Numbers - given matrix"}],"returns":{"type":"Array of Array of Numbers","types":["Array","Number"],"description":"transposed matrix","text":"Array of Array of Numbers - transposed matrix"},"form":"unary","operator":null,"left":null,"right":{"text":"matrix","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nmatrixTranspose \n[\n    [1,2,3], \n    [3,1,2], \n    [2,3,1]\n];\n/* returns \n[\n    [1,3,2], \n    [2,1,3], \n    [3,2,1]\n] */\n```","code":["matrixTranspose \n[\n\t[1,2,3], \n\t[3,1,2], \n\t[2,3,1]\n];\n/* returns \n[\n\t[1,3,2], \n\t[2,1,3], \n\t[3,2,1]\n] */"]},{"text":"```sqf\nmatrixTranspose \n[\n    [1,2,3]\n];\n/* returns \n[\n    [1],\n    [2],\n    [3]\n] */\n```","code":["matrixTranspose \n[\n\t[1,2,3]\n];\n/* returns \n[\n\t[1],\n\t[2],\n\t[3]\n] */"]},{"text":"```sqf\nmatrixTranspose \n[\n    [1],\n    [2],\n    [3]\n];\n/* returns \n[\n    [1,2,3]\n] */\n```","code":["matrixTranspose \n[\n\t[1],\n\t[2],\n\t[3]\n];\n/* returns \n[\n\t[1,2,3]\n] */"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["matrixMultiply","vectorAdd","vectorMagnitude","vectorNormalized","vectorMultiply","vectorDotProduct","vectorCrossProduct","vectorDistance","vectorLinearConversion","vectorCos","vectorFromTo","vectorModelToWorld","vectorWorldToModel"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Math - Vectors","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"max","operator":null,"title":"max","type":"command","url":"https://community.bistudio.com/wiki/max","revid":321188,"updated":"2022-05-13T15:20:51Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The greater value of a and b.","syntaxes":[{"syntax":"a max b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n3 max 2; // Result is 3\n```","code":["3 max 2; // Result is 3"]},{"text":"```sqf\n-3 max -2; // Result is -2\n```","code":["-3 max -2; // Result is -2"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["min","selectMin","selectMax","ceil","floor","linearConversion","Math Commands"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"maxLoad","operator":null,"title":"maxLoad","type":"command","url":"https://community.bistudio.com/wiki/maxLoad","revid":309123,"updated":"2022-05-03T11:08:26Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns maximum load limit for a unit, uniform/vest/backpack containers, vehicle cargo, supply boxes and weapon holders.","syntaxes":[{"syntax":"maxLoad container","since":null,"effect":null,"exec":null,"params":[{"name":"container","type":"Object","optional":false,"default":null,"description":"unit, uniform/vest/backpack container, vehicle cargo, supply box, weapon holder","types":["Object"],"since":null,"text":"container: Object - unit, uniform/vest/backpack container, vehicle cargo, supply box, weapon holder"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"container","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _maxLoad = maxLoad _yaMum;\n```","code":["private _maxLoad = maxLoad _yaMum;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMaxLoad","load","loadAbs","loadBackpack","loadUniform","loadVest","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"members","operator":null,"title":"members","type":"command","url":"https://community.bistudio.com/wiki/members","revid":310843,"updated":"2022-05-07T20:24:01Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of members in given team.","syntaxes":[{"syntax":"members team","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"team","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_members = members _team;\n```","code":["_members = members _team;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["teams"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"menuAction","operator":null,"title":"menuAction","type":"command","url":"https://community.bistudio.com/wiki/menuAction","revid":378323,"updated":"2026-04-02T16:28:16Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns action stored in item on given path in CT_MENU_STRIP control.","syntaxes":[{"syntax":"menuAction [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"action","text":"String - action"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuAction path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"action","text":"String - action"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nmenuAction [120, [1, 0]];\n```","code":["menuAction [120, [1, 0]];"]},{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuAction [1, 0];\n```","code":["findDisplay 313 displayCtrl 120 menuAction [1, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetAction"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuAdd","operator":null,"title":"menuAdd","type":"command","url":"https://community.bistudio.com/wiki/menuAdd","revid":378324,"updated":"2026-04-02T16:28:30Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds new submenu entry into item on given path.","syntaxes":[{"syntax":"menuAdd [idc, path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, text]","types":["Array"]}},{"syntax":"control menuAdd [path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"path where the items should be added","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - path where the items should be added"},{"name":"text","type":"String","optional":false,"default":null,"description":"displayed name for the entry","types":["String"],"since":null,"text":"text: String - displayed name for the entry"}],"returns":{"type":"Number","types":["Number"],"description":"index of the item","text":"Number - index of the item"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, text]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuAdd [[], \"Custom Tools\"]; // Add new entry at the top level to the menu strip in Eden Editor\n```","code":["findDisplay 313 displayCtrl 120 menuAdd [[], \"Custom Tools\"]; // Add new entry at the top level to the menu strip in Eden Editor"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuDelete"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuChecked","operator":null,"title":"menuChecked","type":"command","url":"https://community.bistudio.com/wiki/menuChecked","revid":378328,"updated":"2026-04-02T16:30:35Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if item on given path is checked or not.","syntaxes":[{"syntax":"menuChecked [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuChecked path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nprivate _isChecked = findDisplay 313 displayCtrl 120 menuChecked [0, 1];\n```","code":["private _isChecked = findDisplay 313 displayCtrl 120 menuChecked [0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetCheck"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuClear","operator":null,"title":"menuClear","type":"command","url":"https://community.bistudio.com/wiki/menuClear","revid":339137,"updated":"2023-04-26T10:55:01Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all entries from given menu strip.","syntaxes":[{"syntax":"menuClear idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"menuClear control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nmenuClear (findDisplay 313 displayCtrl 120); // removes all entries from Eden Editor. Restart the editor to reset the menu.\n```","code":["menuClear (findDisplay 313 displayCtrl 120); // removes all entries from Eden Editor. Restart the editor to reset the menu."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuDelete","menuAdd","menuHover","menuValue","menuURL","menuText","menuSort","menuSize","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuCollapse","operator":null,"title":"menuCollapse","type":"command","url":"https://community.bistudio.com/wiki/menuCollapse","revid":378331,"updated":"2026-04-02T16:30:43Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Collapses item on given path and all its children.","syntaxes":[{"syntax":"menuCollapse [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuCollapse path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuCollapse [0];\n```","code":["findDisplay 313 displayCtrl 120 menuCollapse [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuExpand"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuData","operator":null,"title":"menuData","type":"command","url":"https://community.bistudio.com/wiki/menuData","revid":378335,"updated":"2026-04-02T16:30:53Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns data stored in menu entry on given path.","syntaxes":[{"syntax":"menuData [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuData path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n// Create an entry which will return its data once clicked\nprivate _ctrlMenuStrip = findDisplay 313 displayCtrl 120;\nprivate _indexMain = _ctrlMenuStrip menuAdd [[], \"Custom Tools\"];\nprivate _indexData = _ctrlMenuStrip menuAdd [[_indexMain],\"This entry will print its data to system chat when clicked\"];\n_ctrlMenuStrip menuSetData [[_indexMain,_indexData], \"[objNull,'Some String',true]\"];\n_ctrlMenuStrip menuSetAction [[_indexMain,_indexData], \"systemChat (findDisplay 313 displayCtrl 120 menuData (menuHover (findDisplay 313 displayCtrl 120)));\"];\n```","code":["// Create an entry which will return its data once clicked\nprivate _ctrlMenuStrip = findDisplay 313 displayCtrl 120;\nprivate _indexMain = _ctrlMenuStrip menuAdd [[], \"Custom Tools\"];\nprivate _indexData = _ctrlMenuStrip menuAdd [[_indexMain],\"This entry will print its data to system chat when clicked\"];\n_ctrlMenuStrip menuSetData [[_indexMain,_indexData], \"[objNull,'Some String',true]\"];\n_ctrlMenuStrip menuSetAction [[_indexMain,_indexData], \"systemChat (findDisplay 313 displayCtrl 120 menuData (menuHover (findDisplay 313 displayCtrl 120)));\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetData"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuDelete","operator":null,"title":"menuDelete","type":"command","url":"https://community.bistudio.com/wiki/menuDelete","revid":378336,"updated":"2026-04-02T16:31:01Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Deletes menu entry on given path.","syntaxes":[{"syntax":"menuDelete [idc,path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc,path]","types":["Array"]}},{"syntax":"control menuDelete path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n(findDisplay 313 displayCtrl 120) menuDelete [1]; // removes the second entry from Eden Editor menu strip. Restart Eden Editor to reset the menu.\n```","code":["(findDisplay 313 displayCtrl 120) menuDelete [1]; // removes the second entry from Eden Editor menu strip. Restart Eden Editor to reset the menu."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuAdd","menuHover","menuValue","menuURL","menuText","menuSort","menuSize","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuClear","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuEnable","operator":null,"title":"menuEnable","type":"command","url":"https://community.bistudio.com/wiki/menuEnable","revid":378329,"updated":"2026-04-02T16:30:39Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables or disables menu entry on given path.","syntaxes":[{"syntax":"menuEnable [idc, path, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"enable","type":"Boolean","optional":true,"default":"true","description":"disabled if false","types":["Boolean"],"since":"arma3 2.06","text":"enable: Boolean - (Optional, default true) disabled if false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, enable]","types":["Array"]}},{"syntax":"control menuEnable [path, enable]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"enable","type":"Boolean","optional":true,"default":"true","description":"disabled if false","types":["Boolean"],"since":"arma3 2.06","text":"enable: Boolean - (Optional, default true) disabled if false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, enable]","types":["Array"]}},{"syntax":"control menuEnable path > [!CAUTION] > This information is obsolete. This old syntax is kept only for backward compatibility.","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path > [!CAUTION] > This information is obsolete. This old syntax is kept only for backward compatibility.","types":[]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuEnable [0]; // old syntax, do not use\n```","code":["findDisplay 313 displayCtrl 120 menuEnable [0]; // old syntax, do not use"]},{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuEnable [[0, 0, 1], false]; // since Arma 3 v2.06\n```","code":["findDisplay 313 displayCtrl 120 menuEnable [[0, 0, 1], false]; // since Arma 3 v2.06"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuEnabled","operator":null,"title":"menuEnabled","type":"command","url":"https://community.bistudio.com/wiki/menuEnabled","revid":378333,"updated":"2026-04-02T16:30:48Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if menu entry on given path is enabled or not.","syntaxes":[{"syntax":"menuEnabled [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuEnabled path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n_isEnabled = findDisplay 313 displayCtrl 120 menuEnabled [0];\n```","code":["_isEnabled = findDisplay 313 displayCtrl 120 menuEnabled [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuExpand","operator":null,"title":"menuExpand","type":"command","url":"https://community.bistudio.com/wiki/menuExpand","revid":378347,"updated":"2026-04-02T16:31:34Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Expands given menu entry on given path and all its parents so entry is visible.","syntaxes":[{"syntax":"menuExpand [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuExpand path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuExpand [0, 1];\n```","code":["findDisplay 313 displayCtrl 120 menuExpand [0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuCollapse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuHover","operator":null,"title":"menuHover","type":"command","url":"https://community.bistudio.com/wiki/menuHover","revid":339129,"updated":"2023-04-26T10:54:57Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns path to menu entry mouse is currently hovering over.","syntaxes":[{"syntax":"menuHover idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"menuHover control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _path = menuHover (findDisplay 313 displayCtrl 120);\n```","code":["private _path = menuHover (findDisplay 313 displayCtrl 120);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuDelete","menuAdd","menuValue","menuURL","menuText","menuSort","menuSize","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuClear","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuPicture","operator":null,"title":"menuPicture","type":"command","url":"https://community.bistudio.com/wiki/menuPicture","revid":378338,"updated":"2026-04-02T16:31:12Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns picture set into item on given path.","syntaxes":[{"syntax":"menuPicture [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuPicture path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nprivate _picturePath = (findDisplay 313 displayCtrl 120) menuPicture [0, 1];\n```","code":["private _picturePath = (findDisplay 313 displayCtrl 120) menuPicture [0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSetAction","operator":null,"title":"menuSetAction","type":"command","url":"https://community.bistudio.com/wiki/menuSetAction","revid":378340,"updated":"2026-04-02T16:31:17Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets new action into menu entry on given path.","syntaxes":[{"syntax":"menuSetAction [idc, path, action]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"action","type":"String","optional":false,"default":null,"description":"expression that should be executed when entry is clicked","types":["String"],"since":null,"text":"action: String - expression that should be executed when entry is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, action]","types":["Array"]}},{"syntax":"control menuSetAction [path, action]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"action","type":"String","optional":false,"default":null,"description":"expression that should be executed when entry is clicked","types":["String"],"since":null,"text":"action: String - expression that should be executed when entry is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, action]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetAction [[0, 1], \"systemChat 'Hello World!'\"];\n```","code":["findDisplay 313 displayCtrl 120 menuSetAction [[0, 1], \"systemChat 'Hello World!'\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuAction"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSetCheck","operator":null,"title":"menuSetCheck","type":"command","url":"https://community.bistudio.com/wiki/menuSetCheck","revid":378337,"updated":"2026-04-02T16:31:09Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets item on given path to be checked or not. By default menu strip entries are not checkable.\nOnce this command was executed, an entry can become checked and unchecked.\nIf an entry is checked is indicated by a tick to the left of the entry's text.\nSetting an entry to be checkable will overwrite set picture with menuSetPicture.","syntaxes":[{"syntax":"menuSetCheck [idc, path, checked]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"checked","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"checked: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, checked]","types":["Array"]}},{"syntax":"control menuSetCheck [path, checked]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"checked","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"checked: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, checked]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetCheck [[0,1], true];\n```","code":["findDisplay 313 displayCtrl 120 menuSetCheck [[0,1], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuChecked"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSetData","operator":null,"title":"menuSetData","type":"command","url":"https://community.bistudio.com/wiki/menuSetData","revid":378345,"updated":"2026-04-02T16:31:30Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets data into menu entry on given path.","syntaxes":[{"syntax":"menuSetData [idc, path, data]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, data]","types":["Array"]}},{"syntax":"control menuSetData [path, data]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, data]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetData [[0, 1], \"[true, player, 'Hello World!', 1337]\"];\n```","code":["findDisplay 313 displayCtrl 120 menuSetData [[0, 1], \"[true, player, 'Hello World!', 1337]\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuData"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSetPicture","operator":null,"title":"menuSetPicture","type":"command","url":"https://community.bistudio.com/wiki/menuSetPicture","revid":378346,"updated":"2026-04-02T16:31:33Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets new picture into menu entry on given path. The picture will be replaced by a tick if the entry was set to checkable with menuSetCheck.","syntaxes":[{"syntax":"menuSetPicture [idc, path, picture]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"picture","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"picture: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, picture]","types":["Array"]}},{"syntax":"control menuSetPicture [path, picture]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"picture","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"picture: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, picture]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetPicture [[0, 1], \"\\a3\\modules_f\\data\\iconunlock_ca.paa\"];\n```","code":["findDisplay 313 displayCtrl 120 menuSetPicture [[0, 1], \"\\a3\\modules_f\\data\\iconunlock_ca.paa\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSetShortcut","operator":null,"title":"menuSetShortcut","type":"command","url":"https://community.bistudio.com/wiki/menuSetShortcut","revid":378330,"updated":"2026-04-02T16:30:41Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets shortcut of given menu strip entry.","syntaxes":[{"syntax":"menuSetShortcut [idc, path, shortcut]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"shortcut","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"shortcut: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, shortcut]","types":["Array"]}},{"syntax":"control menuSetShortcut [path, shortcut]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"shortcut","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"shortcut: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, shortcut]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrlMenuStrip menuSetShortcut [[0,0], 2048 + 0x16]; // ALT + U\n```","code":["_ctrlMenuStrip menuSetShortcut [[0,0], 2048 + 0x16]; // ALT + U"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuShortcut","menuShortcutText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"menuSetText","operator":null,"title":"menuSetText","type":"command","url":"https://community.bistudio.com/wiki/menuSetText","revid":378350,"updated":"2026-04-02T16:31:40Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets text of given menu strip entry.","syntaxes":[{"syntax":"menuSetText [idc, path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, text]","types":["Array"]}},{"syntax":"control menuSetText [path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, text]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrlMenuStrip menuSetText [[0,0,1], \"Hello World!\"];\n```","code":["_ctrlMenuStrip menuSetText [[0,0,1], \"Hello World!\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"menuSetURL","operator":null,"title":"menuSetURL","type":"command","url":"https://community.bistudio.com/wiki/menuSetURL","revid":378344,"updated":"2026-04-02T16:31:28Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets weblink (URL) of given menu strip entry, subject to `allowedHTMLLoadURIs[]` whitelisting in CfgCommands config.","syntaxes":[{"syntax":"menuSetURL [idc, path, link]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path of Numbers","optional":false,"default":null,"description":null,"types":["Tree View Path","Number"],"since":null,"text":"path: Tree View Path of Numbers"},{"name":"link","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"link: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, link]","types":["Array"]}},{"syntax":"control menuSetURL [path, link]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path of Numbers","optional":false,"default":null,"description":null,"types":["Tree View Path","Number"],"since":null,"text":"path: Tree View Path of Numbers"},{"name":"link","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"link: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, link]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrlMenuStrip menuSetURL [[0,0,1], \"https://arma3.com/\"];\n```","code":["_ctrlMenuStrip menuSetURL [[0,0,1], \"https://arma3.com/\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuURL","ctrlSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"menuSetValue","operator":null,"title":"menuSetValue","type":"command","url":"https://community.bistudio.com/wiki/menuSetValue","revid":378339,"updated":"2026-04-02T16:31:15Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets new value into menu entry on given path.","syntaxes":[{"syntax":"menuSetValue [idc, path, value]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, value]","types":["Array"]}},{"syntax":"control menuSetValue [path, value]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetValue [[0, 1], 1337];\n```","code":["findDisplay 313 displayCtrl 120 menuSetValue [[0, 1], 1337];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuShortcut","operator":null,"title":"menuShortcut","type":"command","url":"https://community.bistudio.com/wiki/menuShortcut","revid":378341,"updated":"2026-04-02T16:31:19Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns shortcut related to menu entry on given path in form of a bitflag. To get the shortcut text use menuShortcutText.","syntaxes":[{"syntax":"menuShortcut [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuShortcut path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuShortcut [0, 1];\n```","code":["findDisplay 313 displayCtrl 120 menuShortcut [0, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuShortcutText","menuSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuShortcutText","operator":null,"title":"menuShortcutText","type":"command","url":"https://community.bistudio.com/wiki/menuShortcutText","revid":378343,"updated":"2026-04-02T16:31:24Z","groups":["GUI Control - Menu","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a string containing shortcut text for menu item on the given path.","syntaxes":[{"syntax":"menuShortcutText [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuShortcutText path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuShortcutText [1, 8]; // returns \"#\"\n```","code":["findDisplay 313 displayCtrl 120 menuShortcutText [1, 8]; // returns \"#\""]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command is currently broken in Arma 3 2.00. It only returns shortcuts which do not use a modifier key (<kbd>Ctrl</kbd>, <kbd>Alt</kbd> and <kbd>Shift</kbd>).","aliases":[],"see_also":["menuShortcut","menuSetShortcut"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSize","operator":null,"title":"menuSize","type":"command","url":"https://community.bistudio.com/wiki/menuSize","revid":378332,"updated":"2026-04-02T16:30:46Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how many sub entries is in item on given path.","syntaxes":[{"syntax":"menuSize [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuSize path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSize [];\n```","code":["findDisplay 313 displayCtrl 120 menuSize [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuDelete","menuAdd","menuHover","menuValue","menuURL","menuText","menuSort","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuClear","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuSort","operator":null,"title":"menuSort","type":"command","url":"https://community.bistudio.com/wiki/menuSort","revid":378342,"updated":"2026-04-02T16:31:22Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts subentries of item on given path by their text.","syntaxes":[{"syntax":"menuSort [idc, path, sortOrder]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"sortOrder","type":"Boolean","optional":false,"default":null,"description":"true to sort from A to Z, false to sort from Z to A","types":["Boolean"],"since":null,"text":"sortOrder: Boolean - true to sort from A to Z, false to sort from Z to A"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, sortOrder]","types":["Array"]}},{"syntax":"control menuSort [path, sortOrder]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"sortOrder","type":"Boolean","optional":false,"default":null,"description":"true to sort from A to Z, false to sort from Z to A","types":["Boolean"],"since":null,"text":"sortOrder: Boolean - true to sort from A to Z, false to sort from Z to A"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, sortOrder]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSort [[], true];\n```","code":["findDisplay 313 displayCtrl 120 menuSort [[], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuDelete","menuAdd","menuHover","menuValue","menuURL","menuText","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuClear","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuText","operator":null,"title":"menuText","type":"command","url":"https://community.bistudio.com/wiki/menuText","revid":378349,"updated":"2026-04-02T16:31:38Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current text set in menu entry on given path.","syntaxes":[{"syntax":"menuText [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuText path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n_ctrlMenuStrip menuText [1];\n```","code":["_ctrlMenuStrip menuText [1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuURL","operator":null,"title":"menuURL","type":"command","url":"https://community.bistudio.com/wiki/menuURL","revid":378348,"updated":"2026-04-02T16:31:36Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current URL set in entry on given path.","syntaxes":[{"syntax":"menuURL [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control menuURL path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuURL [7, 0]; // returns \"https://community.bistudio.com/wiki/Eden_Editor\"\n```","code":["findDisplay 313 displayCtrl 120 menuURL [7, 0]; // returns \"https://community.bistudio.com/wiki/Eden_Editor\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuSetURL"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"menuValue","operator":null,"title":"menuValue","type":"command","url":"https://community.bistudio.com/wiki/menuValue","revid":378334,"updated":"2026-04-02T16:30:50Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current value set in menu entry on given path.","syntaxes":[{"syntax":"menuValue [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuEnable","menuExpand","menuCollapse","menuSetData","menuSetValue","menuSetCheck","menuSetAction","menuDelete","menuAdd","menuHover","menuURL","menuText","menuSort","menuSize","menuEnabled","menuChecked","menuAction","menuShortcutText","menuShortcut","menuPicture","menuData","menuClear","menuSetPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"merge","operator":null,"title":"merge","type":"command","url":"https://community.bistudio.com/wiki/merge","revid":347592,"updated":"2023-09-28T20:05:03Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Merges two HashMaps.","syntaxes":[{"syntax":"hashMap1 merge hashMap2","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap1","type":"HashMap","optional":false,"default":null,"description":"this HashMap will be modified","types":["HashMap"],"since":null,"text":"hashMap1: HashMap - this HashMap will be modified"},{"name":"hashMap2","type":"HashMap","optional":false,"default":null,"description":"all key-value pairs from this HashMap are added to *hashMap1*. If a key from *hashMap2* already exists in *hashMap1*, it doesn't overwrite the value in *hashMap1*.","types":["HashMap"],"since":null,"text":"hashMap2: HashMap - all key-value pairs from this HashMap are added to *hashMap1*. If a key from *hashMap2* already exists in *hashMap1*, it doesn't overwrite the value in *hashMap1*."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"hashMap1","types":["HashMap"]},"right":{"text":"hashMap2","types":["HashMap"]}},{"syntax":"hashMap1 merge [hashMap2, overwriteExisting]","since":null,"effect":null,"exec":null,"params":[{"name":"hashMap1","type":"HashMap","optional":false,"default":null,"description":"this HashMap will be modified","types":["HashMap"],"since":null,"text":"hashMap1: HashMap - this HashMap will be modified"},{"name":"hashMap2","type":"HashMap","optional":false,"default":null,"description":"all key-value pairs from this HashMap are added to *hashMap1*","types":["HashMap"],"since":null,"text":"hashMap2: HashMap - all key-value pairs from this HashMap are added to *hashMap1*"},{"name":"overwriteExisting","type":"Boolean","optional":true,"default":"false","description":"if true, keys from *hashMap1* that also exist in *hashMap2* are overwritten. When set to true, merging is faster","types":["Boolean"],"since":null,"text":"overwriteExisting: Boolean - (Optional, default false) if true, keys from *hashMap1* that also exist in *hashMap2* are overwritten. When set to true, merging is faster"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"hashMap1","types":["HashMap"]},"right":{"text":"[hashMap2, overwriteExisting]","types":["Array"]}}],"examples":[{"text":"```sqf\n_hashMap merge _otherHashMap;\n```","code":["_hashMap merge _otherHashMap;"]},{"text":"```sqf\nprivate _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge _hashmap2; // _hashmap is [[\"cow\",100],[\"cat\",200],[\"chicken\",200],[\"camel\",800]]\n```","code":["private _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge _hashmap2; // _hashmap is [[\"cow\",100],[\"cat\",200],[\"chicken\",200],[\"camel\",800]]"]},{"text":"```sqf\nprivate _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge [_hashmap2, true]; // _hashmap is [[\"cow\",150],[\"cat\",300],[\"chicken\",400],[\"camel\",800]]\n```","code":["private _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge [_hashmap2, true]; // _hashmap is [[\"cow\",150],[\"cat\",300],[\"chicken\",400],[\"camel\",800]]"]},{"text":"```sqf\nprivate _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge [_hashmap2, false]; // _hashmap is [[\"cow\",100],[\"cat\",200],[\"chicken\",200],[\"camel\",800]] as Syntax 1\n```","code":["private _hashmap1 = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [100, 200, 200];\nprivate _hashmap2 = [\"cow\", \"cat\", \"chicken\", \"camel\"] createHashMapFromArray [150, 300, 400, 800];\n_hashmap1 merge [_hashmap2, false]; // _hashmap is [[\"cow\",100],[\"cat\",200],[\"chicken\",200],[\"camel\",800]] as Syntax 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["insert","set"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"min","operator":null,"title":"min","type":"command","url":"https://community.bistudio.com/wiki/min","revid":321189,"updated":"2022-05-13T15:21:16Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The smaller of a and b.","syntaxes":[{"syntax":"a min b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n3 min 2 // Result is 2\n```","code":["3 min 2 // Result is 2"]},{"text":"```sqf\n-3 min -2 // Result is -3\n```","code":["-3 min -2 // Result is -3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["max","selectMin","selectMax","ceil","floor","linearConversion","Math Commands"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"mineActive","operator":null,"title":"mineActive","type":"command","url":"https://community.bistudio.com/wiki/mineActive","revid":319444,"updated":"2022-05-13T09:24:05Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if the given mine is active.","syntaxes":[{"syntax":"mineActive obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nif (mineActive _mine) then {hint \"BOOM!\"};\n```","code":["if (mineActive _mine) then {hint \"BOOM!\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","detectedMines","mineDetectedBy","createMine","revealMine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"mineDetectedBy","operator":null,"title":"mineDetectedBy","type":"command","url":"https://community.bistudio.com/wiki/mineDetectedBy","revid":378787,"updated":"2026-06-05T12:20:54Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if mine has been detected by a given side","syntaxes":[{"syntax":"mine mineDetectedBy side","since":null,"effect":null,"exec":null,"params":[{"name":"mine","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"mine: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"mine","types":["Object"]},"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\nif (_myMine mineDetectedBy opfor) then\n{\n    hint \"Children yearn for the mines\";\n};\n```","code":["if (_myMine mineDetectedBy opfor) then\n{\n\thint \"Children yearn for the mines\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","detectedMines","createMine","mineActive","revealMine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"missileState","operator":null,"title":"missileState","type":"command","url":"https://community.bistudio.com/wiki/missileState","revid":377694,"updated":"2026-01-02T09:03:16Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the provided *guided* missile's engine, target lock and flight profile states.","syntaxes":[{"syntax":"missileState munition","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":"missile","types":["Object"],"since":null,"text":"munition: Object - missile"}],"returns":{"type":"Array with [engineState, lockState, flightState]","types":["Array"],"description":"engineState: String - one of \"INIT\", \"THRUST\", \"FLY\" or \"\" - lockState: String - one of \"MANUAL\", \"LOCKED\", \"LOST\", \"INITIAL\", \"SEEKING\" or \"\" - flightState: String - one of \"DEFAULT\", \"DIRECT\", \"TOPDOWN\", \"LOALDISTANCE\", \"LOALALTITUDE\", \"OVERFLY\", \"CRUISE\" or \"\" (LOAL stands for \"Lock-On After Launch\")","text":"Array with [engineState, lockState, flightState]\n- engineState: String - one of \"INIT\", \"THRUST\", \"FLY\" or \"\"\n- lockState: String - one of \"MANUAL\", \"LOCKED\", \"LOST\", \"INITIAL\", \"SEEKING\" or \"\"\n- flightState: String - one of \"DEFAULT\", \"DIRECT\", \"TOPDOWN\", \"LOALDISTANCE\", \"LOALALTITUDE\", \"OVERFLY\", \"CRUISE\" or \"\" (LOAL stands for \"Lock-On After Launch\")"},"form":"unary","operator":null,"left":null,"right":{"text":"munition","types":["Object"]}}],"examples":[{"text":"```sqf\nmissileState _myMissile params [\"_engineState\", \"_lockState\", \"_flightState\"];\n```","code":["missileState _myMissile params [\"_engineState\", \"_lockState\", \"_flightState\"];"]},{"text":"```sqf\n_myHelicopter addEventHandler [\"Fired\", {\n    private _projectile = _this select 6;\n    // or params [\"\", \"\", \"\", \"\", \"\", \"\", \"_projectile\"];\n    systemChat str missileState _projectile;\n}];\n```","code":["_myHelicopter addEventHandler [\"Fired\", {\n\tprivate _projectile = _this select 6;\n\t// or params [\"\", \"\", \"\", \"\", \"\", \"\", \"_projectile\"];\n\tsystemChat str missileState _projectile;\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missileTargetPos","setMissileTargetPos","setMissileTarget","missileTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"missileTarget","operator":null,"title":"missileTarget","type":"command","url":"https://community.bistudio.com/wiki/missileTarget","revid":364926,"updated":"2024-06-30T22:40:26Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a guided missile's target.","syntaxes":[{"syntax":"missileTarget munition","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"munition: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"munition","types":["Object"]}}],"examples":[{"text":"```sqf\nmissileTarget missile1;\n```","code":["missileTarget missile1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missileTargetPos","setMissileTargetPos","setMissileTarget","missileState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"missileTargetPos","operator":null,"title":"missileTargetPos","type":"command","url":"https://community.bistudio.com/wiki/missileTargetPos","revid":377453,"updated":"2026-01-02T06:47:13Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a guided missile's target position.","syntaxes":[{"syntax":"missileTargetPos munition","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"munition: Object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"munition","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _targetDistance = vehicle player distance missileTargetPos missile1;\n```","code":["private _targetDistance = vehicle player distance missileTargetPos missile1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missileTarget","setMissileTargetPos","setMissileTarget","missileState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"missionConfigFile","operator":null,"title":"missionConfigFile","type":"command","url":"https://community.bistudio.com/wiki/missionConfigFile","revid":342131,"updated":"2023-07-09T12:26:44Z","groups":["Config"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return root of mission Description.ext entries hierarchy.\n\n> [!IMPORTANT]\n> Since the introduction of the Eden Editor, scenario attributes can be configured in the editor itself, not only in the external Description.ext file.\n> To access desired value independently on where it is stored, use the following commands:\n> - getMissionConfigValue\n> - getMissionConfig","syntaxes":[{"syntax":"missionConfigFile","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nfor \"_i\" from 0 to (count paramsArray - 1) do\n{\n    missionNamespace setVariable [configName ((missionConfigFile/\"Params\") select _i), paramsArray select _i];\n};\n```","code":["for \"_i\" from 0 to (count paramsArray - 1) do\n{\n\tmissionNamespace setVariable [configName ((missionConfigFile/\"Params\") select _i), paramsArray select _i];\n};"]},{"text":"To define custom values in description.ext:\n\n```cpp\nclass myMissionConfig\n{\n    class mySetup\n    {\n        myNumber = 3;\n        myArray[] = { 1, 2, 3 };\n        myText = \"LOL\";\n    };\n};\n```\n\nTo read defined custom values from a script:\n\n```sqf\n_myNumber = getNumber (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myNumber\");\n_myArray = getArray (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myArray\");\n_myText = getText (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myText\");\n```","code":["_myNumber = getNumber (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myNumber\");\n_myArray = getArray (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myArray\");\n_myText = getText (missionConfigFile >> \"myMissionConfig\" >> \"mySetup\" >> \"myText\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configFile","campaignConfigFile","getMissionConfigValue","getMissionConfig","getMissionPath"],"notes":[{"user":"Killzone_Kid","date":"2015-02-17T16:46:00Z","text":"missionConfigFile can be used to parse *mission.sqm* file data as well if it is included into description.ext:\n\n```cpp\nclass MissionSQM\n{\n    #include \"mission.sqm\"\n};\n```\n\nThen *mission.sqm* data can be accessed like this:\n\n```sqf\ngetNumber (missionConfigFile >> \"MissionSQM\" >> \"version\"); // 12 - version param in mission.sqm\n```\n\n(courtesy of Master85)"},{"user":"Dedmen","date":"2018-04-27T20:39:00Z","text":"If your Description.ext file is empty, str missionConfigFile may report an empty string instead of the path to the file. You have to put at least one entry into your config.\n\nTo get file path with description.ext to play sound via playSound3D (before getMissionPath):\n\n```sqf\nprivate _missionRootPath = str missionConfigFile select [0, count str missionConfigFile - 15];\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Config","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"missionDifficulty","operator":null,"title":"missionDifficulty","type":"command","url":"https://community.bistudio.com/wiki/missionDifficulty","revid":337653,"updated":"2023-02-16T13:02:43Z","groups":["Difficulty","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return difficulty that has been forced for this mission, returns -1 if difficulty is not forced and it is used one from player's options.","syntaxes":[{"syntax":"missionDifficulty","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _number = missionDifficulty;\n```","code":["private _number = missionDifficulty;"]},{"text":"```sqf\nprivate _playedDifficulty = missionDifficulty;\nif (_playedDifficulty == -1) then\n{\n    _playedDifficulty = difficulty;\n};\n```","code":["private _playedDifficulty = missionDifficulty;\nif (_playedDifficulty == -1) then\n{\n\t_playedDifficulty = difficulty;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["difficultyOption","difficulty"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Difficulty","Command Group: Mission Information","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"missionEnd","operator":null,"title":"missionEnd","type":"command","url":"https://community.bistudio.com/wiki/missionEnd","revid":377043,"updated":"2026-01-01T08:50:34Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns mission end type and how it was ended or an empty array [] is mission was not ended.","syntaxes":[{"syntax":"missionEnd","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [endType, failMission, isFailed] (or empty array if the mission is not ending):","types":["Array"],"description":"endType : String - the ending that was passed to failMission or endMission - failMission: Boolean - true if the mission ended via failMission, false if via endMission - isFailed: Boolean - engine idea of how mission ended. For example if mission ended via failMission but the type of ending was not \"Killed\", isFailed is false","text":"Array with [endType, failMission, isFailed] (or empty array if the mission is not ending):\n- endType : String - the ending that was passed to failMission or endMission\n- failMission: Boolean - true if the mission ended via failMission, false if via endMission\n- isFailed: Boolean - engine idea of how mission ended. For example if mission ended via failMission but the type of ending was not \"Killed\", *isFailed* is false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _endInfo = missionEnd;\n```","code":["private _endInfo = missionEnd;"]},{"text":"```sqf\nmissionEnd params [\"_endType\", \"_failMission\", \"_isFailed\"];\n```","code":["missionEnd params [\"_endType\", \"_failMission\", \"_isFailed\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["endMission","failMission","forceEnd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"missionName","operator":null,"title":"missionName","type":"command","url":"https://community.bistudio.com/wiki/missionName","revid":364087,"updated":"2024-05-03T19:33:29Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return currently loaded mission file (path to mission.pbo, relative to game exe).","syntaxes":[{"syntax":"missionName","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"You are playing mission \"\"%1\"\"\", missionName];\n```","code":["hint format [\"You are playing mission \"\"%1\"\"\", missionName];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNameSource","worldName","briefingName","serverName","worldSize"],"notes":[{"user":".kju","date":"2010-08-02T10:19:00Z","text":"Only works in SP and on the MP Host/DS. It returns the mission pboprefix if available, otherwise the pboname. For clients it returns '__cur_mp'."},{"user":"Kenoxite","date":"2014-09-25T08:05:00Z","text":"Prior to Operation Flashpoint v1.96 it returns the mission filename. Since Operation Flashpoint v1.99, it returns the briefing name instead when in multiplayer. The string displayed is that set in the Intel section of the mission editor."},{"user":"NikkoJT","date":"2021-06-12T19:31:00Z","text":"Testing suggests it does now work on clients in the current Arma 3 version."}],"categories":[]},{"name":"missionNameSource","operator":null,"title":"missionNameSource","type":"command","url":"https://community.bistudio.com/wiki/missionNameSource","revid":310162,"updated":"2022-05-05T13:07:20Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return workshop-compatible currently loaded mission file (path to mission.pbo, relative to game exe).\n\n> [!NOTE]\n> - missionName will return the Workshop user-friendly mission name, whereas missionNameSource will take the information from mission.sqm.\n> - pre-v2.02 missions may return an empty string.","syntaxes":[{"syntax":"missionNameSource","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"You are playing mission \"\"%1\"\"\", missionNameSource];\n```","code":["hint format [\"You are playing mission \"\"%1\"\"\", missionNameSource];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionName","worldName","briefingName","serverName","worldSize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"missionNamespace","operator":null,"title":"missionNamespace","type":"command","url":"https://community.bistudio.com/wiki/missionNamespace","revid":339108,"updated":"2023-04-26T10:54:35Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the global namespace attached to mission.","syntaxes":[{"syntax":"missionNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":null,"text":"Namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nmissionNamespace setVariable [\"StringVariable\", \"myString\"]; // same as: StringVariable = \"myString\";\n_myStringValue = missionNamespace getVariable \"StringVariable\";\nhint _myStringValue; // hints \"myString\"\n```","code":["missionNamespace setVariable [\"StringVariable\", \"myString\"]; // same as: StringVariable = \"myString\";\n_myStringValue = missionNamespace getVariable \"StringVariable\";\nhint _myStringValue; // hints \"myString\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentNamespace","uiNamespace","parsingNamespace","profileNamespace","localNamespace","serverNamespace","allVariables","with","ArmA: Editing"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"missionProfileNamespace","operator":null,"title":"missionProfileNamespace","type":"command","url":"https://community.bistudio.com/wiki/missionProfileNamespace","revid":330144,"updated":"2022-08-23T12:23:40Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This namespace has the same lifetime as profileNamespace but is also connected to the mission it is saved from. See saveMissionProfileNamespace for more details.","syntaxes":[{"syntax":"missionProfileNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":"namespace","text":"Namespace - namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _currentMissionProfileNamespace = missionProfileNamespace;\n```","code":["private _currentMissionProfileNamespace = missionProfileNamespace;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","profileNamespace","saveMissionProfileNamespace","isMissionProfileNamespaceLoaded"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"missionStart","operator":null,"title":"missionStart","type":"command","url":"https://community.bistudio.com/wiki/missionStart","revid":329154,"updated":"2022-07-25T12:25:22Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns date and time when mission started. Because this command returns the time of the actual start of the mission, it might not be available in *pre-init* or *init*, but is guaranteed to be available in *post-init* when `time > 0`.","syntaxes":[{"syntax":"missionStart","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Array","date"],"description":null,"text":"Array format `[year, month, day, hour, minute, second]` in multiplayer, which differs from date format only by seconds. In SP returns `[0,0,0,0,0,0]`"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsetDate (missionStart select [0,5]);\n```","code":["setDate (missionStart select [0,5]);"]},{"text":"Set real date:\n\n```sqf\n//postInit = 1;\nif (isServer) then\n{\n    waitUntil { time > 0 };\n    setDate (missionStart select [0, 5]);\n};\n```","code":["//postInit = 1;\nif (isServer) then\n{\n\twaitUntil { time > 0 };\n\tsetDate (missionStart select [0, 5]);\n};"]}],"multiplayer":"Command only has the desired return value in multiplayer.","problems":null,"aliases":[],"see_also":["date","time","dayTime","serverTime","setDate","systemTime","systemTimeUTC"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Operation Flashpoint version 1.80","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"missionVersion","operator":null,"title":"missionVersion","type":"command","url":"https://community.bistudio.com/wiki/missionVersion","revid":342111,"updated":"2023-07-09T12:26:37Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the version of the current mission.\n- Mission from the 2D Editor: 12\n- Mission from the Eden Editor: 15 and higher (for example current version for Eden Editor mission in Arma 3 v1.57 is 51)","syntaxes":[{"syntax":"missionVersion","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"SQM version","text":"Number - SQM version"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_version = missionVersion;\n```","code":["_version = missionVersion;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission.sqm","Description.ext"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"mod","operator":null,"title":"mod","type":"command","url":"https://community.bistudio.com/wiki/mod","revid":339102,"updated":"2023-04-26T10:54:26Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remainder of a divided by b.","syntaxes":[{"syntax":"a mod b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"a: Number"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"a","types":["Number"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\n_remaining = 5 mod 2; // returns 1, as 5 divided by 2 is 2 × 2 + 1\n```","code":["_remaining = 5 mod 2; // returns 1, as 5 divided by 2 is 2 × 2 + 1"]}],"multiplayer":null,"problems":null,"aliases":["a % b"],"see_also":["Math Commands","Operators","a % b"],"notes":[{"user":"Hoz","date":"2006-04-16T01:34:00Z","text":"- Remainder is calculated in real domain.\n- mod is identical to a % b\nYou can use mod to round a decimal number down to the nearest whole number. For example: If you wanted to use the command random to generate a whole number between 0 and 5, you could put this in a script:\n\n```sqf\n_rand = random 6;\n_num = _rand - (_rand mod 1);\n```\n\nIn A1, the new commands round, floor or ceil would be the easier way to round."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"modelToWorld","operator":null,"title":"modelToWorld","type":"command","url":"https://community.bistudio.com/wiki/modelToWorld","revid":377424,"updated":"2026-01-02T06:45:36Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Translates relative position from object model space to world space in PositionAGL format.\n\nThis command will take into account vectorUp of the object when calculating relative coordinates.\nFor the PositionASL version of this command, see modelToWorldWorld.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will first be multiplied by the object scale.\n>\n> For example, if the object scale is 2, `_obj modelToWorld [0,1,0]` will be offset **2 meters** from the model center (`[0,0,0]`).","syntaxes":[{"syntax":"model modelToWorld position","since":null,"effect":null,"exec":null,"params":[{"name":"model","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"model: Object"},{"name":"position","type":"PositionRelative","optional":false,"default":null,"description":"[x,y,z] offset relative to the model centre","types":["PositionRelative"],"since":null,"text":"position: PositionRelative - [x,y,z] offset relative to the model centre"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"translated world position","text":"PositionAGL - translated world position"},"form":"binary","operator":null,"left":{"text":"model","types":["Object"]},"right":{"text":"position","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\n_aboveAndBehindPlayer = player modelToWorld [0,-1,3];\n```","code":["_aboveAndBehindPlayer = player modelToWorld [0,-1,3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorModelToWorld","modelToWorldVisual","worldToModel","modelToWorldWorld","modelToWorldVisualWorld","selectionPosition"],"notes":[{"user":"Dr_Eyeball","date":"2007-02-18T01:55:00Z","text":"The *worldPos* parameter appears to be a relative offset to the position of *object*, so it can often simply be [0,0,0].\n\n**Example:** to position an object *_obj* relative to the position of another object *_relObj* with on offset of *_offset*, try:\n\n```sqf\n_offset = [_x,_y,_z];\n_worldPos = _relObj modelToWorld _offset;\n_obj setPos _worldPos;\n```"},{"user":"ManDay","date":"2007-07-24T17:45:00Z","text":"The object model space has got its Z-Axis along the object's vectorUp,\nits Y-Axis along the object's vectorDir,\nwhile its X-Axis goes along [vectorDir x VectorUp](https://en.wikipedia.org/wiki/Cross_product) (meaning as the X-Axis in a [right-handed cartesian coordiante system](https://en.wikipedia.org/wiki/Cartesian_coordinate_system#In_three_dimensions))."},{"user":"Dr_Eyeball","date":"2008-05-08T08:05:00Z","text":"If your object requires a new direction, ensure you call setDir *prior* to setPosATL when using modelToWorld.\nCalling setDir afterwards will skew its position otherwise.\n\n```sqf\n_ladder setDir _angle;\n_ladder setPosATL (_building modelToWorld [_x, _y, _z]);\n```"},{"user":"Hduregger","date":"2011-02-06T20:41:00Z","text":"The z height returned changes dynamically with the height of waves beneath the object, if the object is located over sea.\nThe z height returned by getPosATL and getPosASL does not change like this.\nThis was tested by continuously retrieving the position of a static object, like the cross in the empty/corpses category, placed over sea or land.\nmodelToWorld behaves similar to getPos but it does not give the same result, therefore\n\n```sqf\n_obj modelToWorld [0.0, 0.0, 0.0]\n```\n\nis **not** the same as \n\n```sqf\ngetPos _obj;\n```\n\n."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"modelToWorldVisual","operator":null,"title":"modelToWorldVisual","type":"command","url":"https://community.bistudio.com/wiki/modelToWorldVisual","revid":377834,"updated":"2026-01-03T04:32:01Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position from object model space to world space in render time scope. For ASL version see modelToWorldVisualWorld.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will first be multiplied by the object scale.\n>\n> For example, if the object scale is 2, `_obj modelToWorldVisual [0,1,0]` will be offset **2 meters** from the model center (`[0,0,0]`).","syntaxes":[{"syntax":"object modelToWorldVisual modelPos","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"modelPos","type":"Array","optional":false,"default":null,"description":"in format PositionRelative ([x,y,z] offset relative to the model centre)","types":["Array"],"since":null,"text":"modelPos: Array - in format PositionRelative ([x,y,z] offset relative to the model centre)"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"world position","text":"PositionAGL - world position"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"modelPos","types":["Array"]}}],"examples":[{"text":"```sqf\n_aboveAndBehindPlayer = player modelToWorldVisual [0,-1,3];\n```","code":["_aboveAndBehindPlayer = player modelToWorldVisual [0,-1,3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["modelToWorld","vectorModelToWorldVisual","getPosWorldVisual","worldToModelVisual","worldToModel","selectionPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"modelToWorldVisualWorld","operator":null,"title":"modelToWorldVisualWorld","type":"command","url":"https://community.bistudio.com/wiki/modelToWorldVisualWorld","revid":377447,"updated":"2026-01-02T06:47:02Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Converts position from object model space to world space in render time scope. For the PositionAGL version see modelToWorldVisual.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will first be multiplied by the object scale.\n>\n> For example, if the object's scale is 2, `_obj modelToWorldVisualWorld [0,1,0]` will be offset **2 meters** from the model center (`[0,0,0]`).","syntaxes":[{"syntax":"obj modelToWorldVisualWorld modelPos","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"modelPos","type":"PositionRelative","optional":false,"default":null,"description":"[x,y,z] offset relative to the model centre","types":["PositionRelative"],"since":null,"text":"modelPos: PositionRelative - [x,y,z] offset relative to the model centre"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":"translated world position (see getPosWorld)","text":"PositionASL - translated world position (see getPosWorld)"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"modelPos","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\nplayer modelToWorldVisualWorld [0,1,0];\n```","code":["player modelToWorldVisualWorld [0,1,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["modelToWorldWorld","modelToWorldVisual","getPosWorldVisual"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"modelToWorldWorld","operator":null,"title":"modelToWorldWorld","type":"command","url":"https://community.bistudio.com/wiki/modelToWorldWorld","revid":377452,"updated":"2026-01-02T06:47:11Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Converts position from object model space to world space in PositionASL format from the object's centre position.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will first be multiplied by the object scale.\n>\n> For example, if the object scale is 2, `_obj modelToWorldWorld [0,1,0]` will be offset **2 meters** from the model center (`[0,0,0]`).","syntaxes":[{"syntax":"obj modelToWorldWorld modelPos","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"modelPos","type":"PositionRelative","optional":false,"default":null,"description":null,"types":["PositionRelative"],"since":null,"text":"modelPos: PositionRelative"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":"the model's centre (see getPosWorld)","text":"PositionASL - **the model's centre** (see getPosWorld)"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"modelPos","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\nprivate _playersFrontWorld = player modelToWorldWorld [0,1,0];\n```","code":["private _playersFrontWorld = player modelToWorldWorld [0,1,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["modelToWorldVisualWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"modParams","operator":null,"title":"modParams","type":"command","url":"https://community.bistudio.com/wiki/modParams","revid":329409,"updated":"2022-07-27T15:04:52Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list of mod parameters according to given options, values are in same order as the given options.","syntaxes":[{"syntax":"modParams [modClass, options]","since":null,"effect":null,"exec":null,"params":[{"name":"modClass","type":"String","optional":false,"default":null,"description":"mod classname","types":["String"],"since":null,"text":"modClass: String - mod classname"},{"name":"options","type":"Array of Strings","optional":false,"default":null,"description":"can be:\n\n| Option | Data Type | Description |\n|---|---|---|\n| `\"name\"` | String | Name to be shown (Arma 3 instead of A3, etc.) |\n| `\"picture\"` | String | Picture shown in Mod Launcher |\n| `\"logo\"` | String | Logo to be shown in Main Menu |\n| `\"logoOver\"` | String | Logo to be shown in Main Menu when mouse is over |\n| `\"logoSmall\"` | String | Small version of logo, prepared for drawing small icons |\n| `\"tooltip\"` | String | Tooltip to be shown on mouse over |\n| `\"tooltipOwned\"` | String | Tooltip to be shown on mouse over the icon when DLC is owned by player |\n| `\"action\"` | String | URL to be triggered when mod button is clicked |\n| `\"actionName\"` | String | What to put on Action Button |\n| `\"overview\"` | String | Overview text visible in expansion menu |\n| `\"hidePicture\"` | Boolean | Do not show mod picture icon in the main menu mod list |\n| `\"hideName\"` | Boolean | Do not show mod name in the main menu mod list |\n| `\"defaultMod\"` | Boolean | Default mods cannot be moved or disabled by Mod Launcher |\n| `\"serverOnly\"` | Boolean | Mod does not have to be installed on client in order to play on server with this mod running |\n| `\"active\"` | Boolean | Active mod (activated through command line or stored in profile by mod launcher)<br>> [!IMPORTANT]<br>> Note that `\"active\"` does not actually tell if a mod is actually running. |","types":["Array","String"],"since":null,"text":"options: Array of Strings - can be:\n\n| Option | Data Type | Description |\n|---|---|---|\n| `\"name\"` | String | Name to be shown (Arma 3 instead of A3, etc.) |\n| `\"picture\"` | String | Picture shown in Mod Launcher |\n| `\"logo\"` | String | Logo to be shown in Main Menu |\n| `\"logoOver\"` | String | Logo to be shown in Main Menu when mouse is over |\n| `\"logoSmall\"` | String | Small version of logo, prepared for drawing small icons |\n| `\"tooltip\"` | String | Tooltip to be shown on mouse over |\n| `\"tooltipOwned\"` | String | Tooltip to be shown on mouse over the icon when DLC is owned by player |\n| `\"action\"` | String | URL to be triggered when mod button is clicked |\n| `\"actionName\"` | String | What to put on Action Button |\n| `\"overview\"` | String | Overview text visible in expansion menu |\n| `\"hidePicture\"` | Boolean | Do not show mod picture icon in the main menu mod list |\n| `\"hideName\"` | Boolean | Do not show mod name in the main menu mod list |\n| `\"defaultMod\"` | Boolean | Default mods cannot be moved or disabled by Mod Launcher |\n| `\"serverOnly\"` | Boolean | Mod does not have to be installed on client in order to play on server with this mod running |\n| `\"active\"` | Boolean | Active mod (activated through command line or stored in profile by mod launcher)<br>> [!IMPORTANT]<br>> Note that `\"active\"` does not actually tell if a mod is actually running. |"}],"returns":{"type":"Array","types":["Array"],"description":"retrieved requested data on success or empty array `[]`","text":"Array - retrieved requested data on success or empty array `[]`"},"form":"unary","operator":null,"left":null,"right":{"text":"[modClass, options]","types":["Array"]}}],"examples":[{"text":"```sqf\n_data = modParams [\"Kart\", [\"name\", \"logo\", \"picture\"]];\n```","code":["_data = modParams [\"Kart\", [\"name\", \"logo\", \"picture\"]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["configSourceModList","configSourceMod"],"notes":[{"user":"Killzone_Kid","date":"2017-04-24T21:25:00Z","text":"This command used to spam .rpt when queried mod didn't exist, making it little awkward to use for testing if mod is active. For example:\n\n```sqf\n_superDuperModEnabled = modParams [\"super_duper\", [\"active\"]] param [0, false];\n```\n\nSince v1.69 the command would fail silently if mod didn't exist, but would still log .rpt error if the mod name passed to the command was empty or there was an error processing one of the passed options."},{"user":"heyoxe","date":"2021-02-26T16:42:00Z","text":"For each value, it will first read the value from the `mod.cpp` file, if the value is not in it (or the files does not exist), it will try to read it from the `CfgMods` entry as long as it has the **exact** same name. If you try to get `\"name\"` and the command cannot find it in either of those locations, it will return the same value as the `modClass` input.\n\nIn practice, this means that content from user mods will always be read from `mod.cpp` and never from the `CfgMods`."},{"user":"mikero","date":"2021-10-07T16:21:17Z","text":"Later versions of PboProject and its friends with arma as the intended engine, will **never** allow a cfgmods to appear in a pbo. Instead, it will scribble it out to a mod.cpp in the mods\\ folder that this pbo was intended for."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"moonIntensity","operator":null,"title":"moonIntensity","type":"command","url":"https://community.bistudio.com/wiki/moonIntensity","revid":369557,"updated":"2024-09-21T22:26:41Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the intensity of the moon's brightness in range 0..1.","syntaxes":[{"syntax":"moonIntensity","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_intensity = moonIntensity;\n```","code":["_intensity = moonIntensity;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moonPhase","sunOrMoon"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"moonPhase","operator":null,"title":"moonPhase","type":"command","url":"https://community.bistudio.com/wiki/moonPhase","revid":377266,"updated":"2026-01-02T06:34:11Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the phase of the in-game Moon on the given date.\nAccording to this command, the fullest Moon in Arma 3 at midnight is on `setDate [4804, 7, 13, 0, 0];`.\nUse the Moon Phase Utility to find out a scenario date with desired moon.","syntaxes":[{"syntax":"moonPhase date","since":null,"effect":null,"exec":null,"params":[{"name":"date","type":"Date","optional":false,"default":null,"description":null,"types":["Date"],"since":null,"text":"date: Date"}],"returns":{"type":"Number in 0..1 range","types":["Number"],"description":"0 = new Moon, 1 = full Moon","text":"Number in 0..1 range - 0 = new Moon, 1 = full Moon"},"form":"unary","operator":null,"left":null,"right":{"text":"date","types":["Date"]}}],"examples":[{"text":"```sqf\nprivate _currentMoonPhase = moonPhase date;\n```","code":["private _currentMoonPhase = moonPhase date;"]},{"text":"```sqf\n// Returns array of dates for given year when moon is at its fullest\nfnc_fullMoonDates = \n{\n    private _year = param [0, 2035];\n    private [\"_date\", \"_phase\", \"_fullMoonDate\"];\n    private _fullMoonPhase = 1;\n    private _waxing = false;\n    private _fullMoonDates = [];\n    for \"_i\" from dateToNumber [_year, 1, 1, 0, 0] to dateToNumber [_year, 12, 31, 23, 59] step 1 / 365 do\n    {\n        _date = numberToDate [_year, _i];\n        _phase = moonPhase _date;\n\n        call\n        {\n            if (_phase > _fullMoonPhase) exitWith\n            {\n                _waxing = true;\n                _fullMoonDate = _date;\n            };\n\n            if (_waxing) exitWith \n            {\n                _waxing = false;\n                _fullMoonDates pushBack _fullMoonDate;\n            };\n        };\n\n        _fullMoonPhase = _phase;\n    };\n\n    _fullMoonDates;\n};\n\n//set random full moon date in year 1970\nsetDate selectRandom (1970 call fnc_fullMoonDates);\n```","code":["// Returns array of dates for given year when moon is at its fullest\nfnc_fullMoonDates = \n{\n\tprivate _year = param [0, 2035];\n\tprivate [\"_date\", \"_phase\", \"_fullMoonDate\"];\n\tprivate _fullMoonPhase = 1;\n\tprivate _waxing = false;\n\tprivate _fullMoonDates = [];\n\tfor \"_i\" from dateToNumber [_year, 1, 1, 0, 0] to dateToNumber [_year, 12, 31, 23, 59] step 1 / 365 do\n\t{\n\t\t_date = numberToDate [_year, _i];\n\t\t_phase = moonPhase _date;\n\n\t\tcall\n\t\t{\n\t\t\tif (_phase > _fullMoonPhase) exitWith\n\t\t\t{\n\t\t\t\t_waxing = true;\n\t\t\t\t_fullMoonDate = _date;\n\t\t\t};\n\n\t\t\tif (_waxing) exitWith \n\t\t\t{\n\t\t\t\t_waxing = false;\n\t\t\t\t_fullMoonDates pushBack _fullMoonDate;\n\t\t\t};\n\t\t};\n\n\t\t_fullMoonPhase = _phase;\n\t};\n\n\t_fullMoonDates;\n};\n\n//set random full moon date in year 1970\nsetDate selectRandom (1970 call fnc_fullMoonDates);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moonIntensity","sunOrMoon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"morale","operator":null,"title":"morale","type":"command","url":"https://community.bistudio.com/wiki/morale","revid":337696,"updated":"2023-02-21T11:22:08Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the provided unit's current morale level.","syntaxes":[{"syntax":"morale unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":"in range -1..+1","text":"Number - in range -1..+1"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint format [\"Leader's morale: %1\", morale leader player];\n```","code":["hint format [\"Leader's morale: %1\", morale leader player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["skill","setSkill"],"notes":[{"user":".kju","date":"2020-08-13T10:54:00Z","text":"In Arma 3 probably affects Suppression."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"move","operator":null,"title":"move","type":"command","url":"https://community.bistudio.com/wiki/move","revid":319343,"updated":"2022-05-13T09:23:55Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Let group move to given position. Active waypoints will be ignored when command is used.","syntaxes":[{"syntax":"group move position","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"position","type":"Position2D or PositionATL","optional":false,"default":null,"description":null,"types":["Position2D","PositionATL"],"since":null,"text":"position: Position2D or PositionATL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"position","types":["Position2D","PositionATL"]}}],"examples":[{"text":"```sqf\n_groupOne move position player;\n```","code":["_groupOne move position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doMove","commandMove","addWaypoint"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"move3DENCamera","operator":null,"title":"move3DENCamera","type":"command","url":"https://community.bistudio.com/wiki/move3DENCamera","revid":377459,"updated":"2026-01-02T06:47:27Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Moves the Eden Editor camera.","syntaxes":[{"syntax":"move3DENCamera [position, useOffset]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"PositionASL","optional":false,"default":null,"description":"new position","types":["PositionASL"],"since":null,"text":"position: PositionASL - new position"},{"name":"useOffset","type":"Boolean","optional":false,"default":null,"description":"Boolean\n- if true the camera will move to the *position*, add the offset defined in `configFile >> \"Cfg3DEN\" >> \"Camera\" >> \"moveOffset\"` and look at the *position*.  Default camera offset: `[0, -25, 25]`\n- if false, the camera will be moved to the exact *position*","types":["Boolean"],"since":null,"text":"useOffset: Boolean\n- if true the camera will move to the *position*, add the offset defined in `configFile >> \"Cfg3DEN\" >> \"Camera\" >> \"moveOffset\"` and look at the *position*.  Default camera offset: `[0, -25, 25]`\n- if false, the camera will be moved to the exact *position*"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, useOffset]","types":["Array"]}}],"examples":[{"text":"```sqf\nmove3DENCamera [getPosASL player, true];\n```","code":["move3DENCamera [getPosASL player, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENCamera"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"moveInAny","operator":null,"title":"moveInAny","type":"command","url":"https://community.bistudio.com/wiki/moveInAny","revid":378826,"updated":"2026-07-02T20:02:58Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Moves unit to the first available seat in the specified vehicle.\n\nThe order of priorities is the same order used in squad command when you order subordinates to get in vehicle to any position and is the same order used in Zeus when you drag units to a vehicle.\n\nSeat assignment seems to use the following priority logic:\n\ndriver (moveInDriver) → commander (moveInCommander) → gunner (moveInGunner) → turrets (moveInTurret) → cargo (moveInCargo).\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen. You should use moveOut to move the unit out of his vehicle before trying to move him into a new (or same) vehicle.\n\n> [!NOTE]\n> This command will move player into the locked vehicle or seat just as well.","syntaxes":[{"syntax":"unit moveInAny vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person","types":["Object"],"since":null,"text":"unit: Object - person"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success, false on failure","text":"Boolean - true on success, false on failure"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}},{"syntax":"unit moveInAny [vehicle, positions, ignoreLocked]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person","types":["Object"],"since":null,"text":"unit: Object - person"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"positions","type":"Array of Strings","optional":false,"default":null,"description":"array of positions to check and in which order. Positions are (in default order):\n- \"DRIVER\" - driver\n- \"COMMANDER\" - commander turret (turret configured as commander)\n- \"GUNNER\" - gunner turret (turret configured as gunner)\n- \"TURRET\" - other turrets incl. FFV but excl. gunner or commander turret\n- \"CARGO\" - cargo seats excl. FFV\nWhen empty array [] is given, all positions in default order (same as in the main syntax) will be considered; see also emptyPositions","types":["Array","String"],"since":null,"text":"positions: Array of Strings - array of positions to check and in which order. Positions are (in default order):\n- \"DRIVER\" - driver\n- \"COMMANDER\" - commander turret (turret configured as commander)\n- \"GUNNER\" - gunner turret (turret configured as gunner)\n- \"TURRET\" - other turrets incl. FFV but excl. gunner or commander turret\n- \"CARGO\" - cargo seats excl. FFV\nWhen empty array [] is given, all positions in default order (same as in the main syntax) will be considered; see also emptyPositions"},{"name":"ignoreLocked","type":"Boolean","optional":true,"default":"false","description":"true to ignore locked positions","types":["Boolean"],"since":null,"text":"ignoreLocked: Boolean - (Optional, default false) true to ignore locked positions"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success, false on failure","text":"Boolean - true on success, false on failure"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[vehicle, positions, ignoreLocked]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer moveInAny tank;\n```","code":["player moveInAny tank;"]},{"text":"```sqf\nplayer moveInAny [tank, [\"CARGO\", \"TURRET\"]]; // checks free cargo position, if not available, checks free turret next\n```","code":["player moveInAny [tank, [\"CARGO\", \"TURRET\"]]; // checks free cargo position, if not available, checks free turret next"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInDriver","moveInCommander","moveInGunner","moveInTurret","moveInCargo","emptyPositions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.18","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"moveInCargo","operator":null,"title":"moveInCargo","type":"command","url":"https://community.bistudio.com/wiki/moveInCargo","revid":351994,"updated":"2024-02-01T23:23:57Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Moves a unit into a vehicle cargo position (immediately and without animation).\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen. You should use moveOut to move the unit out of his vehicle before trying to move him into a new (or same) vehicle.","syntaxes":[{"syntax":"unit moveInCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}},{"syntax":"unit moveInCargo [vehicle, cargoIndex, canReassign]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"cargoIndex","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"cargoIndex: Number"},{"name":"canReassign","type":"Boolean","optional":true,"default":"true","description":"try to move *unit* into the first free *vehicle* cargo seat if *cargoIndex* is already occupied","types":["Boolean"],"since":"arma3 2.08","text":"canReassign: Boolean - (Optional, default true) try to move *unit* into the first free *vehicle* cargo seat if *cargoIndex* is already occupied"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[vehicle, cargoIndex, canReassign]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne moveInCargo _jeepOne;\n```","code":["_soldierOne moveInCargo _jeepOne;"]},{"text":"```sqf\n_soldierOne moveInCargo [_jeepOne, 1];\n```","code":["_soldierOne moveInCargo [_jeepOne, 1];"]}],"multiplayer":"> [!NOTE]\n> The command should execute where the **unit** (not **vehicle**) is local.","problems":null,"aliases":[],"see_also":["moveInAny","moveInCommander","moveInDriver","moveInGunner","moveInTurret","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","getCargoIndex"],"notes":[{"user":"Hardrock","date":"2006-08-04T14:42:00Z","text":"*Notes from before the conversion*\n\nIf you place a soldier in a vehicle with the moveInCargo command, he wont \"know\" he's in the vehicle, and thus he won't disembark properly when the vehicle reaches a Transport Unload waypoint.\nTherefore you have to use the assignAsCargo command, in order for the AI to catch on. Something like this:\n\n```sqf\n_soldier moveInCargo helo1; _soldier assignAsCargo helo1;\n```"},{"user":"Ceeeb","date":"2007-02-02T07:00:00Z","text":"In **OFP v1.96**, the moveIn commands will not trigger an associated getIn event. To ensure the getIn event is fired, use the \"getIn Cargo\" action command."},{"user":"Killzone_Kid","date":"2014-03-18T19:08:00Z","text":"In Arma 3 when using the alternative syntax of moveInCargo, it is necessary to call assignAsCargoIndex because it is not called automatically.\n\n```sqf\nunit1 moveInCargo [heli, 3];\nunit1 assignAsCargoIndex [heli, 3];\n```\n\nAlternatively avoid this broken syntax all together and use:\n\n```sqf\nunit1 assignAsCargoIndex [heli, 3];\nunit1 moveInCargo heli;\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveInCommander","operator":null,"title":"moveInCommander","type":"command","url":"https://community.bistudio.com/wiki/moveInCommander","revid":352017,"updated":"2024-02-01T23:24:06Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Move soldier into vehicle commander position (Immediate, no animation).\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen. You should use moveOut to move the unit out of his vehicle before trying to move him into a new (or same) vehicle.","syntaxes":[{"syntax":"unitName moveInCommander vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldierOne moveInCommander _tankOne;\n```","code":["_soldierOne moveInCommander _tankOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInAny","moveInCargo","moveInDriver","moveInGunner","moveInTurret","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner"],"notes":[{"user":"Ceeeb","date":"2007-02-02T07:01:00Z","text":"In **OFP v1.96**, the moveIn commands will not trigger an associated getIn event. To ensure the getIn event is fired, use the \"getIn Commander\" action command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveInDriver","operator":null,"title":"moveInDriver","type":"command","url":"https://community.bistudio.com/wiki/moveInDriver","revid":363679,"updated":"2024-04-16T14:31:18Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Moves soldier into vehicle driver position (immediate, no animation).\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen unless moveOut (since Arma 2) is used first to move the unit out of their vehicle (see #Example 2).","syntaxes":[{"syntax":"unit moveInDriver vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n_soldierOne moveInDriver _tankOne;\n```","code":["_soldierOne moveInDriver _tankOne;"]},{"text":"```sqf\nif (not isNull vehicle player) then\n{\n    moveOut player;\n};\n\nplayer moveInDriver _myTruck;\n```","code":["if (not isNull vehicle player) then\n{\n\tmoveOut player;\n};\n\nplayer moveInDriver _myTruck;"]}],"multiplayer":"*unit* must be local, while the vehicle's locality does not matter.","problems":null,"aliases":[],"see_also":["moveInAny","moveInCargo","moveInCommander","moveInGunner","moveInTurret","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","isTurnedOut"],"notes":[{"user":"Ceeeb","date":"2007-02-02T06:02:00Z","text":"In **OFP v1.96**, the moveIn commands will not trigger an associated getIn event.\nTo ensure the getIn event is fired, use the \"getIn Driver\" action command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveInGunner","operator":null,"title":"moveInGunner","type":"command","url":"https://community.bistudio.com/wiki/moveInGunner","revid":378020,"updated":"2026-01-22T17:04:27Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Move the unit into vehicle gunner position (immediate, no animation).\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen.\n> You should use moveOut to move the unit out of his vehicle before trying to move him into a new (or same) vehicle.","syntaxes":[{"syntax":"unitName moveInGunner vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nsoldierOne moveInGunner tankOne;\n```","code":["soldierOne moveInGunner tankOne;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveInAny","moveInCargo","moveInCommander","moveInDriver","moveInTurret","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner"],"notes":[{"user":"Ceeeb","date":"2007-02-02T06:02:00Z","text":"In **OFP v1.96**, the moveIn commands will not trigger an associated getIn event.\nTo ensure the getIn event is fired, use the \"getIn Gunner\" action command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveInTurret","operator":null,"title":"moveInTurret","type":"command","url":"https://community.bistudio.com/wiki/moveInTurret","revid":377492,"updated":"2026-01-02T06:49:15Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Moves the soldier into the vehicle's turret. (Immediately, without animation).\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.\n\n> [!IMPORTANT]\n> If the unit is already in a vehicle, nothing will happen. You should use moveOut to move the unit out of his vehicle before trying to move him into a new (or same) vehicle.","syntaxes":[{"syntax":"unitName moveInTurret [vehicle, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"[vehicle, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne moveInTurret [_tank, [0, 0]];\n```","code":["_soldierOne moveInTurret [_tank, [0, 0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allTurrets","fullCrew","assignAsTurret","moveInAny","moveInCargo","moveInCommander","moveInDriver","moveInGunner","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","ArmA: Actions"],"notes":[{"user":"Kronzky","date":"2008-03-06T20:31:00Z","text":"To find out which turrets are available on a vehicle (**edit:** before allTurrets), and what the syntax is, you can use [this little script](http://kronzky.info/turrets/index.htm)."},{"user":"hcpookie","date":"2014-02-13T01:56:00Z","text":"Examples for nested turrets:\n\nMainTurret = \n\n```sqf\n_soldierOne moveInTurret [_tank, [0]];\n```\n\nCommanderTurret = \n\n```sqf\n_soldierOne moveInTurret [_tank, [0, 0]];\n```\n\n... where:\n\nMainTurret is the standard BIS MainTurret... e.g:\n\n```cpp\nclass Turrets \n{\n    class MainTurret {};\n};\n```\n\nCommanderTurret is the standard BIS CommanderTurret located on the MainTurret... e.g:\n\n```cpp\nclass Turrets \n{\n    class MainTurret\n    {\n        class Turrets \n        {\n            class CommanderTurret {};\n        };\n    };\n};\n```"},{"user":"Killzone_Kid","date":"2014-03-19T00:07:00Z","text":"Here is a small function to find available *turret paths* for a given vehicle. It will only search 2 levels deep, hence called *commonTurrets*:\n\n```sqf\nKK_fnc_commonTurrets = {\n    private [\"_arr\",\"_trts\"];\n    _arr = [];\n    _trts = configFile / \"CfgVehicles\" / typeOf _this / \"Turrets\";\n    for \"_i\" from 0 to count _trts - 1 do {\n        _arr set [count _arr, [_i]];\n        for \"_j\" from 0 to count (\n            _trts / configName (_trts select _i) / \"Turrets\"\n        ) - 1 do {\n            _arr set [count _arr, [_i, _j]];\n        };\n    };\n    _arr\n};\n```\n\nExample call:\n\n```sqf\nhint str (vehicle player call KK_fnc_commonTurrets); // [[0],[0,0]]\n```\n\nSee also allTurrets"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveObjectToEnd","operator":null,"title":"moveObjectToEnd","type":"command","url":"https://community.bistudio.com/wiki/moveObjectToEnd","revid":363294,"updated":"2024-03-26T10:52:01Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shifts an editor object to the end of the objects array. This means,that the object will be drawn last (after all other objects).\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map moveObjectToEnd object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"moveOut","operator":null,"title":"moveOut","type":"command","url":"https://community.bistudio.com/wiki/moveOut","revid":349641,"updated":"2023-11-16T22:02:40Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Moves the soldier out of the vehicle.\n\nNotes:\n- Works for both AI and player entities\n- AI unit gets back in - unless is under player command or combined with other sqf commands (orderGetIn false, allowGetIn false or leaveVehicle)\n- Respects the vehicle's lock state (same as action \"Eject\") - unlike doGetOut, commandGetOut. It will work for player entities regardless though\n- Still executes when the vehicle is moving/flying (same as action \"Eject\") - unlike doGetOut, commandGetOut\n- Without vehicle's position's get out animation - unlike action eject, doGetOut, commandGetOut\n- Immediately - unlike action eject, doGetOut, commandGetOut\n- Works also on dead units (same as action \"Eject\" (but one after another)) - unlike doGetOut, commandGetOut\n- Does not work for UAV crew\n- Does not work for remoteControlled units\n- Works on unconscious (same as action \"Eject\" (but one after another)) - unlike doGetOut, commandGetOut (unless AI under player command)","syntaxes":[{"syntax":"moveOut soldier","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":"unit (only a living unit before Arma 3 v2.06)","types":["Object"],"since":null,"text":"soldier: Object - unit (only a living unit before Arma 3 v2.06)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"soldier","types":["Object"]}},{"syntax":"soldier moveOut vehicle","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"soldier: Object - unit"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle could be objNull, in this case the command is identical to the main syntax.","types":["Object"],"since":null,"text":"vehicle: Object - vehicle could be objNull, in this case the command is identical to the main syntax."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n{ if (lifeState _x == \"UNCONSCIOUS\") then { moveOut _x } } forEach crew cursorTarget;\n```","code":["{ if (lifeState _x == \"UNCONSCIOUS\") then { moveOut _x } } forEach crew cursorTarget;"]},{"text":"Move out player just before he dies:\n\n```sqf\nplayer addEventHandler [\n    \"HandleDamage\", \n    format [\n        'if (switch (_this select 1) do {\n            case \"\": { _this select 2 >= 1 };\n            case \"head\": {_this select 2 >= %1};\n            case \"body\": {_this select 2 >= %2};\n            default {false};\n        }) then {moveOut player}',\n        getNumber (configFile >> \"CfgFirstAid\" >> \"CriticalHeadHit\"),\n        getNumber (configFile >> \"CfgFirstAid\" >> \"CriticalBodyHit\")\n    ]\n];\n```","code":["player addEventHandler [\n\t\"HandleDamage\", \n\tformat [\n\t\t'if (switch (_this select 1) do {\n\t\t\tcase \"\": { _this select 2 >= 1 };\n\t\t\tcase \"head\": {_this select 2 >= %1};\n\t\t\tcase \"body\": {_this select 2 >= %2};\n\t\t\tdefault {false};\n\t\t}) then {moveOut player}',\n\t\tgetNumber (configFile >> \"CfgFirstAid\" >> \"CriticalHeadHit\"),\n\t\tgetNumber (configFile >> \"CfgFirstAid\" >> \"CriticalBodyHit\")\n\t]\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Actions","doGetOut","commandGetOut","leaveVehicle","moveInDriver","moveInGunner","moveInCommander","moveInTurret","moveInCargo","isTurnedOut"],"notes":[{"user":".kju","date":"2020-08-07T08:53:00Z","text":"This seems no longer true in Arma 3:\n\n*Does not work on dead crew - Use setPos family of commands to move dead units out soon after they became dead. After awhile dead unit's group becomes grpNull and it cannot be moved out at all.*"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveTarget","operator":null,"title":"moveTarget","type":"command","url":"https://community.bistudio.com/wiki/moveTarget","revid":377512,"updated":"2026-01-02T06:50:18Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Change information about a target.","syntaxes":[{"syntax":"target moveTarget [position, typeAccuracy, posAccuracy]","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Target","optional":false,"default":null,"description":null,"types":["Target"],"since":null,"text":"target: Target"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"typeAccuracy","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"typeAccuracy: Number"},{"name":"posAccuracy","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"posAccuracy: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"target","types":["Target"]},"right":{"text":"[position, typeAccuracy, posAccuracy]","types":["Array"]}}],"examples":[{"text":"```sqf\n_moved = _target moveTarget [position player, 1, 1];\n```","code":["_moved = _target moveTarget [position player, 1, 1];"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command is not implemented.","aliases":[],"see_also":["createTarget","deleteTarget"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"moveTime","operator":null,"title":"moveTime","type":"command","url":"https://community.bistudio.com/wiki/moveTime","revid":310173,"updated":"2022-05-05T13:10:28Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current time of the most important RTM animation currently being played on the soldier.","syntaxes":[{"syntax":"moveTime soldier","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier:  Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"soldier","types":["Object"]}}],"examples":[{"text":"```sqf\nmoveTime player;\n```","code":["moveTime player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"moveTo","operator":null,"title":"moveTo","type":"command","url":"https://community.bistudio.com/wiki/moveTo","revid":377530,"updated":"2026-01-02T06:53:13Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Low level command to person to move to given position. It is good to check first if AI pilot unit state is COMPLETED moveToCompleted first as this command will set unit into WAIT state waiting for instruction, but only if the unit has COMPLETED.","syntaxes":[{"syntax":"unit moveTo position","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"position","type":"PositionATL","optional":false,"default":null,"description":null,"types":["PositionATL"],"since":null,"text":"position: PositionATL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"position","types":["PositionATL"]}}],"examples":[{"text":"```sqf\n_myAgent moveTo getPosATL player;\n```","code":["_myAgent moveTo getPosATL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["doMove","commandMove","setDestination","move","moveToCompleted","moveToFailed","addWaypoint"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"moveToCompleted","operator":null,"title":"moveToCompleted","type":"command","url":"https://community.bistudio.com/wiki/moveToCompleted","revid":369921,"updated":"2024-10-19T12:27:30Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if latest low level moveTo command is finished. Returns true if given AI pilot unit state == COMPLETED","syntaxes":[{"syntax":"moveToCompleted person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_isCompleted = moveToCompleted _unit;\n```","code":["_isCompleted = moveToCompleted _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveTo","moveToFailed"],"notes":[{"user":"DreadedEntity","date":"2022-04-02T20:31:47Z","text":"This command can also check the status of doMove and commandMove (A3 2.08.149102)\nThis is handy to make your script wait until a unit has moved to some position:\n\n```sqf\nwaitUntil {moveToCompleted _unit};\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"moveToFailed","operator":null,"title":"moveToFailed","type":"command","url":"https://community.bistudio.com/wiki/moveToFailed","revid":369920,"updated":"2024-10-19T12:26:25Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if latest low level moveTo command failed.","syntaxes":[{"syntax":"moveToFailed unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"NOT IMPLEMENTED, ALWAYS false","text":"Boolean - NOT IMPLEMENTED, ALWAYS false"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _hasFailed = moveToFailed _unit;\n```","code":["private _hasFailed = moveToFailed _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moveTo","moveToCompleted"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"musicVolume","operator":null,"title":"musicVolume","type":"command","url":"https://community.bistudio.com/wiki/musicVolume","revid":376980,"updated":"2026-01-01T06:16:13Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current music volume (set by fadeMusic)","syntaxes":[{"syntax":"musicVolume","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..5","types":["Number"],"description":null,"text":"Number in range 0..5"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str musicVolume;\n```","code":["hint str musicVolume;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeMusic","soundVolume","radioVolume","speechVolume","environmentVolume","getAudioOptionVolumes"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"name","operator":null,"title":"name","type":"command","url":"https://community.bistudio.com/wiki/name","revid":373980,"updated":"2025-07-10T15:43:22Z","groups":["Unit Identity","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"When argument is Object, the command returns the name given to a unit using the setIdentity instruction or selected randomly by the game engine if setIdentity has not been used on the unit.\nIf used on vehicle, name of first crew member (in order commander, driver, gunner). If used on an object, \"Error: No unit\" is being returned.","syntaxes":[{"syntax":"name object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"name location","since":"arma1 1.08","effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"String","types":["String"],"description":"the location's name. To get its textual value, use text (see #Example 3)","text":"String - the location's *name*. To get its textual value, use text (see #Example 3)"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}},{"syntax":"name namespace","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"namespace","type":"Namespace","optional":false,"default":null,"description":null,"types":["Namespace"],"since":null,"text":"namespace: Namespace"}],"returns":{"type":"String","types":["String"],"description":"namespace's name. Possible values: - \"mission\" - for missionNamespace - \"profile\" - for profileNamespace - \"ui\" - for uiNamespace - \"parsing\" - for parsingNamespace - \"local\" - for localNamespace - \"missionprofile\" - for missionProfileNamespace - \"server\" - for serverNamespace - \"\" - for some unnamed namespaces like temporary or server config for example. - \"null\" - null namespace (this should never happen)","text":"String - namespace's *name*. Possible values:\n\n- \"mission\" - for missionNamespace\n- \"profile\" - for profileNamespace\n- \"ui\" - for uiNamespace\n- \"parsing\" - for parsingNamespace\n- \"local\" - for localNamespace\n- \"missionprofile\" - for missionProfileNamespace\n- \"server\" - for serverNamespace\n- \"\" - for some unnamed namespaces like temporary or server config for example.\n- \"null\" - null namespace (this should never happen)"},"form":"unary","operator":null,"left":null,"right":{"text":"namespace","types":["Namespace"]}},{"syntax":"name scriptHandle","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":null,"types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle"}],"returns":{"type":"String","types":["String"],"description":"The name given to the script via scriptName or the name passed to spawn when creating a \"Empty Handle\"","text":"String - The name given to the script via scriptName or the name passed to spawn when creating a \"Empty Handle\""},"form":"unary","operator":null,"left":null,"right":{"text":"scriptHandle","types":["Script Handle"]}}],"examples":[{"text":"```sqf\n_name = name player;\n```","code":["_name = name player;"]},{"text":"```sqf\n_locationName = name myLocation;\n```","code":["_locationName = name myLocation;"]},{"text":"```sqf\nname nearestLocation [position player, \"Hill\"]; // \"\"\ntext nearestLocation [position player, \"Hill\"]; // \"Lesnoy Khrebet\"\n```","code":["name nearestLocation [position player, \"Hill\"]; // \"\"\ntext nearestLocation [position player, \"Hill\"]; // \"Lesnoy Khrebet\""]},{"text":"```sqf\n_currentNamespace = name currentNamespace;\n```","code":["_currentNamespace = name currentNamespace;"]}],"multiplayer":"name returns profileName, eventually suffixed by the server in the event of identical names, e.g `username`/`username (2)`.","problems":"> [!IMPORTANT]\n> If the provided unit is dead and has been removed from its group, its identity has then been purged to save memory and using name on it will result in a logged error.","aliases":[],"see_also":["profileName","setName","setIdentity","nameSound","setNameSound","createLocation","deleteLocation","locationPosition","nearestLocation","nearestLocations","nearestLocationWithDubbing"],"notes":[{"user":"Kju","date":"2017-01-30T19:42:00Z","text":"Location variant appears to be only for the 3d editor."},{"user":"Alef","date":"2009-04-14T01:41:00Z","text":"Will return `Error: No vehicle` for JIP players in init.sqf, if no sleep were performed."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"namedProperties","operator":null,"title":"namedProperties","type":"command","url":"https://community.bistudio.com/wiki/namedProperties","revid":338564,"updated":"2023-03-20T14:40:54Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of named properties on Geometry LOD.","syntaxes":[{"syntax":"namedProperties object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":null,"types":["Array","String"],"description":null,"text":"Array of Arrays of Strings, in format: [[namedProperty1, propertyValue1], [namedProperty2, propertyValue2], ...]"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"object namedProperties [LOD]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution","types":["String","Number"],"since":null,"text":"LOD: String or Number - can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution"}],"returns":{"type":"HashMap","types":["HashMap"],"description":null,"text":"HashMap"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[LOD]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _properties = namedProperties _object; // [[\"sbsource\",\"shadowvolume\"],[\"prefershadowvolume\",\"1\"],[\"reversed\",\"1\"],[\"buoyancy\",\"1\"]]\n```","code":["private _properties = namedProperties _object; // [[\"sbsource\",\"shadowvolume\"],[\"prefershadowvolume\",\"1\"],[\"reversed\",\"1\"],[\"buoyancy\",\"1\"]]"]},{"text":"```sqf\nprivate _namedProperties = cursorObject namedProperties [\"FireGeometry\"];\n```","code":["private _namedProperties = cursorObject namedProperties [\"FireGeometry\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectionNames","animationNames","Arma 3: Named Properties","allLODs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"nameSound","operator":null,"title":"nameSound","type":"command","url":"https://community.bistudio.com/wiki/nameSound","revid":310222,"updated":"2022-05-05T13:10:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the nameSound of a person.","syntaxes":[{"syntax":"nameSound person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nnameSound player;\n```","code":["nameSound player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setNameSound","name","setName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.02","Scripting Commands"]},{"name":"nearEntities","operator":null,"title":"nearEntities","type":"command","url":"https://community.bistudio.com/wiki/nearEntities","revid":377403,"updated":"2026-01-02T06:44:59Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Finds entities inside a sphere with the given radius. If the alternative syntax is used, only entities of given types or subtypes are listed.\nEntities returned are not sorted by distance.\n\nThe main syntax does not return dead entities or entities inside vehicles. If you need to return those, use the alternative syntax (with *includeCrew* set to true) or the entities command.\n\n> [!NOTE]\n> This command is much faster than nearestObjects for on-foot soldier and vehicle detection.","syntaxes":[{"syntax":"position nearEntities radius","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"search centre","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D - search centre"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"radius of the sphere","types":["Number"],"since":null,"text":"radius: Number - radius of the sphere"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"not sorted","text":"Array of Objects - not sorted"},"form":"binary","operator":null,"left":{"text":"position","types":["Object","PositionAGL","Position2D"]},"right":{"text":"radius","types":["Number"]}},{"syntax":"position nearEntities [type, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"search centre","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D - search centre"},{"name":"type","type":"String or Array of Strings","optional":false,"default":null,"description":"type(s) to search for. See isKindOf","types":["String","Array"],"since":null,"text":"type: String or Array of Strings - type(s) to search for. See isKindOf"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"radius of the sphere","types":["Number"],"since":null,"text":"radius: Number - radius of the sphere"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"not sorted","text":"Array of Objects - not sorted"},"form":"binary","operator":null,"left":{"text":"position","types":["Object","PositionAGL","Position2D"]},"right":{"text":"[type, radius]","types":["Array"]}},{"syntax":"area nearEntities [types, matchExactType, aliveOnly, includeCrew]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"area","type":"String, Object or Array:","optional":false,"default":null,"description":"String, Object or Array:\n- String - marker name\n- Object - trigger\n- Array - format [center, a, b, angle, isRectangular, c] or Arma 3 v2.22 [center, a, b, angle, isRectangular, c, usePosWorld] (see inArea)","types":["String","Object","Array"],"since":null,"text":"area: String, Object or Array:\n- String - marker name\n- Object - trigger\n- Array - format [center, a, b, angle, isRectangular, c] or Arma 3 v2.22 [center, a, b, angle, isRectangular, c, usePosWorld] (see inArea)"},{"name":"types","type":"Array of Strings","optional":false,"default":null,"description":"type(s) to search for or [] empty array to return every type","types":["Array","String"],"since":null,"text":"types: Array of Strings - type(s) to search for or [] empty array to return every type"},{"name":"matchExactType","type":"Boolean","optional":true,"default":"false","description":"true for an exact type match, false for an isKindOf match","types":["Boolean"],"since":null,"text":"matchExactType: Boolean - (Optional, default false) true for an exact type match, false for an isKindOf match"},{"name":"aliveOnly","type":"Boolean","optional":true,"default":"true","description":"true to ignore dead entities, false to include them","types":["Boolean"],"since":null,"text":"aliveOnly: Boolean - (Optional, default true) true to ignore dead entities, false to include them"},{"name":"includeCrew","type":"Boolean","optional":true,"default":"false","description":"true to include crew of vehicles in search","types":["Boolean"],"since":null,"text":"includeCrew: Boolean - (Optional, default false) true to include crew of vehicles in search"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"not sorted","text":"Array of Objects - not sorted"},"form":"binary","operator":null,"left":{"text":"area","types":["String","Object","Array"]},"right":{"text":"[types, matchExactType, aliveOnly, includeCrew]","types":["Array"]}}],"examples":[{"text":"```sqf\n_list = player nearEntities 20;\n_list = ASLToAGL getPosASL player nearEntities 50;\n_list = player nearEntities [\"Man\", 1000];\n_list = ASLToAGL getPosASL player nearEntities [\"LaserTarget\", 3000];\n_list = player nearEntities [[\"Car\", \"Motorcycle\", \"Tank\"], 50];\n_list = ASLToAGL getPosASL player nearEntities [[\"Man\", \"Air\", \"Car\", \"Motorcycle\", \"Tank\"], 200];\n```","code":["_list = player nearEntities 20;\n_list = ASLToAGL getPosASL player nearEntities 50;\n_list = player nearEntities [\"Man\", 1000];\n_list = ASLToAGL getPosASL player nearEntities [\"LaserTarget\", 3000];\n_list = player nearEntities [[\"Car\", \"Motorcycle\", \"Tank\"], 50];\n_list = ASLToAGL getPosASL player nearEntities [[\"Man\", \"Air\", \"Car\", \"Motorcycle\", \"Tank\"], 200];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["entities","findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestBuilding","operator":null,"title":"nearestBuilding","type":"command","url":"https://community.bistudio.com/wiki/nearestBuilding","revid":377548,"updated":"2026-01-02T06:54:43Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Finds the nearest building to a given object or position. A \"building\" is defined as an object that is of class \"House\" and contains a path LOD.","syntaxes":[{"syntax":"nearestBuilding position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or Position2D or PositionAGL","optional":false,"default":null,"description":null,"types":["Object","Position2D","PositionAGL"],"since":null,"text":"position: Object or Position2D or PositionAGL"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Object","Position2D","PositionAGL"]}}],"examples":[{"text":"```sqf\n_nBuilding = nearestBuilding player;\n```","code":["_nBuilding = nearestBuilding player;"]},{"text":"```sqf\n_nBuilding = nearestBuilding position player;\n```","code":["_nBuilding = nearestBuilding position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["buildingPos","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[{"user":"Pierre MGI","date":"2016-02-18T20:18:00Z","text":"This command doesn't return any house or building placed in editor (with createVehicle). Use nearestObjects instead:\n\n```sqf\nnearestObjects [player, [\"House\", \"Building\"], 50] select 0\n```"},{"user":"Tankbuster","date":"2020-12-30T16:04:00Z","text":"Some large buildings are not found by this command. \"Land_Airport_Tower_F\", \"Land_Offices_01_V1_F\" and \"Land_Hotel_02_F\" are examples."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestLocation","operator":null,"title":"nearestLocation","type":"command","url":"https://community.bistudio.com/wiki/nearestLocation","revid":377409,"updated":"2026-01-02T06:45:10Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the closest location of specified class to a given position. Checked range is unlimited (i.e. covers the whole map).\n\n> [!NOTE]\n> Although locations can be placed in 3D with setPosition, nearestLocations search is conducted in 2D.","syntaxes":[{"syntax":"nearestLocation [position, locationType, maxDistance]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D"},{"name":"locationType","type":null,"optional":false,"default":null,"description":"String of a location class name. If \"\" is supplied, any nearest location is returned. Since Arma 3 2.14 locationType could be an Array of location types. See Location Types","types":["String","Array","Location Types"],"since":null,"text":"locationType: String of a location class name. If \"\" is supplied, any nearest location is returned. Since Arma 3 2.14 locationType could be an Array of location types. See Location Types"},{"name":"maxDistance","type":"Number","optional":true,"default":null,"description":"max search radius. Default - unlimited range.","types":["Number"],"since":"arma3 2.14","text":"maxDistance: Number - (Optional) max search radius. Default - unlimited range."}],"returns":{"type":"Location","types":["Location"],"description":null,"text":"Location"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, locationType, maxDistance]","types":["Array"]}}],"examples":[{"text":"```sqf\n_nearestCity = nearestLocation [getPos player, \"nameCity\"];\n```","code":["_nearestCity = nearestLocation [getPos player, \"nameCity\"];"]},{"text":"```sqf\n_anyNearestLocation = nearestLocation [player, \"\"];\n```","code":["_anyNearestLocation = nearestLocation [player, \"\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","Location","locationPosition","nearestLocations","createLocation","nearestMines"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestLocations","operator":null,"title":"nearestLocations","type":"command","url":"https://community.bistudio.com/wiki/nearestLocations","revid":377540,"updated":"2026-01-02T06:54:27Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of locations of chosen type(s) within the given radius of the given position, sorted from nearest to farthest.\n\n> [!NOTE]\n> Although locations can be placed in 3D with setPosition, nearestLocations' search result is sorted in 2D.","syntaxes":[{"syntax":"nearestLocations [centre, locationTypes, radius, sortPosition]","since":null,"effect":null,"exec":null,"params":[{"name":"centre","type":"Position2D, Position3D or Object","optional":false,"default":null,"description":null,"types":["Position2D","Position3D","Object"],"since":null,"text":"centre: Position2D, Position3D or Object"},{"name":"locationTypes","type":"Array of Strings","optional":false,"default":null,"description":"list of location type names, e.g \"NameCity\"; Arma 3 v2.14 passing empty array [] will return all available locations within the radius","types":["Array","String"],"since":null,"text":"locationTypes: Array of Strings - list of location type names, e.g \"NameCity\"; Arma 3 v2.14 passing empty array [] will return all available locations within the radius"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"maximum distance from the given position that returned locations may be, in metres","types":["Number"],"since":null,"text":"radius: Number - maximum distance from the given position that returned locations may be, in metres"},{"name":"sortPosition","type":"Position2D, Position3D or Object","optional":true,"default":null,"description":"results will be sorted from the distance to given *sortPosition* (nearest to farthest still)","types":["Position2D","Position3D","Object"],"since":null,"text":"sortPosition: Position2D, Position3D or Object - (Optional) results will be sorted from the distance to given *sortPosition* (nearest to farthest still)"}],"returns":{"type":"Array of Locations","types":["Array","Location"],"description":null,"text":"Array of Locations"},"form":"unary","operator":null,"left":null,"right":{"text":"[centre, locationTypes, radius, sortPosition]","types":["Array"]}}],"examples":[{"text":"```sqf\n_nearbyLocations = nearestLocations [getPosATL player, [\"RockArea\", \"VegetationFir\"], 100];\n```","code":["_nearbyLocations = nearestLocations [getPosATL player, [\"RockArea\", \"VegetationFir\"], 100];"]},{"text":"Find any of nearest locations:\n\n```sqf\nprivate _allLocationTypes = [];\n\"_allLocationTypes pushBack configName _x\" configClasses (configFile >> \"CfgLocationTypes\");\n{\n    systemChat format [\n        \"%1 (%2) - %3m\", \n        _x, \n        text _x, \n        getPosATL player distance _x\n    ];\n} forEach nearestLocations [player, _allLocationTypes, 500];\n```","code":["private _allLocationTypes = [];\n\"_allLocationTypes pushBack configName _x\" configClasses (configFile >> \"CfgLocationTypes\");\n{\n\tsystemChat format [\n\t\t\"%1 (%2) - %3m\", \n\t\t_x, \n\t\ttext _x, \n\t\tgetPosATL player distance _x\n\t];\n} forEach nearestLocations [player, _allLocationTypes, 500];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createLocation","nearestLocation","locationPosition","nearestLocationWithDubbing"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestLocationWithDubbing","operator":null,"title":"nearestLocationWithDubbing","type":"command","url":"https://community.bistudio.com/wiki/nearestLocationWithDubbing","revid":377422,"updated":"2026-01-02T06:45:33Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find the nearest location having a non-empty speech.\n\n> [!NOTE]\n> **Arma 3:** No locations are dubbed in Arma 3.","syntaxes":[{"syntax":"nearestLocationWithDubbing position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D"}],"returns":{"type":"Location","types":["Location"],"description":null,"text":"Location"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Object","PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_location = nearestLocationWithDubbing player;\n```","code":["_location = nearestLocationWithDubbing player;"]},{"text":"```sqf\n_location = nearestLocationWithDubbing getMarkerPos \"myMarker\";\n```","code":["_location = nearestLocationWithDubbing getMarkerPos \"myMarker\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearObjectsReady","nearRoads","nearestMines"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestMines","operator":null,"title":"nearestMines","type":"command","url":"https://community.bistudio.com/wiki/nearestMines","revid":377408,"updated":"2026-01-02T06:45:08Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of nearest mines of the given types to the given position or object, within the specified distance.\nIf more than one mine are found they will be ordered by proximity by default, the closest one will be first in the array. The sorting can be turned off.","syntaxes":[{"syntax":"nearestMines [position, types, radius, sort, 2Dmode]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"search position centre","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position:  Object or PositionAGL or Position2D - search position centre"},{"name":"types","type":"Array","optional":false,"default":null,"description":"list of class name of the objects to search for (uses isKindOf comparison instead of direct class name == comparison). Use an empty array `[]` to search for all classes","types":["Array"],"since":null,"text":"types: Array - list of class name of the objects to search for (uses isKindOf comparison instead of direct class name == comparison). Use an empty array `[]` to search for all classes"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"search range","types":["Number"],"since":null,"text":"radius: Number - search range"},{"name":"sort","type":"Boolean","optional":true,"default":"true","description":"true to sort the results closest first, false to turn off sorting","types":["Boolean"],"since":null,"text":"sort: Boolean - (Optional, default true) true to sort the results closest first, false to turn off sorting"},{"name":"2Dmode","type":"Boolean","optional":true,"default":"false","description":"true for 2D distance, false for 3D distance comparison","types":["Boolean"],"since":null,"text":"2Dmode: Boolean - (Optional, default false) true for 2D distance, false for 3D distance comparison"}],"returns":{"type":"Array","types":["Array"],"description":"found mines as array of Objects","text":"Array - found mines as array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, types, radius, sort, 2Dmode]","types":["Array"]}}],"examples":[{"text":"```sqf\nnearestMines [player, [\"MineBase\"], 20];\n```","code":["nearestMines [player, [\"MineBase\"], 20];"]},{"text":"```sqf\nnearestMines [position player, [\"DirectionalBombBase\"], 500, true];\n```","code":["nearestMines [position player, [\"DirectionalBombBase\"], 500, true];"]},{"text":"```sqf\nnearestMines [[2716,2949,0], [\"APERSTripMine_Wire_Ammo\", \"APERSMine_Range_Ammo\"], 100, false, true];\n```","code":["nearestMines [[2716,2949,0], [\"APERSTripMine_Wire_Ammo\", \"APERSMine_Range_Ammo\"], 100, false, true];"]},{"text":"Return every mine in 50 metres radius around player sorted by distance:\n\n```sqf\nnearestMines [player, [], 50];\n```","code":["nearestMines [player, [], 50];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestTerrainObjects","findNearestEnemy","nearestBuilding","nearestObject","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"nearestObject","operator":null,"title":"nearestObject","type":"command","url":"https://community.bistudio.com/wiki/nearestObject","revid":377544,"updated":"2026-01-02T06:54:36Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the nearest object of given type (or inherited classes) to given position within a sphere. Hardcoded radius is 50 meters.\nUnlike with nearestObjects, where distance is measured in 2D space, nearestObject will be closest object in 3D space.\n\n> [!NOTE]\n> - in Operation Flashpoint, only objects of the exact provided class are found.\n> - if an object ID is used (#Syntax 4, see #Example 2) the search range is unlimited","syntaxes":[{"syntax":"nearestObject [position, type]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or Position2D or Position3D","optional":false,"default":null,"description":"position to start search at","types":["Object","Position2D","Position3D"],"since":null,"text":"position: Object or Position2D or Position3D - position to start search at"},{"name":"type","type":"String","optional":false,"default":null,"description":"type of object (see typeOf, class type)","types":["String"],"since":null,"text":"type: String - type of object (see typeOf, class type)"}],"returns":{"type":"Object","types":["Object"],"description":"nearest object, objNull otherwise","text":"Object - nearest object, objNull otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, type]","types":["Array"]}},{"syntax":"nearestObject position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"position to start search at","types":["Position2D","Position3D"],"since":null,"text":"position: Position2D or Position3D - position to start search at"}],"returns":{"type":"Object","types":["Object"],"description":"nearest object, objNull otherwise","text":"Object - nearest object, objNull otherwise"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position2D","Position3D"]}},{"syntax":"position nearestObject typeOrId","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position3D or Position2D","optional":false,"default":null,"description":"position to start search at","types":["Position3D","Position2D"],"since":null,"text":"position: Position3D or Position2D - position to start search at"},{"name":"typeOrId","type":"String","optional":false,"default":null,"description":"type of object (see typeOf, class type) or Arma 3 v2.10 Visitor id (see getObjectID)","types":["String"],"since":null,"text":"typeOrId: String - type of object (see typeOf, class type) or Arma 3 v2.10 Visitor id (see getObjectID)"}],"returns":{"type":"Object","types":["Object"],"description":"nearest object, objNull otherwise","text":"Object - nearest object, objNull otherwise"},"form":"binary","operator":null,"left":{"text":"position","types":["Position3D","Position2D"]},"right":{"text":"typeOrId","types":["String"]}},{"syntax":"position nearestObject id","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"position to start search at","types":["Position2D","Position3D"],"since":null,"text":"position: Position2D or Position3D - position to start search at"},{"name":"id","type":"Number","optional":false,"default":null,"description":"object Visitor id","types":["Number"],"since":null,"text":"id: Number - object Visitor id"}],"returns":{"type":"Object","types":["Object"],"description":"nearest object, objNull otherwise","text":"Object - nearest object, objNull otherwise"},"form":"binary","operator":null,"left":{"text":"position","types":["Position2D","Position3D"]},"right":{"text":"id","types":["Number"]}}],"examples":[{"text":"```sqf\n_nObject = nearestObject [2345, 6789];\n_nObject = nearestObject [player, \"StreetLamp\"];\n```","code":["_nObject = nearestObject [2345, 6789];\n_nObject = nearestObject [player, \"StreetLamp\"];"]},{"text":"Return the object with ID 123456:\n\n```sqf\n_nObject = [0,0,0] nearestObject 123456;\n```","code":["_nObject = [0,0,0] nearestObject 123456;"]},{"text":"```sqf\n_nObject = getPos player nearestObject \"StreetLamp\";\n```","code":["_nObject = getPos player nearestObject \"StreetLamp\";"]},{"text":"Return the nearest object with (typeOf _nObject == \"#XXXX\") -> #mark, #slop, etc. Unlimited search range:\n\n```sqf\n_nObject = _position nearestObject -1;\n```\n\nReturn the nearest object with (typeOf _nObject != \"\"). Search range is 50m:\n\n```sqf\n_nObject = nearestObject _position;\n```","code":["_nObject = _position nearestObject -1;","_nObject = nearestObject _position;"]},{"text":"(See also allMissionObjects):\n\n```sqf\n_blood    = nearestObject [player, \"#slop\"];\n_step    = nearestObject [player, \"#mark\"];\n_track    = nearestObject [player, \"#track\"];\n_crater    = nearestObject [player, \"#crater\"];\n```","code":["_blood\t= nearestObject [player, \"#slop\"];\n_step\t= nearestObject [player, \"#mark\"];\n_track\t= nearestObject [player, \"#track\"];\n_crater\t= nearestObject [player, \"#crater\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestObjects","nearObjectsReady","nearObjects","objectFromNetId","nearEntities","entities","object","nearestBuilding","nearestTerrainObjects","nearestMines"],"notes":[{"user":"Gnashes","date":"2019-01-29T15:31:00Z","text":"The ID for Syntax 4 may be dynamically obtained via the following (as of Arma 3 v1.88):\n(for Arma 3 v2.10 or newer, use getObjectID instead)\n\n```sqf\n// returns Object Terrain/Visitor ID, or -1 if no ID found (invalid/null object)\ncursorObject call {\n    private _obj = str (param [0, objNull]);\n    private _id = -1;\n\n    private _find = ((_obj find \"#\") + 2);\n    if (_find > 1) then\n    {\n        private _len = ((_obj find \":\") - _find);\n        _id = _obj select [_find, _len];\n        parseNumber _id;\n    };\n    _id\n};\n```"},{"user":"blackfisch","date":"2020-02-12T08:55:00Z","text":"Note, that if you want to check for the nearest Unit you have to check for `CAManBase` instead of `Man`, since `Man` will also return any wildlife population in that area:\n\n```sqf\nnearestObject [player, \"Man\"];            // could possibly return rabbits or other wildlife\nnearestObject [player, \"CAManBase\"];    // only returns units\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestObjects","operator":null,"title":"nearestObjects","type":"command","url":"https://community.bistudio.com/wiki/nearestObjects","revid":377394,"updated":"2026-01-02T06:44:39Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of nearest objects of the given types to the given position or object, within the specified distance. If more than one object is found they will be ordered by proximity, the closest one will be first in the array. If an object is given as the center and the filter criteria applies to it, it will be the first result in the list. Alternatively, you can use nearObjects command, which doesn't sort results.\n\nA list of ClassName types (e.g `Tank`) can be found in CfgVehicles.\n\n> [!IMPORTANT]\n> This command matches objects using isKindOf comparison instead of direct class name == comparison. As a result, if a class type is a parent, the search will return all objects that inherit from the parent as well as parent itself. This command also only finds objects that are **entities**. If you are looking for non-entity objects, see nearObjects, nearestObject.\n\n> [!WARNING]\n> Because of map object streaming, using nearestObjects or similar object finding commands over long distance from player camera may not find what you are looking for, as some objects might not exist at the time of command execution. Use nearestTerrainObjects instead.","syntaxes":[{"syntax":"nearestObjects [position, types, radius, 2Dmode]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"where to find objects, center position.","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position:  Object or PositionAGL or Position2D - where to find objects, center position."},{"name":"types","type":"Array","optional":false,"default":null,"description":"list of class name of the objects to search for. Use an empty array `[]` to search for all classes.","types":["Array"],"since":null,"text":"types: Array - list of class name of the objects to search for. Use an empty array `[]` to search for all classes."},{"name":"radius","type":"Number","optional":false,"default":null,"description":"range from center position to search for objects.","types":["Number"],"since":null,"text":"radius: Number - range from center position to search for objects."},{"name":"2Dmode","type":"Boolean","optional":true,"default":"false","description":"true for 2D distance, false for 3D distance","types":["Boolean"],"since":"arma3 1.66","text":"2Dmode: Boolean - (Optional, default false) true for 2D distance, false for 3D distance"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, types, radius, 2Dmode]","types":["Array"]}}],"examples":[{"text":"```sqf\nnearestObjects [player, [\"Car\", \"Tank\"], 200];\n```","code":["nearestObjects [player, [\"Car\", \"Tank\"], 200];"]},{"text":"```sqf\nnearestObjects [player, [\"house\"], 200];\n```","code":["nearestObjects [player, [\"house\"], 200];"]},{"text":"```sqf\nnearestObjects [[2716,2949,0], [\"Car\", \"Truck\"], 100];\n```","code":["nearestObjects [[2716,2949,0], [\"Car\", \"Truck\"], 100];"]},{"text":"Return every object in 50 metres radius around player:\n\n```sqf\nnearestObjects [player, [], 50];\n```","code":["nearestObjects [player, [], 50];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestTerrainObjects","findNearestEnemy","nearestBuilding","nearestObject","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[{"user":"PhilippRauch","date":"2010-04-03T16:21:00Z","text":"To get a list with alive targets for various situations use this construct:\n\n```sqf\n_nearestTargets = nearestObjects [_submunScanPos, [\"VBS2_TANK\", \"TANK\"], _scanArea];\n_validNearestTargets = [];\n{ if (alive _x ) then { _validNearestTargets set [(count _validNearestTargets), _x]; }; } forEach _nearestTargets;\n```\n\nresults in _validNearestTargets being filled with targets == alive .. (you could use other conditions there, of course!)"},{"user":"Rübe","date":"2010-08-10T02:28:00Z","text":"Passing an empty array to define the types will also return objects with no class at all (such as trees, bushes, stones, ...).\nExample:\n\n```sqf\n_objects = nearestObjects [_position, [], _radius];\n```\n\nPassing the array [\"All\"] is not the same and will only return objects that have some sort of class."},{"user":"Katulobotomia","date":"2013-09-11T14:54:00Z","text":"If you want to detect nearby grenades for the position of a unit, for example, using 'nearestObjects' won't work. You have to use\n'nearObjects' instead.\n\n```sqf\ncount (nearestObjects [_unit, [\"GrenadeHand\"], 30]); // WON'T WORK\n```\n\nWon't ever return anything but 0.\n\n```sqf\ncount (_unit nearObjects [\"GrenadeHand\", 30]); // WORKS!\n```\n\nWill work."},{"user":"AgentRev01","date":"2014-03-22T02:38:00Z","text":"The distance from which an object is determined to be inside the radius is calculated from its model center (object modelToWorld [0,0,0]), and not the position returned by getPos/ATL/ASL. If an object is used as the origin from which to scan, distance is calculated from its model center as well."},{"user":"Killzone_Kid","date":"2014-10-26T15:15:00Z","text":"Return all trees in 100m radius around player:\n\n```sqf\nprivate _trees = [];\n{\n    if (str _x find \": t_\" > -1) then {\n        _trees pushBack _x;\n    };\n} forEach nearestObjects [player, [], 100];\n```"},{"user":"Tankbuster","date":"2015-08-27T16:45:00Z","text":"If you use \"Man\" as the class to look for, it will only find dismounted men. IE, men in vehicles will NOT be found."},{"user":"Killzone_Kid","date":"2016-01-08T12:14:00Z","text":"The first call to this command can take significantly longer than consecutive calls. But even after the objects in given radius were cached, the sorting this command performs could be quite expensive. For example to sort ~7000 object it might take up to 100ms. For performance reasons you can use nearObjects instead, which is basically the same command but without added sorting."},{"user":"Ceeeb","date":"2016-03-02T23:09:00Z","text":"In Arma 3, nearestObjects is partially broken and is unable to return nearby placed explosive charges or mines when searching by classnames. Use nearObjects, nearestObject or allMines instead.\n\nExample of non-functional code:\n\n```sqf\n// always returns nothing, even if there are objects that should be returned\nnearestObjects [position player, [\"APERSMine_Range_Ammo\", \"SatchelCharge_Remote_Ammo\"], 10];\n```"},{"user":"Killzone_Kid","date":"2016-10-31T00:32:00Z","text":"Since Arma 3 v1.66 the default sorting is done according to 3D distance not distance2D as before. This is an attempt to correct some very old bug in implementation."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearestTerrainObjects","operator":null,"title":"nearestTerrainObjects","type":"command","url":"https://community.bistudio.com/wiki/nearestTerrainObjects","revid":377095,"updated":"2026-01-01T09:55:27Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of nearest terrain objects of the given types to the given position or object, within the specified distance. If more than one object is found they will be ordered according to 3D distance to the object (i.e. the closest one will be first in the array).\nIn contrast to nearestObjects this command returns terrain placed objects like trees, rocks and buildings which don't necessarily need an associated config class.\n\nPossible type names:\n- `\"BUILDING\"`\n- `\"BUNKER\"`\n- `\"BUSH\"`\n- `\"BUSSTOP\"`\n- `\"CHAPEL\"`\n- `\"CHURCH\"`\n- `\"CROSS\"`\n- `\"FENCE\"`\n- `\"FOREST BORDER\"`\n- `\"FOREST SQUARE\"`\n- `\"FOREST TRIANGLE\"`\n- `\"FOREST\"`\n- `\"FORTRESS\"`\n- `\"FOUNTAIN\"`\n- `\"FUELSTATION\"`\n- `\"HIDE\"`\n- `\"HOSPITAL\"`\n- `\"HOUSE\"`\n- `\"LIGHTHOUSE\"`\n- `\"MAIN ROAD\"`\n- `\"POWER LINES\"`\n- `\"POWERSOLAR\"`\n- `\"POWERWAVE\"`\n- `\"POWERWIND\"`\n- `\"QUAY\"`\n- `\"RAILWAY\"`\n- `\"ROAD\"`\n- `\"ROCK\"`\n- `\"ROCKS\"`\n- `\"RUIN\"`\n- `\"SHIPWRECK\"`\n- `\"SMALL TREE\"`\n- `\"STACK\"`\n- `\"TOURISM\"`\n- `\"TRACK\"`\n- `\"TRAIL\"`\n- `\"TRANSMITTER\"`\n- `\"TREE\"`\n- `\"VIEW-TOWER\"`\n- `\"WALL\"`\n- `\"WATERTOWER\"`\n\n> [!IMPORTANT]\n> The names are / The filter is based on the named property map - not on the named property *class* or any config definition!\n\n> [!NOTE]\n> Types which are missing are not present in the given world. Virtual Reality has no terrain objects. Last updated Arma 3 v2.12\n\nStratis\n- BUSH: 47974\n- CHAPEL: 2\n- CROSS: 1\n- FENCE: 1728\n- FUELSTATION: 3\n- HIDE: 70975\n- HOUSE: 684\n- LIGHTHOUSE: 3\n- ROAD: 143\n- ROCK: 820\n- SHIPWRECK: 11\n- TRACK: 2063\n- TRANSMITTER: 11\n- TREE: 40110\n- WALL: 1355\n- WATERTOWER: 1\n\nAltis\n- BUSH: 747193\n- CHAPEL: 165\n- CHURCH: 54\n- CROSS: 48\n- FENCE: 47940\n- FUELSTATION: 32\n- HIDE: 655958\n- HOSPITAL: 1\n- HOUSE: 17472\n- LIGHTHOUSE: 7\n- MAIN ROAD: 2061\n- POWER LINES: 2224\n- POWERSOLAR: 10\n- POWERWAVE: 51\n- POWERWIND: 128\n- ROAD: 4849\n- ROCK: 5483\n- RUIN: 3\n- SHIPWRECK: 43\n- TOURISM: 1\n- TRACK: 26823\n- TRANSMITTER: 23\n- TREE: 263630\n- WALL: 38943\n- WATERTOWER: 10\n\nMalden 2035\n- BUSH: 288461\n- BUSSTOP: 45\n- CHAPEL: 14\n- CHURCH: 14\n- CROSS: 16\n- FENCE: 11189\n- FUELSTATION: 24\n- HIDE: 192553\n- HOUSE: 4062\n- LIGHTHOUSE: 15\n- MAIN ROAD: 1050\n- POWER LINES: 3427\n- POWERSOLAR: 1\n- ROAD: 1442\n- ROCK: 3513\n- SHIPWRECK: 23\n- TRACK: 3489\n- TRANSMITTER: 7\n- TREE: 101960\n- WALL: 14189\n- WATERTOWER: 63\n\nTanoa\n- BUSH: 754347\n- CHURCH: 21\n- FENCE: 2912\n- FUELSTATION: 85\n- HIDE: 356904\n- HOUSE: 13389\n- MAIN ROAD: 2921\n- POWER LINES: 3985\n- POWERSOLAR: 2\n- POWERWIND: 19\n- RAILWAY: 2138\n- ROAD: 1485\n- ROCK: 8909\n- SHIPWRECK: 58\n- TOURISM: 35\n- TRACK: 9419\n- TRAIL: 6936\n- TRANSMITTER: 16\n- TREE: 506993\n- WALL: 20526\n- WATERTOWER: 73\n\nLivonia\n- BUILDING: 1262\n- BUNKER: 40\n- BUSH: 473543\n- BUSSTOP: 73\n- CHAPEL: 8\n- CHURCH: 17\n- FENCE: 48426\n- FOUNTAIN: 36\n- FUELSTATION: 7\n- HIDE: 474123\n- HOUSE: 6762\n- MAIN ROAD: 2118\n- POWER LINES: 2671\n- POWERSOLAR: 2\n- POWERWIND: 1\n- RAILWAY: 843\n- ROAD: 5378\n- ROCK: 744\n- SHIPWRECK: 4\n- STACK: 11\n- TRACK: 12834\n- TRANSMITTER: 15\n- TREE: 1881630\n- VIEW-TOWER: 239\n- WALL: 4418\n- WATERTOWER: 7\n\nWeferlingen\n- BUILDING: 5072\n- BUSH: 731315\n- BUSSTOP: 106\n- CHAPEL: 13\n- CHURCH: 21\n- FENCE: 83908\n- FUELSTATION: 9\n- HIDE: 231818\n- HOUSE: 4562\n- MAIN ROAD: 1535\n- POWER LINES: 1958\n- RAILWAY: 2324\n- ROAD: 8740\n- STACK: 18\n- TRACK: 24372\n- TRANSMITTER: 1\n- TREE: 829449\n- VIEW-TOWER: 34\n\nWeferlingen (Winter)\n- BUILDING: 5072\n- BUSH: 519827\n- BUSSTOP: 106\n- CHAPEL: 13\n- CHURCH: 21\n- FENCE: 83908\n- FUELSTATION: 9\n- HIDE: 229792\n- HOUSE: 4562\n- MAIN ROAD: 1535\n- POWER LINES: 1958\n- RAILWAY: 2324\n- ROAD: 8740\n- STACK: 18\n- TRACK: 24372\n- TRANSMITTER: 1\n- TREE: 829449\n- VIEW-TOWER: 34\n\nCam Lao Nam\n- BUILDING: 390\n- BUNKER: 2622\n- BUSH: 1852844\n- CHURCH: 6\n- FENCE: 12346\n- FORTRESS: 2\n- FOUNTAIN: 3\n- FUELSTATION: 32\n- HIDE: 309385\n- HOUSE: 13319\n- LIGHTHOUSE: 3\n- MAIN ROAD: 4162\n- POWER LINES: 1591\n- POWERSOLAR: 5\n- POWERWIND: 5\n- RAILWAY: 1345\n- ROAD: 17621\n- ROCK: 60452\n- SHIPWRECK: 161\n- TOURISM: 18\n- TRACK: 6846\n- TRAIL: 7726\n- TRANSMITTER: 33\n- TREE: 1442842\n- VIEW-TOWER: 529\n- WALL: 19664\n- WATERTOWER: 32\n\nKhe Sanh\n- BUILDING: 91\n- BUNKER: 4861\n- BUSH: 1299130\n- FENCE: 2196\n- FOUNTAIN: 2\n- FUELSTATION: 3\n- HIDE: 228731\n- HOUSE: 5754\n- POWER LINES: 801\n- ROAD: 7755\n- ROCK: 33853\n- TRACK: 8156\n- TRANSMITTER: 3\n- TREE: 1145377\n- VIEW-TOWER: 227\n- WALL: 9078\n- WATERTOWER: 13\n\nThe Bra\n- BUILDING: 8\n- BUNKER: 265\n- BUSH: 179428\n- FENCE: 251\n- HIDE: 56960\n- HOUSE: 522\n- POWER LINES: 25\n- ROAD: 7\n- ROCK: 671\n- SHIPWRECK: 2\n- TRACK: 584\n- TRAIL: 2767\n- TRANSMITTER: 1\n- TREE: 203443\n- VIEW-TOWER: 48\n- WALL: 2076\n\nGabreta\n- BUILDING: 222\n- BUSH: 383449\n- BUSSTOP: 18\n- CHAPEL: 10\n- CHURCH: 11\n- CROSS: 17\n- FENCE: 25616\n- FORTRESS: 149\n- FOUNTAIN: 2\n- FUELSTATION: 11\n- HIDE: 582635\n- HOSPITAL: 1\n- HOUSE: 6352\n- MAIN ROAD: 4427\n- POWER LINES: 502\n- POWERSOLAR: 2\n- RAILWAY: 1923\n- ROAD: 8693\n- ROCK: 918\n- RUIN: 5\n- SHIPWRECK: 1\n- STACK: 6\n- TRACK: 10066\n- TRAIL: 1170\n- TRANSMITTER: 2\n- TREE: 3473175\n- VIEW-TOWER: 39\n- WALL: 6218\n- WATERTOWER: 8\n\nSefrou-Ramal\n- BUILDING: 2\n- BUSH: 13669\n- FENCE: 5199\n- FUELSTATION: 2\n- HIDE: 23243\n- HOUSE: 1963\n- MAIN ROAD: 403\n- POWER LINES: 565\n- POWERWIND: 19\n- RAILWAY: 135\n- ROAD: 199\n- ROCK: 1183\n- TRACK: 3286\n- TRANSMITTER: 9\n- TREE: 7592\n- WALL: 3560\n- WATERTOWER: 2\n\nSpearhead 1944 Normandy\n- BUILDING: 2918\n- BUNKER: 1703\n- BUSH: 608441\n- CHURCH: 45\n- CROSS: 16\n- FENCE: 288630\n- FORTRESS: 196\n- FOUNTAIN: 1286\n- HIDE: 330656\n- HOUSE: 12837\n- MAIN ROAD: 1981\n- RAILWAY: 776\n- ROAD: 20237\n- ROCK: 837\n- RUIN: 1\n- SMALL TREE: 20\n- TRACK: 29761\n- TRAIL: 6365\n- TREE: 581549\n- VIEW-TOWER: 95\n- WALL: 60793\n- WATERTOWER: 34\n\nSpearhead 1944 Mortain\n- BUILDING: 759\n- BUNKER: 597\n- BUSH: 192944\n- CHURCH: 7\n- CROSS: 3\n- FENCE: 66361\n- FORTRESS: 35\n- FOUNTAIN: 320\n- HIDE: 140143\n- HOUSE: 3120\n- MAIN ROAD: 551\n- RAILWAY: 733\n- ROAD: 4276\n- ROCK: 1896\n- SMALL TREE: 19\n- TRACK: 11268\n- TRAIL: 996\n- TREE: 291745\n- VIEW-TOWER: 65\n- WALL: 13364\n- WATERTOWER: 13","syntaxes":[{"syntax":"nearestTerrainObjects [position, types, radius, sort, 2Dmode]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object, PositionAGL or Position2D","optional":false,"default":null,"description":"where to find objects, center position","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object, PositionAGL or Position2D - where to find objects, center position"},{"name":"types","type":"Array","optional":false,"default":null,"description":"list of case-insensitive types of the objects to search for. `[]` to search without filters","types":["Array"],"since":null,"text":"types: Array - list of case-insensitive types of the objects to search for. `[]` to search without filters"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"range from center position to search for objects","types":["Number"],"since":null,"text":"radius: Number - range from center position to search for objects"},{"name":"sort","type":"Boolean","optional":true,"default":"true","description":"sort objects by distance to the center or not - setting to false **greatly** improves performance","types":["Boolean"],"since":"arma3 1.62","text":"sort: Boolean - (Optional, default true) sort objects by distance to the center or not - setting to false **greatly** improves performance"},{"name":"2Dmode","type":"Boolean","optional":true,"default":"false","description":"the object search and sorting mode: true - 2D, false - 3D","types":["Boolean"],"since":"arma3 1.66","text":"2Dmode: Boolean - (Optional, default false) the object search and sorting mode: true - 2D, false - 3D"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"Before Arma 3 v2.00 this command did not return roads of type `\"ROAD\"`, `\"MAIN ROAD\"`, `\"TRACK\"`, `\"TRAIL\"`","text":"Array of Objects - Before Arma 3 v2.00 this command did not return roads of type `\"ROAD\"`, `\"MAIN ROAD\"`, `\"TRACK\"`, `\"TRAIL\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, types, radius, sort, 2Dmode]","types":["Array"]}}],"examples":[{"text":"```sqf\nnearestTerrainObjects [player, [\"Tree\", \"Bush\"], 200];\n```","code":["nearestTerrainObjects [player, [\"Tree\", \"Bush\"], 200];"]},{"text":"```sqf\nnearestTerrainObjects [player, [\"House\"], 200];\n```","code":["nearestTerrainObjects [player, [\"House\"], 200];"]},{"text":"```sqf\nnearestTerrainObjects [[2716, 2949, 0], [\"Chapel\", \"Fuelstation\"], 100];\n```","code":["nearestTerrainObjects [[2716, 2949, 0], [\"Chapel\", \"Fuelstation\"], 100];"]},{"text":"Return every terrain object in 50 metres radius around player sorted, closest first:\n\n```sqf\nnearestTerrainObjects [player, [], 50];\n```","code":["nearestTerrainObjects [player, [], 50];"]},{"text":"Return every terrain object in 50 metres radius around player unsorted:\n\n```sqf\nnearestTerrainObjects [player, [], 50, false];\n```","code":["nearestTerrainObjects [player, [], 50, false];"]},{"text":"Hide all terrain objects (run locally for each client):\n\n```sqf\nprivate _allTerrainObjects = nearestTerrainObjects\n[\n    [worldSize / 2, worldSize / 2],\n    [],\n    worldSize * sqrt 2 / 2,\n    false,\n    true\n];\n{ _x hideObject true } forEach _allTerrainObjects;\n```","code":["private _allTerrainObjects = nearestTerrainObjects\n[\n\t[worldSize / 2, worldSize / 2],\n\t[],\n\tworldSize * sqrt 2 / 2,\n\tfalse,\n\ttrue\n];\n{ _x hideObject true } forEach _allTerrainObjects;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestObjects","findNearestEnemy","hideObject","nearestBuilding","nearestObject","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","roadsConnectedTo","roadAt","isOnRoad","getRoadInfo","nearestMines"],"notes":[{"user":"Killzone_Kid","date":"2016-10-31T00:20:00Z","text":"Since Arma 3 v1.66 the default sorting is done according to 3D distance not distance2D as before. This is an attempt to correct some very old bug in implementation."},{"user":"Demellion","date":"2016-12-28T20:21:00Z","text":"Be aware that some terrain objects types might be tricky to be found, such as terrain rocks and boulders which are not considered to be \"ROCKS\" or \"ROCK\", but \"HIDE\". Example:\n\n```sqf\nnearestTerrainObjects [player, [\"HIDE\"], 20]; // [939688: bluntstone_01.p3d,939691: garbagebags_f.p3d,939671: wreck_car_f.p3d,939692: junkpile_f.p3d]\n```"},{"user":"Killzone_Kid","date":"2020-06-07T14:16:00Z","text":"Large bridges are map type `\"ROAD\"`. Small foot bridges are not roads and not included into road net."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"nearObjects","operator":null,"title":"nearObjects","type":"command","url":"https://community.bistudio.com/wiki/nearObjects","revid":377428,"updated":"2026-01-02T06:45:43Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find objects (Units, Vehicles, Dead, Map Objects) in a sphere with given radius. The first object in the returned array is *not* necessarily the closest one. If you need returned objects to be sorted by distance, use nearestObjects. If typeName is given, only objects of given type (or its subtype) are listed.","syntaxes":[{"syntax":"position nearObjects radius","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position, Position2D or Object","optional":false,"default":null,"description":null,"types":["Position","Position2D","Object"],"since":null,"text":"position: Position, Position2D or Object"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"position","types":["Position","Position2D","Object"]},"right":{"text":"radius","types":["Number"]}},{"syntax":"position nearObjects [typeName, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"PositionAGL, Position2D or Object","optional":false,"default":null,"description":null,"types":["PositionAGL","Position2D","Object"],"since":null,"text":"position: PositionAGL, Position2D or Object"},{"name":"typeName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"typeName: String"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"position","types":["PositionAGL","Position2D","Object"]},"right":{"text":"[typeName, radius]","types":["Array"]}}],"examples":[{"text":"```sqf\n_list = position player nearObjects 50;\n```","code":["_list = position player nearObjects 50;"]},{"text":"```sqf\n_list = [_xpos,_ypos] nearObjects [\"House\", 20];\n```","code":["_list = [_xpos,_ypos] nearObjects [\"House\", 20];"]},{"text":"```sqf\n_list = player nearObjects 20;\n```","code":["_list = player nearObjects 20;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[{"user":"Kronzky","date":"2007-06-30T08:21:00Z","text":"Units in vehicles are not detected via this command."},{"user":"Tankbuster","date":"2011-12-15T23:17:00Z","text":"In the second syntax, you can't omit the typeName parameter. It's required and you'll get an error if you don't supply it. Use \"All\" as an alternative to leaving it out. (CO 1.59)"},{"user":"Tankbuster","date":"2013-01-03T19:59:00Z","text":"If you use the first syntax, it will return objects many more objects such as pollen, honeybees and crucially, triggers. Triggers will show in the returned array as \"no shape\" but you can use typeOf to get the classname, which will give \"EmptyDetector\". This will not return objects that don't have classnames such as plants, stones and some map objects like vehicle wrecks. nearestObjects will find objects without classnames."},{"user":"Cheitan","date":"2017-08-08T16:08:00Z","text":"The syntax 2 means that the command will include all types which inherit from the given type. As an example, when using \"Helipad_Base_F\", the command will detect all types of helipads (Land_HelipadSquare_F, Land_HelipadCircle_F, Land_HelipadEmpty_F, etc) in the given radius."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearObjectsReady","operator":null,"title":"nearObjectsReady","type":"command","url":"https://community.bistudio.com/wiki/nearObjectsReady","revid":377425,"updated":"2026-01-02T06:45:38Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check whether all data are loaded to nearObjects will return in reasonable time.","syntaxes":[{"syntax":"position nearObjectsReady radius","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL or Position2D"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"position","types":["Object","PositionAGL","Position2D"]},"right":{"text":"radius","types":["Number"]}}],"examples":[{"text":"```sqf\n_twnpos nearObjectsReady 500; //from ALICE\n```","code":["_twnpos nearObjectsReady 500; //from ALICE"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearRoads","nearestMines"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearRoads","operator":null,"title":"nearRoads","type":"command","url":"https://community.bistudio.com/wiki/nearRoads","revid":377410,"updated":"2026-01-02T06:45:12Z","groups":["Roads and Airports","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find the road segments within the circle of given radius.","syntaxes":[{"syntax":"pos nearRoads radius","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":"center of search radius","types":["Object","PositionAGL","Position2D"],"since":null,"text":"pos: Object or PositionAGL or Position2D - center of search radius"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"search radius in meters","types":["Number"],"since":null,"text":"radius: Number - search radius in meters"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"road segments within radius","text":"Array of Objects - road segments within radius"},"form":"binary","operator":null,"left":{"text":"pos","types":["Object","PositionAGL","Position2D"]},"right":{"text":"radius","types":["Number"]}}],"examples":[{"text":"```sqf\n_list = player nearRoads 50;\n```","code":["_list = player nearRoads 50;"]},{"text":"```sqf\n_list = (position _unit) nearRoads 50;\n```","code":["_list = (position _unit) nearRoads 50;"]},{"text":"```sqf\n_list = [1800,5700] nearRoads 50;\n```","code":["_list = [1800,5700] nearRoads 50;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isOnRoad","roadAt","surfaceIsWater","roadsConnectedTo","findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearTargets","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","getRoadInfo","nearestTerrainObjects","nearestMines"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Roads and Airports","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nearSupplies","operator":null,"title":"nearSupplies","type":"command","url":"https://community.bistudio.com/wiki/nearSupplies","revid":377405,"updated":"2026-01-02T06:45:03Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find supplies (weapon holders, ammo crates, fuel feeds, other units) in the sphere with given radius.","syntaxes":[{"syntax":"origin nearSupplies radius","since":null,"effect":null,"exec":null,"params":[{"name":"origin","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"origin: Object or PositionAGL or Position2D"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"origin","types":["Object","PositionAGL","Position2D"]},"right":{"text":"radius","types":["Number"]}},{"syntax":"origin nearSupplies [typeName, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"origin","type":"Object or PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","Position2D"],"since":null,"text":"origin: Object or PositionAGL or Position2D"},{"name":"typeName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"typeName: String"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"origin","types":["Object","PositionAGL","Position2D"]},"right":{"text":"[typeName, radius]","types":["Array"]}}],"examples":[{"text":"```sqf\n_list = player nearSupplies 50;\n```","code":["_list = player nearSupplies 50;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearTargets","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines","getCorpse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"nearTargets","operator":null,"title":"nearTargets","type":"command","url":"https://community.bistudio.com/wiki/nearTargets","revid":377595,"updated":"2026-01-02T07:00:21Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.07"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.07"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of targets within the defined range. \"Targets\" are not restricted to enemy units.","syntaxes":[{"syntax":"unit nearTargets range","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"range","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"range: Number"}],"returns":{"type":"Array of Arrays in format [position, type, side, subjectiveCost, object, positionAccuracy]:","types":["Array"],"description":"position: Position3D - perceived position including judgment and memory errors - type: String - perceived, gives only what was recognized - side: Side - perceived side - subjectiveCost: Number - positive for enemies, more positive for more important or more dangerous enemies - object: Object object type, can be used to get more information if needed - positionAccuracy: Number - assumed accuracy of the perceived position","text":"Array of Arrays in format [position, type, side, subjectiveCost, object, positionAccuracy]:\n- position: Position3D - perceived position including judgment and memory errors\n- type: String - perceived, gives only what was recognized\n- side: Side - perceived side\n- subjectiveCost: Number - positive for enemies, more positive for more important or more dangerous enemies\n- object: Object object type, can be used to get more information if needed\n- positionAccuracy: Number - assumed accuracy of the perceived position"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"range","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer nearTargets 100;\n// can return e.g\n/*\n    [\n        [[2555.33,2535.33,1.32708],\"SoldierEB\",EAST,214222,EAST 1-1-A:1],\n        [[2550.39,2482.5,1.32696],\"SoldierWB\",WEST,0,WEST 1-1-A:2]\n    ]\n*/\n```","code":["player nearTargets 100;\n// can return e.g\n/*\n\t[\n\t\t[[2555.33,2535.33,1.32708],\"SoldierEB\",EAST,214222,EAST 1-1-A:1],\n\t\t[[2550.39,2482.5,1.32696],\"SoldierWB\",WEST,0,WEST 1-1-A:2]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targets","targetsQuery","targetsAggregate","targetKnowledge","knowsAbout","reveal","forgetTarget","setTargetAge","getHideFrom","findNearestEnemy","nearestBuilding","nearestObject","nearestObjects","nearObjects","nearestLocation","nearEntities","nearSupplies","nearestLocationWithDubbing","nearObjectsReady","nearRoads","nearestMines"],"notes":[{"user":"mrcurry","date":"2011-02-17T16:00:00Z","text":"A subjective cost greater than 0 does not necessarily mean the target is an enemy unit. **Any** unit, that have yet to be identified by the unit, have a small positive cost in the range 0 to 1."},{"user":".kju","date":"2012-01-15T17:45:00Z","text":"The quality/detail level of the info depends on the knowsAbout value of the sourceUnit about the targetUnit:\n\n- For infantry:\n  - ] 0  , 1.5 [ - side unknown, some position offset, identified as SoldierWB\n  - [ 1.5, 1.6 [ - side identified, subjective cost set\n  - [ 1.6, 2   [ - type identified better (USMC_Soldier_Base)\n  - [ 2  , 3.6 [ - type identified precisely (USMC_Soldier)\n  - [ 3.6, 4   ] - position identified precisely\n\nThe values seems closely linked to the accuracy value of the given targetUnit class and its parents up in the config tree:\n- 0\t\t\tclass CAManBase : Man\n- 1.6\t\tclass SoldierWB : CAManBase\n- 2\t\t\tclass USMC_Soldier_Base : SoldierWB\n- 3.9\t\tclass USMC_Soldier : USMC_Soldier_Base\n\n- For tanks:\n  - ] 0   , 0.03 [ - side unknown, some position offset, identified as LandVehicle\n  - [ 0.03, 0.13 [ - type identified better (Tank)\n  - [ 0.13, 0.3  [ - type identified better (M1A1)\n  - [ 0.3 , 1.5  [ - side identified, subjective cost set\n  - [ 1.5 , 3.6  [ - side identified precisely (CIV), subjective cost adjusted\n  - [ 3.6 , 4    ] - position identified precisely\n\nThe values seems closely linked to the accuracy value of the given targetUnit class and its parents up in the config tree:\n- 0\t\tclass All\n- class AllVehicles : All\n  - 0.0005\t\tclass Land : AllVehicles\n  - 0.02\t\tclass LandVehicle : Land\n  - 0.12\t\tclass Tank : LandVehicle\n  - 0.25\t\tclass M1A1 : Tank"},{"user":".kju","date":"2012-01-17T16:14:00Z","text":"- When an unit dies, it is nearTargets array gets emptied after some seconds.\n- When an unit dies, its reference will get removed from other units nearTargets' arrays immediately.\n- A target will be removed from the array after about 360 seconds without contact."},{"user":".kju","date":"2012-01-21T20:00:00Z","text":"Position accuracy seems to be a radius in meters from the perceived position."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Armed Assault version 1.07","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"needReload","operator":null,"title":"needReload","type":"command","url":"https://community.bistudio.com/wiki/needReload","revid":376453,"updated":"2025-10-14T11:29:23Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns how much vehicle wants to reload its weapons.","syntaxes":[{"syntax":"needReload entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle"}],"returns":{"type":"Number","types":["Number"],"description":"range: 0-1, 0: full mag, 1: empty mag","text":"Number - range: 0-1, 0: full mag, 1: empty mag"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}},{"syntax":"entity needReload muzzle","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"entity: Object - unit or vehicle"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"muzzle to check. \"\" to check all muzzles","types":["String"],"since":null,"text":"muzzle: String - muzzle to check. \"\" to check all muzzles"}],"returns":{"type":"Number","types":["Number"],"description":"range: 0-1, 0: full mag, 1: empty mag","text":"Number - range: 0-1, 0: full mag, 1: empty mag"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"muzzle","types":["String"]}}],"examples":[{"text":"```sqf\n_seriousness = needReload _vehicle;\n```","code":["_seriousness = needReload _vehicle;"]},{"text":"```sqf\nif (needReload player == 1) then { reload player };\n```","code":["if (needReload player == 1) then { reload player };"]},{"text":"```sqf\nplayer needReload currentMuzzle player;\n```","code":["player needReload currentMuzzle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["needService","reload","reloadEnabled","enableReload"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"needService","operator":null,"title":"needService","type":"command","url":"https://community.bistudio.com/wiki/needService","revid":377624,"updated":"2026-01-02T08:52:02Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with how much vehicle needs repairing, refueling and rearming.","syntaxes":[{"syntax":"needService vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array with [repair, refuel, rearm]. Values are in range 0..1: 0: no need, 1: maximum need"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nneedService tank params [\"_needRepair\", \"_needRefuel\", \"_needRearm\"];\n```","code":["needService tank params [\"_needRepair\", \"_needRefuel\", \"_needRearm\"];"]},{"text":"```sqf\nonEachFrame { hintSilent str needService vehicle player };\n```","code":["onEachFrame { hintSilent str needService vehicle player };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowService","allowedService","needReload"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"netId","operator":null,"title":"netId","type":"command","url":"https://community.bistudio.com/wiki/netId","revid":364973,"updated":"2024-07-04T17:25:50Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the unique ID of an object or a group.","syntaxes":[{"syntax":"netId objOrGroup","since":null,"effect":null,"exec":null,"params":[{"name":"objOrGroup","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"objOrGroup: Object or Group"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"objOrGroup","types":["Object","Group"]}}],"examples":[{"text":"```sqf\n_playerNetId = netId player;\n```","code":["_playerNetId = netId player;"]}],"multiplayer":"- In singleplayer: Arma 3 v2.18 returns a net ID (different from BIS_fnc_netId's output), before that it returned an empty string in single player (see BIS_fnc_netId and BIS_fnc_objectVar)\n- In multiplayer: works as described","problems":null,"aliases":[],"see_also":["objectFromNetId","groupFromNetId","BIS_fnc_objectFromNetId","BIS_fnc_netId","BIS_fnc_groupFromNetId","BIS_fnc_objectVar"],"notes":[{"user":"Demellion","date":"2018-10-19T13:40:00Z","text":"Even if the returned value is in format of **owner:uniqueid**, it doesn't follow the current ownership of an object (owner for example).\n\nThis command keeps the **original owner** of a created object."}],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"netObjNull","operator":null,"title":"netObjNull","type":"command","url":"https://community.bistudio.com/wiki/netObjNull","revid":379040,"updated":"2026-09-22T14:03:06Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existent NetObject. To compare non-existent objects use isNull or isEqualTo:\n\n```sqf\nnetObjNull == netObjNull;            // false\nnetObjNull != netObjNull;            // true\nisNull netObjNull;                    // true\nnetObjNull isEqualTo netObjNull;    // true\ntypeName netObjNull;                // \"NetObject\"\nnetObjNull isEqualType netObjNull;  // true\n```\n\n.\n\n> [!NOTE]\n> This command always returned false prior to Arma 3 2.24","syntaxes":[{"syntax":"netObjNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"NetObject","types":["NetObject"],"description":"null net object. Before Arma 3 2.24 Boolean, always returned false","text":"NetObject - null net object. Before Arma 3 2.24 Boolean, always returned false"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nstr netObjNull; // <NULL-NetObject>\n```","code":["str netObjNull; // <NULL-NetObject>"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["objNull"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"newOverlay","operator":null,"title":"newOverlay","type":"command","url":"https://community.bistudio.com/wiki/newOverlay","revid":353326,"updated":"2024-03-15T17:11:49Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates the new overlay dialog for the specified type of overlay.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map newOverlay config","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nextMenuItemIndex","operator":null,"title":"nextMenuItemIndex","type":"command","url":"https://community.bistudio.com/wiki/nextMenuItemIndex","revid":363274,"updated":"2024-03-26T10:51:44Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the next available menu item index.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"nextMenuItemIndex map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nextWeatherChange","operator":null,"title":"nextWeatherChange","type":"command","url":"https://community.bistudio.com/wiki/nextWeatherChange","revid":310789,"updated":"2022-05-07T20:21:49Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the remaining time (in seconds) over which the current weather change will occur.\n\nWhen a weather change finishes, the game engine will automatically generate a new random weather change over a realistic time period (minimum of 90 minutes).","syntaxes":[{"syntax":"nextWeatherChange","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_seconds = nextWeatherChange;\n```","code":["_seconds = nextWeatherChange;"]}],"multiplayer":"Each client and the server can have differing weather.","problems":null,"aliases":[],"see_also":["fog","fogForecast","setFog","overcast","setOvercast","overcastForecast","forceWeatherChange"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nil","operator":null,"title":"nil","type":"command","url":"https://community.bistudio.com/wiki/nil","revid":347969,"updated":"2023-11-08T09:38:47Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Nil value. This value can be used to undefine existing variables.","syntaxes":[{"syntax":"nil","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nvariableToDestroy = nil;\n```","code":["variableToDestroy = nil;"]},{"text":"```sqf\nprivate _variable = 50;\n_variable = nil;\nhint format [\"Variable = %1\", _variable];    // will display \"Variable = any\" in unscheduled environment\n                                            // will output \"Error Undefined variable in expression: _variable\" in scheduled environment\n// identical to\nhint format [\"Variable = %1\", _variableThatWasNeverDefined];\n```","code":["private _variable = 50;\n_variable = nil;\nhint format [\"Variable = %1\", _variable];\t// will display \"Variable = any\" in unscheduled environment\n\t\t\t\t\t\t\t\t\t\t\t// will output \"Error Undefined variable in expression: _variable\" in scheduled environment\n// identical to\nhint format [\"Variable = %1\", _variableThatWasNeverDefined];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isNil","Variables"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"nMenuItems","operator":null,"title":"nMenuItems","type":"command","url":"https://community.bistudio.com/wiki/nMenuItems","revid":353351,"updated":"2024-03-15T17:11:54Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the total number of user-added menu items belonging to the given menu. \n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map nMenuItems menuName","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"menuName","type":"String","optional":false,"default":null,"description":"\"file\" or \"view\"","types":["String"],"since":null,"text":"menuName: String - \"file\" or \"view\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"menuName","types":["String"]}},{"syntax":"map nMenuItems index","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"not","operator":null,"title":"not","type":"command","url":"https://community.bistudio.com/wiki/not","revid":319391,"updated":"2022-05-13T09:23:59Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"not a is exactly the same as ! a.","syntaxes":[{"syntax":"not a","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"a: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"a","types":["Boolean"]}}],"examples":[{"text":"```sqf\nnot false; // returns true\n```","code":["not false; // returns true"]}],"multiplayer":null,"problems":null,"aliases":["! a"],"see_also":["Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"numberOfEnginesRTD","operator":null,"title":"numberOfEnginesRTD","type":"command","url":"https://community.bistudio.com/wiki/numberOfEnginesRTD","revid":377770,"updated":"2026-01-03T01:32:19Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the number of engines a helicopter has. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"numberOfEnginesRTD helicopterRTD","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopterRTD","types":["Object"]}}],"examples":[{"text":"```sqf\n_engineCount = numberOfEnginesRTD vehicle player;\n```","code":["_engineCount = numberOfEnginesRTD vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"numberToDate","operator":null,"title":"numberToDate","type":"command","url":"https://community.bistudio.com/wiki/numberToDate","revid":377267,"updated":"2026-01-02T06:34:12Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Convert float number to a date.","syntaxes":[{"syntax":"numberToDate [year, time]","since":null,"effect":null,"exec":null,"params":[{"name":"year","type":"Number","optional":false,"default":null,"description":"year value, e.g 2035","types":["Number"],"since":null,"text":"year: Number - year value, e.g 2035"},{"name":"time","type":"Number","optional":false,"default":null,"description":"year time in range 0..1, from beginning to end of the year (e.g `0` is January 1st and `1` is December 31st)","types":["Number"],"since":null,"text":"time: Number - year time in range 0..1, from beginning to end of the year (e.g `0` is January 1st and `1` is December 31st)"}],"returns":{"type":"Date","types":["Date"],"description":null,"text":"Date"},"form":"unary","operator":null,"left":null,"right":{"text":"[year, time]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetDate numberToDate [2008, 0.5324]; // sets date to [2008,7,13,7,49]\n```","code":["setDate numberToDate [2008, 0.5324]; // sets date to [2008,7,13,7,49]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["dateToNumber","getNumber","isNumber","parseNumber","playersNumber"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"objectCurators","operator":null,"title":"objectCurators","type":"command","url":"https://community.bistudio.com/wiki/objectCurators","revid":377144,"updated":"2026-01-01T10:32:33Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all curators which can edit given object.","syntaxes":[{"syntax":"objectCurators obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\n_curatorsThatcanEdit = objectCurators BIS_Tank;\n```","code":["_curatorsThatcanEdit = objectCurators BIS_Tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addCuratorEditableObjects","curatorRegisteredObjects","removeCuratorEditableObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"objectFromNetId","operator":null,"title":"objectFromNetId","type":"command","url":"https://community.bistudio.com/wiki/objectFromNetId","revid":373126,"updated":"2025-04-02T15:43:29Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get object with given unique ID. For groups, use groupFromNetId.","syntaxes":[{"syntax":"objectFromNetId id","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"id: String"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"id","types":["String"]}}],"examples":[{"text":"```sqf\nobjectFromNetId \"2:3\"\n```","code":["objectFromNetId \"2:3\""]}],"multiplayer":"Before Arma 3 v2.18 it would return objNull in multiplayer - see BIS_fnc_objectFromNetId","problems":null,"aliases":[],"see_also":["groupFromNetId","netId","BIS_fnc_objectFromNetId","BIS_fnc_netId","BIS_fnc_groupFromNetId"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"objectParent","operator":null,"title":"objectParent","type":"command","url":"https://community.bistudio.com/wiki/objectParent","revid":363381,"updated":"2024-03-29T13:23:37Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the parent of an object if said object is a proxy.\n\n> [!IMPORTANT]\n> Use objectParent instead of vehicle to get a soldier's vehicle.\n> Apart from being faster it is also more reliable, as when used on dead crew, vehicle command may surprisingly return the unit itself.\n\n> [!NOTE]\n> Since Arma 3 v2.18 objectParent can return the creator of a weaponholder if the weaponholder was created through some user action.","syntaxes":[{"syntax":"objectParent object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_isOnFoot = isNull objectParent player;                            // check if the player is on foot\n_isCommander = player isEqualTo commander objectParent player;    // check if the player is in a vehicle and is its commander\n\n_holder = objectParent _myBackpack;                                // return:\n                                                                // - the weapon holder of a dropped backpack\n                                                                // - the cargo space of a vehicle holding this backpack\n                                                                // - the dead unit holding the backpack\n                                                                // works for a backpack, a vest or a uniform\n\n_isDeployed = isNull objectParent _deployableStaticMG;            // true if deployed, false if in a backpack\n\n_ropeParent = objectParent _ropeSegment;                        // since Arma 3 v2.12\n_creatorUnit = objectParent _weaponholder;                        // since Arma 3 v2.18\n```","code":["_isOnFoot = isNull objectParent player;\t\t\t\t\t\t\t// check if the player is on foot\n_isCommander = player isEqualTo commander objectParent player;\t// check if the player is in a vehicle and is its commander\n\n_holder = objectParent _myBackpack;\t\t\t\t\t\t\t\t// return:\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// - the weapon holder of a dropped backpack\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// - the cargo space of a vehicle holding this backpack\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// - the dead unit holding the backpack\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// works for a backpack, a vest or a uniform\n\n_isDeployed = isNull objectParent _deployableStaticMG;\t\t\t// true if deployed, false if in a backpack\n\n_ropeParent = objectParent _ropeSegment;\t\t\t\t\t\t// since Arma 3 v2.12\n_creatorUnit = objectParent _weaponholder;\t\t\t\t\t\t// since Arma 3 v2.18"]},{"text":"Create and place a created backpack in front of player:\n\n```sqf\n_backpackContainer = \"B_TacticalPack_rgr\" createVehicle [0, 0, 0];\n_weaponHolder = objectParent _backpackContainer;\n_weaponHolder setPosWorld (player modelToWorldWorld [0, 5, 0]);\n```","code":["_backpackContainer = \"B_TacticalPack_rgr\" createVehicle [0, 0, 0];\n_weaponHolder = objectParent _backpackContainer;\n_weaponHolder setPosWorld (player modelToWorldWorld [0, 5, 0]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack","vehicle","getCorpse"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"objNull","operator":null,"title":"objNull","type":"command","url":"https://community.bistudio.com/wiki/objNull","revid":379022,"updated":"2026-09-22T13:39:58Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existent Object. To compare non-existent objects use isNull or isEqualTo:\n\n```sqf\nobjNull == objNull;            // false\nobjNull != objNull;            // true\nisNull objNull;                // true\nobjNull isEqualTo objNull;    // true\ntypeName objNull;           // \"OBJECT\"\n```","syntaxes":[{"syntax":"objNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nplayer == player; // false if player is null\n```","code":["player == player; // false if player is null"]},{"text":"```sqf\nisNull player; // true if player is null\n```","code":["isNull player; // true if player is null"]},{"text":"```sqf\nstr objNull // <NULL-object>\n```","code":["str objNull // <NULL-object>"]},{"text":"```sqf\nposition objNull // [0,0,0]\n```","code":["position objNull // [0,0,0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","locationNull","taskNull","teamMemberNull","scriptNull","configNull","netObjNull","typeName","isNull"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"objStatus","operator":null,"title":"objStatus","type":"command","url":"https://community.bistudio.com/wiki/objStatus","revid":322935,"updated":"2022-06-28T21:42:43Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the status of an objective that was defined in briefing.html.\n\nStatus may be one of:\n- \"ACTIVE\"\n- \"FAILED\"\n- \"DONE\"\n- \"HIDDEN\"\n\nTo refer to an objective that is named \"OBJ_1\", for example, use only the index number in this command (i.e. \"1\" objStatus \"HIDDEN\").","syntaxes":[{"syntax":"objectivenumber objStatus status","since":null,"effect":null,"exec":null,"params":[{"name":"objectivenumber","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"objectivenumber: String"},{"name":"status","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"status: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"objectivenumber","types":["String"]},"right":{"text":"status","types":["String"]}}],"examples":[{"text":"```sqf\n\"1\" objStatus \"DONE\";\n```\n\nMarks the objective named \"OBJ_1\" as completed.","code":["\"1\" objStatus \"DONE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onBriefingGroup","operator":null,"title":"onBriefingGroup","type":"command","url":"https://community.bistudio.com/wiki/onBriefingGroup","revid":322956,"updated":"2022-06-28T21:42:49Z","groups":["Briefing","Sounds","Groups","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select a sound declared in the Description.ext of the mission to be played the first time the Group tab is selected in the briefing.","syntaxes":[{"syntax":"onBriefingGroup soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}}],"examples":[{"text":"```sqf\nonBriefingGroup \"GroupVoiceOver\";\n```","code":["onBriefingGroup \"GroupVoiceOver\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Description.ext"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Event Handlers","Command Group: Groups","Command Group: Sounds","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onBriefingNotes","operator":null,"title":"onBriefingNotes","type":"command","url":"https://community.bistudio.com/wiki/onBriefingNotes","revid":378135,"updated":"2026-02-24T13:54:13Z","groups":["Sounds","Briefing","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select a sound declared in the Description.ext of the mission to be played the first time the Notes tab is selected in the briefing.","syntaxes":[{"syntax":"onBriefingNotes soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}}],"examples":[{"text":"```sqf\nonBriefingNotes \"NotesVoiceOver\";\n```","code":["onBriefingNotes \"NotesVoiceOver\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playSound"],"notes":[{"user":"Bdfy","date":"2007-02-08T15:30:00Z","text":"In Operation Flashpoint it works only with the sound files defined in the mission's description.ext"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Event Handlers","Command Group: Sounds","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onBriefingPlan","operator":null,"title":"onBriefingPlan","type":"command","url":"https://community.bistudio.com/wiki/onBriefingPlan","revid":340972,"updated":"2023-05-13T22:02:54Z","groups":["Event Handlers","Sounds","Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select a sound declared in the Description.ext of the mission to be played the first time the Plan tab is selected in the briefing.","syntaxes":[{"syntax":"onBriefingPlan soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}}],"examples":[{"text":"```sqf\nonBriefingPlan \"PlanVoiceOver\";\n```","code":["onBriefingPlan \"PlanVoiceOver\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Description.ext"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Event Handlers","Command Group: Sounds","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onBriefingTeamSwitch","operator":null,"title":"onBriefingTeamSwitch","type":"command","url":"https://community.bistudio.com/wiki/onBriefingTeamSwitch","revid":319537,"updated":"2022-05-13T09:24:16Z","groups":["Briefing","Sounds","Team Switch","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select a sound defined in the CfgSounds of the mission to be played the first time the TeamSwitch tab is selected in the briefing.","syntaxes":[{"syntax":"onBriefingTeamSwitch soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}}],"examples":[{"text":"```sqf\nonBriefingTeamSwitch \"TeamSwitchVoiceOver\";\n```","code":["onBriefingTeamSwitch \"TeamSwitchVoiceOver\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableTeamSwitch","onTeamSwitch","teamSwitch","teamSwitchEnabled","Description.ext"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Event Handlers","Command Group: Sounds","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onCommandModeChanged","operator":null,"title":"onCommandModeChanged","type":"command","url":"https://community.bistudio.com/wiki/onCommandModeChanged","revid":369384,"updated":"2024-09-03T18:43:15Z","groups":["Event Handlers","High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines code performed when hc command mode changes either because of (Left Ctrl + Space) shortcut or hcShowBar scripting command. Groups hc mode must contain at least one group for this command to work (see High Command). Attached code receives *_isHighCommand* boolean.\n\n> [!NOTE]\n> Since **Arma 3** *v1.57* a stackable version of this EH is available: CommandModeChanged","syntaxes":[{"syntax":"onCommandModeChanged code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code or String","optional":false,"default":null,"description":null,"types":["Code","String"],"since":null,"text":"code: Code or String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code","String"]}}],"examples":[{"text":"```sqf\n//Examples in-use can be found in:\n\n//ca\\modules\\HC\\data\\scripts\\HC_GUI.sqf\n//A3\\modules_f\\HC\\data\\scripts\\HC_GUI.sqf\n```","code":["//Examples in-use can be found in:\n\n//ca\\modules\\HC\\data\\scripts\\HC_GUI.sqf\n//A3\\modules_f\\HC\\data\\scripts\\HC_GUI.sqf"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onHCGroupSelectionChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onDoubleClick","operator":null,"title":"onDoubleClick","type":"command","url":"https://community.bistudio.com/wiki/onDoubleClick","revid":363235,"updated":"2024-03-26T10:51:11Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when the user double clicks on the map. Command receives:,_pos array position,_units array selected units,_shift,_alt bool key state\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map onDoubleClick command","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onMapSingleClick"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onEachFrame","operator":null,"title":"onEachFrame","type":"command","url":"https://community.bistudio.com/wiki/onEachFrame","revid":369525,"updated":"2024-09-15T18:15:30Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Runs given statement every frame in an unscheduled environment.\n\n> [!NOTE]\n> **Arma 3:** In order to keep compatibility between official and community content:\n> - Since Arma 3 v1.58 a stackable version of this EH is available: EachFrame Mission Event Handler\n> - Before that, the scripted version of the event handler should be used instead (using BIS_fnc_addStackedEventHandler and BIS_fnc_removeStackedEventHandler).","syntaxes":[{"syntax":"onEachFrame statement","since":null,"effect":null,"exec":null,"params":[{"name":"statement","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"statement: String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"statement","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonEachFrame { hintSilent str getPosWorld player }; // hints position every frame\n```","code":["onEachFrame { hintSilent str getPosWorld player }; // hints position every frame"]},{"text":"Private variables defined outside of the onEachFrame scope are not inherited:\n\n```sqf\n_myVar = \"bob\";\nMyVar = \"bill\";\nonEachFrame { hintSilent str [_myVar, MyVar]; };\n// Result: [any, \"bill\"]\n```","code":["_myVar = \"bob\";\nMyVar = \"bill\";\nonEachFrame { hintSilent str [_myVar, MyVar]; };\n// Result: [any, \"bill\"]"]},{"text":"Only one onEachFrame loop can exist at any time:\n\n```sqf\nonEachFrame { player sideChat \"first\"; };\nonEachFrame { player sideChat \"second\"; };    // replaces the first one\nonEachFrame {};                                // reset to the initial state\n```","code":["onEachFrame { player sideChat \"first\"; };\nonEachFrame { player sideChat \"second\"; };\t// replaces the first one\nonEachFrame {};\t\t\t\t\t\t\t\t// reset to the initial state"]},{"text":"Script suspension is not permitted within onEachFrame scope:\n\n```sqf\n// will throw an error\nonEachFrame { sleep 1; };\n```","code":["// will throw an error\nonEachFrame { sleep 1; };"]},{"text":"```sqf\nonEachFrame { if (diag_frameNo mod 60 isEqualTo 0) then { /* code */ } };    // executes every 60 frames (every second @ 60 FPS, every two seconds @ 30 FPS, etc)\n\nonEachFrame {                                                                // this version is the closest to a precise 1 second tick\n    if (isNil \"TAG_LastHint\") then\n    {\n        TAG_LastHint = diag_tickTime;\n    }\n    else\n    {\n        if (diag_tickTime - TAG_LastHint >= 1) then // set the duration in seconds here\n        {\n            hint format [\"a second has passed (%1s since game start)\", diag_tickTime];\n            TAG_LastHint = diag_tickTime;\n        };\n    };\n};\n```","code":["onEachFrame { if (diag_frameNo mod 60 isEqualTo 0) then { /* code */ } };\t// executes every 60 frames (every second @ 60 FPS, every two seconds @ 30 FPS, etc)\n\nonEachFrame {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// this version is the closest to a precise 1 second tick\n\tif (isNil \"TAG_LastHint\") then\n\t{\n\t\tTAG_LastHint = diag_tickTime;\n\t}\n\telse\n\t{\n\t\tif (diag_tickTime - TAG_LastHint >= 1) then // set the duration in seconds here\n\t\t{\n\t\t\thint format [\"a second has passed (%1s since game start)\", diag_tickTime];\n\t\t\tTAG_LastHint = diag_tickTime;\n\t\t};\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_frameNo","diag_fps"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 2: Operation Arrowhead version 1.63","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onGroupIconClick","operator":null,"title":"onGroupIconClick","type":"command","url":"https://community.bistudio.com/wiki/onGroupIconClick","revid":321243,"updated":"2022-05-13T18:19:21Z","groups":["High Command","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when player clicked on group marker (3D or in a map). The code executed once.\nThis EH, unlike onGroupIconOverEnter and onGroupIconOverLeave, has one more param which returns 1 if RMB was pressed, 0 otherwise.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.58 a Mission Event Handler exists and should be used.","syntaxes":[{"syntax":"onGroupIconClick command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":"script","types":["String","Code"],"since":null,"text":"command: String or Code - script"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonGroupIconClick\n{\n    // passed values for _this are:\n    params [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n    // before Arma 3\n    _is3D = _this select 0;\n    _group = _this select 1;\n    _wpID = _this select 2;\n    _RMB = _this select 3;\n    _posx = _this select 4;\n    _posy = _this select 5;\n    _shift = _this select 6;\n    _ctrl = _this select 7;\n    _alt = _this select 8;\n\n    _message = format [\"____ Info ____\"];\n    {_message = _message + format [\"\\n %1\", _x]} forEach _this;\n    hint _message;\n};\n```","code":["onGroupIconClick\n{\n\t// passed values for _this are:\n\tparams [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n\t// before Arma 3\n\t_is3D = _this select 0;\n\t_group = _this select 1;\n\t_wpID = _this select 2;\n\t_RMB = _this select 3;\n\t_posx = _this select 4;\n\t_posy = _this select 5;\n\t_shift = _this select 6;\n\t_ctrl = _this select 7;\n\t_alt = _this select 8;\n\n\t_message = format [\"____ Info ____\"];\n\t{_message = _message + format [\"\\n %1\", _x]} forEach _this;\n\thint _message;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible","onGroupIconOverEnter","onGroupIconOverLeave"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onGroupIconOverEnter","operator":null,"title":"onGroupIconOverEnter","type":"command","url":"https://community.bistudio.com/wiki/onGroupIconOverEnter","revid":369394,"updated":"2024-09-03T18:43:18Z","groups":["High Command","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when player moves pointer over group marker (3D or in a map). The code will execute continuously while pointer is over icon.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.58 a Mission Event Handler exists and should be used.","syntaxes":[{"syntax":"onGroupIconOverEnter command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"command:  String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonGroupIconOverEnter\n{\n    // passed values for _this are:\n    params [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n    // before Arma 3\n    _is3D = _this select 0;\n    _group = _this select 1;\n    _wpID = _this select 2;\n    _posx = _this select 3;\n    _posy = _this select 4;\n    _shift = _this select 5;\n    _ctrl = _this select 6;\n    _alt = _this select 7;\n\n    _message = format [\"____ Info ____\"];\n    {_message = _message + format [\"\\n %1\",_x]} forEach _this;\n    hint _message;\n};\n```","code":["onGroupIconOverEnter\n{\n\t// passed values for _this are:\n\tparams [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n\t// before Arma 3\n\t_is3D = _this select 0;\n\t_group = _this select 1;\n\t_wpID = _this select 2;\n\t_posx = _this select 3;\n\t_posy = _this select 4;\n\t_shift = _this select 5;\n\t_ctrl = _this select 6;\n\t_alt = _this select 7;\n\n\t_message = format [\"____ Info ____\"];\n\t{_message = _message + format [\"\\n %1\",_x]} forEach _this;\n\thint _message;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onGroupIconClick","onGroupIconOverLeave","groupIconSelectable","setGroupIconsSelectable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onGroupIconOverLeave","operator":null,"title":"onGroupIconOverLeave","type":"command","url":"https://community.bistudio.com/wiki/onGroupIconOverLeave","revid":369294,"updated":"2024-09-03T18:42:50Z","groups":["High Command","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when pointer, previously positioned over icon, is moved away from it (3D or in a map). The code is executed once.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.58 a Mission Event Handler exists and should be used.","syntaxes":[{"syntax":"onGroupIconOverLeave command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"command: String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonGroupIconOverLeave\n{\n    // passed values for _this are:\n    params [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n    // before Arma 3\n    _is3D = _this select 0;\n    _group = _this select 1;\n    _wpID = _this select 2;\n    _posx = _this select 3;\n    _posy = _this select 4;\n    _shift = _this select 5;\n    _ctrl = _this select 6;\n    _alt = _this select 7;\n\n    _message = format [\"____ Info ____\"];\n    { _message = _message + format [\"\\n %1\",_x] } forEach _this;\n    hint _message;\n};\n```","code":["onGroupIconOverLeave\n{\n\t// passed values for _this are:\n\tparams [\"_is3D\", \"_group\", \"_wpID\", \"_posX\", \"_posY\", \"_shift\", \"_ctrl\", \"_alt\"];\n\n\t// before Arma 3\n\t_is3D = _this select 0;\n\t_group = _this select 1;\n\t_wpID = _this select 2;\n\t_posx = _this select 3;\n\t_posy = _this select 4;\n\t_shift = _this select 5;\n\t_ctrl = _this select 6;\n\t_alt = _this select 7;\n\n\t_message = format [\"____ Info ____\"];\n\t{ _message = _message + format [\"\\n %1\",_x] } forEach _this;\n\thint _message;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onGroupIconClick","onGroupIconOverEnter","groupIconSelectable","setGroupIconsSelectable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onHCGroupSelectionChanged","operator":null,"title":"onHCGroupSelectionChanged","type":"command","url":"https://community.bistudio.com/wiki/onHCGroupSelectionChanged","revid":369345,"updated":"2024-09-03T18:43:02Z","groups":["High Command","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when high command group selection has been changed.\n\nCommand receives 2 variables:\n- _group: Group - last selected/deselected group\n- _isSelected: Boolean - new selection state of the specific group\nThe code is executed on every hc group selection change until it is replaced or removed (see #Example 3).\n\n> [!IMPORTANT]\n> Using the command again will **overwrite** the previously set code.\n\n> [!NOTE]\n> Since Arma 3 v1.58 a stackable version of this EH is available: HCGroupSelectionChanged","syntaxes":[{"syntax":"onHCGroupSelectionChanged code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"code: String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonHCGroupSelectionChanged {\n    if (_isSelected) then\n    {\n        hint format [\"Group %1 has been selected.\", _group];\n    }\n    else\n    {\n        hint format [\"Group %1 has been deselected.\", _group];\n    };\n};\n```","code":["onHCGroupSelectionChanged {\n\tif (_isSelected) then\n\t{\n\t\thint format [\"Group %1 has been selected.\", _group];\n\t}\n\telse\n\t{\n\t\thint format [\"Group %1 has been deselected.\", _group];\n\t};\n};"]},{"text":"```sqf\nonHCGroupSelectionChanged \"player globalChat 'HC group selection has been changed.';\";\n```","code":["onHCGroupSelectionChanged \"player globalChat 'HC group selection has been changed.';\";"]},{"text":"Remove event handler:\n\n```sqf\nonHCGroupSelectionChanged \"\";\n// or\nonHCGroupSelectionChanged {};\n```","code":["onHCGroupSelectionChanged \"\";\n// or\nonHCGroupSelectionChanged {};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["High Command","hcAllGroups","hcGroupParams","hcLeader","hcRemoveAllGroups","hcRemoveGroup","hcSelected","hcSelectGroup","hcSetGroup","hcShowBar","hcShownBar","onCommandModeChanged"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onMapSingleClick","operator":null,"title":"onMapSingleClick","type":"command","url":"https://community.bistudio.com/wiki/onMapSingleClick","revid":377823,"updated":"2026-01-03T04:21:02Z","groups":["Map","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines the action performed when user clicks in map by executing command string. The code is executed on every click, until the **command** is\n- removed via `onMapSingleClick \"\"`, or\n- replaced by `onMapSingleClick \"SomeOtherCommand(s)\"`\n\nIn Arma 3 the code should return true only if you wish to override default engine handling of the mouse click on map (see #Example 4).\n\nFor older games, when click is processed, code should ultimately return true back to the engine. If false is returned, default processing by the game engine is done.\nReturn value of any other type (including Nothing) is an error. In such case default processing by the game engine is done, and error message may be displayed.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.58 the stackable MapSingleClick Mission Event Handler is available and should be used instead.","syntaxes":[{"syntax":"onMapSingleClick command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":"code executed on click. The following variables are available:\n- _pos: Position2D - clicked position\n- _units: Array of Objects - units which were selected (via function keys) **before** opening the map (*may be non-functional in Arma*)\n- _shift: Boolean - Whether <kbd>Shift</kbd> was pressed when clicking on the map\n- _alt: Boolean - Whether <kbd>Alt</kbd> was pressed when clicking on the map","types":["String","Code"],"since":null,"text":"command: String or Code - code executed on click. The following variables are available:\n- _pos: Position2D - clicked position\n- _units: Array of Objects - units which were selected (via function keys) **before** opening the map (*may be non-functional in Arma*)\n- _shift: Boolean - Whether <kbd>Shift</kbd> was pressed when clicking on the map\n- _alt: Boolean - Whether <kbd>Alt</kbd> was pressed when clicking on the map"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}},{"syntax":"params onMapSingleClick command","since":null,"effect":null,"exec":null,"params":[{"name":"params","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"params: Anything"},{"name":"command","type":"String or Code","optional":false,"default":null,"description":"code executed on click. The following variables are available:\n- _this: Anything - Params passed to onMapSingleClick\n- _pos: Position2D - clicked position\n- _units: Array of Objects - units which were selected (via function keys) **before** opening the map (*may be non-functional in Arma*)\n- _shift: Boolean - Whether <kbd>Shift</kbd> was pressed when clicking on the map\n- _alt: Boolean - Whether <kbd>Alt</kbd> was pressed when clicking on the map","types":["String","Code"],"since":null,"text":"command: String or Code - code executed on click. The following variables are available:\n- _this: Anything - Params passed to onMapSingleClick\n- _pos: Position2D - clicked position\n- _units: Array of Objects - units which were selected (via function keys) **before** opening the map (*may be non-functional in Arma*)\n- _shift: Boolean - Whether <kbd>Shift</kbd> was pressed when clicking on the map\n- _alt: Boolean - Whether <kbd>Alt</kbd> was pressed when clicking on the map"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"params","types":["Anything"]},"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"**Armed Assault:** Creates a soldier unit at the position clicked:\n\n```sqf\nonMapSingleClick \"'SoldierWB' createUnit [_pos, group player]; true\";\n```","code":["onMapSingleClick \"'SoldierWB' createUnit [_pos, group player]; true\";"]},{"text":"**Armed Assault:** Orders \"grp1\" to move to position clicked. Disables further map-click actions:\n\n```sqf\nonMapSingleClick \"grp1 move _pos; onMapSingleClick ''; true\";\n```","code":["onMapSingleClick \"grp1 move _pos; onMapSingleClick ''; true\";"]},{"text":"**Operation Flashpoint:** Single quotes cannot be used for string definition, so two double-quotes have to be used instead:\n\n```sqf\nonMapSingleClick \"'SoldierWB' createUnit [_pos, group player]; true\";\n```","code":["onMapSingleClick \"'SoldierWB' createUnit [_pos, group player]; true\";"]},{"text":"```sqf\n// The following code will disable Shift+click waypoint marker creation\nonMapSingleClick {_shift};\n```","code":["// The following code will disable Shift+click waypoint marker creation\nonMapSingleClick {_shift};"]},{"text":"```sqf\n// Pass params to onMapSingleClick code\nplayer onMapSingleClick { hint (\"Hello \" + name _this) }; // Hello KK\n```","code":["// Pass params to onMapSingleClick code\nplayer onMapSingleClick { hint (\"Hello \" + name _this) }; // Hello KK"]},{"text":"```sqf\n// Pass params to onMapSingleClick code -and- disable Shift+click waypoint marker creation\n player onMapSingleClick \"hint (\"\"Hello \"\" + name _this); _shift\"; // Hello KK\n```","code":["// Pass params to onMapSingleClick code -and- disable Shift+click waypoint marker creation\n player onMapSingleClick \"hint (\"\"Hello \"\" + name _this); _shift\"; // Hello KK"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onGroupIconClick"],"notes":[{"user":"General Barron","date":"2009-07-08T02:25:00Z","text":"See my [Multiple OnMapSingleClick](http://www.ofpec.com/editors-depot/index.php?action=details&id=292&game=ArmA) script to allow you to add multiple events to the onMapSingleClick event. Some minor editing of the scripts would be required to use them in Arma."},{"user":"Killzone_Kid","date":"2016-04-01T00:25:00Z","text":"`_units` param is supposed to return what groupSelectedUnits returns. Player must be leader and some units in the group must be selected on the group bar. However selected units are connected with group orders menu, which interferes with map click. In other words, when you click on the main map, the map gets focus and group orders menu closes, deselecting any selected unit, so `_units` is [] pretty much all the time."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Map","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onPlayerConnected","operator":null,"title":"onPlayerConnected","type":"command","url":"https://community.bistudio.com/wiki/onPlayerConnected","revid":369528,"updated":"2024-09-15T18:22:20Z","groups":["Multiplayer","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"This command will execute the provided code on the server whenever a player connects to a multiplayer session.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.58 a stackable MissionEventHandler is available and should be used: PlayerConnected.\n> Before that, the functions BIS_fnc_addStackedEventHandler and BIS_fnc_removeStackedEventHandler should be used instead in order to keep compatibility between official and community content.","syntaxes":[{"syntax":"onPlayerConnected code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"String or Code","optional":false,"default":null,"description":"has access to the following variables:\n- **_id**: Number - is the unique DirectPlay ID. Quite useless as the number is too big for in-built string representation and gets rounded. It is also the same id used for user placed markers.\n- **_uid**: String - is getPlayerUID of the joining player. In Arma 3 it is also the same as Steam ID.\n- **_name**: String - is profileName of the joining player.\n- Arma 3 v1.50 **_jip**: Boolean - is a flag that indicates whether or not the player joined after the mission has started (**J**oined **I**n **P**rogress). true when the player is JIP, otherwise false.\n- Arma 3 v1.50 **_owner**: Number - is owner id of the joining player. Can be used for kick or ban purposes or just for publicVariableClient.\n- Arma 3 v1.96 **_idstr**: String - same as `_id` but in string format, so could be exactly compared to user marker ids.","types":["String","Code"],"since":null,"text":"code: String or Code - has access to the following variables:\n- **_id**: Number - is the unique DirectPlay ID. Quite useless as the number is too big for in-built string representation and gets rounded. It is also the same id used for user placed markers.\n- **_uid**: String - is getPlayerUID of the joining player. In Arma 3 it is also the same as Steam ID.\n- **_name**: String - is profileName of the joining player.\n- Arma 3 v1.50 **_jip**: Boolean - is a flag that indicates whether or not the player joined after the mission has started (**J**oined **I**n **P**rogress). true when the player is JIP, otherwise false.\n- Arma 3 v1.50 **_owner**: Number - is owner id of the joining player. Can be used for kick or ban purposes or just for publicVariableClient.\n- Arma 3 v1.96 **_idstr**: String - same as `_id` but in string format, so could be exactly compared to user marker ids."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonPlayerConnected \"[_id, _name] execVM 'PlayerConnected.sqf';\";\n```","code":["onPlayerConnected \"[_id, _name] execVM 'PlayerConnected.sqf';\";"]},{"text":"```sqf\nonPlayerConnected { diag_log [_id, _uid, _name] };\n```","code":["onPlayerConnected { diag_log [_id, _uid, _name] };"]},{"text":"From Arma 3 v1.49:\n\n```sqf\nonPlayerConnected {\n    somevar = random 123;\n    _owner publicVariableClient \"somevar\";\n    // this will define \"somevar\" to a random value on the joining machine\n};\n```","code":["onPlayerConnected {\n\tsomevar = random 123;\n\t_owner publicVariableClient \"somevar\";\n\t// this will define \"somevar\" to a random value on the joining machine\n};"]}],"multiplayer":"> [!IMPORTANT]\n> A player with the **_name** `__SERVER__` will also connect to a multiplayer game, executing *code*.","problems":null,"aliases":[],"see_also":["onPlayerDisconnected","didJIP","didJIPOwner"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Multiplayer","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"onPlayerDisconnected","operator":null,"title":"onPlayerDisconnected","type":"command","url":"https://community.bistudio.com/wiki/onPlayerDisconnected","revid":369204,"updated":"2024-09-03T10:34:50Z","groups":["Multiplayer","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"This command will execute attached code whenever a player is leaving an MP session. The code will receive a number of special variables:","syntaxes":[{"syntax":"onPlayerDisconnected code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"String or Code","optional":false,"default":null,"description":"code executed. The code will receive a number of special variables:\n- _id: Number - Is the unique DirectPlay ID. Quite useless as the number is too big for in-built string representation and gets rounded. It is also the same id used for user placed markers.\n- _uid: String - Is getPlayerUID of the leaving player. In Arma 3 it is also the same as Steam ID.\n- _name: String - Is profileName of the leaving player.\n- Arma 3 v1.50 _jip: Boolean - Is a flag that indicated whether or not the player joined after the mission has started (**J**oined **I**n **P**rogress). true - if the player was JIP, otherwise false.\n- Arma 3 v1.50 _owner: Number - Is owner id of the leaving player. Can be used for kick or ban purposes or just for publicVariableClient.\n- Arma 3 v1.96 _idstr:  String - Same as `_id` but in string format, so could be exactly compared to user marker ids.","types":["String","Code"],"since":null,"text":"code: String or Code - code executed. The code will receive a number of special variables:\n- _id: Number - Is the unique DirectPlay ID. Quite useless as the number is too big for in-built string representation and gets rounded. It is also the same id used for user placed markers.\n- _uid: String - Is getPlayerUID of the leaving player. In Arma 3 it is also the same as Steam ID.\n- _name: String - Is profileName of the leaving player.\n- Arma 3 v1.50 _jip: Boolean - Is a flag that indicated whether or not the player joined after the mission has started (**J**oined **I**n **P**rogress). true - if the player was JIP, otherwise false.\n- Arma 3 v1.50 _owner: Number - Is owner id of the leaving player. Can be used for kick or ban purposes or just for publicVariableClient.\n- Arma 3 v1.96 _idstr:  String - Same as `_id` but in string format, so could be exactly compared to user marker ids."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonPlayerDisconnected {diag_log [_id, _uid, _name]};\n```","code":["onPlayerDisconnected {diag_log [_id, _uid, _name]};"]},{"text":"```sqf\nonPlayerDisconnected {\n    if (count allPlayers == 0) then {\n        endMission \"END1\";\n    };\n};\n```","code":["onPlayerDisconnected {\n\tif (count allPlayers == 0) then {\n\t\tendMission \"END1\";\n\t};\n};"]}],"multiplayer":"In multiplayer onPlayerDisconnected is executed only on the server.\n\n> [!NOTE]\n> **Arma 3:** Use playerDisconnected or HandleDisconnect instead in Arma 3.","problems":null,"aliases":[],"see_also":["onPlayerConnected","didJIP","didJIPOwner","Arma 3: Mission Event Handlers"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Multiplayer","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"onPreloadFinished","operator":null,"title":"onPreloadFinished","type":"command","url":"https://community.bistudio.com/wiki/onPreloadFinished","revid":369526,"updated":"2024-09-15T18:15:31Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed after the preload screen finished. Preload event occurs after briefing screen on mission start.\n\n> [!IMPORTANT]\n> This event handler also fires on client after user closes the main map.\n\n> [!NOTE]\n> **Arma 3:** - Since Arma 3 v1.58 a stackable version of this EH is available: PreloadFinished\n> - Before that, the BIS_fnc_addStackedEventHandler and BIS_fnc_removeStackedEventHandler functions should be used instead.","syntaxes":[{"syntax":"onPreloadFinished command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"command: String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonPreloadFinished {TAG_ReceivingScreenDone = true};\n```","code":["onPreloadFinished {TAG_ReceivingScreenDone = true};"]},{"text":"```sqf\n// removes the event immediately after the first run again\nonPreloadFinished { TAG_ReceivingScreenDone = true; onPreloadFinished \"\" };\n```","code":["// removes the event immediately after the first run again\nonPreloadFinished { TAG_ReceivingScreenDone = true; onPreloadFinished \"\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onPreloadStarted"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onPreloadStarted","operator":null,"title":"onPreloadStarted","type":"command","url":"https://community.bistudio.com/wiki/onPreloadStarted","revid":352159,"updated":"2024-02-01T23:25:23Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed just before the preload screen started. Preload event occurs after briefing screen on mission start.\n\n> [!IMPORTANT]\n> This event handler also fires on client after user closes the main map.\n\n> [!NOTE]\n> Since **Arma 3** *v1.57* a stackable version of this EH is available: PreloadStarted\n\n> [!NOTE]\n> **Arma 3:** In order to keep compatibility between official and community content the functions BIS_fnc_addStackedEventHandler and BIS_fnc_removeStackedEventHandler should be used instead.","syntaxes":[{"syntax":"onPreloadStarted command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"command: String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonPreloadStarted {diag_log \"preload started\"};\n```","code":["onPreloadStarted {diag_log \"preload started\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["onPreloadFinished"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onShowNewObject","operator":null,"title":"onShowNewObject","type":"command","url":"https://community.bistudio.com/wiki/onShowNewObject","revid":363234,"updated":"2024-03-26T10:51:09Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when the user right clicks on the map and,selects New Object. Set to empty for default behavior. Command receives:,_pos array position,\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map onShowNewObject command","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"onTeamSwitch","operator":null,"title":"onTeamSwitch","type":"command","url":"https://community.bistudio.com/wiki/onTeamSwitch","revid":353308,"updated":"2024-03-15T17:11:45Z","groups":["Team Switch","Event Handlers"],"status":"deprecated","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines an action performed when the team switch is finished.\nCommandset receives the following special variables: *_from* object previous unit, *_to* object current unit.\nConsecutive use of onTeamSwitch command will overwrite previously set commandset.\n\n> [!IMPORTANT]\n> This command is deprecated. Since **Arma 3** *v1.57* a stackable version of this EH is available: TeamSwitch\n\n> [!NOTE]\n> When player switches and leaves behind AI unit, you need to enable \"TeamSwitch\" AI on it (with `onTeamSwitch { _from enableAI \"TeamSwitch\" };`) so that the unit continues with waypoints.","syntaxes":[{"syntax":"onTeamSwitch commandset","since":null,"effect":null,"exec":null,"params":[{"name":"commandset","type":"String or Code","optional":false,"default":null,"description":null,"types":["String","Code"],"since":null,"text":"commandset:  String or Code"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"commandset","types":["String","Code"]}}],"examples":[{"text":"```sqf\nonTeamSwitch { [_from, _to] execVM \"myTeamSwitchScript.sqf\"; };\n```","code":["onTeamSwitch { [_from, _to] execVM \"myTeamSwitchScript.sqf\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Team Switch","enableTeamSwitch","onBriefingTeamSwitch","teamSwitch","teamSwitchEnabled"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Team Switch","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"openCuratorInterface","operator":null,"title":"openCuratorInterface","type":"command","url":"https://community.bistudio.com/wiki/openCuratorInterface","revid":321434,"updated":"2022-05-14T14:17:08Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Force opens curator interface.","syntaxes":[{"syntax":"openCuratorInterface","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Open interface:\n\n```sqf\nopenCuratorInterface;\n```","code":["openCuratorInterface;"]},{"text":"Close interface:\n\n```sqf\nfindDisplay 312 closeDisplay 2;\n```","code":["findDisplay 312 closeDisplay 2;"]},{"text":"Detect if user used \"Zeus\" key to open curator interface in the absence of event handler for it:\n\n```sqf\nfindDisplay 46 displayAddEventHandler [\"KeyDown\", {\n    if (inputAction \"CuratorInterface\" > 0) then\n    {\n        hint \"Curator interface is open\";\n    };\n    false\n}];\n```","code":["findDisplay 46 displayAddEventHandler [\"KeyDown\", {\n\tif (inputAction \"CuratorInterface\" > 0) then\n\t{\n\t\thint \"Curator interface is open\";\n\t};\n\tfalse\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"openDLCPage","operator":null,"title":"openDLCPage","type":"command","url":"https://community.bistudio.com/wiki/openDLCPage","revid":286224,"updated":"2021-06-21T20:52:06Z","groups":["DLC"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens a Steam page of the app with given appId. Only works for known appId (game + linked DLCs)","syntaxes":[{"syntax":"openDLCPage dlcID","since":null,"effect":null,"exec":null,"params":[{"name":"dlcID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"dlcID: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"result","text":"Boolean - result"},"form":"unary","operator":null,"left":null,"right":{"text":"dlcID","types":["Number"]}}],"examples":[{"text":"openDLCPage 288520","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isDLCAvailable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: DLC","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"openGPS","operator":null,"title":"openGPS","type":"command","url":"https://community.bistudio.com/wiki/openGPS","revid":310316,"updated":"2022-05-05T16:28:36Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens or closes minimap if player has `\"ItemGPS\"` linked in inventory and `\"MinimapDisplayComponent\"` is not disabled with enableInfoPanelComponent. Returns true on success. If more than one minimap is open (see infoPanels, infoPanel) each call to the command will close only 1 minimap. Visibility of minimap can be checked with visibleGPS command.","syntaxes":[{"syntax":"openGPS open","since":null,"effect":null,"exec":null,"params":[{"name":"open","type":"Boolean","optional":false,"default":null,"description":"true to open, false to close","types":["Boolean"],"since":null,"text":"open: Boolean - true to open, false to close"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"unary","operator":null,"left":null,"right":{"text":"open","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer linkItem \"ItemGPS\";\nprivate _success = openGPS true;\n```","code":["player linkItem \"ItemGPS\";\nprivate _success = openGPS true;"]},{"text":"To close all opened minimaps:\n\n```sqf\nwhile { openGPS false } do { };\n// or\nwhile { visibleGPS } do { openGPS false };\n```","code":["while { openGPS false } do { };\n// or\nwhile { visibleGPS } do { openGPS false };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showGPS","shownGPS","visibleGPS"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"openMap","operator":null,"title":"openMap","type":"command","url":"https://community.bistudio.com/wiki/openMap","revid":349654,"updated":"2023-11-18T17:02:30Z","groups":["Map","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.03"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.03"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Opens or closes in-game map.\n\n> [!WARNING]\n> If `forced` param is set to true and map is set to open, when the map is opened it cannot be closed manually and the user can get stuck requiring the game restart.\n> Make sure you provide scripted mechanics to resolve this, should you need to force the map.\n> Useful when you wish to keep user for example on respawn screen, where they could still interact with the map but cannot enter the game until the time is up.","syntaxes":[{"syntax":"openMap show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":"if true opens map, if false closes map, provided it is not *forced*","types":["Boolean"],"since":null,"text":"show: Boolean - if true opens map, if false closes map, provided it is not *forced*"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"equivalent of visibleMap","text":"Boolean - equivalent of visibleMap"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}},{"syntax":"openMap [show, forced]","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":"if true opens map, if false closes map, provided it is not *forced*.","types":["Boolean"],"since":null,"text":"show: Boolean - if true opens map, if false closes map, provided it is not *forced*."},{"name":"forced","type":"Boolean","optional":false,"default":null,"description":"if true keeps map from closing when map is open. Arma 3 v2.06 if false, forces map to stay closed if *show* is false (see #Example 1)","types":["Boolean"],"since":null,"text":"forced: Boolean - if true keeps map from closing when map is open. Arma 3 v2.06 if false, forces map to stay closed if *show* is false (see #Example 1)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"equivalent of visibleMap","text":"Boolean - equivalent of visibleMap"},"form":"unary","operator":null,"left":null,"right":{"text":"[show, forced]","types":["Array"]}}],"examples":[{"text":"```sqf\nopenMap [true, false];    // opens map normally\nopenMap [false, false];    // closes an opened map normally\nopenMap [true, true];    // force opens map and keeps it open (the user cannot close it on their own)\nopenMap [false, true];    // since Arma 3 2.06: prevents map from opening, closes open map and forces it to stay close (the user cannot open it on their own)\n```","code":["openMap [true, false];\t// opens map normally\nopenMap [false, false];\t// closes an opened map normally\nopenMap [true, true];\t// force opens map and keeps it open (the user cannot close it on their own)\nopenMap [false, true];\t// since Arma 3 2.06: prevents map from opening, closes open map and forces it to stay close (the user cannot open it on their own)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceMap","forcedMap","visibleMap","showMap","shownMap"],"notes":[{"user":"Fraali","date":"2021-12-08T11:00:58Z","text":"(**As of Arma 3 ver.2.06.148470**)\n\nTrying to close a map using `openMap false` inside of a map event handler like\n\n```sqf\naddMissionEventHandler [\"Map\", { openMap false }];\n```\n\nwill cause the game to crash.\n\nTo fix this, please use it inside of a spawned script.\n\n```sqf\naddMissionEventHandler [\"Map\", { 0 spawn { openMap false }; }];\n```\n\nThis should stop any issue of crashing when you close the map."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Map","Introduced with Arma 2 version 1.03","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"openSteamApp","operator":null,"title":"openSteamApp","type":"command","url":"https://community.bistudio.com/wiki/openSteamApp","revid":309224,"updated":"2022-05-04T10:07:21Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens a Steam application, returns false if it was not possible to run the application.","syntaxes":[{"syntax":"openSteamApp appID","since":null,"effect":null,"exec":null,"params":[{"name":"appID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"appID: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"appID","types":["Number"]}}],"examples":[{"text":"```sqf\nopenSteamApp 553228;\n```","code":["openSteamApp 553228;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSteamFriendsServers","openYoutubeVideo"],"notes":[{"user":".kju","date":"2018-08-02T14:26:00Z","text":"It seems like it was limited to bohemia stuff. Like launching 'Arma 3 Community Guide Series: Zeus DLC'."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.78","Scripting Commands"]},{"name":"openYoutubeVideo","operator":null,"title":"openYoutubeVideo","type":"command","url":"https://community.bistudio.com/wiki/openYoutubeVideo","revid":339601,"updated":"2023-04-28T14:11:50Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens Steam overlay with given YT video. Video URL is the end part of the YT URL, starting with **watch?v=...**. If the user has Steam overlay disabled, the command will display appropriate message to the user and return false.","syntaxes":[{"syntax":"openYoutubeVideo youTubeUrl","since":null,"effect":null,"exec":null,"params":[{"name":"youTubeUrl","type":"String","optional":false,"default":null,"description":"for parameters see: https://developers.google.com/youtube/player_parameters","types":["String"],"since":null,"text":"youTubeUrl: String - for parameters see: https://developers.google.com/youtube/player_parameters"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"youTubeUrl","types":["String"]}}],"examples":[{"text":"```sqf\n// open http://www.youtube.com/watch?v=UBIAbm7Rt78\n_isOpened = openYoutubeVideo \"watch?v=UBIAbm7Rt78\";\n```","code":["// open http://www.youtube.com/watch?v=UBIAbm7Rt78\n_isOpened = openYoutubeVideo \"watch?v=UBIAbm7Rt78\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["openDSInterface","openMap"],"notes":[{"user":"celoush","date":"2018-05-25T15:03:00Z","text":"[SITREP 00061](https://dev.arma3.com/post/sitrep-00061): For security reasons we have restricted its use to outside scenarios only (e.g. in the game's UI or a mod's UI)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"opfor","operator":null,"title":"opfor","type":"command","url":"https://community.bistudio.com/wiki/opfor","revid":369180,"updated":"2024-09-03T10:34:45Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the opfor side.","syntaxes":[{"syntax":"opfor","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side player == opfor) then\n{\n    hint \"OPFOR\";\n};\n```","code":["if (side player == opfor) then\n{\n\thint \"OPFOR\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["east"],"see_also":["side","civilian","blufor","east","independent","resistance","west"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"or","operator":null,"title":"or","type":"command","url":"https://community.bistudio.com/wiki/or","revid":369315,"updated":"2024-09-03T18:42:56Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if one or both conditions are true. In case of the alternative syntax, [lazy evaluation](https://en.wikipedia.org/wiki/Lazy_evaluation#Control_structures) is used. That means that if left operand is true, evaluation of the right side is skipped completely.","syntaxes":[{"syntax":"a or b","since":null,"effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"b: Boolean - test condition or variable"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Boolean"]}},{"syntax":"a or b","since":"arma2oa 1.62","effect":null,"exec":null,"params":[{"name":"a","type":"Boolean","optional":false,"default":null,"description":"test condition or variable","types":["Boolean"],"since":null,"text":"a: Boolean - test condition or variable"},{"name":"b","type":"Code","optional":false,"default":null,"description":"code that returns Boolean. It is not evaluated if *a* returns true","types":["Code"],"since":null,"text":"b: Code - code that returns Boolean. It is not evaluated if *a* returns true"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"a","types":["Boolean"]},"right":{"text":"b","types":["Code"]}}],"examples":[{"text":"```sqf\nif (_obj1 or (_enemycount == 0) or (not alive _enemyGeneral)) then { hint \"you win !\"; };\n```","code":["if (_obj1 or (_enemycount == 0) or (not alive _enemyGeneral)) then { hint \"you win !\"; };"]},{"text":"```sqf\n// without lazy evaluation, select would throw an error in the event of an empty array\nif ((count _array == 0) or { (_array select 0) != player }) then\n{\n    hint \"It works!\";\n};\n```","code":["// without lazy evaluation, select would throw an error in the event of an empty array\nif ((count _array == 0) or { (_array select 0) != player }) then\n{\n\thint \"It works!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["a or b"],"see_also":["a or b","and","Operators"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"orderGetIn","operator":null,"title":"orderGetIn","type":"command","url":"https://community.bistudio.com/wiki/orderGetIn","revid":377143,"updated":"2026-01-01T10:31:44Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Force all units in the array to get in or out of their assigned vehicles. Units must be assigned to a vehicle before this command will do anything.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unitArray orderGetIn order","since":null,"effect":null,"exec":null,"params":[{"name":"unitArray","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"unitArray: Array of Objects"},{"name":"order","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"order: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitArray","types":["Array","Object"]},"right":{"text":"order","types":["Boolean"]}}],"examples":[{"text":"```sqf\n[_unitOne, _unitTwo] orderGetIn true;\n```","code":["[_unitOne, _unitTwo] orderGetIn true;"]},{"text":"```sqf\n[_unitOne, _unitTwo] orderGetIn false;\n```","code":["[_unitOne, _unitTwo] orderGetIn false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowGetIn","addVehicle","assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"overcast","operator":null,"title":"overcast","type":"command","url":"https://community.bistudio.com/wiki/overcast","revid":310759,"updated":"2022-05-07T20:21:35Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current overcast level. Zero is clear skies, one is maximum cloud cover.","syntaxes":[{"syntax":"overcast","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_cloudLevel = overcast;\n```","code":["_cloudLevel = overcast;"]}],"multiplayer":"Before Arma 3, each client and the server can have differing overcast values.","problems":null,"aliases":[],"see_also":["overcastForecast","setOvercast","nextWeatherChange"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"overcastForecast","operator":null,"title":"overcastForecast","type":"command","url":"https://community.bistudio.com/wiki/overcastForecast","revid":310793,"updated":"2022-05-07T20:21:53Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the overcast forecast.","syntaxes":[{"syntax":"overcastForecast","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_forecast = overcastForecast;\n```","code":["_forecast = overcastForecast;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["overcast","rain","fog"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"owner","operator":null,"title":"owner","type":"command","url":"https://community.bistudio.com/wiki/owner","revid":363241,"updated":"2024-03-26T10:51:18Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":true},"exec":null,"description":"On server machine, returns the machine network ID of the client to which the object is local. Otherwise returns 0. For use on clients clientOwner command is available. To find out the owner of a Group, use groupOwner.","syntaxes":[{"syntax":"owner object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_clientID = owner _someobject;\n```","code":["_clientID = owner _someobject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["publicVariableClient","setOwner","setGroupOwner","groupOwner","flagOwner","onPlayerConnected","didJIPOwner","local","admin","remoteExecutedOwner"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"param","operator":null,"title":"param","type":"command","url":"https://community.bistudio.com/wiki/param","revid":369264,"updated":"2024-09-03T18:42:42Z","groups":["Variables","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Extracts a single value with given index from input argument, similar to BIS_fnc_param.  When used without argument, as shown in main syntax, internal variable _this, which is usually available inside functions and event handlers, is used as argument. If input argument is not an array, it will be converted to 1 element array.\n\nIf extracted item of input with given index is undefined, of the wrong type or of the wrong length (if the item is an array), default value is used instead. Since Arma 3 v1.54, onscreen errors are displayed for when the input is of the wrong type or size.","syntaxes":[{"syntax":"param [index, defaultValue, expectedDataTypes, expectedArrayCount]","since":null,"effect":null,"exec":null,"params":[{"name":"index","type":"Number","optional":false,"default":null,"description":"index of required item in the input array.","types":["Number"],"since":null,"text":"index: Number - index of required item in the input array."},{"name":"defaultValue","type":"Anything","optional":true,"default":null,"description":"a default value to return if input is undefined, of the wrong type or of the wrong length (if the item is an array).","types":["Anything"],"since":null,"text":"defaultValue: Anything - (Optional) a default value to return if input is undefined, of the wrong type or of the wrong length (if the item is an array)."},{"name":"expectedDataTypes","type":"Array of direct Data Types","optional":true,"default":null,"description":"checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.","types":["Array"],"since":null,"text":"expectedDataTypes: Array of direct Data Types - (Optional) checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted."},{"name":"expectedArrayCount","type":"Number or Array","optional":true,"default":null,"description":"a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted.","types":["Number","Array"],"since":null,"text":"expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted."}],"returns":{"type":"Anything","types":["Anything"],"description":"extracted value on success or default value otherwise. Nothing if syntax error occurred.","text":"Anything - extracted value on success or default value otherwise. Nothing if syntax error occurred."},"form":"unary","operator":null,"left":null,"right":{"text":"[index, defaultValue, expectedDataTypes, expectedArrayCount]","types":["Array"]}},{"syntax":"argument param [index, defaultValue, expectedDataTypes, expectedArrayCount]","since":null,"effect":null,"exec":null,"params":[{"name":"argument","type":"Anything","optional":false,"default":null,"description":"a usual array of params is expected. If a non-array value is passed, it will be converted to 1 element array","types":["Anything"],"since":null,"text":"argument: Anything - a usual array of params is expected. If a non-array value is passed, it will be converted to 1 element array"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index of required item in the input array.","types":["Number"],"since":null,"text":"index: Number - index of required item in the input array."},{"name":"defaultValue","type":"Anything","optional":true,"default":null,"description":"a default value to return if input is undefined, of the wrong type or of the wrong length (if the item is an array).","types":["Anything"],"since":null,"text":"defaultValue: Anything - (Optional) a default value to return if input is undefined, of the wrong type or of the wrong length (if the item is an array)."},{"name":"expectedDataTypes","type":"Array of direct Data Types","optional":true,"default":null,"description":"checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.","types":["Array"],"since":null,"text":"expectedDataTypes: Array of direct Data Types - (Optional) checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted."},{"name":"expectedArrayCount","type":"Number or Array","optional":true,"default":null,"description":"a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted.","types":["Number","Array"],"since":null,"text":"expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted."}],"returns":{"type":"Anything","types":["Anything"],"description":"extracted value on success or default value otherwise. Nothing if syntax error occurred.","text":"Anything - extracted value on success or default value otherwise. Nothing if syntax error occurred."},"form":"binary","operator":null,"left":{"text":"argument","types":["Anything"]},"right":{"text":"[index, defaultValue, expectedDataTypes, expectedArrayCount]","types":["Array"]}}],"examples":[{"text":"```sqf\n[1, 2, 3] call \n{\n    private _one = param [0, 1];\n    private _two = param [1, 2];\n    private _three = param [2, 3];\n    // ...\n};\n```","code":["[1, 2, 3] call \n{\n\tprivate _one = param [0, 1];\n\tprivate _two = param [1, 2];\n\tprivate _three = param [2, 3];\n\t// ...\n};"]},{"text":"```sqf\n[123] call \n{\n    private _val = param [0];\n};\n\n// Below would produce the same result as above\n123 call \n{\n    private _val = param [0];\n};\n```","code":["[123] call \n{\n\tprivate _val = param [0];\n};\n\n// Below would produce the same result as above\n123 call \n{\n\tprivate _val = param [0];\n};"]},{"text":"```sqf\n_z = position player param [2, 0];\nif (_z > 10) then \n{\n    hint \"YOU ARE FLYING!\";\n};\n```","code":["_z = position player param [2, 0];\nif (_z > 10) then \n{\n\thint \"YOU ARE FLYING!\";\n};"]},{"text":"```sqf\nfnc = \n{\n    private _pos = param [0, [0,0,0], [objNull, []], [2,3]];\n    private _rad = param [1, 0, [0]];\n    _pos nearObjects _rad;\n};\n\n[position player, 25] call fnc; // ok\n[player, 25] call fnc; // ok\n[25, player] call fnc; // default values are used\n```","code":["fnc = \n{\n\tprivate _pos = param [0, [0,0,0], [objNull, []], [2,3]];\n\tprivate _rad = param [1, 0, [0]];\n\t_pos nearObjects _rad;\n};\n\n[position player, 25] call fnc; // ok\n[player, 25] call fnc; // ok\n[25, player] call fnc; // default values are used"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["params","select","set","resize","reverse","in","find","findIf","toArray","toString","forEach","count","deleteAt","deleteRange","append","sort","arrayIntersect","splitString","joinString","isEqualTypeAll","isEqualType","isEqualTypeParams","isEqualTypeArray","isEqualTypeAny","typeName","BIS_fnc_param"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Variables","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"params","operator":null,"title":"params","type":"command","url":"https://community.bistudio.com/wiki/params","revid":377705,"updated":"2026-01-02T09:03:38Z","groups":["Variables","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Parses input argument into array of private variables. When used without argument, as shown in main syntax, internal variable _this, which is usually available inside functions and event handlers, is used as argument.\n\nIn addition to simple parsing directly into variables, input can be tested in case it is undefined, of the wrong type or of the wrong size (if array) and substituted if necessary with default values. Since Arma 3 v1.54, onscreen errors are displayed for when the input is of the wrong type or size.\n\n> [!WARNING]\n> All variables names must start with underscore and be enclosed in quotes:\n\n> [!NOTE]\n> It is a good practice to make your local variables **private** (through private or params) in order to avoid overwriting a local variable of the same name.","syntaxes":[{"syntax":"params [element1, element2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"elementN","type":"String or Array","optional":true,"default":null,"description":"String or Array\n- String:name of the private variable (must begin with underscore _, e.g. \"_myVar\", or can be an empty string \"\", in which case the element is skipped)\n- Array with [variableName, defaultValue, expectedDataTypes, expectedArrayCount]\n  - variableName: String - name of a private variable (must begin with underscore _, e.g. \"_myVar\")\n  - defaultValue: Anything - default value to return if input element is undefined, of the wrong type or of the wrong size (if array).\n  - expectedDataTypes: Array of direct Data Types -  checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.\n  - expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted.","types":["String","Array"],"since":null,"text":"elementN: String or Array\n- String:name of the private variable (must begin with underscore _, e.g. \"_myVar\", or can be an empty string \"\", in which case the element is skipped)\n- Array with [variableName, defaultValue, expectedDataTypes, expectedArrayCount]\n  - variableName: String - name of a private variable (must begin with underscore _, e.g. \"_myVar\")\n  - defaultValue: Anything - default value to return if input element is undefined, of the wrong type or of the wrong size (if array).\n  - expectedDataTypes: Array of direct Data Types - (Optional) checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.\n  - expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"false if error occurred or default value has been used, otherwise true","text":"Boolean - false if error occurred or default value has been used, otherwise true"},"form":"unary","operator":null,"left":null,"right":{"text":"[element1, element2, ...]","types":["Array"]}},{"syntax":"argument params [element1, element2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"argument","type":"Anything","optional":false,"default":null,"description":"a usual array of params is expected. If a non-array argument is passed, it will be converted to 1 element array","types":["Anything"],"since":null,"text":"argument: Anything - a usual array of params is expected. If a non-array argument is passed, it will be converted to 1 element array"},{"name":"elementN","type":"String or Array","optional":true,"default":null,"description":"String or Array\n- String:name of the private variable (must begin with underscore _, e.g. \"_myVar\", or can be an empty string \"\", in which case the element is skipped)\n- Array with [variableName, defaultValue, expectedDataTypes, expectedArrayCount]\n  - variableName: String - name of a private variable (must begin with underscore _, e.g. \"_myVar\")\n  - defaultValue: Anything - default value to return if input element is undefined, of the wrong type or of the wrong size (if array).\n  - expectedDataTypes: Array of direct Data Types -  checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.\n  - expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted.","types":["String","Array"],"since":null,"text":"elementN: String or Array\n- String:name of the private variable (must begin with underscore _, e.g. \"_myVar\", or can be an empty string \"\", in which case the element is skipped)\n- Array with [variableName, defaultValue, expectedDataTypes, expectedArrayCount]\n  - variableName: String - name of a private variable (must begin with underscore _, e.g. \"_myVar\")\n  - defaultValue: Anything - default value to return if input element is undefined, of the wrong type or of the wrong size (if array).\n  - expectedDataTypes: Array of direct Data Types - (Optional) checks if passed value is one of listed Data Types. If not, default value is used instead. Empty array [] means every data type is accepted.\n  - expectedArrayCount: Number or Array - (Optional) a single size or array of sizes. If passed input value is an array, checks that it has a certain number of elements. If not, default value is used instead. Empty array [] means any size is accepted."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"false if error occurred or default value has been used, otherwise true","text":"Boolean - false if error occurred or default value has been used, otherwise true"},"form":"binary","operator":null,"left":{"text":"argument","types":["Anything"]},"right":{"text":"[element1, element2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n[1, 2, 3] call {\n    private [\"_one\", \"_two\", \"_three\"];\n    _one = _this select 0;\n    _two = _this select 1;\n    _three = _this select 2;\n    // ...\n};\n\n// Same as above, only using params\n[1, 2, 3] call {\n    params [\"_one\", \"_two\", \"_three\"];\n    // ...\n};\n```","code":["[1, 2, 3] call {\n\tprivate [\"_one\", \"_two\", \"_three\"];\n\t_one = _this select 0;\n\t_two = _this select 1;\n\t_three = _this select 2;\n\t// ...\n};\n\n// Same as above, only using params\n[1, 2, 3] call {\n\tparams [\"_one\", \"_two\", \"_three\"];\n\t// ...\n};"]},{"text":"```sqf\n[123] call {\n    params [\"_myvar\"];\n};\n\n// Below would produce the same result as above\n123 call {\n    params [\"_myvar\"];\n};\n```","code":["[123] call {\n\tparams [\"_myvar\"];\n};\n\n// Below would produce the same result as above\n123 call {\n\tparams [\"_myvar\"];\n};"]},{"text":"Skipping some array elements:\n\n```sqf\nposition player params [\"\", \"\", \"_z\"];\nif (_z > 10) then {\n    hint \"YOU ARE FLYING!\";\n};\n```","code":["position player params [\"\", \"\", \"_z\"];\nif (_z > 10) then {\n\thint \"YOU ARE FLYING!\";\n};"]},{"text":"```sqf\n[1, nil, 2] params [\"_var1\", \"_var2\", \"_var3\"];\n// All 3 variables are made private but only _var1 and _var3 are defined\n\n[1, nil, 2] params [\"_var1\", [\"_var2\", 23], \"_var3\"];\n// All 3 variables are private and defined\n```","code":["[1, nil, 2] params [\"_var1\", \"_var2\", \"_var3\"];\n// All 3 variables are made private but only _var1 and _var3 are defined\n\n[1, nil, 2] params [\"_var1\", [\"_var2\", 23], \"_var3\"];\n// All 3 variables are private and defined"]},{"text":"```sqf\n[1, 2] call {\n    if (!params [\"_var1\", \"_var2\", [\"_var3\", true, [true]]]) exitWith {\n        hint str [_var1, _var2, _var3];\n    };\n};\n// The hint shows [1,2,true]\n// Script exits, default value was used due to missing value\n\n[1, 2, 3] call {\n    if (!params [\"_var1\", \"_var2\", [\"_var3\", true, [true]]]) exitWith {\n        hint str [_var1, _var2, _var3];\n    };\n};\n// The hint shows [1,2,true]\n// Script exits, default value was used due incorrect value type\n```","code":["[1, 2] call {\n\tif (!params [\"_var1\", \"_var2\", [\"_var3\", true, [true]]]) exitWith {\n\t\thint str [_var1, _var2, _var3];\n\t};\n};\n// The hint shows [1,2,true]\n// Script exits, default value was used due to missing value\n\n[1, 2, 3] call {\n\tif (!params [\"_var1\", \"_var2\", [\"_var3\", true, [true]]]) exitWith {\n\t\thint str [_var1, _var2, _var3];\n\t};\n};\n// The hint shows [1,2,true]\n// Script exits, default value was used due incorrect value type"]},{"text":"```sqf\n[1, \"ok\", [1, 2, 3]] call {\n    if (!params [\n        [\"_var1\", 0, [0]],\n        [\"_var2\", \"\", [\"\"]],\n        [\"_var3\", [0,0,0], [[], objNull, 0], [2,3]]\n    ]) exitWith {};\n    hint \"ok\";\n};\n// Passes validation\n\n[1, 2, [3, 4, 5]] call {\n    if (!params [\"_var1\", \"_var2\", [\"_var3\", [], [[], objNull, 0], 0]]) exitWith {};\n    hint \"ok\";\n};\n// Fails, because passed array is expected to be of 0 length, i.e. empty\n```","code":["[1, \"ok\", [1, 2, 3]] call {\n\tif (!params [\n\t\t[\"_var1\", 0, [0]],\n\t\t[\"_var2\", \"\", [\"\"]],\n\t\t[\"_var3\", [0,0,0], [[], objNull, 0], [2,3]]\n\t]) exitWith {};\n\thint \"ok\";\n};\n// Passes validation\n\n[1, 2, [3, 4, 5]] call {\n\tif (!params [\"_var1\", \"_var2\", [\"_var3\", [], [[], objNull, 0], 0]]) exitWith {};\n\thint \"ok\";\n};\n// Fails, because passed array is expected to be of 0 length, i.e. empty"]},{"text":"```sqf\n[1, 2, 3, [4, 5, 6]] call {\n    params [\"_one\", \"_two\", \"_three\"];\n    _this select 3 params [\"_four\", \"_five\", \"_six\"];\n};\n```","code":["[1, 2, 3, [4, 5, 6]] call {\n\tparams [\"_one\", \"_two\", \"_three\"];\n\t_this select 3 params [\"_four\", \"_five\", \"_six\"];\n};"]},{"text":"```sqf\n{\n    _x params [\"_group\", \"_index\"];\n    // ...\n} forEach waypoints group player;\n\nfn_someFnc = {\n    params [\"_position\", [\"_direction\", 0], [\"_name\", \"\"]];\n    // Extract the x, y, and z from \"_position\" array:\n    _position params [\"_x\", \"_y\", \"_z\"];\n    // ...\n};\n\n[position player, direction player, name player] call fn_someFnc;\n```","code":["{\n\t_x params [\"_group\", \"_index\"];\n\t// ...\n} forEach waypoints group player;\n\nfn_someFnc = {\n\tparams [\"_position\", [\"_direction\", 0], [\"_name\", \"\"]];\n\t// Extract the x, y, and z from \"_position\" array:\n\t_position params [\"_x\", \"_y\", \"_z\"];\n\t// ...\n};\n\n[position player, direction player, name player] call fn_someFnc;"]},{"text":"```sqf\nplayer addEventHandler [\"HitPart\", {\n    _this select 0 params [\"_target\", \"_shooter\", \"_projectile\"];\n}];\n```","code":["player addEventHandler [\"HitPart\", {\n\t_this select 0 params [\"_target\", \"_shooter\", \"_projectile\"];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["param","select","#"," this","isEqualTypeAll","isEqualType","isEqualTypeParams","isEqualTypeArray","isEqualTypeAny"],"notes":[{"user":"Dedmen","date":"2016-11-03T04:07:00Z","text":"With a function only taking one Parameter, it doesn't matter whether the parameter is in an array or not:\n\nExample:\n\n```sqf\n1 call {\n    params [[\"_number\",0, [0]]];\n};\n```\n\nor\n\n```sqf\n[1] call {\n    params [[\"_number\",0, [0]]];\n};\n```\n\nBut when the one Parameter is an array that parameter has to be inside of an array when the function is called\n\nExample:\n\n```sqf\n[1, 2] call {\n    params [[\"_array\", [], [[]], 2]];\n}; // Fails\n\n[[1,2]] call {\n    params [[\"_array\", [], [[]], 2]];\n}; // Succeeds\n```"},{"user":"7erra","date":"2019-07-04T16:54:00Z","text":"It is valid to redefine the _this variable and use params again like this:\n\n```sqf\n[1, 2, [3, 4]] call {\n    params [\"_one\", \"_two\", \"_this\"];\n    params [\"_three\", \"_four\"];\n};\n```"},{"user":"AgentRev","date":"2021-11-01T16:00:30Z","text":"Here's how to validate HashMap parameters:\n\n```sqf\n_myHashMap = createHashMapFromArray [[\"a\",1],[\"b\",2],[\"c\",3]];\n\n[_myHashMap] call {\n    params [[\"_theHashMap\",createHashMap,[createHashMap]]];\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Variables","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"parentAttached","operator":null,"title":"parentAttached","type":"command","url":"https://community.bistudio.com/wiki/parentAttached","revid":378907,"updated":"2026-08-11T14:57:07Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Get the parent of a attachChild attached child.","syntaxes":[{"syntax":"parentAttached child","since":null,"effect":null,"exec":null,"params":[{"name":"child","type":"Object","optional":false,"default":null,"description":"Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?).","types":["Object"],"since":null,"text":"child: Object -  Must be a Transport vehicle like Car/Tank (Maybe helicopter/airplane works?)."}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"child","types":["Object"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","childAttached"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"parseNumber","operator":null,"title":"parseNumber","type":"command","url":"https://community.bistudio.com/wiki/parseNumber","revid":378867,"updated":"2026-07-30T16:48:17Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Parses the string, interpreting its content as a floating point number.\n\n> [!IMPORTANT]\n> This command does **not** work with strings representing hexadecimal numbers (e.g `\"0xCF\"`).\n>\n> ```sqf\n> parseNumber \"512 + 0x2F\"; // 512, WRONG!\n> \"512 + 0x2F\" call BIS_fnc_parseNumber // 559, CORRECT!\n> ```\n\n> [!NOTE]\n> Starting whitespaces are discarded, then as many valid characters are used to be interpreted as a number until an invalid character is found then the rest of the string is ignored.","syntaxes":[{"syntax":"parseNumber value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"String or Arma 3 v1.50 Boolean or Arma 3 v2.24 Anything","optional":false,"default":null,"description":null,"types":["String","Boolean","Anything"],"since":null,"text":"value: String or Arma 3 v1.50 Boolean or Arma 3 v2.24 Anything"}],"returns":{"type":"Number","types":["Number"],"description":"the parsed number, `0` if no valid number was found; in the case of a passed Boolean, 0 if false, 1 if true","text":"Number - the parsed number, `0` if no valid number was found; in the case of a passed Boolean, 0 if false, 1 if true"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["String","Boolean","Anything"]}}],"examples":[{"text":"```sqf\n_number = parseNumber \"0.125\";            // 0.125\n_number = parseNumber \"0050\";            // 50\n_number = parseNumber \"        42 yes\";    // 42\n_number = parseNumber \"3 or 4\";            // 3\n_number = parseNumber \"either 3 or 4\";    // 0\n_number = parseNumber \"0xCF\";            // 0\n```","code":["_number = parseNumber \"0.125\";\t\t\t// 0.125\n_number = parseNumber \"0050\";\t\t\t// 50\n_number = parseNumber \"\t\t42 yes\";\t// 42\n_number = parseNumber \"3 or 4\";\t\t\t// 3\n_number = parseNumber \"either 3 or 4\";\t// 0\n_number = parseNumber \"0xCF\";\t\t\t// 0"]},{"text":"since Arma 3 v1.50:\n\n```sqf\n_result = parseNumber false;                // 0\n_result = parseNumber true;                    // 1\n_zeroOneStatus = parseNumber alive player;    // 0 if the player is dead, 1 if alive\n```","code":["_result = parseNumber false;\t\t\t\t// 0\n_result = parseNumber true;\t\t\t\t\t// 1\n_zeroOneStatus = parseNumber alive player;\t// 0 if the player is dead, 1 if alive"]},{"text":"since Arma 3 v2.24:\n\n```sqf\nparseNumber 0;                    // 0\nparseNumber 1;                     // 1\nparseNumber false;                // 0\nparseNumber true;                // 1\nparseNumber \"0\";                // 0\nparseNumber \"1\";                // 1\nparseNumber \"false\";            // 0\nparseNumber \"true\";                // 1\n```","code":["parseNumber 0;\t\t\t\t\t// 0\nparseNumber 1;\t\t \t\t\t// 1\nparseNumber false;\t\t\t\t// 0\nparseNumber true;\t\t\t\t// 1\nparseNumber \"0\";\t\t\t\t// 0\nparseNumber \"1\";\t\t\t\t// 1\nparseNumber \"false\";\t\t\t// 0\nparseNumber \"true\";\t\t\t\t// 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_parseNumber","Floating Point Number"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"parseSimpleArray","operator":null,"title":"parseSimpleArray","type":"command","url":"https://community.bistudio.com/wiki/parseSimpleArray","revid":363379,"updated":"2024-03-29T13:22:55Z","groups":["Strings","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts given, formatted as simple array, String into a valid Array. Simple array is array consisting of Numbers, Strings, Booleans and Arrays of all of the above.\nThis command is almost **4× faster** than similar uncached call compile method. And because call compile is not required, it is also **more secure** and primarily intended for use with callExtension to parse the String output into Array.\n\n> [!NOTE]\n> Since Arma 3 v1.96 the command tolerates extra spaces and supports single quotes. The only recognised keywords (case **in**sensitive) are:\n> - `true` - translates into true\n> - `false` - translates into false\n> - `nil` - translates into nil\n> - `null` - translates into nil\n> - `<null>` - translates into nil (*not* objNull)\n> - `any` - translates into nil","syntaxes":[{"syntax":"parseSimpleArray stringArray","since":null,"effect":null,"exec":null,"params":[{"name":"stringArray","type":"String","optional":false,"default":null,"description":"string formatted as simple array","types":["String"],"since":null,"text":"stringArray: String - string formatted as simple array"}],"returns":{"type":"Array","types":["Array"],"description":"valid array","text":"Array - valid array"},"form":"unary","operator":null,"left":null,"right":{"text":"stringArray","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _arr = parseSimpleArray \"[1,2,3]\";\n```","code":["private _arr = parseSimpleArray \"[1,2,3]\";"]},{"text":"```sqf\nprivate _array1 = [1, \"2\", true, [4, \"five\", false]];\nprivate _array2 = parseSimpleArray \"[1,\"\"2\"\",true,[4,\"\"five\"\",false]]\";\n_array1 isEqualTo _array2; // true\n```","code":["private _array1 = [1, \"2\", true, [4, \"five\", false]];\nprivate _array2 = parseSimpleArray \"[1,\"\"2\"\",true,[4,\"\"five\"\",false]]\";\n_array1 isEqualTo _array2; // true"]},{"text":"```sqf\n_bool = true;\n_num = 123.45;\n_str = \"ok\";\n_arr = [1, false, \"cool\"];\n_res = parseSimpleArray format [\"[%1,%2,%3,%4]\", _bool, _num, str _str, str _arr];\n// note how _bool and _num do not need str, however if used anyway, the result in this case would be identical\nhint str _res;  // returns [true,123.45,\"ok\",[1,false,\"cool\"]]\n```","code":["_bool = true;\n_num = 123.45;\n_str = \"ok\";\n_arr = [1, false, \"cool\"];\n_res = parseSimpleArray format [\"[%1,%2,%3,%4]\", _bool, _num, str _str, str _arr];\n// note how _bool and _num do not need str, however if used anyway, the result in this case would be identical\nhint str _res;  // returns [true,123.45,\"ok\",[1,false,\"cool\"]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","resize","pushBack","pushBackUnique","select","apply","reverse","count","find","in","forEach","deleteAt","deleteRange","append","sort","arrayIntersect","callExtension"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Strings","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"parseText","operator":null,"title":"parseText","type":"command","url":"https://community.bistudio.com/wiki/parseText","revid":364995,"updated":"2024-07-04T19:58:06Z","groups":["Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a structured text by parsing the given XML description. Do not use parseText when displaying a localized text from Stringtable.xml.\n\nA detailed explanation of all formatting possibilities can be found at Structured Text.","syntaxes":[{"syntax":"parseText text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _Stxt = parseText \"First line<img image='data\\isniper.paa'/><br/>Second line\";\n```","code":["private _Stxt = parseText \"First line<img image='data\\isniper.paa'/><br/>Second line\";"]},{"text":"```sqf\nhintSilent parseText format[\"<t size='1.25' font='Zeppelin33' color='#ff0000'>%1 lives remaining.</t>\", 12];\n```","code":["hintSilent parseText format[\"<t size='1.25' font='Zeppelin33' color='#ff0000'>%1 lives remaining.</t>\", 12];"]},{"text":"```sqf\nprivate _clickableLink = parseText \"<a href='http://arma3.com'>A3</a>\";\n```","code":["private _clickableLink = parseText \"<a href='http://arma3.com'>A3</a>\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Structured Text","composeText","text","localize","ctrlSetStructuredText"],"notes":[{"user":"Dr_Eyeball","date":"2016-09-01T06:47:00Z","text":"To convert a structured text back to a string type, just use:\n\n```sqf\n_str = str parseText _structuredText;\n```"},{"user":"AgentRev","date":"2017-09-01T13:23:00Z","text":"If you are parsing user-defined strings like player names, you may want to convert special characters to their [XML entities](https://en.wikipedia.org/wiki/Character_encodings_in_HTML#XML_character_references) as a precaution beforehand, otherwise the result might be corrupted.\n\n```sqf\nprivate _escapeXML =\n{\n    _this\n    regexReplace [\"&\", \"&\"]\n    regexReplace [\"<\", \"<\"]\n    regexReplace [\">\", \">\"]\n    regexReplace ['\"', \"\"\"]\n    regexReplace [\"'\", \"'\"]\n};\n\nprivate _name = '<A&M> Paul \"Bear\" Bryant';\nprivate _escapedName = _name call _escapeXML;\nprivate _redName = parseText format [\"<t color='#ff0000'>%1</t>\", _escapedName];\n```"},{"user":"Sa-Matra","date":"2023-10-13T12:02:33Z","text":"Here is a useful script snippet to safely use angled braces and ampersand in structured texts:\n\n```sqf\n_string regexReplace [\"&\", \"&\"] regexReplace [\"<\", \"<\"]\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Command Group: Structured Text","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"parsingNamespace","operator":null,"title":"parsingNamespace","type":"command","url":"https://community.bistudio.com/wiki/parsingNamespace","revid":339160,"updated":"2023-04-26T10:55:24Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the global namespace attached to config parser.","syntaxes":[{"syntax":"parsingNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":null,"text":"Namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nparsingNamespace setVariable [\"var1\", 101.23124];\n_profVar1 = parsingNamespace getVariable \"var1\";\n```","code":["parsingNamespace setVariable [\"var1\", 101.23124];\n_profVar1 = parsingNamespace getVariable \"var1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","uiNamespace","currentNamespace","profileNamespace","localNamespace","allVariables","with","ArmA: Editing"],"notes":[{"user":"BrotherhoodOfHam","date":"2015-01-27T18:08:00Z","text":"Any global variable defined in a config using __EXEC() will be stored in this namespace.\n\nFor example in the description.ext:\n\n```sqf\n__EXEC(testVar = 1);\n```\n\nThe variable \"testVar\" can be accessed during mission run time using getVariable\n\n```sqf\nhint str (parsingNamespace getVariable [\"testVar\", 0]);\n```\n\nThe above example would print 1.\n\nThis example however:\n\n```sqf\n__EXEC(_testVar = 1);\n```\n\nWould print 0, because adding an underscore will make the variable local to the config in the same way that it would make it local to a script.\n\nSee PreProcessor Commands for more details on __EXEC()"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"particlesQuality","operator":null,"title":"particlesQuality","type":"command","url":"https://community.bistudio.com/wiki/particlesQuality","revid":310765,"updated":"2022-05-07T20:21:39Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Returns current user settings for particles quality (configure->video->general->particles). 0-low, 1-normal, 2-high","syntaxes":[{"syntax":"particlesQuality","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_currentQuality = particlesQuality;\n```","code":["_currentQuality = particlesQuality;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setParticleCircle","setParticleParams","setParticleRandom","ParticleTemplates","setParticleClass","setParticleFire"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Particles","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"periscopeElevation","operator":null,"title":"periscopeElevation","type":"command","url":"https://community.bistudio.com/wiki/periscopeElevation","revid":378227,"updated":"2026-03-17T23:24:58Z","groups":["Object Manipulation","Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current periscope elevation value, see also elevatePeriscope.","syntaxes":[{"syntax":"vehicle periscopeElevation turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with periscope tech","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with periscope tech"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Array format [elevation, isLocked]:","types":["Array"],"description":"elevation: Number - current periscope elevation value. -1 in case of an invalid turret - isLocked: Boolean - whether or not user override is blocked","text":"Array format [elevation, isLocked]:\n- elevation: Number - current periscope elevation value. -1 in case of an invalid turret\n- isLocked: Boolean - whether or not user override is blocked"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_eddie periscopeElevation [0] params [\"_elevation\", \"_isLocked\"];\n```","code":["_eddie periscopeElevation [0] params [\"_elevation\", \"_isLocked\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["elevatePeriscope","animationPhase","allTurrets","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Object Manipulation","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"pi","operator":null,"title":"pi","type":"command","url":"https://community.bistudio.com/wiki/pi","revid":319402,"updated":"2022-05-13T09:24:00Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"pi (180 degrees converted to Radians).","syntaxes":[{"syntax":"pi","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_radians = 2 * pi; // Result is 6.2830\n```","code":["_radians = 2 * pi; // Result is 6.2830"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tan","cos","sin"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"pickWeaponPool","operator":null,"title":"pickWeaponPool","type":"command","url":"https://community.bistudio.com/wiki/pickWeaponPool","revid":310249,"updated":"2022-05-05T13:11:07Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Transfers weapons and magazines from cargo of object into the weapon pool. This is used in the campaign to transfer weapons into the next mission.","syntaxes":[{"syntax":"pickWeaponPool object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\npickWeaponPool vehicle player;\n```","code":["pickWeaponPool vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"pitch","operator":null,"title":"pitch","type":"command","url":"https://community.bistudio.com/wiki/pitch","revid":310193,"updated":"2022-05-05T13:10:35Z","groups":["Unit Identity","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the pitch of a persons voice.","syntaxes":[{"syntax":"pitch person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\npitch player;\n```","code":["pitch player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPitch"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands"]},{"name":"pixelGrid","operator":null,"title":"pixelGrid","type":"command","url":"https://community.bistudio.com/wiki/pixelGrid","revid":376543,"updated":"2025-10-27T00:18:56Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns grid size based on screen resolution, UI size and configs: uiScaleFactor, uiScaleMaxGrids.","syntaxes":[{"syntax":"pixelGrid","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"grid size, see Arma 3: Pixel Grid System","text":"Number - grid size, see Arma 3: Pixel Grid System"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _gridHeight = pixelH * pixelGrid;\n```","code":["private _gridHeight = pixelH * pixelGrid;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelGridBase","pixelGridNoUIScale","pixelH","pixelW","Pixel Grid System"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"pixelGridBase","operator":null,"title":"pixelGridBase","type":"command","url":"https://community.bistudio.com/wiki/pixelGridBase","revid":348722,"updated":"2023-11-08T14:31:29Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns grid size based on screen resolution.","syntaxes":[{"syntax":"pixelGridBase","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"grid size, see Arma 3: Pixel Grid System","text":"Number - grid size, see Arma 3: Pixel Grid System"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_gridBaseHeight = pixelH * pixelGridBase;\n```","code":["_gridBaseHeight = pixelH * pixelGridBase;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelGrid","pixelGridNoUIScale","pixelH","pixelW","Pixel Grid System"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"pixelGridNoUIScale","operator":null,"title":"pixelGridNoUIScale","type":"command","url":"https://community.bistudio.com/wiki/pixelGridNoUIScale","revid":378048,"updated":"2026-01-29T12:07:20Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns grid size based on screen resolution and configs: `uiScaleFactor`, `uiScaleMaxGrids`.\nAs mentioned in the name of this command, **the user interface scale is ignored**.","syntaxes":[{"syntax":"pixelGridNoUIScale","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"grid size, see Arma 3: Pixel Grid System","text":"Number - grid size, see Arma 3: Pixel Grid System"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _gridHeightNoUIScale = pixelH * pixelGridNoUIScale;\n```","code":["private _gridHeightNoUIScale = pixelH * pixelGridNoUIScale;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelGrid","pixelGridBase","pixelH","pixelW","Pixel Grid System"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"pixelH","operator":null,"title":"pixelH","type":"command","url":"https://community.bistudio.com/wiki/pixelH","revid":349003,"updated":"2023-11-08T14:45:51Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the height of one pixel for current resolution.","syntaxes":[{"syntax":"pixelH","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"pixel height","text":"Number - pixel height"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_pixelHeight = pixelH;\n```","code":["_pixelHeight = pixelH;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelGrid","pixelGridBase","pixelGridNoUIScale","pixelW","Pixel Grid System"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"pixelW","operator":null,"title":"pixelW","type":"command","url":"https://community.bistudio.com/wiki/pixelW","revid":348976,"updated":"2023-11-08T14:45:44Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns width of one pixel for current resolution.","syntaxes":[{"syntax":"pixelW","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"pixel width","text":"Number - pixel width"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_pixelWidth = pixelW;\n```","code":["_pixelWidth = pixelW;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pixelGrid","pixelGridBase","pixelGridNoUIScale","pixelH","Pixel Grid System"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"playableSlotsNumber","operator":null,"title":"playableSlotsNumber","type":"command","url":"https://community.bistudio.com/wiki/playableSlotsNumber","revid":319373,"updated":"2022-05-13T09:23:58Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.06"}],"since":{"game":"arma3","name":"Arma 3","version":"1.06"},"arma3_since":"1.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the number of available slots in mission per side (both empty and taken).\nIn singleplayer mission, it returns number of playable units per side.","syntaxes":[{"syntax":"playableSlotsNumber side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n_maxBluforPlayers = playableSlotsNumber blufor;\n```","code":["_maxBluforPlayers = playableSlotsNumber blufor;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playersNumber","playableUnits","switchableUnits"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.06","Scripting Commands"]},{"name":"playableUnits","operator":null,"title":"playableUnits","type":"command","url":"https://community.bistudio.com/wiki/playableUnits","revid":376985,"updated":"2026-01-01T07:13:32Z","groups":["Multiplayer","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of playable units in a multiplayer game (occupied by both AI or players), created on the following sides east/opfor, west/blufor, resistance/independent and civilian only.\nDoes not contain units of sideLogic.\n\n> [!NOTE]\n> This command returns an empty array in Singleplayer; use switchableUnits instead.\n\n> [!IMPORTANT]\n> This command does not include dead players awaiting for respawn.","syntaxes":[{"syntax":"playableUnits","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n{ _x groupChat \"I'm a playable unit.\"; } forEach playableUnits;\n```","code":["{ _x groupChat \"I'm a playable unit.\"; } forEach playableUnits;"]},{"text":"```sqf\n_playableInGroup = units group player arrayIntersect playableUnits;\n```","code":["_playableInGroup = units group player arrayIntersect playableUnits;"]},{"text":"```sqf\n_nonPlayableInGroup = units group player - playableUnits;\n```","code":["_nonPlayableInGroup = units group player - playableUnits;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playableSlotsNumber","allPlayers","allCurators","allGroups","allDead","switchableUnits","vehicles","allUnitsUAV","allDeadMen","isPlayer","playersNumber"],"notes":[{"user":"DreadedEntity","date":"2014-12-23T23:13:00Z","text":"To get a list of all player-controlled units:\n\n```sqf\n_allPlayers = [];\n{\n    if (isPlayer _x) then\n    {\n        _allPlayers pushBack _x;\n    };\n} forEach playableUnits;\n```"},{"user":"FR Starfox64","date":"2015-08-16T10:05:00Z","text":"playableUnits will not return dead players, use allPlayers instead."},{"user":"Pierre MGI","date":"2017-02-14T22:05:00Z","text":"Using the Editor (multiplayer attributes) for unchecking \"enable AI\", or disabling AI(s) in lobby, will make playableUnits as a public variable,  updated by each JIP on disabled slot.\nSo, if all slots are disabled AI, playableUnits is same as allPlayers\n\nFurthermore, in this case, non-played slot (playable and disabled AI) units simply don't exist!\n\ni.e. If you name 8 playable units: u1..u8, then 2 players in game: u3 & u6\n\nplayableUnits will return [u3,u6], and true for  isNil \"u1\", isNil \"u2\"... until another player takes the slot."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playAction","operator":null,"title":"playAction","type":"command","url":"https://community.bistudio.com/wiki/playAction","revid":341827,"updated":"2023-06-28T04:46:19Z","groups":["Unit Control","Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"When used on a person, a smooth transition to the given action will be initiated.\n\nFor Arma 3 actions see: playAction/actions.","syntaxes":[{"syntax":"soldier playAction action","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nsoldierOne playAction \"SitDown\";\n```","code":["soldierOne playAction \"SitDown\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playActionNow","switchAction","playMove","playMoveNow","switchMove"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"playActionNow","operator":null,"title":"playActionNow","type":"command","url":"https://community.bistudio.com/wiki/playActionNow","revid":364763,"updated":"2024-06-08T18:43:24Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"When used on a person, a smooth transition to the given action will be initiated, but all previous playAction are discarded.\n\n> [!NOTE]\n> **Arma 3:** For Arma 3 actions, see playAction/actions.","syntaxes":[{"syntax":"soldier playActionNow action","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nsoldierOne playActionNow \"SitDown\";\n```","code":["soldierOne playActionNow \"SitDown\";"]},{"text":"```sqf\nrabbitTwo playActionNow \"WalkF\";\n```","code":["rabbitTwo playActionNow \"WalkF\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playAction","switchAction","playMove","playMoveNow","switchMove"],"notes":[{"user":"Wolfrug","date":"2010-10-12T09:41:00Z","text":"Some other possible playactions:\n- `\"walkF\"` - walk forward\n- `\"walkB\"` - walk backwards\n- `\"walkR\"` - strafe right\n- `\"walkL\"` - strafe left\n- `\"grabDrag\"` - initiate First Aid dragging animation\n- `\"stopDrag\"` - stop First Aid dragging animation\n- `\"reloadMagazine\"` - reload the current magazine\n- `\"gestureFreeze\"` - hand signal \"Freeze\"\n- `\"gestureGo\"`\n- `\"gestureCover\"`\n- `\"gestureAttack\"`\n- `\"gestureCeaseFire\"`\n- `\"gestureFollow\"`\n- `\"gestureUp\"`\n- `\"gestureAdvance\"`\n- `\"gesturePoint\"`\n\nNote that playAction works regardless of stance (rifle up, down, crouched, prone)."},{"user":"h -","date":"2023-09-05T07:36:58Z","text":"Playing a gesture with playActionNow while a soldier held weapon is deployed on something will 'undeploy' the weapon.\nUsing playAction doesn't."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"player","operator":null,"title":"player","type":"command","url":"https://community.bistudio.com/wiki/player","revid":363907,"updated":"2024-04-24T21:56:05Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A person object controlled by user. In Intros and Outros this isn't set by default and must be assigned.","syntaxes":[{"syntax":"player","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nplayer addRating 500;\n```","code":["player addRating 500;"]}],"multiplayer":"In MP player is different on each computer and on dedicated server it is objNull by default ([unless scripted](https://www.youtube.com/watch?v=JzgJe9sXAiU)).\nWhen user is joining a dedicated server mission, at the moment of onPlayerConnected the player object is remote to the joining client, as the player unit is created on the server, but once control of the unit is passed to the user moments later, the player objects becomes and remains local to the client.\n\nSee Multiplayer Scripting's player topic for additional helpful information.","problems":"In multiplayer, the command is not initialised in functions called by initline or init eventhandlers.","aliases":[],"see_also":["Multiplayer Scripting","isPlayer","playableUnits","selectPlayer"],"notes":[{"user":"Galzohar","date":"2010-06-20T03:11:00Z","text":"Before you use the **player** object in init scripts, to avoid JIP issues all you need is to run:\n\n```sqf\nwaitUntil { not isNull player };\n```\n\nAnything else you see in other scripts is equivalent and/or redundant. (but you may need to add other conditions too, such as checking hasInterface before initiating that loop)\n\nOf course JIP players may need more than just the player to point at the actual JIP player unit, but that's script/mission-specific."},{"user":"Killzone_Kid","date":"2014-06-26T18:49:00Z","text":"player can actually be REMOTE object on player's PC: <http://www.youtube.com/watch?v=m6IILtfa3cQ>"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playerRespawnTime","operator":null,"title":"playerRespawnTime","type":"command","url":"https://community.bistudio.com/wiki/playerRespawnTime","revid":353208,"updated":"2024-03-12T13:57:45Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the player's remaining time before respawn, or -1 if it is not available (such as when the player is alive).","syntaxes":[{"syntax":"playerRespawnTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nwaitUntil { playerRespawnTime <= 0 };\n```","code":["waitUntil { playerRespawnTime <= 0 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPlayerRespawnTime"],"notes":[{"user":"Synide","date":"2007-06-21T17:33:00Z","text":"When playerRespawnTime reaches zero the player respawns as expected. When the player has completed respawning this command returns -1."},{"user":"RolanDecoy","date":"2009-02-25T20:44:00Z","text":"Also note that spawning doesn't create a body to use, but allows a player to choose an already existing one as defined either in the mission editor or in a script as player or playable."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playerSide","operator":null,"title":"playerSide","type":"command","url":"https://community.bistudio.com/wiki/playerSide","revid":353328,"updated":"2024-03-15T17:11:49Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the player's side. This is valid even when the player controlled person is dead (a difference from side player).\n\n> [!NOTE]\n> playerSide will not change automatically if player joins a group on different side. However, selectPlayer command can and does change playerSide - see #Example 3 for information.","syntaxes":[{"syntax":"playerSide","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side man1 == playerSide) then\n{\n    hint \"man1 is on your side!\";\n};\n```","code":["if (side man1 == playerSide) then\n{\n\thint \"man1 is on your side!\";\n};"]},{"text":"```sqf\nswitch (playerSide) do\n{\n    case west: { hint \"You are BLUFOR\"; };\n    case east: { hint \"You are OPFOR\"; };\n};\n```","code":["switch (playerSide) do\n{\n\tcase west: { hint \"You are BLUFOR\"; };\n\tcase east: { hint \"You are OPFOR\"; };\n};"]},{"text":"the following code will change the side of the player including playerSide:\n\n```sqf\nprivate _player = player;\n[player] join createGroup east;\nselectNoPlayer;\nselectPlayer _player;\nhint str playerSide; // EAST\n```","code":["private _player = player;\n[player] join createGroup east;\nselectNoPlayer;\nselectPlayer _player;\nhint str playerSide; // EAST"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side","side","west","east","resistance","civilian","sideLogic","sideFriendly","sideEnemy","sideUnknown","sideEmpty","sideAmbientLife","Side Relations"],"notes":[{"user":"Dr_Eyeball","date":"2008-01-27T07:52:00Z","text":"playerSide defaults to west for JIP players early on during initialization regardless of their side.\n\nSo if you are a JIP player on another side (like east), you will need to cater for this for any early initializations."},{"user":"Dr_Eyeball","date":"2008-10-13T08:30:00Z","text":"playerSide also shows your starting side, even if your side changes to enemy due to a bad rating. In that case, playerSide != side player."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playersNumber","operator":null,"title":"playersNumber","type":"command","url":"https://community.bistudio.com/wiki/playersNumber","revid":369133,"updated":"2024-09-03T10:34:34Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns count of occupied role selection slots for given side. Players who claimed a slot in the lobby but did not start the mission are counted as well. If `disabledAI = 0;` in description.ext or *Enable AI* option is checked in Eden Editor, AI bots will be treated as valid players and will be counted too.","syntaxes":[{"syntax":"playersNumber side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n_west = playersNumber west;\n_east = playersNumber east;\n_civ = playersNumber civilian;\nhint format [\"West:%1 East:%2, Civ:%3\", _west, _east, _civ];\n```","code":["_west = playersNumber west;\n_east = playersNumber east;\n_civ = playersNumber civilian;\nhint format [\"West:%1 East:%2, Civ:%3\", _west, _east, _civ];"]}],"multiplayer":"**Multiplayer only**, in singleplayer it always returns 0.","problems":null,"aliases":[],"see_also":["playableSlotsNumber","countSide","allPlayers","allUnits"],"notes":[{"user":"Nelis75733126","date":"2015-04-13T09:44:00Z","text":"**2024-04-16 edit:**\n\n`playersNumber` returns playable AI as well as human players.\n\nBy default, a unit (placed down in the editor for example) ONLY becomes playable when the creator specifically checks the relevant checkbox.\n\nIn addition to the examples already given, this is how `playersNumber` can be used to get an array of players and playable AI on the same side as the side of the player:\n\n```sqf\nplayersNumber playerSide;\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint version 1.80","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playerTargetLock","operator":null,"title":"playerTargetLock","type":"command","url":"https://community.bistudio.com/wiki/playerTargetLock","revid":377647,"updated":"2026-01-02T09:01:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the local player's current locked target (with weapons that can lock on).","syntaxes":[{"syntax":"playerTargetLock","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [target, lockValue, config]","types":["Array"],"description":"target: Object - the locked object - lockValue: Number - in range 0..1 where 1 is fully locked - config: Config - used weapon's `CfgWeapons` config","text":"Array with [target, lockValue, config]\n- target: Object - the locked object\n- lockValue: Number - in range 0..1 where 1 is fully locked\n- config: Config - used weapon's `CfgWeapons` config"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nplayerTargetLock params [\"_target\", \"_lock\", \"_cfg\"];\nif (_lock == 1) then\n{\n    hint format [\"%1 locked %2\", getText (_cfg >> \"displayName\"), getText (configOf _target >> \"displayName\")];\n};\n```","code":["playerTargetLock params [\"_target\", \"_lock\", \"_cfg\"];\nif (_lock == 1) then\n{\n\thint format [\"%1 locked %2\", getText (_cfg >> \"displayName\"), getText (configOf _target >> \"displayName\")];\n};"]},{"text":"```sqf\nplayerTargetLock; // returns [objNull, 0, configNull] if no lock is being done\n```","code":["playerTargetLock; // returns [objNull, 0, configNull] if no lock is being done"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cursorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"playGesture","operator":null,"title":"playGesture","type":"command","url":"https://community.bistudio.com/wiki/playGesture","revid":373654,"updated":"2025-06-01T19:10:10Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"When used on a person,a smooth transition to the given move will be initiated. **Command doesn't seem to be functional**\n\n> [!NOTE]\n> **Arma 3:** Use switchGesture instead (the alternative syntax, sinceArma 3 v2.18)","syntaxes":[{"syntax":"soldier playGesture moveName","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"moveName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"moveName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"moveName","types":["String"]}}],"examples":[{"text":"```sqf\nsoldierOne playGesture \"Wave\";\n```","code":["soldierOne playGesture \"Wave\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playMove","playMoveNow","playAction","playActionNow","switchMove","switchGesture"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playMission","operator":null,"title":"playMission","type":"command","url":"https://community.bistudio.com/wiki/playMission","revid":376427,"updated":"2025-10-13T07:06:23Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The mission is launched (from the main menu).","syntaxes":[{"syntax":"playMission [campaign, mission, skipBriefing]","since":null,"effect":null,"exec":null,"params":[{"name":"campaign","type":"String","optional":false,"default":null,"description":"directory of Campaign, if empty a single mission is launched","types":["String"],"since":null,"text":"campaign: String - directory of Campaign, if empty a single mission is launched"},{"name":"mission","type":"String or Config","optional":false,"default":null,"description":"directory if a string","types":["String","Config"],"since":null,"text":"mission: String or Config - directory if a string"},{"name":"skipBriefing","type":"Boolean","optional":true,"default":null,"description":"If true, the intro and briefing are skipped.","types":["Boolean"],"since":null,"text":"skipBriefing: Boolean - (Optional) If true, the intro and briefing are skipped."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[campaign, mission, skipBriefing]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayMission [\"XOutrage\", \"x05Negotiator.Noe\"];\n```","code":["playMission [\"XOutrage\", \"x05Negotiator.Noe\"];"]},{"text":"```sqf\nplayMission [\"\", configFile >> \"CfgMissions\" >> \"Missions\" >> \"Armory1\"];\n```","code":["playMission [\"\", configFile >> \"CfgMissions\" >> \"Missions\" >> \"Armory1\"];"]},{"text":"```sqf\nplayMission [\"\", \"\\A3\\Missions_F_Bootcamp\\Scenarios\\Arsenal.VR\"];\n```","code":["playMission [\"\", \"\\A3\\Missions_F_Bootcamp\\Scenarios\\Arsenal.VR\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hostMission","playScriptedMission","createMissionDisplay","createMPCampaignDisplay"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playMove","operator":null,"title":"playMove","type":"command","url":"https://community.bistudio.com/wiki/playMove","revid":373663,"updated":"2025-06-01T19:28:50Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"When used on a person, smooth transition to given move will be done.\n\nThe difference between playMove and playMoveNow is that playMove adds another move to the move queue, while playMoveNow replaces the whole move queue with new move (see #Example 2).\n\n> [!NOTE]\n> see Category:Moves for respective games animations.\n\n> [!IMPORTANT]\n> A transition is only possible if the current and provided animation nodes are connected to each other in config (via connectTo/From and interpolateTo/From). The connection can be indirect (using intermediate animations)","syntaxes":[{"syntax":"unitName playMove moveName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"moveName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"moveName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"moveName","types":["String"]}}],"examples":[{"text":"```sqf\nsoldierOne playMove \"Stand\";\n```","code":["soldierOne playMove \"Stand\";"]},{"text":"```sqf\nplayer switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn \n{\n    sleep 0.5;\n    player playMove \"AmovPpneMstpSrasWrflDnon\";        // player goes prone\n    player playMove \"amovPknlMstpSrasWrflDnon\";        // player gets up on one knee\n};\n```","code":["player switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn \n{\n\tsleep 0.5;\n\tplayer playMove \"AmovPpneMstpSrasWrflDnon\";\t\t// player goes prone\n\tplayer playMove \"amovPknlMstpSrasWrflDnon\";\t\t// player gets up on one knee\n};"]},{"text":"```sqf\nplayer switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn\n{\n    sleep 0.5;\n    player playMove \"AmovPpneMstpSrasWrflDnon\";        // player never goes prone\n    player playMoveNow \"AmovPknlMstpSrasWrflDnon\";    // player goes down on one knee straight away\n};\n```","code":["player switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn\n{\n\tsleep 0.5;\n\tplayer playMove \"AmovPpneMstpSrasWrflDnon\";\t\t// player never goes prone\n\tplayer playMoveNow \"AmovPknlMstpSrasWrflDnon\";\t// player goes down on one knee straight away\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playMoveNow","switchMove","playAction","playActionNow"],"notes":[{"user":"Macguba","date":"2006-04-16T02:39:00Z","text":"For an immediate transition use switchMove. This command must be executed after mission start. If you place it into init.sqs / init.sqf or in the Init field of some unit, it will not work. Just add a little delay (~0.001) and then place the command."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"playMoveNow","operator":null,"title":"playMoveNow","type":"command","url":"https://community.bistudio.com/wiki/playMoveNow","revid":376870,"updated":"2025-12-10T17:02:35Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"When used on a person,a smooth transition to the given move will be initiated, but all previous playMove are discarded.\n\nThe difference between playMove and playMoveNow is that playMove adds another move to the move queue, while playMoveNow replaces the whole move queue with new move (see #Example 2).\n\n> [!NOTE]\n> see Category:Moves for respective games animations.\n\n> [!IMPORTANT]\n> A transition is only possible if the current and provided animation nodes are connected to each other in config (via connectTo/From and interpolateTo/From).\n> The connection can be indirect (using intermediate animations).","syntaxes":[{"syntax":"soldier playMoveNow moveName","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"moveName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"moveName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"moveName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer playMoveNow \"AmovPercMevaSlowWrflDf\";\n```","code":["player playMoveNow \"AmovPercMevaSlowWrflDf\";"]},{"text":"```sqf\nplayer switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn \n{\n    sleep 0.5;\n    player playMove \"AmovPpneMstpSrasWrflDnon\";        // player goes prone\n    player playMove \"amovPknlMstpSrasWrflDnon\";        // player gets up on one knee\n};\n```","code":["player switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn \n{\n\tsleep 0.5;\n\tplayer playMove \"AmovPpneMstpSrasWrflDnon\";\t\t// player goes prone\n\tplayer playMove \"amovPknlMstpSrasWrflDnon\";\t\t// player gets up on one knee\n};"]},{"text":"```sqf\nplayer switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn\n{\n    sleep 0.5;\n    player playMove \"AmovPpneMstpSrasWrflDnon\";        // player never goes prone\n    player playMoveNow \"AmovPknlMstpSrasWrflDnon\";    // player goes down on one knee straight away\n};\n```","code":["player switchMove \"AmovPercMstpSrasWrflDnon\";\n0 spawn\n{\n\tsleep 0.5;\n\tplayer playMove \"AmovPpneMstpSrasWrflDnon\";\t\t// player never goes prone\n\tplayer playMoveNow \"AmovPknlMstpSrasWrflDnon\";\t// player goes down on one knee straight away\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playMove","switchMove","playAction","playActionNow"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"playMusic","operator":null,"title":"playMusic","type":"command","url":"https://community.bistudio.com/wiki/playMusic","revid":369050,"updated":"2024-09-02T20:24:51Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Plays music defined in Description.ext's CfgMusic or config.cpp. If the *musicName* could not be found a message is logged into the .rpt file: `Music <*musicName*> not found`.\n- Arma 3: CfgMusic\n- Arma 2: CfgMusic\n- ArmA: Armed Assault: CfgMusic\n- Operation Flashpoint: CfgMusic\n\n> [!NOTE]\n> To stop the music, use `playMusic \"\";`.","syntaxes":[{"syntax":"playMusic musicName","since":null,"effect":null,"exec":null,"params":[{"name":"musicName","type":"String","optional":false,"default":null,"description":"music classname","types":["String"],"since":null,"text":"musicName: String - music classname"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"musicName","types":["String"]}},{"syntax":"playMusic [musicName, start]","since":null,"effect":null,"exec":null,"params":[{"name":"musicName","type":"String","optional":false,"default":null,"description":"music classname","types":["String"],"since":null,"text":"musicName: String - music classname"},{"name":"start","type":"Number","optional":false,"default":null,"description":"start, in seconds. Can be negative.","types":["Number"],"since":null,"text":"start: Number - start, in seconds. Can be negative."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[musicName, start]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayMusic \"RadioAmbient1\";\n```","code":["playMusic \"RadioAmbient1\";"]},{"text":"```sqf\nplayMusic [\"RadioAmbient3\", 3]; // start to play from 00:00:03\n```","code":["playMusic [\"RadioAmbient3\", 3]; // start to play from 00:00:03"]},{"text":"Play from 00:00:01 to 00:00:05:\n\n```sqf\n0 spawn {\n    playMusic [\"RadioAmbient5\", 1];\n    sleep 4;\n    playMusic \"\";\n};\n```","code":["0 spawn {\n\tplayMusic [\"RadioAmbient5\", 1];\n\tsleep 4;\n\tplayMusic \"\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMusicPlayedTime","playSound","say","createSoundSource","addMusicEventHandler","fadeMusic","Arma 3 Utilities"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"playScriptedMission","operator":null,"title":"playScriptedMission","type":"command","url":"https://community.bistudio.com/wiki/playScriptedMission","revid":369272,"updated":"2024-09-03T18:42:43Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Load the given world, launch an empty mission, and execute the given expression.\nIf provided, *config* can reference to the config entry, replacing Description.ext for this mission.","syntaxes":[{"syntax":"playScriptedMission [world, expression, config, ignoreChildWindow]","since":null,"effect":null,"exec":null,"params":[{"name":"world","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"world: String"},{"name":"expression","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"expression: Code"},{"name":"config","type":"Config","optional":true,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config - (Optional)"},{"name":"ignoreChildWindow","type":"Boolean","optional":true,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"ignoreChildWindow: Boolean - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[world, expression, config, ignoreChildWindow]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayScriptedMission\n[\n    \"desert_e\",\n    {\n        execVM \"\\ca\\missions_e\\data\\scenes\\credits1\\init.sqf\";\n    },\n    configFile / \"CfgMissions\" / \"Cutscenes\" / \"Credits\"\n];\n```","code":["playScriptedMission\n[\n\t\"desert_e\",\n\t{\n\t\texecVM \"\\ca\\missions_e\\data\\scenes\\credits1\\init.sqf\";\n\t},\n\tconfigFile / \"CfgMissions\" / \"Cutscenes\" / \"Credits\"\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hostMission","playMission","createMissionDisplay","createMPCampaignDisplay"],"notes":[{"user":"SkaceKachna","date":"2015-12-31T17:55:00Z","text":"For this command to work, you will need to:\n1. call command with ignoreChildWindow param set to true (in VBS docs its called fromMission)\n1. close any opened display (not sure about this part, but closing every display (but #0) seems to work):\n  - if mission is run from 2D editor, you can just close RscDisplayArcadeMap display (idd 26) (because this was done from 2D editor, so RscDisplayArcadeMap is still active in background -- benargee)\n  - if mission is run from single mission browser, you can just close RscDisplaySingleMission (idd 2)\n1. end mission\n\nDebriefing will show and player will be moved to new mission after clicking on Continue.\n\nCommand is a bit bugged:\n- third (config) param doesn't seem to work\n- if you run this command in mission loaded from pbo, said pbo won't be writable until you close the game (you can't update it)\n\nFollowing code will change change island to Stratis and spawns player as basic soldier at [0,0,0] coordinates.\n\n```sqf\ndisableSerialization;\nplayScriptedMission ['Stratis', {\n    private _grp = createGroup west;\n    private _player = _grp createUnit [\"B_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\n    selectPlayer _player;\n}, missionConfigFile, true];\n\n// Close all displays that could be the background display ... this is essentially forceEnd command\n// Closing #0 will cause game to fail\n_zero = findDisplay 0;\n{\n    if (_x != _zero) then {\n        _x closeDisplay 1;\n    };\n} foreach allDisplays;\nfailMission \"END1\";\n```\n\n(tested in Arma 3 1.54.133741)"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"playSound","operator":null,"title":"playSound","type":"command","url":"https://community.bistudio.com/wiki/playSound","revid":349659,"updated":"2023-11-18T17:02:31Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Plays a sound from CfgSounds. Sound can be defined in missionConfigFile, configFile or campaignConfigFile.","syntaxes":[{"syntax":"playSound soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Object","types":["Object"],"description":"the speaker object (Nothing before Arma 3 v2.00)","text":"Object - the speaker object (Nothing before Arma 3 v2.00)"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}},{"syntax":"playSound [soundName, isSpeech, offset]","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"},{"name":"isSpeech","type":"Boolean or Arma 3 v2.04 Number","optional":true,"default":"false","description":"0/false = play as sound (fadeSound applies)\n- 1/true = play as speech (fadeSpeech applies), filters are not applied to it (i.e. house or vehicle interior one)\n- 2 = play as sound (fadeSound applies) without interior/vehicle muffling","types":["Boolean","Number"],"since":null,"text":"isSpeech: Boolean or Arma 3 v2.04 Number - (Optional, default false)\n- 0/false = play as sound (fadeSound applies)\n- 1/true = play as speech (fadeSpeech applies), filters are not applied to it (i.e. house or vehicle interior one)\n- 2 = play as sound (fadeSound applies) without interior/vehicle muffling"},{"name":"offset","type":"Number","optional":true,"default":"0","description":"offset in seconds. Same as playMusic","types":["Number"],"since":"arma3 2.00","text":"offset: Number - (Optional, default 0) offset in seconds. Same as playMusic"}],"returns":{"type":"Object","types":["Object"],"description":"the speaker object (Nothing before Arma 3 v2.00)","text":"Object - the speaker object (Nothing before Arma 3 v2.00)"},"form":"unary","operator":null,"left":null,"right":{"text":"[soundName, isSpeech, offset]","types":["Array"]}}],"examples":[{"text":"```sqf\nplaySound \"soundname\";\n```","code":["playSound \"soundname\";"]},{"text":"Start a sound and then stop it after 1.2 second:\n\n```sqf\nplaySound \"AlarmCar\";\n0 spawn\n{\n    _sound = ASLToAGL [0,0,0] nearestObject \"#soundonvehicle\";\n    sleep 1.2;\n    deleteVehicle _sound;\n};\n\n// since Arma 3 v2.00\n_source = playSound \"AlarmCar\";\n_source spawn\n{\n    sleep 1.2;\n    deleteVehicle _this;\n};\n```","code":["playSound \"AlarmCar\";\n0 spawn\n{\n\t_sound = ASLToAGL [0,0,0] nearestObject \"#soundonvehicle\";\n\tsleep 1.2;\n\tdeleteVehicle _sound;\n};\n\n// since Arma 3 v2.00\n_source = playSound \"AlarmCar\";\n_source spawn\n{\n\tsleep 1.2;\n\tdeleteVehicle _this;\n};"]},{"text":"Start a sound and wait until it is finished:\n\n```sqf\nplaySound \"Alarm\";\nhint \"Started!\";\n0 spawn\n{\n    _sound = ASLToAGL [0,0,0] nearestObject \"#soundonvehicle\";\n    waitUntil {isNull _sound};\n    hint \"Finished!\";\n};\n\n// since Arma 3 v2.00\nprivate _source = playSound \"Alarm\";\n_source spawn\n{\n    waitUntil { isNull _this };\n    hint \"Finished!\";\n};\n```","code":["playSound \"Alarm\";\nhint \"Started!\";\n0 spawn\n{\n\t_sound = ASLToAGL [0,0,0] nearestObject \"#soundonvehicle\";\n\twaitUntil {isNull _sound};\n\thint \"Finished!\";\n};\n\n// since Arma 3 v2.00\nprivate _source = playSound \"Alarm\";\n_source spawn\n{\n\twaitUntil { isNull _this };\n\thint \"Finished!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playSound3D","sideRadio","say","playMusic","say2D","say3D","createSoundSource","playSoundUI"],"notes":[{"user":"Hardrock","date":"2006-08-04T10:57:00Z","text":"*Notes from before the conversion:*\n\nFor dialogue involving living units it is better to use say,\nplaySound will play a sound at the location of the player,\nsay will play a sound at the location of the unit that is speaking, and it will only play that sound if the unit is alive."},{"user":"PiZZADOX","date":"2014-12-28T08:22:00Z","text":"As you may have noticed, the parameter for playsound/say3d that deals with the \"volume\" of the sound played has little to do with the effective loudness heard in game. What it is alters is the drop off for fading the sound at a distance. A higher decibel or integer value will increase the distance before any sort of fading will take place. The actual volume of the sound file played will factor in to this, as it does throughout the playing action.\n==== Amplifying the Sound ====\nModifying the effective volume of sounds played by the engine is possible by \"spamming\" the sounds. By quickly playing the sounds overtop of one another, you can effectively amplify the volume\n\nThis example\n\n```sqf\nplaySound \"soundname\";\nplaySound \"soundname\";\n```\n\nWill effectively amplify the sound by a sensed 2x. The volume of the sound file itself will still affect the sound volume as it appears as though the arma engine has no normalization for sound files added to it.\n\n> [!NOTE]\n> This technique may cause issues in sound quality in large multiplayer servers. I observed multiple instances when a triggered sound amplified with this method was out of sync with each other. Timing of the individual commands sent over the network is probably the issue. Recommend you compile your amplification code into a single finished function for better syncing for clients not activating the action/far away from the activation position."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"playSound3D","operator":null,"title":"playSound3D","type":"command","url":"https://community.bistudio.com/wiki/playSound3D","revid":379065,"updated":"2026-09-24T20:28:32Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Plays positional sound with given *filename* on every computer on network. To stop the sound use stopSound","syntaxes":[{"syntax":"playSound3D [filename, soundSource, isInside, soundPosition, volume, soundPitch, distance, offset, local, loop]","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":"see Arma 3: Sound Files for available file names or #Example 3 to use mission files\n\n> [!IMPORTANT]\n> Since Arma 3 v2.10 the file name can start with a leading backslash `**\\**a3\\...`.\n>\n> However a leading backslash must **not** be used for an **addon** sound file.","types":["String"],"since":null,"text":"filename: String - see Arma 3: Sound Files for available file names or #Example 3 to use mission files\n\n> [!IMPORTANT]\n> Since Arma 3 v2.10 the file name can start with a leading backslash `**\\**a3\\...`.\n>\n> However a leading backslash must **not** be used for an **addon** sound file."},{"name":"soundSource","type":"Object","optional":false,"default":null,"description":"the object emitting the sound. If *soundPosition* below is specified this parameter is ignored","types":["Object"],"since":null,"text":"soundSource: Object - the object emitting the sound. If *soundPosition* below is specified this parameter is ignored"},{"name":"isInside","type":"Boolean","optional":true,"default":"false","description":"true to simulate a sound played inside a building or similar","types":["Boolean"],"since":null,"text":"isInside: Boolean - (Optional, default false) - true to simulate a sound played inside a building or similar"},{"name":"soundPosition","type":"PositionASL","optional":true,"default":"nil","description":"position for sound emitter, overrides *soundSource*. Object is also supported (see note below). Since Arma 3 v2.24 use nil to skip this param\n\n> [!NOTE]\n> If a following parameter has to be used, simply use `getPosASL _soundSource` for *soundPosition* instead of `_soundSource` for *soundSource*.\n\n> [!IMPORTANT]\n> This parameter also takes Object but their AGL position is used instead of ASL resulting in sound source being underground if they're above ground, always use PositionASL instead.","types":["PositionASL"],"since":null,"text":"soundPosition: PositionASL - (Optional, default nil) position for sound emitter, overrides *soundSource*. Object is also supported (see note below). Since Arma 3 v2.24 use nil to skip this param\n\n> [!NOTE]\n> If a following parameter has to be used, simply use `getPosASL _soundSource` for *soundPosition* instead of `_soundSource` for *soundSource*.\n\n> [!IMPORTANT]\n> This parameter also takes Object but their AGL position is used instead of ASL resulting in sound source being underground if they're above ground, always use PositionASL instead."},{"name":"volume","type":"Number","optional":true,"default":"1","description":"sound volume. A value greater than 5 gets capped","types":["Number"],"since":null,"text":"volume: Number - (Optional, default 1) sound volume. A value greater than 5 gets capped"},{"name":"soundPitch","type":"Number","optional":true,"default":"1","description":"1.0 → normal\n- 0.5 → Darth Vader\n- 2.0 → Chipmunks","types":["Number"],"since":null,"text":"soundPitch: Number - (Optional, default 1)\n- 1.0 → normal\n- 0.5 → Darth Vader\n- 2.0 → Chipmunks"},{"name":"distance","type":"Number","optional":true,"default":"0","description":"how far the sound is audible, in meters. `0` means no maximum distance","types":["Number"],"since":null,"text":"distance: Number - (Optional, default 0) how far the sound is audible, in meters. `0` means no maximum distance"},{"name":"offset","type":"Number","optional":true,"default":"0","description":"offset in seconds. Same as with playMusic (ignored if sound is set to play repeatedly, see 'loop')","types":["Number"],"since":"arma3 2.00","text":"offset: Number - (Optional, default 0) offset in seconds. Same as with playMusic (ignored if sound is set to play repeatedly, see 'loop')"},{"name":"local","type":"Boolean","optional":true,"default":"false","description":"if true the sound will not be broadcast over network","types":["Boolean"],"since":"arma3 2.06","text":"local: Boolean - (Optional, default false) if true the sound will not be broadcast over network"},{"name":"loop","type":"Boolean","optional":true,"default":"false","description":"if true the sound will repeat indefinitely. In MP, requires 'local' to be set to true. Use stopSound to stop.","types":["Boolean"],"since":"arma3 2.22","text":"loop: Boolean - (Optional, default false) if true the sound will repeat indefinitely. In MP, requires 'local' to be set to true. Use stopSound to stop."}],"returns":{"type":"Number","types":["Number"],"description":"id of the sound (0..65535) (was Nothing before Arma 3 v2.12)","text":"Number - id of the sound (0..65535) (was Nothing before Arma 3 v2.12)"},"form":"unary","operator":null,"left":null,"right":{"text":"[filename, soundSource, isInside, soundPosition, volume, soundPitch, distance, offset, local, loop]","types":["Array"]}}],"examples":[{"text":"```sqf\nplaySound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player];\n```","code":["playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player];"]},{"text":"```sqf\nplaySound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player, false, getPosASL player, 1, 1, 0];\n```","code":["playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player, false, getPosASL player, 1, 1, 0];"]},{"text":"```sqf\nplaySound3D [getMissionPath \"mySound.ogg\", player]; // to play a mission directory sound\n```","code":["playSound3D [getMissionPath \"mySound.ogg\", player]; // to play a mission directory sound"]},{"text":"Sound file extension must be specified even if a config entry has none:\n\n```sqf\nplaySound3D [\"A3\\Sounds_F\\sfx\\alarm_independent\", player];        // no sound\nplaySound3D [\"A3\\Sounds_F\\sfx\\alarm_independent.wss\", player];    // alarm\n```","code":["playSound3D [\"A3\\Sounds_F\\sfx\\alarm_independent\", player];\t\t// no sound\nplaySound3D [\"A3\\Sounds_F\\sfx\\alarm_independent.wss\", player];\t// alarm"]},{"text":"Example 2 from Arma 3 v2.24 \n\n```sqf\nplaySound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player, false, nil, 1, 1, 0];\n```","code":["playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player, false, nil, 1, 1, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["say3D","playSound","say2D","say","createSoundSource","setRandomLip","getMissionPath","playSoundUI","stopSound"],"notes":[{"user":"Killzone_Kid","date":"2014-09-26T09:18:00Z","text":"Currently, playSound3D is not JIP compatible, so joining players will not hear the sound if is started before and is still playing when player joins."},{"user":"Killzone_Kid","date":"2014-11-08T21:48:00Z","text":"When object is supplied but not a position, the position is taken from object, otherwise the position is taken from supplied position. That doesn't mean that when position is taken from object it is going to follow object when it changes position. The sound is generated at object position and it stays there.\n\nOne other important note: If *soundSource* param is objNull then this command develops the same bug with first person view as createSoundSource and say3D. If *soundSource* is player then the bug is inverted. It seems that passing vehicle player as *soundSource* param is the only way to make it behave correctly when vehicles involved."},{"user":"R3vo","date":"2020-10-07T12:24:00Z","text":"The sound will be distorted according to the <https://en.wikipedia.org/wiki/Doppler_effect> when passing by the sound source quickly."},{"user":"Hypoxic125","date":"2023-05-14T13:57:52Z","text":"Wait for sound to end:\n\n```sqf\nprivate _sound = playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player];\nwaitUntil { soundParams _sound isEqualTo [] };\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"playSoundUI","operator":null,"title":"playSoundUI","type":"command","url":"https://community.bistudio.com/wiki/playSoundUI","revid":376806,"updated":"2025-11-21T17:10:26Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Plays given CfgSounds sound or a sound file given by file path through a dedicated UI sound channel unaffected by the global mixer volumes. If the file path is given, the leading slash will be ignored. To stop the sound use stopSound","syntaxes":[{"syntax":"playSoundUI [sound, volume, soundPitch, isEffect, offset, loop]","since":null,"effect":null,"exec":null,"params":[{"name":"sound","type":"String","optional":false,"default":null,"description":"CfgSounds class or file as used in playSound3D (see Arma 3: Sound Files for available file names)","types":["String"],"since":null,"text":"sound: String - CfgSounds class or file as used in playSound3D (see Arma 3: Sound Files for available file names)"},{"name":"volume","type":"Number","optional":true,"default":"1","description":"sound volume clamped in range 0..5","types":["Number"],"since":null,"text":"volume: Number - (Optional, default 1) sound volume clamped in range 0..5"},{"name":"soundPitch","type":"Number","optional":true,"default":"1","description":"1.0 → normal\n- 0.5 → Darth Vader\n- 2.0 → Chipmunks","types":["Number"],"since":null,"text":"soundPitch: Number - (Optional, default 1)\n- 1.0 → normal\n- 0.5 → Darth Vader\n- 2.0 → Chipmunks"},{"name":"isEffect","type":"Boolean","optional":true,"default":"false","description":"if true, diverts sound through effects channel (see fadeSound, soundVolume)","types":["Boolean"],"since":null,"text":"isEffect: Boolean - (Optional, default false) if true, diverts sound through effects channel (see fadeSound, soundVolume)"},{"name":"offset","type":"Number","optional":true,"default":"0","description":"offset in seconds. Same as with playSound3D (ignored if sound is set to 'loop')","types":["Number"],"since":"arma3 2.12","text":"offset: Number - (Optional, default 0) offset in seconds. Same as with playSound3D (ignored if sound is set to 'loop')"},{"name":"loop","type":"Boolean","optional":true,"default":"false","description":"If true the sound will loop forever. Use stopSound to stop","types":["Boolean"],"since":"arma3 2.22","text":"loop: Boolean - (Optional, default false) If true the sound will loop forever. Use stopSound to stop"}],"returns":{"type":"Number","types":["Number"],"description":"id of the sound (0..65535) since Arma 3 v2.12 (was Nothing before that)","text":"Number - id of the sound (0..65535) since Arma 3 v2.12 (was Nothing before that)"},"form":"unary","operator":null,"left":null,"right":{"text":"[sound, volume, soundPitch, isEffect, offset, loop]","types":["Array"]}}],"examples":[{"text":"```sqf\nplaySoundUI [\"Alarm\", 0.5, 0.5];\n```","code":["playSoundUI [\"Alarm\", 0.5, 0.5];"]},{"text":"```sqf\nplaySoundUI [\"A3\\Sounds_F\\sfx\\blip1.wss\"];\n```","code":["playSoundUI [\"A3\\Sounds_F\\sfx\\blip1.wss\"];"]},{"text":"Sound file extension must be specified even if a config entry has none:\n\n```sqf\nplaySoundUI [\"A3\\Sounds_F\\sfx\\alarm_independent\", 5, 1];        // no sound\nplaySoundUI [\"A3\\Sounds_F\\sfx\\alarm_independent.wss\", 5, 1];    // alarm\n```","code":["playSoundUI [\"A3\\Sounds_F\\sfx\\alarm_independent\", 5, 1];\t\t// no sound\nplaySoundUI [\"A3\\Sounds_F\\sfx\\alarm_independent.wss\", 5, 1];\t// alarm"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["stopSound","soundParams","say3D","playSound","say2D","say","createSoundSource","setRandomLip","getMissionPath","playSound3D"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"pose","operator":null,"title":"pose","type":"command","url":"https://community.bistudio.com/wiki/pose","revid":351637,"updated":"2023-12-12T20:33:12Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the pose of the given unit.","syntaxes":[{"syntax":"pose unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"can be one of: - `\"Dead\"` - `\"Weapon\"` (special weapon - AT) - `\"BinocLying\"` - `\"LyingNoWeapon\"` - `\"Lying\"` - `\"HandGunLying\"` - `\"Crouch\"` - `\"HandGunCrouch\"` - `\"Combat\"` - `\"HandGunStand\"` - `\"Stand\"` - `\"Swimming\"` - `\"BottomSwimming\"` - `\"SurfaceSwimming\"` - `\"Diving\"` - `\"BottomDiving\"` - `\"SurfaceDiving\"` - `\"NoWeapon\"` (civilian moves) - `\"Binoc\"` (binocular pose) - `\"BinocStand\"` (binocular pose (weapon on back)) - `\"Healing\"` - `\"Dragged\"` - `\"Carrying\"` - `\"Freefall\"`","text":"String - can be one of:\n- `\"Dead\"`\n- `\"Weapon\"` (special weapon - AT)\n- `\"BinocLying\"`\n- `\"LyingNoWeapon\"`\n- `\"Lying\"`\n- `\"HandGunLying\"`\n- `\"Crouch\"`\n- `\"HandGunCrouch\"`\n- `\"Combat\"`\n- `\"HandGunStand\"`\n- `\"Stand\"`\n- `\"Swimming\"`\n- `\"BottomSwimming\"`\n- `\"SurfaceSwimming\"`\n- `\"Diving\"`\n- `\"BottomDiving\"`\n- `\"SurfaceDiving\"`\n- `\"NoWeapon\"` (civilian moves)\n- `\"Binoc\"` (binocular pose)\n- `\"BinocStand\"` (binocular pose (weapon on back))\n- `\"Healing\"`\n- `\"Dragged\"`\n- `\"Carrying\"`\n- `\"Freefall\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (pose player == \"SurfaceSwimming\") then { hint \"How's water?\" };\n```","code":["if (pose player == \"SurfaceSwimming\") then { hint \"How's water?\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationState","unitPos","stance","getLeaning"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"position","operator":null,"title":"position","type":"command","url":"https://community.bistudio.com/wiki/position","revid":377525,"updated":"2026-01-02T06:52:45Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns position of an object (alias of getPos) or location (alias of locationPosition).\n\n> [!IMPORTANT]\n> Do **not** use this command to get an object's position in 3D. See getPos for an explanation and alternatives.","syntaxes":[{"syntax":"position object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"PositionAGLS","types":["PositionAGLS"],"description":null,"text":"PositionAGLS"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"position location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"see locationPosition > [!IMPORTANT] > This position is the location's position regardless of attachObject usage - see #Example 3.","text":"PositionAGL - see locationPosition\n\n> [!IMPORTANT]\n> This position is the location's position **regardless of attachObject usage** - see #Example 3."},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\nprivate _pos = position player;\n```","code":["private _pos = position player;"]},{"text":"```sqf\n_myLocationHomePos = position myLocation;\n```","code":["_myLocationHomePos = position myLocation;"]},{"text":"```sqf\nprivate _location = createLocation [\"b_inf\", [1000, 1000], 1, 1];\n_location attachObject player;\nlocationPosition _location;    // [1916.03,5711.98,12.208]\ngetPos _location;            // [1916.03,5711.98,12.208]\nposition _location;            // [1000,1000,0]\n```","code":["private _location = createLocation [\"b_inf\", [1000, 1000], 1, 1];\n_location attachObject player;\nlocationPosition _location;\t// [1916.03,5711.98,12.208]\ngetPos _location;\t\t\t// [1916.03,5711.98,12.208]\nposition _location;\t\t\t// [1000,1000,0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPos","getPosATL","getPosASL","getPosASLW","visiblePosition","getPosVisual","visiblePositionASL","locationPosition"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint version","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"positionCameraToWorld","operator":null,"title":"positionCameraToWorld","type":"command","url":"https://community.bistudio.com/wiki/positionCameraToWorld","revid":378531,"updated":"2026-05-04T02:19:23Z","groups":["Camera Control","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the world coordinate space (AGL) from a camera-relative position.","syntaxes":[{"syntax":"positionCameraToWorld cameraPos","since":null,"effect":null,"exec":null,"params":[{"name":"cameraPos","type":"PositionRelative","optional":false,"default":null,"description":"relative camera position, format **[x, z, y]** (X = left-right, Z = below-above, Y = back-front)\n\n> [!IMPORTANT]\n> This command has Y and Z axes swapped around, which is different from the usual model space coordinates format ([x, y, z]).","types":["PositionRelative"],"since":null,"text":"cameraPos: PositionRelative - relative camera position, format **[x, z, y]** (X = left-right, Z = below-above, Y = back-front)\n\n> [!IMPORTANT]\n> This command has Y and Z axes swapped around, which is different from the usual model space coordinates format ([x, y, z])."}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"camera world position","text":"PositionAGL - camera world position"},"form":"unary","operator":null,"left":null,"right":{"text":"cameraPos","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\n_worldPos = positionCameraToWorld _cameraPos;\n```","code":["_worldPos = positionCameraToWorld _cameraPos;"]},{"text":"Example demonstrating reversed Y and Z:\n\n```sqf\nplayer setDir 0; // assuming player is looking forward\nhint str [positionCameraToWorld [0,0,0], positionCameraToWorld [0,0,1]];\n/*\n[\n    [2481.35, 5671.21, 1.51395],\n    [2481.35, 5672.21, 1.46955]\n]\n*/\n```","code":["player setDir 0; // assuming player is looking forward\nhint str [positionCameraToWorld [0,0,0], positionCameraToWorld [0,0,1]];\n/*\n[\n\t[2481.35, 5671.21, 1.51395],\n\t[2481.35, 5672.21, 1.46955]\n]\n*/"]},{"text":"```sqf\n_cameraAGLPosition = positionCameraToWorld [0,0,0];\n```","code":["_cameraAGLPosition = positionCameraToWorld [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["modelToWorld","modelToWorldVisual","getCameraViewDirection","weaponDirection","eyeDirection","vectorDir","vectorDirVisual"],"notes":[{"user":"Kronzky","date":"2008-10-17T11:25:00Z","text":"By measuring the distance between the camera and the player one can determine whether 1st-person or 3rd-person view is being used:\n\n```sqf\nif ((positionCameraToWorld [0,0,0] distance player)>2) then { hint \"3rd person\" } else { hint \"1st person\" };\n```"},{"user":"Worldeater","date":"2010-10-17T22:45:00Z","text":"The camera coordinate system is different from the model coordinate system: when modelToWorld uses [x, y, z] then positionCameraToWorld uses [x, z, y]. So for a steady camera the following is true:\n\n```sqf\npositionCameraToWorld [5,10,15] == _camera modelToWorld [5,15,10];\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"posScreenToWorld","operator":null,"title":"posScreenToWorld","type":"command","url":"https://community.bistudio.com/wiki/posScreenToWorld","revid":377564,"updated":"2026-01-02T06:55:27Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts map screen coordinates into world coordinates. Unlike ctrlMapScreenToWorld, this command returns world position is format [x, y, 0], otherwise it is identical to it.","syntaxes":[{"syntax":"map posScreenToWorld [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"map: Control - map control"},{"name":"x","type":"Number","optional":false,"default":null,"description":"screen X","types":["Number"],"since":null,"text":"x: Number - screen X"},{"name":"y","type":"Number","optional":false,"default":null,"description":"screen Y","types":["Number"],"since":null,"text":"y: Number - screen Y"}],"returns":{"type":"Position3D","types":["Position3D"],"description":"world position in format [x,y,0]","text":"Position3D - world position in format [x,y,0]"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\n_worldCoord = _control posScreenToWorld _ScreenCoord;\n```","code":["_worldCoord = _control posScreenToWorld _ScreenCoord;"]},{"text":"```sqf\n_worldCoord = _control posScreenToWorld [_x, _y];\n```","code":["_worldCoord = _control posScreenToWorld [_x, _y];"]},{"text":"```sqf\n_worldCoord = _control posScreenToWorld [0.5, 0.5];\n```","code":["_worldCoord = _control posScreenToWorld [0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["posWorldToScreen","ctrlMapScreenToWorld","ctrlMapWorldToScreen"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"posWorldToScreen","operator":null,"title":"posWorldToScreen","type":"command","url":"https://community.bistudio.com/wiki/posWorldToScreen","revid":377539,"updated":"2026-01-02T06:54:25Z","groups":["GUI Control - Map","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts world coordinates into map screen coordinates. This command is identical to ctrlMapWorldToScreen.","syntaxes":[{"syntax":"map posWorldToScreen position","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":"map control","types":["Control"],"since":null,"text":"map : Control - map control"},{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"world position","types":["Position2D","Position3D"],"since":null,"text":"position : Position2D or Position3D - world position"}],"returns":{"type":"Position2D","types":["Position2D"],"description":"screen coordinates in format [x, y]","text":"Position2D - screen coordinates in format [x, y]"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"position","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_screenCoord = _control posWorldToScreen _worldCoord;\n```","code":["_screenCoord = _control posWorldToScreen _worldCoord;"]},{"text":"```sqf\n_screenCoord = _control posWorldToScreen position player;\n```","code":["_screenCoord = _control posWorldToScreen position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["posScreenToWorld","ctrlMapWorldToScreen"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Map","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectAdjust","operator":null,"title":"ppEffectAdjust","type":"command","url":"https://community.bistudio.com/wiki/ppEffectAdjust","revid":377096,"updated":"2026-01-01T09:56:04Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set post process effect parameters.\n\n> [!NOTE]\n> The two syntaxes differ in what format of the params they accept. The syntax with PP name expects colors to be packed into arrays within main array, while the syntax with PP handle can handle both flat and packed array. Therefore it is recommended to use the universal packed format, such as shown in the examples.","syntaxes":[{"syntax":"effect ppEffectAdjust settings","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"String or Number","optional":false,"default":null,"description":"String or Number\n- String - effect name\n- Number - effect handle","types":["String","Number"],"since":null,"text":"effect: String or Number\n- String - effect name\n- Number - effect handle"},{"name":"settings","type":"Array of Anything","optional":false,"default":null,"description":"array of effect params","types":["Array","Anything"],"since":null,"text":"settings: Array of Anything - array of effect params"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"effect","types":["String","Number"]},"right":{"text":"settings","types":["Array","Anything"]}},{"syntax":"","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n\"colorCorrections\" ppEffectAdjust [1, 1, -0.01, [0, 0, 0, 0], [1.5, 1, 1.2, 0.6], [0.199, 0.587, 0.114, 0]];\n```","code":["\"colorCorrections\" ppEffectAdjust [1, 1, -0.01, [0, 0, 0, 0], [1.5, 1, 1.2, 0.6], [0.199, 0.587, 0.114, 0]];"]},{"text":"Black&White:\n\n```sqf\n_colorCorrectionsEffHandle ppEffectAdjust [1, 0.4, 0, [0, 0, 0, 0], [1, 1, 1, 0], [1, 1, 1, 0]];\n```","code":["_colorCorrectionsEffHandle ppEffectAdjust [1, 0.4, 0, [0, 0, 0, 0], [1, 1, 1, 0], [1, 1, 1, 0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectEnabled","ppEffectDestroy","ppEffectCreate","ppEffectCommitted","ppEffectCommit","setPiPEffect"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectCommit","operator":null,"title":"ppEffectCommit","type":"command","url":"https://community.bistudio.com/wiki/ppEffectCommit","revid":327517,"updated":"2022-07-12T22:25:19Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Commit post process effect in given time.","syntaxes":[{"syntax":"effect ppEffectCommit commit","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"String","optional":false,"default":null,"description":"name of the effect","types":["String"],"since":null,"text":"effect: String - name of the effect"},{"name":"commit","type":"Number","optional":false,"default":null,"description":"duration","types":["Number"],"since":null,"text":"commit: Number - duration"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"effect","types":["String"]},"right":{"text":"commit","types":["Number"]}},{"syntax":"handle ppEffectCommit commit","since":null,"effect":null,"exec":null,"params":[{"name":"handle","type":"Number","optional":false,"default":null,"description":"handle of the effect","types":["Number"],"since":null,"text":"handle: Number - handle of the effect"},{"name":"commit","type":"Number","optional":false,"default":null,"description":"duration","types":["Number"],"since":null,"text":"commit: Number - duration"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"handle","types":["Number"]},"right":{"text":"commit","types":["Number"]}},{"syntax":"handles ppEffectCommit commit","since":null,"effect":null,"exec":null,"params":[{"name":"handles","type":"Array of Numbers","optional":false,"default":null,"description":"list of handles","types":["Array","Number"],"since":null,"text":"handles: Array of Numbers - list of handles"},{"name":"commit","type":"Number","optional":false,"default":null,"description":"duration","types":["Number"],"since":null,"text":"commit: Number - duration"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"handles","types":["Array","Number"]},"right":{"text":"commit","types":["Number"]}}],"examples":[{"text":"```sqf\n\"colorCorrection\" ppEffectCommit 3;\n```","code":["\"colorCorrection\" ppEffectCommit 3;"]},{"text":"```sqf\n_hndl ppEffectCommit 3;\n```","code":["_hndl ppEffectCommit 3;"]},{"text":"```sqf\n[_hndl1, _hndl2] ppEffectCommit 3;\n```","code":["[_hndl1, _hndl2] ppEffectCommit 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectEnabled","ppEffectDestroy","ppEffectCreate","ppEffectCommitted","ppEffectAdjust"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectCommitted","operator":null,"title":"ppEffectCommitted","type":"command","url":"https://community.bistudio.com/wiki/ppEffectCommitted","revid":348518,"updated":"2023-11-08T13:06:00Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check whether given post process effect is committed.","syntaxes":[{"syntax":"ppEffectCommitted effect","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"String","optional":false,"default":null,"description":"effect name","types":["String"],"since":null,"text":"effect: String - effect name"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"effect","types":["String"]}},{"syntax":"ppEffectCommitted handle","since":null,"effect":null,"exec":null,"params":[{"name":"handle","type":"Number","optional":false,"default":null,"description":"effect handle","types":["Number"],"since":null,"text":"handle: Number - effect handle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"handle","types":["Number"]}}],"examples":[{"text":"```sqf\nppEffectCommitted \"colorCorrection\";\n```","code":["ppEffectCommitted \"colorCorrection\";"]},{"text":"```sqf\nppEffectCommitted _hndl;\n```","code":["ppEffectCommitted _hndl;"]},{"text":"```sqf\nif (ppEffectCommitted \"colorCorrection\") then { hint \"alteration done !\" };\n```","code":["if (ppEffectCommitted \"colorCorrection\") then { hint \"alteration done !\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectDestroy","ppEffectCreate","ppEffectCommit","ppEffectAdjust"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectCreate","operator":null,"title":"ppEffectCreate","type":"command","url":"https://community.bistudio.com/wiki/ppEffectCreate","revid":376949,"updated":"2025-12-31T23:30:11Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates Post Process Effects specified by effect name and priority.\n\nSupported effects:\n- \"RadialBlur\"\n- \"ChromAberration\"\n- \"WetDistortion\"\n- \"ColorCorrections\"\n- \"DynamicBlur\"\n- \"FilmGrain\"\n- \"ColorInversion\"\n- \"SSAO\"\n- \"Resolution\"","syntaxes":[{"syntax":"ppEffectCreate [name, priority]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"name of effect type","types":["String"],"since":null,"text":"name: String - name of effect type"},{"name":"priority","type":"Number","optional":false,"default":null,"description":"unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail","types":["Number"],"since":null,"text":"priority: Number - unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail"}],"returns":{"type":"Number","types":["Number"],"description":"handle or -1 if failed","text":"Number - handle or -1 if failed"},"form":"unary","operator":null,"left":null,"right":{"text":"[name, priority]","types":["Array"]}},{"syntax":"ppEffectCreate [[name1, priority1], ...]","since":null,"effect":null,"exec":null,"params":[{"name":"nameN","type":"String","optional":false,"default":null,"description":"name of effect type","types":["String"],"since":null,"text":"nameN: String - name of effect type"},{"name":"priorityN","type":"Number","optional":false,"default":null,"description":"unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail","types":["Number"],"since":null,"text":"priorityN: Number - unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail"}],"returns":{"type":"Array of Numbers or Nothing if failed","types":["Array","Number","Nothing"],"description":null,"text":"Array of Numbers or Nothing if failed"},"form":"unary","operator":null,"left":null,"right":{"text":"[[name1, priority1], ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ppGrain = ppEffectCreate [\"filmGrain\", 2005];\n```","code":["_ppGrain = ppEffectCreate [\"filmGrain\", 2005];"]},{"text":"If an effect ID is already used, the effect is not created. Use the following:\n\n```sqf\nprivate _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwhile\n{\n    _handle = ppEffectCreate [_name, _priority];\n    _handle < 0;\n} do {\n    _priority = _priority + 1;\n};\n\n// _handle can be used here as usual\n```\n\nor\n\n```sqf\nprivate _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwaitUntil { _handle = ppEffectCreate [_name, _priority]; _priority = _priority + 1; _handle > 0; };\n\n// _handle can be used here as usual\n```","code":["private _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwhile\n{\n\t_handle = ppEffectCreate [_name, _priority];\n\t_handle < 0;\n} do {\n\t_priority = _priority + 1;\n};\n\n// _handle can be used here as usual","private _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwaitUntil { _handle = ppEffectCreate [_name, _priority]; _priority = _priority + 1; _handle > 0; };\n\n// _handle can be used here as usual"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectEnabled","ppEffectDestroy","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[{"user":"Lou Montana","date":"2009-06-29T22:33:00Z","text":"For some examples, check [this forums' topic](http://forums.bistudio.com/showthread.php?t=75528)."},{"user":"Raymix (DayZ)","date":"2015-06-24T04:08:00Z","text":"\"wetDistortion\" only works if handle is used."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectDestroy","operator":null,"title":"ppEffectDestroy","type":"command","url":"https://community.bistudio.com/wiki/ppEffectDestroy","revid":330371,"updated":"2022-09-04T20:26:39Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Destroy Post Process Effects given by handle or array of handles.","syntaxes":[{"syntax":"ppEffectDestroy effect","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"Number","optional":false,"default":null,"description":"effect handle","types":["Number"],"since":null,"text":"effect: Number - effect handle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"effect","types":["Number"]}},{"syntax":"ppEffectDestroy effects","since":null,"effect":null,"exec":null,"params":[{"name":"effects","type":"Array of Numbers","optional":false,"default":null,"description":"array of effect handles","types":["Array","Number"],"since":null,"text":"effects: Array of Numbers - array of effect handles"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"effects","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nppEffectDestroy _hndl;\n```","code":["ppEffectDestroy _hndl;"]},{"text":"```sqf\nppEffectDestroy [_hndl0, _hndl1, _hndl2];\n```","code":["ppEffectDestroy [_hndl0, _hndl1, _hndl2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectEnabled","ppEffectCreate","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectEnable","operator":null,"title":"ppEffectEnable","type":"command","url":"https://community.bistudio.com/wiki/ppEffectEnable","revid":363568,"updated":"2024-04-07T08:27:59Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable / disable Post Process Effects\n\n> [!IMPORTANT]\n> If effect fails to get enabled (can check it with ppEffectEnabled) try adding a little sleep in front of it.","syntaxes":[{"syntax":"effect ppEffectEnable enable","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"String","optional":false,"default":null,"description":"name of the effect","types":["String"],"since":null,"text":"effect: String - name of the effect"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"effect","types":["String"]},"right":{"text":"enable","types":["Boolean"]}},{"syntax":"effect ppEffectEnable enable","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"Number","optional":false,"default":null,"description":"handle of the effect","types":["Number"],"since":null,"text":"effect: Number - handle of the effect"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"effect","types":["Number"]},"right":{"text":"enable","types":["Boolean"]}},{"syntax":"effectArray ppEffectEnable enable","since":null,"effect":null,"exec":null,"params":[{"name":"effectArray","type":"Array of Numbers","optional":false,"default":null,"description":"array of effect handles","types":["Array","Number"],"since":null,"text":"effectArray: Array of Numbers - array of effect handles"},{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"effectArray","types":["Array","Number"]},"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\n\"colorCorrections\" ppEffectEnable true;\n```","code":["\"colorCorrections\" ppEffectEnable true;"]},{"text":"```sqf\n_hndl ppEffectEnable true;\n```","code":["_hndl ppEffectEnable true;"]},{"text":"```sqf\n[_hndl1, _hndl2] ppEffectEnable true;\n```","code":["[_hndl1, _hndl2] ppEffectEnable true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectDestroy","ppEffectCreate","ppEffectEnabled","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[{"user":"Pi123263","date":"2024-04-06T13:32:57Z","text":"Using ppEffectEnable immediatelly enables/disables the effect. If you want the effect to fade in/out it might be better to use ppEffectAdjust.\n\nIf you want to fade out an effect using ppEffectAdjust you can set the values for the command back to the default and then use ppEffectCommit to set the time for the fadeout.\n\nExample:\nActivate effect:\n\n```sqf\n\"colorCorrections\" ppEffectAdjust [1,1,0,[0,0,0,0],[0,0,0,0.24],[1,1,1,0],[0.6,0.5,0,0,-0.1,0.4,0.8]]; \n\"colorCorrections\" ppEffectEnable true; \n\"colorCorrections\" ppEffectCommit 0;\n```\n\nAnd then fade the effect out over 10 seconds:\n\n```sqf\n\"colorCorrections\" ppEffectAdjust [1,1,0,[0,0,0,0],[1,1,1,1],[0.299, 0.587, 0.114, 0],[-1,-1,0,0,0,0,0]]; \n\"colorCorrections\" ppEffectCommit 10;\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ppEffectEnabled","operator":null,"title":"ppEffectEnabled","type":"command","url":"https://community.bistudio.com/wiki/ppEffectEnabled","revid":327511,"updated":"2022-07-12T22:24:54Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether given post process effect is enabled","syntaxes":[{"syntax":"ppEffectEnabled effect","since":null,"effect":null,"exec":null,"params":[{"name":"effect","type":"Number","optional":false,"default":null,"description":"effect handle","types":["Number"],"since":null,"text":"effect: Number - effect handle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"effect","types":["Number"]}},{"syntax":"ppEffectEnabled effect","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"effect","type":"String","optional":false,"default":null,"description":"effect name","types":["String"],"since":null,"text":"effect: String - effect name"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"effect","types":["String"]}}],"examples":[{"text":"```sqf\n_enabled = ppEffectEnabled _hndl;\n```","code":["_enabled = ppEffectEnabled _hndl;"]},{"text":"```sqf\n_enabled = ppEffectEnabled \"DynamicBlur\";\n```","code":["_enabled = ppEffectEnabled \"DynamicBlur\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectDestroy","ppEffectEnable","ppEffectCreate","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"ppEffectForceInNVG","operator":null,"title":"ppEffectForceInNVG","type":"command","url":"https://community.bistudio.com/wiki/ppEffectForceInNVG","revid":348736,"updated":"2023-11-08T14:32:10Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Forces use of Post Process Effects in NVG.","syntaxes":[{"syntax":"ppHandle ppEffectForceInNVG force","since":null,"effect":null,"exec":null,"params":[{"name":"ppHandle","type":"Number","optional":false,"default":null,"description":"handle of the post processing returned by ppEffectCreate","types":["Number"],"since":null,"text":"ppHandle: Number - handle of the post processing returned by ppEffectCreate"},{"name":"force","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"force: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ppHandle","types":["Number"]},"right":{"text":"force","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_ppGrain ppEffectForceInNVG true;\n```","code":["_ppGrain ppEffectForceInNVG true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Post Process Effects","ppEffectEnable","ppEffectEnabled","ppEffectDestroy","ppEffectCreate","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"precision","operator":null,"title":"precision","type":"command","url":"https://community.bistudio.com/wiki/precision","revid":369414,"updated":"2024-09-03T18:46:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the movement precision of the given entity, how is the entity able to be precise when moving to given target.\n\n> [!NOTE]\n> See CfgVehicles Config Reference#precision.","syntaxes":[{"syntax":"precision entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"}],"returns":{"type":"Number","types":["Number"],"description":"accuracy in metres","text":"Number - accuracy in metres"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\n// used in formationCDanger.fsm\nif (getPosATL _this distance _dangerPos <= precision _this) then { /* ... */ };\n```","code":["// used in formationCDanger.fsm\nif (getPosATL _this distance _dangerPos <= precision _this) then { /* ... */ };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["visiblePositionASL"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preloadCamera","operator":null,"title":"preloadCamera","type":"command","url":"https://community.bistudio.com/wiki/preloadCamera","revid":377505,"updated":"2026-01-02T06:50:05Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Preload all textures and models around given Position to avoid visual artifacts after camera is moved.\n\nShould be used before any abrupt camera change/cut.\n\nReturns true once all data is ready. See camPreload for alternative, more flexible camera preloading.","syntaxes":[{"syntax":"preloadCamera position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position"]}}],"examples":[{"text":"```sqf\nwaitUntil { preloadCamera markerPos \"cam_location_2\" };\n```","code":["waitUntil { preloadCamera markerPos \"cam_location_2\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camPreload","camPreloaded"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preloadObject","operator":null,"title":"preloadObject","type":"command","url":"https://community.bistudio.com/wiki/preloadObject","revid":369157,"updated":"2024-09-03T10:34:40Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Preloads all textures, materials and proxies needed to render given object. Works with objects and classnames - note that classnames require an object instance in the mission.","syntaxes":[{"syntax":"distance preloadObject object","since":null,"effect":null,"exec":null,"params":[{"name":"distance","type":"Number","optional":false,"default":null,"description":"distance at which preload the object","types":["Number"],"since":null,"text":"distance: Number -  distance at which preload the object"},{"name":"object","type":"Object or String","optional":false,"default":null,"description":"Object or String\n- Object - existing object\n- String - object classname - an object of that type **must** exist in the mission for it to have effect","types":["Object","String"],"since":null,"text":"object: Object or String\n- Object - existing object\n- String - object classname - an object of that type **must** exist in the mission for it to have effect"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when preload is finished","text":"Boolean - true when preload is finished"},"form":"binary","operator":null,"left":{"text":"distance","types":["Number"]},"right":{"text":"object","types":["Object","String"]}}],"examples":[{"text":"```sqf\n0 spawn \n{\n    waitUntil { 10 preloadObject \"SoldierW\" };\n    hint \"Preload finished\";\n};\n```","code":["0 spawn \n{\n\twaitUntil { 10 preloadObject \"SoldierW\" };\n\thint \"Preload finished\";\n};"]},{"text":"```sqf\n0 spawn \n{\n    waitUntil { 10 preloadObject leader player };\n    hint \"Preload finished\";\n};\n```","code":["0 spawn \n{\n\twaitUntil { 10 preloadObject leader player };\n\thint \"Preload finished\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["preloadCamera","preloadSound","preloadTitleObj","preloadTitleRsc"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preloadSound","operator":null,"title":"preloadSound","type":"command","url":"https://community.bistudio.com/wiki/preloadSound","revid":376517,"updated":"2025-10-22T23:11:17Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Makes sure that a sound can start playing without any delay once it is needed.\nCommand works in Arma 3 but might not be implemented in earlier Arma installments.","syntaxes":[{"syntax":"preloadSound soundName","since":null,"effect":null,"exec":null,"params":[{"name":"soundName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"soundName: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"soundName","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _sounds = getArray (missionConfigFile >> \"CfgSounds\" >> \"sounds\");\nwaitUntil { _sounds findIf { !(preloadSound _x) } == -1 };\n```","code":["private _sounds = getArray (missionConfigFile >> \"CfgSounds\" >> \"sounds\");\nwaitUntil { _sounds findIf { !(preloadSound _x) } == -1 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["preloadTitleRsc"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preloadTitleObj","operator":null,"title":"preloadTitleObj","type":"command","url":"https://community.bistudio.com/wiki/preloadTitleObj","revid":363768,"updated":"2024-04-19T08:56:31Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Preloads data for the given resource object.","syntaxes":[{"syntax":"preloadTitleObj [name, type, speed, showInMap]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"defined in `configFile >> \"CfgTitles\" >> name`","types":["String"],"since":null,"text":"name: String - defined in `configFile >> \"CfgTitles\" >> name`"},{"name":"type","type":"String","optional":false,"default":null,"description":"see Title Effect Types","types":["String"],"since":null,"text":"type: String - see Title Effect Types"},{"name":"speed","type":"Number","optional":true,"default":"-1","description":null,"types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1)"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":null,"types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[name, type, speed, showInMap]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ok = preloadTitleObj [\"BISLogo\", \"PLAIN\"];\n```","code":["_ok = preloadTitleObj [\"BISLogo\", \"PLAIN\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cutObj"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preloadTitleRsc","operator":null,"title":"preloadTitleRsc","type":"command","url":"https://community.bistudio.com/wiki/preloadTitleRsc","revid":322925,"updated":"2022-06-28T21:42:39Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Resource title - preload data. The resource can be defined in the Description.ext file.","syntaxes":[{"syntax":"preloadTitleRsc [name, type, speed, showInMap]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"defined in Description.ext for the mission","types":["String"],"since":null,"text":"name: String - defined in Description.ext for the mission"},{"name":"type","type":"String","optional":false,"default":null,"description":"e.g \"PLAIN\"","types":["String"],"since":null,"text":"type: String - e.g \"PLAIN\""},{"name":"speed","type":"Number","optional":true,"default":null,"description":"ignored","types":["Number"],"since":null,"text":"speed: Number - (Optional) ignored"},{"name":"showInMap","type":"Boolean","optional":true,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[name, type, speed, showInMap]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ok = preloadTitleRsc [\"BIS\", \"PLAIN\"];\n```","code":["_ok = preloadTitleRsc [\"BIS\", \"PLAIN\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preprocessFile","operator":null,"title":"preprocessFile","type":"command","url":"https://community.bistudio.com/wiki/preprocessFile","revid":349792,"updated":"2023-11-20T22:10:15Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Reads and processes the content of the specified file. Preprocessor is C-like, supports comments using `//` or `/*` and `- /` and PreProcessor Commands.\nDue to the hard-drive access this command executes and the lack of caching this command should not be used in time-critical script loops.\n\n> [!WARNING]\n> If the file you are loading is not prepared using UTF-8 encoding and contains some characters with codes > 127, they might convert incorrectly.","syntaxes":[{"syntax":"preprocessFile fileName","since":null,"effect":null,"exec":null,"params":[{"name":"fileName","type":"String","optional":false,"default":null,"description":"path to the file and name of the file","types":["String"],"since":null,"text":"fileName: String - path to the file and name of the file"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\n_content = preprocessFile \"myFunction.sqf\";\n```","code":["_content = preprocessFile \"myFunction.sqf\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fileExists","preprocessFileLineNumbers","loadFile","Function","SQF Syntax","call","spawn","execVM","PreProcessor Commands"],"notes":[{"user":"Alef","date":"2008-03-04T22:35:00Z","text":"File path is always relative to mission directory. If script dir\\a.sqf includes dir\\b.sqf, use \"dir\\b.sqf\" and not \"b.sqf\"."},{"user":"Kju","date":"2011-07-08T10:59:00Z","text":"Use preprocessFileLineNumbers instead as it provides more context information on error."},{"user":"Killzone_Kid","date":"2013-12-17T13:44:00Z","text":"The main difference between preprocessFile and preprocessFileLineNumbers is that the latter adds #line directive to the target file, which allows to log the `__LINE__` error happened at and the `__FILE__` error happened in."},{"user":"BrotherhoodOfHam","date":"2014-07-25T18:43:00Z","text":"Essentially what the preprocessFile command does is it refers to the contents of a file as a string:\n\nExample 1:\n\nboop.html:\n\n```html\n<t align = 'center' valign = 'middle' shadow = '0' size = '2'>structured text</t>\n```\n\ninit.sqf:\n\n```sqf\n_text = parseText preprocessFile \"boop.html\";\nhint _text;\n```\n\nThis is especially useful for long strings, and it works on files with any file extension as long as they can be edited with a text editor.\n\nExample 2:\n\ninit.sqf:\n\n```sqf\nhint preprocessFile \"description.ext\";\ncopyToClipboard preprocessFile \"mission.sqm\";\n```\n\nThe above is all valid. However, using *.jpg or any other files saved in an image format is not possible."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"preprocessFileLineNumbers","operator":null,"title":"preprocessFileLineNumbers","type":"command","url":"https://community.bistudio.com/wiki/preprocessFileLineNumbers","revid":364516,"updated":"2024-05-16T20:46:22Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the preprocessed content of the given file. The preprocessor is C-like, it supports comments using /* */ and PreProcessor Commands. The preprocessor also adds a default debug entrypoint for compiler at the begining of script: `1. line 1 \"aFilename\"`\n\nThe **#line** keyword can be used in any script that are not preprocess, or with preprocess script with extra macro to protect reserverd sharp character. The format is:\n\n`**#line** <number> \"<name>\"`\n\nfollowed by new line. <number> could be only positive integer and <name> could be any name. This will be used only if an error occurs in the script. The error will contain the line:\n`File <filename>, line <linenumber>`\n\nwhere <filename> will be the <name> you set and <linenumber> will be <number> + how many lines it is from the **#line** line. If the error happened on the line right under **#line** it will add 0 to <number>, if on second line, it will add 1 etc.\n\nIt is possible to use more than one **#line** keywords, but it seems having just one at the top for little script is enough to pinpoint position of the error easily.\n\n> [!WARNING]\n> If the file you are loading is not prepared using UTF-8 encoding and contains some characters with codes > 127, they might convert incorrectly","syntaxes":[{"syntax":"preprocessFileLineNumbers fileName","since":null,"effect":null,"exec":null,"params":[{"name":"fileName","type":"String","optional":false,"default":null,"description":"path to the file","types":["String"],"since":null,"text":"fileName: String - path to the file"}],"returns":{"type":"String","types":["String"],"description":"file content containing `1. line 1 \"aFilename\"`","text":"String - file content containing `1. line 1 \"aFilename\"`"},"form":"unary","operator":null,"left":null,"right":{"text":"fileName","types":["String"]}}],"examples":[{"text":"```sqf\n_string = preprocessFileLineNumbers \"A3\\ui_f\\scripts\\IGUI\\RscUnitInfo.sqf\"\n```\n\nResult is:\n\n #line 1 \"A3\\ui_f\\scripts\\IGUI\\RscUnitInfo.sqf\"\n\n disableserialization;\n\n ........","code":["_string = preprocessFileLineNumbers \"A3\\ui_f\\scripts\\IGUI\\RscUnitInfo.sqf\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fileExists","preprocessFile","loadFile","Function","SQF Syntax","call","spawn","execVM","PreProcessor Commands"],"notes":[{"user":"Killzone_Kid","date":"2013-12-17T13:44:00Z","text":"The main difference between preprocessFile and preprocessFileLineNumbers is that the latter adds #line keyword to the target file, which allows to log the __LINE__ error happened at and the __FILE__ error happened in."},{"user":"code34","date":"2017-11-04T10:16:00Z","text":"The #line directive get's removed from the output.\n\nSo to add a custom #line directive before while using preprocessFileLineNumbers, you have to use a preprocessor macro like this:\n\n*#define* DEBUG(sharp,name) sharp##line 0 name\n\nand add this at the right place in your code\n\nDEBUG(#,\"your filename\");\n\nThis way you can have custom filenames in error messages."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"primaryWeapon","operator":null,"title":"primaryWeapon","type":"command","url":"https://community.bistudio.com/wiki/primaryWeapon","revid":349379,"updated":"2023-11-08T15:35:14Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns name of unit's primary weapon. This command will also return a weapon class name if the weapon is not used by the player, for example, it is on the unit's back. Use currentWeapon to get the weapon the unit is using.","syntaxes":[{"syntax":"primaryWeapon unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"weapon class name or \"\" if no primary weapon","text":"String - weapon class name or \"\" if no primary weapon"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_pWeap = primaryWeapon player;\n```","code":["_pWeap = primaryWeapon player;"]},{"text":"```sqf\nhint primaryWeapon player; // \"arifle_MX_ACO_pointer_F\"\n```","code":["hint primaryWeapon player; // \"arifle_MX_ACO_pointer_F\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["primaryWeaponMagazine","primaryWeaponItems","addPrimaryWeaponItem","removePrimaryWeaponItem","removeAllPrimaryWeaponItems","secondaryWeapon","handgunWeapon","currentWeapon","weapons"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"primaryWeaponItems","operator":null,"title":"primaryWeaponItems","type":"command","url":"https://community.bistudio.com/wiki/primaryWeaponItems","revid":378479,"updated":"2026-04-24T11:51:13Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns array with all items assigned to the primaryWeapon except magazines. Use primaryWeaponMagazine command for the latter. This command is used for infantry weapons only.","syntaxes":[{"syntax":"primaryWeaponItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [muzzle, rail, optic, bipod]","types":["Array"],"description":"muzzle: String - class name of the muzzle attachment (silencer, flash hider) - rail: String - class name of the rail attachement (laserpointer/flashlight) - optic: String - bipod: String","text":"Array with [muzzle, rail, optic, bipod]\n- muzzle: String - class name of the muzzle attachment (silencer, flash hider)\n- rail: String - class name of the rail attachement (laserpointer/flashlight)\n- optic: String\n- bipod: String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprimaryWeaponItems player;\n/*\n[\n    \"muzzle_snds_H\",    // silencer\n    \"acc_pointer_IR\",    // laser\n    \"optic_Aco\",        // optics\n    \"bipod_01_F_blk\"    // bipod\n]\n*/\n```","code":["primaryWeaponItems player;\n/*\n[\n\t\"muzzle_snds_H\",\t// silencer\n\t\"acc_pointer_IR\",\t// laser\n\t\"optic_Aco\",\t\t// optics\n\t\"bipod_01_F_blk\"\t// bipod\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addPrimaryWeaponItem","removePrimaryWeaponItem","removeAllPrimaryWeaponItems","weaponAccessories","weaponAccessoriesCargo","handgunItems","binocularItems","secondaryWeaponItems","weaponsItems","weaponsItemsCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"primaryWeaponMagazine","operator":null,"title":"primaryWeaponMagazine","type":"command","url":"https://community.bistudio.com/wiki/primaryWeaponMagazine","revid":377142,"updated":"2026-01-01T10:31:18Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Collects all loaded magazines from all primaryWeapon muzzles and returns them in Array, otherwise it returns []. This command is used for infantry weapons only.","syntaxes":[{"syntax":"primaryWeaponMagazine unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str primaryWeaponMagazine player; //[\"30Rnd_65x39_caseless_mag\"]\n```","code":["hint str primaryWeaponMagazine player; //[\"30Rnd_65x39_caseless_mag\"]"]},{"text":"```sqf\n_array = primaryWeaponMagazine player;\nif (count _array > 0) then {\n    hint (\"Primary weapon is loaded with \" + (_array select 0) + \"!\");\n} else {\n    if (primaryWeapon player != \"\") then {\n        hint \"Primary weapon is not loaded!\";\n    } else {\n        hint \"Player doesn't have a primary weapon!\";\n    };\n};\n```","code":["_array = primaryWeaponMagazine player;\nif (count _array > 0) then {\n\thint (\"Primary weapon is loaded with \" + (_array select 0) + \"!\");\n} else {\n\tif (primaryWeapon player != \"\") then {\n\t\thint \"Primary weapon is not loaded!\";\n\t} else {\n\t\thint \"Player doesn't have a primary weapon!\";\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["primaryWeapon","primaryWeaponItems","addPrimaryWeaponItem","removePrimaryWeaponItem","removeAllPrimaryWeaponItems","handgunMagazine","secondaryWeaponMagazine","binocularMagazine"],"notes":[{"user":"Pierre MGI","date":"2014-06-08T21:52:00Z","text":"This function returns an array like [\"type of magazine loaded in primary weapon\", \"type of grenade loaded in launcher if exist\"]\n\nFor example [\"30Rnd_556x45_Stanag\", \"1Rnd_HE_Grenade_shell\"], with no consideration about amount of these ammo.\n\nHowever, be careful if you intend to use it in expression like : (magazines _unit) - (primaryWeaponMagazine _unit), i.e. magazines \"minus\" this array,\n\nThe result will inventory all magazines (with grenades, chemlights...) except ALL magazines (and grenades eventually) belonging to the TYPE of the loaded one! i.e. you suppress ALL \"30Rnd_556x45_Stanag\" but the \"30Rnd_556x45_Stanag_Tracer_Green\" are still remaining.\n\nIf you kill the unit, the same expression will return a consistent inventory as primary weapon \"disappears\" and primaryWeaponMagazine is empty. \"30Rnd_556x45_Stanag\" are back!"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands"]},{"name":"priority","operator":null,"title":"priority","type":"command","url":"https://community.bistudio.com/wiki/priority","revid":323078,"updated":"2022-06-28T21:43:13Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the priority of the task.","syntaxes":[{"syntax":"priority task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_prioTsk01 = priority task01;\n```","code":["_prioTsk01 = priority task01;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleTask","simpleTasks"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"private","operator":null,"title":"private","type":"command","url":"https://community.bistudio.com/wiki/private","revid":377850,"updated":"2026-01-03T11:40:32Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets a variable to the innermost scope. See also param and params.\n\n> [!WARNING]\n> - private variables **must** start with an underscore:  - see Identifier.\n> - **Always** make your local variables **private** (through private or params) in order to avoid overwriting a local variable of the same name.","syntaxes":[{"syntax":"private variableName","since":null,"effect":null,"exec":null,"params":[{"name":"variableName","type":"String","optional":false,"default":null,"description":"e.g `\"_myVar\"`","types":["String"],"since":null,"text":"variableName: String - e.g `\"_myVar\"`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"variableName","types":["String"]}},{"syntax":"private variableNameList","since":null,"effect":null,"exec":null,"params":[{"name":"variableNameList","type":"Array of Strings","optional":false,"default":null,"description":"e.g `[\"_target\", \"_damage\"]`","types":["Array","String"],"since":null,"text":"variableNameList: Array of Strings - e.g `[\"_target\", \"_damage\"]`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"variableNameList","types":["Array","String"]}},{"syntax":"private _identifier = value From Arma 2 v1.00 to Arma 3 v1.52: see local","since":"arma3 1.54","effect":null,"exec":null,"params":[{"name":"_identifier","type":"underscored variable name, for example `_myVar`","optional":false,"default":null,"description":null,"types":["Identifier"],"since":null,"text":"_identifier: underscored variable name, for example `_myVar`"},{"name":"value","type":"Anything: value to assign to the variable","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything: value to assign to the variable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"_identifier = value From Arma 2 v1.00 to Arma 3 v1.52: see local","types":[]}}],"examples":[{"text":"```sqf\nprivate _varname = \"this is my new variable\"; // since Arma 3 v1.54\n\n// identical, but less performant\nprivate \"_varname\";\n_varname = \"this is my new variable\";\n```","code":["private _varname = \"this is my new variable\"; // since Arma 3 v1.54\n\n// identical, but less performant\nprivate \"_varname\";\n_varname = \"this is my new variable\";"]},{"text":"```sqf\nprivate [\"_varname1\", \"_varname2\"];\n_varname1 = \"variable 1\";\n_varname2 = \"variable 2\";\n```","code":["private [\"_varname1\", \"_varname2\"];\n_varname1 = \"variable 1\";\n_varname2 = \"variable 2\";"]},{"text":"```sqf\n_lol = 123; call { hint str [_lol] }; // [123]\n_lol = 123; call { private \"_lol\"; hint str [_lol] }; // [any]\n```","code":["_lol = 123; call { hint str [_lol] }; // [123]\n_lol = 123; call { private \"_lol\"; hint str [_lol] }; // [any]"]},{"text":"```sqf\n_myvar = 123;\nsystemChat str [_myvar];        // [123]\ncall {\n    systemChat str [_myvar];    // [123]\n    private \"_myvar\";\n    systemChat str [_myvar];    // [any]\n    _myvar = 345;\n    systemChat str [_myvar];    // [345]\n};\nsystemChat str [_myvar];        // [123]\n```","code":["_myvar = 123;\nsystemChat str [_myvar];\t\t// [123]\ncall {\n\tsystemChat str [_myvar];\t// [123]\n\tprivate \"_myvar\";\n\tsystemChat str [_myvar];\t// [any]\n\t_myvar = 345;\n\tsystemChat str [_myvar];\t// [345]\n};\nsystemChat str [_myvar];\t\t// [123]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["param","params","privateAll"],"notes":[{"user":"Faguss","date":"2010-08-04T13:30:00Z","text":"The higher scope is also the script from which the function has been called.\n\nin **script2.sqf**:\n\n```sqf\n_a = 2;\n```\n\nin **script1.sqf**:\n\n```sqf\n_a = 1;\ncall compile preprocessFileLineNumbers \"script2.sqf\";\nhint format [\"%1\", _a];\n```\n\nGame will display 2.\n\nInserting `private \"_a\"` in the function prevents the change and so number 1 will be displayed on the screen."},{"user":"DreadedEntity","date":"2015-02-25T17:06:00Z","text":"Recursive loops require the use of private. Without it, your variables will be overwritten."},{"user":"654wak654","date":"2018-01-31T10:37:00Z","text":"This command is *similar* to javascript's [let](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/let) keyword.\n\n**EDIT:** in the way that it scopes the variable to the innermost scope. Otherwise, let and private can behave differently - Lou Montana (talk)"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"privateAll","operator":null,"title":"privateAll","type":"command","url":"https://community.bistudio.com/wiki/privateAll","revid":369773,"updated":"2024-10-08T15:08:58Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Disables the implicit inheritance of local variables, as defined in the parent scope.\n\nBy default, any local variables defined in a parent scope are available to the lower scope code.\n\nAfter using privateAll, parent scope variables can no longer be accessed implicitly. However, it is still possible to explicitly access parent scope variables using the import command.","syntaxes":[{"syntax":"privateAll","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_a = 1;\n_b = 2;\n_c = 3;\n4 call {\n    // _a, _b and _c from the parent scope are accessible at this point\n    systemChat str [_a, _b, _c];             // prints [1, 2, 3]\n    privateAll;                             // _a, _b and _c from the parent scope can no longer be accessed\n    systemChat str [_a, _b, _c];             // prints [Any, Any, Any]\n    import [\"_a\", \"_b\"];                     // _a and _b are now defined as private variables in the current scope; _c is still not defined\n    systemChat str [_a, _b, _c, _this];     // prints [1, 2, Any, 4]\n    _a = _a + 1;                             // changes the private _a variable in the current scope, but doesn't change the parent scope _a\n};\nsystemChat str _a; // _a is still 1\n```","code":["_a = 1;\n_b = 2;\n_c = 3;\n4 call {\n\t// _a, _b and _c from the parent scope are accessible at this point\n\tsystemChat str [_a, _b, _c]; \t\t\t// prints [1, 2, 3]\n\tprivateAll; \t\t\t\t\t\t\t// _a, _b and _c from the parent scope can no longer be accessed\n\tsystemChat str [_a, _b, _c]; \t\t\t// prints [Any, Any, Any]\n\timport [\"_a\", \"_b\"]; \t\t\t\t\t// _a and _b are now defined as private variables in the current scope; _c is still not defined\n\tsystemChat str [_a, _b, _c, _this]; \t// prints [1, 2, Any, 4]\n\t_a = _a + 1; \t\t\t\t\t\t\t// changes the private _a variable in the current scope, but doesn't change the parent scope _a\n};\nsystemChat str _a; // _a is still 1"]},{"text":"```sqf\nprivate _a = /* ... */;\nprivate _b = /* ... */;\nprivate _c = /* ... */;\n\n{\n    _x call {\n        privateAll;\n        import [\"_a\", \"_b\"];\n        call _this;\n    };\n} forEach CustomEventHandlers;\n```\n\n1. Because of the import-statement, code from `CustomEventHandlers` can use `_a` and `_b` without using params (even if `_a` and `_b` were provided via `_this`, which is not the case here).\n1. Code from `CustomEventHandlers` can only see `_a` and `_b`, but no other variables such as `_c`, `_x` or `_forEachIndex`.\n1. Code from `CustomEventHandlers` can modify `_a` and `_b` (e.g. `_a = _b / 2`), but only within its own scope (i.e. `CustomEventHandlers # (n + 1)` will not see any changes that `CustomEventHandlers # n` may have made to `_a` and `_b`).\n1. The values of `_a`, `_b` and `_c` after the forEach-loop are guaranteed to be the same as before the forEach-loop.\n\n> [!IMPORTANT]\n> There is one important exception to points 3 and 4: Modifications by reference (e.g. `_a pushBack 123` where `_a` is an Array) are applied in all scopes. This can be avoided by copying `_a` before calling the `CustomEventHandlers` code:\n>\n> ```sqf\n> private _a = [/* ... */]; // Note that _a is an array.\n> private _b = /* ... */;\n> private _c = /* ... */;\n>\n> {\n>     _x call {\n>         privateAll;\n>         import [\"_a\", \"_b\"];\n>         _a = +_a; // Copy the array so that the code from CustomEventHandlers can no longer modify the original array.\n>         call _this;\n>     };\n> } forEach CustomEventHandlers;\n> ```","code":["private _a = /* ... */;\nprivate _b = /* ... */;\nprivate _c = /* ... */;\n\n{\n\t_x call {\n\t\tprivateAll;\n\t\timport [\"_a\", \"_b\"];\n\t\tcall _this;\n\t};\n} forEach CustomEventHandlers;","private _a = [/* ... */]; // Note that _a is an array.\nprivate _b = /* ... */;\nprivate _c = /* ... */;\n\n{\n\t_x call {\n\t\tprivateAll;\n\t\timport [\"_a\", \"_b\"];\n\t\t_a = +_a; // Copy the array so that the code from CustomEventHandlers can no longer modify the original array.\n\t\tcall _this;\n\t};\n} forEach CustomEventHandlers;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["import","private","Variables"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"processDiaryLink","operator":null,"title":"processDiaryLink","type":"command","url":"https://community.bistudio.com/wiki/processDiaryLink","revid":321937,"updated":"2022-05-22T12:54:35Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens the Diary screen on the subject/record specified by link. To get a valid link format, use createDiaryLink.","syntaxes":[{"syntax":"processDiaryLink link","since":null,"effect":null,"exec":null,"params":[{"name":"link","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"link:  String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"link","types":["String"]}}],"examples":[{"text":"```sqf\nprocessDiaryLink createDiaryLink [\"Tasks\", (simpleTasks player) select 0, \"\"]; // Select a task in the Task menu\n```","code":["processDiaryLink createDiaryLink [\"Tasks\", (simpleTasks player) select 0, \"\"]; // Select a task in the Task menu"]},{"text":"```sqf\n// To select various tabs in the map screen:\nprocessDiaryLink createDiaryLink [\"selected_tab\", player, \"\"];\n// ... where \"selected_tab\" can be \"Tasks\", \"Diary\", \"Units\", \"Players\", \"Statistics\", other user created subjects\n```","code":["// To select various tabs in the map screen:\nprocessDiaryLink createDiaryLink [\"selected_tab\", player, \"\"];\n// ... where \"selected_tab\" can be \"Tasks\", \"Diary\", \"Units\", \"Players\", \"Statistics\", other user created subjects"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDiaryLink","createDiaryRecord","createDiarySubject","diarySubjectExists"],"notes":[{"user":"Killzone_Kid","date":"2017-06-30T21:49:00Z","text":"You can also force open diary with selected link by passing string in link format directly:\n\n```sqf\nprocessDiaryLink \"<log subject='Diary'></log>\";\n```\n\nThe above will open tab Briefing.\n\n```sqf\nprocessDiaryLink \"<log subject='Diary' record='Record2'></log>\";\n```\n\nThe above will open tab Briefing and select 3rd record from the bottom, provided the records were added consistently."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"productVersion","operator":null,"title":"productVersion","type":"command","url":"https://community.bistudio.com/wiki/productVersion","revid":377698,"updated":"2026-01-02T09:03:25Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the product's friendly name, identifier, version and build number.\n\n> [!NOTE]\n> **Arma 3:** The command has been upgraded to also returns branch identifier, whether or not the game was launched using mods, the platform and the architecture.","syntaxes":[{"syntax":"productVersion","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [name, nameShort, version, buildNumber, buildType, isModded, platform, architecture, steamBranchName]","types":["Array"],"description":"name: String - product name - nameShort: String - product short name - version: Number - product version number - buildNumber: Number - product build number - Arma 3 v1.00 buildType: String - build type, can be `\"Stable\"`, `\"Development\"`, `\"Diag\"` or `\"Profile\"` - Arma 3 v1.00 isModded: Boolean - is the product running with mods (true) or vanilla (false) - Arma 3 v1.00 platform: String - can be `\"Windows\"`, `\"Linux\"` or `\"OSX\"` - Arma 3 v1.68 architecture: String - `\"x64\"` for 64bit or `\"x86\"` for 32bit - Arma 3 v2.20 steamBranchName: String - `\"\"` (for default/public branch), `\"profiling\"` or `\"development\"`","text":"Array with [name, nameShort, version, buildNumber, buildType, isModded, platform, architecture, steamBranchName]\n- name: String - product name\n- nameShort: String - product short name\n- version: Number - product version number\n- buildNumber: Number - product build number\n- Arma 3 v1.00 buildType: String - build type, can be `\"Stable\"`, `\"Development\"`, `\"Diag\"` or `\"Profile\"`\n- Arma 3 v1.00 isModded: Boolean - is the product running with mods (true) or vanilla (false)\n- Arma 3 v1.00 platform: String - can be `\"Windows\"`, `\"Linux\"` or `\"OSX\"`\n- Arma 3 v1.68 architecture: String - `\"x64\"` for 64bit or `\"x86\"` for 32bit\n- Arma 3 v2.20 steamBranchName: String - `\"\"` (for default/public branch), `\"profiling\"` or `\"development\"`"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str productVersion; // would return [\"Arma 2 OA\", \"arma2oa\", 162, 95208] on Arma 2 OA 1.62.95208\n```","code":["hint str productVersion; // would return [\"Arma 2 OA\", \"arma2oa\", 162, 95208] on Arma 2 OA 1.62.95208"]},{"text":"```sqf\nhint str productVersion; // [\"Arma 3\", \"Arma3\", 137, 128764, \"Development\", false, \"Windows\"]\n```","code":["hint str productVersion; // [\"Arma 3\", \"Arma3\", 137, 128764, \"Development\", false, \"Windows\"]"]},{"text":"```sqf\nformat [\"%1.%2\", (productVersion select 2) * 0.01 toFixed 2, productVersion select 3]; // returns version e.g.: \"2.00.146773\"\n```","code":["format [\"%1.%2\", (productVersion select 2) * 0.01 toFixed 2, productVersion select 3]; // returns version e.g.: \"2.00.146773\""]},{"text":"```sqf\nproductVersion params [\"_name\", \"_nameShort\", \"_version\", \"_buildNumber\", \"_buildType\", \"_isModded\", \"_platform\", \"_architecture\", \"_steamBranchName\"];\n```","code":["productVersion params [\"_name\", \"_nameShort\", \"_version\", \"_buildNumber\", \"_buildType\", \"_isModded\", \"_platform\", \"_architecture\", \"_steamBranchName\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["supportInfo","requiredVersion"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"profileName","operator":null,"title":"profileName","type":"command","url":"https://community.bistudio.com/wiki/profileName","revid":310755,"updated":"2022-05-07T20:21:33Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns currently chosen user profile name. For Steam profile name see profileNameSteam.","syntaxes":[{"syntax":"profileName","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_myInGameProfileName = profileName;\n```","code":["_myInGameProfileName = profileName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["profileNameSteam","name"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"profileNamespace","operator":null,"title":"profileNamespace","type":"command","url":"https://community.bistudio.com/wiki/profileNamespace","revid":369330,"updated":"2024-09-03T18:43:00Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the global namespace attached to the active user profile. Use setVariable and getVariable to save and load data to and from this Namespace. A variable can be deleted by setting its value to nil. By default the variables set in this namespace will exist while the game is running, and variables are saved persistently when the game is closed. Saving can also be forced by using saveProfileNamespace to prevent data loss on e.g game crash.\n\nThe variables are stored next to the user profile in a file named `myUsername.vars.GAMENAME`.","syntaxes":[{"syntax":"profileNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":null,"text":"Namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprofileNamespace setVariable [\"TAG_kills\", 10000];\n// somewhere else in the code\n_kills = profileNamespace getVariable [\"TAG_kills\", 0];\n```","code":["profileNamespace setVariable [\"TAG_kills\", 10000];\n// somewhere else in the code\n_kills = profileNamespace getVariable [\"TAG_kills\", 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveProfileNamespace","missionNamespace","uiNamespace","parsingNamespace","currentNamespace","localNamespace","allVariables","with","ArmA: Editing"],"notes":[{"user":"Joris","date":"2011-11-25T17:33:00Z","text":"The variables are loaded when the user profile is loaded or changed."}],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"profileNameSteam","operator":null,"title":"profileNameSteam","type":"command","url":"https://community.bistudio.com/wiki/profileNameSteam","revid":310745,"updated":"2022-05-07T20:21:28Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.46"}],"since":{"game":"arma3","name":"Arma 3","version":"1.46"},"arma3_since":"1.46","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns name of the current Steam profile. For currently chosen user profile name see profileName","syntaxes":[{"syntax":"profileNameSteam","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_mySteamProfileName = profileNameSteam;\n```","code":["_mySteamProfileName = profileNameSteam;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["profileName","getPlayerUID","name"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.46","Scripting Commands"]},{"name":"progressLoadingScreen","operator":null,"title":"progressLoadingScreen","type":"command","url":"https://community.bistudio.com/wiki/progressLoadingScreen","revid":376972,"updated":"2026-01-01T06:03:03Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"If loading screen is shown, sets progress bar to the given value (interval is from 0 to 1]).\n\n> [!NOTE]\n> **Arma 3:** The loading screen can be force-ended with the ENDLOAD cheat code.","syntaxes":[{"syntax":"progressLoadingScreen progress","since":null,"effect":null,"exec":null,"params":[{"name":"progress","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"progress: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"progress","types":["Number"]}}],"examples":[{"text":"```sqf\nstartLoadingScreen [\"Loading My Mission\"];\n// \n// batch of code\n// \nprogressLoadingScreen 0.25;\n// \n// batch of code\n// \nprogressLoadingScreen 0.50;\n// \n// batch of code\n// \nprogressLoadingScreen 0.95;\n// \n// batch of code\n// \nendLoadingScreen;\n```","code":["startLoadingScreen [\"Loading My Mission\"];\n// \n// batch of code\n// \nprogressLoadingScreen 0.25;\n// \n// batch of code\n// \nprogressLoadingScreen 0.50;\n// \n// batch of code\n// \nprogressLoadingScreen 0.95;\n// \n// batch of code\n// \nendLoadingScreen;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["startLoadingScreen","endLoadingScreen","BIS_fnc_progressLoadingScreen"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"progressPosition","operator":null,"title":"progressPosition","type":"command","url":"https://community.bistudio.com/wiki/progressPosition","revid":348954,"updated":"2023-11-08T14:45:39Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current position in the progress bar.","syntaxes":[{"syntax":"progressPosition control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"progress bar","types":["Control"],"since":null,"text":"control:  Control - progress bar"}],"returns":{"type":"Number","types":["Number"],"description":"progress from 0 to 1","text":"Number - progress from 0 to 1"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_progress = progressPosition _control;\n```","code":["_progress = progressPosition _control;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["progressSetPosition","ctrlScrollValues","sliderPosition","progressLoadingScreen"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"progressSetPosition","operator":null,"title":"progressSetPosition","type":"command","url":"https://community.bistudio.com/wiki/progressSetPosition","revid":369221,"updated":"2024-09-03T10:34:54Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets progress position of a progress bar.","syntaxes":[{"syntax":"control progressSetPosition progress","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":"progress bar control","types":["Control"],"since":null,"text":"control: Control - progress bar control"},{"name":"progress","type":"Number","optional":false,"default":null,"description":"0: no progress; 1: full progress","types":["Number"],"since":null,"text":"progress: Number - 0: no progress; 1: full progress"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"progress","types":["Number"]}}],"examples":[{"text":"```sqf\n_control progressSetPosition 0.5;\n```","code":["_control progressSetPosition 0.5;"]},{"text":"```sqf\nwith uiNamespace do {\n    bar = findDisplay 46 ctrlCreate [\"RscProgress\", -1];\n    bar ctrlSetPosition [0,0,1,0.01];\n    bar ctrlCommit 0;\n    bar progressSetPosition 0.75;\n};\n```","code":["with uiNamespace do {\n\tbar = findDisplay 46 ctrlCreate [\"RscProgress\", -1];\n\tbar ctrlSetPosition [0,0,1,0.01];\n\tbar ctrlCommit 0;\n\tbar progressSetPosition 0.75;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["progressPosition","ctrlSetScrollValues","sliderSetPosition"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"publicVariable","operator":null,"title":"publicVariable","type":"command","url":"https://community.bistudio.com/wiki/publicVariable","revid":343848,"updated":"2023-07-26T14:57:01Z","groups":["Multiplayer","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Reliably broadcasts missionNamespace variable and its **current** value to all computers (server/client).\n\nVariables broadcast with publicVariable during a mission will be available to JIP clients with the value they held at the time.\n\nSuch variables are persistent and sent to the JIP client before the first batch of client-side Event Scripts (such as init.sqf) is run.\n\n> [!IMPORTANT]\n> Using publicVariable too frequently and/or with a lot of data can cause other aspects of the game to experience bandwidth problems.\n\nThe following Data Types are supported:\n\n|  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|\n| Type | Number | Boolean | Object | Group | String | Text | Array | Code | Nothing (nil) | HashMap |\n| Since | Operation Flashpoint v1.34 | Armed Assault v1.00 | Armed Assault v1.09 | Arma 3 v1.26 | Arma 3 v2.02 |  |  |  |  |  |\n\n> [!IMPORTANT]\n> It is not possible (and illogical) to transfer a local entity reference, such as scripts, displays or local objects.\n>\n> Also, note that Team Member is not supported.","syntaxes":[{"syntax":"publicVariable varName","since":null,"effect":null,"exec":null,"params":[{"name":"varName","type":"String","optional":false,"default":null,"description":"the global variable's Identifier","types":["String"],"since":null,"text":"varName: String - the global variable's Identifier"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"varName","types":["String"]}}],"examples":[{"text":"```sqf\nTAG_MyPublicVariable = 0;\nTAG_MyPublicVariable = 1;\npublicVariable \"TAG_MyPublicVariable\";    // other clients will receive the \"TAG_MyPublicVariable\" variable with a 1 value\n\nTAG_MyPublicVariable = 2;                // needs to be broadcast again - synchronisation is not automatic\n```","code":["TAG_MyPublicVariable = 0;\nTAG_MyPublicVariable = 1;\npublicVariable \"TAG_MyPublicVariable\";\t// other clients will receive the \"TAG_MyPublicVariable\" variable with a 1 value\n\nTAG_MyPublicVariable = 2;\t\t\t\t// needs to be broadcast again - synchronisation is not automatic"]},{"text":"JIP example:\n\n```sqf\nif (isNil \"TAG_CurrentTarget\") then    // has the variable already been set and broadcast?\n{\n    TAG_CurrentTarget = objNull;    // if not, set it on the local machine\n};\n\nplayer doTarget TAG_CurrentTarget;\n```","code":["if (isNil \"TAG_CurrentTarget\") then\t// has the variable already been set and broadcast?\n{\n\tTAG_CurrentTarget = objNull;\t// if not, set it on the local machine\n};\n\nplayer doTarget TAG_CurrentTarget;"]},{"text":"```sqf\nTAG_BossName = \"EvilBigBoss\";\n\npublicVariable TAG_BossName;    // wrong - will try to publicVariable \"EvilBigBoss\" variable, that does not exist\npublicVariable \"TAG_BossName\";    // correct - important, do not forget the QUOTES\n```","code":["TAG_BossName = \"EvilBigBoss\";\n\npublicVariable TAG_BossName;\t// wrong - will try to publicVariable \"EvilBigBoss\" variable, that does not exist\npublicVariable \"TAG_BossName\";\t// correct - important, do not forget the QUOTES"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Multiplayer Scripting","Initialisation Order","addPublicVariableEventHandler","publicVariableClient","publicVariableServer","Variables","Event Scripts"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Variables","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"publicVariableClient","operator":null,"title":"publicVariableClient","type":"command","url":"https://community.bistudio.com/wiki/publicVariableClient","revid":369283,"updated":"2024-09-03T18:42:48Z","groups":["Multiplayer","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send the variable value to the client computer - same limitations regarding variable type as publicVariable.\n\nThe Client ID is the temporary ID given to a connected client for that session. You can find out this ID with the owner command (using it on a player's character, for example, will give you that players client ID).\n\n> [!NOTE]\n> **Arma 3:** In Arma 3 it is possible to broadcast nil value","syntaxes":[{"syntax":"clientID publicVariableClient varName","since":null,"effect":null,"exec":null,"params":[{"name":"clientID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"clientID: Number"},{"name":"varName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"varName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"clientID","types":["Number"]},"right":{"text":"varName","types":["String"]}}],"examples":[{"text":"```sqf\n3 publicVariableClient \"CTFscoreOne\";\n```","code":["3 publicVariableClient \"CTFscoreOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clientOwner","owner","publicVariable","publicVariableServer","addPublicVariableEventHandler","remoteExecutedOwner"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Variables","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"publicVariableServer","operator":null,"title":"publicVariableServer","type":"command","url":"https://community.bistudio.com/wiki/publicVariableServer","revid":363982,"updated":"2024-04-29T23:08:24Z","groups":["Multiplayer","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send the variable value to the server - same limitations regarding variable type as publicVariable.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3 it is possible to broadcast the nil value.","syntaxes":[{"syntax":"publicVariableServer varName","since":null,"effect":null,"exec":null,"params":[{"name":"varName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"varName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"varName","types":["String"]}}],"examples":[{"text":"```sqf\npublicVariableServer \"CTFscoreOne\";\n```","code":["publicVariableServer \"CTFscoreOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["publicVariable","publicVariableClient","addPublicVariableEventHandler"],"notes":[{"user":"Kylania","date":"2012-08-24T02:06:00Z","text":"- publicVariableServer (run on client)\n- publicVariableClient (run on server)\n\nPublishes the variable (name as String) to the server only.\nUseful when you want to synchronise a variable with the server but not any other clients. -"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Variables","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"pushBack","operator":null,"title":"pushBack","type":"command","url":"https://community.bistudio.com/wiki/pushBack","revid":377141,"updated":"2026-01-01T10:30:59Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Insert an element to the back of the given array. This command modifies the original array. (see also: pushBackUnique)","syntaxes":[{"syntax":"array pushBack element","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"element","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"element: Anything"}],"returns":{"type":"Number","types":["Number"],"description":"index of inserted element","text":"Number - index of inserted element"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"element","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3];\n_arr pushBack 4;\nhint str _arr; //[1,2,3,4]\n```","code":["_arr = [1,2,3];\n_arr pushBack 4;\nhint str _arr; //[1,2,3,4]"]},{"text":"```sqf\n_arr = [1,[2,4],3];\n(_arr select 1) pushBack [5,6];\nhint str _arr //[1,[2,4,[5,6]],3]\n```","code":["_arr = [1,[2,4],3];\n(_arr select 1) pushBack [5,6];\nhint str _arr //[1,[2,4,[5,6]],3]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pushBackUnique","select","set","resize","reverse","count","find","in","forEach","deleteAt","deleteRange","append","sort","arrayIntersect","apply","BIS_fnc_arrayPushStack","BIS_fnc_arrayPush"],"notes":[{"user":"ffur2007slx2_5","date":"2014-08-01T21:15:00Z","text":"(A3 1.26) It is recommended to use pushBack instead of BIS_fnc_arrayPush.\n\n```sqf\n_array = [1,2,3];\n_array pushBack 4; //same as [_array, 4] call BIS_fnc_arrayPush;\n```"},{"user":"Skaronator","date":"2014-08-23T21:35:00Z","text":"It's highly recommended to use the new pushBack command, up to 43% faster than set and up to **11843%** faster a plus b!"},{"user":"DreadedEntity","date":"2014-11-26T18:25:00Z","text":"pushBack does not support nil while set and a plus b do. For example:\n\n```sqf\n_array = [];\nfor \"_i\" from 0 to 3 do\n{\n    _array pushBack nil;\n};\nhint str _array; //hint is []\n```"},{"user":"Killzone_Kid","date":"2015-05-21T10:52:00Z","text":"Array \"push\" implementation using pushBack, alternative to BIS_fnc_arrayPush\n\n```sqf\nKK_fnc_push = {\n    _this select 0 pushBack (_this select 1);\n    _this select 0\n};\n\n// Example\narr = [1,2,3];\n[arr, 4] call KK_fnc_push; //both arr and return of function are now [1,2,3,4]\n```"},{"user":"OOKexOo","date":"2016-10-05T02:19:00Z","text":"Note that pushBack does not create a new object.\n\nTherefore, if you edit an object that was pushed back to an array, it also affects the object in the array.\ne.g.\n\n```sqf\n_first_squence = [1,2,3];\n_second_squence = [5,4];\n\n_first_squence pushBack _second_squence;\nsystemChat str _first_squence // prints [1,2,3,[5,4]]]\n\nreverse _second_squence;\nsystemChat str _first_squence // prints [1,2,3,[4,5]]]\n```\n\nIf you pushBack an array for instance, you can just copy it to generate a new object.\ne.g.\n\n```sqf\n_first_squence pushBack +_second_squence;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"pushBackUnique","operator":null,"title":"pushBackUnique","type":"command","url":"https://community.bistudio.com/wiki/pushBackUnique","revid":377140,"updated":"2026-01-01T10:30:41Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds element to the back of the given array but only if it is unique to the array. The index of the added element is returned upon success, otherwise -1. This command modifies the original array.\n\n> [!NOTE]\n> Adding string elements is **case sensitive**.","syntaxes":[{"syntax":"array pushBackUnique element","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"element","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"element: Anything"}],"returns":{"type":"Number","types":["Number"],"description":"index of inserted element or -1","text":"Number - index of inserted element or -1"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"element","types":["Anything"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3];\n_index = _arr pushBackUnique 3;\nhint str [_index, _arr]; // [-1,[1,2,3]]\n```","code":["_arr = [1,2,3];\n_index = _arr pushBackUnique 3;\nhint str [_index, _arr]; // [-1,[1,2,3]]"]},{"text":"```sqf\n_arr = [1,2,3];\n_index = _arr pushBackUnique 4;\nhint str [_index, _arr]; // [3,[1,2,3,4]]\n```","code":["_arr = [1,2,3];\n_index = _arr pushBackUnique 4;\nhint str [_index, _arr]; // [3,[1,2,3,4]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pushBack","select","set","resize","reverse","count","find","in","forEach","deleteAt","deleteRange","append","sort","arrayIntersect","apply","BIS_fnc_arrayPushStack","BIS_fnc_arrayPush"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"putWeaponPool","operator":null,"title":"putWeaponPool","type":"command","url":"https://community.bistudio.com/wiki/putWeaponPool","revid":310280,"updated":"2022-05-05T13:11:24Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Transfers weapons and magazines from weapon pool into cargo of given object. Used in campaign to transfer weapons into next mission.","syntaxes":[{"syntax":"putWeaponPool object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nputWeaponPool player;\n```","code":["putWeaponPool player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pickWeaponPool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"pylonAction","operator":null,"title":"pylonAction","type":"command","url":"https://community.bistudio.com/wiki/pylonAction","revid":378897,"updated":"2026-08-11T14:56:32Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Executes an action on a specific pylon. MP effect and locality depend on the specific action.\n\nComponents and their actions:\n\nCameraComponent\n- SetLightState (arg bool, ret none)\n- GetLightState (arg none, ret bool)\n\nTransportPylonsComponent (pylon index -1, no component name, no component index)\n\n- GetLastFiredPylonIndex (no arg, ret scalar), returns the pylon index (note this is script index, which is 1-based) that last fired the gun, or -1 if the last firing was not from a pylon (can be used in Fired eventhandler)\n\nAll pylons (Not on a component)\n\n- animateSource - Arg local, effect global. See animateSource pylonAction [vehicle player, 1, \"animateSource\", [\"extendBoxSource\", 1]];","syntaxes":[{"syntax":"pylonAction [vehicle, pylon, actionPath(, arguments)]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"The object carrying the pylon","types":["Object"],"since":null,"text":"vehicle: Object - The object carrying the pylon"},{"name":"pylon","type":"Number or String","optional":false,"default":null,"description":"pylon index (index starts from 1) or pylon name (see #Example 1). Or -1 to access the TransportPylonsComponent of the vehicle","types":["Number","String"],"since":null,"text":"pylon: Number or String - pylon index (index starts from 1) or pylon name (see #Example 1). Or -1 to access the TransportPylonsComponent of the vehicle"},{"name":"actionPath","type":"String","optional":false,"default":null,"description":"The path to reach the specific component to send the action to.\n\nactionPath is a \".\" delimited address of the component and action (like animation sources). Or (without a \".\" a command to the pylon directly)\n\narguments and return type depends on the final action\n\nActionPath examples\n\n\"CameraComponent.0.SetLightState\" with argument bool, returns nothing.\n\n\"CameraComponent.0.GetLightState\" with no argument, returns bool.\n\n\"CameraComponent.*.SetLightState\" wildcard executes the action all components of that type (if there are multiple). Note the return value will be the value of the last executed action","types":["String"],"since":null,"text":"actionPath: String - The path to reach the specific component to send the action to.\n\nactionPath is a \".\" delimited address of the component and action (like animation sources). Or (without a \".\" a command to the pylon directly)\n\narguments and return type depends on the final action\n\nActionPath examples\n\n\"CameraComponent.0.SetLightState\" with argument bool, returns nothing.\n\n\"CameraComponent.0.GetLightState\" with no argument, returns bool.\n\n\"CameraComponent.*.SetLightState\" wildcard executes the action all components of that type (if there are multiple). Note the return value will be the value of the last executed action"}],"returns":{"type":"Anything","types":["Anything"],"description":"Depends on action","text":"Anything - Depends on action"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, pylon, actionPath(, arguments)]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"queryItemsPool","operator":null,"title":"queryItemsPool","type":"command","url":"https://community.bistudio.com/wiki/queryItemsPool","revid":319415,"updated":"2022-05-13T09:24:03Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the number of items of type in the weapon pool (used in campaigns to transfer weapons to the next mission).","syntaxes":[{"syntax":"queryItemsPool name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _amountOfFAKgiven = queryItemsPool \"FirstAidKit\";\n```","code":["private _amountOfFAKgiven = queryItemsPool \"FirstAidKit\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["queryWeaponPool"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"queryMagazinePool","operator":null,"title":"queryMagazinePool","type":"command","url":"https://community.bistudio.com/wiki/queryMagazinePool","revid":319440,"updated":"2022-05-13T09:24:05Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return number of magazines of type name in magazine pool (used in campaign to transfer magazines into next mission).","syntaxes":[{"syntax":"queryMagazinePool name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_num = queryMagazinePool \"M16\";\n```","code":["_num = queryMagazinePool \"M16\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineGlobal","addMagazine","addMagazines","addMagazineCargo","addMagazineCargoGlobal","addMagazineTurret","addWeaponPool","clearMagazinePool","addMagazineAmmoCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"queryWeaponPool","operator":null,"title":"queryWeaponPool","type":"command","url":"https://community.bistudio.com/wiki/queryWeaponPool","revid":323019,"updated":"2022-06-28T21:43:07Z","groups":["Weapon Pool"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return number of weapons of type name in weapon pool (used in campaign to transfer weapons into next mission).","syntaxes":[{"syntax":"queryWeaponPool name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_num = queryWeaponPool \"M16\";\n```","code":["_num = queryWeaponPool \"M16\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["queryItemsPool"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"rad","operator":null,"title":"rad","type":"command","url":"https://community.bistudio.com/wiki/rad","revid":319456,"updated":"2022-05-13T09:24:06Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts given value in degrees to radians. 1 radian equals 180 degrees divided by pi.","syntaxes":[{"syntax":"rad value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":"degrees","types":["Number"],"since":null,"text":"value: Number - degrees"}],"returns":{"type":"Number","types":["Number"],"description":"radians","text":"Number - radians"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n_radians = rad 180; // returns 3.1415 (pi)\n```","code":["_radians = rad 180; // returns 3.1415 (pi)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pi","deg"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioChannelAdd","operator":null,"title":"radioChannelAdd","type":"command","url":"https://community.bistudio.com/wiki/radioChannelAdd","revid":370595,"updated":"2025-01-14T13:03:39Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Add the units to the custom channel.","syntaxes":[{"syntax":"customChannelID radioChannelAdd units","since":null,"effect":null,"exec":null,"params":[{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate command"},{"name":"units","type":"Array of Objects","optional":false,"default":null,"description":"list of units","types":["Array","Object"],"since":null,"text":"units: Array of Objects - list of units"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"customChannelID","types":["Number"]},"right":{"text":"units","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n2 radioChannelAdd [player, unit1];\n```","code":["2 radioChannelAdd [player, unit1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelCreate","radioChannelRemove","radioChannelSetCallSign","radioChannelSetLabel"],"notes":[{"user":"Hypoxic125","date":"2022-11-01T06:36:41Z","text":"Units are removed from the chat channel on RESPAWN. Be sure to add units back to their custom chat channels upon respawn via onPlayerRespawn.sqf or Respawn Event Handler."}],"categories":["Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Take On Helicopters version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioChannelCreate","operator":null,"title":"radioChannelCreate","type":"command","url":"https://community.bistudio.com/wiki/radioChannelCreate","revid":378309,"updated":"2026-04-01T22:48:12Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Create a custom radio channel with the given color, label, call sign and registered characters.\nThe **custom channel ID** returned can be used to manipulate the created channel later.\nThere are **50** slots (10 slots before Arma 3 v2.22) for custom radio channels which would correspond to channels 6..15 and 26..65 (see getPlayerChannel).\nThe command will find an unused index in this range and create it when found.","syntaxes":[{"syntax":"radioChannelCreate [color, label, callSign, units, sentenceType]","since":null,"effect":null,"exec":null,"params":[{"name":"color","type":"Array","optional":false,"default":null,"description":"RGBA color values","types":["Array"],"since":null,"text":"color: Array - RGBA color values"},{"name":"label","type":"String","optional":false,"default":null,"description":"label","types":["String"],"since":null,"text":"label: String - label"},{"name":"callSign","type":"String or Arma 3 v2.22 Array of Strings","optional":false,"default":null,"description":"see radioChannelSetCallSign","types":["String","Array"],"since":null,"text":"callSign: String or Arma 3 v2.22 Array of Strings - see radioChannelSetCallSign"},{"name":"units","type":"Array of Objects","optional":false,"default":null,"description":"units in the channel","types":["Array","Object"],"since":null,"text":"units: Array of Objects - units in the channel"},{"name":"sentenceType","type":"Boolean","optional":true,"default":"true","description":"true - use *Protocol* message color from `getArray (configFile >> \"RscChatListDefault\" >> \"colorMessageProtocol\")`\n- false - use *Normal* message color from `getArray (configFile >> \"RscChatListDefault\" >> \"colorMessage\")`","types":["Boolean"],"since":null,"text":"sentenceType: Boolean - (Optional, default true)\n- true - use *Protocol* message color from `getArray (configFile >> \"RscChatListDefault\" >> \"colorMessageProtocol\")`\n- false - use *Normal* message color from `getArray (configFile >> \"RscChatListDefault\" >> \"colorMessage\")`"}],"returns":{"type":"Number","types":["Number"],"description":"created custom channel ID (used in customChat command), 0 if failed. (see BIS_fnc_channelNumToRadioChannelID, BIS_fnc_radioChannelIDToChannelNum)","text":"Number - created **custom channel ID** (used in customChat command), 0 if failed. (see BIS_fnc_channelNumToRadioChannelID, BIS_fnc_radioChannelIDToChannelNum)"},"form":"unary","operator":null,"left":null,"right":{"text":"[color, label, callSign, units, sentenceType]","types":["Array"]}}],"examples":[{"text":"```sqf\n_channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [player1, player2]];\n```","code":["_channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [player1, player2]];"]},{"text":"```sqf\n_channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [player1, player2], true];\n// using true also disables automatic quotes for chat in channel (Arma 3)\n```","code":["_channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [player1, player2], true];\n// using true also disables automatic quotes for chat in channel (Arma 3)"]},{"text":"Create custom channel and add all players to it, present and JIP:\n\n```sqf\nif (isServer) then\n{\n    private _channelName = \"Q-dance Radio\";\n    private _channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], _channelName, \"%UNIT_NAME\", []];\n    if (_channelID == 0) exitWith {diag_log format [\"Custom channel '%1' creation failed!\", _channelName]};\n    [_channelID, {_this radioChannelAdd [player]}] remoteExec [\"call\", [0, -2] select isDedicated, _channelName];\n};\n```","code":["if (isServer) then\n{\n\tprivate _channelName = \"Q-dance Radio\";\n\tprivate _channelID = radioChannelCreate [[0.96, 0.34, 0.13, 0.8], _channelName, \"%UNIT_NAME\", []];\n\tif (_channelID == 0) exitWith {diag_log format [\"Custom channel '%1' creation failed!\", _channelName]};\n\t[_channelID, {_this radioChannelAdd [player]}] remoteExec [\"call\", [0, -2] select isDedicated, _channelName];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelAdd","radioChannelRemove","radioChannelSetCallSign","radioChannelSetLabel","customChat","customRadio","setCurrentChannel","currentChannel","enableChannel","channelEnabled","getPlayerChannel","radioChannelInfo"],"notes":[{"user":"Killzone_Kid","date":"2016-01-21T13:30:00Z","text":"Make sure you add all units you intend to speak or receive messages on created custom channel to the channel."},{"user":"Hypoxic125","date":"2022-11-01T06:38:08Z","text":"Units are removed from the chat channel on RESPAWN. Be sure to add units back to their custom chat channels upon respawn via onPlayerRespawn.sqf or Respawn Event Handler."}],"categories":["Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Take On Helicopters version 1.00","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioChannelInfo","operator":null,"title":"radioChannelInfo","type":"command","url":"https://community.bistudio.com/wiki/radioChannelInfo","revid":377628,"updated":"2026-01-02T08:52:11Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Obtains custom radio channel's details. if 'customChannelID' is invalid, the return is either the first custom radio channel (customChannelID < firstCCChannel) or the last (customChannelID > lastCCChannel). 'inUse' true indicates if the channel was made available using radioChannelCreate, false means it can be created.","syntaxes":[{"syntax":"radioChannelInfo customChannelID","since":null,"effect":null,"exec":null,"params":[{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate"}],"returns":{"type":null,"types":["Array","radioChannelCreate"],"description":null,"text":"Array with [colour, label, callSign, units, sentenceType, inUse, Arma 3 v2.22 callSignVoN] (see radioChannelCreate)"},"form":"unary","operator":null,"left":null,"right":{"text":"customChannelID","types":["Number"]}},{"syntax":"radioChannelInfo option","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"option","type":"Boolean","optional":false,"default":null,"description":"true to return only channels in use, false to return all available channels","types":["Boolean"],"since":null,"text":"option: Boolean - true to return only channels in use, false to return all available channels"}],"returns":{"type":null,"types":["Array","radioChannelCreate"],"description":null,"text":"Array of Arrays in format [ [colour, label, callSign, units, sentenceType, inUse, callSignVoN],....] (see radioChannelCreate)"},"form":"unary","operator":null,"left":null,"right":{"text":"option","types":["Boolean"]}}],"examples":[{"text":"```sqf\nprivate _channelID = radioChannelCreate [[1, 0, 0.5, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [u1, u2], false];\nradioChannelInfo _channelID; // returns [[1,0,0.5,0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [u1, u2], false, true]\n```","code":["private _channelID = radioChannelCreate [[1, 0, 0.5, 0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [u1, u2], false];\nradioChannelInfo _channelID; // returns [[1,0,0.5,0.8], \"Q-dance Radio\", \"%UNIT_NAME\", [u1, u2], false, true]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelCreate","getPlayerChannel"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"radioChannelRemove","operator":null,"title":"radioChannelRemove","type":"command","url":"https://community.bistudio.com/wiki/radioChannelRemove","revid":377811,"updated":"2026-01-03T04:09:28Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove the units from the custom radio channel.","syntaxes":[{"syntax":"customChannelID radioChannelRemove units","since":null,"effect":null,"exec":null,"params":[{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate command"},{"name":"units","type":"Array of Objects","optional":false,"default":null,"description":"units","types":["Array","Object"],"since":null,"text":"units: Array of Objects - units"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"customChannelID","types":["Number"]},"right":{"text":"units","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n3 radioChannelRemove [blufor_unit_1, blufor_unit_2];\n```","code":["3 radioChannelRemove [blufor_unit_1, blufor_unit_2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelAdd","radioChannelCreate","radioChannelSetCallSign","radioChannelSetLabel"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioChannelSetCallSign","operator":null,"title":"radioChannelSetCallSign","type":"command","url":"https://community.bistudio.com/wiki/radioChannelSetCallSign","revid":378308,"updated":"2026-04-01T22:46:59Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Set the custom radio chat channel's callsign / VoN callsign.","syntaxes":[{"syntax":"customChannelID radioChannelSetCallSign callSign","since":null,"effect":null,"exec":null,"params":[{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate command"},{"name":"callSign","type":"String or Arma 3 v2.22 Array","optional":false,"default":null,"description":"custom chat callsign or [callSign, callSignVoN]. Available parameters:\n\n| Parameter | Description | Example |\n|---|---|---|\n| `%$KEY` | Reference a localised text | \"%$STR_Q_North\" → \"North\" |\n| `%CHANNEL_LABEL` | The channel's label - see radioChannelSetLabel | \"Q-dance Radio\" |\n| `%UNIT_SIDE` | Side's name, similar to sideRadio | \"BLUFOR\" |\n| `%UNIT_NAME` | The ***player***'s or AI's name - see name | \"John Doe\" |\n| `%UNIT_RANK` | A shorthand version of the unit's rank | \"Sgt\" |\n| `%UNIT_ID` | The unit's id in the group | \"1\" |\n| `%UNIT_REF` | The unit's log reference | \"Unit123456\" |\n| `%UNIT_GRP_NAME` | The group's name - see setGroupId | \"Alpha 1-1\" |\n| `%UNIT_GRP_LEADER` | Group leader mention (if the unit is its group's leader) | \", group leader\" |\n| `%UNIT_VEH_NAME` | Display name of the unit's vehicle | \"Hunter\" |\n| `%UNIT_VEH_POSITION` | Unit's vehicle position, similar to vehicleRadio | \"Gunner\" |\n| `%%` | To display a normal percentage sign | N/A |","types":["String","Array"],"since":null,"text":"callSign: String or Arma 3 v2.22 Array - custom chat callsign or [callSign, callSignVoN]. Available parameters:\n\n| Parameter | Description | Example |\n|---|---|---|\n| `%$KEY` | Reference a localised text | \"%$STR_Q_North\" → \"North\" |\n| `%CHANNEL_LABEL` | The channel's label - see radioChannelSetLabel | \"Q-dance Radio\" |\n| `%UNIT_SIDE` | Side's name, similar to sideRadio | \"BLUFOR\" |\n| `%UNIT_NAME` | The ***player***'s or AI's name - see name | \"John Doe\" |\n| `%UNIT_RANK` | A shorthand version of the unit's rank | \"Sgt\" |\n| `%UNIT_ID` | The unit's id in the group | \"1\" |\n| `%UNIT_REF` | The unit's log reference | \"Unit123456\" |\n| `%UNIT_GRP_NAME` | The group's name - see setGroupId | \"Alpha 1-1\" |\n| `%UNIT_GRP_LEADER` | Group leader mention (if the unit is its group's leader) | \", group leader\" |\n| `%UNIT_VEH_NAME` | Display name of the unit's vehicle | \"Hunter\" |\n| `%UNIT_VEH_POSITION` | Unit's vehicle position, similar to vehicleRadio | \"Gunner\" |\n| `%%` | To display a normal percentage sign | N/A |"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"customChannelID","types":["Number"]},"right":{"text":"callSign","types":["String","Array"]}}],"examples":[{"text":"```sqf\n4 radioChannelSetCallSign \"(%UNIT_ID) %UNIT_RANK %UNIT_NAME%UNIT_GRP_LEADER\"; // (1) Sgt Ben Kelly, group leader\n```","code":["4 radioChannelSetCallSign \"(%UNIT_ID) %UNIT_RANK %UNIT_NAME%UNIT_GRP_LEADER\"; // (1) Sgt Ben Kelly, group leader"]},{"text":"```sqf\n4 radioChannelSetCallSign [\"%UNIT_VEH_POSITION, %UNIT_VEH_NAME\", \"%UNIT_NAME%UNIT_GRP_LEADER\"];\n```","code":["4 radioChannelSetCallSign [\"%UNIT_VEH_POSITION, %UNIT_VEH_NAME\", \"%UNIT_NAME%UNIT_GRP_LEADER\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelAdd","radioChannelCreate","radioChannelRemove","radioChannelSetLabel"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Take On Helicopters version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioChannelSetLabel","operator":null,"title":"radioChannelSetLabel","type":"command","url":"https://community.bistudio.com/wiki/radioChannelSetLabel","revid":319392,"updated":"2022-05-13T09:24:00Z","groups":["Radio and Chat","Custom Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the custom radio channel's label.","syntaxes":[{"syntax":"customChannelID radioChannelSetLabel label","since":null,"effect":null,"exec":null,"params":[{"name":"customChannelID","type":"Number","optional":false,"default":null,"description":"custom channel ID returned by radioChannelCreate command","types":["Number"],"since":null,"text":"customChannelID: Number - custom channel ID returned by radioChannelCreate command"},{"name":"label","type":"String","optional":false,"default":null,"description":"label","types":["String"],"since":null,"text":"label: String - label"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"customChannelID","types":["Number"]},"right":{"text":"label","types":["String"]}}],"examples":[{"text":"```sqf\n5 radioChannelSetLabel \"Q-dance Radio\";\n```","code":["5 radioChannelSetLabel \"Q-dance Radio\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["radioChannelAdd","radioChannelCreate","radioChannelRemove","radioChannelSetCallSign"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Custom Radio and Chat","Command Group: Radio and Chat","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"radioEnabled","operator":null,"title":"radioEnabled","type":"command","url":"https://community.bistudio.com/wiki/radioEnabled","revid":349010,"updated":"2023-11-08T14:47:05Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for enableRadio.","syntaxes":[{"syntax":"radioEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if radio is enabled","text":"Boolean - returns true if radio is enabled"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (radioEnabled) then { enableRadio false };\n```","code":["if (radioEnabled) then { enableRadio false };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableRadio"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"radioVolume","operator":null,"title":"radioVolume","type":"command","url":"https://community.bistudio.com/wiki/radioVolume","revid":376982,"updated":"2026-01-01T06:23:17Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current radio volume (set by fadeRadio).","syntaxes":[{"syntax":"radioVolume","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..2","types":["Number"],"description":null,"text":"Number in range 0..2"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str radioVolume;\n```","code":["hint str radioVolume;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeRadio","soundVolume","musicVolume","speechVolume","environmentVolume","getAudioOptionVolumes"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"rain","operator":null,"title":"rain","type":"command","url":"https://community.bistudio.com/wiki/rain","revid":348549,"updated":"2023-11-08T13:10:02Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current value of rain density.","syntaxes":[{"syntax":"rain","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_rainLevel = rain;\n```","code":["_rainLevel = rain;"]}],"multiplayer":"Pre-Arma 3, each client and the server could have different rain values. Since Arma 3 the value is synced over network.","problems":null,"aliases":[],"see_also":["setRain","fog"],"notes":[],"categories":[]},{"name":"rainbow","operator":null,"title":"rainbow","type":"command","url":"https://community.bistudio.com/wiki/rainbow","revid":310802,"updated":"2022-05-07T20:21:58Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current rainbow intensity.","syntaxes":[{"syntax":"rainbow","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _intensity = rainbow;\n```","code":["private _intensity = rainbow;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setRainbow"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"rainParams","operator":null,"title":"rainParams","type":"command","url":"https://community.bistudio.com/wiki/rainParams","revid":377674,"updated":"2026-01-02T09:02:36Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns currently set RainParticles params, custom or default.","syntaxes":[{"syntax":"rainParams","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [rainDropTexture, texDropCount, minRainDensity, effectRadius, windCoef, dropSpeed, rndSpeed, rndDir, dropWidth, dropHeight, dropColor, lumSunFront, lumSunBack, refractCoef, refractSaturation, snow, dropColorStrong]","types":["Array"],"description":"rainDropTexture: String - texDropCount: Number - minRainDensity: Number - effectRadius: Number - windCoef: Number - dropSpeed: Number - rndSpeed: Number - rndDir: Number - dropWidth: Number - dropHeight: Number - dropColor: Color (RGBA) - lumSunFront: Number - lumSunBack: Number - refractCoef: Number - refractSaturation: Number - snow: Boolean - dropColorStrong: Boolean > [!NOTE] > See RainParticles for more information.","text":"Array with [rainDropTexture, texDropCount, minRainDensity, effectRadius, windCoef, dropSpeed, rndSpeed, rndDir, dropWidth, dropHeight, dropColor, lumSunFront, lumSunBack, refractCoef, refractSaturation, snow, dropColorStrong]\n- rainDropTexture: String\n- texDropCount: Number\n- minRainDensity: Number\n- effectRadius: Number\n- windCoef: Number\n- dropSpeed: Number\n- rndSpeed: Number\n- rndDir: Number\n- dropWidth: Number\n- dropHeight: Number\n- dropColor: Color (RGBA)\n- lumSunFront: Number\n- lumSunBack: Number\n- refractCoef: Number\n- refractSaturation: Number\n- snow: Boolean\n- dropColorStrong: Boolean\n\n> [!NOTE]\n> See RainParticles for more information."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _rainParams = rainParams;\n// or\nrainParams params [\n    \"_rainDropTexture\",\n    \"_texDropCount\",\n    \"_minRainDensity\",\n    \"_effectRadius\",\n    \"_windCoef\",\n    \"_dropSpeed\",\n    \"_rndSpeed\",\n    \"_rndDir\",\n    \"_dropWidth\",\n    \"_dropHeight\",\n    \"_dropColor\",\n    \"_lumSunFront\",\n    \"_lumSunBack\",\n    \"_refractCoef\",\n    \"_refractSaturation\",\n    \"_snow\",\n    \"_dropColorStrong\"\n];\n```","code":["private _rainParams = rainParams;\n// or\nrainParams params [\n\t\"_rainDropTexture\",\n\t\"_texDropCount\",\n\t\"_minRainDensity\",\n\t\"_effectRadius\",\n\t\"_windCoef\",\n\t\"_dropSpeed\",\n\t\"_rndSpeed\",\n\t\"_rndDir\",\n\t\"_dropWidth\",\n\t\"_dropHeight\",\n\t\"_dropColor\",\n\t\"_lumSunFront\",\n\t\"_lumSunBack\",\n\t\"_refractCoef\",\n\t\"_refractSaturation\",\n\t\"_snow\",\n\t\"_dropColorStrong\"\n];"]}],"multiplayer":"> [!IMPORTANT]\n> - Rain particle params are **local**\n> - If used on a dedicated server, this command returns an empty array.","problems":null,"aliases":[],"see_also":["setRain","fogParams","overcast","humidity","wind","forceWeatherChange"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 2.08","Scripting Commands"]},{"name":"random","operator":null,"title":"random","type":"command","url":"https://community.bistudio.com/wiki/random","revid":377710,"updated":"2026-01-02T09:03:49Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"|  |  |\n|---|---|\n|  |  |\n\n|  |  |\n|---|---|\n| #Syntax 1 | generates a random floating point value |\n| #Syntax 2 | generates a [Gaussian Distribution](https://en.wikipedia.org/wiki/Normal_distribution) (ref: Technically, it is a rescaled <https://en.wikipedia.org/wiki/Bates_distribution> with n = 4.<br>The distribution is split in two at its midpoint and scaled linearly such that its maximum lies at the specified midpoint.). It uses the same method as setTriggerTimeout command and is quite useful for e.g spawning loot, making more valuable items more rare |\n| #Syntax 3 | generates a [seed-based](https://en.wikipedia.org/wiki/Random_seed) random number |\n| #Syntax 4 | generates a [seed-based](https://en.wikipedia.org/wiki/Random_seed) random noise (**not** Perlin) texture based on provided seed and returning the value at supplied coordinates |","syntaxes":[{"syntax":"random x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":null,"types":["Number"],"description":null,"text":"Number from 0 (included) to *x*, **ex**cluded\n\n> [!IMPORTANT]\n> *x* was accidentally **in**cluded due to a bug introduced in Arma 2 v1.00 and fixed in Arma 3 v2.18."},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}},{"syntax":"random [min, mid, max]","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"min","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"min: Number"},{"name":"mid","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"mid: Number"},{"name":"max","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"max: Number"}],"returns":{"type":"Number in range from min to max, weighted by mid","types":["Number"],"description":"can be higher than max (maximum value is `min + max - mid`)","text":"Number in range from *min* to *max*, weighted by *mid* - **can** be higher than max (maximum value is `min + max - mid`)"},"form":"unary","operator":null,"left":null,"right":{"text":"[min, mid, max]","types":["Array"]}},{"syntax":"seed random x","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"seed","type":"Number","optional":false,"default":null,"description":"an **integer**. Any float value will be truncated (e.g -0.9, -0.1, 0.1 or 0.9 will be read as **0**)","types":["Number"],"since":null,"text":"seed: Number - an **integer**. Any float value will be truncated (e.g -0.9, -0.1, 0.1 or 0.9 will be read as **0**)"},{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number from 0 (included) to x (included)","types":["Number"],"description":null,"text":"Number from 0 (included) to *x* (**in**cluded)"},"form":"binary","operator":null,"left":{"text":"seed","types":["Number"]},"right":{"text":"x","types":["Number"]}},{"syntax":"seed random [x, y]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"seed","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"seed: Number"},{"name":"x","type":"Number","optional":false,"default":null,"description":"x texture position","types":["Number"],"since":null,"text":"x: Number - x texture position"},{"name":"y","type":"Number","optional":false,"default":null,"description":"y texture position","types":["Number"],"since":null,"text":"y: Number - y texture position"}],"returns":{"type":"Number from 0 (included) to 1 (excluded)","types":["Number"],"description":null,"text":"Number from 0 (included) to 1 (**ex**cluded)"},"form":"binary","operator":null,"left":{"text":"seed","types":["Number"]},"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\n_rNumber = random 1;\n```","code":["_rNumber = random 1;"]},{"text":"```sqf\n_rNumber = random -10;\n```","code":["_rNumber = random -10;"]},{"text":"Generate a random position inside a circle (see also Example Code: Random Area Distribution)\n\n```sqf\n_center getPos [_radius * sqrt random 1, random 360];\n```","code":["_center getPos [_radius * sqrt random 1, random 360];"]},{"text":"Select a random value from an array:\n\n```sqf\n_array = [\"apples\", \"pears\", \"bananas\", \"M16\"];\n\n_random = _array select floor random count _array;    // before Arma 2\n_random = _array call BIS_fnc_selectRandom;            // since Arma 2\n_random = selectRandom _array;                        // since Arma 3 v1.56\n```","code":["_array = [\"apples\", \"pears\", \"bananas\", \"M16\"];\n\n_random = _array select floor random count _array;\t// before Arma 2\n_random = _array call BIS_fnc_selectRandom;\t\t\t// since Arma 2\n_random = selectRandom _array;\t\t\t\t\t\t// since Arma 3 v1.56"]},{"text":"Visualisation of #Syntax 4 (warning, it takes a bit to execute and draw):\n\n```sqf\nprivate _parent = call BIS_fnc_displayMission;\nif (is3DEN) then { _parent = findDisplay 313 };\nprivate _display = _parent createDisplay \"RscDisplayEmpty\";\nprivate _background = _disp ctrlCreate [\"RscBackground\", -1];\n\nprivate _coef = 0.1;\n\nfor \"_x\" from 1 to 100 do\n{\n    for \"_y\" from 1 to 100 do\n    {\n        private _random = 0 random [_x * _coef, _y * _coef];\n        private _dot = _display ctrlCreate [\"RscBackground\", -1];\n\n        _dot ctrlSetPosition [0.5 + pixelW * _x, 0.5 + pixelH * _y, pixelW, pixelH];\n        _dot ctrlSetBackgroundColor [_random, _random, _random, 1];\n        _dot ctrlCommit 0;\n    };\n};\n```","code":["private _parent = call BIS_fnc_displayMission;\nif (is3DEN) then { _parent = findDisplay 313 };\nprivate _display = _parent createDisplay \"RscDisplayEmpty\";\nprivate _background = _disp ctrlCreate [\"RscBackground\", -1];\n\nprivate _coef = 0.1;\n\nfor \"_x\" from 1 to 100 do\n{\n\tfor \"_y\" from 1 to 100 do\n\t{\n\t\tprivate _random = 0 random [_x * _coef, _y * _coef];\n\t\tprivate _dot = _display ctrlCreate [\"RscBackground\", -1];\n\n\t\t_dot ctrlSetPosition [0.5 + pixelW * _x, 0.5 + pixelH * _y, pixelW, pixelH];\n\t\t_dot ctrlSetBackgroundColor [_random, _random, _random, 1];\n\t\t_dot ctrlCommit 0;\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectRandom","selectRandomWeighted","Example Code: Random Area Distribution"],"notes":[{"user":"Hcpookie","date":"2015-07-12T20:32:00Z","text":"Random selections including negative numbers can be obtained via:\n\n```sqf\n_xRnd = round (random 200) - 100;\n```\n\nThis will yield numbers between -100 and 100.\n- Be careful using random numbers in multiplayer, each client will come up with a different result. See multiplayer tutorials for more general information about locality.\n- The number returned is unlikely to be a whole number.\n\nTo return a whole number use either **round**, **ceil** or **floor** together with random\n\n```sqf\nx = round    (random 5) // will return 0, 1, 2, 3, 4 or 5.    (non-uniform distribution, 0 and 5 are half as likely to be selected than any of the other numbers)\nx = floor    (random 5) // will return 0, 1, 2, 3 or 4.        (uniform distribution, all numbers have the same probability of being selected)\nx = ceil    (random 5) // will return 0, 1, 2, 3, 4 or 5.    (0 is very unlikely, but possible, as ceil 0 is 0)\n```"},{"user":"Lou Montana","date":"2018-07-22T12:58:00Z","text":"|  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|\n| + Repartition comparison | Formula | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |\n| ```sqf<br>floor random 10<br>``` | 10% | 10% | 10% | 10% | 10% | 10% | 10% | 10% | 10% | 10% |  |\n| ```sqf<br>floor random [0, 5, 10]<br>``` | 0% | 2% | 7% | 17% | 25% | 25% | 17% | 7% | 2% | 0% |  |\n| ```sqf<br>floor random [0, 10, 0]<br>``` | 0% | 0% | 1% | 2% | 5% | 9% | 14% | 19% | 24% | 26% |  |\n| ```sqf<br>floor random [0, 10, 5]<br>``` | 0% | 0% | 0% | 1% | 2% | 5% | 9% | 16% | 28% | 38% |  |"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"rank","operator":null,"title":"rank","type":"command","url":"https://community.bistudio.com/wiki/rank","revid":337318,"updated":"2023-01-16T09:46:20Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the rank of the given unit. Rank can be one of the following:\n- `\"PRIVATE\"`\n- `\"CORPORAL\"`\n- `\"SERGEANT\"`\n- `\"LIEUTENANT\"`\n- `\"CAPTAIN\"`\n- `\"MAJOR\"`\n- `\"COLONEL\"`","syntaxes":[{"syntax":"rank unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_rank = rank player;\n```","code":["_rank = rank player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rankId","rating","addRating","setUnitRank","ArmA: Rating Values"],"notes":[],"categories":[]},{"name":"rankId","operator":null,"title":"rankId","type":"command","url":"https://community.bistudio.com/wiki/rankId","revid":319405,"updated":"2022-05-13T09:24:01Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return the rank of the given unit for comparison.\n\nValue may be:\n- **0** - Private\n- **1** - Corporal\n- **2** - Sergeant\n- **3** - Lieutenant\n- **4** - Captain\n- **5** - Major\n- **6** - Colonel","syntaxes":[{"syntax":"rankId unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_myIdRank = rankId player;\n```","code":["_myIdRank = rankId player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rank"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"rating","operator":null,"title":"rating","type":"command","url":"https://community.bistudio.com/wiki/rating","revid":341627,"updated":"2023-06-12T19:02:54Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check unit rating. Rating is increased for killing enemies, decreased for killing friendlies (see Rating Values). Can be changed via addRating by the mission designer.\n\nThe rating of the player is displayed as the \"score\" at the end of the mission. Via Description.ext one can define how many points it takes to get a perfect score, as well as the number of stars.","syntaxes":[{"syntax":"rating unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\n_score = rating player;\n```","code":["_score = rating player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side Relations","ArmA: Rating Values","addRating","rank","setUnitRank"],"notes":[{"user":"Leo15745","date":"2011-01-06T13:19:00Z","text":"In ArmA 1.18 rating does only return rating levels for units that are local."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"rectangular","operator":null,"title":"rectangular","type":"command","url":"https://community.bistudio.com/wiki/rectangular","revid":319430,"updated":"2022-05-13T09:24:03Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if a location is rectangular (returns true) or elliptical (returns false).","syntaxes":[{"syntax":"rectangular location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_isRect = rectangular myLocation;\n```","code":["_isRect = rectangular myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setText","nearestLocation","nearestLocations","locationPosition","nearestLocationWithDubbing","setRectangular","createLocation"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"regexFind","operator":null,"title":"regexFind","type":"command","url":"https://community.bistudio.com/wiki/regexFind","revid":369430,"updated":"2024-09-03T18:48:53Z","groups":["Strings - Regular Expression"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Searches in a string with a regular expression.\n\n> [!NOTE]\n> See Arma 3: Regular Expressions.","syntaxes":[{"syntax":"haystack regexFind [pattern, startOffset]","since":null,"effect":null,"exec":null,"params":[{"name":"haystack","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"haystack: String"},{"name":"pattern","type":"String","optional":false,"default":null,"description":"format regex pattern","types":["String"],"since":null,"text":"pattern: String - format regex pattern"},{"name":"startOffset","type":"Number","optional":true,"default":"0","description":"has to be in range from 0 to `count haystack` (*haystack*'s length)","types":["Number"],"since":null,"text":"startOffset: Number - (Optional, default 0) has to be in range from 0 to `count haystack` (*haystack*'s length)"}],"returns":{"type":"Array of nested arrays. Each lowest level array in format:","types":["Array"],"description":"0: String - match - 1: Number - offset of given match relative to haystack beginning (the provided offset is ignored)","text":"Array of nested arrays. Each lowest level array in format:\n- 0: String - match\n- 1: Number  - offset of given match relative to *haystack* beginning (the provided *offset* is ignored)"},"form":"binary","operator":null,"left":{"text":"haystack","types":["String"]},"right":{"text":"[pattern, startOffset]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"wooKie boOkie cookie\" regexFind [\".ookie/gio\"]; // [[[\"wooKie\", 0]], [[\"boOkie\", 7]], [[\"cookie\", 14]]]\n```","code":["\"wooKie boOkie cookie\" regexFind [\".ookie/gio\"]; // [[[\"wooKie\", 0]], [[\"boOkie\", 7]], [[\"cookie\", 14]]]"]},{"text":"```sqf\n\"wooKie boOkie cookie\" regexFind [\".ookie/i\"]; // [[[\"wooKie\",0]]]\n```","code":["\"wooKie boOkie cookie\" regexFind [\".ookie/i\"]; // [[[\"wooKie\",0]]]"]},{"text":"```sqf\n\"wooKie boOkie cookie\" regexFind [\".ookie/\"]; // [[[\"cookie\", 14]]]\n```","code":["\"wooKie boOkie cookie\" regexFind [\".ookie/\"]; // [[[\"cookie\", 14]]]"]},{"text":"Multiline example:\n\n```sqf\n\"co1kie2\nco2kie\" regexFind [\"^co.kie$\"]; // [[[\"co2kie\",9]]]\n```","code":["\"co1kie2\nco2kie\" regexFind [\"^co.kie$\"]; // [[[\"co2kie\",9]]]"]},{"text":"```sqf\n\"I'm a cookie clicker\" regexFind [\"c(.*?)k(.*?)e/i\"]; // [[[\"cookie\",6], [\"oo\", 7], [\"i\", 10]]]\n```","code":["\"I'm a cookie clicker\" regexFind [\"c(.*?)k(.*?)e/i\"]; // [[[\"cookie\",6], [\"oo\", 7], [\"i\", 10]]]"]},{"text":"```sqf\n\"I'm a cookie clicker\" regexFind [\"c(.*?)k(.*?)e\"]; // [[[\"cookie\", 6], [\"oo\", 7], [\"i\", 10]], [[\"clicke\", 13], [\"lic\", 14], [\"\", 18]]]\n```","code":["\"I'm a cookie clicker\" regexFind [\"c(.*?)k(.*?)e\"]; // [[[\"cookie\", 6], [\"oo\", 7], [\"i\", 10]], [[\"clicke\", 13], [\"lic\", 14], [\"\", 18]]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["regexMatch","regexReplace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings - Regular Expression","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"regexMatch","operator":null,"title":"regexMatch","type":"command","url":"https://community.bistudio.com/wiki/regexMatch","revid":369126,"updated":"2024-09-03T10:34:33Z","groups":["Strings - Regular Expression"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether the *haystack* matches the *pattern*.","syntaxes":[{"syntax":"haystack regexMatch pattern","since":null,"effect":null,"exec":null,"params":[{"name":"haystack","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"haystack: String"},{"name":"pattern","type":"String","optional":false,"default":null,"description":"in format regex pattern","types":["String"],"since":null,"text":"pattern: String - in format regex pattern"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if match was found, otherwise false","text":"Boolean - returns true if match was found, otherwise false"},"form":"binary","operator":null,"left":{"text":"haystack","types":["String"]},"right":{"text":"pattern","types":["String"]}}],"examples":[{"text":"```sqf\n\"I'm a coOkIe clicker\" regexMatch \".*cookie.*\"; // true\n```","code":["\"I'm a coOkIe clicker\" regexMatch \".*cookie.*\"; // true"]},{"text":"```sqf\n\"I'm a coOkIe clicker\" regexMatch \".*cookie.*/\"; // false, empty flags == case sensitive\n```","code":["\"I'm a coOkIe clicker\" regexMatch \".*cookie.*/\"; // false, empty flags == case sensitive"]},{"text":"```sqf\nforceUnicode 1;\n\"I'm a coÖkIe clicker\" regexMatch \".*coökie.*\";\n```","code":["forceUnicode 1;\n\"I'm a coÖkIe clicker\" regexMatch \".*coökie.*\";"]},{"text":"```sqf\n\"Cookie clicker\" regexMatch \"cookie/i\"; // false, pattern does not fully match the haystack\n```","code":["\"Cookie clicker\" regexMatch \"cookie/i\"; // false, pattern does not fully match the haystack"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["regexFind","regexReplace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings - Regular Expression","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"regexReplace","operator":null,"title":"regexReplace","type":"command","url":"https://community.bistudio.com/wiki/regexReplace","revid":349515,"updated":"2023-11-08T17:14:41Z","groups":["Strings - Regular Expression"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Searches given *haystack* with given *pattern* and replaces all matches with given *replaceString*.","syntaxes":[{"syntax":"haystack regexReplace [pattern, replaceString]","since":null,"effect":null,"exec":null,"params":[{"name":"haystack","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"haystack: String"},{"name":"pattern","type":"String","optional":false,"default":null,"description":"format regex pattern","types":["String"],"since":null,"text":"pattern: String - format regex pattern"},{"name":"replaceString","type":"String","optional":false,"default":null,"description":"[Reference](https://www.boost.org/doc/libs/1_76_0/libs/regex/doc/html/boost_regex/format/perl_format.html)","types":["String"],"since":null,"text":"replaceString: String - [Reference](https://www.boost.org/doc/libs/1_76_0/libs/regex/doc/html/boost_regex/format/perl_format.html)"}],"returns":{"type":"String","types":["String"],"description":"modified text","text":"String - modified text"},"form":"binary","operator":null,"left":{"text":"haystack","types":["String"]},"right":{"text":"[pattern, replaceString]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"wookie boOkie cookie\" regexReplace [\".oo/gio\", \"[$']\"];                        // \"[kie boOkie cookie]kie [kie cookie]kie [kie]kie\"\n```","code":["\"wookie boOkie cookie\" regexReplace [\".oo/gio\", \"[$']\"];\t\t\t\t\t\t// \"[kie boOkie cookie]kie [kie cookie]kie [kie]kie\""]},{"text":"```sqf\n\"wookie boOkie cookie\" regexReplace [\".oo/gio\", \"[$&]\"];                        // \"[woo]kie [boO]kie [coo]kie\"\n```","code":["\"wookie boOkie cookie\" regexReplace [\".oo/gio\", \"[$&]\"];\t\t\t\t\t\t// \"[woo]kie [boO]kie [coo]kie\""]},{"text":"```sqf\n\"wook1e boOk2e cook3e\" regexReplace [\".oo/gio\", \"[$`]\"];                        // \"[]kie [k1e ]k2e [k2e ]k3e\"\n```","code":["\"wook1e boOk2e cook3e\" regexReplace [\".oo/gio\", \"[$`]\"];\t\t\t\t\t\t// \"[]kie [k1e ]k2e [k2e ]k3e\""]},{"text":"```sqf\n\"wook1e boOk2e cook3e\" regexReplace [\".(oo)(.*?)e\", \"[$2]\"];                    // \"[k1] [k2] [k3]\"\n```","code":["\"wook1e boOk2e cook3e\" regexReplace [\".(oo)(.*?)e\", \"[$2]\"];\t\t\t\t\t// \"[k1] [k2] [k3]\""]},{"text":"```sqf\n\"wOokie boOkie cookie\" regexReplace [\".(?<test>oo)kie/gio\", \"[$+{test}]\"];    // \"[oo] [oO] [oo]\"\n```","code":["\"wOokie boOkie cookie\" regexReplace [\".(?<test>oo)kie/gio\", \"[$+{test}]\"];\t// \"[oo] [oO] [oo]\""]},{"text":"```sqf\n// Make captured group all lower case '\\L' (lower case) or '\\U' (upper case)\n\"ArmA 3 is so awesome!\" regexReplace [\"(rmA 3)\", \"\\L$1\"]; // \"Arma 3 is so awesome!\"\n```","code":["// Make captured group all lower case '\\L' (lower case) or '\\U' (upper case)\n\"ArmA 3 is so awesome!\" regexReplace [\"(rmA 3)\", \"\\L$1\"]; // \"Arma 3 is so awesome!\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["regexMatch","regexFind"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings - Regular Expression","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"registeredTasks","operator":null,"title":"registeredTasks","type":"command","url":"https://community.bistudio.com/wiki/registeredTasks","revid":378146,"updated":"2026-02-25T18:55:11Z","groups":["Briefing","Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all registered task types for the given agent.\nThe values are the names set in `CfgTasks` classes `name` property and are the same names used for unregisterTask.","syntaxes":[{"syntax":"registeredTasks teamMember","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":"teamMember agent","types":["Team Member"],"since":null,"text":"teamMember: Team Member - teamMember agent"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"names of tasks","text":"Array of Strings - names of tasks"},"form":"unary","operator":null,"left":null,"right":{"text":"teamMember","types":["Team Member"]}}],"examples":[{"text":"```sqf\ntasklist = registeredTasks teamMember _agent;\n```","code":["tasklist = registeredTasks teamMember _agent;"]},{"text":"```sqf\n_rabbit = createAgent [\"Rabbit_F\", position player,[], 0, \"None\"];\nhint str registeredTasks teamMember _rabbit; // shows [\"Animal Main Task\"] in Arma 3\n```","code":["_rabbit = createAgent [\"Rabbit_F\", position player,[], 0, \"None\"];\nhint str registeredTasks teamMember _rabbit; // shows [\"Animal Main Task\"] in Arma 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["registerTask","unregisterTask","sendTask","createTask","currentTasks","taskCompleted"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"registerTask","operator":null,"title":"registerTask","type":"command","url":"https://community.bistudio.com/wiki/registerTask","revid":319377,"updated":"2022-05-13T09:23:58Z","groups":["Briefing","Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Registers a new task type. Parameters are defined in the given config class (subclass of `CfgTasks`)","syntaxes":[{"syntax":"teamMember registerTask entryName","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":"teamMember agent","types":["Team Member"],"since":null,"text":"teamMember: Team Member - teamMember agent"},{"name":"entryName","type":"String","optional":false,"default":null,"description":"`CfgTasks` classname","types":["String"],"since":null,"text":"entryName: String - `CfgTasks` classname"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"entryName","types":["String"]}}],"examples":[{"text":"```sqf\nteamMember _agent registerTask \"MyTask\";\n```","code":["teamMember _agent registerTask \"MyTask\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["registeredTasks","unregisterTask","sendTask","createTask","currentTasks","taskCompleted"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"reload","operator":null,"title":"reload","type":"command","url":"https://community.bistudio.com/wiki/reload","revid":347639,"updated":"2023-10-03T09:06:43Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Main syntax: Reload first found muzzle that needs reloading (with some inconsistencies).\n\nAlternative syntax: this syntax allows to reload given muzzle with given magazine while playing proper animation.\nIf *param* is omitted or is empty string, default value is used. The default behaviour is to find the best matching magazine for the provided muzzle from the pool of available magazines.\nIf specific magazine is requested, the reload will fail if unit has run out of this type of magazines. If an empty array `[]` is given, the behaviour is similar to pressing the \"Reload\" key.\nThe command reloads the given muzzle but does not select it. In case of throwable muzzles, each throwable has its own muzzle, they are autoreloaded after throw.\nUsing reload on the throwable muzzle will just swap throwable for another one of the same type from inventory.","syntaxes":[{"syntax":"reload unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}},{"syntax":"unit reload [muzzle, magazine]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person","types":["Object"],"since":null,"text":"unit: Object - person"},{"name":"muzzle","type":"String","optional":true,"default":"currentMuzzle","description":"muzzle name or \"\" for the current muzzle.","types":["String"],"since":null,"text":"muzzle: String - (Optional, default currentMuzzle) muzzle name or \"\" for the current muzzle."},{"name":"magazine","type":"String","optional":true,"default":"given muzzle magazine","description":"magazine name or \"\" for given muzzle's magazine. If given muzzle is currentMuzzle then currentMagazine","types":["String"],"since":null,"text":"magazine: String - (Optional, default given muzzle magazine) magazine name or \"\" for given muzzle's magazine. If given muzzle is currentMuzzle then currentMagazine"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[muzzle, magazine]","types":["Array"]}}],"examples":[{"text":"```sqf\nif (needReload player == 1) then { reload player };\n```","code":["if (needReload player == 1) then { reload player };"]},{"text":"```sqf\nplayer reload [\"GL_3GL_F\", \"1Rnd_HE_Grenade_shell\"];\n```","code":["player reload [\"GL_3GL_F\", \"1Rnd_HE_Grenade_shell\"];"]},{"text":"Reload current muzzle:\n\n```sqf\nplayer reload [];\n```","code":["player reload [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["reloadEnabled","needReload","enableReload","setWeaponReloadingTime"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"reloadEnabled","operator":null,"title":"reloadEnabled","type":"command","url":"https://community.bistudio.com/wiki/reloadEnabled","revid":370147,"updated":"2024-11-02T13:33:13Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for enableReload. The value returned is wether or not auto-reload is enabled for current client only.","syntaxes":[{"syntax":"reloadEnabled unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _aiCanReload = reloadEnabled _unit1;\n```","code":["private _aiCanReload = reloadEnabled _unit1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableReload","reload","needReload"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"remoteControl","operator":null,"title":"remoteControl","type":"command","url":"https://community.bistudio.com/wiki/remoteControl","revid":373364,"updated":"2025-04-30T13:23:33Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Switches on remote control of the unit. The command was Global Argument prior to Arma 3 v2.14). For more info see Remote Control Tutorial.\n\nIf the drone is remote it will get transferred to the player's PC.\n\n> [!NOTE]\n> See also remoteControlled, isRemoteControlling, and #Example 4 for a getter workaround for earlier game versions.\n\n> [!WARNING]\n> Always use switchCamera first (when needed) before using remoteControl as doing it after may lead to unpredictable results.","syntaxes":[{"syntax":"who remoteControl whom","since":null,"effect":null,"exec":null,"params":[{"name":"who","type":"Object","optional":false,"default":null,"description":"controlling unit","types":["Object"],"since":null,"text":"who: Object - controlling unit"},{"name":"whom","type":"Object","optional":false,"default":null,"description":"controlled unit","types":["Object"],"since":null,"text":"whom: Object - controlled unit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"who","types":["Object"]},"right":{"text":"whom","types":["Object"]}}],"examples":[{"text":"Set player remote control of driver:\n\n```sqf\ndriver UAV switchCamera \"Internal\"; // switchCamera required\nplayer remoteControl driver UAV;\n// sometimes switchCamera is not needed\nplayer remoteControl driver UAV;\n```","code":["driver UAV switchCamera \"Internal\"; // switchCamera required\nplayer remoteControl driver UAV;\n// sometimes switchCamera is not needed\nplayer remoteControl driver UAV;"]},{"text":"Return control to player: \n\n> [!IMPORTANT]\n> This method will not work if unit is dead, use the method in Example 3 instead\n\n```sqf\nobjNull remoteControl driver UAV;\n```","code":["objNull remoteControl driver UAV;"]},{"text":"Arma 3 v2.14 Return control to player:\n\n```sqf\nplayer remoteControl objNull;\n```","code":["player remoteControl objNull;"]},{"text":"A dirty hack to return controlling unit because of the absence of dedicated getter:\n\n```sqf\nSQF_fnc_remoteControlledBy =\n{\n    params [\"_obj\"];\n    if (!isNull objectParent _obj) exitWith { UAVControl _obj select 0 };\n    private _res = [objNull];\n    isNil\n    {\n        private _pos = getPosWorld _obj;\n        private _dirUp = [vectorDirVisual _obj, vectorUpVisual _obj];\n        private _anim = animationState _obj;\n        private _dummy = \"PaperCar\" createVehicleLocal [0,0,0];\n        _obj moveInAny _dummy;\n        _res = uavControl _dummy;\n        _obj setPosWorld _pos;\n        _obj setVectorDirAndUp _dirUp;\n        _obj switchMove _anim;\n        deleteVehicle _dummy;\n    };\n    _res select 0\n};\n```\n\nUsage (could be scheduled or unscheduled):\n\n```sqf\n0 spawn\n{\n    player remoteControl bob;\n    systemChat str (bob call SQF_fnc_remoteControlledBy); // B Alpha 1-1:1 (KK)\n    objNull remoteControl bob;\n    systemChat str (bob call SQF_fnc_remoteControlledBy); // <NULL-object>\n};\n```","code":["SQF_fnc_remoteControlledBy =\n{\n\tparams [\"_obj\"];\n\tif (!isNull objectParent _obj) exitWith { UAVControl _obj select 0 };\n\tprivate _res = [objNull];\n\tisNil\n\t{\n\t\tprivate _pos = getPosWorld _obj;\n\t\tprivate _dirUp = [vectorDirVisual _obj, vectorUpVisual _obj];\n\t\tprivate _anim = animationState _obj;\n\t\tprivate _dummy = \"PaperCar\" createVehicleLocal [0,0,0];\n\t\t_obj moveInAny _dummy;\n\t\t_res = uavControl _dummy;\n\t\t_obj setPosWorld _pos;\n\t\t_obj setVectorDirAndUp _dirUp;\n\t\t_obj switchMove _anim;\n\t\tdeleteVehicle _dummy;\n\t};\n\t_res select 0\n};","0 spawn\n{\n\tplayer remoteControl bob;\n\tsystemChat str (bob call SQF_fnc_remoteControlledBy); // B Alpha 1-1:1 (KK)\n\tobjNull remoteControl bob;\n\tsystemChat str (bob call SQF_fnc_remoteControlledBy); // <NULL-object>\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["switchCamera","selectPlayer","UAVControl","remoteControlled","isRemoteControlling","cameraOn","focusOn"],"notes":[{"user":"TeRp","date":"2009-06-04T18:55:00Z","text":"You must use switchCamera in order to remote control a unit.\n\nYou can only remoteControl characters, e.g. if yo want to remote control a car, you have to add a driver and use\n\n```sqf\nplayer remoteControl driver someVehicle\n```"},{"user":"Lou Montana","date":"2010-01-25T14:35:00Z","text":"**Arma 2 v1.05**:\n- You can remoteControl multiple units at the same time.\n- It is not needed to switchCamera to the unit to be able to control it - it is needed to be able to fire with.\n- The switchCamera is fixed : the player can't change internal/external/optics view.\n- Do not think about it like a selectPlayer: it is used to give the control to **the vehicle role the unit is in**.\n- switchCamera to the **vehicle** the unit is in; the camera will go depending the role you are remoteControlling.\n- The AI driver won't follow your vehicle move orders.\n- If the player dies, the death screen will appear, not automatically turning back to the player.\n- If you want to stop the remote control, use objNull as remote controller.\n- Example:\n\n```sqf\nplayer remoteControl driver jeep1;        // will remoteControl it, you still will have full control of the player\njeep1 switchCamera \"internal\";            // fix the camera to the vehicle and not to driver jeep1!\nwaitUntil { !(alive jeep1) || !(alive player) };\nobjNull remoteControl driver jeep1;        // removes the remoteControlling\nplayer switchCamera \"internal\";            // returns to the player\n```"},{"user":"thedawnofallwars","date":"2020-09-17T03:01:00Z","text":"Far and away the easiest way to check the unit remote controlling an AI through Zeus' Remote Control module is using BIS_fnc_moduleRemoteControl_owner\nThis will return the unit in question which you can then run name on to find the controller's name.\n\n```sqf\nprivate _name = \"-\";\n_who = _unit getVariable [\"BIS_fnc_moduleRemoteControl_owner\", objNull];\nif (!isNull _who) then\n{\n    _name = name _who;\n};\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"remoteControlled","operator":null,"title":"remoteControlled","type":"command","url":"https://community.bistudio.com/wiki/remoteControlled","revid":349626,"updated":"2023-11-16T13:24:07Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Returns the player controlling the given unit if the argument is the unit, or the unit controlled by the player if the argument is the player.\n\n> [!IMPORTANT]\n> See also Remote Control Tutorial.","syntaxes":[{"syntax":"remoteControlled unitOrPlayer","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrPlayer","type":"Object","optional":false,"default":null,"description":"unit under remote control or the player controlling a unit","types":["Object"],"since":null,"text":"unitOrPlayer: Object - unit under remote control or the player controlling a unit"}],"returns":{"type":"Object","types":["Object"],"description":"the person controlling the unit or the unit controlled by the player; objNull if not applicable","text":"Object - the person controlling the unit or the unit controlled by the player; objNull if not applicable"},"form":"unary","operator":null,"left":null,"right":{"text":"unitOrPlayer","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _controllingPlayer = remoteControlled _dronePilot;\n```","code":["private _controllingPlayer = remoteControlled _dronePilot;"]},{"text":"```sqf\nprivate _dronePilot = remoteControlled _controllingPlayer;\n```","code":["private _dronePilot = remoteControlled _controllingPlayer;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remoteControl","isRemoteControlling"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"remoteExec","operator":null,"title":"remoteExec","type":"command","url":"https://community.bistudio.com/wiki/remoteExec","revid":370655,"updated":"2025-01-17T21:17:19Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Asks the server to execute the given function or script command on the given target machine(s).\n- Functions are executed in the scheduled environment; suspension is allowed.\n- Script commands are executed in the unscheduled environment; suspension is not allowed (see #Example 7).\n\nRead Arma 3: Remote Execution for more information about remote execution, security features and JIP techniques.\n\n> [!NOTE]\n> remoteExec/remoteExecCall can be used in single player as well, as it is considered as player-hosted multiplayer.\n\n> [!IMPORTANT]\n> The direct execution of call or spawn via remoteExec (or remoteExecCall) should be avoided to prevent issues in cases where the remote execution of call or spawn is blocked by CfgRemoteExec. It is instead recommended to create a function to be itself remote-executed.\n\n> [!WARNING]\n> The order of persistent remote execution for JIP players is not guaranteed, i.e. the order in which multiple calls are added is not necessarily the order they will be executed for joining player.","syntaxes":[{"syntax":"params remoteExec [order, targets, JIP]","since":null,"effect":null,"exec":null,"params":[{"name":"params","type":"Anything but Structured Text","optional":false,"default":null,"description":"*order*'s parameter \n\n> [!IMPORTANT]\n> Structured Text is **not** meant to be sent over network.","types":["Anything","Structured Text"],"since":null,"text":"**params**: Anything **but** Structured Text - *order*'s parameter \n\n> [!IMPORTANT]\n> Structured Text is **not** meant to be sent over network."},{"name":"order","type":"String","optional":false,"default":null,"description":"function or command name; while any function or command can be used here, only those allowed by CfgRemoteExec will actually be executed","types":["String"],"since":null,"text":"**order**: String - function or command name; while any function or command can be used here, only those allowed by CfgRemoteExec will actually be executed"},{"name":"targets","type":null,"optional":true,"default":"0","description":":\n- Number (See also Machine network ID):\n  - **0:** the order will be executed globally, i.e. on the server and every connected client, including the machine where remoteExec originated\n  - **2:** the order will only be executed on the server - is both dedicated and hosted server. See for more info\n  - **Other number:** the order will be executed on the machine where clientOwner matches the given number\n  - **Negative number:** the effect is inverted: **-2** means every client but not the server, **-12** means the server and every client, except for the client where clientOwner returns 12\n- Object - the order will be executed where the given object is local\n- String - interpreted as an Identifier (variable name); the function / command will be executed where the object or group identified by the variable with the provided name is local\n- Side - the order will be executed on machines where the player is on the specified side\n- Group - the order will be executed on machines **where the player is in the specified group** (**not** where said group is local!)\n- Array - array of any combination of the types listed above","types":[],"since":null,"text":"**targets** - (Optional, default 0):\n- Number (See also Machine network ID):\n  - **0:** the order will be executed globally, i.e. on the server and every connected client, including the machine where remoteExec originated\n  - **2:** the order will only be executed on the server - is both dedicated and hosted server. See for more info\n  - **Other number:** the order will be executed on the machine where clientOwner matches the given number\n  - **Negative number:** the effect is inverted: **-2** means every client but not the server, **-12** means the server and every client, except for the client where clientOwner returns 12\n- Object - the order will be executed where the given object is local\n- String - interpreted as an Identifier (variable name); the function / command will be executed where the object or group identified by the variable with the provided name is local\n- Side - the order will be executed on machines where the player is on the specified side\n- Group - the order will be executed on machines **where the player is in the specified group** (**not** where said group is local!)\n- Array - array of any combination of the types listed above"},{"name":"JIP","type":null,"optional":true,"default":"false","description":":\n- Boolean - if true, a unique JIP ID is generated and the remoteExec statement is added to the JIP queue from which it will be executed for every JIP\n- String:\n  - if the string is empty, it is interpreted as false\n  - if the string is in format \"Number:Number\" (e.g. \"0:0\"), it is interpreted as a netId (see below)\n  - else the string is treated as a custom JIP ID and the remoteExec statement is added to the JIP queue, replacing statements that have the same JIP ID\n- Object, Group or netId - the persistent execution of the remoteExec statement is attached to the given object or group, replacing any previous statement that has the same JIP ID.\nWhen the object / group is deleted, the remoteExec statement is automatically removed from the JIP queue\n\nThe **JIP** parameter can only be used if the **targets** parameter is 0 or a negative number.\n\nSee also Example 3 on how to remove statements from the JIP queue.","types":[],"since":null,"text":"**JIP** - (Optional, default false):\n- Boolean - if true, a unique JIP ID is generated and the remoteExec statement is added to the JIP queue from which it will be executed for every JIP\n- String:\n  - if the string is empty, it is interpreted as false\n  - if the string is in format \"Number:Number\" (e.g. \"0:0\"), it is interpreted as a netId (see below)\n  - else the string is treated as a custom JIP ID and the remoteExec statement is added to the JIP queue, replacing statements that have the same JIP ID\n- Object, Group or netId - the persistent execution of the remoteExec statement is attached to the given object or group, replacing any previous statement that has the same JIP ID.\nWhen the object / group is deleted, the remoteExec statement is automatically removed from the JIP queue\n\nThe **JIP** parameter can only be used if the **targets** parameter is 0 or a negative number.\n\nSee also Example 3 on how to remove statements from the JIP queue."}],"returns":{"type":"- nil","types":["nil"],"description":"In case of error. - String - In case of success (see remoteExecutedJIPID). - If the JIP parameter was false or an empty string, the return value is \"\". - If the JIP parameter was true or a custom JIP ID, the JIP ID is returned. - If the JIP parameter was an Object, a Group or a netId, the (corresponding) netId is returned.","text":"- nil - In case of error.\n- String - In case of success (see remoteExecutedJIPID).\n  - If the **JIP** parameter was false or an empty string, the return value is \"\".\n  - If the **JIP** parameter was true or a custom JIP ID, the JIP ID is returned.\n  - If the **JIP** parameter was an Object, a Group or a netId, the (corresponding) netId is returned."},"form":"binary","operator":null,"left":{"text":"params","types":["Anything","Structured Text"]},"right":{"text":"[order, targets, JIP]","types":["Array"]}},{"syntax":"remoteExec [functionName, targets, JIP]","since":null,"effect":null,"exec":null,"params":[{"name":"functionName","type":"String","optional":false,"default":null,"description":"see the main syntax above for more details.","types":["String"],"since":null,"text":"**functionName**: String - see the main syntax above for more details."},{"name":"targets","type":"Number, Object, String, Side, Group or Array","optional":true,"default":"0","description":"see the main syntax above for more details.","types":["Number","Object","String","Side","Group","Array"],"since":null,"text":"**targets**: Number, Object, String, Side, Group or Array - (Optional, default 0) see the main syntax above for more details."},{"name":"JIP","type":"Boolean, String, Object, Group or netId","optional":true,"default":"false","description":"see the main syntax above for more details.","types":["Boolean","String","Object","Group","netId"],"since":null,"text":"**JIP**: Boolean, String, Object, Group or netId - (Optional, default false) see the main syntax above for more details."}],"returns":{"type":"nil or String","types":["nil","String"],"description":"see the main syntax above for more details.","text":"nil or String - see the main syntax above for more details."},"form":"unary","operator":null,"left":null,"right":{"text":"[functionName, targets, JIP]","types":["Array"]}}],"examples":[{"text":"How to write remoteExec/remoteExecCall with arguments - note the colours:\n`hint \"Hello\"; // becomes [\"Hello\"] remoteExec [\"hint\"]; \"Hello\" remoteExec [\"hint\"]; // alternatively`\n\n`unit1 setFace \"Miller\"; // becomes [unit1, \"Miller\"] remoteExec [\"setFace\"];`\n\n`cutRsc [\"\", \"BLACK OUT\"]; // becomes [[\"\", \"BLACK OUT\"]] remoteExec [\"cutRsc\"]; // double brackets are needed as the unary command takes an array`\n\n`// functions, however, do not need double squared brackets [\"line 1\", \"line 2\"] spawn BIS_fnc_infoText; // becomes [\"line 1\", \"line 2\"] remoteExec [\"BIS_fnc_infoText\"];`","code":[]},{"text":"send an order to specific machines:\n\n```sqf\n\"message\" remoteExec [\"hint\"];                    // sends a hint message to everyone\n\"message\" remoteExec [\"hint\", 0];                // sends a hint message to everyone, identical to \"message\" remoteExec [\"hint\"]\n\"message\" remoteExec [\"hint\", -2];                // sends a hint message to everybody but the server (also not hosted server)\n\"message\" remoteExec [\"hint\", myCar];            // sends a hint message where myCar is local\n\"message\" remoteExec [\"hint\", -clientOwner];    // sends a hint message to everybody but the current machine\n```","code":["\"message\" remoteExec [\"hint\"];\t\t\t\t\t// sends a hint message to everyone\n\"message\" remoteExec [\"hint\", 0];\t\t\t\t// sends a hint message to everyone, identical to \"message\" remoteExec [\"hint\"]\n\"message\" remoteExec [\"hint\", -2];\t\t\t\t// sends a hint message to everybody but the server (also not hosted server)\n\"message\" remoteExec [\"hint\", myCar];\t\t\t// sends a hint message where myCar is local\n\"message\" remoteExec [\"hint\", -clientOwner];\t// sends a hint message to everybody but the current machine"]},{"text":"Add statements to the JIP queue:\n\n```sqf\nprivate _jipId = [\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, true]; // adds the hint to the JIP queue and returns the JIP queue order id\nwaitUntil { canMove _car };\nremoteExec [\"\", _jipId]; // the systemChat order is removed from the JIP queue\n```\n\n```sqf\n[\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, _queueObject];\n// ...\nremoteExec [\"\", _queueObject]; // the order attached to _queueObject is removed\n```\n\n```sqf\nprivate _jipId = [\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, \"MY_JIP_ID\"]; // _jipId is actually \"MY_JIP_ID\" now\nwaitUntil { canMove _car };\n[\"mission state: the car is repaired\"] remoteExec [\"systemChat\", 0, \"MY_JIP_ID\"]; // this order replaces the previous one\n// ...\nremoteExec [\"\", \"MY_JIP_ID\"]; // the \"MY_JIP_ID\" order is removed from the JIP queue\n```","code":["private _jipId = [\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, true]; // adds the hint to the JIP queue and returns the JIP queue order id\nwaitUntil { canMove _car };\nremoteExec [\"\", _jipId]; // the systemChat order is removed from the JIP queue","[\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, _queueObject];\n// ...\nremoteExec [\"\", _queueObject]; // the order attached to _queueObject is removed","private _jipId = [\"mission state: the car is broken\"] remoteExec [\"systemChat\", 0, \"MY_JIP_ID\"]; // _jipId is actually \"MY_JIP_ID\" now\nwaitUntil { canMove _car };\n[\"mission state: the car is repaired\"] remoteExec [\"systemChat\", 0, \"MY_JIP_ID\"]; // this order replaces the previous one\n// ...\nremoteExec [\"\", \"MY_JIP_ID\"]; // the \"MY_JIP_ID\" order is removed from the JIP queue"]},{"text":"Some more complex examples:\n\n```sqf\n[\"Open\", true] remoteExec [\"BIS_fnc_arsenal\", MyTargetPlayer];\n[MyCurator, [[MyObject1, MyObject2], false]] remoteExec [\"addCuratorEditableObjects\", 2];\n```","code":["[\"Open\", true] remoteExec [\"BIS_fnc_arsenal\", MyTargetPlayer];\n[MyCurator, [[MyObject1, MyObject2], false]] remoteExec [\"addCuratorEditableObjects\", 2];"]},{"text":"A tricky example: executing `player setAmmo [primaryWeapon player, 1];` (on machines where the player is in MyGroup):\n\n```sqf\n[player, [primaryWeapon player, 1]] remoteExec [\"setAmmo\", MyGroup];            // WRONG:    the local player object is used here!\n[{ player setAmmo [primaryWeapon player, 1]; }] remoteExec [\"call\", MyGroup];    // CORRECT:    the remote player object is used here\n```","code":["[player, [primaryWeapon player, 1]] remoteExec [\"setAmmo\", MyGroup];\t\t\t// WRONG:\tthe local player object is used here!\n[{ player setAmmo [primaryWeapon player, 1]; }] remoteExec [\"call\", MyGroup];\t// CORRECT:\tthe remote player object is used here"]},{"text":"**Multiplayer Scripting \"performance trick\"**\n\nThis `[0, -2] select isDedicated` check is worth it to avoid **function** server-side calculations only. See also #Example 9 for an advanced solution.\n\n```sqf\n[\"message\"] remoteExec [\"BIS_fnc_infoText\"];                                // not ideal - the function will still run on the dedicated server for nothing\n[\"message\"] remoteExec [\"BIS_fnc_infoText\", [0, -2] select isDedicated];    // ideal - the dedicated server will not run the code, a player-hosted server will\n\n[\"message\"] remoteExec [\"hint\", [0, -2] select isDedicated];    // the check is too expensive to be worthy - it becomes worthy if the server logs an RPT warning\n[\"message\"] remoteExec [\"hint\"];                                // the (dedicated) server will automatically ditch hint usage due to it not having an interface\n\nprivate _allPlayersTarget = [0, -2] select isDedicated;            // caching the result for multiple usages makes it worthy - think of headless clients as well\n[\"message 1\"] remoteExec [\"hint\", _allPlayersTarget];\n[\"message 2\"] remoteExec [\"hint\", _allPlayersTarget];\n```\n\n> [!NOTE]\n> See #Example 9 below for an advanced example.","code":["[\"message\"] remoteExec [\"BIS_fnc_infoText\"];\t\t\t\t\t\t\t\t// not ideal - the function will still run on the dedicated server for nothing\n[\"message\"] remoteExec [\"BIS_fnc_infoText\", [0, -2] select isDedicated];\t// ideal - the dedicated server will not run the code, a player-hosted server will\n\n[\"message\"] remoteExec [\"hint\", [0, -2] select isDedicated];\t// the check is too expensive to be worthy - it becomes worthy if the server logs an RPT warning\n[\"message\"] remoteExec [\"hint\"];\t\t\t\t\t\t\t\t// the (dedicated) server will automatically ditch hint usage due to it not having an interface\n\nprivate _allPlayersTarget = [0, -2] select isDedicated;\t\t\t// caching the result for multiple usages makes it worthy - think of headless clients as well\n[\"message 1\"] remoteExec [\"hint\", _allPlayersTarget];\n[\"message 2\"] remoteExec [\"hint\", _allPlayersTarget];"]},{"text":"As said in the description: **commands** will be executed in an unscheduled environment\n\n```sqf\n[{ sleep 1 }] remoteExec [\"call\"]; // will throw an error: it is forbidden to use sleep (or waitUntil, etc) in unscheduled environment\n```","code":["[{ sleep 1 }] remoteExec [\"call\"]; // will throw an error: it is forbidden to use sleep (or waitUntil, etc) in unscheduled environment"]},{"text":"```sqf\n\"Message 1\" remoteExec [\"systemChat\"];\n\"Message 2\" remoteExec [\"systemChat\"];\n// will result in\n// \"Message 1\"\n// \"Message 2\"\n// in this exact order on clients\n```","code":["\"Message 1\" remoteExec [\"systemChat\"];\n\"Message 2\" remoteExec [\"systemChat\"];\n// will result in\n// \"Message 1\"\n// \"Message 2\"\n// in this exact order on clients"]},{"text":"It is possible to create a \"to all players\" remote exec target variable:\n\n```sqf\nif (isServer) then\n{\n    TO_ALL_PLAYERS = [0, -2] select isDedicated;\n    publicVariable \"TO_ALL_PLAYERS\";\n};\n```\n\nIf Headless Clients are involved:\n\n```sqf\nif (isServer) then\n{\n    TO_ALL_PLAYERS = [0, -2] select isDedicated;\n\n    private _allNegativeHCs = allPlayers apply { getPlayerID _x } select { _x != \"-1\" }    // all valid playerIDs\n        apply { getUserInfo _x } select { _x select 7 }                                    // filter by HC\n        apply { -(_x select 1) };                                                        // get negative network ID\n\n    if (_allNegativeHCs isNotEqualTo []) then\n    {\n        TO_ALL_PLAYERS = [TO_ALL_PLAYERS] + _allNegativeHCs;\n    };\n\n    publicVariable \"TO_ALL_PLAYERS\";\n\n    addMissionEventHandler [\"OnUserConnected\", {\n        params [\"_networkId\"];\n        private _userInfo = getUserInfo _networkId;\n        if !(_userInfo select 7) exitWith {};    // not a HC\n\n        if (TO_ALL_PLAYERS isEqualType 0) then    // number to array conversion\n        {\n            if (TO_ALL_PLAYERS == 0) then        // player-hosted\n            {\n                TO_ALL_PLAYERS = [-(_userInfo select 1)];\n            }\n            else                                // -2, dedicated server\n            {\n                TO_ALL_PLAYERS = [TO_ALL_PLAYERS, -(_userInfo select 1)];\n            };\n        }\n        else                                    // already an array\n        {\n            TO_ALL_PLAYERS pushBackUnique -(_userInfo select 1);\n        };\n\n        publicVariable \"TO_ALL_PLAYERS\";\n    }];\n};\n```\n\n```sqf\n// client or server will always target the good machines\n[\"Yay!\"] remoteExec [\"hint\", TO_ALL_PLAYERS];\n```","code":["if (isServer) then\n{\n\tTO_ALL_PLAYERS = [0, -2] select isDedicated;\n\tpublicVariable \"TO_ALL_PLAYERS\";\n};","if (isServer) then\n{\n\tTO_ALL_PLAYERS = [0, -2] select isDedicated;\n\n\tprivate _allNegativeHCs = allPlayers apply { getPlayerID _x } select { _x != \"-1\" }\t// all valid playerIDs\n\t\tapply { getUserInfo _x } select { _x select 7 }\t\t\t\t\t\t\t\t\t// filter by HC\n\t\tapply { -(_x select 1) };\t\t\t\t\t\t\t\t\t\t\t\t\t\t// get negative network ID\n\n\tif (_allNegativeHCs isNotEqualTo []) then\n\t{\n\t\tTO_ALL_PLAYERS = [TO_ALL_PLAYERS] + _allNegativeHCs;\n\t};\n\n\tpublicVariable \"TO_ALL_PLAYERS\";\n\n\taddMissionEventHandler [\"OnUserConnected\", {\n\t\tparams [\"_networkId\"];\n\t\tprivate _userInfo = getUserInfo _networkId;\n\t\tif !(_userInfo select 7) exitWith {};\t// not a HC\n\n\t\tif (TO_ALL_PLAYERS isEqualType 0) then\t// number to array conversion\n\t\t{\n\t\t\tif (TO_ALL_PLAYERS == 0) then\t\t// player-hosted\n\t\t\t{\n\t\t\t\tTO_ALL_PLAYERS = [-(_userInfo select 1)];\n\t\t\t}\n\t\t\telse\t\t\t\t\t\t\t\t// -2, dedicated server\n\t\t\t{\n\t\t\t\tTO_ALL_PLAYERS = [TO_ALL_PLAYERS, -(_userInfo select 1)];\n\t\t\t};\n\t\t}\n\t\telse\t\t\t\t\t\t\t\t\t// already an array\n\t\t{\n\t\t\tTO_ALL_PLAYERS pushBackUnique -(_userInfo select 1);\n\t\t};\n\n\t\tpublicVariable \"TO_ALL_PLAYERS\";\n\t}];\n};","// client or server will always target the good machines\n[\"Yay!\"] remoteExec [\"hint\", TO_ALL_PLAYERS];"]}],"multiplayer":"Remote executions are queued and are therefore executed in the same order on remote clients (see #Example 8).","problems":null,"aliases":[],"see_also":["Multiplayer Scripting","remoteExecCall","remoteExecutedOwner","isRemoteExecuted","isRemoteExecutedJIP","Arma 3: Remote Execution","canSuspend","BIS_fnc_MP","remoteExecutedJIPID"],"notes":[{"user":"AgentRev","date":"2015-12-29T20:28:00Z","text":"remoteExec and remoteExecCall are currently filtered by BattlEye's remoteexec.txt, the string analyzed by BE is formatted the same way as the following example's output:\n\n```sqf\nformat [\"%1 %2\", functionName, str params]\n```\n\nIf CfgRemoteExec `class Functions` is set to , the following remoteexec.txt exclusion can be used to safely allow all whitelisted *_fnc_* functions taking an array as parameter to go through:\n\n```sqf\n!=\"\\w+?_fnc_\\w+? \\[[\\S\\s]*\\]\"\n```\n\nAny attempt to exploit this exclusion using other RE methods like createUnit will run into \"Error Missing ;\" without any malicious code being executed. Mod makers should refrain from remote-executing raw commands from clients, as they require individual exclusions, and instead use *_fnc_* functions taking an array as parameter, which are covered by the above exclusion."},{"user":"Pierre MGI","date":"2017-01-30T18:35:00Z","text":"```sqf\n[someArgs] remoteExec ['someCommand', 2, true];\n```\n\nwill fail, as you can't use JIP and remoteExec on server only\n\n```sqf\n[someArgs] remoteExec ['someCommand', 2]; // works\n```"},{"user":"7erra","date":"2021-03-05T00:48:00Z","text":"The remoteExec'ed function only has to exist on the target machine. For example:\n\n```sqf\n// initPlayerLocal.sqf\nTAG_fnc_testRemote = {\n    hint \"Remote Exec Received\";\n};\n```\n\n```sqf\n// executed on a DEDICATED server\nremoteExec [\"TAG_fnc_testRemote\", -2];\n```\n\nWill display a hint for every client. This is especially useful for when the server is running a mod that is not required by clients."},{"user":"Sa-Matra","date":"2024-09-19T08:33:05Z","text":"It is not possible to use two negative owners to exclude two clients, you'll end up REing all clients:\n\n```sqf\nargs remoteExec [\"func\", [-2, -3]]; // Doesn't work, gonna execute on every client\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Remote Execution","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"remoteExecCall","operator":null,"title":"remoteExecCall","type":"command","url":"https://community.bistudio.com/wiki/remoteExecCall","revid":369336,"updated":"2024-09-03T18:43:00Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unscheduled version of remoteExec. The only difference between remoteExec and remoteExecCall is that remoteExecCall will run **functions** in unscheduled environment.\n\n> [!IMPORTANT]\n> The \"Call\" in remoteExecCall only means that the remote execution will take place in unscheduled environment and does **not** mean it will happen right away (see #Example 3).","syntaxes":[{"syntax":"see remoteExec","since":null,"effect":null,"exec":null,"params":[{"name":"see remoteExec","type":null,"optional":false,"default":null,"description":null,"types":["remoteExec"],"since":null,"text":"see remoteExec"}],"returns":{"type":"see remoteExec","types":["remoteExec"],"description":null,"text":"see remoteExec"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n[\"hello\"] remoteExec [\"hint\"];        // runs unscheduled\n[\"hello\"] remoteExecCall [\"hint\"];    // no difference at all\n```","code":["[\"hello\"] remoteExec [\"hint\"];\t\t// runs unscheduled\n[\"hello\"] remoteExecCall [\"hint\"];\t// no difference at all"]},{"text":"```sqf\n[\"my message\"] remoteExec [\"BIS_fnc_infoText\"];        // correct\n[\"my message\"] remoteExecCall [\"BIS_fnc_infoText\"];    // wrong - BIS_fnc_infoText needs a scheduled environment, see its spawn need\n```","code":["[\"my message\"] remoteExec [\"BIS_fnc_infoText\"];\t\t// correct\n[\"my message\"] remoteExecCall [\"BIS_fnc_infoText\"];\t// wrong - BIS_fnc_infoText needs a scheduled environment, see its spawn need"]},{"text":"```sqf\nremoteExecCall [\"fnc1\"];\ncall fnc2;    // fnc1 may or may not be executed after fnc2\n\ncall fnc1;\ncall fnc2;    // fnc2 will be executed after fnc1\n```","code":["remoteExecCall [\"fnc1\"];\ncall fnc2;\t// fnc1 may or may not be executed after fnc2\n\ncall fnc1;\ncall fnc2;\t// fnc2 will be executed after fnc1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remoteExec","remoteExecutedOwner","isRemoteExecuted","isRemoteExecutedJIP","Arma 3: Remote Execution","canSuspend","BIS_fnc_MP","remoteExecutedJIPID"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Remote Execution","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"remoteExecutedJIPID","operator":null,"title":"remoteExecutedJIPID","type":"command","url":"https://community.bistudio.com/wiki/remoteExecutedJIPID","revid":369745,"updated":"2024-10-08T15:06:58Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns JIP ID of the persistent call generated from JIP queue for the joining player (see remoteExec).","syntaxes":[{"syntax":"remoteExecutedJIPID","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":"JIP ID","text":"String - JIP ID"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_jipid = remoteExecutedJIPID;\n```","code":["_jipid = remoteExecutedJIPID;"]},{"text":"```sqf\n/* \nHave mission with 2 players.\nFirst player starts local server and executes given code\nSecond player joins the server and sees the 'all good' message\nSecond player logs out \nFirst player kills 'bob'\nSecond player joins back and sees 'removing JIP call' message\nSecond player logs out then joins back in, no message as call was removed\n*/\n\nprivate _fnc = \n{\n    if (isRemoteExecutedJIP) then\n    {\n        remoteExecutedJIPID splitString \"|\" params [\"_myID\", \"_netID\"];\n        private _obj = objectFromNetId _netID;\n        if (!alive _obj) then\n        {\n            hint \"object is dead or deleted, removing JIP call\";\n            remoteExec [\"\", remoteExecutedJIPID];\n        }\n        else\n        {\n            hint \"JIP call, all good, doing something\";\n        };\n    };\n};\n\nprivate _bob = group player createUnit [typeOf player, position player, [], 0, \"NONE\"];\nprivate _myID = \"lalala\";\nprivate _jipID = [_myID, netId _bob] joinString \"|\";\n[[], _fnc] remoteExec [\"call\", 0, _jipId];\n```","code":["/* \nHave mission with 2 players.\nFirst player starts local server and executes given code\nSecond player joins the server and sees the 'all good' message\nSecond player logs out \nFirst player kills 'bob'\nSecond player joins back and sees 'removing JIP call' message\nSecond player logs out then joins back in, no message as call was removed\n*/\n\nprivate _fnc = \n{\n\tif (isRemoteExecutedJIP) then\n\t{\n\t\tremoteExecutedJIPID splitString \"|\" params [\"_myID\", \"_netID\"];\n\t\tprivate _obj = objectFromNetId _netID;\n\t\tif (!alive _obj) then\n\t\t{\n\t\t\thint \"object is dead or deleted, removing JIP call\";\n\t\t\tremoteExec [\"\", remoteExecutedJIPID];\n\t\t}\n\t\telse\n\t\t{\n\t\t\thint \"JIP call, all good, doing something\";\n\t\t};\n\t};\n};\n\nprivate _bob = group player createUnit [typeOf player, position player, [], 0, \"NONE\"];\nprivate _myID = \"lalala\";\nprivate _jipID = [_myID, netId _bob] joinString \"|\";\n[[], _fnc] remoteExec [\"call\", 0, _jipId];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["remoteExecutedOwner","isRemoteExecuted","isRemoteExecutedJIP","remoteExec","remoteExecCall","canSuspend","publicVariableClient","admin","owner","clientOwner","groupOwner","didJIPOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"remoteExecutedOwner","operator":null,"title":"remoteExecutedOwner","type":"command","url":"https://community.bistudio.com/wiki/remoteExecutedOwner","revid":365035,"updated":"2024-07-14T12:57:10Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the machine network ID of the client that initiated Remote Execution.\n\n> [!IMPORTANT]\n> Running this command\n> - in a Single Player environment\n> - outside of a remote-executed context\n> - in a remote-executed context received from a Headless Client\n> will return **0** by design. To check if the context is remote executed, use isRemoteExecuted or isRemoteExecutedJIP.","syntaxes":[{"syntax":"remoteExecutedOwner","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"returns zero in the specific cases listed in the #Description","text":"Number - returns zero in the specific cases listed in the #Description"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _callerRE = remoteExecutedOwner;\n```","code":["private _callerRE = remoteExecutedOwner;"]},{"text":"Send request to the server and get immediate response:\n\n```sqf\n{\n    // in this scope, the remoteExecutedOwner equals clientOwner of the sender\n    // so using it as target in remoteExec will send response right back at him\n    [\n        time, // mission time value on the server\n        {\n            hint format\n            [\n                \"Request received!\\nMission time value on the server is: %1\",\n                _this\n            ];\n        }\n    ]\n    remoteExec [\"call\", remoteExecutedOwner]; // server response to the sender\n} \nremoteExec [\"call\", 2]; // send request to server\n```","code":["{\n\t// in this scope, the remoteExecutedOwner equals clientOwner of the sender\n\t// so using it as target in remoteExec will send response right back at him\n\t[\n\t\ttime, // mission time value on the server\n\t\t{\n\t\t\thint format\n\t\t\t[\n\t\t\t\t\"Request received!\\nMission time value on the server is: %1\",\n\t\t\t\t_this\n\t\t\t];\n\t\t}\n\t]\n\tremoteExec [\"call\", remoteExecutedOwner]; // server response to the sender\n} \nremoteExec [\"call\", 2]; // send request to server"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isRemoteExecuted","isRemoteExecutedJIP","remoteExecutedJIPID","remoteExec","remoteExecCall","canSuspend","publicVariableClient","admin","owner","clientOwner","groupOwner","didJIPOwner"],"notes":[{"user":"Demellion","date":"2017-09-11T09:31:00Z","text":"Always be sure to check if the remoteExecutedOwner is not equal to 0 when sending a remoteExec/remoteExecCall packet back, as this will result in sending packet to ANYONE (0):\n\n```sqf\nif (remoteExecutedOwner isEqualTo 0) exitWith {}; // invalid RE owner\n_gearArray remoteExecCall ['someGearFunction', remoteExecutedOwner];\n```\n\nWill prevent from code being accidentally sent to everyone on the server."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Remote Execution","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"remove3DENConnection","operator":null,"title":"remove3DENConnection","type":"command","url":"https://community.bistudio.com/wiki/remove3DENConnection","revid":348517,"updated":"2023-11-08T13:06:00Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes connection between entities.","syntaxes":[{"syntax":"remove3DENConnection [type, from, to]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"connection class from *Cfg3DEN >> Connections*","types":["String"],"since":null,"text":"type: String - connection class from *Cfg3DEN >> Connections*"},{"name":"from","type":"Array of Eden Entities","optional":false,"default":null,"description":"entities which has a connection","types":["Array","Eden Entity"],"since":null,"text":"from: Array of Eden Entities - entities which has a connection"},{"name":"to","type":"Eden Entity","optional":false,"default":null,"description":"connection target","types":["Eden Entity"],"since":null,"text":"to: Eden Entity - connection target"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true If the connection was removed","text":"Boolean - true If the connection was removed"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, from, to]","types":["Array"]}}],"examples":[{"text":"```sqf\nremove3DENConnection [\"RandomStart\", get3DENSelected \"Object\", \"marker_0\"];// Remove random start on marker \"marker_0\" from all selected objects.\n```","code":["remove3DENConnection [\"RandomStart\", get3DENSelected \"Object\", \"marker_0\"];// Remove random start on marker \"marker_0\" from all selected objects."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENConnection","get3DENConnections"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"remove3DENEventHandler","operator":null,"title":"remove3DENEventHandler","type":"command","url":"https://community.bistudio.com/wiki/remove3DENEventHandler","revid":369147,"updated":"2024-09-03T10:34:38Z","groups":["Eden Editor","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes Eden Editor event handler of given type and ID.\n\nSee the list of all Eden Editor Event Handlers.","syntaxes":[{"syntax":"remove3DENEventHandler [type,id]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"name of event handler","types":["String"],"since":null,"text":"type: String - name of event handler"},{"name":"id","type":"Number","optional":false,"default":null,"description":"ID of event handler, returned by add3DENEventHandler","types":["Number"],"since":null,"text":"id: Number - ID of event handler, returned by add3DENEventHandler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[type,id]","types":["Array"]}}],"examples":[{"text":"```sqf\neh = add3DENEventHandler [\"onUndo\",{systemChat \"Zip...\"}];\nremove3DENEventHandler [\"onUndo\",eh];\n```","code":["eh = add3DENEventHandler [\"onUndo\",{systemChat \"Zip...\"}];\nremove3DENEventHandler [\"onUndo\",eh];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENEventHandler","removeAll3DENEventHandlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Command Group: Event Handlers","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"remove3DENLayer","operator":null,"title":"remove3DENLayer","type":"command","url":"https://community.bistudio.com/wiki/remove3DENLayer","revid":351677,"updated":"2023-12-20T10:39:52Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove Eden Editor editing layer.\n\n> [!NOTE]\n> delete3DENEntities seems to be more reliable.","syntaxes":[{"syntax":"remove3DENLayer layerID","since":null,"effect":null,"exec":null,"params":[{"name":"layerID","type":"Number","optional":false,"default":null,"description":"layer ID as returned by add3DENLayer command","types":["Number"],"since":null,"text":"layerID : Number - layer ID as returned by add3DENLayer command"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the layer was removed successfully (i.e., correct layer ID was used)","text":"Boolean - true if the layer was removed successfully (i.e., correct layer ID was used)"},"form":"unary","operator":null,"left":null,"right":{"text":"layerID","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _myLayer = -1 add3DENLayer \"Enemy Base\";\nremove3DENLayer _myLayer;\n```","code":["private _myLayer = -1 add3DENLayer \"Enemy Base\";\nremove3DENLayer _myLayer;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENLayer","set3DENLayer","get3DENLayerEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"removeAction","operator":null,"title":"removeAction","type":"command","url":"https://community.bistudio.com/wiki/removeAction","revid":348246,"updated":"2023-11-08T11:40:32Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.20"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.20"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Removes user added action with given ID. This only removes actions added with the addAction command. You cannot remove default game actions, such as reload.","syntaxes":[{"syntax":"unit removeAction actionID","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit, vehicle or static object","types":["Object"],"since":null,"text":"unit: Object - unit, vehicle or static object"},{"name":"actionID","type":"Number","optional":false,"default":null,"description":"action ID returned by addAction","types":["Number"],"since":null,"text":"actionID: Number - action ID returned by addAction"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"actionID","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer removeAction 0;\n```","code":["player removeAction 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAllActions","action"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.20","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeAll3DENEventHandlers","operator":null,"title":"removeAll3DENEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAll3DENEventHandlers","revid":342137,"updated":"2023-07-09T12:26:45Z","groups":["Eden Editor","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all Eden Editor event handlers of given type.\n\nSee the list of all Eden Editor Event Handlers.","syntaxes":[{"syntax":"removeAll3DENEventHandlers type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"name of event handler","types":["String"],"since":null,"text":"type: String - name of event handler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nremoveAll3DENEventHandlers \"onUndo\";\n```","code":["removeAll3DENEventHandlers \"onUndo\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENEventHandler","remove3DENEventHandler"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Command Group: Event Handlers","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"removeAllActions","operator":null,"title":"removeAllActions","type":"command","url":"https://community.bistudio.com/wiki/removeAllActions","revid":329338,"updated":"2022-07-27T10:37:51Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Removes all unit's user added actions.\n\n> [!NOTE]\n> This command's syntax was `unit removeAllActions number` from Arma 3 v0.50 to v1.06.\n\n> [!IMPORTANT]\n> Usage of this command is usually a bad practice unless justified by the situation; removing all actions in order to remove all actions that *one* added is not a good method as a mod or another script could have added its own actions as well and see them removed. Instead, store the action id returned by addAction either in a script variable or using setVariable.","syntaxes":[{"syntax":"removeAllActions obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllActions player;\n```","code":["removeAllActions player;"]},{"text":"Do\n\n```sqf\nprivate _actionId = player addAction [\"Heal self\", { player setDamage 0; }];\n// ...\nplayer removeAction _actionId;\n```\n\nDon't\n\n```sqf\nplayer addAction [\"Heal self\", { player setDamage 0; }];\n// ...\nremoveAllActions player;\n```","code":["private _actionId = player addAction [\"Heal self\", { player setDamage 0; }];\n// ...\nplayer removeAction _actionId;","player addAction [\"Heal self\", { player setDamage 0; }];\n// ...\nremoveAllActions player;"]},{"text":"Do\n\n```sqf\nplayer addAction [\"Heal self (once)\", {\n    params [\"_target\", \"\", \"_actionId\"];\n    _target setDamage 0;\n    _target removeAction _actionId;\n}];\n```\n\nDon't\n\n```sqf\nplayer addAction [\"Heal self (once)\", {\n    player setDamage 0;\n    removeAllActions player;\n}];\n```","code":["player addAction [\"Heal self (once)\", {\n\tparams [\"_target\", \"\", \"_actionId\"];\n\t_target setDamage 0;\n\t_target removeAction _actionId;\n}];","player addAction [\"Heal self (once)\", {\n\tplayer setDamage 0;\n\tremoveAllActions player;\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionIDs","actionParams","addAction","setUserActionText","inGameUISetEventHandler","showHUD","inputAction","removeAction","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeAllAssignedItems","operator":null,"title":"removeAllAssignedItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllAssignedItems","revid":352419,"updated":"2024-02-09T15:26:08Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Unassigns and deletes all linked items from inventory.\nThe commands operates on assignedItems array, which does not include goggles or headgear but includes binoculars, which is a weapon.\n\nUse removeGoggles and removeHeadgear for those.","syntaxes":[{"syntax":"removeAllAssignedItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"removeAllAssignedItems [unit, allItems, includeBinocs]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"soldier","types":["Object"],"since":null,"text":"unit: Object - soldier"},{"name":"allItems","type":"Boolean","optional":false,"default":null,"description":"true to include all slot items, false exclude goggles and headgear","types":["Boolean"],"since":null,"text":"allItems: Boolean - true to include all slot items, false exclude goggles and headgear"},{"name":"includeBinocs","type":"Boolean","optional":false,"default":null,"description":"true to include binoculars (which is a weapon), false to exclude it","types":["Boolean"],"since":null,"text":"includeBinocs: Boolean - true to include binoculars (which is a weapon), false to exclude it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, allItems, includeBinocs]","types":["Array"]}}],"examples":[{"text":"```sqf\nremoveAllAssignedItems player;\n```","code":["removeAllAssignedItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignedItems","linkItem","unlinkItem","assignItem","unassignItem","addItem","removeItem","removeAllContainers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllBinocularItems","operator":null,"title":"removeAllBinocularItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllBinocularItems","revid":310163,"updated":"2022-05-05T13:07:56Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all items from binocular weapon, except magazine.","syntaxes":[{"syntax":"removeAllBinocularItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllBinocularItems player;\n```","code":["removeAllBinocularItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addBinocularItem","removeBinocularItem","removeAllPrimaryWeaponItems","removeAllSecondaryWeaponItems","removeAllHandgunItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllContainers","operator":null,"title":"removeAllContainers","type":"command","url":"https://community.bistudio.com/wiki/removeAllContainers","revid":338829,"updated":"2023-04-10T10:24:35Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all containers (vest, uniform, backpack) from the provided unit.","syntaxes":[{"syntax":"removeAllContainers unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllContainers player;\n```","code":["removeAllContainers player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeAllAssignedItems","removeGoggles","removeHeadgear","removeItem","removeItems","removeUniform","removeVest"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"removeAllCuratorAddons","operator":null,"title":"removeAllCuratorAddons","type":"command","url":"https://community.bistudio.com/wiki/removeAllCuratorAddons","revid":348433,"updated":"2023-11-08T13:00:12Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Restrict access to all addons for given curator.","syntaxes":[{"syntax":"removeAllCuratorAddons curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllCuratorAddons myCurator;\n```","code":["removeAllCuratorAddons myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorAddons","removeAllCuratorAddons","curatorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeAllCuratorCameraAreas","operator":null,"title":"removeAllCuratorCameraAreas","type":"command","url":"https://community.bistudio.com/wiki/removeAllCuratorCameraAreas","revid":348361,"updated":"2023-11-08T12:59:53Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Delete all curator camera areas.","syntaxes":[{"syntax":"removeAllCuratorCameraAreas curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllCuratorCameraAreas myCurator;\n```","code":["removeAllCuratorCameraAreas myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorCameraArea","removeCuratorCameraArea","curatorCameraArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeAllCuratorEditingAreas","operator":null,"title":"removeAllCuratorEditingAreas","type":"command","url":"https://community.bistudio.com/wiki/removeAllCuratorEditingAreas","revid":348470,"updated":"2023-11-08T13:00:25Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Delete all curator edit areas.","syntaxes":[{"syntax":"removeAllCuratorEditingAreas curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllCuratorEditingAreas myCurator;\n```","code":["removeAllCuratorEditingAreas myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorEditingArea","removeCuratorEditingArea","curatorEditingArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeAllEventHandlers","operator":null,"title":"removeAllEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAllEventHandlers","revid":349140,"updated":"2023-11-08T14:49:47Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes all event handlers of given type that were added by addEventHandler **and** resets event handler's creation index to 0.","syntaxes":[{"syntax":"target removeAllEventHandlers handlerType","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Arma 3 v2.10 Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"target: Object or Arma 3 v2.10 Group"},{"name":"handlerType","type":"String","optional":false,"default":null,"description":"see Event Handlers","types":["String"],"since":null,"text":"handlerType: String - see Event Handlers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Object","Group"]},"right":{"text":"handlerType","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeAllEventHandlers \"Killed\";\n```","code":["player removeAllEventHandlers \"Killed\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeEventHandler","addEventHandler","removeMissionEventHandler"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeAllHandgunItems","operator":null,"title":"removeAllHandgunItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllHandgunItems","revid":310238,"updated":"2022-05-05T13:11:00Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all items from handgunWeapon, except magazine.","syntaxes":[{"syntax":"removeAllHandgunItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllHandgunItems player;\n```","code":["removeAllHandgunItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addHandgunItem","removeHandgunItem","removeAllPrimaryWeaponItems","removeAllSecondaryWeaponItems","removeAllBinocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllItems","operator":null,"title":"removeAllItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllItems","revid":378942,"updated":"2026-08-26T10:51:46Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all special items from the unit.","syntaxes":[{"syntax":"removeAllItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllItems unitName;\n```","code":["removeAllItems unitName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeAllWeapons","removeMagazines"],"notes":[{"user":"DarkDruid","date":"2013-06-18T15:35:00Z","text":"Arma 3, version 0.70 - removes only items listed by command items."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeAllItemsWithMagazines","operator":null,"title":"removeAllItemsWithMagazines","type":"command","url":"https://community.bistudio.com/wiki/removeAllItemsWithMagazines","revid":310275,"updated":"2022-05-05T13:11:22Z","groups":["Unit Inventory","Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all itemsWithMagazines from the uniform, vest and backpack. Command essentially clears all unit's containers.","syntaxes":[{"syntax":"removeAllItemsWithMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllItemsWithMagazines player;\n```","code":["removeAllItemsWithMagazines player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["itemsWithMagazines","items"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"removeAllMagazines","operator":null,"title":"removeAllMagazines","type":"command","url":"https://community.bistudio.com/wiki/removeAllMagazines","revid":373492,"updated":"2025-05-16T14:39:26Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all magazines from the unit.","syntaxes":[{"syntax":"removeAllMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllMagazines player;\n```","code":["removeAllMagazines player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMagazines","addMagazine","magazines","removeMagazine","removeWeapon","removeMagazinesTurret","removeAllMagazinesTurret","removeMagazineTurret","setVehicleAmmo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.20","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllMagazinesTurret","operator":null,"title":"removeAllMagazinesTurret","type":"command","url":"https://community.bistudio.com/wiki/removeAllMagazinesTurret","revid":378391,"updated":"2026-04-04T07:52:47Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all magazines from the given turret or from all turrets. Use turret path [-1] for driver's turret or [] for all turrets.","syntaxes":[{"syntax":"vehicle removeAllMagazinesTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"[-1] for driver's turret or [] for all turrets","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - [-1] for driver's turret or [] for all turrets"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\nvehicle player removeAllMagazinesTurret [-1];\n```","code":["vehicle player removeAllMagazinesTurret [-1];"]},{"text":"```sqf\n_tank removeAllMagazinesTurret [];\n```","code":["_tank removeAllMagazinesTurret [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMagazinesTurret","addMagazineTurret","removeAllMagazines","magazinesTurret","removeMagazineTurret","weaponsTurret","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.20","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllMissionEventHandlers","operator":null,"title":"removeAllMissionEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAllMissionEventHandlers","revid":319390,"updated":"2022-05-13T09:23:59Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes all mission event handlers of the given type which were added by addMissionEventHandler.\n\n> [!IMPORTANT]\n> Prior to Arma 3 v2.08 this command would also reset the Event Handler creation index to 0.","syntaxes":[{"syntax":"removeAllMissionEventHandlers type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nremoveAllMissionEventHandlers \"Loaded\";\n```","code":["removeAllMissionEventHandlers \"Loaded\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMissionEventHandler","addMissionEventHandler"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeAllMPEventHandlers","operator":null,"title":"removeAllMPEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAllMPEventHandlers","revid":321196,"updated":"2022-05-13T15:24:42Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all MP event handlers of the given type which were added by addMPEventHandler. Command needs to be executed only on one PC for MP event handler to be removed globally.","syntaxes":[{"syntax":"objectName removeAllMPEventHandlers event","since":null,"effect":null,"exec":null,"params":[{"name":"objectName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"objectName: Object"},{"name":"event","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"event: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"objectName","types":["Object"]},"right":{"text":"event","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeAllMPEventHandlers \"MPKilled\";\n```","code":["player removeAllMPEventHandlers \"MPKilled\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMPEventHandler","removeMPEventHandler"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeAllMusicEventHandlers","operator":null,"title":"removeAllMusicEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAllMusicEventHandlers","revid":322941,"updated":"2022-06-28T21:42:45Z","groups":["Event Handlers","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes all music track event handlers of given type.","syntaxes":[{"syntax":"removeAllMusicEventHandlers type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"\"MusicStart\" or \"MusicStop\"","types":["String"],"since":null,"text":"type: String - \"MusicStart\" or \"MusicStop\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\nremoveAllMusicEventHandlers \"MusicStart\";\n```","code":["removeAllMusicEventHandlers \"MusicStart\";"]},{"text":"```sqf\nremoveAllMusicEventHandlers \"MusicStop\";\n```","code":["removeAllMusicEventHandlers \"MusicStop\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMusicEventHandler","setMusicEventHandler","removeMusicEventHandler","playMusic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Sounds","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"removeAllOwnedMines","operator":null,"title":"removeAllOwnedMines","type":"command","url":"https://community.bistudio.com/wiki/removeAllOwnedMines","revid":310204,"updated":"2022-05-05T13:10:41Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes ownership of all owned mines/explosive devices of the given unit","syntaxes":[{"syntax":"removeAllOwnedMines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllOwnedMines player;\n```","code":["removeAllOwnedMines player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","createMine","detectedMines","mineActive","removeOwnedMine","addOwnedMine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"removeAllPrimaryWeaponItems","operator":null,"title":"removeAllPrimaryWeaponItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllPrimaryWeaponItems","revid":310215,"updated":"2022-05-05T13:10:44Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all items from primaryWeapon, except magazine.","syntaxes":[{"syntax":"removeAllPrimaryWeaponItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllPrimaryWeaponItems player;\n```","code":["removeAllPrimaryWeaponItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addPrimaryWeaponItem","removePrimaryWeaponItem","removeAllSecondaryWeaponItems","removeAllHandgunItems","removeAllBinocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllSecondaryWeaponItems","operator":null,"title":"removeAllSecondaryWeaponItems","type":"command","url":"https://community.bistudio.com/wiki/removeAllSecondaryWeaponItems","revid":310170,"updated":"2022-05-05T13:10:24Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all items from secondaryWeapon, except magazine.","syntaxes":[{"syntax":"removeAllSecondaryWeaponItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllSecondaryWeaponItems player;\n```","code":["removeAllSecondaryWeaponItems player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addSecondaryWeaponItem","removeSecondaryWeaponItem","removeAllPrimaryWeaponItems","removeAllHandgunItems","removeAllBinocularItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeAllUserActionEventHandlers","operator":null,"title":"removeAllUserActionEventHandlers","type":"command","url":"https://community.bistudio.com/wiki/removeAllUserActionEventHandlers","revid":322842,"updated":"2022-06-27T07:33:49Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes all UserAction event handlers of the given type which were added by addUserActionEventHandler.\n\n> [!IMPORTANT]\n> This command also resets the Event Handler creation index to 0.","syntaxes":[{"syntax":"removeAllUserActionEventHandlers [keyName, eventType]","since":null,"effect":null,"exec":null,"params":[{"name":"keyName","type":"String","optional":false,"default":null,"description":"see inputAction/actions","types":["String"],"since":null,"text":"keyName: String - see inputAction/actions"},{"name":"eventType","type":"String","optional":false,"default":null,"description":"event name; see UserAction Event Handlers. Can be one of:\n- \"Activate\"\n- \"Deactivate\"\n- \"Analog\"","types":["String"],"since":null,"text":"eventType: String - event name; see UserAction Event Handlers. Can be one of:\n- \"Activate\"\n- \"Deactivate\"\n- \"Analog\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[keyName, eventType]","types":["Array"]}}],"examples":[{"text":"```sqf\nremoveAllUserActionEventHandlers [\"Reload\", \"Activate\"];\n```","code":["removeAllUserActionEventHandlers [\"Reload\", \"Activate\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUserActionEventHandler","removeUserActionEventHandler","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeAllWeapons","operator":null,"title":"removeAllWeapons","type":"command","url":"https://community.bistudio.com/wiki/removeAllWeapons","revid":352410,"updated":"2024-02-09T15:16:20Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all weapons and magazines from the given unit. Does not remove items like map, compass, radio (see removeWeapon for this).\n\n> [!NOTE]\n> Does not quite work with vehicles. If you need to remove all weapons from a vehicle, remove each weapon individually (see removeWeapon).","syntaxes":[{"syntax":"removeAllWeapons unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveAllWeapons player;\n```","code":["removeAllWeapons player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeapon","setVehicleAmmo","clearWeaponCargo","clearMagazineCargo","removeAllItems","removeBackpack"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeBackpack","operator":null,"title":"removeBackpack","type":"command","url":"https://community.bistudio.com/wiki/removeBackpack","revid":319442,"updated":"2022-05-13T09:24:04Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes unit's backpack","syntaxes":[{"syntax":"removeBackpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveBackpack this;\n```","code":["removeBackpack this;"]},{"text":"```sqf\nremoveBackpack mySoldierDude;\n```","code":["removeBackpack mySoldierDude;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeBackpackGlobal","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeBackpackGlobal","operator":null,"title":"removeBackpackGlobal","type":"command","url":"https://community.bistudio.com/wiki/removeBackpackGlobal","revid":364902,"updated":"2024-06-29T14:38:36Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes backpack from a unit. (even non-local)","syntaxes":[{"syntax":"removeBackpackGlobal unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"soldier","types":["Object"],"since":null,"text":"unit: Object - soldier"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveBackpackGlobal player;\n```","code":["removeBackpackGlobal player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeBackpack","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeBinocularItem","operator":null,"title":"removeBinocularItem","type":"command","url":"https://community.bistudio.com/wiki/removeBinocularItem","revid":310306,"updated":"2022-05-05T13:24:30Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes given weapon item, including magazine, from the binocular weapon.","syntaxes":[{"syntax":"unit removeBinocularItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeBinocularItem \"Laserbatteries\";\n```","code":["player removeBinocularItem \"Laserbatteries\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addBinocularItem","binocularItems","removeAllBinocularItems","removePrimaryWeaponItem","removeSecondaryWeaponItem","removeHandgunItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeCuratorAddons","operator":null,"title":"removeCuratorAddons","type":"command","url":"https://community.bistudio.com/wiki/removeCuratorAddons","revid":377139,"updated":"2026-01-01T10:30:26Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Restrict curator use of given addons.","syntaxes":[{"syntax":"curatorObj removeCuratorAddons addons","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"addons","type":"Array of Strings","optional":false,"default":null,"description":null,"types":["Array","String"],"since":null,"text":"addons: Array of Strings"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"addons","types":["Array","String"]}}],"examples":[{"text":"```sqf\ncuratorModule removeCuratorAddons [addon1, addon2];\n```","code":["curatorModule removeCuratorAddons [addon1, addon2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorAddons","removeAllCuratorAddons","curatorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeCuratorCameraArea","operator":null,"title":"removeCuratorCameraArea","type":"command","url":"https://community.bistudio.com/wiki/removeCuratorCameraArea","revid":348426,"updated":"2023-11-08T13:00:09Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Removes curator camera area.","syntaxes":[{"syntax":"curatorObj removeCuratorCameraArea cameraAreaID","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"cameraAreaID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"cameraAreaID: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"cameraAreaID","types":["Number"]}}],"examples":[{"text":"```sqf\nmyCurator removeCuratorCameraArea 3;\n```","code":["myCurator removeCuratorCameraArea 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorCameraArea","removeAllCuratorCameraAreas","curatorCameraArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeCuratorEditableObjects","operator":null,"title":"removeCuratorEditableObjects","type":"command","url":"https://community.bistudio.com/wiki/removeCuratorEditableObjects","revid":377069,"updated":"2026-01-01T09:30:27Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Unregister objects which can be edited by a curator.","syntaxes":[{"syntax":"curatorObj removeCuratorEditableObjects [objects, removeCrew]","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"},{"name":"removeCrew","type":"Boolean","optional":true,"default":"true","description":null,"types":["Boolean"],"since":null,"text":"removeCrew: Boolean - (Optional, default true)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"[objects, removeCrew]","types":["Array"]}}],"examples":[{"text":"```sqf\ncuratorModule removeCuratorEditableObjects [[cursorTarget], true];\n```","code":["curatorModule removeCuratorEditableObjects [[cursorTarget], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorEditableObjects","curatorEditableObjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeCuratorEditingArea","operator":null,"title":"removeCuratorEditingArea","type":"command","url":"https://community.bistudio.com/wiki/removeCuratorEditingArea","revid":348385,"updated":"2023-11-08T12:59:59Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Removes editing area for given curator.","syntaxes":[{"syntax":"curatorObj removeCuratorEditingArea editAreaID","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"editAreaID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"editAreaID: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"editAreaID","types":["Number"]}}],"examples":[{"text":"```sqf\nmyCurator removeCuratorEditingArea 3;\n```","code":["myCurator removeCuratorEditingArea 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorAddons","removeAllCuratorAddons","curatorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"removeDiaryRecord","operator":null,"title":"removeDiaryRecord","type":"command","url":"https://community.bistudio.com/wiki/removeDiaryRecord","revid":340844,"updated":"2023-05-10T15:17:04Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Remove a log record.","syntaxes":[{"syntax":"unit removeDiaryRecord [subject, diaryRecord]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"subject","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"subject: String"},{"name":"diaryRecord","type":"Diary Record","optional":false,"default":null,"description":null,"types":["Diary Record"],"since":null,"text":"diaryRecord: Diary Record"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[subject, diaryRecord]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _diaryRecord = player createDiaryRecord [\"Diary\", [\"Subject\", \"Text\"]];\n// ...\nplayer removeDiaryRecord [\"Diary\", _diaryRecord];\n```","code":["private _diaryRecord = player createDiaryRecord [\"Diary\", [\"Subject\", \"Text\"]];\n// ...\nplayer removeDiaryRecord [\"Diary\", _diaryRecord];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDiaryRecord","removeDiarySubject"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.96","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeDiarySubject","operator":null,"title":"removeDiarySubject","type":"command","url":"https://community.bistudio.com/wiki/removeDiarySubject","revid":309156,"updated":"2022-05-03T14:17:34Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes a page and all its subjects from the Diary.","syntaxes":[{"syntax":"player removeDiarySubject diaryPage","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"player: Object"},{"name":"diaryPage","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"diaryPage: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"diaryPage","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeDiarySubject \"myPage\";\n```","code":["player removeDiarySubject \"myPage\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDiarySubject","diarySubjectExists","selectDiarySubject","removeDiaryRecord","allDiarySubjects"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.96","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeDrawIcon","operator":null,"title":"removeDrawIcon","type":"command","url":"https://community.bistudio.com/wiki/removeDrawIcon","revid":363580,"updated":"2024-04-07T14:47:33Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes an icon for an editor object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map removeDrawIcon [object, string identifier]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"string identifier","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string identifier: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object, string identifier]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeDrawLinks","operator":null,"title":"removeDrawLinks","type":"command","url":"https://community.bistudio.com/wiki/removeDrawLinks","revid":363290,"updated":"2024-03-26T10:51:58Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove all drawn links for the given editor object for the given editor,object type. Pass an empty string as param type to remove all draw,links for an object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map removeDrawLinks [from,param type]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[from,param type]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[from,param type]: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[from,param type]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeEventHandler","operator":null,"title":"removeEventHandler","type":"command","url":"https://community.bistudio.com/wiki/removeEventHandler","revid":369196,"updated":"2024-09-03T10:34:47Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes a given Event Handler that was added with addEventHandler.","syntaxes":[{"syntax":"target removeEventHandler [type, index]","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object or Arma 3 v2.10 Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"target: Object or Arma 3 v2.10 Group"},{"name":"type","type":"String","optional":false,"default":null,"description":"see Event Handlers for the full list of available options","types":["String"],"since":null,"text":"type: String - see Event Handlers for the full list of available options"},{"name":"index","type":"Number","optional":false,"default":null,"description":"the value originally returned by addEventHandler","types":["Number"],"since":null,"text":"index: Number - the value originally returned by addEventHandler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Object","Group"]},"right":{"text":"[type, index]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer removeEventHandler [\"Killed\", 0];\n```","code":["player removeEventHandler [\"Killed\", 0];"]},{"text":"The Magic Variables `_thisEvent` and `_thisEventHandler` can be used to easily remove an Event Handler:\n\n```sqf\nplayer addEventHandler [\"FiredNear\", {\n    systemChat \"This Event Handler is now removing itself!\";\n    player removeEventHandler [_thisEvent, _thisEventHandler];\n}];\n```","code":["player addEventHandler [\"FiredNear\", {\n\tsystemChat \"This Event Handler is now removing itself!\";\n\tplayer removeEventHandler [_thisEvent, _thisEventHandler];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addEventHandler","removeAllEventHandlers","removeMPEventHandler","removeMissionEventHandler"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeFromRemainsCollector","operator":null,"title":"removeFromRemainsCollector","type":"command","url":"https://community.bistudio.com/wiki/removeFromRemainsCollector","revid":377097,"updated":"2026-01-01T09:56:53Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes vehicles/units from the garbage collector, so they do not get deleted automatically; added earlier with addToRemainsCollector.","syntaxes":[{"syntax":"removeFromRemainsCollector remains","since":null,"effect":null,"exec":null,"params":[{"name":"remains","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"remains: Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"remains","types":["Array","Object"]}}],"examples":[{"text":"```sqf\nremoveFromRemainsCollector [unit1, unit2, vehicle1];\n```","code":["removeFromRemainsCollector [unit1, unit2, vehicle1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addToRemainsCollector","isInRemainsCollector","diag_remainsCollector"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeGoggles","operator":null,"title":"removeGoggles","type":"command","url":"https://community.bistudio.com/wiki/removeGoggles","revid":309949,"updated":"2022-05-05T12:17:00Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes goggles from unit (diver goggles for example). This command does not remove NVGoggles. Use unassignItem and removeItem or just unlinkItem for latter.","syntaxes":[{"syntax":"removeGoggles unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveGoggles assaultDiver;\n```","code":["removeGoggles assaultDiver;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["goggles","addGoggles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeGroupIcon","operator":null,"title":"removeGroupIcon","type":"command","url":"https://community.bistudio.com/wiki/removeGroupIcon","revid":363186,"updated":"2024-03-25T09:04:50Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove icon with given ID from group.","syntaxes":[{"syntax":"group removeGroupIcon iconID","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"iconID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"iconID: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"iconID","types":["Number"]}}],"examples":[{"text":"```sqf\n_target removeGroupIcon (_target getVariable \"hc_attackicon\");\n```","code":["_target removeGroupIcon (_target getVariable \"hc_attackicon\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","setGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeHandgunItem","operator":null,"title":"removeHandgunItem","type":"command","url":"https://community.bistudio.com/wiki/removeHandgunItem","revid":348319,"updated":"2023-11-08T12:59:40Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes given weapon item, including magazine, from the handgunWeapon","syntaxes":[{"syntax":"unit removeHandgunItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":"config class","types":["String"],"since":null,"text":"item: String - config class"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeHandgunItem \"muzzle_snds_L\";\n```","code":["player removeHandgunItem \"muzzle_snds_L\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addHandgunItem","removeAllHandgunItems","removePrimaryWeaponItem","removeSecondaryWeaponItem","removeBinocularItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeHeadgear","operator":null,"title":"removeHeadgear","type":"command","url":"https://community.bistudio.com/wiki/removeHeadgear","revid":340893,"updated":"2023-05-13T21:57:45Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes headgear from a unit. If unit has no headgear command quietly fails.","syntaxes":[{"syntax":"removeHeadgear unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveHeadgear player;\n```","code":["removeHeadgear player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["headgear","addHeadgear"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeItem","operator":null,"title":"removeItem","type":"command","url":"https://community.bistudio.com/wiki/removeItem","revid":351753,"updated":"2024-01-03T10:47:47Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes item from the inventory. The removal order by containers is uniform → vest → backpack.","syntaxes":[{"syntax":"unit removeItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nbluforUnit unassignItem \"NVGoggles\";\nbluforUnit removeItem \"NVGoggles\";\nopforUnit unassignItem \"NVGoggles_OPFOR\";\nopforUnit removeItem \"NVGoggles_OPFOR\";\nindependentUnit unassignItem \"NVGoggles_INDEP\";\nindependentUnit removeItem \"NVGoggles_INDEP\";\n```","code":["bluforUnit unassignItem \"NVGoggles\";\nbluforUnit removeItem \"NVGoggles\";\nopforUnit unassignItem \"NVGoggles_OPFOR\";\nopforUnit removeItem \"NVGoggles_OPFOR\";\nindependentUnit unassignItem \"NVGoggles_INDEP\";\nindependentUnit removeItem \"NVGoggles_INDEP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItems","unassignItem","addItem","assignItem","assignedItems","linkItem","unlinkItem","removeAllAssignedItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeItemFromBackpack","operator":null,"title":"removeItemFromBackpack","type":"command","url":"https://community.bistudio.com/wiki/removeItemFromBackpack","revid":319517,"updated":"2022-05-13T09:24:13Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes item from soldier's backpack.","syntaxes":[{"syntax":"unit removeItemFromBackpack item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeItemFromBackpack \"itemGPS\";\n```","code":["player removeItemFromBackpack \"itemGPS\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItemFromUniform","removeItemFromVest","removeItemFromPrimaryWeapon","backpackContainer","firstBackpack","unitBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","everyBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeItemFromUniform","operator":null,"title":"removeItemFromUniform","type":"command","url":"https://community.bistudio.com/wiki/removeItemFromUniform","revid":376273,"updated":"2025-09-23T06:13:21Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes item from soldier's uniform. Can be used with magazines and weapons too.","syntaxes":[{"syntax":"unit removeItemFromUniform item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeItemFromUniform \"FirstAidKit\";\n```","code":["player removeItemFromUniform \"FirstAidKit\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemToUniform","removeItemFromVest","removeItemFromBackpack","removeItemFromPrimaryWeapon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeItemFromVest","operator":null,"title":"removeItemFromVest","type":"command","url":"https://community.bistudio.com/wiki/removeItemFromVest","revid":376274,"updated":"2025-09-23T06:13:45Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes item from soldier's vest.","syntaxes":[{"syntax":"unit removeItemFromVest item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeItemFromVest \"itemWatch\";\n```","code":["player removeItemFromVest \"itemWatch\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addItemToVest","removeItemFromUniform","removeItemFromBackpack","removeItemFromPrimaryWeapon"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 3 version 1.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeItems","operator":null,"title":"removeItems","type":"command","url":"https://community.bistudio.com/wiki/removeItems","revid":319499,"updated":"2022-05-13T09:24:12Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes all items with given class name from the inventory.","syntaxes":[{"syntax":"unit removeItems item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeItems \"FirstAidKit\";\n```","code":["player removeItems \"FirstAidKit\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeItem","removeAllAssignedItems","unassignItem","assignItem","assignedItems","addItem","linkItem","unlinkItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeMagazine","operator":null,"title":"removeMagazine","type":"command","url":"https://community.bistudio.com/wiki/removeMagazine","revid":370164,"updated":"2024-11-02T23:35:39Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Remove magazine from the unit or static weapon.","syntaxes":[{"syntax":"unitName removeMagazine magazineName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":"see weapons","types":["String"],"since":null,"text":"magazineName: String - see weapons"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"magazineName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeMagazine \"M16\";\n```","code":["player removeMagazine \"M16\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMagazines","removeWeapon","removeMagazinesTurret","removeMagazineTurret","setVehicleAmmo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeMagazineGlobal","operator":null,"title":"removeMagazineGlobal","type":"command","url":"https://community.bistudio.com/wiki/removeMagazineGlobal","revid":319326,"updated":"2022-05-13T09:23:53Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes the magazine from the unit.","syntaxes":[{"syntax":"unit removeMagazineGlobal magazineName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"magazineName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeMagazineGlobal \"30Rnd_65x39_caseless_mag\";\n```","code":["player removeMagazineGlobal \"30Rnd_65x39_caseless_mag\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeMagazine","removeMagazines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeMagazines","operator":null,"title":"removeMagazines","type":"command","url":"https://community.bistudio.com/wiki/removeMagazines","revid":373502,"updated":"2025-05-18T11:00:18Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all magazines of given type from the unit. If magazine class does not exist, nothing happens, not even .rpt message, unlike with addMagazine command.","syntaxes":[{"syntax":"unitName removeMagazines magazineName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"magazineName","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeMagazines \"30Rnd_556x45_Stanag\";\n```","code":["player removeMagazines \"30Rnd_556x45_Stanag\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeAllMagazines","addMagazine","magazines","removeMagazine","removeWeapon","removeMagazinesTurret","removeMagazineTurret","setVehicleAmmo"],"notes":[{"user":"Pyro05x","date":"2007-01-27T03:46:00Z","text":"Though BIS did not provide a command to remove **all** magazines of every type, it can still be accomplished using forEach magazines.\nexample:\n\n```sqf\n{ player removeMagazine _x } forEach magazines player;\n```\n\n**edit:** `removeAllMagazines player;` now exists since Arma 3 v2.20."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeMagazinesTurret","operator":null,"title":"removeMagazinesTurret","type":"command","url":"https://community.bistudio.com/wiki/removeMagazinesTurret","revid":377499,"updated":"2026-01-02T06:49:26Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes all magazines of the given type from given vehicle. Use turret path [-1] for driver's turret.","syntaxes":[{"syntax":"vehicle removeMagazinesTurret [magazineName, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineName, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player removeMagazinesTurret [\"60rnd_CMFlareMagazine\", [-1]];\n```","code":["vehicle player removeMagazinesTurret [\"60rnd_CMFlareMagazine\", [-1]];"]},{"text":"```sqf\n_tank removeMagazinesTurret [\"20Rnd_120mmSABOT_M1A2\", [0]];\n```","code":["_tank removeMagazinesTurret [\"20Rnd_120mmSABOT_M1A2\", [0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeAllMagazinesTurret","addMagazineTurret","removeAllMagazines","magazinesTurret","removeMagazineTurret","weaponsTurret","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[{"user":"Kylania","date":"2011-07-30T18:42:00Z","text":"Here's how you would remove all machine gun ammo from an M1A2 TUSK:\n\nremove the gunner's M240 ammo.\n\n```sqf\nthis removeMagazinesTurret [\"1200Rnd_762x51_M240\", [0]];\n```\n\nremove the commander's M2 ammo.\n\n```sqf\nthis removeMagazinesTurret [\"100Rnd_127x99_M2\", [0, 0]];\n```\n\nremove the loader's M240 ammo.\n\n```sqf\nthis removeMagazinesTurret [\"100Rnd_762x51_M240\", [0, 1]];\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2: Operation Arrowhead version 1.52","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeMagazineTurret","operator":null,"title":"removeMagazineTurret","type":"command","url":"https://community.bistudio.com/wiki/removeMagazineTurret","revid":377469,"updated":"2026-01-02T06:48:35Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes the magazine from the turret. Use turret path [-1] for driver's turret.\n\nNote: you may create invalid combinations by using this function. When doing so, application behaviour is undefined.","syntaxes":[{"syntax":"vehicle removeMagazineTurret [magazineName, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineName, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player removeMagazineTurret [\"60rnd_cmflaremagazine\",[-1]];\n```","code":["vehicle player removeMagazineTurret [\"60rnd_cmflaremagazine\",[-1]];"]},{"text":"```sqf\n_tank removeMagazineTurret [\"20Rnd_120mmSABOT_M1A2\",[0]];\n```","code":["_tank removeMagazineTurret [\"20Rnd_120mmSABOT_M1A2\",[0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineTurret","magazinesTurret","removeMagazinesTurret","weaponsTurret","addWeaponTurret","removeWeaponTurret","turretLocal","removeMagazine"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2: Operation Arrowhead version 1.52","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeMenuItem","operator":null,"title":"removeMenuItem","type":"command","url":"https://community.bistudio.com/wiki/removeMenuItem","revid":363243,"updated":"2024-03-26T10:51:18Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes a previously added menu item.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map removeMenuItem index","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index of menu item to delete","types":["Number"],"since":null,"text":"index: Number - index of menu item to delete"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeMissionEventHandler","operator":null,"title":"removeMissionEventHandler","type":"command","url":"https://community.bistudio.com/wiki/removeMissionEventHandler","revid":369303,"updated":"2024-09-03T18:42:53Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes mission event handler added by addMissionEventHandler.","syntaxes":[{"syntax":"removeMissionEventHandler [type, index]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index is returned by addMissionEventHandler.","types":["Number"],"since":null,"text":"index: Number - index is returned by addMissionEventHandler."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, index]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _eventHandlerId = addMissionEventHandler [\"Ended\", { diag_log \"mission complete\"; }];\n// ...\nremoveMissionEventHandler [\"Ended\", _eventHandlerId];\n```","code":["private _eventHandlerId = addMissionEventHandler [\"Ended\", { diag_log \"mission complete\"; }];\n// ...\nremoveMissionEventHandler [\"Ended\", _eventHandlerId];"]},{"text":"```sqf\nfor \"_i\" from 0 to 4 do {\n    missionNamespace setVariable [format [\"handler%1\",_i], addMissionEventHandler [\"Loaded\",\"hint \"\"_i\"\";\"]];\n};\nremoveMissionEventHandler [\"Loaded\", handler2]; // Remove the third index under type \"Loaded\"\n```","code":["for \"_i\" from 0 to 4 do {\n\tmissionNamespace setVariable [format [\"handler%1\",_i], addMissionEventHandler [\"Loaded\",\"hint \"\"_i\"\";\"]];\n};\nremoveMissionEventHandler [\"Loaded\", handler2]; // Remove the third index under type \"Loaded\""]},{"text":"```sqf\naddMissionEventHandler [\"entityKilled\",{hint \"First kill!\"; removeMissionEventHandler [\"entityKilled\", _thisEventHandler]; }];\n```","code":["addMissionEventHandler [\"entityKilled\",{hint \"First kill!\"; removeMissionEventHandler [\"entityKilled\", _thisEventHandler]; }];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMissionEventHandler","removeAllMissionEventHandlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeMPEventHandler","operator":null,"title":"removeMPEventHandler","type":"command","url":"https://community.bistudio.com/wiki/removeMPEventHandler","revid":364089,"updated":"2024-05-03T19:34:19Z","groups":["Multiplayer","Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes MP event handler added by addMPEventHandler.","syntaxes":[{"syntax":"unitName removeMPEventHandler [event, index]","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"event","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"event: String"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index returned by addMPEventHandler","types":["Number"],"since":null,"text":"index: Number - index returned by addMPEventHandler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"[event, index]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer removeMPEventHandler [\"MPKilled\", 0];\n```","code":["player removeMPEventHandler [\"MPKilled\", 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMPEventHandler","removeAllMPEventHandlers"],"notes":[{"user":".kju","date":"2011-07-25T19:41:00Z","text":"At least for MPKilled it needs to be executed where the target unit is local. The effect (the removal) is global."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeMusicEventHandler","operator":null,"title":"removeMusicEventHandler","type":"command","url":"https://community.bistudio.com/wiki/removeMusicEventHandler","revid":369308,"updated":"2024-09-03T18:42:54Z","groups":["Event Handlers","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes specified music track event handler. See Arma 3: Event Handlers#Music Event Handlers.","syntaxes":[{"syntax":"removeMusicEventHandler [type, id]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"\"MusicStart\" or \"MusicStop\"","types":["String"],"since":null,"text":"type: String - \"MusicStart\" or \"MusicStop\""},{"name":"id","type":"Number","optional":false,"default":null,"description":"event handler id","types":["Number"],"since":null,"text":"id: Number - event handler id"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, id]","types":["Array"]}}],"examples":[{"text":"```sqf\nremoveMusicEventHandler [\"MusicStart\", 12];\n```","code":["removeMusicEventHandler [\"MusicStart\", 12];"]},{"text":"```sqf\nremoveMusicEventHandler [\"MusicStop\", 12];\n```","code":["removeMusicEventHandler [\"MusicStop\", 12];"]},{"text":"```sqf\nprivate _stopMusicEH = addMusicEventHandler [\"MusicStop\", {}];\n// ...\nremoveMusicEventHandler [\"MusicStop\", _stopMusicEH];\n```","code":["private _stopMusicEH = addMusicEventHandler [\"MusicStop\", {}];\n// ...\nremoveMusicEventHandler [\"MusicStop\", _stopMusicEH];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMusicEventHandler","setMusicEventHandler","removeAllMusicEventHandlers","playMusic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Sounds","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"removeOwnedMine","operator":null,"title":"removeOwnedMine","type":"command","url":"https://community.bistudio.com/wiki/removeOwnedMine","revid":347976,"updated":"2023-11-08T09:47:29Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Removes ownership over a remotely detonatable mine from the unit.","syntaxes":[{"syntax":"unit removeOwnedMine mine","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mine","type":"Object","optional":false,"default":null,"description":"the mine object","types":["Object"],"since":null,"text":"mine: Object - the mine object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mine","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer removeOwnedMine SuperMine;\n```","code":["player removeOwnedMine SuperMine;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","createMine","detectedMines","mineActive","getAllOwnedMines","addOwnedMine","removeAllOwnedMines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"removePrimaryWeaponItem","operator":null,"title":"removePrimaryWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/removePrimaryWeaponItem","revid":347501,"updated":"2023-09-24T01:03:45Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes given weapon item, including magazine, from the primaryWeapon.","syntaxes":[{"syntax":"unit removePrimaryWeaponItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removePrimaryWeaponItem \"acc_flashlight\";\n```","code":["player removePrimaryWeaponItem \"acc_flashlight\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addPrimaryWeaponItem","removeAllPrimaryWeaponItems","removeSecondaryWeaponItem","removeHandgunItem","removeBinocularItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeSecondaryWeaponItem","operator":null,"title":"removeSecondaryWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/removeSecondaryWeaponItem","revid":319509,"updated":"2022-05-13T09:24:13Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes given weapon item, including magazine, from the secondaryWeapon.","syntaxes":[{"syntax":"unit removeSecondaryWeaponItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nplayer removeSecondaryWeaponItem (secondaryWeaponItems player select 0);\n```","code":["player removeSecondaryWeaponItem (secondaryWeaponItems player select 0);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addSecondaryWeaponItem","removePrimaryWeaponItem","removeHandgunItem","removeBinocularItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.38","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeSimpleTask","operator":null,"title":"removeSimpleTask","type":"command","url":"https://community.bistudio.com/wiki/removeSimpleTask","revid":353336,"updated":"2024-03-15T17:11:51Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove a simple task from the list of simple tasks.\n\n> [!NOTE]\n> If the Task to be removed is a child to some parent task and at the same time the parent to some child task, the child of this task gets orphaned and is listed in the root of Tasks tree (Tasks menu), retaining tree structure of its children.","syntaxes":[{"syntax":"person removeSimpleTask task","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\nplayer removeSimpleTask _tskKillSpongebob;\n```","code":["player removeSimpleTask _tskKillSpongebob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","createSimpleTask","setSimpleTaskDescription","setSimpleTaskDestination","setTaskState","setTaskResult","taskState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeSwitchableUnit","operator":null,"title":"removeSwitchableUnit","type":"command","url":"https://community.bistudio.com/wiki/removeSwitchableUnit","revid":309935,"updated":"2022-05-05T12:16:59Z","groups":["Team Switch","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove a unit from the list of units available for Team Switch.","syntaxes":[{"syntax":"removeSwitchableUnit unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveSwitchableUnit _unit1;\n```","code":["removeSwitchableUnit _unit1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Team Switch","addSwitchableUnit"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"removeTeamMember","operator":null,"title":"removeTeamMember","type":"command","url":"https://community.bistudio.com/wiki/removeTeamMember","revid":310128,"updated":"2022-05-05T12:25:41Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Remove given member from given team. Effect is local, unless both member and team are local to PC on which command is executed, then effect is global.","syntaxes":[{"syntax":"team removeTeamMember member","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"},{"name":"member","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"member: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"team","types":["Team Member"]},"right":{"text":"member","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_team removeTeamMember _teamMember;\n```","code":["_team removeTeamMember _teamMember;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","teamMember","teamMemberNull","teamName","teams","teamType"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeUniform","operator":null,"title":"removeUniform","type":"command","url":"https://community.bistudio.com/wiki/removeUniform","revid":310201,"updated":"2022-05-05T13:10:40Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes uniform from unit.","syntaxes":[{"syntax":"removeUniform unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveUniform player;\n```","code":["removeUniform player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUniform","forceAddUniform","isUniformAllowed","uniform","removeVest","removeBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeUserActionEventHandler","operator":null,"title":"removeUserActionEventHandler","type":"command","url":"https://community.bistudio.com/wiki/removeUserActionEventHandler","revid":364189,"updated":"2024-05-05T10:46:49Z","groups":["Event Handlers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Removes a UserAction event handler. For a list of available UserAction event handlers, see: Arma 3: Mission Event Handlers.","syntaxes":[{"syntax":"removeUserActionEventHandler [keyName, event, index]","since":null,"effect":null,"exec":null,"params":[{"name":"keyName","type":"String","optional":false,"default":null,"description":"action key name; see inputAction/actions","types":["String"],"since":null,"text":"keyName: String - action key name; see inputAction/actions"},{"name":"event","type":"String","optional":false,"default":null,"description":"event name - see UserAction Event Handlers. Can be one of:\n- \"Activate\"\n- \"Deactivate\"\n- \"Analog\"","types":["String"],"since":null,"text":"event: String - event name - see UserAction Event Handlers. Can be one of:\n- \"Activate\"\n- \"Deactivate\"\n- \"Analog\""},{"name":"index","type":"Number","optional":false,"default":null,"description":"index returned by addUserActionEventHandler","types":["Number"],"since":null,"text":"index: Number - index returned by addUserActionEventHandler"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[keyName, event, index]","types":["Array"]}}],"examples":[{"text":"```sqf\nremoveUserActionEventHandler [\"Reload\", \"Activate\", _reloadUAEH];\n```","code":["removeUserActionEventHandler [\"Reload\", \"Activate\", _reloadUAEH];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUserActionEventHandler","removeAllUserActionEventHandlers","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"removeVest","operator":null,"title":"removeVest","type":"command","url":"https://community.bistudio.com/wiki/removeVest","revid":310183,"updated":"2022-05-05T13:10:31Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes vest from unit.","syntaxes":[{"syntax":"removeVest unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nremoveVest player;\n```","code":["removeVest player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addVest","vest","removeUniform","removeBackpack"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeWeapon","operator":null,"title":"removeWeapon","type":"command","url":"https://community.bistudio.com/wiki/removeWeapon","revid":376459,"updated":"2025-10-14T22:27:24Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Remove weapon from a unit. The unit must be local to the computer where command is executed.\nFor a global version of this command, see removeWeaponGlobal.\n\n> [!NOTE]\n> It is possible to create invalid combinations with this command (e.g attempting to remove a weapon that a unit does not possess).\n> When doing so, application behaviour is undefined.","syntaxes":[{"syntax":"unit removeWeapon weapon","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"unit: Object - unit or vehicle"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}},{"syntax":"object removeWeapon [weapon, autoselect]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"object: Object - unit or vehicle"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"autoselect","type":"String","optional":true,"default":"true","description":"false to abort weapon autoselection when removing primary weapon.","types":["String"],"since":null,"text":"autoselect: String - (Optional, default true) false to abort weapon autoselection when removing primary weapon."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weapon, autoselect]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer removeWeapon \"BAF_L85A2_RIS_SUSAT\";\n```","code":["player removeWeapon \"BAF_L85A2_RIS_SUSAT\";"]},{"text":"```sqf\nAn_2 removeWeapon \"M240_veh\";\n```","code":["An_2 removeWeapon \"M240_veh\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponGlobal","addWeapon","removeAllWeapons"],"notes":[{"user":"zGuba","date":"2009-05-27T14:30:00Z","text":"CTD may occur in certain conditions: when shooter is AI and is currently shooting at target in some proximity (tested with M136 on ACE 1.08 and Compact Fix 1.14H+). Even \"dropweapon\" action may cause CTD with AI."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"removeWeaponAttachmentCargo","operator":null,"title":"removeWeaponAttachmentCargo","type":"command","url":"https://community.bistudio.com/wiki/removeWeaponAttachmentCargo","revid":352122,"updated":"2024-02-01T23:25:04Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove attachment linked to a weapon from the vehicle cargo space.\n\n> [!WARNING]\n> This is unofficial documentation. All Information here is as it exists in the Engine. It might not reflect the reality.","syntaxes":[{"syntax":"object removeWeaponAttachmentCargo [weaponID,creatorID,attachment]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"},{"name":"weaponID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"weaponID: Number"},{"name":"creatorID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"creatorID: Number"},{"name":"attachment","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"attachment: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weaponID,creatorID,attachment]","types":["Array"]}}],"examples":[{"text":"```sqf\nrearmTruckOne removeWeaponAttachmentCargo [weaponID, creatorID, \"attachment\"];\n```","code":["rearmTruckOne removeWeaponAttachmentCargo [weaponID, creatorID, \"attachment\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponCargo","weaponAccessoriesCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"removeWeaponCargo","operator":null,"title":"removeWeaponCargo","type":"command","url":"https://community.bistudio.com/wiki/removeWeaponCargo","revid":352183,"updated":"2024-02-01T23:25:50Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Remove weapon from the vehicle cargo space.\n\n> [!WARNING]\n> This is unofficial documentation. All Information here is as it exists in the Engine. It might not reflect the reality.","syntaxes":[{"syntax":"object removeWeaponCargo [weaponID,creatorID]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or ammo box","types":["Object"],"since":null,"text":"object: Object - vehicle or ammo box"},{"name":"weaponID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"weaponID: Number"},{"name":"creatorID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"creatorID: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weaponID,creatorID]","types":["Array"]}}],"examples":[{"text":"```sqf\nrearmTruckOne removeWeaponCargo [19, 1];\n```","code":["rearmTruckOne removeWeaponCargo [19, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponAttachmentCargo","weaponAccessoriesCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"removeWeaponGlobal","operator":null,"title":"removeWeaponGlobal","type":"command","url":"https://community.bistudio.com/wiki/removeWeaponGlobal","revid":373147,"updated":"2025-04-04T06:15:31Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Remove a weapon from a unit. An attempt to remove a weapon, which is not in unit's possession, is simply ignored.","syntaxes":[{"syntax":"unit removeWeaponGlobal weapon","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"unit: Object - unit or vehicle"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}},{"syntax":"object removeWeaponGlobal [weapon, autoselect]","since":"arma3 2.20","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"object: Object - unit or vehicle"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name","types":["String"],"since":null,"text":"weapon: String - weapon class name"},{"name":"autoselect","type":"String","optional":true,"default":"true","description":"false to abort weapon autoselection when removing primary weapon.","types":["String"],"since":null,"text":"autoselect: String - (Optional, default true) false to abort weapon autoselection when removing primary weapon."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weapon, autoselect]","types":["Array"]}}],"examples":[{"text":"```sqf\n{\n    _x removeWeaponGlobal \"Laserdesignator\";\n} forEach allUnits;\n```","code":["{\n\t_x removeWeaponGlobal \"Laserdesignator\";\n} forEach allUnits;"]},{"text":"```sqf\n{\n    if (typeOf _x == \"O_Heli_Attack_02_black_F\") then {\n        _x removeWeaponGlobal \"rockets_Skyfire\";\n    };\n} forEach vehicles;\n```","code":["{\n\tif (typeOf _x == \"O_Heli_Attack_02_black_F\") then {\n\t\t_x removeWeaponGlobal \"rockets_Skyfire\";\n\t};\n} forEach vehicles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponGlobal","removeWeapon","removeMagazine","removeMagazineGlobal","removeAllWeapons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.76","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeWeaponItem","operator":null,"title":"removeWeaponItem","type":"command","url":"https://community.bistudio.com/wiki/removeWeaponItem","revid":376149,"updated":"2025-09-06T17:37:00Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes magazine from the specified muzzle.\nIt is possible to remove magazine directly from 'Throw' muzzle provided it is configured with `keepInInventory = 0;`.\n\n> [!NOTE]\n> To add such magazine, see addWeaponItem.","syntaxes":[{"syntax":"unit removeWeaponItem [muzzle, magazine]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"name of the muzzle to add magazine to","types":["String"],"since":null,"text":"muzzle: String - name of the muzzle to add magazine to"},{"name":"magazine","type":"String","optional":false,"default":null,"description":"class name of the magazine to remove","types":["String"],"since":null,"text":"magazine: String - class name of the magazine to remove"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[muzzle, magazine]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer removeWeaponItem [\"arifle_MX_GL_ACO_F\", \"1Rnd_HE_Grenade_shell\"];\n```","code":["player removeWeaponItem [\"arifle_MX_GL_ACO_F\", \"1Rnd_HE_Grenade_shell\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponItem","addPrimaryWeaponItem","addSecondaryWeaponItem","addHandgunItem","addBinocularItem","weaponsItems","handgunItems","primaryWeaponItems","secondaryWeaponItems","binocularItems","removePrimaryWeaponItem","removeSecondaryWeaponItem","removeHandgunItem","removeBinocularItem"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"removeWeaponTurret","operator":null,"title":"removeWeaponTurret","type":"command","url":"https://community.bistudio.com/wiki/removeWeaponTurret","revid":377481,"updated":"2026-01-02T06:48:57Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Removes weapon from the turret. Use turret path [-1] for driver's turret.","syntaxes":[{"syntax":"vehicle removeWeaponTurret [weaponName, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponName: String"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[weaponName, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\n_tank removeWeaponTurret [\"LMG_M200\", [0,0]];\n```","code":["_tank removeWeaponTurret [\"LMG_M200\", [0,0]];"]},{"text":"```sqf\nvehicle player removeWeaponTurret [\"SportCarHorn\", [-1]];\n```","code":["vehicle player removeWeaponTurret [\"SportCarHorn\", [-1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWeaponTurret","turretLocal","addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","currentMagazineDetailTurret","currentMagazineTurret","currentWeaponTurret","selectWeaponTurret"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"reportRemoteTarget","operator":null,"title":"reportRemoteTarget","type":"command","url":"https://community.bistudio.com/wiki/reportRemoteTarget","revid":310923,"updated":"2022-05-07T20:45:37Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Shares the target vehicle via datalink to the Side center for a given time.","syntaxes":[{"syntax":"side reportRemoteTarget [target, time]","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"},{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"side","types":["Side"]},"right":{"text":"[target, time]","types":["Array"]}}],"examples":[{"text":"```sqf\nblufor reportRemoteTarget [vehicle player, 60];\n```","code":["blufor reportRemoteTarget [vehicle player, 60];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition"],"notes":[{"user":"Freddo3000","date":"2021-02-14T11:05:00Z","text":"This command cannot be used on projectiles, such as IR Grenades."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"requiredVersion","operator":null,"title":"requiredVersion","type":"command","url":"https://community.bistudio.com/wiki/requiredVersion","revid":341009,"updated":"2023-05-13T22:06:20Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if version of application is available. If the current version is older than the required one, a warning message is shown and false is returned.\n\nVersion of format **Major.Minor**, e.g. **1.30**","syntaxes":[{"syntax":"requiredVersion version","since":null,"effect":null,"exec":null,"params":[{"name":"version","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"version: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"version","types":["String"]}}],"examples":[{"text":"```sqf\nif !(requiredVersion \"1.09\") exitWith {};\n```","code":["if !(requiredVersion \"1.09\") exitWith {};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["productVersion","supportInfo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"resetCamShake","operator":null,"title":"resetCamShake","type":"command","url":"https://community.bistudio.com/wiki/resetCamShake","revid":321939,"updated":"2022-05-22T12:55:05Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Stops any ongoing camera shake effects. Does not prevent new effects from being created. To disallow new effects altogether, enableCamShake should be used.","syntaxes":[{"syntax":"resetCamShake","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nresetCamShake;\n```","code":["resetCamShake;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableCamShake","addCamShake","setCamShakeDefParams","setCamShakeParams"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"resetSubgroupDirection","operator":null,"title":"resetSubgroupDirection","type":"command","url":"https://community.bistudio.com/wiki/resetSubgroupDirection","revid":321292,"updated":"2022-05-13T19:08:11Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets formation direction of a group relative to current direction of the group leader. The group units will change their positions to form new formation if new formation direction is different (approx +/- 15 degrees). Does the same as:\n\n```sqf\n_grp setFormDir getDir leader _grp;\n```","syntaxes":[{"syntax":"resetSubgroupDirection unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"any member of the Group","types":["Object"],"since":null,"text":"unit: Object - any member of the Group"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nresetSubgroupDirection myUnit;\n```","code":["resetSubgroupDirection myUnit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFormDir","group","leader","formation","formationLeader","formationMembers","formationTask","formationDirection","formationPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"resistance","operator":null,"title":"resistance","type":"command","url":"https://community.bistudio.com/wiki/resistance","revid":308939,"updated":"2022-04-18T19:51:00Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Pre-defined variable for the resistance side.","syntaxes":[{"syntax":"resistance","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side _unit == resistance) then\n{\n    hint \"This is a resistance unit!\";\n};\n```","code":["if (side _unit == resistance) then\n{\n\thint \"This is a resistance unit!\";\n};"]},{"text":"```sqf\nhint format [\"%1\", resistance]; // Returns \"GUER\"\n```","code":["hint format [\"%1\", resistance]; // Returns \"GUER\""]}],"multiplayer":null,"problems":null,"aliases":["independent"],"see_also":["side","west","east","civilian","sideEmpty","sideAmbientLife"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"resize","operator":null,"title":"resize","type":"command","url":"https://community.bistudio.com/wiki/resize","revid":364809,"updated":"2024-06-15T13:16:01Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the size of the given array. The command does not return new array, it resizes the source array to the desired number of elements.\nIf the new size is bigger than the current size, the new places are filled with nil. The alternative syntax allows to fill resized positions with a given value. Array and HashMap values are copied.","syntaxes":[{"syntax":"array resize count","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"count","type":"Number","optional":false,"default":null,"description":"the new array size","types":["Number"],"since":null,"text":"count: Number - the new array size"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"count","types":["Number"]}},{"syntax":"array resize [count, fill]","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"count","type":"Number","optional":false,"default":null,"description":"the new array size","types":["Number"],"since":null,"text":"count: Number - the new array size"},{"name":"fill","type":"Anything","optional":false,"default":null,"description":"value to fill added positions","types":["Anything"],"since":null,"text":"fill: Anything - value to fill added positions"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"[count, fill]","types":["Array"]}}],"examples":[{"text":"```sqf\n_arrayNum = [0,1,2,3,4];\n_arrayNum resize 2; // _arrayNum is now [0, 1]\n_arrayNum resize 5; // _arrayNum is now [0, 1, nil, nil, nil]\n```","code":["_arrayNum = [0,1,2,3,4];\n_arrayNum resize 2; // _arrayNum is now [0, 1]\n_arrayNum resize 5; // _arrayNum is now [0, 1, nil, nil, nil]"]},{"text":"```sqf\nprivate _array = [0, 1, 2];\n_array resize [5, -1]; // _array is now [0, 1, 2, -1, -1]\n\nprivate _array = [0, 1, 2];\n_array resize [1, -1]; // _array is now [0]\n\nprivate _array = [0, 1, 2];\n_array resize [4, \"something\"]; // _array is now [0, 1, 2, \"something\"]\n```","code":["private _array = [0, 1, 2];\n_array resize [5, -1]; // _array is now [0, 1, 2, -1, -1]\n\nprivate _array = [0, 1, 2];\n_array resize [1, -1]; // _array is now [0]\n\nprivate _array = [0, 1, 2];\n_array resize [4, \"something\"]; // _array is now [0, 1, 2, \"something\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","reverse","deleteAt","deleteRange"],"notes":[{"user":"DreadedEntity","date":"2014-11-13T06:26:00Z","text":"Use this number to resize the array to the number of elements desired, not the desired index of the final element.\n\nresize cannot be used to create a new array."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"resources","operator":null,"title":"resources","type":"command","url":"https://community.bistudio.com/wiki/resources","revid":319310,"updated":"2022-05-13T09:23:51Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Returns the resources of a team member. Results are local to the PC on which command was executed.","syntaxes":[{"syntax":"resources member","since":null,"effect":null,"exec":null,"params":[{"name":"member","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"member: Team Member"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"member","types":["Team Member"]}}],"examples":[{"text":"```sqf\nresources teamMember _unit;\n```","code":["resources teamMember _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addResources","deleteResources"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"respawnVehicle","operator":null,"title":"respawnVehicle","type":"command","url":"https://community.bistudio.com/wiki/respawnVehicle","revid":370172,"updated":"2024-11-03T21:40:23Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets vehicle as respawnable in MP game (see Vehicle Respawn). The vehicle will be spawned at the locality and coordinates it was prior to destruction.\nIf respawn type is set to base respawn (type 3) and vehicle respawn marker is provided (respawn_vehicle_SIDEXXX), vehicle will spawn on the marker. The command must be executed where vehicle is local. If the vehicle is in respawn queue, as long as the vehicle is local it should be possible to update params of the respawning vehicle, i.e change delay, disable respawn, etc.","syntaxes":[{"syntax":"vehicle respawnVehicle [respawnDelay, respawnCount, deleteOldWreck, respawnOnServer, respawnFlying, respawnUnit, respawnMode, respawnSide, useRespawnMarkerDir]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"transport","types":["Object"],"since":null,"text":"vehicle: Object - transport"},{"name":"respawnDelay","type":"Number","optional":true,"default":"-1","description":"delay in seconds between respawns. (-1 to use 3DEN vehicle respawn delay or *respawnVehicleDelay* from description.ext)","types":["Number"],"since":null,"text":"respawnDelay: Number - (Optional since 2.18, default -1) delay in seconds between respawns. (-1 to use 3DEN vehicle respawn delay or *respawnVehicleDelay* from description.ext)"},{"name":"respawnCount","type":"Number","optional":true,"default":"unlimited respawns","description":"how many times to respawn vehicle in total. (since 2.18 -1 unlimited respawns, 0 stop respawning)","types":["Number"],"since":null,"text":"respawnCount: Number - (Optional, default unlimited respawns) how many times to respawn vehicle in total. (since 2.18 -1 unlimited respawns, 0 stop respawning)"},{"name":"deleteOldWreck","type":"Boolean","optional":true,"default":"false","description":"deletes old wreck automatically after vehicle respawns","types":["Boolean"],"since":"arma3 2.18","text":"deleteOldWreck: Boolean - (Optional, default false) - deletes old wreck automatically after vehicle respawns"},{"name":"respawnOnServer","type":"Boolean","optional":true,"default":"false","description":"wreck is always transferred to the server and the new vehicle always respawns on server","types":["Boolean"],"since":"arma3 2.18","text":"respawnOnServer: Boolean - (Optional, default false) - wreck is always transferred to the server and the new vehicle always respawns on server"},{"name":"respawnFlying","type":"Boolean","optional":true,"default":"false","description":"by default all vehicles placed on the ground, true overrides this","types":["Boolean"],"since":"arma3 2.18","text":"respawnFlying: Boolean - (Optional, default false) - by default all vehicles placed on the ground, true overrides this"},{"name":"respawnUnit","type":"Object","optional":true,"default":"objNull","description":"unit that would be put in the driver seat after vehicle respawns","types":["Object"],"since":"arma3 2.18","text":"respawnUnit: Object - (Optional, default objNull) - unit that would be put in the driver seat after vehicle respawns"},{"name":"respawnMode","type":"Number or String","optional":true,"default":"-1","description":"overrides vehicle respawn mode. Available modes are: 2 or \"INSTANT\" and 3 or \"BASE\". -1 use description.ext value.","types":["Number","String"],"since":"arma3 2.18","text":"respawnMode: Number or String - (Optional, default -1) - overrides vehicle respawn mode. Available modes are: 2 or \"INSTANT\" and 3 or \"BASE\". -1 use description.ext value."},{"name":"respawnSide","type":"Side","optional":true,"default":"typical vehicle side","description":"sets respawn side for the purpouse of selecting respawn marker","types":["Side"],"since":"arma3 2.18","text":"respawnSide: Side - (Optional, default typical vehicle side) - sets respawn side for the purpouse of selecting respawn marker"},{"name":"useRespawnMarkerDir","type":"Boolean","optional":true,"default":"false","description":"respawn vehicle matches respawn marker direction or the old wreck direction. false - random direction.","types":["Boolean"],"since":"arma3 2.18","text":"useRespawnMarkerDir: Boolean - (Optional, default false) - respawn vehicle matches respawn marker direction or the old wreck direction. false - random direction."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[respawnDelay, respawnCount, deleteOldWreck, respawnOnServer, respawnFlying, respawnUnit, respawnMode, respawnSide, useRespawnMarkerDir]","types":["Array"]}}],"examples":[{"text":"```sqf\ncar respawnVehicle [5, 3]; // 'car' will respawn at the predefined marker for the side after 5 seconds. The unit will respawn 3 times.\n```","code":["car respawnVehicle [5, 3]; // 'car' will respawn at the predefined marker for the side after 5 seconds. The unit will respawn 3 times."]},{"text":"```sqf\ncar respawnVehicle [30]; // 'car' will respawn at the predefined marker for the side after 30 seconds. The unit will respawn an unlimited number of times.\n```","code":["car respawnVehicle [30]; // 'car' will respawn at the predefined marker for the side after 30 seconds. The unit will respawn an unlimited number of times."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Vehicle Respawn","getRespawnVehicleInfo","playerRespawnTime","setPlayerRespawnTime"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"restartEditorCamera","operator":null,"title":"restartEditorCamera","type":"command","url":"https://community.bistudio.com/wiki/restartEditorCamera","revid":353393,"updated":"2024-03-15T17:12:01Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Restarts the mission editor camera (if it was deleted by a script,for example).\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"restartEditorCamera map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"reveal","operator":null,"title":"reveal","type":"command","url":"https://community.bistudio.com/wiki/reveal","revid":369307,"updated":"2024-09-03T18:42:54Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Reveals a target to a group. If *toWhom* is a unit, unit's group is considered. If *toWhom* is a vehicle, vehicle commander's group is considered.  The knowledge value will be set to the highest level any unit of the revealing side has about the revealed target. If the revealing side has *no* knowledge about the revealed target, the value will be set to 1.\n\n> [!NOTE]\n> The knowledge level can only be increased by this command, not decreased. Use forgetTarget first if you need to decrease value.","syntaxes":[{"syntax":"toWhom reveal target","since":null,"effect":null,"exec":null,"params":[{"name":"toWhom","type":"Object or Group","optional":false,"default":null,"description":"which receives revealing information","types":["Object","Group"],"since":null,"text":"toWhom: Object or Group - which receives revealing information"},{"name":"target","type":"Object","optional":false,"default":null,"description":"which is revealed","types":["Object"],"since":null,"text":"target: Object - which is revealed"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"toWhom","types":["Object","Group"]},"right":{"text":"target","types":["Object"]}},{"syntax":"toWhom reveal [target, accuracy]","since":"arma2oa 1.60","effect":null,"exec":null,"params":[{"name":"toWhom","type":"Object or Group","optional":false,"default":null,"description":"which receives revealing information","types":["Object","Group"],"since":null,"text":"toWhom: Object or Group - which receives revealing information"},{"name":"target","type":"Object","optional":false,"default":null,"description":"which is revealed","types":["Object"],"since":null,"text":"target: Object - which is revealed"},{"name":"accuracy","type":"Number","optional":false,"default":null,"description":"knowledge value, clamped to 0..4 range","types":["Number"],"since":null,"text":"accuracy: Number - knowledge value, clamped to 0..4 range"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"toWhom","types":["Object","Group"]},"right":{"text":"[target, accuracy]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldierOne reveal _soldierTwo; // soldierOne knowsAbout information about soldierTwo is updated\n```","code":["_soldierOne reveal _soldierTwo; // soldierOne knowsAbout information about soldierTwo is updated"]},{"text":"```sqf\nplayer reveal cursorObject; // player knowsAbout information about object under cursor is updated\n```","code":["player reveal cursorObject; // player knowsAbout information about object under cursor is updated"]},{"text":"```sqf\n_soldierOne reveal [_soldierTwo, 1.5];\n```","code":["_soldierOne reveal [_soldierTwo, 1.5];"]}],"multiplayer":"targetKnowledge and knowsAbout information only get updated on the PC where this command was executed.","problems":null,"aliases":[],"see_also":["nearTargets","knowsAbout","forgetTarget","ignoreTarget"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"revealMine","operator":null,"title":"revealMine","type":"command","url":"https://community.bistudio.com/wiki/revealMine","revid":369185,"updated":"2024-09-03T10:34:46Z","groups":["Mines"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets given mine as known to the side. (Knowledge about a mine is always shared across all units in a side.)","syntaxes":[{"syntax":"side revealMine mine","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"},{"name":"mine","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"mine: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"side","types":["Side"]},"right":{"text":"mine","types":["Object"]}}],"examples":[{"text":"```sqf\nwest revealMine _mine;\n```","code":["west revealMine _mine;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allMines","detectedMines","mineDetectedBy","createMine","mineActive"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mines","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"reverse","operator":null,"title":"reverse","type":"command","url":"https://community.bistudio.com/wiki/reverse","revid":377138,"updated":"2026-01-01T10:29:57Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.24"}],"since":{"game":"arma3","name":"Arma 3","version":"1.24"},"arma3_since":"1.24","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Reverses given array by reference (modifies the original array, just like resize). The alternative syntax can be used to reverse a ANSI string. If Unicode support is desired, see forceUnicode.","syntaxes":[{"syntax":"reverse array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Anything"]}},{"syntax":"reverse string","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to be reversed","types":["String"],"since":null,"text":"string: String - string to be reversed"}],"returns":{"type":"String","types":["String"],"description":"reversed string","text":"String - reversed string"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\n_arr = [1,2,3];\nreverse _arr;\nhint str _arr; // [3,2,1]\n```","code":["_arr = [1,2,3];\nreverse _arr;\nhint str _arr; // [3,2,1]"]},{"text":"```sqf\n_wordArr = toArray \"gateman\";\nreverse _wordArr;\nhint toString _wordArr; // nametag\n```","code":["_wordArr = toArray \"gateman\";\nreverse _wordArr;\nhint toString _wordArr; // nametag"]},{"text":"```sqf\nreverse \"treboR\"; // Returns \"Robert\"\n```","code":["reverse \"treboR\"; // Returns \"Robert\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","resize","select","in","find","toArray","toString","forEach","count","pushBack","pushBackUnique","apply","append","sort","param","params","arrayIntersect","splitString","joinString","forceUnicode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.24","Scripting Commands"]},{"name":"reversedMouseY","operator":null,"title":"reversedMouseY","type":"command","url":"https://community.bistudio.com/wiki/reversedMouseY","revid":319719,"updated":"2022-05-13T09:24:45Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if mouse vertical axe is inverted.","syntaxes":[{"syntax":"reversedMouseY","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (reversedMouseY) then { hint \"Dude!\" };\n```","code":["if (reversedMouseY) then { hint \"Dude!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMousePosition","getMousePosition"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"roadAt","operator":null,"title":"roadAt","type":"command","url":"https://community.bistudio.com/wiki/roadAt","revid":377838,"updated":"2026-01-03T04:32:28Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns a road segment containing given position, objNull otherwise. Same as isOnRoad only returns the actual road object instead of boolean.","syntaxes":[{"syntax":"roadAt position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object or PositionAGL (especially on bridges) or Arma 3 v2.00 Position2D","optional":false,"default":null,"description":"array, in which case Z will be automatically deduced as the height of the road surface","types":["Object","PositionAGL","Position2D"],"since":null,"text":"position: Object or PositionAGL (especially on bridges) or Arma 3 v2.00 Position2D - array, in which case Z will be automatically deduced as the height of the road surface"}],"returns":{"type":"Object","types":["Object"],"description":"road segment or objNull","text":"Object - road segment or objNull"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Object","PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_road = roadAt ASLToAGL getPosASL player;\n```","code":["_road = roadAt ASLToAGL getPosASL player;"]},{"text":"```sqf\n_isOnRoad = !isNull roadAt player;\n```","code":["_isOnRoad = !isNull roadAt player;"]},{"text":"For detecting bridges, for example:\n\n```sqf\ngetModelInfo (roadAt ASLToAGL getPosASL player); // [\"bridgesea_01_f.p3d\", \"a3\\structures_f_exp\\infrastructure\\bridges\\bridgesea_01_f.p3d\", true]\n```","code":["getModelInfo (roadAt ASLToAGL getPosASL player); // [\"bridgesea_01_f.p3d\", \"a3\\structures_f_exp\\infrastructure\\bridges\\bridgesea_01_f.p3d\", true]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearRoads","roadsConnectedTo","isOnRoad","surfaceIsWater","getRoadInfo","nearestTerrainObjects"],"notes":[{"user":"OOKexOo","date":"2016-12-30T21:40:00Z","text":"This command does not necessarily return the segment which center is the closest to the given position.\n\nIn order to get such segment use nearRoads.\n\n```sqf\n_closest_road = (_pos nearRoads 0.1) select 0;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"roadsConnectedTo","operator":null,"title":"roadsConnectedTo","type":"command","url":"https://community.bistudio.com/wiki/roadsConnectedTo","revid":369200,"updated":"2024-09-03T10:34:49Z","groups":["Roads and Airports"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find the road segments connected to the given road segment.\n\n> [!IMPORTANT]\n> - Pedestrian roads such as `\"TRAIL\"`s are missing connection information by design, therefore the primary syntax will return empty array for those - use the alternative syntax to return pedestrian roads.\n> - Road connection is not bidirectional; e.g road segment Y can be connected to road segment Z, but road segment Z can lack a connection with road segment Y.","syntaxes":[{"syntax":"roadsConnectedTo roadSegment","since":null,"effect":null,"exec":null,"params":[{"name":"roadSegment","type":"Object","optional":false,"default":null,"description":"road segment","types":["Object"],"since":null,"text":"roadSegment: Object - road segment"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"connected road segments","text":"Array of Objects - connected road segments"},"form":"unary","operator":null,"left":null,"right":{"text":"roadSegment","types":["Object"]}},{"syntax":"roadsConnectedTo [roadSegment, extended]","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"roadSegment","type":"Object","optional":false,"default":null,"description":"road segment","types":["Object"],"since":null,"text":"roadSegment: Object - road segment"},{"name":"extended","type":"Boolean","optional":true,"default":"false","description":"when true, performs a more thorough search on top of base behaviour, slower but returns pedestrian and other missing road segments","types":["Boolean"],"since":null,"text":"extended: Boolean - (Optional, default false) when true, performs a more thorough search on top of base behaviour, slower but returns pedestrian and other missing road segments"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"connected road segments","text":"Array of Objects - connected road segments"},"form":"unary","operator":null,"left":null,"right":{"text":"[roadSegment, extended]","types":["Array"]}}],"examples":[{"text":"```sqf\n_road = (player nearRoads 50) select 0;\n_connectedRoads = roadsConnectedTo _road;\n```","code":["_road = (player nearRoads 50) select 0;\n_connectedRoads = roadsConnectedTo _road;"]},{"text":"```sqf\n_road = (player nearRoads 50) select 0;\n_connectedRoadsIncPedestrian = roadsConnectedTo [_road, true];\n```","code":["_road = (player nearRoads 50) select 0;\n_connectedRoadsIncPedestrian = roadsConnectedTo [_road, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearRoads","isOnRoad","roadAt","surfaceIsWater","getRoadInfo","nearestTerrainObjects"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"roleDescription","operator":null,"title":"roleDescription","type":"command","url":"https://community.bistudio.com/wiki/roleDescription","revid":329074,"updated":"2022-07-21T23:46:21Z","groups":["Object Manipulation","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unit description set in the editor and visible on role selection screen in multiplayer.","syntaxes":[{"syntax":"roleDescription unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerRole = roleDescription player;\n```","code":["_playerRole = roleDescription player;"]}],"multiplayer":null,"problems":"**Does not** work in single player.","aliases":[],"see_also":["name","getPlayerUID","vehicleVarName","worldName","briefingName","missionName","serverName"],"notes":[{"user":"Killzone_Kid","date":"2015-06-29T12:05:00Z","text":"One thing you should know about roles. When switching to units placed in editor on the fly in MP, it could mess up the role of the player. Could be bug, could be intended, but I would not recommend doing this. Create new unit dynamically if you need to switch to. Anyway, if role of the unit is messed up so is roleDescription."},{"user":"Pierre MGI","date":"2017-05-26T01:10:00Z","text":"roleDescription works for playableUnits only. That means not on AI disabled in lobby and not in SP (even for player)."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Manipulation","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"ropeAttachedObjects","operator":null,"title":"ropeAttachedObjects","type":"command","url":"https://community.bistudio.com/wiki/ropeAttachedObjects","revid":377098,"updated":"2026-01-01T09:57:17Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array of all entities that are attached to the transport with ropes. This command is the opposite of ropeAttachedTo.","syntaxes":[{"syntax":"ropeAttachedObjects ropesOwner","since":null,"effect":null,"exec":null,"params":[{"name":"ropesOwner","type":"Object","optional":false,"default":null,"description":"transport from which a single or multiple ropes are originating","types":["Object"],"since":null,"text":"ropesOwner: Object - transport from which a single or multiple ropes are originating"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"array of attached entities on ropes","text":"Array of Objects - array of attached entities on ropes"},"form":"unary","operator":null,"left":null,"right":{"text":"ropesOwner","types":["Object"]}}],"examples":[{"text":"```sqf\n_cargoArray = ropeAttachedObjects heli1;\n```","code":["_cargoArray = ropeAttachedObjects heli1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeAttachedTo","operator":null,"title":"ropeAttachedTo","type":"command","url":"https://community.bistudio.com/wiki/ropeAttachedTo","revid":350037,"updated":"2023-11-20T22:12:04Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the owner of the first rope - the transport to which other entities are attached with ropes. This command is the opposite of ropeAttachedObjects. To return all owners see ropesAttachedTo.","syntaxes":[{"syntax":"ropeAttachedTo cargo","since":null,"effect":null,"exec":null,"params":[{"name":"cargo","type":"Object","optional":false,"default":null,"description":"entity attached to the end of the first rope","types":["Object"],"since":null,"text":"cargo: Object - entity attached to the end of the first rope"}],"returns":{"type":"Object","types":["Object"],"description":"a transport from which the first rope originates, the rope owner","text":"Object - a transport from which the first rope originates, the rope owner"},"form":"unary","operator":null,"left":null,"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"```sqf\n_heli = ropeAttachedTo veh1;\n```","code":["_heli = ropeAttachedTo veh1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropesAttachedTo","ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeAttachEnabled","operator":null,"title":"ropeAttachEnabled","type":"command","url":"https://community.bistudio.com/wiki/ropeAttachEnabled","revid":309984,"updated":"2022-05-05T12:17:03Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if entity can be attached to a rope end.","syntaxes":[{"syntax":"ropeAttachEnabled entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity to check","types":["Object"],"since":null,"text":"entity: Object - entity to check"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if allowed","text":"Boolean - true if allowed"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\nropeAttachEnabled veh1;\n```","code":["ropeAttachEnabled veh1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeAttachTo","operator":null,"title":"ropeAttachTo","type":"command","url":"https://community.bistudio.com/wiki/ropeAttachTo","revid":329674,"updated":"2022-08-01T01:24:20Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attaches entity to the rope end with optional offset. For detach operation use ropeDetach.","syntaxes":[{"syntax":"[entity, toPoint, ropeEndDownVector] ropeAttachTo rope","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity to be attached to the end of rope","types":["Object"],"since":null,"text":"entity: Object - entity to be attached to the end of rope"},{"name":"toPoint","type":"String or Array","optional":true,"default":null,"description":"position for the rope end, either a memory point String or relative offset Array","types":["String","Array"],"since":null,"text":"toPoint: String or Array - (Optional) position for the rope end, either a memory point String or relative offset Array"},{"name":"ropeEndDownVector","type":"String or Array","optional":true,"default":"[0,0,-1]","description":"either a memory point String or relative vector Array. If String is given, then `ropeEndDownVector` is calculated from `toPoint` towards `ropeEndDownVector` memory point","types":["String","Array"],"since":null,"text":"ropeEndDownVector: String or Array - (Optional, default [0,0,-1]) either a memory point String or relative vector Array. If String is given, then `ropeEndDownVector` is calculated from `toPoint` towards `ropeEndDownVector` memory point"},{"name":"rope","type":"Object","optional":false,"default":null,"description":"the rope to which entity will be attached to","types":["Object"],"since":null,"text":"rope: Object - the rope to which entity will be attached to"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[entity, toPoint, ropeEndDownVector]","types":["Array"]},"right":{"text":"rope","types":["Object"]}},{"syntax":"entity ropeAttachTo rope","since":"arma3 2.10","effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"entity to be attached to the end of rope","types":["Object"],"since":null,"text":"entity: Object - entity to be attached to the end of rope"},{"name":"rope","type":"Object","optional":false,"default":null,"description":"the rope to which entity will be attached to","types":["Object"],"since":null,"text":"rope: Object - the rope to which entity will be attached to"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\n[veh1, [0,0,0], [0,0,-1]] ropeAttachTo (ropes heli1 select 0);\n```","code":["[veh1, [0,0,0], [0,0,-1]] ropeAttachTo (ropes heli1 select 0);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeCreate","operator":null,"title":"ropeCreate","type":"command","url":"https://community.bistudio.com/wiki/ropeCreate","revid":377047,"updated":"2026-01-01T08:54:21Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Creates a PhysX rope with given params. Since Arma 3 v2.14 the optional arguments can be skipped by setting them to nil.\n\n> [!NOTE]\n> - *fromObject* has to be transport vehicle, alive with rope attachment enabled, *toObject* has to be an entity, alive with rope attachment enabled.\n> - `ropeEndType` is defined in config under `\"CfgNonAIVehicles\" >> \"RopeEnd\"`; see Arma 3: Ropes. Currently this is a hook that will be created on the end of the rope, and `ropeEndDownVector` is its orientation, [0,0,-1] for example. The `\"RopeEnd\"` is only shown when the rope is created object to object, it does not show on the open ended rope for some reason. There is currently no `\"RopeStart\"`.\n> - The rope creation is limited to 63 segments.","syntaxes":[{"syntax":"ropeCreate [fromObject, fromPoint, toObject, toPoint, length, ropeStart, ropeEnd, ropeType, nSegments]","since":null,"effect":null,"exec":null,"params":[{"name":"fromObject","type":"Object","optional":false,"default":null,"description":"transport where the rope originates and which fly behavior will be affected","types":["Object"],"since":null,"text":"fromObject: Object - transport where the rope originates and which fly behavior will be affected"},{"name":"fromPoint","type":"String or Array","optional":false,"default":null,"description":"position for the rope start, either a memory point String or relative offset Array","types":["String","Array"],"since":null,"text":"fromPoint: String or Array - position for the rope start, either a memory point String or relative offset Array"},{"name":"toObject","type":"Object","optional":false,"default":null,"description":"entity which is automatically attached to the end of the rope","types":["Object"],"since":null,"text":"toObject: Object - entity which is automatically attached to the end of the rope"},{"name":"toPoint","type":"String or Array","optional":false,"default":null,"description":"position for the rope end, either a memory point String or relative offset Array","types":["String","Array"],"since":null,"text":"toPoint: String or Array - position for the rope end, either a memory point String or relative offset Array"},{"name":"length","type":"Number","optional":true,"default":"-1","description":"rope length in meters","types":["Number"],"since":null,"text":"length: Number - (Optional, default -1) rope length in meters"},{"name":"ropeStart","type":"Array with [ropeStartType, ropeStartDownVector]","optional":true,"default":"[\"\", [0,0,-1]]","description":"ropeStartType: String - type of the rope start (see description)\n- ropeStartDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeStartDownVector` is calculated from `fromPoint` towards `ropeStartDownVector` memory point","types":["Array"],"since":null,"text":"ropeStart: Array with [ropeStartType, ropeStartDownVector] - (Optional, default [\"\", [0,0,-1]])\n- ropeStartType: String - type of the rope start (see description)\n- ropeStartDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeStartDownVector` is calculated from `fromPoint` towards `ropeStartDownVector` memory point"},{"name":"ropeEnd","type":"Array with [ropeEndType, ropeEndDownVector]","optional":true,"default":"[\"\", [0,0,-1]]","description":":\n- ropeEndType: String - type of the rope end (see description)\n- ropeEndDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeEndDownVector` is calculated from `toPoint` towards `ropeEndDownVector` memory point","types":["Array"],"since":null,"text":"ropeEnd: Array with [ropeEndType, ropeEndDownVector] - (Optional, default [\"\", [0,0,-1]]):\n- ropeEndType: String - type of the rope end (see description)\n- ropeEndDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeEndDownVector` is calculated from `toPoint` towards `ropeEndDownVector` memory point"},{"name":"ropeType","type":"String","optional":true,"default":"\"Rope\"","description":"rope type, `CfgVehicles`' classname","types":["String"],"since":"arma3 2.06","text":"ropeType: String - (Optional, default \"Rope\") - rope type, `CfgVehicles`' classname"},{"name":"nSegments","type":"Number","optional":true,"default":"-1","description":"number of rope segments (max 63)","types":["Number"],"since":"arma3 2.14","text":"nSegments: Number - (Optional, default -1) - number of rope segments (max 63)"}],"returns":{"type":"Object","types":["Object"],"description":"created rope or objNull on failure","text":"Object - created rope or objNull on failure"},"form":"unary","operator":null,"left":null,"right":{"text":"[fromObject, fromPoint, toObject, toPoint, length, ropeStart, ropeEnd, ropeType, nSegments]","types":["Array"]}},{"syntax":"ropeCreate [fromObject, fromPoint, length, ropeStart, ropeEnd, ropeType, nSegments]","since":null,"effect":null,"exec":null,"params":[{"name":"fromObject","type":"Object","optional":false,"default":null,"description":"transport where the rope originates and which fly behavior will be affected","types":["Object"],"since":null,"text":"fromObject: Object - transport where the rope originates and which fly behavior will be affected"},{"name":"fromPoint","type":"String or Array","optional":false,"default":null,"description":"position for the rope start, either a memory point String or relative offset Array","types":["String","Array"],"since":null,"text":"fromPoint: String or Array - position for the rope start, either a memory point String or relative offset Array"},{"name":"length","type":"Number","optional":false,"default":null,"description":"rope length in meters","types":["Number"],"since":null,"text":"length: Number - rope length in meters"},{"name":"ropeStart","type":"Array with [ropeStartType, ropeStartDownVector]","optional":true,"default":"[\"\", [0,0,-1]]","description":"ropeStartType: String - type of the rope start (see description)\n- ropeStartDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeStartDownVector` is calculated from `fromPoint` towards `ropeStartDownVector` memory point","types":["Array"],"since":null,"text":"ropeStart: Array with [ropeStartType, ropeStartDownVector] - (Optional, default [\"\", [0,0,-1]])\n- ropeStartType: String - type of the rope start (see description)\n- ropeStartDownVector: String or Array, either a memory point String or relative vector Array. If String is given, then `ropeStartDownVector` is calculated from `fromPoint` towards `ropeStartDownVector` memory point"},{"name":"ropeEnd","type":"Array with [ropeEndType, ropeEndDownVector]","optional":true,"default":"[\"\", [0,0,-1]]","description":"ropeEndType: String - type of the rope end (see description)\n- ropeEndDownVector: Array - relative vector","types":["Array"],"since":null,"text":"ropeEnd: Array with [ropeEndType, ropeEndDownVector] - (Optional, default [\"\", [0,0,-1]])\n- ropeEndType: String - type of the rope end (see description)\n- ropeEndDownVector: Array - relative vector"},{"name":"ropeType","type":"String","optional":true,"default":"\"Rope\"","description":"rope type, `CfgVehicles`' classname","types":["String"],"since":"arma3 2.06","text":"ropeType: String - (Optional, default \"Rope\") - rope type, `CfgVehicles`' classname"},{"name":"nSegments","type":"Number","optional":true,"default":"-1","description":"number of rope segments (max 63)","types":["Number"],"since":"arma3 2.14","text":"nSegments: Number - (Optional, default -1) - number of rope segments (max 63)"}],"returns":{"type":"Object","types":["Object"],"description":"created rope or objNull on failure","text":"Object - created rope or objNull on failure"},"form":"unary","operator":null,"left":null,"right":{"text":"[fromObject, fromPoint, length, ropeStart, ropeEnd, ropeType, nSegments]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyRope = ropeCreate [vehicle player, \"slingload0\", myCargo, [0, 0, 0], 10];\n```","code":["myRope = ropeCreate [vehicle player, \"slingload0\", myCargo, [0, 0, 0], 10];"]},{"text":"```sqf\nmyRope = ropeCreate [veh1, [0, 0, -2], veh2, [0, 0, 0], 10];\n```","code":["myRope = ropeCreate [veh1, [0, 0, -2], veh2, [0, 0, 0], 10];"]},{"text":"Free end rope (Alt Syntax):\n\n```sqf\nmyRope = ropeCreate [vehicle player, [0, 0, 0], 10];\n```","code":["myRope = ropeCreate [vehicle player, [0, 0, 0], 10];"]},{"text":"A rope with a hook on the end:\n\n```sqf\nmyRope = ropeCreate [heli, \"slingload0\", player, [0, 0, 2], 20, [], [\"RopeEnd\", [0, 0, -1]]];\n```","code":["myRope = ropeCreate [heli, \"slingload0\", player, [0, 0, 2], 20, [], [\"RopeEnd\", [0, 0, -1]]];"]},{"text":"Since 2.14:\n\n```sqf\nmyRope = ropeCreate [vehicle player, [0, 0, 0], 10, nil, nil, nil, 50];\n```","code":["myRope = ropeCreate [vehicle player, [0, 0, 0], 10, nil, nil, nil, 50];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Ropes","ropeDestroy","ropeDetach","ropes","ropeSegments"],"notes":[{"user":"Tajin","date":"2014-11-08T14:57:00Z","text":"Doesn't work well for towing vehicles on the ground.\n\nTheir wheels don't turn freely and have a LOT of friction. You'll most likely end up flipping the vehicle over if you try to tow it.\n\nAlso note that ropes can be destroyed/cut by shooting at them.\n\n**Edit:** see setTowParent since Arma 3 v2.06!"},{"user":"Feint","date":"2015-01-04T03:24:00Z","text":"Pay special attention to what is your **fromObject** and what is your **toObject** as this will have an impact on the physics of the rope.\n\n*For example:* If you want to tow an Assault CRRC from a heavier Speedboat Minigun, attach two boats together with a rope.  If you drive the Speedboat Minigun and set the CRRC as the fromObject, the rope will have almost no elasticity and the CRRC will yank around as you tow it.  However, if you set the CRRC as the toObject, the rope will have more elasticity and will be a little friendlier for the CRRC when you are towing it."},{"user":"Sa-Matra","date":"2024-05-22T04:20:07Z","text":"Following simulations are considered transports by that transport config list:\n\n```sqf\n\"motorcycle\"\n\"car\"\n\"carx\"\n\"tankx\"\n\"airplanex\"\n\"helicopterrtd\"\n\"shipx\"\n\"submarinex\"\n\"paraglide\"\n\"parachute\"\n```\n\nThere could be more but unlisted there, but these should cover majority of the vehicles in all mods."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Introduced with Take On Helicopters version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ropeCut","operator":null,"title":"ropeCut","type":"command","url":"https://community.bistudio.com/wiki/ropeCut","revid":353360,"updated":"2024-03-15T17:11:55Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Cuts the given rope to the specified length. If some entity was attached to the end of the rope, it will be detached. The rope remains attached to its parent transport and if the length is set to 0 or even negative does not get destroyed. Use ropeDestroy to remove it completely.\n\n> [!NOTE]\n> The rope could only be shortened. If the cut length is greater than current rope length, nothing happens","syntaxes":[{"syntax":"ropeCut [rope, length]","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":"rope object obtained from ropeCreate","types":["Object"],"since":null,"text":"rope: Object - rope object obtained from ropeCreate"},{"name":"length","type":"Number","optional":false,"default":null,"description":"length of the rope in meters after the cut","types":["Number"],"since":null,"text":"length: Number - length of the rope in meters after the cut"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[rope, length]","types":["Array"]}}],"examples":[{"text":"```sqf\nropeCut [ropes heli1 select 0, 5];\n```","code":["ropeCut [ropes heli1 select 0, 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeDestroy","operator":null,"title":"ropeDestroy","type":"command","url":"https://community.bistudio.com/wiki/ropeDestroy","revid":309944,"updated":"2022-05-05T12:16:59Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Destroys the given rope. If the rope is attached to a vehicle, it will be detached and then destroyed.","syntaxes":[{"syntax":"ropeDestroy rope","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":"rope object returned by ropeCreate command","types":["Object"],"since":null,"text":"rope: Object - rope object returned by ropeCreate command"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\nropeDestroy myRope;\n```","code":["ropeDestroy myRope;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropeCreate","ropeDetach","ropeSetCargoMass","ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeLength","ropeUnwound","ropeAttachedTo","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ropeDetach","operator":null,"title":"ropeDetach","type":"command","url":"https://community.bistudio.com/wiki/ropeDetach","revid":319665,"updated":"2022-05-13T09:24:40Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Detaches attached object from rope (i.e. detaches rope end from attached to it entity). See ropeAttachTo for attach operation.","syntaxes":[{"syntax":"attachedObject ropeDetach rope","since":null,"effect":null,"exec":null,"params":[{"name":"attachedObject","type":"Object","optional":false,"default":null,"description":"entity attached to the end of rope","types":["Object"],"since":null,"text":"attachedObject: Object - entity attached to the end of rope"},{"name":"rope","type":"Object","optional":false,"default":null,"description":"rope object to which entity is attached","types":["Object"],"since":null,"text":"rope: Object - rope object to which entity is attached"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"attachedObject","types":["Object"]},"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\nvehicle player ropeDetach myRope;\n```","code":["vehicle player ropeDetach myRope;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropeCreate","ropeDestroy","ropeSetCargoMass","ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeLength","ropeUnwound","ropeAttachedTo","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"ropeEndPosition","operator":null,"title":"ropeEndPosition","type":"command","url":"https://community.bistudio.com/wiki/ropeEndPosition","revid":377646,"updated":"2026-01-02T09:01:47Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns start and end positions for the given rope. If command fails, empty array `[]` is returned.","syntaxes":[{"syntax":"ropeEndPosition rope","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":"rope object","types":["Object"],"since":null,"text":"rope: Object - rope object"}],"returns":{"type":"Array with [startPos, endPos]","types":["Array"],"description":"startPos: PositionAGL - endPos: PositionAGL","text":"Array with [startPos, endPos]\n- startPos: PositionAGL\n- endPos: PositionAGL"},"form":"unary","operator":null,"left":null,"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\n_ends = ropeEndPosition (ropes heli1 select 0);\n_start = _ends select 0;\n_end = _ends select 1;\n```","code":["_ends = ropeEndPosition (ropes heli1 select 0);\n_start = _ends select 0;\n_end = _ends select 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropeLength","operator":null,"title":"ropeLength","type":"command","url":"https://community.bistudio.com/wiki/ropeLength","revid":364981,"updated":"2024-07-04T19:58:04Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return rope length in meters (set by ropeCreate, ropeCut, ropeUnwind).\n\n> [!NOTE]\n> Returned rope length will remain the same, even if the rope is stretched.","syntaxes":[{"syntax":"ropeLength rope","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"rope: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\n_length = ropeLength (ropes heli1 select 0);\n```","code":["_length = ropeLength (ropes heli1 select 0);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[{"user":"Sa-Matra","date":"2024-06-08T04:40:02Z","text":"Returns 0 for rope segments. To get length of individual segment, do `vectorMagnitude vectorUpVisual _segment * 0.3`. 0.3 is model height of `RopeSegment`, you can calculate it using boundingBox for other rope types."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropes","operator":null,"title":"ropes","type":"command","url":"https://community.bistudio.com/wiki/ropes","revid":340878,"updated":"2023-05-13T21:30:53Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all ropes attached to a ropes owner transport vehicle.","syntaxes":[{"syntax":"ropes ropesOwner","since":null,"effect":null,"exec":null,"params":[{"name":"ropesOwner","type":"Object","optional":false,"default":null,"description":"a transport from which the ropes originate","types":["Object"],"since":null,"text":"ropesOwner: Object - a transport from which the ropes originate"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"array of the actual rope objects","text":"Array of Objects - array of the actual rope objects"},"form":"unary","operator":null,"left":null,"right":{"text":"ropesOwner","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str (ropes vehicle player);\n```","code":["hint str (ropes vehicle player);"]},{"text":"```sqf\n_rope1 = (ropes heli1) select 0;\n```","code":["_rope1 = (ropes heli1) select 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[{"user":"Waffle SS.","date":"2014-10-13T02:05:00Z","text":"The ropes command seems to return each individual sling load rope.\nropes will return an empty Array if the sling load ropes are not deployed.\nRopes as of A3 1.33 have a cfgVehicles classname of \"Rope\"."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"ropesAttachedTo","operator":null,"title":"ropesAttachedTo","type":"command","url":"https://community.bistudio.com/wiki/ropesAttachedTo","revid":352477,"updated":"2024-02-11T23:39:44Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the owners of all ropes attached to the cargo - the transports to which other entities are attached with ropes.","syntaxes":[{"syntax":"ropesAttachedTo cargo","since":null,"effect":null,"exec":null,"params":[{"name":"cargo","type":"Object","optional":false,"default":null,"description":"entity attached to the ends of the ropes","types":["Object"],"since":null,"text":"cargo: Object - entity attached to the ends of the ropes"}],"returns":{"type":null,"types":["Array","Object"],"description":null,"text":"Array of Objects which are transports from which the ropes originate, the ropes owners"},"form":"unary","operator":null,"left":null,"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"```sqf\nr1 = ropeCreate [car1, [0,0,0], car3, [0,0,0], 10];\nr2 = ropeCreate [car2, [0,0,0], car3, [0,0,0], 10];\nropesAttachedTo car3; // [car1,car2]\n```","code":["r1 = ropeCreate [car1, [0,0,0], car3, [0,0,0], 10];\nr2 = ropeCreate [car2, [0,0,0], car3, [0,0,0], 10];\nropesAttachedTo car3; // [car1,car2]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropeAttachedTo","ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"ropeSegments","operator":null,"title":"ropeSegments","type":"command","url":"https://community.bistudio.com/wiki/ropeSegments","revid":364777,"updated":"2024-06-10T12:28:27Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns provided rope's segments.\n\nArma 3 v2.12 use objectParent to return the rope parent from a rope segment.","syntaxes":[{"syntax":"ropeSegments rope","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"rope: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"the rope's segments","text":"Array of Objects - the rope's segments"},"form":"unary","operator":null,"left":null,"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _segments = ropeSegments _myRope;\n```","code":["private _segments = ropeSegments _myRope;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropeCreate","ropeLength","ropeCut","ropeEndPosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"ropeUnwind","operator":null,"title":"ropeUnwind","type":"command","url":"https://community.bistudio.com/wiki/ropeUnwind","revid":363666,"updated":"2024-04-14T18:49:41Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Increases or decreases the rope length by the given amount. Use relative parameter for changing rope length +/- from current length.\n\n> [!NOTE]\n> Rope length can be in range 0.5..100 metres.","syntaxes":[{"syntax":"ropeUnwind [rope, speed, length, relative]","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":"rope object","types":["Object"],"since":null,"text":"rope: Object - rope object"},{"name":"speed","type":"Number","optional":false,"default":null,"description":"animation speed in m/s with which to lengthen or shorten the rope, in range 0.01..20","types":["Number"],"since":null,"text":"speed: Number - animation speed in m/s with which to lengthen or shorten the rope, in range 0.01..20"},{"name":"length","type":"Number","optional":false,"default":null,"description":"the amount of length change in meters, in range: 0.1..100","types":["Number"],"since":null,"text":"length: Number - the amount of length change in meters, in range: 0.1..100"},{"name":"relative","type":"Boolean","optional":true,"default":null,"description":"true will add or subtract given length from current rope length, false will resize the rope to the given length","types":["Boolean"],"since":null,"text":"relative: Boolean - (Optional) true will add or subtract given length from current rope length, false will resize the rope to the given length"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[rope, speed, length, relative]","types":["Array"]}}],"examples":[{"text":"```sqf\nropeUnwind [ropes heli1 select 0, 3, 10]; // set rope length to 10m at 3m/s\n```","code":["ropeUnwind [ropes heli1 select 0, 3, 10]; // set rope length to 10m at 3m/s"]},{"text":"```sqf\nropeUnwind [ropes heli1 select 0, 3, -5, true]; // decrease rope length by 5m at 3m/s\n```","code":["ropeUnwind [ropes heli1 select 0, 3, -5, true]; // decrease rope length by 5m at 3m/s"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","setSlingLoad","slingLoadAssistantShown"],"notes":[{"user":"Tajin","date":"2014-11-08T15:28:00Z","text":"Unwinding speed is not linear but instead automatically accelerates at the beginning and slows down at the end.\n\nThe speed also only seems to have no effect when pulling the rope in. (unless the end of the rope is not attached to anything)\n\nHigh unwinding speeds (over ~250) can cause your cargo to get stuck in midair."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"ropeUnwound","operator":null,"title":"ropeUnwound","type":"command","url":"https://community.bistudio.com/wiki/ropeUnwound","revid":369179,"updated":"2024-09-03T10:34:44Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns false if rope length changing animation is in progress. Returns true if animation is done.","syntaxes":[{"syntax":"ropeUnwound rope","since":null,"effect":null,"exec":null,"params":[{"name":"rope","type":"Object","optional":false,"default":null,"description":"given rope object","types":["Object"],"since":null,"text":"rope: Object - given rope object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if unwinding is complete","text":"Boolean - true if unwinding is complete"},"form":"unary","operator":null,"left":null,"right":{"text":"rope","types":["Object"]}}],"examples":[{"text":"```sqf\nwaitUntil { ropeUnwound (ropes heli1 select 0) };\nhint \"Unwinding Complete\";\n```","code":["waitUntil { ropeUnwound (ropes heli1 select 0) };\nhint \"Unwinding Complete\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","setSlingLoad","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"rotorsForcesRTD","operator":null,"title":"rotorsForcesRTD","type":"command","url":"https://community.bistudio.com/wiki/rotorsForcesRTD","revid":377137,"updated":"2026-01-01T10:28:59Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns force produced by rotors.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"rotorsForcesRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Array of Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_rotorForces = rotorsForcesRTD _taru; // Returns [[-465.981,351.941,45960.5],[-469.079,397.451,46933.3]]\n```","code":["_rotorForces = rotorsForcesRTD _taru; // Returns [[-465.981,351.941,45960.5],[-469.079,397.451,46933.3]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rotorsRpmRTD","weightRTD","wingsForcesRTD","airDensityRTD"],"notes":[{"user":"Benargee","date":"2014-11-04T02:00:00Z","text":"There is no official information I can find on what these values mean. According to my testing on the Mi-290 Taru, here is what I have come up with:\n`[ [rotor 1 roll +right/-left, rotor 1 pitch +down/-up, rotor 1 collective +up/-down], [rotor 2 roll +right/-left, rotor 2 pitch +down/-up, rotor 2 collective +up/-down] ]`\nWhen yawing left and right, rotor 1 and 2 collective differ from each other. This is normal behaviour with coaxial rotors. Yawing right increase rotor 1 collective and decreases rotor 2 collective. Yawing left does the opposite. Rotor 1 in this example seems to be the bottom rotor."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"rotorsRpmRTD","operator":null,"title":"rotorsRpmRTD","type":"command","url":"https://community.bistudio.com/wiki/rotorsRpmRTD","revid":377136,"updated":"2026-01-01T10:28:32Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns rotors RPM. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"rotorsRpmRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_mh9_main = (rotorsRpmRTD _MH9) select 0;//main rotor\n_mh9_tail = (rotorsRpmRTD _MH9) select 1;//tail rotor\n```","code":["_mh9_main = (rotorsRpmRTD _MH9) select 0;//main rotor\n_mh9_tail = (rotorsRpmRTD _MH9) select 1;//tail rotor"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rotorsForcesRTD","weightRTD","wingsForcesRTD","airDensityRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"round","operator":null,"title":"round","type":"command","url":"https://community.bistudio.com/wiki/round","revid":319690,"updated":"2022-05-13T09:24:42Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Rounds the provided value to the closest integer.","syntaxes":[{"syntax":"round value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nround 5.25; // returns 5\n```","code":["round 5.25; // returns 5"]},{"text":"```sqf\nround -5.25; // returns -5\n```","code":["round -5.25; // returns -5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["floor","ceil","linearConversion"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"runInitScript","operator":null,"title":"runInitScript","type":"command","url":"https://community.bistudio.com/wiki/runInitScript","revid":347552,"updated":"2023-09-28T09:35:18Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Fades in mission screen and re-executes init.sqf and init.sqs scripts. In Eden Editor the code inside the \"Init\" mission attribute is executed.","syntaxes":[{"syntax":"runInitScript","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nrunInitScript;\n```","code":["runInitScript;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Event Scripts"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneH","operator":null,"title":"safeZoneH","type":"command","url":"https://community.bistudio.com/wiki/safeZoneH","revid":369130,"updated":"2024-09-03T10:34:34Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the height of the screen in screen measurement units.\nTaken from top left corner of the default viewport (0,0) of the screen and going in the same direction as the Y axis, the value will be positive but resulting Y will end up beyond the bottom border.\nTherefore in order to calculate Y of the bottom screen border, the length of safeZoneY must be subtracted from safeZoneH, but because it is negative, it must be added instead.\n`_screenBottomBorderY = safeZoneH + safeZoneY`. The measurement units depend on the current screen resolution getResolution. See also SafeZone.","syntaxes":[{"syntax":"safeZoneH","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"height of the screen in screen measurement units","text":"Number - height of the screen in screen measurement units"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_screenHeight = safeZoneH;\n```","code":["_screenHeight = safeZoneH;"]},{"text":"```sqf\n_screenTopBorderY = safeZoneY;\n_screenBottomBorderY = safeZoneH + safeZoneY;\n```","code":["_screenTopBorderY = safeZoneY;\n_screenBottomBorderY = safeZoneH + safeZoneY;"]},{"text":"Create control 50% wide, 30% tall, centered on screen:\n\n```sqf\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;\n```","code":["private _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","safeZoneX","safeZoneY","safeZoneW","safeZoneXAbs","safeZoneWAbs"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneW","operator":null,"title":"safeZoneW","type":"command","url":"https://community.bistudio.com/wiki/safeZoneW","revid":349848,"updated":"2023-11-20T22:10:41Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the width of the screen in screen measurement units.\nTaken from top left corner of the default viewport (0,0) of the screen and going in the same direction as the X axis, the value will be positive but resulting X will end up beyond the right border.\nTherefore in order to calculate X of the right screen border, the length of safeZoneX must be subtracted from safeZoneW, but because it is negative, it must be added instead.\n`_screenRightBorderX = safeZoneW + safeZoneX`. The measurement units depend on the current screen resolution getResolution. See also SafeZone.","syntaxes":[{"syntax":"safeZoneW","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"screen width in screen measurement units","text":"Number - screen width in screen measurement units"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_screenWidth = safeZoneW;\n```","code":["_screenWidth = safeZoneW;"]},{"text":"```sqf\n_screenLeftBorderX = safeZoneX;\n_screenRightBorderX = safeZoneW + safeZoneX;\n```","code":["_screenLeftBorderX = safeZoneX;\n_screenRightBorderX = safeZoneW + safeZoneX;"]},{"text":"Create control 50% wide, 30% tall, centered on screen:\n\n```sqf\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;\n```","code":["private _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","safeZoneX","safeZoneY","safeZoneH","safeZoneXAbs","safeZoneWAbs"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneWAbs","operator":null,"title":"safeZoneWAbs","type":"command","url":"https://community.bistudio.com/wiki/safeZoneWAbs","revid":349758,"updated":"2023-11-20T22:10:03Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.03"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.03"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns absolute safeZoneW including all monitors.","syntaxes":[{"syntax":"safeZoneWAbs","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"screen width including multiple monitors in screen measurement units","text":"Number - screen width including multiple monitors in screen measurement units"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_szW = safeZoneWAbs;\n```","code":["_szW = safeZoneWAbs;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["safeZoneXAbs","SafeZone","safeZoneH","safeZoneX","safeZoneY","safeZoneW"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.03","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneX","operator":null,"title":"safeZoneX","type":"command","url":"https://community.bistudio.com/wiki/safeZoneX","revid":349941,"updated":"2023-11-20T22:11:22Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the X of the left border of the screen, which is also a distance in screen measurement units from top left corner of the default viewport (0,0) of the screen to the left border of the screen.\nSince it is going in opposite way of the X axis, the value is negative. The measurement units depend on the current screen resolution getResolution. See also SafeZone.","syntaxes":[{"syntax":"safeZoneX","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_screenLeftBorderX = safeZoneX; // returns a float value < 0\n```","code":["_screenLeftBorderX = safeZoneX; // returns a float value < 0"]},{"text":"Create control 50% wide, 30% tall, centered on screen:\n\n```sqf\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;\n```","code":["private _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","safeZoneY","safeZoneW","safeZoneH","safeZoneXAbs","safeZoneWAbs"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneXAbs","operator":null,"title":"safeZoneXAbs","type":"command","url":"https://community.bistudio.com/wiki/safeZoneXAbs","revid":349882,"updated":"2023-11-20T22:10:54Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.03"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.03"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns absolute safeZoneX including all monitors.","syntaxes":[{"syntax":"safeZoneXAbs","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_szX = safeZoneXAbs;\n```","code":["_szX = safeZoneXAbs;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["safeZoneWAbs","SafeZone","safeZoneH","safeZoneX","safeZoneY","safeZoneW"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.03","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"safeZoneY","operator":null,"title":"safeZoneY","type":"command","url":"https://community.bistudio.com/wiki/safeZoneY","revid":350006,"updated":"2023-11-20T22:11:49Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the Y of the top border of the screen, which is also a distance in screen measurement units from top left corner of the default viewport (0,0) of the screen to the top border of the screen.\nSince it is going in opposite way of the Y axis, the value is negative. The measurement units depend on the current screen resolution getResolution. See also SafeZone.","syntaxes":[{"syntax":"safeZoneY","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_screenTopBorderY = safeZoneY; // returns a float value < 0\n```","code":["_screenTopBorderY = safeZoneY; // returns a float value < 0"]},{"text":"Create control 50% wide, 30% tall, centered on screen:\n\n```sqf\nprivate _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;\n```","code":["private _ctrl = findDisplay 46 createDisplay \"RscDisplayEmpty\" ctrlCreate [\"RscText\", -1];\n_ctrl ctrlSetBackgroundColor [1,0,0,0.5];\nprivate _ctrlWidth = 0.5 * safeZoneW; // 50% of screen width\nprivate _ctrlHeight = 0.3 * safeZoneH; // 30% of screen height\n_ctrl ctrlSetPositionW _ctrlWidth;\n_ctrl ctrlSetPositionH _ctrlHeight;\n_ctrl ctrlSetPositionX ((safeZoneW - _ctrlWidth) / 2 + safeZoneX); // center it horizontally\n_ctrl ctrlSetPositionY ((safeZoneH - _ctrlHeight) / 2 + safeZoneY); // center it vertically\n_ctrl ctrlCommit 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","safeZoneX","safeZoneW","safeZoneH","safeZoneXAbs","safeZoneWAbs"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"save3DENInventory","operator":null,"title":"save3DENInventory","type":"command","url":"https://community.bistudio.com/wiki/save3DENInventory","revid":330340,"updated":"2022-08-31T21:24:40Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves the current state of entities' inventory to the Mission.sqm.","syntaxes":[{"syntax":"save3DENInventory entities","since":null,"effect":null,"exec":null,"params":[{"name":"entities","type":"Array of Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Array","Eden Entity","Eden ID"],"since":null,"text":"entities: Array of Eden Entity or Eden ID"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"entities","types":["Array","Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\nsave3DENInventory [_soldier1, _soldier2];\n```","code":["save3DENInventory [_soldier1, _soldier2];"]},{"text":"```sqf\nsave3DENInventory [11234, 21251];\n```","code":["save3DENInventory [11234, 21251];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clear3DENInventory","get3DENEntityID","collect3DENHistory"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"save3DENPreferences","operator":null,"title":"save3DENPreferences","type":"command","url":"https://community.bistudio.com/wiki/save3DENPreferences","revid":369740,"updated":"2024-10-08T15:05:37Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves current 3DEN preferences into .3den.Arma3Profile file.","syntaxes":[{"syntax":"save3DENPreferences","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n\"Preferences\" set3DENMissionAttribute [\"SaveBinarized\", true];\nsave3DENPreferences;\n```","code":["\"Preferences\" set3DENMissionAttribute [\"SaveBinarized\", true];\nsave3DENPreferences;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveProfileNamespace","saveMissionProfileNamespace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"saveGame","operator":null,"title":"saveGame","type":"command","url":"https://community.bistudio.com/wiki/saveGame","revid":311106,"updated":"2022-05-10T14:30:26Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Autosaves the game (used for Retry). The saving is not started immediately, the request for autosave is made instead. To check the status of the request, use isSaving. The game can then be loaded from the last autosave with loadGame. Will not save if the player is null or dead.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.88 a `\"OnSaveGame\"` scripted event handler is available.","syntaxes":[{"syntax":"saveGame","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsaveGame;\n```","code":["saveGame;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isSaving","enableSaving","loadGame","savingEnabled"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"saveIdentity","operator":null,"title":"saveIdentity","type":"command","url":"https://community.bistudio.com/wiki/saveIdentity","revid":340915,"updated":"2023-05-13T21:59:50Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves units's identity to Objects.sav file in campaign directory as entry name.","syntaxes":[{"syntax":"unit saveIdentity name","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successful, otherwise false","text":"Boolean - true if successful, otherwise false"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_successful = player saveIdentity \"playerid\";\n```","code":["_successful = player saveIdentity \"playerid\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadIdentity"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"saveJoysticks","operator":null,"title":"saveJoysticks","type":"command","url":"https://community.bistudio.com/wiki/saveJoysticks","revid":319552,"updated":"2022-05-13T09:24:28Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves joysticks key mappings into the joysticks.cfg file. Engine add these joysticks to the Joystick Scheme mapping dialog in options controls section.","syntaxes":[{"syntax":"saveJoysticks","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsaveJoysticks;\n```","code":["saveJoysticks;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveProfileNamespace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"saveMissionProfileNamespace","operator":null,"title":"saveMissionProfileNamespace","type":"command","url":"https://community.bistudio.com/wiki/saveMissionProfileNamespace","revid":353417,"updated":"2024-03-18T11:29:33Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"missionProfileNamespace provides long-term storage solution for mission variables.\nWhen this namespace has variables set with setVariable and is saved, the variables are saved into `*missionName*.vars` file into the current player's profileName folder.\nNext time when the same mission is loaded by the client with the same player profile, the saved variables can be read normally with getVariable command.\nThis way each mission maker can create persistent data that is both mission and player profile specific. The file is only created when the save operation is invoked with this command.\n\nIt is also possible to share the same mission profile variables between several missions.\nTo override the default behaviour, create a `missionGroup` entry in Description.ext, for example `missionGroup = \"TAG_MyMissionCollectionName\";`.\nThis will create `TAG_MyMissionCollectionName.vars` file instead of the default-named one, which would be loaded into every mission with a matching `missionGroup` entry.","syntaxes":[{"syntax":"saveMissionProfileNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true in case of success, false otherwise (e.g trying to save in Eden Editor or trying to save into existing save file but the file wasn't loaded yet)","text":"Boolean - true in case of success, false otherwise (e.g trying to save in Eden Editor or trying to save into existing save file but the file wasn't loaded yet)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsaveMissionProfileNamespace;\n```","code":["saveMissionProfileNamespace;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionProfileNamespace","isMissionProfileNamespaceLoaded","saveProfileNamespace","save3DENPreferences"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"saveOverlay","operator":null,"title":"saveOverlay","type":"command","url":"https://community.bistudio.com/wiki/saveOverlay","revid":363296,"updated":"2024-03-26T10:52:01Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Save the current overlay.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"saveOverlay map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\nsaveOverlay _map;\n```","code":["saveOverlay _map;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"saveProfileNamespace","operator":null,"title":"saveProfileNamespace","type":"command","url":"https://community.bistudio.com/wiki/saveProfileNamespace","revid":369335,"updated":"2024-09-03T18:43:00Z","groups":["Namespaces","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves all variables stored in profileNamespace to the active Profile.\n\n> [!NOTE]\n> This command should be used when it is likely that the game will not be closed the usual way (e.g. via <kbd>Alt</kbd>+<kbd>F4</kbd>) or when the data is important and must not be lost due to a game crash.\n\n> [!WARNING]\n> - This command triggers a file operation. As file operations are slow (even on SSDs), it is not recommended to use this command too frequently (i.e. several times per second).\n> - Do not save large amounts of data to the profile; the larger the profile file gets, the slower it loads!\n> - The profileNamespace is saved automatically when the game is closed.\n\n> [!NOTE]\n> **Take On Helicopters:** Heliport status, used in the Career mode for example, is stored in the file that is modified by this command, so be mindful of this to avoid losing data and progress.","syntaxes":[{"syntax":"saveProfileNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprofileNamespace setVariable [\"TAG_lastPlayerLocation\", getPosASL player];\nsaveProfileNamespace; // Optional since namespace is saved when game is closed\n```","code":["profileNamespace setVariable [\"TAG_lastPlayerLocation\", getPosASL player];\nsaveProfileNamespace; // Optional since namespace is saved when game is closed"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["saveMissionProfileNamespace","save3DENPreferences","profileNamespace","Profile"],"notes":[],"categories":["Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Variables","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"saveStatus","operator":null,"title":"saveStatus","type":"command","url":"https://community.bistudio.com/wiki/saveStatus","revid":337534,"updated":"2023-02-06T23:57:52Z","groups":["Weapon Pool","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Saves object's properties to Objects.sav file in campaign directory as entry name.","syntaxes":[{"syntax":"object saveStatus name","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successful, otherwise false","text":"Boolean - true if successful, otherwise false"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nplayer saveStatus \"playerstate\";\n```","code":["player saveStatus \"playerstate\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["loadStatus","saveVar"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Weapon Pool","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"saveVar","operator":null,"title":"saveVar","type":"command","url":"https://community.bistudio.com/wiki/saveVar","revid":340971,"updated":"2023-05-13T22:02:54Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Save variable value into the campaign space.\nThis variable is available to all following missions in the campaign.","syntaxes":[{"syntax":"saveVar varname","since":null,"effect":null,"exec":null,"params":[{"name":"varname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"varname: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"varname","types":["String"]}}],"examples":[{"text":"```sqf\nsaveVar \"varOne\";\n```","code":["saveVar \"varOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isNil","missionNamespace","saveStatus"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"savingEnabled","operator":null,"title":"savingEnabled","type":"command","url":"https://community.bistudio.com/wiki/savingEnabled","revid":342154,"updated":"2023-07-09T12:26:50Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if saving the game is enabled.\n\n> [!NOTE]\n> **Arma 3:** If saving is disabled by Eden Editor mission attribute, this command will still return true.","syntaxes":[{"syntax":"savingEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (savingEnabled) then\n{\n    hint \"Saving is enabled!\";\n};\n```","code":["if (savingEnabled) then\n{\n\thint \"Saving is enabled!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableSaving","loadGame","saveGame","isSaving"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"say","operator":null,"title":"say","type":"command","url":"https://community.bistudio.com/wiki/say","revid":338267,"updated":"2023-02-25T14:17:50Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Make unit say given sound. The sound is defined in CfgSounds.\nIf the unit is a person, it will also perform the corresponding lipsync effect provided an appropriate .lip file has been created for this sound.\n\n- A dead or non-existent unit obviously cannot say anything.\n- If the camera is not within given range, title is not shown and the sound will not be heard.\n- See also playSound in order to play a sound wherever the camera/player is.\n\n> [!NOTE]\n> say will mimic either say2D or say3D depending on whether it is executed in a cutscene or in a game scene.","syntaxes":[{"syntax":"from say sound","since":null,"effect":null,"exec":null,"params":[{"name":"from","type":"Object or Array of Objects","optional":false,"default":null,"description":"Object or Array of Objects\n- Object - the sound source\n- Array - format [from, to]:\n  - from: Object - sound source\n  - to: Object - target","types":["Object","Array"],"since":null,"text":"from: Object or Array of Objects\n- Object - the sound source\n- Array - format [from, to]:\n  - from: Object - sound source\n  - to: Object - target"},{"name":"sound","type":"String or Array","optional":true,"default":"100","description":"String or Array\n- String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n- Array - format [sound, maxTitlesDistance, speed]:\n  - sound: String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxTitlesDistance: Number  - max. distance in meters at which the sound can be heard\n  - speed: Number (Optional, default 1) - pitch of the sound","types":["String","Array"],"since":null,"text":"sound: String or Array\n- String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n- Array - format [sound, maxTitlesDistance, speed]:\n  - sound: String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxTitlesDistance: Number (Optional, default 100) - max. distance in meters at which the sound can be heard\n  - speed: Number (Optional, default 1) - pitch of the sound"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"from","types":["Object","Array"]},"right":{"text":"sound","types":["String","Array"]}}],"examples":[{"text":"```sqf\n(units player select 1) say [\"whisper1\", 5];\n```","code":["(units player select 1) say [\"whisper1\", 5];"]},{"text":"```sqf\nplayer say \"scuba_breath\"; // Arma 3 vanilla sound\n```","code":["player say \"scuba_breath\"; // Arma 3 vanilla sound"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["say3D","say2D","playSound","createSoundSource","playSoundUI"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"say2D","operator":null,"title":"say2D","type":"command","url":"https://community.bistudio.com/wiki/say2D","revid":364817,"updated":"2024-06-16T09:10:27Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Plays given sound in 2D.","syntaxes":[{"syntax":"from say2D sound","since":null,"effect":null,"exec":null,"params":[{"name":"from","type":"One of","optional":false,"default":null,"description":"One of\n- Object - the sound source\n- Array with [from, to]\n  - from: Object - sound source\n  - to: Object - target","types":[],"since":null,"text":"from: One of\n- Object - the sound source\n- Array with [from, to]\n  - from: Object - sound source\n  - to: Object - target"},{"name":"sound","type":"One of","optional":true,"default":"100","description":"One of\n- String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n- Array with [sound, maxTitlesDistance, speed]\n  - sound: String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxTitlesDistance: Number  - max. distance in meters at which the sound can be heard\n  - speed: Number (Optional, default 1) - pitch of the sound","types":[],"since":null,"text":"sound: One of\n- String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n- Array with [sound, maxTitlesDistance, speed]\n  - sound: String - class name of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxTitlesDistance: Number (Optional, default 100) - max. distance in meters at which the sound can be heard\n  - speed: Number (Optional, default 1) - pitch of the sound"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"from","types":[]},"right":{"text":"sound","types":[]}}],"examples":[{"text":"```sqf\nplayer say2D \"HelloThere\";\n```","code":["player say2D \"HelloThere\";"]},{"text":"```sqf\n[player, _officer] say2D [\"HelloThere\", 50, 0.9];\n```","code":["[player, _officer] say2D [\"HelloThere\", 50, 0.9];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["say","say3D","playSound","createSoundSource","playSoundUI"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"say3D","operator":null,"title":"say3D","type":"command","url":"https://community.bistudio.com/wiki/say3D","revid":379095,"updated":"2026-09-27T21:30:33Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Lets an object say given sound in 3D space.\nThis allows broadcasting of positional music or sound from a source, without having to script a fade sound or music command. The source has to be alive.\nCompare this with say2D which will always play a sound at the location of the player after he has been in the vicinity of a broadcasting sound.\nSound is defined in \"CfgSounds\" of the Description.ext or main config.\n\n> [!NOTE]\n> The name of the command is the clue to its usage. It is meant for playing short sounds within short range. Consecutive execution of the command queues the sounds, the next sound would not start until the previous sound is finished, hence the need for the short sounds. The simulation of speed of sound would delay next sound and might mess with the timing of the queued sounds, especially if used globally. Additionally the sounds are not synced for JIP players. A long playing sound will not be heard by newly joined payers. To summarise:\n>\n> - An object can only \"say\" **one** sound at a time\n> - In order to stop a say3D sound: delete the returned **sound source** with deleteVehicle, or kill the **sound source** with e.g setDamage.\n> - Forcing the speed of sound simulation may delay the queued sound to play right after the previous sound, even if the second sound does not simulate sound delay (e.g sound 1 plays with a 5s delay, ends, *then* sound 2 plays). If the queued sound uses speed of sound simulation, it will be delayed from the end of the first sound (they will not follow \"as expected\"). Makes the *offset* parameter ignored.\n> - **Do use** it for short distance short sounds with speed of sound simulation off.\n> - When used with 'isGlobal' option, a null NetObject is returned. To stop such sound globally, destroy the sound source 'from' object.","syntaxes":[{"syntax":"from say3D sound","since":null,"effect":null,"exec":null,"params":[{"name":"from","type":"Object or Array of Objects","optional":true,"default":"objNull","description":"Object or Array of Objects\n- Object - origin of the sound\n- Array with [from, to]\n  - from: Object - origin of the sound\n  - to: Object -  target","types":["Object","Array"],"since":null,"text":"from: Object or Array of Objects\n- Object - origin of the sound\n- Array with [from, to]\n  - from: Object - origin of the sound\n  - to: Object - (Optional, default objNull) target"},{"name":"sound","type":"String or Array","optional":true,"default":"100","description":"String or Array\n- String - classname of the sound to be played. Defined in CfgSounds including Description.ext\n- Array with [sound, maxDistance, pitchCoef, isSpeech, offset, simulateSpeedOfSound, playMode, isGlobal]\n  - sound: String - classname of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxDistance: Number -  maximum distance in meters at which the sound can be heard. -1 to use the maxDistance from the sound config\n  - pitchCoef: Number - (Optional, default 1) **multiplier** to the CfgSounds defined pitch. The final audio pitch is clipped between 0.5 and 2.0\n  - Arma 3 v1.92 isSpeech: Boolean or Arma 3 v2.04 Number - (Optional, default false)\n    - 0/false = play as sound (fadeSound applies)\n    - 1/true = play as speech (fadeSpeech applies), filters are not applied to it (i.e. house or vehicle interior one)\n    - 2 = play as sound (fadeSound applies) without interior/vehicle muffling\n  - Arma 3 v2.00 offset: Number - (Optional, default 0) offset in seconds; ignored when *simulateSpeedOfSound* is used\n  - Arma 3 v2.18 simulateSpeedOfSound: Boolean - (Optional, default false) true to simulate speed of sound (see description note)\n  - Arma 3 v2.24 isInside: Boolean - (Optional, default false) true if the sound is well audible inside the source (only for 'isSpeech' 0/false)\n  - Arma 3 v2.24 playMode: Number - (Optional, default 0) Could be one of the following:\n    - 0 - queued sound playback. The same source plays queued sounds in sequence\n    - 1 - single sound playback. The queue is cleared and a single sound is played instantly\n    - 2 - multiple sounds playback. The same source can play multiple sounds simultaneously and instantly\n  - Arma 3 v2.24 isGlobal: Boolean - (Optional, default false) true to play the sound on every client currently in game","types":["String","Array"],"since":null,"text":"sound: String or Array\n- String - classname of the sound to be played. Defined in CfgSounds including Description.ext\n- Array with [sound, maxDistance, pitchCoef, isSpeech, offset, simulateSpeedOfSound, playMode, isGlobal]\n  - sound: String - classname of the sound to be played. Defined in CfgSounds including Description.ext\n  - maxDistance: Number - (Optional, default 100) maximum distance in meters at which the sound can be heard. -1 to use the maxDistance from the sound config\n  - pitchCoef: Number - (Optional, default 1) **multiplier** to the CfgSounds defined pitch. The final audio pitch is clipped between 0.5 and 2.0\n  - Arma 3 v1.92 isSpeech: Boolean or Arma 3 v2.04 Number - (Optional, default false)\n    - 0/false = play as sound (fadeSound applies)\n    - 1/true = play as speech (fadeSpeech applies), filters are not applied to it (i.e. house or vehicle interior one)\n    - 2 = play as sound (fadeSound applies) without interior/vehicle muffling\n  - Arma 3 v2.00 offset: Number - (Optional, default 0) offset in seconds; ignored when *simulateSpeedOfSound* is used\n  - Arma 3 v2.18 simulateSpeedOfSound: Boolean - (Optional, default false) true to simulate speed of sound (see description note)\n  - Arma 3 v2.24 isInside: Boolean - (Optional, default false) true if the sound is well audible inside the source (only for 'isSpeech' 0/false)\n  - Arma 3 v2.24 playMode: Number - (Optional, default 0) Could be one of the following:\n    - 0 - queued sound playback. The same source plays queued sounds in sequence\n    - 1 - single sound playback. The queue is cleared and a single sound is played instantly\n    - 2 - multiple sounds playback. The same source can play multiple sounds simultaneously and instantly\n  - Arma 3 v2.24 isGlobal: Boolean - (Optional, default false) true to play the sound on every client currently in game"}],"returns":{"type":"Object","types":["Object"],"description":"the sound source or NetObject - when 'isGlobal' is true","text":"Object - the sound source or NetObject - when 'isGlobal' is true"},"form":"binary","operator":null,"left":{"text":"from","types":["Object","Array"]},"right":{"text":"sound","types":["String","Array"]}}],"examples":[{"text":"All possible combinations:\n\n```sqf\nhelicopter1 say3D \"FortunateSon\";\nhelicopter1 say3D [\"FortunateSon\", 500, 1, 0, 0, true];\n[helicopter1, player] say3D \"FortunateSon\";\n[helicopter1, player] say3D [\"FortunateSon\", 500, 1, 0, 0, true];\n```","code":["helicopter1 say3D \"FortunateSon\";\nhelicopter1 say3D [\"FortunateSon\", 500, 1, 0, 0, true];\n[helicopter1, player] say3D \"FortunateSon\";\n[helicopter1, player] say3D [\"FortunateSon\", 500, 1, 0, 0, true];"]},{"text":"Workaround for dead bodies:\n\n```sqf\nprivate _dummy = \"#particlesource\" createVehicleLocal ASLToAGL getPosWorld _corpse;\n_dummy say3D \"whatever\";\n_dummy spawn {\n    sleep 5; // at least the length of your sound\n    deleteVehicle _this;\n};\n```","code":["private _dummy = \"#particlesource\" createVehicleLocal ASLToAGL getPosWorld _corpse;\n_dummy say3D \"whatever\";\n_dummy spawn {\n\tsleep 5; // at least the length of your sound\n\tdeleteVehicle _this;\n};"]},{"text":"```sqf\n// Since Arma 3 v2.00, the sound source is returned and can be deleted directly\n_soundSrc = helicopter1 say3D \"Fortunateson\";\nsleep 5;\ndeleteVehicle _soundSrc; // stop the sound after ~5 seconds\n```","code":["// Since Arma 3 v2.00, the sound source is returned and can be deleted directly\n_soundSrc = helicopter1 say3D \"Fortunateson\";\nsleep 5;\ndeleteVehicle _soundSrc; // stop the sound after ~5 seconds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["say","say2D","playSound","playSound3D","createSoundSource","playSoundUI","setRandomLip","stopSound","soundParams"],"notes":[{"user":"Rocket","date":"2013-03-07T13:17:00Z","text":"The only difference with this command and say is during cutscenes (when some camera effect is active). In cutscenes, say3D is 3D, say is not."},{"user":"Benargee","date":"2015-06-19T21:26:00Z","text":"In Arma 2 1.63, the object this command is assigned to must be alive for the sound to broadcast. If the object is killed while the sound is still playing, the sound will stop immediately.\n\nHere is [a link to the forum](http://forums.bistudio.com/showthread.php?146122-Making-a-dead-soldier-play-a-sound-in-3d) to get around this issue.\n\nI have not tested this in Arma 3 yet."},{"user":"Killzone_Kid","date":"2017-03-11T14:43:00Z","text":"This command creates sound object \"#soundonvehicle\" which can be detected with allMissionObjects\n\n```sqf\nonEachFrame { hintSilent str allMissionObjects \"#soundonvehicle\" };\n0 spawn { sleep 1; player say3D \"Alarm\" };\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"scopeName","operator":null,"title":"scopeName","type":"command","url":"https://community.bistudio.com/wiki/scopeName","revid":363355,"updated":"2024-03-27T12:05:28Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines name of current scope. Name is visible in debugger, and name is also used as reference in some commands like breakOut and breakTo.\nScope name should be defined only once per scope. Trying to set a different name on the scope that has already defined scope name will result in error.","syntaxes":[{"syntax":"scopeName name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nscopeName \"main\";\nwhile { sleep 0.1; true } do\n{\n    scopeName \"loop1\";\n\n    while { sleep 0.1; true } do\n    {\n        scopeName \"loop2\";\n\n        // ...\n    };\n};\n```","code":["scopeName \"main\";\nwhile { sleep 0.1; true } do\n{\n\tscopeName \"loop1\";\n\n\twhile { sleep 0.1; true } do\n\t{\n\t\tscopeName \"loop2\";\n\n\t\t// ...\n\t};\n};"]},{"text":"```sqf\nif (true) then\n{\n    scopeName \"mainScope\";\n    scopeName \"main_scope\"; // error\n};\n```","code":["if (true) then\n{\n\tscopeName \"mainScope\";\n\tscopeName \"main_scope\"; // error\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["breakOut","breakTo"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"score","operator":null,"title":"score","type":"command","url":"https://community.bistudio.com/wiki/score","revid":352995,"updated":"2024-03-09T10:17:34Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the person's score in MP.","syntaxes":[{"syntax":"score unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_pScore = score player;\n```","code":["_pScore = score player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addScore","scoreSide","addScoreSide","getPlayerScores"],"notes":[{"user":"Aimgame","date":"2024-03-09T10:17:34Z","text":"In MP **score player** returns only the score of player in faction he joined first (within one server session).\n\nI.e. if he first logged for WEST faction and then relogged for another faction, **score player** will show his score when he was WEST, no matter what real score is in current faction.\n\nIn this regard it is better to use getPlayerScores:\n\n```sqf\n(getPlayerScores player) select (count (getPlayerScores player) - 1)\n```\n\nor\n\n```sqf\n(getPlayerScores player) select 5\n```\n\n- it will always return the player's actual score in the current faction."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"scoreSide","operator":null,"title":"scoreSide","type":"command","url":"https://community.bistudio.com/wiki/scoreSide","revid":321011,"updated":"2022-05-13T11:05:55Z","groups":["Multiplayer","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns score for the given side. MP Only.","syntaxes":[{"syntax":"scoreSide side","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n_number = scoreSide west;\n```","code":["_number = scoreSide west;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["score","addScore","addScoreSide","getPlayerScores"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Sides","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"screenshot","operator":null,"title":"screenshot","type":"command","url":"https://community.bistudio.com/wiki/screenshot","revid":373186,"updated":"2025-04-11T09:26:12Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"| Post-Process Effect | Active in<br>screenshot |\n|---|---|\n| ColorInversion | ✗ |\n| FilmGrain | ✗ |\n| ColorCorrections | ✗ |\n| DynamicBlur | ✓ |\n| WetDistortion | ✓ |\n| ChromaticAberration | ✓ |\n| RadialBlur | ✓ |\n| SSAO |  |\n| Resolution | ✓ |\n\nTakes a screenshot of the 3D scene and saves it to the provided filename.\n- Only the 3D scene is captured, no GUI/cursor\n- Sampling is taken in consideration: a 200% sampling value on a 1920x1080 resolution takes a 3840x2160 screenshot\n- PNG is the only available format\n\nThe file is saved in the *Screenshots* folder in the Profile directory. The folder is by default limited to **250 MB** to prevent abuse.\n\nTo increase the limit, add the following line at the end of the profile file:\n\n```cpp\nmaxScreenShotFolderSizeMB = 2000; // 2 GB\n```","syntaxes":[{"syntax":"screenshot filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":"**must** have `.png` extension; desired path and name relative to `<PROFILEDIR>\\Screenshots\\` (see Profile).\n\nIf empty string `\"\"` used, the filename will be autogenerated in format: `YYYY_MM_DD_hh_mm_ss.png`","types":["String"],"since":null,"text":"filename: String - **must** have `.png` extension; desired path and name relative to `<PROFILEDIR>\\Screenshots\\` (see Profile).\n\nIf empty string `\"\"` used, the filename will be autogenerated in format: `YYYY_MM_DD_hh_mm_ss.png`"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if success","text":"Boolean - true if success"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\nscreenshot \"\";\n```","code":["screenshot \"\";"]},{"text":"```sqf\nscreenshot \"testFile.png\";\n```","code":["screenshot \"testFile.png\";"]},{"text":"The following code will result in the screenshot being placed in `\\Documents\\Arma 3\\Screenshots\\**any\\where\\you\\want.png**`:\n\n```sqf\nscreenshot \"any\\where\\you\\want.png\";\n```","code":["screenshot \"any\\where\\you\\want.png\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_exportEditorPreviews","Eden Editor: Configuring Asset Previews"],"notes":[{"user":"Komachi","date":"2018-03-20T15:29:00Z","text":"The command will silently fail if your profiles folder is configured to be somewhere else (`-profiles` parameter), or if your HDR setting is below 16 (configurable in arma3.cfg or medium and above in in-game settings)\n\nFor full reference on recommended settings consult Eden Editor: Configuring Asset Previews."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"screenToWorld","operator":null,"title":"screenToWorld","type":"command","url":"https://community.bistudio.com/wiki/screenToWorld","revid":377892,"updated":"2026-01-05T17:38:23Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the position on landscape (PositionAGL) corresponding to the given point on screen (in UI coordinates).\n\n> [!NOTE]\n> This command performs an intersection with the ground/water surface, from the camera position along the screenToWorldDirection vector up to `viewDistance` for terrain intersection and `2 * viewDistance` for water intersection. In other words, it is similar to doing:\n>\n> ```sqf\n> private _p1 = AGLToASL positionCameraToWorld [0, 0, 0];                    // camera position ASL\n> private _vector = screenToWorldDirection _screenPos;                    // \"aim\" vector\n> private _p2 = _p1 vectorAdd (_vector vectorMultiply viewDistance * 2);    // the ray does not go beyond 2 * view distance\n> ASLToAGL terrainIntersectAtASL [_p1, _p2]\n> ```","syntaxes":[{"syntax":"screenToWorld screen","since":null,"effect":null,"exec":null,"params":[{"name":"screen","type":"Array with [x, y]","optional":false,"default":null,"description":"screen position, see SafeZone for more information\n- x: Number\n- y: Number","types":["Array"],"since":null,"text":"screen: Array with [x, y] - screen position, see SafeZone for more information\n- x: Number\n- y: Number"}],"returns":{"type":"PositionAGL, world position on surface [x, y, 0]","types":["PositionAGL"],"description":null,"text":"PositionAGL, world position on surface [x, y, 0]"},"form":"unary","operator":null,"left":null,"right":{"text":"screen","types":["Array"]}},{"syntax":"camera screenToWorld position","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"camera object","types":["Object"],"since":null,"text":"camera: Object - camera object"},{"name":"screen","type":"Array with [x, y]","optional":false,"default":null,"description":"screen position, see SafeZone for more information\n- x: Number\n- y: Number","types":["Array"],"since":null,"text":"screen: Array with [x, y] - screen position, see SafeZone for more information\n- x: Number\n- y: Number"}],"returns":{"type":"PositionAGL, world position on surface [x,y,0]","types":["PositionAGL"],"description":null,"text":"PositionAGL, world position on surface [x,y,0]"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":[]}}],"examples":[{"text":"```sqf\nprivate _wPos = screenToWorld [0.5, 0.5];\n```","code":["private _wPos = screenToWorld [0.5, 0.5];"]},{"text":"```sqf\nprivate _wPos = _myCamera screenToWorld [0.5, 0.5]; // since Arma 3 2.18\n```","code":["private _wPos = _myCamera screenToWorld [0.5, 0.5]; // since Arma 3 2.18"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","worldToScreen","screenToWorldDirection"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"screenToWorldDirection","operator":null,"title":"screenToWorldDirection","type":"command","url":"https://community.bistudio.com/wiki/screenToWorldDirection","revid":378361,"updated":"2026-04-03T16:05:32Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the 3D vector in world corresponding to the given point on the screen (in UI coordinates), as if the vector was aiming from the camera to the screen position.","syntaxes":[{"syntax":"screenToWorldDirection screen","since":null,"effect":null,"exec":null,"params":[{"name":"screen","type":"Array","optional":false,"default":null,"description":"screen position [x,y] (see SafeZone for more info)","types":["Array"],"since":null,"text":"screen: Array - screen position [x,y] (see SafeZone for more info)"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"world vector","text":"Vector3D - world vector"},"form":"unary","operator":null,"left":null,"right":{"text":"screen","types":["Array"]}},{"syntax":"camera screenToWorldDirection position","since":null,"effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"camera object","types":["Object"],"since":null,"text":"camera: Object - camera object"},{"name":"position","type":"Array","optional":false,"default":null,"description":"screen position [x,y] (see SafeZone for more info)","types":["Array"],"since":null,"text":"position: Array - screen position [x,y] (see SafeZone for more info)"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"world vector","text":"Vector3D - world vector"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _vec = screenToWorldDirection [0.5, 0.5]; // a vector pointing to the front of the camera\n```","code":["private _vec = screenToWorldDirection [0.5, 0.5]; // a vector pointing to the front of the camera"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["SafeZone","worldToScreen","screenToWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"scriptDone","operator":null,"title":"scriptDone","type":"command","url":"https://community.bistudio.com/wiki/scriptDone","revid":321342,"updated":"2022-05-13T19:10:40Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if a script is finished running using the Script Handle returned by execVM or spawn.","syntaxes":[{"syntax":"scriptDone handle","since":null,"effect":null,"exec":null,"params":[{"name":"handle","type":"Script Handle","optional":false,"default":null,"description":"handle returned by spawn or execVM","types":["Script Handle"],"since":null,"text":"handle: Script Handle - handle returned by spawn or execVM"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"handle","types":["Script Handle"]}}],"examples":[{"text":"```sqf\n_scriptHandle = [\"arguments\"] execVM \"scriptname.sqf\";\nwaitUntil { scriptDone _scriptHandle };\n```","code":["_scriptHandle = [\"arguments\"] execVM \"scriptname.sqf\";\nwaitUntil { scriptDone _scriptHandle };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["execVM","spawn","terminate","scriptNull"],"notes":[{"user":"Bn880","date":"2009-09-11T03:54:00Z","text":"A Null Script handle can be created in this manner:\n\n```sqf\n_handle = 0 spawn {};\n```\n\nThat is what any Script Handle becomes when a script is finished running, meaning it will test as true with:\n\n```sqf\nscriptDone _handle;\n```\n\nand it returns \"<NULL-script>\" when converted to string.\nThis in turn lets you initialize the variable with a completed Script Handle and lets you test the variable even though nothing else may have set the handle by creating a script with spawn or execVM.\nIt also lets you store and manage script handles in arrays, and a few other sexy things."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"scriptName","operator":null,"title":"scriptName","type":"command","url":"https://community.bistudio.com/wiki/scriptName","revid":369379,"updated":"2024-09-03T18:43:13Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assign a user friendly name to the VM script this command is executed from.\n\n> [!IMPORTANT]\n> Once a name is assigned, it cannot be changed.","syntaxes":[{"syntax":"scriptName name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nscriptName \"leetScript.sqf\";\n```","code":["scriptName \"leetScript.sqf\";"]},{"text":"```sqf\nscriptName format [\"%1ARTY\\data\\scripts\\ARTY_sadarmDeploy.sqf (_this: %1)\", _this];\n```","code":["scriptName format [\"%1ARTY\\data\\scripts\\ARTY_sadarmDeploy.sqf (_this: %1)\", _this];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["spawn","execVM","scriptDone"],"notes":[{"user":"PhilippRauch","date":"2009-06-13T17:39:00Z","text":"scriptName is good when you want to load the handle of some spawn or call with some name:\n\n```sqf\nexample_scripthandle = 0 spawn {\n    scriptName \"Example\";\n    systemChat str example_scripthandle; // System: Example\n}\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"scriptNull","operator":null,"title":"scriptNull","type":"command","url":"https://community.bistudio.com/wiki/scriptNull","revid":363804,"updated":"2024-04-21T18:03:23Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing or completed Script Handle. To compare non-existent scripts use isNull or isEqualTo:\n\n```sqf\nscriptNull == scriptNull;            // ERROR! == cannot be used with script object\nisNull scriptNull;                    // true\nscriptNull isEqualTo scriptNull;    // true\n```","syntaxes":[{"syntax":"scriptNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Script Handle","types":["Script Handle"],"description":"NULL script","text":"Script Handle - NULL script"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Wait until previous script is finished before starting a new one:\n\n```sqf\n0 spawn\n{\n    _script = scriptNull;\n    for \"_i\" from 1 to 10 do\n    {\n        waitUntil { isNull _script };\n        _script = _i spawn\n        {\n            hint format [\"script %1 started\", _this];\n            sleep 1;\n            hint format [\"script %1 finished\", _this];\n            sleep 0.2;\n        };\n    };\n};\n```","code":["0 spawn\n{\n\t_script = scriptNull;\n\tfor \"_i\" from 1 to 10 do\n\t{\n\t\twaitUntil { isNull _script };\n\t\t_script = _i spawn\n\t\t{\n\t\t\thint format [\"script %1 started\", _this];\n\t\t\tsleep 1;\n\t\t\thint format [\"script %1 finished\", _this];\n\t\t\tsleep 0.2;\n\t\t};\n\t};\n};"]},{"text":"```sqf\nif (scriptDone (_obj getVariable [\"TAG_objScript\", scriptNull])) then\n{\n    _scriptHandle = _obj spawn { waitUntil { damage _this > 0.9 }; hint \"Critical Damage!\"; };\n    _obj setVariable [\"TAG_objScript\", _scriptHandle];\n};\n```","code":["if (scriptDone (_obj getVariable [\"TAG_objScript\", scriptNull])) then\n{\n\t_scriptHandle = _obj spawn { waitUntil { damage _this > 0.9 }; hint \"Critical Damage!\"; };\n\t_obj setVariable [\"TAG_objScript\", _scriptHandle];\n};"]},{"text":"```sqf\nstr scriptNull; // <NULL-script>\n```","code":["str scriptNull; // <NULL-script>"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","locationNull","objNull","taskNull","teamMemberNull","configNull","typeName","isNull","scriptDone","spawn","execVM"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"scudState","operator":null,"title":"scudState","type":"command","url":"https://community.bistudio.com/wiki/scudState","revid":369332,"updated":"2024-09-03T18:43:00Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.30"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.30"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the current state of given Scud launcher.","syntaxes":[{"syntax":"scudState scudName","since":null,"effect":null,"exec":null,"params":[{"name":"scudName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"scudName: Object"}],"returns":{"type":"Number","types":["Number"],"description":"can be one of: - 0 - No activity - 1 - Launch preparation - 2 - Launch prepared - 3 - Ignition - 4 - Launched","text":"Number - can be one of:\n- 0 - No activity\n- 1 - Launch preparation\n- 2 - Launch prepared\n- 3 - Ignition\n- 4 - Launched"},"form":"unary","operator":null,"left":null,"right":{"text":"scudName","types":["Object"]}}],"examples":[{"text":"```sqf\nwaitUntil { sleep 1; scudState _scud > 2 };\nguba say \"MasterPlanCompletion\";\n```","code":["waitUntil { sleep 1; scudState _scud > 2 };\nguba say \"MasterPlanCompletion\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["action","Arma 3: Actions"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.30","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"secondaryWeapon","operator":null,"title":"secondaryWeapon","type":"command","url":"https://community.bistudio.com/wiki/secondaryWeapon","revid":348320,"updated":"2023-11-08T12:59:40Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of a unit's secondary weapon (launcher). To detect the weapon which is **currently** being used by the unit use currentWeapon.","syntaxes":[{"syntax":"secondaryWeapon unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"class name of the secondary weapon or `\"\"` if none available","text":"String - class name of the secondary weapon or `\"\"` if none available"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _secondaryWeapon = secondaryWeapon player;\n```","code":["private _secondaryWeapon = secondaryWeapon player;"]},{"text":"```sqf\nhint secondaryWeapon player; // \"launch_NLAW_F\"\n```","code":["hint secondaryWeapon player; // \"launch_NLAW_F\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["secondaryWeaponMagazine","secondaryWeaponItems","addSecondaryWeaponItem","primaryWeapon","handgunWeapon","currentWeapon","weapons"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"secondaryWeaponItems","operator":null,"title":"secondaryWeaponItems","type":"command","url":"https://community.bistudio.com/wiki/secondaryWeaponItems","revid":320949,"updated":"2022-05-13T10:04:45Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all items assigned to the secondaryWeapon except magazines. Use secondaryWeaponMagazine command for the latter. This command is used for infantry weapons only.","syntaxes":[{"syntax":"secondaryWeaponItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array","types":["Array"],"description":"[silencer, laserpointer/flashlight, optics, bipod]","text":"Array -  [silencer, laserpointer/flashlight, optics, bipod]"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nsecondaryWeaponItems player; //[\"\",\"\",\"\",\"\"]\n```","code":["secondaryWeaponItems player; //[\"\",\"\",\"\",\"\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addSecondaryWeaponItem","weaponAccessories","weaponAccessoriesCargo","handgunItems","primaryWeaponItems","binocularItems","weaponsItems","weaponsItemsCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"secondaryWeaponMagazine","operator":null,"title":"secondaryWeaponMagazine","type":"command","url":"https://community.bistudio.com/wiki/secondaryWeaponMagazine","revid":377135,"updated":"2026-01-01T10:28:04Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.70"}],"since":{"game":"arma3","name":"Arma 3","version":"0.70"},"arma3_since":"0.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Collects all loaded magazines from all secondaryWeapon muzzles and returns them in Array, otherwise it returns []. This command is used for infantry weapons only.","syntaxes":[{"syntax":"secondaryWeaponMagazine unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str secondaryWeaponMagazine player; //[\"NLAW_F\"]\n```","code":["hint str secondaryWeaponMagazine player; //[\"NLAW_F\"]"]},{"text":"```sqf\n_array = secondaryWeaponMagazine player;\nif (count _array > 0) then {\n    hint (\"Secondary weapon is loaded with \" + (_array select 0) + \"!\");\n} else {\n    if (secondaryWeapon player != \"\") then {\n        hint \"Secondary weapon is not loaded!\";\n    } else {\n        hint \"Player doesn't have a secondary weapon!\";\n    };\n};\n```","code":["_array = secondaryWeaponMagazine player;\nif (count _array > 0) then {\n\thint (\"Secondary weapon is loaded with \" + (_array select 0) + \"!\");\n} else {\n\tif (secondaryWeapon player != \"\") then {\n\t\thint \"Secondary weapon is not loaded!\";\n\t} else {\n\t\thint \"Player doesn't have a secondary weapon!\";\n\t};\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["secondaryWeapon","secondaryWeaponItems","addSecondaryWeaponItem","primaryWeaponMagazine","handgunMagazine","binocularMagazine"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.70","Scripting Commands"]},{"name":"select","operator":null,"title":"select","type":"command","url":"https://community.bistudio.com/wiki/select","revid":377134,"updated":"2026-01-01T10:27:32Z","groups":["Arrays","Strings","Config"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects an element from an array, config entry from Config or substring from a string or a range from an array.","syntaxes":[{"syntax":"array select index","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index 0 denotes the first element, 1 the second, etc. If index has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up.\n\nArma 3 v2.12 negative index can be used to select from the end of the array, i.e. -1 means last array element.","types":["Number"],"since":null,"text":"index: Number - index 0 denotes the first element, 1 the second, etc. If index has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up.\n\nArma 3 v2.12 negative index can be used to select from the end of the array, i.e. -1 means last array element."}],"returns":{"type":"Anything","types":["Anything"],"description":"a reference to the array element given by its index > [!IMPORTANT] > When the index equals the size of the array, there is no error for out of range selection and nil is returned - see #Example 8.","text":"Anything - a reference to the array element given by its index\n\n> [!IMPORTANT]\n> When the index equals the size of the array, there is no error for out of range selection and nil is returned - see #Example 8."},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"index","types":["Number"]}},{"syntax":"array select boolean","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"boolean","type":"Boolean","optional":false,"default":null,"description":"false selects the **first** element of the Array, true the **second** one","types":["Boolean"],"since":null,"text":"boolean: Boolean - false selects the **first** element of the Array, true the **second** one"}],"returns":{"type":"Anything","types":["Anything"],"description":"a reference to the array element","text":"Anything - a reference to the array element"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"boolean","types":["Boolean"]}},{"syntax":"config select index","since":"arma1 1.00","effect":null,"exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":null,"types":["Config"],"since":null,"text":"config: Config"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index 0 denotes the first element, 1 the second, etc. If index has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up","types":["Number"],"since":null,"text":"index: Number - index 0 denotes the first element, 1 the second, etc. If index has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up"}],"returns":{"type":"Config","types":["Config"],"description":null,"text":"Config"},"form":"binary","operator":null,"left":{"text":"config","types":["Config"]},"right":{"text":"index","types":["Number"]}},{"syntax":"string select [start, length]","since":"arma3 1.28","effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"},{"name":"start","type":"Number","optional":false,"default":null,"description":"string position to start selection from. 0 denotes the first character of the string, 1 the second, etc. If passed number has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up","types":["Number"],"since":null,"text":"start: Number - string position to start selection from. 0 denotes the first character of the string, 1 the second, etc. If passed number has decimal places it gets rounded down for fractions less than or equal .5, otherwise it gets rounded up"},{"name":"length","type":"Number","optional":true,"default":"string's length","description":"number of characters to select","types":["Number"],"since":null,"text":"length: Number - (Optional, default *string*'s length) number of characters to select"}],"returns":{"type":null,"types":["String"],"description":null,"text":"String\n\n> [!NOTE]\n> Substring version of select operates with the ANSI charset; if Unicode support is desired, see forceUnicode."},"form":"binary","operator":null,"left":{"text":"string","types":["String"]},"right":{"text":"[start, length]","types":["Array"]}},{"syntax":"array select [start, count]","since":"arma3 1.32","effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"start","type":"Number","optional":false,"default":null,"description":"array index to start selection from","types":["Number"],"since":null,"text":"start: Number - array index to start selection from"},{"name":"count","type":"Number","optional":true,"default":null,"description":"number of array elements to select. If the selected range exceeds source array boundaries, selection will be made up to the last element of the array.\n\n> [!NOTE]\n> Since v2.14 'count' is optional, if omitted the selection is made from *start* until the end of the array.","types":["Number"],"since":null,"text":"count: Number - (Optional after Arma 3 v2.14) number of array elements to select. If the selected range exceeds source array boundaries, selection will be made up to the last element of the array.\n\n> [!NOTE]\n> Since v2.14 'count' is optional, if omitted the selection is made from *start* until the end of the array."}],"returns":{"type":"Array","types":["Array"],"description":"a new array from selection","text":"Array - a new array from selection"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"[start, count]","types":["Array"]}},{"syntax":"array select expression","since":"arma3 1.56","effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"expression","type":"Code","optional":false,"default":null,"description":"expression that is expected to return Boolean or Nothing.\nIf true is returned, the original array value of currently tested element _x will be added to the output array","types":["Code"],"since":null,"text":"expression: Code - expression that is expected to return Boolean or Nothing.\nIf true is returned, the original array value of currently tested element _x will be added to the output array"}],"returns":{"type":"Array","types":["Array"],"description":"a new array of all elements from the original array that satisfied expression condition","text":"Array - a new array of all elements from the original array that satisfied expression condition"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"expression","types":["Code"]}}],"examples":[{"text":"```sqf\n[\"a\", \"b\", \"c\", \"d\"] select 2;    // result is \"c\"\nposition player select 2;        // result is Z coordinate of player position\n```","code":["[\"a\", \"b\", \"c\", \"d\"] select 2;\t// result is \"c\"\nposition player select 2;\t\t// result is Z coordinate of player position"]},{"text":"```sqf\n[\"\", currentWeapon player] select alive player; // if player is dead, \"\" is selected\n```","code":["[\"\", currentWeapon player] select alive player; // if player is dead, \"\" is selected"]},{"text":"```sqf\n(configFile >> \"cfgVehicles\" >> typeOf vehicle player >> \"Turrets\") select 0 >> \"gunnerAction\";\n```","code":["(configFile >> \"cfgVehicles\" >> typeOf vehicle player >> \"Turrets\") select 0 >> \"gunnerAction\";"]},{"text":"```sqf\nhint str (\"japa is the man!\" select [8]);        // the man!\nhint str (\"japa is the man!\" select [0, 7]);    // japa is\n```","code":["hint str (\"japa is the man!\" select [8]);\t\t// the man!\nhint str (\"japa is the man!\" select [0, 7]);\t// japa is"]},{"text":"```sqf\nhint str ([1,2,3,4,5,6] select [1, 4]); // [2,3,4,5]\n```","code":["hint str ([1,2,3,4,5,6] select [1, 4]); // [2,3,4,5]"]},{"text":"```sqf\n_even = [1,2,3,4,5,6,7,8,9,0] select { _x % 2 == 0 }; // returns [2, 4, 6, 8, 0]\n```","code":["_even = [1,2,3,4,5,6,7,8,9,0] select { _x % 2 == 0 }; // returns [2, 4, 6, 8, 0]"]},{"text":"JavaScript endsWith() alternative:\n\n```sqf\nprivate _fnc_endsWith = \n{\n    params [\"_string\", \"_endswith\"];\n    _string select [count _string - count _endswith] isEqualTo _endswith\n};\n\n[\"Arma 3\", \"3\"] call _fnc_endsWith; // true\n[\"Arma 3\", \"4\"] call _fnc_endsWith; // false\n```","code":["private _fnc_endsWith = \n{\n\tparams [\"_string\", \"_endswith\"];\n\t_string select [count _string - count _endswith] isEqualTo _endswith\n};\n\n[\"Arma 3\", \"3\"] call _fnc_endsWith; // true\n[\"Arma 3\", \"4\"] call _fnc_endsWith; // false"]},{"text":"select index traps:\n\n```sqf\nprivate _array = [\"a\", \"b\", \"c\", \"d\"];\n_array select 0; // \"a\"\n_array select 3; // \"d\"\n_array select 4; // nil - no error shown\n_array select 5; // error\n\n// can sometimes be useful\nprivate _firstEnemyNearMe = units opfor select { player distance _x < 10 } select 0; // nil if no enemies nearby\nif (isNil \"_firstEnemyNearMe\") exitWith { systemChat \"no enemy found\" };\nsystemChat format [\"enemy found: %1\", name _firstEnemyNearMe];\n\n// get the last element properly\n_array select (count _array);        // wrong - nil is returned\n_array select (count _array - 1);    // correct - \"d\" is returned\n```","code":["private _array = [\"a\", \"b\", \"c\", \"d\"];\n_array select 0; // \"a\"\n_array select 3; // \"d\"\n_array select 4; // nil - no error shown\n_array select 5; // error\n\n// can sometimes be useful\nprivate _firstEnemyNearMe = units opfor select { player distance _x < 10 } select 0; // nil if no enemies nearby\nif (isNil \"_firstEnemyNearMe\") exitWith { systemChat \"no enemy found\" };\nsystemChat format [\"enemy found: %1\", name _firstEnemyNearMe];\n\n// get the last element properly\n_array select (count _array);\t\t// wrong - nil is returned\n_array select (count _array - 1);\t// correct - \"d\" is returned"]},{"text":"> [!NOTE]\n> **Arma 3:** Since Arma 3 v2.12 `-1` can be used to select the last element of an array.\n\n```sqf\nprivate _array = [1, 2, 3, 4, 5];\nhint str (_array select -1); // 5\n```","code":["private _array = [1, 2, 3, 4, 5];\nhint str (_array select -1); // 5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["a hash b","selectRandom","selectRandomWeighted","set","resize","reverse","in","find","findIf","toArray","toString","forEach","count","deleteAt","deleteRange","append","sort","param","params","splitString","joinString","pushBack","pushBackUnique","apply","forceUnicode"],"notes":[{"user":"General Barron","date":"2009-03-03T02:02:00Z","text":"When combined with the count command, this can be used to read all entries out of a config; even when you don't know exactly how many entries there will be.\nSee the notes under count for more info."},{"user":"Killzone_Kid","date":"2013-09-28T00:53:00Z","text":"Rounding of fractions with select is not the same as when you use round command:\n\n```sqf\n_roundThis = 0.5;\nhint str ([0,1] select _roundThis);            // 0\nhint str ([0,1] select round _roundThis);    // 1\n```"},{"user":"Pierre MGI","date":"2016-07-14T04:18:00Z","text":"You can substract array from array using select:\n\n```sqf\n_array = [[1], [2], [3]];\n_sub = [2];\n_array - _sub; // [[1], [2], [3]]\n_array select { !(_x isEqualTo _sub) }; // [[1], [3]]\n[[1],[2],[2],[2],[2],[3]] select { !(_x isEqualTo _sub) }; // [[1], [3]]\n```"},{"user":"Commy2","date":"2016-11-12T22:36:00Z","text":"It is not safe to escape the code block of alternative syntax #5 with exitWith, breakOut etc:\n\n```sqf\nx3 = [1,2,3,4,5] select {\n    if (_x == 3) exitWith\n    {\n        false;\n    };\n    true\n};\n// could be expected to be: x3 = [1,2,4,5]\n// actual result: x3 = false\n```"},{"user":"Igneous01","date":"2017-02-14T16:26:00Z","text":"#Syntax 5 is the equivalent of passing in a predicate that returns a boolean. In SQF, a piece of code will always return what the last executed command returned.\n\n```sqf\nmyAliveUnits = allUnits select { alive _x };    // alive returns a boolean, the last statement run was alive _x,\n                                                // therefore this piece of code will return a true/false to the select command\nmyEastGroups = allGroups select { side _x == east };                    // returns all east groups\nmy4ManGroups = allGroups select { count units _x == 4 };                // returns all groups that have 4 men in them\nunitsThatDetectedMe = allUnits select { _x knowsAbout player > 0.1 };    // returns a list of units that have detected the player\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Config","Command Group: Strings","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectBestPlaces","operator":null,"title":"selectBestPlaces","type":"command","url":"https://community.bistudio.com/wiki/selectBestPlaces","revid":377620,"updated":"2026-01-02T08:51:55Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Find the places with the maximum value of *expression* in the given area. Places can be on water. Results are sorted by value. Search pattern is randomised every command execution.","syntaxes":[{"syntax":"selectBestPlaces [position, radius, expression, precision, sourcesCount]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Object, Position3D or Position2D","optional":false,"default":null,"description":null,"types":["Object","Position3D","Position2D"],"since":null,"text":"position: Object, Position3D or Position2D"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"},{"name":"expression","type":"String","optional":false,"default":null,"description":"arithmetic expression. Simple expression var names containing values from 0 to 1 depending on location (see also Ambient Parameters):\n- forest\n- trees\n- meadow\n- hills\n- houses\n- sea\n- coast\n- night\n- rain\n- windy\n- deadBody\n- waterDepth\n- camDepth","types":["String"],"since":null,"text":"expression: String - arithmetic expression. Simple expression var names containing values from 0 to 1 depending on location (see also Ambient Parameters):\n- forest\n- trees\n- meadow\n- hills\n- houses\n- sea\n- coast\n- night\n- rain\n- windy\n- deadBody\n- waterDepth\n- camDepth"},{"name":"precision","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"precision: Number"},{"name":"sourcesCount","type":"Number","optional":false,"default":null,"description":"max results to return. The maximum possible is the number of random samples, which is **n = (2 * radius / precision)^2**","types":["Number"],"since":null,"text":"sourcesCount: Number - max results to return. The maximum possible is the number of random samples, which is **n = (2 * radius / precision)^2**"}],"returns":{"type":null,"types":["Array","Position2D","Number"],"description":null,"text":"Array with [[position: Position2D, expressionResult: Number], ...]"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, radius, expression, precision, sourcesCount]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyPlaces = selectBestPlaces [position player, 50, \"meadow + 2*hills\", 1, 5];\n```","code":["myPlaces = selectBestPlaces [position player, 50, \"meadow + 2*hills\", 1, 5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getEnvSoundController","getAllEnvSoundControllers","findEmptyPosition","isFlatEmpty","Ambient Parameters"],"notes":[{"user":"Rübe","date":"2010-07-17T18:39:00Z","text":"see http://forums.bistudio.com/showthread.php?t=93897 for some more information (though neither official, nor complete).\nThe most important information is the list of useable keywords for the expression which is: **forest, trees, meadow, hills, houses, sea, night, rain, windy** and **deadBody**.\nThe keyword will be replaced by the actual value at the given sample position and thus the expression gets evaluated.\nFor example the following expression (which returns high values in forest) *\"forest + trees - meadow - houses - (10 * sea)\"* might be transformed to *0 + 0.1 - 0.7 - 0 - (10 * 0)* which is - with it is result of -0.6 - not in the forest, though there are some tree(s) around. You get the idea.\n\nAlso note that you may aswell check such an expression value at a single position by passing a low radius and a sourceCount of 1, which is often just as useful as retrieving multiple (and already sorted) positions.\n\nAlso do not underestimate the keywords *night*, *rain* or *windy*, for if you couple them with the other keywords, you can easily get a highly dynamic system at a very low cost.\n(this, btw., is how animals \"choose\" where and when to spawn)"},{"user":"ffur2007slx2_5","date":"2014-04-03T16:10:00Z","text":"In Arma 3 ver 1.14 Two new expressions are available: **waterDepth**(0-1) and **camDepth**(0-1), along with three simple operators: **interpolate**, **randomGen** and **factor** that can be used together with expressions. E.g.\n\n```sqf\np = selectBestPlaces [\n    position player,\n    500,\n    \"(2 * (waterDepth interpolate [1,16,0,1]) * ((0.1+houses factor [0.1,0.8]) * (randomGen 1 + houses)))\",\n    1,\n    1\n];\n```\n\n**A**lgorithm randomGen:\n`randomGen A(number): randomly generate a float number from 0 - A`\n**A**lgorithm factor:\n`A(number) factor [p,q] = p< A <q: [(A -p)/(q-p)]`\n**A**lgorithm interpolate:\n`A(number) interpolate [p,q,r,s] = A <=p:r A >=q:s p< A <q: [(A -p)/(q-p)]*(s-r) +r`"},{"user":"Killzone_Kid","date":"2015-06-15T13:27:00Z","text":"*precision* seems to have range 0 - 100. At very low values the command is extremely slow. 100 makes it quite fast. It looks like *precision* is some kind of grid search size.\nLarge chunks make the search faster but less accurate.\n\nResulting array is [] if *sourcesCount* is 0 or  *expression* is \"\". In all other cases it seems that result is array of arrays of the set max count.\nThe sole indication of successful search is *expressionResult* value when it is > 0."},{"user":"Tankbuster","date":"2017-06-04T20:51:00Z","text":"Results are sorted by value, that is, the result of the expression.\nThey are sorted in descending order, so in the case of waterdepth, the deepest water will be found at the locations at the start of the returned array and the shallowest water will be found at the locations at the end."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectDiarySubject","operator":null,"title":"selectDiarySubject","type":"command","url":"https://community.bistudio.com/wiki/selectDiarySubject","revid":349165,"updated":"2023-11-08T14:49:52Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Selects a subject page in the diary. The subject page is selected but the command does not open the map by default, which could be opened with openMap if necessary.","syntaxes":[{"syntax":"player selectDiarySubject subject","since":null,"effect":null,"exec":null,"params":[{"name":"player","type":"Object","optional":false,"default":null,"description":"player","types":["Object"],"since":null,"text":"player: Object - player"},{"name":"subject","type":"String","optional":false,"default":null,"description":"subject name, for example \"Diary\" (see also Diary).\n\n> [!NOTE]\n> In order to open a specific record inside a subject one can append `Record#` to the subject name.\n>\n> ```sqf\n> player selectDiarySubject \"Diary:Record0\"; // selects the first record in the diary subject (from bottom to top)\n> player selectDiarySubject \"Diary:Record1\"; // selects the second record\n> ```","types":["String"],"since":null,"text":"subject: String - subject name, for example \"Diary\" (see also Diary).\n\n> [!NOTE]\n> In order to open a specific record inside a subject one can append `Record#` to the subject name.\n>\n> ```sqf\n> player selectDiarySubject \"Diary:Record0\"; // selects the first record in the diary subject (from bottom to top)\n> player selectDiarySubject \"Diary:Record1\"; // selects the second record\n> ```"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if subject was successfully selected","text":"Boolean - true if subject was successfully selected"},"form":"binary","operator":null,"left":{"text":"player","types":["Object"]},"right":{"text":"subject","types":["String"]}}],"examples":[{"text":"```sqf\nopenMap true;\nplayer selectDiarySubject \"Diary\";\n```","code":["openMap true;\nplayer selectDiarySubject \"Diary\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["processDiaryLink","createDiaryLink","createDiarySubject","diarySubjectExists","allDiarySubjects"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"selectedEditorObjects","operator":null,"title":"selectedEditorObjects","type":"command","url":"https://community.bistudio.com/wiki/selectedEditorObjects","revid":377133,"updated":"2026-01-01T10:26:59Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a list of currently selected editor objects.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"selectedEditorObjects map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\n_selObjects = selectedEditorObjects _map; // result can be: [\"_vehicle_0\",\"_vehicle_9\",\"_vehicle_11\"]\n```","code":["_selObjects = selectedEditorObjects _map; // result can be: [\"_vehicle_0\",\"_vehicle_9\",\"_vehicle_11\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENSelected"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectEditorObject","operator":null,"title":"selectEditorObject","type":"command","url":"https://community.bistudio.com/wiki/selectEditorObject","revid":363240,"updated":"2024-03-26T10:51:18Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Select an editor object. Does not un-select previously selected objects.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map selectEditorObject object","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"object","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectionNames","operator":null,"title":"selectionNames","type":"command","url":"https://community.bistudio.com/wiki/selectionNames","revid":376409,"updated":"2025-10-11T01:01:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of model selections. When using default syntax, the named selections are returned from the first LOD only (LOD index 0).\n\nAlternative syntax allows to select LOD by name or by LOD resolution.\n\n> [!IMPORTANT]\n> Sometimes internally \"ViewGeometry\" can be equal to \"Geometry\", and \"FireGeometry\" could be equal to \"ViewGeometry\".\n> In order to pinpoint the actual LOD, use allLODs and LOD resolution as argument for selecting the LOD.","syntaxes":[{"syntax":"selectionNames object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"selection names","text":"Array of Strings - selection names"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}},{"syntax":"object selectionNames LOD","since":"arma3 2.00","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"String or Number\n- String - LOD name; can be one of:\n  - \"Memory\"\n  - \"Geometry\"\n  - \"FireGeometry\"\n  - \"LandContact\"\n  - \"HitPoints\"\n  - Arma 3 v2.06 \"ViewGeometry\"\n- Number - LOD resolution; command searches for a LOD with the similar resolution","types":["String","Number"],"since":null,"text":"LOD: String or Number\n- String - LOD name; can be one of:\n  - \"Memory\"\n  - \"Geometry\"\n  - \"FireGeometry\"\n  - \"LandContact\"\n  - \"HitPoints\"\n  - Arma 3 v2.06 \"ViewGeometry\"\n- Number - LOD resolution; command searches for a LOD with the similar resolution"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"selection names","text":"Array of Strings - selection names"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"LOD","types":["String","Number"]}}],"examples":[{"text":"```sqf\nprivate _result = \"Land_i_House_Small_02_V3_F\" createVehicle _pos;\nselectionNames _house;\n/*\n[\n    \"door_1\",\"door_2\",\"damt_1\",\"door_handle_1\",\"door_handle_2\",\"glass_1_hide\",\"glass_2_hide\",\"glass_3_hide\",\n    \"glass_1_unhide\",\"glass_2_unhide\",\"glass_3_unhide\",\"glass_4_hide\",\"glass_4_unhide\"\n]\n*/\n```","code":["private _result = \"Land_i_House_Small_02_V3_F\" createVehicle _pos;\nselectionNames _house;\n/*\n[\n\t\"door_1\",\"door_2\",\"damt_1\",\"door_handle_1\",\"door_handle_2\",\"glass_1_hide\",\"glass_2_hide\",\"glass_3_hide\",\n\t\"glass_1_unhide\",\"glass_2_unhide\",\"glass_3_unhide\",\"glass_4_hide\",\"glass_4_unhide\"\n]\n*/"]},{"text":"```sqf\nselectionNames player;\n/*\n[\n    \"spine\",\"spine1\",\"spine2\",\"spine3\",\"head\",\n    \"leftshoulder\",\"leftarm\",\"leftarmroll\",\"leftforearm\",\"leftforearmroll\",\"lefthand\",\"rightshoulder\",\"rightarm\",\"rightarmroll\",\"rightforearm\",\"rightforearmroll\",\"righthand\",\n    \"pelvis\",\"leftupleg\",\"leftuplegroll\",\"leftleg\",\"leftlegroll\",\"leftfoot\",\"lefttoebase\",\"rightupleg\",\"rightuplegroll\",\"rightleg\",\"rightlegroll\",\"rightfoot\",\"righttoebase\",\"weapon\",\n    \"proxy:\\a3\\characters_f\\proxies\\weapon.001\",\"proxy:\\a3\\characters_f\\proxies\\pistol.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\binoculars.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\launcher.001\",\n    \"launcher\",\"nvg\",\"proxy:\\a3\\characters_f\\proxies\\nvg.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\flag.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\equipment.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\backpack.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\pistol_holstered.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\head_male.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\glasses.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\headgear.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\hair.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\backpack2.001\",\n    \"proxy:\\a3\\characters_f\\proxies\\radio.001\",\n    \"body_proxy\",\"head_proxy\",\n    \"lefthandindex1\",\"lefthandindex2\",\"lefthandindex3\",\"lefthandmiddle1\",\"lefthandmiddle2\",\"lefthandmiddle3\",\"lefthandring\",\"lefthandpinky1\",\"lefthandpinky2\",\"lefthandpinky3\",\n    \"lefthandring1\",\"lefthandring2\",\"lefthandring3\",\"lefthandthumb1\",\"lefthandthumb2\",\"lefthandthumb3\",\n    \"righthandindex1\",\"righthandindex2\",\"righthandindex3\",\"righthandmiddle1\",\"righthandmiddle2\",\"righthandmiddle3\",\"righthandring\",\"righthandpinky1\",\"righthandpinky2\",\"righthandpinky3\",\n    \"righthandring1\",\"righthandring2\",\"righthandring3\",\"righthandthumb1\",\"righthandthumb2\",\"righthandthumb3\",\n    \"injury_hands\",\n    \"camo\",\n    \"proxy:\\a3\\characters_f\\heads\\bysta.001\",\n    \"injury_legs\",\n    \"proxy:\\a3\\characters_f\\proxies\\hmd.001\",\n    \"hl\",\"insignia\",\"injury_body\",\"clan\"\n]\n*/\n```","code":["selectionNames player;\n/*\n[\n\t\"spine\",\"spine1\",\"spine2\",\"spine3\",\"head\",\n\t\"leftshoulder\",\"leftarm\",\"leftarmroll\",\"leftforearm\",\"leftforearmroll\",\"lefthand\",\"rightshoulder\",\"rightarm\",\"rightarmroll\",\"rightforearm\",\"rightforearmroll\",\"righthand\",\n\t\"pelvis\",\"leftupleg\",\"leftuplegroll\",\"leftleg\",\"leftlegroll\",\"leftfoot\",\"lefttoebase\",\"rightupleg\",\"rightuplegroll\",\"rightleg\",\"rightlegroll\",\"rightfoot\",\"righttoebase\",\"weapon\",\n\t\"proxy:\\a3\\characters_f\\proxies\\weapon.001\",\"proxy:\\a3\\characters_f\\proxies\\pistol.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\binoculars.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\launcher.001\",\n\t\"launcher\",\"nvg\",\"proxy:\\a3\\characters_f\\proxies\\nvg.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\flag.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\equipment.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\backpack.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\pistol_holstered.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\head_male.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\glasses.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\headgear.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\hair.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\backpack2.001\",\n\t\"proxy:\\a3\\characters_f\\proxies\\radio.001\",\n\t\"body_proxy\",\"head_proxy\",\n\t\"lefthandindex1\",\"lefthandindex2\",\"lefthandindex3\",\"lefthandmiddle1\",\"lefthandmiddle2\",\"lefthandmiddle3\",\"lefthandring\",\"lefthandpinky1\",\"lefthandpinky2\",\"lefthandpinky3\",\n\t\"lefthandring1\",\"lefthandring2\",\"lefthandring3\",\"lefthandthumb1\",\"lefthandthumb2\",\"lefthandthumb3\",\n\t\"righthandindex1\",\"righthandindex2\",\"righthandindex3\",\"righthandmiddle1\",\"righthandmiddle2\",\"righthandmiddle3\",\"righthandring\",\"righthandpinky1\",\"righthandpinky2\",\"righthandpinky3\",\n\t\"righthandring1\",\"righthandring2\",\"righthandring3\",\"righthandthumb1\",\"righthandthumb2\",\"righthandthumb3\",\n\t\"injury_hands\",\n\t\"camo\",\n\t\"proxy:\\a3\\characters_f\\heads\\bysta.001\",\n\t\"injury_legs\",\n\t\"proxy:\\a3\\characters_f\\proxies\\hmd.001\",\n\t\"hl\",\"insignia\",\"injury_body\",\"clan\"\n]\n*/"]},{"text":"HitPart hit selections only:\n\n```sqf\nselectionNames player select { !(player selectionPosition [_x, \"HitPoints\"] isEqualTo [0,0,0]) };\n/*\n[\n    \"spine1\",\"spine2\",\"spine3\",\"head\",\"leftarm\",\"leftarmroll\",\"leftforearm\",\"rightarm\",\"rightarmroll\",\"rightforearm\",\n    \"pelvis\",\"leftupleg\",\"leftuplegroll\",\"leftlegroll\",\"leftfoot\",\"rightupleg\",\"rightuplegroll\",\"rightleg\",\"rightlegroll\",\"rightfoot\"\n]\n*/\n```","code":["selectionNames player select { !(player selectionPosition [_x, \"HitPoints\"] isEqualTo [0,0,0]) };\n/*\n[\n\t\"spine1\",\"spine2\",\"spine3\",\"head\",\"leftarm\",\"leftarmroll\",\"leftforearm\",\"rightarm\",\"rightarmroll\",\"rightforearm\",\n\t\"pelvis\",\"leftupleg\",\"leftuplegroll\",\"leftlegroll\",\"leftfoot\",\"rightupleg\",\"rightuplegroll\",\"rightleg\",\"rightlegroll\",\"rightfoot\"\n]\n*/"]},{"text":"Copy 5 LODs' selections:\n\n```sqf\nprivate _car = \"B_MRAP_01_F\" createVehicle getPos player;\nprivate _return = [];\n{\n    _return pushBack (_x + \": \" + str (_car selectionNames _x));\n} forEach [\"Memory\", \"Geometry\", \"FireGeometry\", \"LandContact\", \"HitPoints\"];\ncopyToClipboard (_return joinString endl);\n/*\n    Memory: [\"light_r_end\",\"drivewheel_axis\",\"posun wheel_1_1\",\"posun wheel_1_2\",\"posun wheel_2_1\",\"posun wheel_2_2\",\"wheel_1_1_steering_axis\",\"wheel_2_1_steering_axis\",\"wheel_2_1_axis\",\"wheel_2_2_axis\",\"wheel_1_2_axis\",\"wheel_1_1_axis\",\"basic_damper_destruct_axis\",\"pos cargo\",\"pos cargo dir\",\"pos driver\",\"pos driver dir\",\"circulumreference\",\"zamerny\",\"doplnovani\",\"light_l_end\",\"light_r\",\"light_l\",\"stopa pll\",\"stopa plp\",\"stopa ppl\",\"stopa ppp\",\"stopa zll\",\"stopa zlp\",\"stopa zpl\",\"stopa zpp\",\"exhaust_dir\",\"exhaust_pos\",\"osaveze\",\"mph_axis\",\"rpm_axis\",\"fuel_axis\",\"temp2_axis\",\"temp_axis\",\"pip1_pos\",\"pip1_dir\",\"pip4_dir\",\"pip6_dir\",\"pip5_dir\",\"pip7_dir\",\"pip4_pos\",\"pip6_pos\",\"pip7_pos\",\"pip5_pos\",\"dustfrontright\",\"dustfrontleft\",\"dustbackleft\",\"dustbackright\",\"light_r_flare\",\"light_l_flare\",\"light_r_flare2\",\"light_l_flare2\",\"wheel_1_1_bound\",\"wheel_1_2_bound\",\"wheel_2_1_bound\",\"wheel_2_2_bound\",\"door_1_axis\",\"door_2_axis\",\"door_3_axis\",\"door_4_axis\",\"pedal_thrust_axis\",\"pedal_brake_axis\",\"slingloadcargo1\",\"slingloadcargo2\",\"slingloadcargo3\",\"slingloadcargo4\",\"tow_front_l\",\"tow_rear_r\",\"tow_front_r\",\"tow_rear_l\",\"taskmarker_1_pos\",\"bbox_1_2_pos\",\"bbox_1_1_pos\",\"bbox_2_1_pos\",\"bbox_2_2_pos\",\"pip_1_tl\",\"pip_1_tr\",\"pip_1_bl\",\"pip_1_br\",\"pip_4_tl\",\"pip_4_tr\",\"pip_4_bl\",\"pip_4_br\",\"pip_5_tl\",\"pip_5_tr\",\"pip_5_br\",\"pip_5_bl\"]\n    Geometry: [\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.001\",\"wheel_1_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.002\",\"wheel_1_2_unhide\",\"wheel_2_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.003\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.004\",\"wheel_2_2_unhide\",\"damagehide\",\"wheel_1_2_damper\",\"wheel_1_1_damper\",\"wheel_2_2_damper\",\"wheel_2_1_damper\"]\n    FireGeometry: [\"wheel_2_2_hide\",\"wheel_1_2_hide\",\"wheel_1_1_hide\",\"wheel_2_1_hide\",\"damagehide\",\"glass2\",\"glass3\",\"glass1\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.001\",\"wheel_1_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.002\",\"wheel_1_2_unhide\",\"wheel_2_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.003\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.004\",\"wheel_2_2_unhide\",\"proxy:\\a3\\data_f\\proxies\\passenger_mrap_01_back\\cargo.002\",\"proxy:\\a3\\data_f\\proxies\\passenger_generic01_foldhands\\cargo.003\",\"proxy:\\a3\\data_f\\proxies\\passenger_mrap_01_front\\cargo.001\",\"proxy:\\a3\\data_f\\proxies\\driver_offroad\\driver.001\",\"reserve_wheel\",\"zbytek\",\"glass4\",\"glass5\",\"glass6\",\"hit_engine\",\"hit_fuel\",\"hit_hull\",\"door_1_hide\",\"door_3_hide\"]\n    LandContact: [\"wheel_2_1_damper_land\",\"wheel_1_2_damper_land\",\"wheel_2_2_damper_land\",\"wheel_1_1_damper_land\"]\n    HitPoints: [\"wheel_2_1_steering\",\"wheel_2_2_steering\",\"wheel_1_2_steering\",\"wheel_1_1_steering\",\"motor\",\"karoserie\",\"light_r\",\"light_l\",\"glass2\",\"palivo\",\"glass3\",\"glass1\",\"wheel_reserve_hit\",\"light_r2\",\"light_l2\",\"zbytek\",\"door_1\",\"door_2\",\"door_3\",\"door_4\",\"glass4\",\"glass5\",\"glass6\",\"hit_engine_point\",\"hit_fuel_point\",\"hit_hull_point\"]\n*/\n```","code":["private _car = \"B_MRAP_01_F\" createVehicle getPos player;\nprivate _return = [];\n{\n\t_return pushBack (_x + \": \" + str (_car selectionNames _x));\n} forEach [\"Memory\", \"Geometry\", \"FireGeometry\", \"LandContact\", \"HitPoints\"];\ncopyToClipboard (_return joinString endl);\n/*\n\tMemory: [\"light_r_end\",\"drivewheel_axis\",\"posun wheel_1_1\",\"posun wheel_1_2\",\"posun wheel_2_1\",\"posun wheel_2_2\",\"wheel_1_1_steering_axis\",\"wheel_2_1_steering_axis\",\"wheel_2_1_axis\",\"wheel_2_2_axis\",\"wheel_1_2_axis\",\"wheel_1_1_axis\",\"basic_damper_destruct_axis\",\"pos cargo\",\"pos cargo dir\",\"pos driver\",\"pos driver dir\",\"circulumreference\",\"zamerny\",\"doplnovani\",\"light_l_end\",\"light_r\",\"light_l\",\"stopa pll\",\"stopa plp\",\"stopa ppl\",\"stopa ppp\",\"stopa zll\",\"stopa zlp\",\"stopa zpl\",\"stopa zpp\",\"exhaust_dir\",\"exhaust_pos\",\"osaveze\",\"mph_axis\",\"rpm_axis\",\"fuel_axis\",\"temp2_axis\",\"temp_axis\",\"pip1_pos\",\"pip1_dir\",\"pip4_dir\",\"pip6_dir\",\"pip5_dir\",\"pip7_dir\",\"pip4_pos\",\"pip6_pos\",\"pip7_pos\",\"pip5_pos\",\"dustfrontright\",\"dustfrontleft\",\"dustbackleft\",\"dustbackright\",\"light_r_flare\",\"light_l_flare\",\"light_r_flare2\",\"light_l_flare2\",\"wheel_1_1_bound\",\"wheel_1_2_bound\",\"wheel_2_1_bound\",\"wheel_2_2_bound\",\"door_1_axis\",\"door_2_axis\",\"door_3_axis\",\"door_4_axis\",\"pedal_thrust_axis\",\"pedal_brake_axis\",\"slingloadcargo1\",\"slingloadcargo2\",\"slingloadcargo3\",\"slingloadcargo4\",\"tow_front_l\",\"tow_rear_r\",\"tow_front_r\",\"tow_rear_l\",\"taskmarker_1_pos\",\"bbox_1_2_pos\",\"bbox_1_1_pos\",\"bbox_2_1_pos\",\"bbox_2_2_pos\",\"pip_1_tl\",\"pip_1_tr\",\"pip_1_bl\",\"pip_1_br\",\"pip_4_tl\",\"pip_4_tr\",\"pip_4_bl\",\"pip_4_br\",\"pip_5_tl\",\"pip_5_tr\",\"pip_5_br\",\"pip_5_bl\"]\n\tGeometry: [\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.001\",\"wheel_1_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.002\",\"wheel_1_2_unhide\",\"wheel_2_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.003\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.004\",\"wheel_2_2_unhide\",\"damagehide\",\"wheel_1_2_damper\",\"wheel_1_1_damper\",\"wheel_2_2_damper\",\"wheel_2_1_damper\"]\n\tFireGeometry: [\"wheel_2_2_hide\",\"wheel_1_2_hide\",\"wheel_1_1_hide\",\"wheel_2_1_hide\",\"damagehide\",\"glass2\",\"glass3\",\"glass1\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.001\",\"wheel_1_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.002\",\"wheel_1_2_unhide\",\"wheel_2_1_unhide\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.003\",\"proxy:\\a3\\data_f\\proxies\\damagewheel\\damagewheel_1.004\",\"wheel_2_2_unhide\",\"proxy:\\a3\\data_f\\proxies\\passenger_mrap_01_back\\cargo.002\",\"proxy:\\a3\\data_f\\proxies\\passenger_generic01_foldhands\\cargo.003\",\"proxy:\\a3\\data_f\\proxies\\passenger_mrap_01_front\\cargo.001\",\"proxy:\\a3\\data_f\\proxies\\driver_offroad\\driver.001\",\"reserve_wheel\",\"zbytek\",\"glass4\",\"glass5\",\"glass6\",\"hit_engine\",\"hit_fuel\",\"hit_hull\",\"door_1_hide\",\"door_3_hide\"]\n\tLandContact: [\"wheel_2_1_damper_land\",\"wheel_1_2_damper_land\",\"wheel_2_2_damper_land\",\"wheel_1_1_damper_land\"]\n\tHitPoints: [\"wheel_2_1_steering\",\"wheel_2_2_steering\",\"wheel_1_2_steering\",\"wheel_1_1_steering\",\"motor\",\"karoserie\",\"light_r\",\"light_l\",\"glass2\",\"palivo\",\"glass3\",\"glass1\",\"wheel_reserve_hit\",\"light_r2\",\"light_l2\",\"zbytek\",\"door_1\",\"door_2\",\"door_3\",\"door_4\",\"glass4\",\"glass5\",\"glass6\",\"hit_engine_point\",\"hit_fuel_point\",\"hit_hull_point\"]\n*/"]},{"text":"Select \"Memory\" LOD by its resolution:\n\n```sqf\nprivate _memoryLODNamedSelections = player selectionNames 1e15;\n```","code":["private _memoryLODNamedSelections = player selectionNames 1e15;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getBoneNames","createSimpleObject","hideSelection","selectionPosition","namedProperties","animationNames","allLODs","LOD resolutions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"selectionPosition","operator":null,"title":"selectionPosition","type":"command","url":"https://community.bistudio.com/wiki/selectionPosition","revid":377819,"updated":"2026-01-03T04:18:08Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns selection position in model space pertaining to the current animation in render time scope.\nWhen the default syntax is used, command searches first in Memory LOD, then in Geometry LOD, FireGeometry LOD, LandContact LOD, HitPoints LOD and finally in ViewGeometry LOD and returns the first matching find.\nThe second syntax allows to specify which one of these LODs to search in instead.\n\n> [!IMPORTANT]\n> Sometimes internally \"ViewGeometry\" could be equal to \"Geometry\", and \"FireGeometry\" could be equal to \"ViewGeometry\".\n> In order to pinpoint the actual LOD, use allLODs and LOD resolution as argument for selecting the LOD.\n>\n> Also note that similar models can have different LOD indexes, for example a soldier model differs from a model of civilian in this regard.","syntaxes":[{"syntax":"object selectionPosition selectionName","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selectionName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"selectionName: String"}],"returns":{"type":"relative position","types":["relative position"],"description":"If selection does not exist, [0, 0, 0] is returned.","text":"relative position - If selection does not exist, [0, 0, 0] is returned."},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"selectionName","types":["String"]}},{"syntax":"object selectionPosition [selectionName, LOD, returnMode]","since":"arma3 1.50","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selectionName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"selectionName: String"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- Arma 3 v2.06 `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution","types":["String","Number"],"since":"arma3 2.06","text":"LOD: String or Number - can be one of:\n- `\"Memory\"`\n- `\"Geometry\"`\n- `\"FireGeometry\"`\n- `\"LandContact\"`\n- `\"HitPoints\"`\n- Arma 3 v2.06 `\"ViewGeometry\"`\nWhen Number is used, command searches for a LOD with the similar LOD resolution"},{"name":"returnMode","type":"String","optional":true,"default":"`\"FirstPoint\"`","description":"can be one of:\n- `\"FirstPoint\"`\n- `\"AveragePoint\"`\n- `\"BoundingBox\"`","types":["String"],"since":"arma3 2.08","text":"returnMode: String - (Optional, default `\"FirstPoint\"`) can be one of:\n- `\"FirstPoint\"`\n- `\"AveragePoint\"`\n- `\"BoundingBox\"`"}],"returns":{"type":"relative position","types":["relative position"],"description":"If selection does not exist, [0, 0, 0] is returned. If returnMode is `\"BoundingBox\"`, Array of Arrays","text":"relative position - If selection does not exist, [0, 0, 0] is returned. If returnMode is `\"BoundingBox\"`, Array of Arrays"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selectionName, LOD, returnMode]","types":["Array"]}},{"syntax":"selectionPosition [object, selectionName, LODIndex, isVisual, returnMode]","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selectionName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"selectionName: String"},{"name":"LODIndex","type":"Number","optional":false,"default":null,"description":"the index of the target LOD (see allLODs)","types":["Number"],"since":null,"text":"LODIndex: Number - the index of the target LOD (see allLODs)"},{"name":"isVisual","type":"Boolean","optional":true,"default":"true","description":"true for Render, false for Simulation time scope","types":["Boolean"],"since":null,"text":"isVisual: Boolean - (Optional, default true) true for Render, false for Simulation time scope"},{"name":"returnMode","type":"String","optional":true,"default":"`\"FirstPoint\"`","description":"can be one of:\n- `\"FirstPoint\"`\n- `\"AveragePoint\"`\n- `\"BoundingBox\"`","types":["String"],"since":"arma3 2.08","text":"returnMode: String - (Optional, default `\"FirstPoint\"`) can be one of:\n- `\"FirstPoint\"`\n- `\"AveragePoint\"`\n- `\"BoundingBox\"`"}],"returns":{"type":"relative position","types":["relative position"],"description":"If selection does not exist, [0, 0, 0] is returned. If returnMode is `\"BoundingBox\"`, Array of Arrays","text":"relative position - If selection does not exist, [0, 0, 0] is returned. If returnMode is `\"BoundingBox\"`, Array of Arrays"},"form":"unary","operator":null,"left":null,"right":{"text":"[object, selectionName, LODIndex, isVisual, returnMode]","types":["Array"]}}],"examples":[{"text":"```sqf\n_inModelPosition = player selectionPosition \"head_hit\";\n```","code":["_inModelPosition = player selectionPosition \"head_hit\";"]},{"text":"```sqf\n_inModelPosition = player selectionPosition \"pelvis\";\n```","code":["_inModelPosition = player selectionPosition \"pelvis\";"]},{"text":"```sqf\n_inModelPosition = player selectionPosition \"head\";\n```","code":["_inModelPosition = player selectionPosition \"head\";"]},{"text":"```sqf\n_inModelPosition = player selectionPosition \"camera\";\n```","code":["_inModelPosition = player selectionPosition \"camera\";"]},{"text":"```sqf\nstomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"FirstPoint\"];    // [-0.774058,0.860854,-1.40365]\nstomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"AveragePoint\"];    // [-0.597142,1.35486,-1.58345]\nstomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"BoundingBox\"];    // [[-0.774058,0.860854,-2.07746],[-0.420225,1.84887,-1.08944]]\n```","code":["stomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"FirstPoint\"];\t// [-0.774058,0.860854,-1.40365]\nstomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"AveragePoint\"];\t// [-0.597142,1.35486,-1.58345]\nstomper selectionPosition [\"wheel_1_1\", \"HitPoints\", \"BoundingBox\"];\t// [[-0.774058,0.860854,-2.07746],[-0.420225,1.84887,-1.08944]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectionVectorDirAndUp","modelToWorld","selectionNames","getAllHitPointsDamage","allLODs","LOD resolutions"],"notes":[{"user":"Killzone_Kid","date":"2017-06-25T15:13:00Z","text":"Do use the filter that comes with #Syntax 2 to suit your needs. For example player has 3 selections called \"head\" and their selectionPositions are quite different from each other:\n\n```sqf\nplayer selectionPosition [\"head\", \"Memory\"];        // [0.173798,0.330415,1.37783]\nplayer selectionPosition [\"head\", \"FireGeometry\"];    // [0.14375,0.206039,1.44689]\nplayer selectionPosition [\"head\", \"HitPoints\"];    // [0.144257,0.306769,1.53471]\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectionVectorDirAndUp","operator":null,"title":"selectionVectorDirAndUp","type":"command","url":"https://community.bistudio.com/wiki/selectionVectorDirAndUp","revid":377722,"updated":"2026-01-02T09:17:58Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Searches for selection in the object model's LOD level, and returns the Direction and Up vectors in model space.","syntaxes":[{"syntax":"object selectionVectorDirAndUp [selectionName, LOD]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selectionName","type":"String","optional":false,"default":null,"description":"selection name (see selectionNames)","types":["String"],"since":null,"text":"selectionName: String - selection name (see selectionNames)"},{"name":"LOD","type":"String or Number","optional":false,"default":null,"description":"the LOD that contains the selection:\n- String - can be one of:\n  - \"Memory\"\n  - \"Geometry\"\n  - \"FireGeometry\"\n  - \"LandContact\"\n  - \"HitPoints\"\n  - \"ViewGeometry\"\n- Number - command searches for a LOD with the similar resolution (see allLODs).","types":["String","Number"],"since":null,"text":"LOD: String or Number - the LOD that contains the selection:\n- String - can be one of:\n  - \"Memory\"\n  - \"Geometry\"\n  - \"FireGeometry\"\n  - \"LandContact\"\n  - \"HitPoints\"\n  - \"ViewGeometry\"\n- Number - command searches for a LOD with the similar resolution (see allLODs)."}],"returns":{"type":"Array with [vectorDir, vectorUp]","types":["Array","vectorDir","vectorUp"],"description":"vectors are in model space - vectorDir: Vector3D - vectorUp: Vector3D","text":"Array with [vectorDir, vectorUp] - vectors are in model space\n- vectorDir: Vector3D\n- vectorUp: Vector3D"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selectionName, LOD]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player selectionVectorDirAndUp [\"drivewheel_axis\", \"FireGeometry\"] params [\"_axisVectorDir\", \"_axisVectorUp\"];\n```","code":["vehicle player selectionVectorDirAndUp [\"drivewheel_axis\", \"FireGeometry\"] params [\"_axisVectorDir\", \"_axisVectorUp\"];"]},{"text":"Get the player's barrel end (`_p1` being muzzle end's ASL position):\n\n```sqf\nonEachFrame {\n    private _weapon = currentWeapon player;\n    if (_weapon == \"\") exitWith {};\n\n    // update weapon info upon weapon switch\n    if (_weapon != player getVariable [\"last_weapon\", \"?\"]) then\n    {\n        private _cfg = configFile >> \"CfgWeapons\" >> _weapon;\n        private _model = getText(_cfg >> \"model\");\n        private _simpleObject = createSimpleObject [_model, [0,0,0], true];\n        private _offset = _simpleObject selectionPosition [getText (_cfg >> \"muzzlePos\"), \"memory\"];\n        _offset = _offset apply { [_x] };\n        deleteVehicle _simpleObject;\n        player setVariable [\"offset\", _offset];\n        player setVariable [\"last_weapon\", _weapon];\n        player setVariable [\"proxy\",\n            [\n                \"proxy:\\a3\\characters_f\\proxies\\pistol.001\",\n                \"proxy:\\a3\\characters_f\\proxies\\weapon.001\",\n                \"proxy:\\a3\\characters_f\\proxies\\launcher.001\",\n                \"proxy:\\a3\\characters_f\\proxies\\binoculars.001\"\n            ] select (([1, 4, 4096] find getNumber (_cfg >> \"type\")) + 1)\n        ];\n    };\n\n    _offset = player getVariable [\"offset\", []];\n    private _proxy = player getVariable [\"proxy\", \"\"];\n    // using LOD resolution 1 (and lod index 0) - this is not always reliable\n    // you should manually check allLODs and find the most suitable LOD (smallest res LOD usually has the best accuracy, but it might be slow too)\n    player selectionVectorDirAndUp [_proxy, 1] params [\"_vy\", \"_vz\"];\n    private _pos = selectionPosition [player, _proxy, 0];\n    private _vx = _vy vectorCrossProduct _vz;\n\n    private _mat = matrixTranspose [_vx, _vy, _vz];\n    _pos = _pos vectorAdd flatten (_mat matrixMultiply _offset);\n\n    private _p1 = player modelToWorldVisualWorld _pos;\n    private _p2 = _p1 vectorAdd (player vectorModelToWorldVisual (_vx vectorMultiply -1000));\n    drawLine3D [ASLToAGL _p1, ASLToAGL _p2, [1,0,0,1]];\n};\n```","code":["onEachFrame {\n\tprivate _weapon = currentWeapon player;\n\tif (_weapon == \"\") exitWith {};\n\n\t// update weapon info upon weapon switch\n\tif (_weapon != player getVariable [\"last_weapon\", \"?\"]) then\n\t{\n\t\tprivate _cfg = configFile >> \"CfgWeapons\" >> _weapon;\n\t\tprivate _model = getText(_cfg >> \"model\");\n\t\tprivate _simpleObject = createSimpleObject [_model, [0,0,0], true];\n\t\tprivate _offset = _simpleObject selectionPosition [getText (_cfg >> \"muzzlePos\"), \"memory\"];\n\t\t_offset = _offset apply { [_x] };\n\t\tdeleteVehicle _simpleObject;\n\t\tplayer setVariable [\"offset\", _offset];\n\t\tplayer setVariable [\"last_weapon\", _weapon];\n\t\tplayer setVariable [\"proxy\",\n\t\t\t[\n\t\t\t\t\"proxy:\\a3\\characters_f\\proxies\\pistol.001\",\n\t\t\t\t\"proxy:\\a3\\characters_f\\proxies\\weapon.001\",\n\t\t\t\t\"proxy:\\a3\\characters_f\\proxies\\launcher.001\",\n\t\t\t\t\"proxy:\\a3\\characters_f\\proxies\\binoculars.001\"\n\t\t\t] select (([1, 4, 4096] find getNumber (_cfg >> \"type\")) + 1)\n\t\t];\n\t};\n\n\t_offset = player getVariable [\"offset\", []];\n\tprivate _proxy = player getVariable [\"proxy\", \"\"];\n\t// using LOD resolution 1 (and lod index 0) - this is not always reliable\n\t// you should manually check allLODs and find the most suitable LOD (smallest res LOD usually has the best accuracy, but it might be slow too)\n\tplayer selectionVectorDirAndUp [_proxy, 1] params [\"_vy\", \"_vz\"];\n\tprivate _pos = selectionPosition [player, _proxy, 0];\n\tprivate _vx = _vy vectorCrossProduct _vz;\n\n\tprivate _mat = matrixTranspose [_vx, _vy, _vz];\n\t_pos = _pos vectorAdd flatten (_mat matrixMultiply _offset);\n\n\tprivate _p1 = player modelToWorldVisualWorld _pos;\n\tprivate _p2 = _p1 vectorAdd (player vectorModelToWorldVisual (_vx vectorMultiply -1000));\n\tdrawLine3D [ASLToAGL _p1, ASLToAGL _p2, [1,0,0,1]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectionPosition","selectionNames","allLODs"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"selectLeader","operator":null,"title":"selectLeader","type":"command","url":"https://community.bistudio.com/wiki/selectLeader","revid":321115,"updated":"2022-05-13T14:14:32Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Select the group's leader. Group locality can be checked with local command and group ownership with groupOwner command.\n\n> [!IMPORTANT]\n> An invalid combination can be provided to this command, e.g *unitName* **not** being part of *group*. In that case:\n> - *unitName* will be leader of *group*, but will not be able to command them\n> - if *unitName* is deleted or killed, leader of *group* will be objNull and will not automatically be reassigned.","syntaxes":[{"syntax":"group selectLeader unitName","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\ngroup player selectLeader player;\n```","code":["group player selectLeader player;"]},{"text":"Make unit a leader from server:\n\n```sqf\n[group _unit, _unit] remoteExec [\"selectLeader\", groupOwner group _unit];\n```","code":["[group _unit, _unit] remoteExec [\"selectLeader\", groupOwner group _unit];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFollow","doFollow","formationLeader","formLeader","isFormationLeader","leader","setLeader"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"selectMax","operator":null,"title":"selectMax","type":"command","url":"https://community.bistudio.com/wiki/selectMax","revid":377099,"updated":"2026-01-01T09:58:04Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the array element with maximum numerical value. Engine solution to BIS_fnc_greatestNum and BIS_fnc_findExtreme. Therefore it is expected that supplied array consists of Numbers only. Booleans however are also supported and will be evaluated as Numbers: true - 1, false - 0.  nil value treated as 0.\n\n> [!WARNING]\n> Other non Number elements (not recommended) will be evaluated as 0 and **Bad conversion: scalar** message will be logged into .rpt.","syntaxes":[{"syntax":"selectMax array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"array: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":"element with maximum numerical value","text":"Number - element with maximum numerical value"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_max = selectMax [1,2,3,4,5]; //5\n```","code":["_max = selectMax [1,2,3,4,5]; //5"]},{"text":"```sqf\n// Same as, for example: \n_max = _a max _b max _c max _d;\n// Only faster:\n_max = selectMax [_a,_b,_c,_d];\n```","code":["// Same as, for example: \n_max = _a max _b max _c max _d;\n// Only faster:\n_max = selectMax [_a,_b,_c,_d];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectMin","min","max","selectRandom","select","selectRandomWeighted"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"selectMin","operator":null,"title":"selectMin","type":"command","url":"https://community.bistudio.com/wiki/selectMin","revid":377100,"updated":"2026-01-01T09:58:18Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the array element with minimum numerical value. Engine solution to BIS_fnc_lowestNum and BIS_fnc_findExtreme. Therefore it is expected that supplied array consists of Numbers only.  Booleans however are also supported and will be evaluated as Numbers: true - 1, false - 0. nil value treated as 0.\n\n> [!WARNING]\n> Other non Number elements (not recommended) will be evaluated as 0 and **Bad conversion: scalar** message will be logged into .rpt.","syntaxes":[{"syntax":"selectMin array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"array: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":"element with minimum numerical value","text":"Number - element with minimum numerical value"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_min = selectMin [1,2,3,4,5]; //1\n```","code":["_min = selectMin [1,2,3,4,5]; //1"]},{"text":"```sqf\n// Same as, for example: \n_min = _a min _b min _c min _d;\n// Only faster:\n_min = selectMin [_a,_b,_c,_d];\n```","code":["// Same as, for example: \n_min = _a min _b min _c min _d;\n// Only faster:\n_min = selectMin [_a,_b,_c,_d];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectMax","min","max","selectRandom","select","selectRandomWeighted"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"selectNoPlayer","operator":null,"title":"selectNoPlayer","type":"command","url":"https://community.bistudio.com/wiki/selectNoPlayer","revid":369361,"updated":"2024-09-03T18:43:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Switches player to no unit, makes player return objNull.","syntaxes":[{"syntax":"selectNoPlayer","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Single player:\n\n```sqf\nselectNoPlayer;\nhint str player; // <NULL-object>\n```\n\nRough multiplayer emulation:\n\n```sqf\n_noPlayer = createGroup sideLogic createUnit [\n    \"Logic\",\n    [0,0,1000],\n    [],\n    0,\n    \"NONE\"\n];\nselectPlayer _noPlayer;\nhint str player; // L Charlie 4-3:1 (KK)\n```","code":["selectNoPlayer;\nhint str player; // <NULL-object>","_noPlayer = createGroup sideLogic createUnit [\n\t\"Logic\",\n\t[0,0,1000],\n\t[],\n\t0,\n\t\"NONE\"\n];\nselectPlayer _noPlayer;\nhint str player; // L Charlie 4-3:1 (KK)"]}],"multiplayer":"Does **not** work in multiplayer.","problems":null,"aliases":[],"see_also":["selectPlayer"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"selectPlayer","operator":null,"title":"selectPlayer","type":"command","url":"https://community.bistudio.com/wiki/selectPlayer","revid":363391,"updated":"2024-03-29T17:43:01Z","groups":["Object Manipulation","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Move player into given unit. Some usage advices:\n- Avoid using selectPlayer on editor-placed units in multiplayer, as it may, on occasion, lead to some undefined behaviour.\n- If you need to selectPlayer into another unit, consider creating a unit dynamically.\n\n> [!NOTE]\n> Before Arma 3 it was possible to selectPlayer another player-controlled unit, leading to control issues.\n\n> [!WARNING]\n> Creating and immediately selecting player into newly created unit could cause all sort of problems due to possible delay in unit initialisation.\n> Give the unit some time to propagate properly on the network before using this command on it.","syntaxes":[{"syntax":"selectPlayer unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nselectPlayer bob;\n```","code":["selectPlayer bob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectNoPlayer","remoteControl","Team Switch","switchCamera","teamSwitch","enableTeamSwitch"],"notes":[{"user":"Killzone_Kid","date":"2015-06-24T23:34:00Z","text":"> [!IMPORTANT]\n> Most of the notes below do not apply to Arma 3 anymore."},{"user":"SnowSky","date":"2010-03-02T23:09:00Z","text":"**This command has significant effects on locality**!\n\nNotes on locality issues with selectPlayer in multiplayer environments:\n\n1) If you switch to a unit that's not local, control over movement will not be given to you immediately. For example, if you switch to an AI unit whose leader is a player, you will not be able to control the movement of your new avatar, as its control remains with the leader unit. You will however be able to look around while the unit walks automatically.\n\n2) The identity of units are not transferred properly: If your old unit dies, this will count for your stats. Your old unit might remain identifiable as you (if you aim at the unit you see your own name). Your new unit will keep it is name, face and voice (face can be set dynamically, but name, voice and glasses have to be defined before mission start in the description.ext). When chatting, not the name of your original identity, but the identity of the transferred to person will show.\n\nThose 2 Points were for ArmA I, I am currently analyzing the behaviour in Arma 2 with version 1.08 + OA 1.57\n\nSo with Arma 2, you still have to keep an eye on locality (otherwise the AI will controll the unit you are), but there are cool possibilities now: if you do a \"selectPlayer unitVarName\",the unit takes your identity (with name, voice, face and glasses) - and your identity is also visible on other clients!\n\nBut you have to remember that your old unit will stay with your Identity. Dies the old unit, the stats count it. An other thing you have to pay attention is the Death for your new unit - you have to register an EventHandler, otherwise you will stay in your dead unit, and also the MenuOption Respawn won't help you out! 3.Jan. 2011\n\n3) If you do a selectPlayer call, join,joinSilent,joinAs,joinAsSilent wont work anymore correctly. Means: Your unit joins the other group AND your unit will be local to the other group. so at the moment you can use selectPlayer only as a single human player in a group. In the later day I will try what happens if both human players are units by selectPlayer, and both join the same group (till yet tried with one selectPlayer unit and one originUnit)\n14.May 2011\n\nTried to create ingame a group with a selectPlayer Unit (on both clients), and joint the new squad. The result was, the group was local to the client who created the group, so after that, all other units that join that Group are - as you may think already, local to that single client. 18.May 2011"},{"user":"Besselinksjm","date":"2010-06-17T16:19:00Z","text":"4) After switching to a unit that's not local, the unit will remain local to you after switching back. For example, if we have units A and B, and a client starts as unit A and unit B is AI under server control. If you switch to unit B, it will take some time, but eventually you can control the movement of unit B (see (1) above). Now if you switch back to unit A, unit B will remain local to you, the player. Any server-side scripts which try to execute local arguments – such as doMove – will fail."},{"user":"Kju","date":"2010-06-17T17:20:00Z","text":"A working implementation can be found at [A&S ProMode dev-heaven repo](http://dev-heaven.net/projects/clanbase-aas/repository/revisions/master/entry/core/cb_aas_20_ChernarusTemplate.Utes/changePlayerModel.sqf), acc guest, pw guest or at [pastebin](http://pastebin.jonasscholz.de/834).\n\nBe careful to learn all the pitfalls and things you need to take into consideration to have this working in MP."},{"user":"EUTWtrnapster","date":"2014-03-09T19:06:00Z","text":"Arma 3 (v1.13): In MP the Identity and the name carries over to the new Unit but not in SP. Use setName+profileName to set the name in SP."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"selectRandom","operator":null,"title":"selectRandom","type":"command","url":"https://community.bistudio.com/wiki/selectRandom","revid":377101,"updated":"2026-01-01T09:58:32Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a random element from the given array. Engine solution to BIS_fnc_selectRandom","syntaxes":[{"syntax":"selectRandom array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"}],"returns":{"type":"Anything","types":["Anything"],"description":"random selected value or Nothing if array is empty","text":"Anything - random selected value or Nothing if array is empty"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Anything"]}}],"examples":[{"text":"```sqf\n_randomElement = selectRandom [1,2,3,4,5];\n```","code":["_randomElement = selectRandom [1,2,3,4,5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectRandomWeighted","random","select","selectMin","selectMax"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"selectRandomWeighted","operator":null,"title":"selectRandomWeighted","type":"command","url":"https://community.bistudio.com/wiki/selectRandomWeighted","revid":377677,"updated":"2026-01-02T09:02:40Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.76"}],"since":{"game":"arma3","name":"Arma 3","version":"1.76"},"arma3_since":"1.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a random element from the given array according to assigned weights. Engine solution to BIS_fnc_selectRandomWeighted. A few notes:\n- Negative weights are not supported\n- If an item's weight is 0, the item is ignored\n- The weights don't have to total to 1\n- If numbers of items and weights do not match, the shortest array is used\n- A single array Syntax is slightly faster than Alt Syntax","syntaxes":[{"syntax":"selectRandomWeighted valuesAndWeights","since":null,"effect":null,"exec":null,"params":[{"name":"valuesAndWeights","type":"Array with [valueN, weightN]","optional":false,"default":null,"description":"Array with [valueN, weightN]\n- valueN: Anything - weighted value\n- weightN: Number - values relative weight","types":["Array"],"since":null,"text":"valuesAndWeights: Array with [valueN, weightN]\n- valueN: Anything - weighted value\n- weightN: Number - values relative weight"}],"returns":{"type":"Anything","types":["Anything"],"description":"random weighted value or Nothing if array is empty or all weights are 0","text":"Anything - random weighted value or Nothing if array is empty or all weights are 0"},"form":"unary","operator":null,"left":null,"right":{"text":"valuesAndWeights","types":["Array"]}},{"syntax":"values selectRandomWeighted weights","since":null,"effect":null,"exec":null,"params":[{"name":"values","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"values: Array of Anything"},{"name":"weights","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"weights: Array of Numbers"}],"returns":{"type":"Anything","types":["Anything"],"description":"random weighted value or Nothing if any of arrays is empty or all weights are 0","text":"Anything - random weighted value or Nothing if any of arrays is empty or all weights are 0"},"form":"binary","operator":null,"left":{"text":"values","types":["Array","Anything"]},"right":{"text":"weights","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nprivate _randomWeightedElement = selectRandomWeighted [1,0.1,2,0.2,3,1.3,4,2.4,5,7.5];\n```","code":["private _randomWeightedElement = selectRandomWeighted [1,0.1,2,0.2,3,1.3,4,2.4,5,7.5];"]},{"text":"```sqf\nprivate _randomWeightedElement = [1,2,3,4,5] selectRandomWeighted [0.1,0.2,1.3,2.4,7.5];\n```","code":["private _randomWeightedElement = [1,2,3,4,5] selectRandomWeighted [0.1,0.2,1.3,2.4,7.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["random","select","selectRandom","selectMin","selectMax"],"notes":[{"user":"Killzone_Kid","date":"2017-06-26T19:17:00Z","text":"A 100000 runs of the following code:\n\n```sqf\n_values = [0,1,2,3,4,5,6,7,8,9];\n_weights = [0.109,0.65,0.01,1.01,1.24,0,1.59,0.09,1.15,0.55];\n_result = _values selectRandomWeighted _weights;\n```\n\nGave this result:\n\n```\n0 - 0\n0.01 - 144\n0.09 - 1409\n0.109 - 1633\n0.55 - 8673\n0.65 - 10127\n1.01 - 15668\n1.15 - 18059\n1.24 - 19518\n1.59 - 24769\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.76","Scripting Commands"]},{"name":"selectThrowable","operator":null,"title":"selectThrowable","type":"command","url":"https://community.bistudio.com/wiki/selectThrowable","revid":369741,"updated":"2024-10-08T15:05:51Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects current throwable, which will be launched if the user presses <kbd>G</kbd>.","syntaxes":[{"syntax":"unit selectThrowable throwable","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"throwable","type":"String","optional":false,"default":null,"description":"either the name of the throwable magazine or the name of the throwable muzzle","types":["String"],"since":null,"text":"throwable: String - either the name of the throwable magazine or the name of the throwable muzzle"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"throwable","types":["String"]}}],"examples":[{"text":"```sqf\nplayer selectThrowable \"SmokeShellGreen\";\n```","code":["player selectThrowable \"SmokeShellGreen\";"]},{"text":"```sqf\nplayer selectThrowable \"SmokeShellGreenMuzzle\";\n```","code":["player selectThrowable \"SmokeShellGreenMuzzle\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["throwables","isThrowable","currentThrowable","selectWeapon","currentWeapon","currentMagazine","currentMuzzle","BIS_fnc_isThrowable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"selectWeapon","operator":null,"title":"selectWeapon","type":"command","url":"https://community.bistudio.com/wiki/selectWeapon","revid":373007,"updated":"2025-03-11T23:11:21Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.27"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Selects the given weapon.\n\n> [!NOTE]\n> Passing empty string will not deselect current weapon. Use 'SwitchWeapon' action instead:\n>\n> ```sqf\n> player action [\"SwitchWeapon\", player, player, -1]\n> ```","syntaxes":[{"syntax":"unitName selectWeapon muzzleName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"muzzleName","type":"String","optional":false,"default":null,"description":"name of the weapon or muzzle\n\n> [!IMPORTANT]\n> For weapons that have **more than one muzzle**, you have to input the **muzzleName** and not the **weaponName**.\n> - In Operation Flashpoint, in most cases, both names are the same. But check.\n> - In Armed Assault the weaponNames and muzzleNames are different.\n> - For muzzle names see CfgWeapons.","types":["String"],"since":null,"text":"muzzleName: String - name of the weapon or muzzle\n\n> [!IMPORTANT]\n> For weapons that have **more than one muzzle**, you have to input the **muzzleName** and not the **weaponName**.\n> - In Operation Flashpoint, in most cases, both names are the same. But check.\n> - In Armed Assault the weaponNames and muzzleNames are different.\n> - For muzzle names see CfgWeapons."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"muzzleName","types":["String"]}},{"syntax":"unit selectWeapon [weapon, muzzle, firemode]","since":"arma3 2.08","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person. This argument has to be local, or it can be remote when executed on the server","types":["Object"],"since":null,"text":"unit: Object - person. This argument has to be local, or it can be remote when executed on the server"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"name of the weapon, personal or vehicle's weapon (see weaponState)","types":["String"],"since":null,"text":"weapon: String - name of the weapon, personal or vehicle's weapon (see weaponState)"},{"name":"muzzle","type":"String","optional":false,"default":null,"description":"name of the selected muzzle (see weaponState)","types":["String"],"since":null,"text":"muzzle: String - name of the selected muzzle (see weaponState)"},{"name":"firemode","type":"String","optional":false,"default":null,"description":"name of the firemode (see weaponState)","types":["String"],"since":null,"text":"firemode: String - name of the firemode (see weaponState)"}],"returns":{"type":"Boolean or Nothing","types":["Boolean","Nothing"],"description":"true on success, false on failure, Nothing when the call to the command is dispatched over network","text":"Boolean or Nothing - true on success, false on failure, Nothing when the call to the command is dispatched over network"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[weapon, muzzle, firemode]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldier1 selectWeapon \"LAWLauncher\";\n```","code":["_soldier1 selectWeapon \"LAWLauncher\";"]},{"text":"```sqf\nplayer selectWeapon \"M203Muzzle\";\n```","code":["player selectWeapon \"M203Muzzle\";"]},{"text":"```sqf\nplayer selectWeapon [\"arifle_MX_GL_ACO_F\", \"arifle_MX_GL_ACO_F\", \"FullAuto\"];\n```","code":["player selectWeapon [\"arifle_MX_GL_ACO_F\", \"arifle_MX_GL_ACO_F\", \"FullAuto\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fire","forceWeaponFire","primaryWeapon","handgunWeapon","secondaryWeapon","weapons","ArmA: Actions","isSwitchingWeapon"],"notes":[{"user":"Dr_Eyeball","date":"2008-08-05T09:49:00Z","text":"Rather than simply using selectWeapon to select your default weapon after adding them to your player, it is recommended you use a script instead similar to the following, which caters for multiple muzzles:\n\nSelectWeapon.sqf\n\n```sqf\n// Desc: select default weapon & handle multiple muzzles\nif (count weapons player > 0) then\n{\n    private ['_type', '_muzzles'];\n\n    _type = ((weapons player) select 0);\n    // check for multiple muzzles (eg: GL)\n    _muzzles = getArray (configFile >> \"cfgWeapons\" >> _type >> \"muzzles\");\n\n    if (count _muzzles > 1) then\n    {\n        player selectWeapon (_muzzles select 0);\n    }\n    else\n    {\n        player selectWeapon _type;\n    };\n};\n```"},{"user":"MaestrO.fr","date":"2010-03-22T15:45:00Z","text":"Can be used with primaryWeapon to select the primary weapon.\nAn example with muzzle care (see Dr_EyeBall note) :\n\n```sqf\nif ((primaryWeapon player) != \"\") then\n{\n    private ['_type', '_muzzles'];\n\n    _type = primaryWeapon player;\n    // check for multiple muzzles (eg: GL)\n    _muzzles = getArray (configFile >> \"cfgWeapons\" >> _type >> \"muzzles\");\n\n    if (count _muzzles > 1) then\n    {\n        player selectWeapon (_muzzles select 0);\n    }\n    else\n    {\n        player selectWeapon _type;\n    };\n};\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Operation Flashpoint version 1.27","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"selectWeaponTurret","operator":null,"title":"selectWeaponTurret","type":"command","url":"https://community.bistudio.com/wiki/selectWeaponTurret","revid":377503,"updated":"2026-01-02T06:49:33Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Selects the given weapon on the specified turret. Use turret path [-1] for the driver's turret.","syntaxes":[{"syntax":"vehicle selectWeaponTurret [weapon, turretPath, muzzle, firemode]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"weapon class name or (since Arma 3 v1.64) muzzle class name","types":["String"],"since":null,"text":"weapon: String - weapon class name or (since Arma 3 v1.64) muzzle class name"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"muzzle","type":"String","optional":true,"default":null,"description":"muzzle name","types":["String"],"since":"arma3 2.08","text":"muzzle: String - (Optional) muzzle name"},{"name":"firemode","type":"String","optional":true,"default":null,"description":"firemode name","types":["String"],"since":"arma3 2.08","text":"firemode: String - (Optional) firemode name"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[weapon, turretPath, muzzle, firemode]","types":["Array"]}}],"examples":[{"text":"```sqf\nMBT_Kuma selectWeaponTurret [\"LMG_coax\",[0]];\n```","code":["MBT_Kuma selectWeaponTurret [\"LMG_coax\",[0]];"]},{"text":"```sqf\nKamysh selectWeaponTurret [\"missiles_titan\", [0], \"missiles_titan\", \"topdown\"];\n```","code":["Kamysh selectWeaponTurret [\"missiles_titan\", [0], \"missiles_titan\", \"topdown\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeWeaponTurret","weaponState","turretLocal","addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","currentMagazineDetailTurret","currentMagazineTurret","currentWeaponTurret","addWeaponTurret"],"notes":[{"user":"Killzone_Kid","date":"2017-02-13T16:54:00Z","text":"The command will treat weapon or muzzle param like a weapon first. If no such weapon is found then it will try to find muzzle with such name. For example AMV-7 Marshall APC has main gun \"autocannon_40mm_CTWS\" which has 2 muzzles \"HE\" and \"AP\". Default muzzle is \"HE\". So if you try to select weapon by the name \"autocannon_40mm_CTWS\" you will always get \"HE\" muzzle selected. However if you pass \"AP\" as param, it will correctly select \"AP\" muzzle, since no \"AP\" weapon exists on this turret it will continue searching for a muzzle with this name and will find it eventually."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"sendAUMessage","operator":null,"title":"sendAUMessage","type":"command","url":"https://community.bistudio.com/wiki/sendAUMessage","revid":321116,"updated":"2022-05-13T14:14:53Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send the command to the list of clients.","syntaxes":[{"syntax":"sendAUMessage [clientList, command]","since":null,"effect":null,"exec":null,"params":[{"name":"clientList","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"clientList: Array"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[clientList, command]","types":["Array"]}}],"examples":[{"text":"```sqf\nsendAUMessage [[dpnid1, dpnid2], \"ConnectTo: 192.168.1.66\"];\n```","code":["sendAUMessage [[dpnid1, dpnid2], \"ConnectTo: 192.168.1.66\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sendUDPMessage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"sendSimpleCommand","operator":null,"title":"sendSimpleCommand","type":"command","url":"https://community.bistudio.com/wiki/sendSimpleCommand","revid":336305,"updated":"2022-12-21T11:10:14Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sends a simple command to the vehicle's driver / gunner (air vehicles ignore it). See also vehicleMoveInfo.\n\n> [!IMPORTANT]\n> Doesn't seem to work if AI driver is alone, needs another unit in the vehicle (could be another AI or player) that is set as setEffectiveCommander. If driver is effectiveCommander it will refuse any drive commands.\n\n> [!NOTE]\n> **Arma 3:** Due to some sort of a bug when vehicle is ordered turning (\"LEFT\" or \"RIGHT\"), it locks the vehicle ability to respond to any other commands properly. Always use \"STOPTURNING\" to cancel turning before issuing other move commands\n\n| Gunner commands | Driver Move commands | Driver Turn commands |\n|---|---|---|\n| - `\"FIRE\"`<br>- `\"CEASE FIRE\"`<br>- `\"MANUAL FIRE\"`<br>- `\"CANCEL MANUAL FIRE\"`<br>- `\"KEY FIRE\"` | - `\"FORWARD\"` - move forward<br>- `\"FAST\"` - move forward, fast<br>- `\"SLOW\"` - move forward, slow<br>- `\"STOP\"` - stop moving forward or backward<br>- `\"BACK\"` - move backward<br>- `\"KEY UP\"`<br>- `\"KEY DOWN\"`<br>- `\"KEY FAST\"`<br>- `\"KEY SLOW\"` | - `\"LEFT\"` - turn left, while moving or not<br>- `\"RIGHT\"` - turn right, while moving or not<br>- Arma 3 v1.78 `\"STOPTURNING\"` cancel turning (special case, normally would be called by the engine when LEFT or RIGHT turn key is released by the player) |","syntaxes":[{"syntax":"vehicleName sendSimpleCommand command","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player sendSimpleCommand \"STOP\";\n```","code":["vehicle player sendSimpleCommand \"STOP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vehicleMoveInfo","useAISteeringComponent","effectiveCommander","setEffectiveCommander","enableAI","disableAI","enableAIFeature","enableSentences"],"notes":[{"user":"Ceeeb","date":"2007-04-16T04:52:00Z","text":"Valid commands include: \"FORWARD\", \"SLOW\", \"FAST\" \"BACK\", \"LEFT\", \"RIGHT\", \"STOP\", \"FIRE\", \"CEASE FIRE\", \"MANUAL FIRE\", \"CANCEL MANUAL FIRE\". There may be more.\n\nOnly vehicles crewed by a player can use sendSimpleCommand."},{"user":"Killzone_Kid","date":"2014-01-26T15:58:00Z","text":"Other commands that work: \"KEY FIRE\", \"KEY FAST\", \"KEY SLOW\", \"KEY DOWN\", \"KEY UP\". These will simulate key presses.\n\nIn Arma 3 player doesn't always need to be in the vehicle to give commands."}],"categories":[]},{"name":"sendTask","operator":null,"title":"sendTask","type":"command","url":"https://community.bistudio.com/wiki/sendTask","revid":330641,"updated":"2022-10-03T11:04:22Z","groups":["Briefing","Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a new AI task (subtask of parentTask). Type is name of registered task type.","syntaxes":[{"syntax":"sender sendTask [receiver,[type] or [type,parentTask],priority,name1,value1,name2,value2,...]","since":null,"effect":null,"exec":null,"params":[{"name":"sender","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"sender:  Team Member"},{"name":"[receiver,[type] or [type,parentTask],priority,name1,value1,name2,value2,...]: Array","type":null,"optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[receiver,[type] or [type,parentTask],priority,name1,value1,name2,value2,...]: Array"}],"returns":{"type":"Task","types":["Task"],"description":null,"text":"Task"},"form":"binary","operator":null,"left":{"text":"sender","types":["Team Member"]},"right":{"text":"[receiver,[type] or [type,parentTask],priority,name1,value1,name2,value2,...]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sendTaskResult","operator":null,"title":"sendTaskResult","type":"command","url":"https://community.bistudio.com/wiki/sendTaskResult","revid":363249,"updated":"2024-03-26T10:51:23Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send a result of the task to the task sender.","syntaxes":[{"syntax":"task sendTaskResult [state,result,sentence]","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"[state,result,sentence]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[state,result,sentence]: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"[state,result,sentence]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sendUDPMessage","operator":null,"title":"sendUDPMessage","type":"command","url":"https://community.bistudio.com/wiki/sendUDPMessage","revid":351538,"updated":"2023-12-06T23:45:43Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send message to given address using UDP protocol. Returns false if the message has not been delivered\n\n> [!WARNING]\n> Disabled in retail version (see the talk page for more info).","syntaxes":[{"syntax":"sendUDPMessage [ip, port, message]","since":null,"effect":null,"exec":null,"params":[{"name":"ip","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"ip: String"},{"name":"port","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"port: Number"},{"name":"message","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"message: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[ip, port, message]","types":["Array"]}}],"examples":[{"text":"```sqf\n_bool = sendUDPMessage [\"192.168.0.1\", 2302, \"Here goes you message...\"];\n```","code":["_bool = sendUDPMessage [\"192.168.0.1\", 2302, \"Here goes you message...\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sendAUMessage"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sentencesEnabled","operator":null,"title":"sentencesEnabled","type":"command","url":"https://community.bistudio.com/wiki/sentencesEnabled","revid":349008,"updated":"2023-11-08T14:47:05Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for enableSentences.","syntaxes":[{"syntax":"sentencesEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if sentences are enabled","text":"Boolean - returns true if sentences are enabled"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (sentencesEnabled) then\n{\n    hint \"sentences are enabled; changing that now\";\n    enableSentences false;\n};\n```","code":["if (sentencesEnabled) then\n{\n\thint \"sentences are enabled; changing that now\";\n\tenableSentences false;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableSentences"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"serverCommand","operator":null,"title":"serverCommand","type":"command","url":"https://community.bistudio.com/wiki/serverCommand","revid":377886,"updated":"2026-01-04T16:30:46Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Executes the given server command. Requires you to be **logged-in** admin as client to execute on a client, or provide the **serverCommandPassword** with the serverCommand execution as client/server to basically also get logged in admin permissions.\n\n> [!NOTE]\n> - Available commands for execution can be found with serverCommandAvailable\n> - Commands that can be executed can be found with serverCommandExecutable\n\n> [!IMPORTANT]\n> If serverCommand is executed on a client, it must be executed from UI context, such as \"onButtonDown\" or similar events (see User Interface Event Handlers).","syntaxes":[{"syntax":"serverCommand command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"false if a non valid command is used (\"#blah\"), false otherwise (was always true before Arma 3 v1.40)","text":"Boolean - false if a non valid command is used (\"#blah\"), false otherwise (was always true before Arma 3 v1.40)"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String"]}},{"syntax":"password serverCommand command","since":"arma3 1.40","effect":null,"exec":"server","params":[{"name":"password","type":"String","optional":false,"default":null,"description":"case-sensitive password defined in server config with `serverCommandPassword` param","types":["String"],"since":null,"text":"password: String - case-sensitive password defined in server config with `serverCommandPassword` param"},{"name":"command","type":"String","optional":false,"default":null,"description":"server command","types":["String"],"since":null,"text":"command: String - server command"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"false if command failed at some stage. true doesn't mean that command succeeded.","text":"Boolean - false if command failed at some stage. true doesn't mean that command succeeded."},"form":"binary","operator":null,"left":{"text":"password","types":["String"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\nserverCommand \"#logout\";\n```","code":["serverCommand \"#logout\";"]},{"text":"Create button on the main map which will show userlist to anyone who clicks on it:\n\n```sqf\nwith uiNamespace do \n{\n    private _ctrl = findDisplay 12 ctrlCreate [\"RscButton\", -1];\n    _ctrl ctrlSetPosition [0,0,0.5,0.1];\n    _ctrl ctrlSetText \"USERLIST\";\n    _ctrl ctrlCommit 0;\n    _ctrl ctrlAddEventHandler [\"ButtonDown\", \n    {\n        serverCommand \"#userlist\";\n    }];\n};\n```","code":["with uiNamespace do \n{\n\tprivate _ctrl = findDisplay 12 ctrlCreate [\"RscButton\", -1];\n\t_ctrl ctrlSetPosition [0,0,0.5,0.1];\n\t_ctrl ctrlSetText \"USERLIST\";\n\t_ctrl ctrlCommit 0;\n\t_ctrl ctrlAddEventHandler [\"ButtonDown\", \n\t{\n\t\tserverCommand \"#userlist\";\n\t}];\n};"]},{"text":"```sqf\nserverCommand format [\"#kick %1\",_name];\n```","code":["serverCommand format [\"#kick %1\",_name];"]},{"text":"```sqf\nprivate _passwordWasOK = \"MyServerCommandPassword\" serverCommand \"#lock\";\n```","code":["private _passwordWasOK = \"MyServerCommandPassword\" serverCommand \"#lock\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["serverCommandAvailable","serverCommandExecutable","admin","isUIContext"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.05","Introduced with Arma 3 version 1.40","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"serverCommandAvailable","operator":null,"title":"serverCommandAvailable","type":"command","url":"https://community.bistudio.com/wiki/serverCommandAvailable","revid":370060,"updated":"2024-10-29T14:40:43Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if given serverCommand is available on current machine, false if not.\n\n> [!NOTE]\n> Execution via RCon is basically being **logged-in** as admin in terms of permissions.\n\n| Arma 3 Multiplayer Server Commands | Available to |  |  |  |\n|---|---|---|---|---|\n| Client | Voted Admin | Logged Admin | Server Host |  |\n| `1. login`, `1. userlist`, `1. beclient`, `1. vote` | ✓ | ✓ | ✓ | ✓ |\n| `1. kick`, `1. debug` | ✗ | ✓ | ✓ | ✓ |\n| `1. lock`, `1. unlock`, `1. maxping`, `1. maxdesync`, `1. maxpacketloss` | ✗ | ✗ | ✓ | ✓ |\n| `1. logout`, `1. restart`, `1. mission`, `1. missions`, `1. reassign`, `1. monitor`, `1. init` | ✗ | ✓ | ✓ | ✗ |\n| `1. shutdown`, `1. restartserver`, `1. restartserveraftermission`, `1. shutdownaftermission`, `1. dctimeout`, `1. exec`, `1. monitords`, `1. beserver` | ✗ | ✗ | ✓ | ✗ |\n| `1. logentities`, `1. exportjipqueue` | ✗ | ✗ | ✓ | ✓ |\n| Profiling type builds only: `1. captureframe`, `1. captureslowframe` | ✗ | ✗ | ✓ | ✓ |\n\nTo check if a server command can be executed in the current environment, use serverCommandExecutable.\n\n> [!NOTE]\n> The table above does not apply to the command's password variant on a dedicated server as everything is available to it.","syntaxes":[{"syntax":"serverCommandAvailable command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\n_can = serverCommandAvailable \"#kick\";\n```","code":["_can = serverCommandAvailable \"#kick\";"]},{"text":"```sqf\nif (serverCommandAvailable \"#logout\") then \n{\n    hint \"You are a some sort of admin\";\n};\n```","code":["if (serverCommandAvailable \"#logout\") then \n{\n\thint \"You are a some sort of admin\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["serverCommand","serverCommandExecutable","admin","isServer","Multiplayer Server Commands"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"serverCommandExecutable","operator":null,"title":"serverCommandExecutable","type":"command","url":"https://community.bistudio.com/wiki/serverCommandExecutable","revid":369186,"updated":"2024-09-03T10:34:46Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the serverCommand can be performed on the machine and in this exact environment, otherwise false. serverCommand can be executed only from User Interface Event Handlers, and this command also checks if that's the case.","syntaxes":[{"syntax":"serverCommandExecutable command","since":null,"effect":null,"exec":null,"params":[{"name":"command","type":"String","optional":false,"default":null,"description":"see Multiplayer Server Commands for all available commands","types":["String"],"since":null,"text":"command: String - see Multiplayer Server Commands for all available commands"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\n_canKick = serverCommandAvailable \"#kick\";\n```","code":["_canKick = serverCommandAvailable \"#kick\";"]},{"text":"Add button to the main map to lock server, which could only be activated by admin:\n\n```sqf\nwith uiNamespace do {\n    ctrl = findDisplay 12 ctrlCreate [\"RscButton\", -1];\n    ctrl ctrlSetPosition [0, 0, 0.5, 0.1];\n    ctrl ctrlCommit 0;\n    ctrl ctrlSetText \"LOCK SERVER\";\n    ctrl ctrlAddEventHandler [\"ButtonDown\",\n    {    \n        if (serverCommandExecutable \"#lock\") then {\n            serverCommand \"#lock\";\n        } else {\n            hint \"You need to be logged in as admin to do this\";\n        };\n    }];\n};\n```","code":["with uiNamespace do {\n\tctrl = findDisplay 12 ctrlCreate [\"RscButton\", -1];\n\tctrl ctrlSetPosition [0, 0, 0.5, 0.1];\n\tctrl ctrlCommit 0;\n\tctrl ctrlSetText \"LOCK SERVER\";\n\tctrl ctrlAddEventHandler [\"ButtonDown\",\n\t{\t\n\t\tif (serverCommandExecutable \"#lock\") then {\n\t\t\tserverCommand \"#lock\";\n\t\t} else {\n\t\t\thint \"You need to be logged in as admin to do this\";\n\t\t};\n\t}];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["serverCommand","serverCommandAvailable","Multiplayer Server Commands"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"serverName","operator":null,"title":"serverName","type":"command","url":"https://community.bistudio.com/wiki/serverName","revid":319671,"updated":"2022-05-13T09:24:40Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns name of the hosting server in MP, \"\" in SP.","syntaxes":[{"syntax":"serverName","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"Welcome to the %1 server!\", serverName];\n```","code":["hint format [\"Welcome to the %1 server!\", serverName];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["worldName","briefingName","missionName","worldSize"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"serverNamespace","operator":null,"title":"serverNamespace","type":"command","url":"https://community.bistudio.com/wiki/serverNamespace","revid":351793,"updated":"2024-01-11T04:51:36Z","groups":["Namespaces","Variables","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Returns server's namespace.\nThis namespace is only available on the server for the server's uptime duration (same as uiNamespace).\n\nAll server event handlers, which are available in server config, use this namespace.","syntaxes":[{"syntax":"serverNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Namespace","Nothing"],"description":null,"text":"Namespace on the server, Nothing on clients or in single-player."},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (isServer) then\n{\n    hint str allVariables serverNamespace;\n}\nelse\n{\n    hint \"you do not have permission!\";\n};\n```","code":["if (isServer) then\n{\n\thint str allVariables serverNamespace;\n}\nelse\n{\n\thint \"you do not have permission!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","setVariable","getVariable","allVariables"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"serverTime","operator":null,"title":"serverTime","type":"command","url":"https://community.bistudio.com/wiki/serverTime","revid":364976,"updated":"2024-07-04T17:33:25Z","groups":["Time","Mission Information","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Returns the time since latest server (re)start in seconds.\n\n> [!IMPORTANT]\n> The time returned is different to the time returned by time and diag_tickTime commands on server.\n\n> [!NOTE]\n> Known issues before Arma 3 v1.86:\n> both server and clients showed the same value when synced, but the only time it was not synced was on the server, right after server restart and only for the first 300 seconds. Client-side it was synced from the start.","syntaxes":[{"syntax":"serverTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"Synced server time : %1\", serverTime];\n```","code":["hint format [\"Synced server time : %1\", serverTime];"]}],"multiplayer":"- In singleplayer: Arma 3 v2.18 returns the same value as diag_tickTime, the time since game launch (returned 0 before v2.18)\n- In multiplayer: It is synced to all clients both at mission start and when a new client connects to it, and every 5 minutes. Synchronisation can be forced by executing the estimatedTimeLeft command.","problems":null,"aliases":[],"see_also":["time","diag_tickTime","date","missionStart","estimatedTimeLeft","estimatedEndServerTime","systemTime","systemTimeUTC"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Multiplayer","Command Group: Time","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"set","operator":null,"title":"set","type":"command","url":"https://community.bistudio.com/wiki/set","revid":377132,"updated":"2026-01-01T10:26:06Z","groups":["Arrays","HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the element at the given zero-based index of the array.\n\n> [!NOTE]\n> If the index is out of bounds, the array will resize to incorporate the index as its last value, padding with nil as necessary (see #Example 4).","syntaxes":[{"syntax":"array set [index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":null,"types":["Array","Anything"],"since":null,"text":"array: Array of Anything"},{"name":"index","type":"Number","optional":false,"default":null,"description":"0-based array index. Arma 3 v2.12 negative index can be used to select from the end of the array, i.e. -1 means last array element.","types":["Number"],"since":null,"text":"index: Number - 0-based array index. Arma 3 v2.12 negative index can be used to select from the end of the array, i.e. -1 means last array element."},{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"[index, value]","types":["Array"]}},{"syntax":"hashMap set [key, value, insertOnly]","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"key","type":"HashMapKey","optional":false,"default":null,"description":null,"types":["HashMapKey"],"since":null,"text":"key: HashMapKey"},{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"},{"name":"insertOnly","type":"Boolean","optional":true,"default":"false","description":"if set to true, set the value only if the key does not exist already","types":["Boolean"],"since":"arma3 2.08","text":"insertOnly: Boolean - (Optional, default false) if set to true, set the value only if the key does not exist already"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"false if the key is new to the hashmap, true if a value got overwritten","text":"Boolean - false if the key is new to the hashmap, true if a value got overwritten"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"[key, value, insertOnly]","types":["Array"]}}],"examples":[{"text":"```sqf\n_arrayOne set [0, \"Hello\"];\n```","code":["_arrayOne set [0, \"Hello\"];"]},{"text":"Append \"Bye\" as last element to `_arrayTwo`:\n\n```sqf\n_arrayTwo set [count _arrayTwo, \"Bye\"];\n```","code":["_arrayTwo set [count _arrayTwo, \"Bye\"];"]},{"text":"Replace the last element of `_arrayThree` with 23:\n\n```sqf\n_arrayThree set [(count _arrayThree) - 1, 23];\n```","code":["_arrayThree set [(count _arrayThree) - 1, 23];"]},{"text":"Using set with an index that is out of bounds:\n\n```sqf\nprivate _array = [\"A\"];\n_array set [2, \"C\"]; // _array is now [\"A\", nil, \"C\"]\n_array set [1, \"B\"]; // _array is now [\"A\", \"B\", \"C\"]\n```","code":["private _array = [\"A\"];\n_array set [2, \"C\"]; // _array is now [\"A\", nil, \"C\"]\n_array set [1, \"B\"]; // _array is now [\"A\", \"B\", \"C\"]"]},{"text":"```sqf\nprivate _myHashMap = createHashMap;\n_myHashMap set [\"key\", \"value1\", true]; // \"key\" value is set to \"value1\"\n_myHashMap set [\"key\", \"value2\", true]; // \"key\" value is still \"value1\" as \"key\" already exists in the hashmap\n```","code":["private _myHashMap = createHashMap;\n_myHashMap set [\"key\", \"value1\", true]; // \"key\" value is set to \"value1\"\n_myHashMap set [\"key\", \"value2\", true]; // \"key\" value is still \"value1\" as \"key\" already exists in the hashmap"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["resize","reverse","select","deleteAt","deleteRange"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"set3DENAttachedCursorEntity","operator":null,"title":"set3DENAttachedCursorEntity","type":"command","url":"https://community.bistudio.com/wiki/set3DENAttachedCursorEntity","revid":369759,"updated":"2024-10-08T15:08:56Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attach an entity to the Eden Editor cursor.","syntaxes":[{"syntax":"set3DENAttachedCursorEntity entityHashMap","since":null,"effect":null,"exec":null,"params":[{"name":"entityHashMap","type":"HashMap","optional":false,"default":null,"description":"in format [[\"type\", entityType], otherOptions] where *entityType* can be one of:\n\n| type | options<br>case-sensitive! |\n|---|---|\n| \"object\" | - \"classname\": String - object classname; see Arma 3: Assets |\n| \"marker\" | - \"classname\": String - see marker classes<br>- \"markershape\": String - can be one of:<br>  - \"icon\"<br>  - \"rectangle\"<br>  - \"ellipse\"<br>> [!IMPORTANT]<br>> \"polyline\" is **not** supported. |\n| \"trigger\" | - \"classname\": String - object classname; from CfgNonAIVehicles with simulation=\"detector\". Usually \"EmptyDetector\" |\n| \"module\" | - \"classname\": String - object classname; |\n| \"waypoint\" | - \"classname\": String - classname; from CfgWaypoints |","types":["HashMap"],"since":null,"text":"entityHashMap: HashMap - in format [[\"type\", entityType], otherOptions] where *entityType* can be one of:\n\n| type | options<br>case-sensitive! |\n|---|---|\n| \"object\" | - \"classname\": String - object classname; see Arma 3: Assets |\n| \"marker\" | - \"classname\": String - see marker classes<br>- \"markershape\": String - can be one of:<br>  - \"icon\"<br>  - \"rectangle\"<br>  - \"ellipse\"<br>> [!IMPORTANT]<br>> \"polyline\" is **not** supported. |\n| \"trigger\" | - \"classname\": String - object classname; from CfgNonAIVehicles with simulation=\"detector\". Usually \"EmptyDetector\" |\n| \"module\" | - \"classname\": String - object classname; |\n| \"waypoint\" | - \"classname\": String - classname; from CfgWaypoints |"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"entityHashMap","types":["HashMap"]}}],"examples":[{"text":"```sqf\nset3DENAttachedCursorEntity createHashMapFromArray [[\"type\", \"object\"], [\"classname\", \"B_Survivor_F\"]];\n```","code":["set3DENAttachedCursorEntity createHashMapFromArray [[\"type\", \"object\"], [\"classname\", \"B_Survivor_F\"]];"]},{"text":"```sqf\nset3DENAttachedCursorEntity createHashMapFromArray [[\"type\", \"marker\"], [\"classname\", \"mil_pickup\"], [\"markertype\", \"icon\"]];\n```","code":["set3DENAttachedCursorEntity createHashMapFromArray [[\"type\", \"marker\"], [\"classname\", \"mil_pickup\"], [\"markertype\", \"icon\"]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Eden Editor: Object","typeOf"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"set3DENAttribute","operator":null,"title":"set3DENAttribute","type":"command","url":"https://community.bistudio.com/wiki/set3DENAttribute","revid":348910,"updated":"2023-11-08T14:40:02Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets one of entity attributes. For the list of all attributes with their properties see Setting Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. You cannot access them in scenario preview or exported scenario!","syntaxes":[{"syntax":"entity set3DENAttribute [class, value]","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Eden Entity","Eden ID"],"since":null,"text":"entity: Eden Entity or Eden ID"},{"name":"class","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"class: String - attribute name"},{"name":"value","type":"Anything","optional":false,"default":null,"description":"new attribute value","types":["Anything"],"since":null,"text":"value: Anything - new attribute value"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true If the value was set","text":"Boolean - true If the value was set"},"form":"binary","operator":null,"left":{"text":"entity","types":["Eden Entity","Eden ID"]},"right":{"text":"[class, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer set3DENAttribute [\"allowDamage\", false]; // Mark player as invincible\n```","code":["player set3DENAttribute [\"allowDamage\", false]; // Mark player as invincible"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENAttributes","get3DENAttribute"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENAttributes","operator":null,"title":"set3DENAttributes","type":"command","url":"https://community.bistudio.com/wiki/set3DENAttributes","revid":321117,"updated":"2022-05-13T14:15:26Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set entity attributes.\nAn attribute is identified by its `property` (`data` when it is engine-drive attribute) value in config.\nFor the list of all attributes with their properties, see Setting Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace and cannot be accessed in scenario preview or exported scenario!","syntaxes":[{"syntax":"set3DENAttributes [[entities1, class1, value1], [entities2, class2, value2], ...]","since":null,"effect":null,"exec":null,"params":[{"name":"entitiesN","type":"Array of Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Array","Eden Entity","Eden ID"],"since":null,"text":"entitiesN: Array of Eden Entity or Eden ID"},{"name":"classN","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"classN: String - attribute name"},{"name":"valueN","type":"Anything","optional":false,"default":null,"description":"new attribute value","types":["Anything"],"since":null,"text":"valueN: Anything - new attribute value"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the value was set","text":"Boolean - true if the value was set"},"form":"unary","operator":null,"left":null,"right":{"text":"[[entities1, class1, value1], [entities2, class2, value2], ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n// Set all selected objects as playable\nset3DENAttributes [[get3DENSelected \"Object\", \"ControlMP\", true]];\n```","code":["// Set all selected objects as playable\nset3DENAttributes [[get3DENSelected \"Object\", \"ControlMP\", true]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENAttribute","clear3DENAttribute"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENGrid","operator":null,"title":"set3DENGrid","type":"command","url":"https://community.bistudio.com/wiki/set3DENGrid","revid":353050,"updated":"2024-03-12T12:23:19Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the grid increment for the given transformation type.","syntaxes":[{"syntax":"set3DENGrid [type, value]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"name of transformation type. Can be:\n- `\"r\"` - Rotation\n- `\"t\"` - Translation\n- `\"s\"` - Scale","types":["String"],"since":null,"text":"type: String - name of transformation type. Can be:\n- `\"r\"` - Rotation\n- `\"t\"` - Translation\n- `\"s\"` - Scale"},{"name":"value","type":"Number","optional":false,"default":null,"description":"transformation increment","types":["Number"],"since":null,"text":"value: Number - transformation increment"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nset3DENGrid [\"t\", 100]; // 100m movement increment\n```","code":["set3DENGrid [\"t\", 100]; // 100m movement increment"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENIconsVisible","operator":null,"title":"set3DENIconsVisible","type":"command","url":"https://community.bistudio.com/wiki/set3DENIconsVisible","revid":342174,"updated":"2023-07-09T12:26:58Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle visibility of Eden Editor icons.","syntaxes":[{"syntax":"set3DENIconsVisible [showMap, showScene]","since":null,"effect":null,"exec":null,"params":[{"name":"showScene","type":"Boolean","optional":false,"default":null,"description":"visibility in the scene","types":["Boolean"],"since":null,"text":"showScene: Boolean - visibility in the scene"},{"name":"showMap","type":"Boolean","optional":false,"default":null,"description":"visibility in the map","types":["Boolean"],"since":null,"text":"showMap : Boolean - visibility in the map"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[showMap, showScene]","types":["Array"]}}],"examples":[{"text":"```sqf\nset3DENIconsVisible [false, false]; // Hide all icons\n```","code":["set3DENIconsVisible [false, false]; // Hide all icons"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENIconsVisible","set3DENLinesVisible","get3DENLinesVisible","set3DENModelsVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENLayer","operator":null,"title":"set3DENLayer","type":"command","url":"https://community.bistudio.com/wiki/set3DENLayer","revid":377849,"updated":"2026-01-03T11:30:21Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set layer for Eden Entity.","syntaxes":[{"syntax":"entity set3DENLayer layerID","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Eden Entity","optional":false,"default":null,"description":null,"types":["Eden Entity"],"since":null,"text":"entity: Eden Entity"},{"name":"layerID","type":"Number","optional":false,"default":null,"description":"layer ID as returned by add3DENLayer command","types":["Number"],"since":null,"text":"layerID: Number - layer ID as returned by add3DENLayer command"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the entity was moved succesfully","text":"Boolean - true if the entity was moved succesfully"},"form":"binary","operator":null,"left":{"text":"entity","types":["Eden Entity"]},"right":{"text":"layerID","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _myLayer = -1 add3DENLayer \"CTRG\";\nplayer set3DENLayer _myLayer;\n```","code":["private _myLayer = -1 add3DENLayer \"CTRG\";\nplayer set3DENLayer _myLayer;"]},{"text":"```sqf\nplayer set3DENLayer -1; // Move to root\n```","code":["player set3DENLayer -1; // Move to root"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["add3DENLayer","remove3DENLayer","get3DENLayerEntities"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENLinesVisible","operator":null,"title":"set3DENLinesVisible","type":"command","url":"https://community.bistudio.com/wiki/set3DENLinesVisible","revid":342208,"updated":"2023-07-09T12:27:19Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle visibility of Eden Editor lines.","syntaxes":[{"syntax":"set3DENLinesVisible [showMap, showScene]","since":null,"effect":null,"exec":null,"params":[{"name":"showScene","type":"Boolean","optional":false,"default":null,"description":"visibility in the scene","types":["Boolean"],"since":null,"text":"showScene: Boolean - visibility in the scene"},{"name":"showMap","type":"Boolean","optional":false,"default":null,"description":"visibility in the map","types":["Boolean"],"since":null,"text":"showMap : Boolean - visibility in the map"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[showMap, showScene]","types":["Array"]}}],"examples":[{"text":"```sqf\nset3DENLinesVisible [false, false];// Hide all lines\n```","code":["set3DENLinesVisible [false, false];// Hide all lines"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENLinesVisible","set3DENIconsVisible","get3DENIconsVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENLogicType","operator":null,"title":"set3DENLogicType","type":"command","url":"https://community.bistudio.com/wiki/set3DENLogicType","revid":310924,"updated":"2022-05-07T20:45:59Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the new type of Logic object(s). For other objects use set3DENObjectType.","syntaxes":[{"syntax":"objects set3DENLogicType classname","since":null,"effect":null,"exec":null,"params":[{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"},{"name":"classname","type":"String","optional":false,"default":null,"description":"name of the cfgVehicles class","types":["String"],"since":null,"text":"classname: String - name of the cfgVehicles class"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"objects","types":["Array","Object"]},"right":{"text":"classname","types":["String"]}}],"examples":[{"text":"```sqf\n[get3DENSelected \"logic\" select 0] set3DENLogicType \"MiscOR_F\";\n```","code":["[get3DENSelected \"logic\" select 0] set3DENLogicType \"MiscOR_F\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENObjectType","get3DENMouseOver","add3DENConnection","add3DENEventHandler","all3DENEntities","collect3DENHistory","create3DENComposition","create3DENEntity","current3DENOperation","delete3DENEntities","do3DENAction","get3DENActionState","get3DENAttribute","get3DENCamera","get3DENConnections","get3DENEntityID","get3DENGrid","get3DENIconsVisible","get3DENLinesVisible","get3DENSelected","is3DEN","is3DENMultiplayer","move3DENCamera","remove3DENConnection","remove3DENEventHandler","removeAll3DENEventHandlers","set3DENAttributes","set3DENGrid","set3DENIconsVisible","set3DENLinesVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"set3DENMissionAttribute","operator":null,"title":"set3DENMissionAttribute","type":"command","url":"https://community.bistudio.com/wiki/set3DENMissionAttribute","revid":351680,"updated":"2023-12-20T14:55:30Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set scenario attribute.\nAn attribute is identified by its `property` (`data` when it is engine-drive attribute) value in config. For the list of all attributes with their properties, see Setting Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. They cannot be accessed in scenario preview or exported scenario!\n\n> [!IMPORTANT]\n> Changing the value of an attribute will also execute the expression defined in its config.","syntaxes":[{"syntax":"section set3DENMissionAttribute [class, value]","since":null,"effect":null,"exec":null,"params":[{"name":"section","type":"String","optional":false,"default":null,"description":"attribute section. See Sections & Properties","types":["String"],"since":null,"text":"section: String - attribute section. See Sections & Properties"},{"name":"class","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"class: String - attribute name"},{"name":"value","type":"Anything","optional":false,"default":null,"description":"new attribute value","types":["Anything"],"since":null,"text":"value: Anything - new attribute value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"section","types":["String"]},"right":{"text":"[class, value]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"Multiplayer\" set3DENMissionAttribute [\"respawn\", 3]; // Set respawn type to 3\n```","code":["\"Multiplayer\" set3DENMissionAttribute [\"respawn\", 3]; // Set respawn type to 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENMissionAttribute","set3DENMissionAttributes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENMissionAttributes","operator":null,"title":"set3DENMissionAttributes","type":"command","url":"https://community.bistudio.com/wiki/set3DENMissionAttributes","revid":364856,"updated":"2024-06-25T09:27:10Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set scenario attributes.\nAn attribute is identified by its `property` (`data` when it is an engine-driven attribute) value in config.\nFor the list of all attributes with their properties, see Mission Attributes.\n\n> [!IMPORTANT]\n> Attributes are available only within the Eden Editor workspace. You cannot access them in scenario preview or exported scenario!","syntaxes":[{"syntax":"set3DENMissionAttributes [[section1, class1, value1], ...]","since":null,"effect":null,"exec":null,"params":[{"name":"sectionN","type":"String","optional":false,"default":null,"description":"attribute section. See Sections & Properties","types":["String"],"since":null,"text":"sectionN: String - attribute section. See Sections & Properties"},{"name":"classN","type":"String","optional":false,"default":null,"description":"attribute name","types":["String"],"since":null,"text":"classN: String - attribute name"},{"name":"valueN","type":"Anything","optional":false,"default":null,"description":"new attribute value","types":["Anything"],"since":null,"text":"valueN: Anything - new attribute value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[[section1, class1, value1], ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n// set respawn type to 3 and respawn delay to 10 seconds\nset3DENMissionAttributes [[\"Multiplayer\", \"respawn\", 3], [\"Multiplayer\", \"respawnDelay\", 10]];\n```","code":["// set respawn type to 3 and respawn delay to 10 seconds\nset3DENMissionAttributes [[\"Multiplayer\", \"respawn\", 3], [\"Multiplayer\", \"respawnDelay\", 10]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENMissionAttribute","set3DENMissionAttribute"],"notes":[{"user":"R3vo","date":"2019-01-02T12:09:00Z","text":"Usually, the attributes value can be received by \n\n```sqf\n_sectionName get3DENMissionAttribute _attributeName; // See example above\n```\n\nHowever, if the attribute was not changed and it is default value is used get3DENMissionAttribute might return Nothing, even though in Eden Editor the attribute has got a value. In that case the attribute's config name is not identical to the 'property' or 'data' config value. To get the right values in these cases one has to do:\n\n```sqf\n_sectionName get3DENMissionAttribute _propertyName;\n// or\n_sectionName get3DENMissionAttribute _dataName;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENModelsVisible","operator":null,"title":"set3DENModelsVisible","type":"command","url":"https://community.bistudio.com/wiki/set3DENModelsVisible","revid":351312,"updated":"2023-11-27T04:55:31Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enables or disables trigger area visibility.","syntaxes":[{"syntax":"set3DENModelsVisible [map, scene]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"map: Boolean"},{"name":"scene","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"scene: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[map, scene]","types":["Array"]}}],"examples":[{"text":"```sqf\nset3DENModelsVisible [true, true];\n```","code":["set3DENModelsVisible [true, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENLinesVisible","get3DENIconsVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENObjectType","operator":null,"title":"set3DENObjectType","type":"command","url":"https://community.bistudio.com/wiki/set3DENObjectType","revid":364151,"updated":"2024-05-05T10:44:17Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the classname of one or more given Eden Editor objects. For Logic objects use set3DENLogicType.","syntaxes":[{"syntax":"objects set3DENObjectType classname","since":null,"effect":null,"exec":null,"params":[{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"},{"name":"classname","type":"String","optional":false,"default":null,"description":"name of the cfgVehicles class","types":["String"],"since":null,"text":"classname: String - name of the cfgVehicles class"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"objects","types":["Array","Object"]},"right":{"text":"classname","types":["String"]}}],"examples":[{"text":"```sqf\n[get3DENMouseOver select 1] set3DENObjectType \"B_crew_F\"; // turns object under cursor into a blufor crewman\n```","code":["[get3DENMouseOver select 1] set3DENObjectType \"B_crew_F\"; // turns object under cursor into a blufor crewman"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set3DENLogicType","get3DENMouseOver","add3DENConnection","add3DENEventHandler","all3DENEntities","collect3DENHistory","create3DENComposition","create3DENEntity","current3DENOperation","delete3DENEntities","do3DENAction","get3DENActionState","get3DENAttribute","get3DENCamera","get3DENConnections","get3DENEntityID","get3DENGrid","get3DENIconsVisible","get3DENLinesVisible","get3DENSelected","is3DEN","is3DENMultiplayer","move3DENCamera","remove3DENConnection","remove3DENEventHandler","removeAll3DENEventHandlers","set3DENAttributes","set3DENGrid","set3DENIconsVisible","set3DENLinesVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"set3DENSelected","operator":null,"title":"set3DENSelected","type":"command","url":"https://community.bistudio.com/wiki/set3DENSelected","revid":352152,"updated":"2024-02-01T23:25:20Z","groups":["Eden Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes selection in Eden Editor to what is inside entities array. \n\n> [!WARNING]\n> This command will trigger the 3DEN event handler **\"OnSelectionChange\"**. Do not use it inside this event handler!","syntaxes":[{"syntax":"set3DENSelected entities","since":null,"effect":null,"exec":null,"params":[{"name":"entities","type":"Array of Eden Entity or Eden ID","optional":false,"default":null,"description":null,"types":["Array","Eden Entity","Eden ID"],"since":null,"text":"entities: Array of Eden Entity or Eden ID"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"entities","types":["Array","Eden Entity","Eden ID"]}}],"examples":[{"text":"```sqf\nset3DENSelected [0,5,3,6,7,12];\n```","code":["set3DENSelected [0,5,3,6,7,12];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["get3DENMouseOver","all3DENEntities","collect3DENHistory","get3DENEntityID","get3DENSelected","set3DENObjectType"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Eden Editor","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"setAccTime","operator":null,"title":"setAccTime","type":"command","url":"https://community.bistudio.com/wiki/setAccTime","revid":338949,"updated":"2023-04-18T01:26:22Z","groups":["Time"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set simulation acceleration coefficient. May also be used to slow time in cutscenes.","syntaxes":[{"syntax":"setAccTime accFactor","since":null,"effect":null,"exec":null,"params":[{"name":"accFactor","type":"Number","optional":false,"default":null,"description":"time factor; 2 will make time go twice as fast, 0.5 half of it, etc","types":["Number"],"since":null,"text":"accFactor: Number - time factor; 2 will make time go twice as fast, 0.5 half of it, etc"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"accFactor","types":["Number"]}}],"examples":[{"text":"```sqf\nsetAccTime 0.1;\n```","code":["setAccTime 0.1;"]}],"multiplayer":"Command is disabled in multiplayer.","problems":"This command is **not** clamped and incorrect values may be entered (negative values, high values, etc - game behaviour is then undefined).","aliases":[],"see_also":["accTime","setTimeMultiplier","timeMultiplier","useAudioTimeForMoves"],"notes":[{"user":"Hardrock","date":"2006-08-04T10:58:00Z","text":"*Notes from before the conversion:*\n\nA good habit to get into is setting the accTime to 1 at the start of all cutscenes, in case the player is running at 4x speed when the scene starts."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Time","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setActualCollectiveRTD","operator":null,"title":"setActualCollectiveRTD","type":"command","url":"https://community.bistudio.com/wiki/setActualCollectiveRTD","revid":377779,"updated":"2026-01-03T01:32:34Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the collective pitch control to a specific position, regardless of input devices (until those are changed).\n- 0: collective fully down\n- ~0.7: approximate stable hover position\n- 1: collective fully up\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD setActualCollectiveRTD value","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD : ObjectRTD - helicopter"},{"name":"value","type":"Number","optional":false,"default":null,"description":"collective position","types":["Number"],"since":null,"text":"value: Number - collective position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD setActualCollectiveRTD 0.7;\n```","code":["myHelicopterRTD setActualCollectiveRTD 0.7;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["collectiveRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setAirplaneThrottle","operator":null,"title":"setAirplaneThrottle","type":"command","url":"https://community.bistudio.com/wiki/setAirplaneThrottle","revid":310925,"updated":"2022-05-07T20:46:43Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets a wanted throttle position - works only on player's vehicle.","syntaxes":[{"syntax":"airplane setAirplaneThrottle value","since":null,"effect":null,"exec":null,"params":[{"name":"airplane","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"airplane: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":"wanted throttle","types":["Number"],"since":null,"text":"value: Number - wanted throttle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"airplane","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nvehicle player setAirplaneThrottle 0.5;\n```","code":["vehicle player setAirplaneThrottle 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["airplaneThrottle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setAirportSide","operator":null,"title":"setAirportSide","type":"command","url":"https://community.bistudio.com/wiki/setAirportSide","revid":322975,"updated":"2022-06-28T21:42:54Z","groups":["Roads and Airports","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set owning side of the airport. ID is the number to identify which airport on the island you want to check.","syntaxes":[{"syntax":"id setAirportSide side","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"id","types":["Number"]},"right":{"text":"side","types":["Side"]}},{"syntax":"target setAirportSide side","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Object"]},"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n0 setAirportSide east;\n```","code":["0 setAirportSide east;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["airportSide","landAt","land","assignToAirport","allAirports","Arma: Airport IDs"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Roads and Airports","Command Group: Sides","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setAmmo","operator":null,"title":"setAmmo","type":"command","url":"https://community.bistudio.com/wiki/setAmmo","revid":369275,"updated":"2024-09-03T18:42:45Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets custom ammo count in the currently loaded magazine of the specified weapon or muzzle.","syntaxes":[{"syntax":"unit setAmmo [weaponOrMuzzle, count]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"gunner or vehicle.","types":["Object"],"since":null,"text":"unit: Object - gunner or vehicle."},{"name":"weaponOrMuzzle","type":"String","optional":false,"default":null,"description":"weapon name. Muzzle name in case the weapon has more than one muzzle, e.g. weapon with grenade launcher. See CfgWeapons for muzzle names","types":["String"],"since":null,"text":"weaponOrMuzzle: String - weapon name. Muzzle name in case the weapon has more than one muzzle, e.g. weapon with grenade launcher. See CfgWeapons for muzzle names"},{"name":"count","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"count: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[weaponOrMuzzle, count]","types":["Array"]}}],"examples":[{"text":"Set player's handgun magazine ammo count to 10 rounds:\n\n```sqf\nplayer setAmmo [handgunWeapon player, 10];\n```","code":["player setAmmo [handgunWeapon player, 10];"]},{"text":"Set player's current weapon magazine ammo count to 1 round:\n\n```sqf\nplayer setAmmo [currentWeapon player, 1];\n```","code":["player setAmmo [currentWeapon player, 1];"]},{"text":"If player is a gunner in a vehicle, set current weapon magazine ammo count to 5 rounds:\n\n```sqf\nif (local vehicle player) then {\n    vehicle player setAmmo [currentWeapon vehicle player, 5];\n} else {\n    hint \"Vehicle must be local to this machine for 'setAmmo' to work\";\n};\n```","code":["if (local vehicle player) then {\n\tvehicle player setAmmo [currentWeapon vehicle player, 5];\n} else {\n\thint \"Vehicle must be local to this machine for 'setAmmo' to work\";\n};"]},{"text":"If you try to set more ammo than the magazine can hold, it will be clipped at default magazine capacity:\n\n```sqf\nplayer setAmmo [primaryWeapon player, 1000000]; // full mag with default ammo count\n```","code":["player setAmmo [primaryWeapon player, 1000000]; // full mag with default ammo count"]},{"text":"Some weapons has more than one muzzles:\n\n```sqf\n_marshall setAmmo [\"autocannon_40mm_CTWS\", 0];// won't work\n_marshall setAmmo [\"HE\", 0];// works\n```","code":["_marshall setAmmo [\"autocannon_40mm_CTWS\", 0];// won't work\n_marshall setAmmo [\"HE\", 0];// works"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ammo","setVehicleAmmo","setFuel","setHit"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setAmmoCargo","operator":null,"title":"setAmmoCargo","type":"command","url":"https://community.bistudio.com/wiki/setAmmoCargo","revid":376962,"updated":"2026-01-01T05:54:37Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set amount of ammo resources in cargo space of a rearm vehicle. Ammo resource is used to resupply vehicles that take ammo. Soldiers use individual magazines instead.\n\nThe actual **quantity** to work with is determined by the model's class in CfgVehicles","syntaxes":[{"syntax":"vehicleName setAmmoCargo ammoCargo","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"ammoCargo","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"ammoCargo: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"ammoCargo","types":["Number"]}}],"examples":[{"text":"```sqf\n_ammoTruck1 setAmmoCargo 0.5;\n```","code":["_ammoTruck1 setAmmoCargo 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAmmoCargo","setFuelCargo","setRepairCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setAmmoOnPylon","operator":null,"title":"setAmmoOnPylon","type":"command","url":"https://community.bistudio.com/wiki/setAmmoOnPylon","revid":310926,"updated":"2022-05-07T20:47:37Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set count of ammo in magazine on pylon (supports pylon name since Arma 3 v1.94)","syntaxes":[{"syntax":"vehicle setAmmoOnPylon [pylon, ammocount]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"pylon","type":"Number or String","optional":false,"default":null,"description":"pylon index (index starts from 1) or pylon name (see getCompatiblePylonMagazines Example 4)","types":["Number","String"],"since":null,"text":"pylon: Number or String - pylon index (index starts from 1) or pylon name (see getCompatiblePylonMagazines Example 4)"},{"name":"ammocount","type":"Number","optional":false,"default":null,"description":"ammo count","types":["Number"],"since":null,"text":"ammocount: Number - ammo count"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[pylon, ammocount]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setAmmoOnPylon [1, 12];\n```","code":["vehicle player setAmmoOnPylon [1, 12];"]},{"text":"```sqf\nvehicle player setAmmoOnPylon [\"pylon1\", 12];\n```","code":["vehicle player setAmmoOnPylon [\"pylon1\", 12];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","getPylonMagazines","animatePylon","animateBay","setPylonsPriority","setPylonLoadout","setMagazineTurretAmmo"],"notes":[{"user":"Commy2","date":"2017-08-18T14:20:00Z","text":"The pylon indices start at 1 and not at 0."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setAngularVelocity","operator":null,"title":"setAngularVelocity","type":"command","url":"https://community.bistudio.com/wiki/setAngularVelocity","revid":377432,"updated":"2026-01-02T06:46:18Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the angular velocity of the object in world space as a 3D vector. The units are in Rad/s and rotations are clockwise.\n\n> [!IMPORTANT]\n> Angular velocity is limited to a range of +-1000 Rad/s.","syntaxes":[{"syntax":"obj setAngularVelocity vector","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"vector","type":"Vector3D","optional":false,"default":null,"description":"angular velocity of the object in world space.","types":["Vector3D"],"since":null,"text":"vector: Vector3D - angular velocity of the object in world space."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"vector","types":["Vector3D"]}}],"examples":[{"text":"```sqf\nmyHeli setAngularVelocity [0,0,1]; // will cause the helicopter to spin around a vertical line passing through its center\n```","code":["myHeli setAngularVelocity [0,0,1]; // will cause the helicopter to spin around a vertical line passing through its center"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVelocity","setAngularVelocityModelSpace","angularVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setAngularVelocityModelSpace","operator":null,"title":"setAngularVelocityModelSpace","type":"command","url":"https://community.bistudio.com/wiki/setAngularVelocityModelSpace","revid":377262,"updated":"2026-01-02T06:33:08Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the angular velocity of the object in model space as a 3D vector. The units are in Rad/s and rotations are clockwise.\n\n> [!IMPORTANT]\n> Angular velocity is limited to a range of +-1000 Rad/s.","syntaxes":[{"syntax":"obj setAngularVelocityModelSpace vector","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"vector","type":"Vector3D","optional":false,"default":null,"description":"angular velocity of the object in model space","types":["Vector3D"],"since":null,"text":"vector: Vector3D - angular velocity of the object in model space"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"vector","types":["Vector3D"]}}],"examples":[{"text":"```sqf\nmyHeli setAngularVelocityModelSpace [0,0,1]; // will cause the helicopter to spin around its main rotor shaft\n```","code":["myHeli setAngularVelocityModelSpace [0,0,1]; // will cause the helicopter to spin around its main rotor shaft"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVelocity","setAngularVelocity","angularVelocity","angularVelocityModelSpace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setAnimSpeedCoef","operator":null,"title":"setAnimSpeedCoef","type":"command","url":"https://community.bistudio.com/wiki/setAnimSpeedCoef","revid":353131,"updated":"2024-03-12T12:48:26Z","groups":["Animations","Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets a coefficient for animation speed (0.5 will play animations half the speed, 2 twice the speed).\n\nDoesn't affect upper body animations (reloading, etc.)","syntaxes":[{"syntax":"unit setAnimSpeedCoef coef","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"coef","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"coef: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"coef","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setAnimSpeedCoef 0.75;\n```","code":["player setAnimSpeedCoef 0.75;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","getAnimSpeedCoef","setAccTime"],"notes":[{"user":"Waffle SS.","date":"2021-10-30T19:41:02Z","text":"For animation speed to control unit speed, this must be executed on the local client.\nNon-local clients can set a speed less than the local client's.\nNon-local clients using an animation speed greater than the local client's may result in the animation freezing."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setAperture","operator":null,"title":"setAperture","type":"command","url":"https://community.bistudio.com/wiki/setAperture","revid":340862,"updated":"2023-05-12T17:05:48Z","groups":["Camera Control","Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets custom eye accommodation camera aperture.\n\n> [!NOTE]\n> If HDR is enabled, when setAperture `value` is used it also forces setApertureNew to the following values: [`value`, `value`, `value`, 1].\n> Execute setApertureNew after setAperture to override this default mechanic.\n\n> [!IMPORTANT]\n> The aperture is set to default by the engine at the mission start. If you set it before the mission started it will reset like it never happened.\n> Make sure you set it at the right time (see #Example 2).","syntaxes":[{"syntax":"setAperture aperture","since":null,"effect":null,"exec":null,"params":[{"name":"aperture","type":"Number","optional":false,"default":null,"description":"aperture value; a value  will set the aperture automatically. Maximum value which has an effect seems to be `100`.","types":["Number"],"since":null,"text":"aperture: Number - aperture value; a value  will set the aperture automatically. Maximum value which has an effect seems to be `100`."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"aperture","types":["Number"]}}],"examples":[{"text":"```sqf\nsetAperture 0.3;\n```","code":["setAperture 0.3;"]},{"text":"```sqf\n0 spawn { sleep 0.1; setAperture 100 };\n```","code":["0 spawn { sleep 0.1; setAperture 100 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setApertureNew","apertureParams"],"notes":[{"user":"Namikaze","date":"2009-03-17T19:43:00Z","text":"The aperture value to simulate typical daylight (outdoor) conditions is 50. The aperture value to simulate typical daylight (indoor) conditions is 30.\nSetting the value to less than 20 will result in a very bright scene, suitable for night conditions.\nThe closer the number is to 0, the more light will be let into the lens, to carry on the aperture metaphor.\nDifferent lighting/weather conditions can change the actual indoor and outdoor aperture values. Experiment and test to be sure."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Lights","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setApertureNew","operator":null,"title":"setApertureNew","type":"command","url":"https://community.bistudio.com/wiki/setApertureNew","revid":376403,"updated":"2025-10-11T00:55:28Z","groups":["Camera Control","Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets custom camera aperture when HDR is enabled. Provided values should be set such as *minimum* &lte; *standard* &lte; *maximum*.\n\n> [!NOTE]\n> - This command has to be executed after mission start: be sure to use e.g `sleep 0.1;` for it to take effect.\n> - If HDR is enabled (it is by default), when setAperture `value` is used it also forces setApertureNew to the following values: [`value`, `value`, `value`, 1]. Execute setApertureNew *after* setAperture to override this default mechanic.","syntaxes":[{"syntax":"setApertureNew [minimum, standard, maximum, luminance]","since":null,"effect":null,"exec":null,"params":[{"name":"minimum","type":"Number","optional":false,"default":null,"description":"minimum aperture","types":["Number"],"since":null,"text":"minimum: Number - minimum aperture"},{"name":"standard","type":"Number","optional":false,"default":null,"description":"standard aperture","types":["Number"],"since":null,"text":"standard: Number - standard aperture"},{"name":"maximum","type":"Number","optional":false,"default":null,"description":"maximum aperture","types":["Number"],"since":null,"text":"maximum: Number - maximum aperture"},{"name":"luminance","type":"Number","optional":false,"default":null,"description":"standard luminance","types":["Number"],"since":null,"text":"luminance: Number - standard luminance"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[minimum, standard, maximum, luminance]","types":["Array"]}},{"syntax":"setApertureNew [reset]","since":null,"effect":null,"exec":null,"params":[{"name":"reset","type":"Number","optional":false,"default":null,"description":"reset to default with -1","types":["Number"],"since":null,"text":"reset: Number - reset to default with -1"}],"returns":null,"form":"unary","operator":null,"left":null,"right":{"text":"[reset]","types":["Array"]}},{"syntax":"","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsetApertureNew [0.1, 0.2, 0.3, 1];\nsetApertureNew [-1];                // reset to default\n```","code":["setApertureNew [0.1, 0.2, 0.3, 1];\nsetApertureNew [-1];\t\t\t\t// reset to default"]},{"text":"Simulate eye adjustment at night:\n\n```sqf\nsetDate [2016, 8, 10, 4, 0];\nsetApertureNew [2, 8, 14, 0.9];\n```","code":["setDate [2016, 8, 10, 4, 0];\nsetApertureNew [2, 8, 14, 0.9];"]},{"text":"Narrower range for a subtler effect:\n\n```sqf\nsetDate [2016, 8, 10, 4, 0];\nsetApertureNew [2, 5, 9, 0.8];\n```","code":["setDate [2016, 8, 10, 4, 0];\nsetApertureNew [2, 5, 9, 0.8];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAperture","apertureParams"],"notes":[{"user":"Tofof","date":"2016-10-30T04:54:00Z","text":"Some notes on #Example 2 - try it outdoors on a piece of ground with high contrasting areas. I suggest the end of a runway, standing among the white painted triangles.\n\nLook up about 60 degrees above the horizon and toggle between `setApertureNew [2, 8, 14, .9];` and the default setting of `setAperture -1;`. There should be little change -- at least on the date in the example.\n\nReset again to `setApertureNew [2, 8, 14, .9];` and then pan slowly down until you're basically looking at your feet. The less sky (the main outdoor light source) you see, the 'wider' (toward the 'min' number) the aperture will become. Looking at the ground on a runway, for example, you should be able to easily distinguish the painted white triangles from the unpainted pavement. Again, toggle back to the default aperture. The view should get much darker.\n\nThis setting allows for some natural adjustment based on the amount of visible light in the scene, and is highly encouraged over the default fixed aperature for night missions. When you're standing in the beam of a lighthouse, for example (try near the 'Spartan' on Stratis), you will be basically unable to see anything not illuminated by the beam. Once the beam passes and your vision returns to normal, your immediate surroundings will be dimmer, of course, but you'll be able to see further out."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setArmoryPoints","operator":null,"title":"setArmoryPoints","type":"command","url":"https://community.bistudio.com/wiki/setArmoryPoints","revid":319633,"updated":"2022-05-13T09:24:36Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Stores passed number into [USERNAME].ArmaXProfile file, where it assigns it as a value to *armoryPoints* entry. If entry doesn't exist, it is created.","syntaxes":[{"syntax":"setArmoryPoints points","since":null,"effect":null,"exec":null,"params":[{"name":"points","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"points: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"points","types":["Number"]}}],"examples":[{"text":"```sqf\nsetArmoryPoints (armoryPoints + 20);\n```","code":["setArmoryPoints (armoryPoints + 20);"]},{"text":"```sqf\nsetArmoryPoints 3.14;\n```","code":["setArmoryPoints 3.14;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["armoryPoints"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setAttributes","operator":null,"title":"setAttributes","type":"command","url":"https://community.bistudio.com/wiki/setAttributes","revid":351277,"updated":"2023-11-27T02:34:49Z","groups":["Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a Structured Text created from the given structured text and sets attributes to the given values.\n\n> [!IMPORTANT]\n> Even though command accepts plain String too, the argument should be Structured Text in order for the set attributes to have an effect.\n> Additionally the result of the command should be fed to composeText (See #Example 1) or formatText.","syntaxes":[{"syntax":"text setAttributes [name1, value1, name2, value2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String or Structured Text","optional":false,"default":null,"description":"only passing Structured Text has any effect","types":["String","Structured Text"],"since":null,"text":"text: String or Structured Text - only passing Structured Text has any effect"},{"name":"nameN","type":"String","optional":false,"default":null,"description":"name of the attribute","types":["String"],"since":null,"text":"nameN: String - name of the attribute"},{"name":"valueN","type":"String","optional":false,"default":null,"description":"value of the attribute","types":["String"],"since":null,"text":"valueN: String - value of the attribute"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"binary","operator":null,"left":{"text":"text","types":["String","Structured Text"]},"right":{"text":"[name1, value1, name2, value2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n_txt = text \"Red text, right align\";\n_txt setAttributes [\"color\", \"#FF0000\", \"align\", \"right\"];\nhint composeText [_txt];\n```","code":["_txt = text \"Red text, right align\";\n_txt setAttributes [\"color\", \"#FF0000\", \"align\", \"right\"];\nhint composeText [_txt];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["composeText","formatText","parseText","text","ctrlSetStructuredText"],"notes":[],"categories":[]},{"name":"setAutonomous","operator":null,"title":"setAutonomous","type":"command","url":"https://community.bistudio.com/wiki/setAutonomous","revid":364993,"updated":"2024-07-04T19:58:05Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets UAV autonomous mode.","syntaxes":[{"syntax":"uav setAutonomous bool","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"whether the operation was successful. Returns false when the object is not a uav.","text":"Boolean - whether the operation was successful. Returns false when the object is not a uav."},"form":"binary","operator":null,"left":{"text":"uav","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nuav setAutonomous true;\n```","code":["uav setAutonomous true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAutonomous","disableAI","enableAI","checkAIFeature"],"notes":[{"user":"Sa-Matra","date":"2023-04-30T04:00:28Z","text":"This command effectively does disableAI on this list of features: `[\"ANIM\",\"AUTOTARGET\",\"CHECKVISIBLE\",\"FSM\",\"MOVE\",\"PATH\",\"TARGET\",\"WEAPONAIM\"]`, the effect is local, just like disableAI. If at least one of these AI features is disabled, then \"Autonomous\" checkbox in UAV Terminal will be turned off, isAutonomous will return false, you won't be able to give it waypoints, despite UAV still being mostly autonomous."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setBehaviour","operator":null,"title":"setBehaviour","type":"command","url":"https://community.bistudio.com/wiki/setBehaviour","revid":364537,"updated":"2024-05-16T20:46:45Z","groups":["Groups","AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets individual unit behaviour **on every unit in a group**.\n\n> [!IMPORTANT]\n> This command doesn't set AI Group behaviour, see setCombatBehaviour or setBehaviourStrong for this.\n\n> [!NOTE]\n> See AI Behaviour for details of the effect of this command on AI units.\n\n| Command | Applies To |\n|---|---|\n| setBehaviour | **Every unit** in the group, but **not the group** itself |\n| setBehaviourStrong | **Every unit** in the group, and the **group** itself |\n| setCombatBehaviour | If argument is Object, only that **unit**, and if argument is Group, the **group** itself (not its units) |","syntaxes":[{"syntax":"groupOrUnit setBehaviour behaviour","since":null,"effect":null,"exec":null,"params":[{"name":"groupOrUnit","type":"Group or Object","optional":false,"default":null,"description":"unit or a group","types":["Group","Object"],"since":null,"text":"groupOrUnit : Group or Object - unit or a group"},{"name":"behaviour","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"","types":["String"],"since":null,"text":"behaviour: String - can be one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupOrUnit","types":["Group","Object"]},"right":{"text":"behaviour","types":["String"]}}],"examples":[{"text":"```sqf\n_group1 setBehaviour \"SAFE\";\n```","code":["_group1 setBehaviour \"SAFE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCombatBehaviour","combatBehaviour","AIBehaviour","behaviour","setBehaviourStrong","setWaypointBehaviour","combatMode","setCombatMode","skill","setSkill","Arma 3: AI Skill"],"notes":[{"user":"SNKMAN","date":"2009-01-03T15:57:00Z","text":"Warning! Since Armed Assault v.1.14 the command setBehaviour \"COMBAT\" does not work correctly any longer.\nUnits ( Groups ) which are using this behaviour and then get a move order will not move to the given position."},{"user":"MadRussian","date":"2010-02-14T08:19:00Z","text":"Although setBehaviour can be called on an individual unit, the entire group will be affected."},{"user":"MulleDK13","date":"2010-11-22T19:18:00Z","text":"If setting a behaviour on an individual unit is required, it can be achieved by creating a temporary group, use joinSilent to make the individual unit belong to that group, then change his behaviour, use joinSilent into the original group, then delete the temporary group."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setBehaviourStrong","operator":null,"title":"setBehaviourStrong","type":"command","url":"https://community.bistudio.com/wiki/setBehaviourStrong","revid":364285,"updated":"2024-05-06T09:38:35Z","groups":["Groups","AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets individual unit behaviour on every unit in a group and additionally tries to force this behaviour to the unit's group. Alternatively see setCombatBehaviour.\n\n> [!NOTE]\n> See AI Behaviour for details of the effect of this command on AI units.\n\n| Command | Applies To |\n|---|---|\n| setBehaviour | **Every unit** in the group, but **not the group** itself |\n| setBehaviourStrong | **Every unit** in the group, and the **group** itself |\n| setCombatBehaviour | If argument is Object, only that **unit**, and if argument is Group, the **group** itself (not its units) |","syntaxes":[{"syntax":"groupName setBehaviourStrong behaviour","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Group or Object","optional":false,"default":null,"description":"unit from the group","types":["Group","Object"],"since":null,"text":"groupName: Group or Object - unit from the group"},{"name":"behaviour","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"","types":["String"],"since":null,"text":"behaviour: String - can be one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Group","Object"]},"right":{"text":"behaviour","types":["String"]}}],"examples":[{"text":"```sqf\n_group1 setBehaviourStrong \"SAFE\";\n```","code":["_group1 setBehaviourStrong \"SAFE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCombatBehaviour","combatBehaviour","AIBehaviour","behaviour","setBehaviour","setWaypointBehaviour","combatMode","setCombatMode","skill","setSkill","Arma 3: AI Skill"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Arma 3 version 1.92","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setBleedingRemaining","operator":null,"title":"setBleedingRemaining","type":"command","url":"https://community.bistudio.com/wiki/setBleedingRemaining","revid":321008,"updated":"2022-05-13T11:02:28Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets for how many seconds injured unit leaves blood trail.\nThe unit damage must be >= 0.1 for this command to have an effect, otherwise, the getBleedingRemaining will return 0 and no blood trail is left behind.","syntaxes":[{"syntax":"unit setBleedingRemaining time","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"time","types":["Number"]}}],"examples":[{"text":"```sqf\n_unit setBleedingRemaining 60;\n```","code":["_unit setBleedingRemaining 60;"]},{"text":"```sqf\nplayer setDamage 0.25;\nplayer setBleedingRemaining 120;\n```","code":["player setDamage 0.25;\nplayer setBleedingRemaining 120;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getBleedingRemaining","isBurning","isBleeding"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setBrakesRTD","operator":null,"title":"setBrakesRTD","type":"command","url":"https://community.bistudio.com/wiki/setBrakesRTD","revid":377777,"updated":"2026-01-03T01:32:30Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable landing gear wheel brakes for a helicopter.\n- value 0: brakes off\n- value 1: brakes on\n\n- index 1: left wheels\n- index 2: right wheels\n- index 3: both sides\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.\n\n> [!NOTE]\n> This command is implemented, but not fully supported.","syntaxes":[{"syntax":"helicopterRTD setBrakesRTD [value, wheelIndex]","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"},{"name":"value","type":"Number","optional":false,"default":null,"description":"value of the brakes","types":["Number"],"since":null,"text":"value: Number - value of the brakes"},{"name":"wheelIndex","type":"Number","optional":false,"default":null,"description":"wheel index","types":["Number"],"since":null,"text":"wheelIndex: Number - wheel index"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"[value, wheelIndex]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD setBrakesRTD [1, 3];\n```","code":["myHelicopterRTD setBrakesRTD [1, 3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setCameraInterest","operator":null,"title":"setCameraInterest","type":"command","url":"https://community.bistudio.com/wiki/setCameraInterest","revid":310118,"updated":"2022-05-05T12:25:32Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set camera interest for given entity. Camera interest is by default 0. Any unit which is speaking has its camera interest raised to 50. Camera interest is used to focus camera to control depth of field in cutscenes. Combination of camera interest, unit position of the screen, unit movement, unit type, and some other properties is used to determine which unit to focus at. Higher camera interest increases the chance of the unit being focused.","syntaxes":[{"syntax":"entity setCameraInterest interest","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"},{"name":"interest","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"interest: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"entity","types":["Object"]},"right":{"text":"interest","types":["Number"]}}],"examples":[{"text":"```sqf\n_soldier setCameraInterest 50;\n```","code":["_soldier setCameraInterest 50;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cameraInterest"],"notes":[],"categories":[]},{"name":"setCamShakeDefParams","operator":null,"title":"setCamShakeDefParams","type":"command","url":"https://community.bistudio.com/wiki/setCamShakeDefParams","revid":341177,"updated":"2023-05-13T22:13:33Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets camera shake default parameters.","syntaxes":[{"syntax":"setCamShakeDefParams [power, duration, frequency, minSpeed, minMass, caliberCoefHit, vehicleCoef]","since":null,"effect":null,"exec":null,"params":[{"name":"power","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"power: Number"},{"name":"duration","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"duration: Number"},{"name":"frequency","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"frequency: Number"},{"name":"minSpeed","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"minSpeed: Number"},{"name":"minMass","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"minMass: Number"},{"name":"caliberCoefHit","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"caliberCoefHit: Number"},{"name":"vehicleCoef","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"vehicleCoef: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[power, duration, frequency, minSpeed, minMass, caliberCoefHit, vehicleCoef]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetCamShakeDefParams [1, 2, 3, 4, 5, .5, .5];\n```","code":["setCamShakeDefParams [1, 2, 3, 4, 5, .5, .5];"]},{"text":"```sqf\nsetCamShakeDefParams [100, 10, 10, 4, 5, 1, 1];\n```","code":["setCamShakeDefParams [100, 10, 10, 4, 5, 1, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableCamShake","addCamShake","setCamShakeParams","resetCamShake"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setCamShakeParams","operator":null,"title":"setCamShakeParams","type":"command","url":"https://community.bistudio.com/wiki/setCamShakeParams","revid":364174,"updated":"2024-05-05T10:46:45Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets camera shake parameters. Will not have any effect until shake is started via addCamShake.","syntaxes":[{"syntax":"setCamShakeParams [posCoef, vertCoef, horzCoef, bankCoef, interpolation]","since":null,"effect":null,"exec":null,"params":[{"name":"posCoef","type":"Number","optional":false,"default":null,"description":"strength of positional movement (how far the whole position can change in X,Y&Z). Should not be bigger than **0.1** to prevent the camera from moving into or behind the player","types":["Number"],"since":null,"text":"posCoef: Number - strength of positional movement (how far the whole position can change in X,Y&Z). Should not be bigger than **0.1** to prevent the camera from moving into or behind the player"},{"name":"vertCoef","type":"Number","optional":false,"default":null,"description":"strength of vertical camera pan (up/down), practical range: 0..10","types":["Number"],"since":null,"text":"vertCoef: Number - strength of vertical camera pan (up/down), practical range: 0..10"},{"name":"horzCoef","type":"Number","optional":false,"default":null,"description":"strength of horizontal camera pan (left/right), practical range: 0..10","types":["Number"],"since":null,"text":"horzCoef: Number - strength of horizontal camera pan (left/right), practical range: 0..10"},{"name":"bankCoef","type":"Number","optional":false,"default":null,"description":"strength of camera tilt/bank, practical range: 0..20","types":["Number"],"since":null,"text":"bankCoef: Number - strength of camera tilt/bank, practical range: 0..20"},{"name":"interpolation","type":"Boolean","optional":false,"default":null,"description":"if true, then transitions in the different shaking directions will be smoother","types":["Boolean"],"since":null,"text":"interpolation: Boolean - if true, then transitions in the different shaking directions will be smoother"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[posCoef, vertCoef, horzCoef, bankCoef, interpolation]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetCamShakeParams [0.1, 1, 1, 1, true];\n```","code":["setCamShakeParams [0.1, 1, 1, 1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCamShakeDefParams","addCamShake","enableCamShake","resetCamShake"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setCamUseTI","operator":null,"title":"setCamUseTI","type":"command","url":"https://community.bistudio.com/wiki/setCamUseTI","revid":369156,"updated":"2024-09-03T10:34:40Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets thermal vision mode for currently used camera. This command only works with camCreate created camera that is currently the main camera for the player (see Example 2).","syntaxes":[{"syntax":"state setCamUseTI modeIndex","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to enable, false to disable the effect","types":["Boolean"],"since":null,"text":"state: Boolean - true to enable, false to disable the effect"},{"name":"modeIndex","type":"Number","optional":false,"default":null,"description":"TI mode. Can be:\n- 0 - White Hot\n- 1 - Black Hot\n- 2 - Light Green Hot / Darker Green cold\n- 3 - Black Hot / Darker Green cold\n- 4 - Light Red Hot /Darker Red Cold\n- 5 - Black Hot / Darker Red Cold\n- 6 - White Hot . Darker Red Cold\n- 7 - Thermal (Shade of Red and Green, Bodies are white)","types":["Number"],"since":null,"text":"modeIndex: Number - TI mode. Can be:\n- 0 - White Hot\n- 1 - Black Hot\n- 2 - Light Green Hot / Darker Green cold\n- 3 - Black Hot / Darker Green cold\n- 4 - Light Red Hot /Darker Red Cold\n- 5 - Black Hot / Darker Red Cold\n- 6 - White Hot . Darker Red Cold\n- 7 - Thermal (Shade of Red and Green, Bodies are white)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"state","types":["Boolean"]},"right":{"text":"modeIndex","types":["Number"]}}],"examples":[{"text":"```sqf\ntrue setCamUseTI 1;\n```","code":["true setCamUseTI 1;"]},{"text":"*Predator* vision:\n\n```sqf\n_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, 1, 1.5];\n_cam cameraEffect [\"Internal\", \"Back\"];\n_cam camCommit 0;\ntrue setCamUseTI 7;\n```","code":["_cam = \"camera\" camCreate [0, 0, 0];\n_cam camSetTarget player;\n_cam camSetRelPos [0, 1, 1.5];\n_cam cameraEffect [\"Internal\", \"Back\"];\n_cam camCommit 0;\ntrue setCamUseTI 7;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camUseNVG","disableTIEquipment"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setCaptive","operator":null,"title":"setCaptive","type":"command","url":"https://community.bistudio.com/wiki/setCaptive","revid":338620,"updated":"2023-03-24T10:44:44Z","groups":["Object Manipulation","Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Mark a unit as captive. If unit is a vehicle, commander is marked. A captive unit:\n- is seen as belonging to the civilian Side\n- will not be fired upon\n- will still shoot at its real side's enemies\n- will make its killer earn/lose score/rating as usual\n- will not get its weapons removed (see removeAllWeapons)\n- will not trigger \"detected by\" conditions for its original Side.\n\n> [!NOTE]\n> The number used as status can be retrieved by captiveNum to keep track of the captivity status at a finer resolution (e.g. handcuffed, grouped, etc).","syntaxes":[{"syntax":"unitName setCaptive status","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"status","type":"Boolean","optional":false,"default":null,"description":"true means captive","types":["Boolean"],"since":null,"text":"status: Boolean - true means captive"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"status","types":["Boolean"]}},{"syntax":"unitName setCaptive statusNumber","since":"arma2 1.00","effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"statusNumber","type":"Number","optional":false,"default":null,"description":"zero means non-captive, a non-zero value means captive; see captiveNum","types":["Number"],"since":null,"text":"statusNumber:  Number - zero means non-captive, a non-zero value means captive; see captiveNum"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"statusNumber","types":["Number"]}}],"examples":[{"text":"```sqf\n_soldier1 setCaptive true;\nside _soldier1;            // returns civilian\nside group _soldier1;    // returns e.g blufor\n```","code":["_soldier1 setCaptive true;\nside _soldier1;\t\t\t// returns civilian\nside group _soldier1;\t// returns e.g blufor"]},{"text":"```sqf\n_soldier1 setCaptive 1;\ncaptive _soldier1;        // returns true\n\n_soldier1 setCaptive 42;\ncaptive _soldier1;        // returns true\n\n_soldier1 setCaptive 0;\ncaptive _soldier1;        // returns false\n```","code":["_soldier1 setCaptive 1;\ncaptive _soldier1;\t\t// returns true\n\n_soldier1 setCaptive 42;\ncaptive _soldier1;\t\t// returns true\n\n_soldier1 setCaptive 0;\ncaptive _soldier1;\t\t// returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["captive","captiveNum"],"notes":[{"user":"Talkingtoaj","date":"2011-01-01T13:11:00Z","text":"If you change a unit from captive to no longer captive (for example, to \"reveal\" an undercover unit), enemy units that already have prior knowledge of the unit as a captive will only partially engage, making it very easy for the undercover unit. This seems to be a bug.\n\nHowever other enemy unit the unit later encounters will engage freely with full force."},{"user":"Lou Montana","date":"2017-11-19T10:58:00Z","text":"**Talkingtoaj**'s note does not apply to Arma 3 anymore (earlier than 1.76)\n\nA captive unit will immediately be shot (after a normal \"human\" reaction time from the AI)"},{"user":"DreadedEntity","date":"2022-04-26T01:15:28Z","text":"In **A3 2.08.149102**, entering an empty vehicle with the same side as the player as defined in `configFile >> \"CfgVehicles\" >> _vehicleClassname >> \"side\"` will briefly switch the side of the vehicle to the side of the player soldier (specifically, while the get in animation is playing), even if captive. Once exiting the vehicle, it will retain that side until the player enters a new vehicle or, seemingly arbitrarily, moves more than 100 meters away from the vehicle `player distance _vehicle > 100`. If the player gets within 100 meters of the vehicle without entering a new vehicle, it will again switch to the players side. This is probably a bug, in my opinion"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setCenterOfMass","operator":null,"title":"setCenterOfMass","type":"command","url":"https://community.bistudio.com/wiki/setCenterOfMass","revid":377797,"updated":"2026-01-03T03:53:45Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Changes the center of mass of an object smoothly during the given time (in seconds). A time of zero (or using the alternative syntax) means an immediate change.","syntaxes":[{"syntax":"myObject setCenterOfMass [centerOfMass, time]","since":null,"effect":null,"exec":null,"params":[{"name":"myObject","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"myObject: Object"},{"name":"centerOfMass","type":"PositionRelative","optional":false,"default":null,"description":"relative to the model centre","types":["PositionRelative"],"since":null,"text":"centerOfMass: PositionRelative - relative to the model centre"},{"name":"time","type":"Number","optional":false,"default":null,"description":"transition time, 0 for instant center of mass transfer","types":["Number"],"since":null,"text":"time: Number - transition time, 0 for instant center of mass transfer"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"myObject","types":["Object"]},"right":{"text":"[centerOfMass, time]","types":["Array"]}},{"syntax":"myObject setCenterOfMass centerOfMass","since":null,"effect":null,"exec":null,"params":[{"name":"myObject","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"myObject: Object"},{"name":"centerOfMass","type":"PositionRelative","optional":false,"default":null,"description":"relative to the model centre","types":["PositionRelative"],"since":null,"text":"centerOfMass: PositionRelative - relative to the model centre"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"myObject","types":["Object"]},"right":{"text":"centerOfMass","types":["PositionRelative"]}}],"examples":[{"text":"```sqf\nmyObject setCenterOfMass [[0,-1,0], 0.5];\n```","code":["myObject setCenterOfMass [[0,-1,0], 0.5];"]},{"text":"```sqf\nmyObject setCenterOfMass [0,-1,0];\n```","code":["myObject setCenterOfMass [0,-1,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCenterOfMass","setMass","getMass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setCollisionLight","operator":null,"title":"setCollisionLight","type":"command","url":"https://community.bistudio.com/wiki/setCollisionLight","revid":319554,"updated":"2022-05-13T09:24:28Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Switches collision lights of a vehicle on/off.","syntaxes":[{"syntax":"vehicle setCollisionLight set","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"set","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"set: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\nheli setCollisionLight true;\n```","code":["heli setCollisionLight true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isLightOn","isCollisionLightOn","setPilotLight","isIRLaserOn","engineOn","isEngineOn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setCombatBehaviour","operator":null,"title":"setCombatBehaviour","type":"command","url":"https://community.bistudio.com/wiki/setCombatBehaviour","revid":321904,"updated":"2022-05-22T11:02:37Z","groups":["AI Behaviour","Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets an individual unit entity behaviour (main syntax) or a group entity behaviour (alternative syntax). The group in this case is a Group entity and not a simple collection of units. To retrieve unit or group behaviour see combatBehaviour. The behaviour is one of:\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"\n\n> [!NOTE]\n> See AI Behaviour for details of the effect of this command on AI units. Group behaviour usually is \"CARELESS\" or \"SAFE\"\n\n| Command | Applies To |\n|---|---|\n| setBehaviour | **Every unit** in the group, but **not the group** itself |\n| setBehaviourStrong | **Every unit** in the group, and the **group** itself |\n| setCombatBehaviour | If argument is Object, only that **unit**, and if argument is Group, the **group** itself (not its units) |","syntaxes":[{"syntax":"unit setCombatBehaviour behaviour","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"AI unit","types":["Object"],"since":null,"text":"unit: Object - AI unit"},{"name":"behaviour","type":"String","optional":false,"default":null,"description":"see description","types":["String"],"since":null,"text":"behaviour: String - see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"behaviour","types":["String"]}},{"syntax":"group setCombatBehaviour behaviour","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"AI group","types":["Group"],"since":null,"text":"group: Group - AI group"},{"name":"behaviour","type":"String","optional":false,"default":null,"description":"see description","types":["String"],"since":null,"text":"behaviour: String - see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"behaviour","types":["String"]}}],"examples":[{"text":"```sqf\nunit1 setCombatBehaviour \"SAFE\";\n```","code":["unit1 setCombatBehaviour \"SAFE\";"]},{"text":"```sqf\ngroup1 setCombatBehaviour \"CARELESS\";\n```","code":["group1 setCombatBehaviour \"CARELESS\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["AIBehaviour","combatBehaviour","behaviour","setBehaviour","setBehaviourStrong","setWaypointBehaviour","combatMode","setCombatMode","skill","setSkill"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setCombatMode","operator":null,"title":"setCombatMode","type":"command","url":"https://community.bistudio.com/wiki/setCombatMode","revid":364240,"updated":"2024-05-06T09:38:16Z","groups":["Groups","AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets AI group combat mode (engagement rules). For individual unit's combat mode see setUnitCombatMode. Mode may be one of the following:\n- `\"BLUE\"` : Never fire, keep formation\n- `\"GREEN\"` : Hold fire, keep formation\n- `\"WHITE\"` : Hold fire, engage at will/loose formation\n- `\"YELLOW\"` : Fire at will, keep formation\n- `\"RED\"` : Fire at will, engage at will/loose formation\nSee Combat Modes for more information on combat modes.","syntaxes":[{"syntax":"group setCombatMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group or Object","optional":false,"default":null,"description":"if the argument is unit Object, unit's current group is used.","types":["Group","Object"],"since":null,"text":"group: Group or Object - if the argument is unit Object, unit's current group is used."},{"name":"mode","type":"String","optional":false,"default":null,"description":"see description","types":["String"],"since":null,"text":"mode: String - see description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group","Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_group1 setCombatMode \"BLUE\";\n```","code":["_group1 setCombatMode \"BLUE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Combat Modes","Mission Editor: Waypoints","combatMode","behaviour","setBehaviour","skill","setSkill","Arma 3: AI Skill","setUnitCombatMode","unitCombatMode","setCombatBehaviour","combatBehaviour"],"notes":[{"user":".kju","date":"2020-01-01T07:35:00Z","text":"- Combat mode can only be changed via scripting/waypoints - not by player radio commands for an AI group.\n\n- \"Engage at will\" means AI can form subgroups and break off to engage known or assigned enemies. These AI will then act largely on their own.\n- As player one can use the \"engage at will\" radio command to achieve the same/similar behavior. However this will not change the unit's combat mode. Yet one can override the \"keep/loose formation\" status of combat mode with radio commands.\n\n- \"Never fire\" means AI will actually never fire. Whereas under \"Hold fire\", AI will shoot back if getting fired upon, hostiles get too close, or they get a target explicitly assigned by the (sub)group leader.\n- As player, one can override the fire status with radio commands (\"Hold fire\", \"Open fire\", \"Fire\"). However this will not change the unit's combat mode.\n- \"Never fire\"/combat mode blue cannot be overridden by group leader target assignment. One needs to command \"Open fire\" or switch to a different combat mode (with \"Hold fire\") to be able to do so.\n\n- Applying combat mode blue, clears the attack target commands from AI subgroups. Might be useful in combination with doFollow/commandFollow. Note: It will not affect assignedTargets."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setCompassDeclination","operator":null,"title":"setCompassDeclination","type":"command","url":"https://community.bistudio.com/wiki/setCompassDeclination","revid":377875,"updated":"2026-01-04T13:22:06Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the [declination angle](https://en.wikipedia.org/wiki/Magnetic_declination) of player's compass, which is the difference between magnetic north and true north.","syntaxes":[{"syntax":"setCompassDeclination angleRad","since":null,"effect":null,"exec":null,"params":[{"name":"angleRad","type":"Number","optional":false,"default":null,"description":"Declination angle in radians. Use 0 to reset it to default.","types":["Number"],"since":null,"text":"angleRad: Number - Declination angle in radians. Use 0 to reset it to default."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"angleRad","types":["Number"]}}],"examples":[{"text":"```sqf\nsetCompassDeclination rad 10; // declination angle is 10 degrees\n```","code":["setCompassDeclination rad 10; // declination angle is 10 degrees"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCompassOscillation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setCompassOscillation","operator":null,"title":"setCompassOscillation","type":"command","url":"https://community.bistudio.com/wiki/setCompassOscillation","revid":351911,"updated":"2024-01-25T09:37:29Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"This command sets random heading on the player's compass (both in map and in 3D view) with given frequency, which is also randomised.","syntaxes":[{"syntax":"setCompassOscillation [angle, frequencyMin, frequencyMax]","since":null,"effect":null,"exec":null,"params":[{"name":"angle","type":"Number","optional":false,"default":null,"description":"heading deviation angle in radians; the random angle will be picked up from `[-angle...+angle]` range","types":["Number"],"since":null,"text":"angle: Number - heading deviation angle in radians; the random angle will be picked up from `[-angle...+angle]` range"},{"name":"frequencyMin","type":"Number","optional":false,"default":null,"description":"lower bound of heading change in seconds","types":["Number"],"since":null,"text":"frequencyMin: Number - lower bound of heading change in seconds"},{"name":"frequencyMax","type":"Number","optional":false,"default":null,"description":"higher bound of heading change in seconds","types":["Number"],"since":null,"text":"frequencyMax: Number - higher bound of heading change in seconds"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[angle, frequencyMin, frequencyMax]","types":["Array"]}}],"examples":[{"text":"Set compass to oscillate every second within -90/+90 degrees:\n\n```sqf\nsetCompassOscillation [rad 90, 1, 1];\n```","code":["setCompassOscillation [rad 90, 1, 1];"]},{"text":"Change heading every 60 to 90 seconds:\n\n```sqf\nsetCompassOscillation [rad 180, 60, 90];\n```","code":["setCompassOscillation [rad 180, 60, 90];"]},{"text":"Make compass go crazy:\n\n```sqf\nsetCompassOscillation [rad 360, 0.1, 0.2];\n```","code":["setCompassOscillation [rad 360, 0.1, 0.2];"]},{"text":"Reset to default behaviour:\n\n```sqf\nsetCompassOscillation [-1, 0, 0];\n```","code":["setCompassOscillation [-1, 0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["visibleCompass","shownCompass","shownCuratorCompass","showCompass","showCuratorCompass","setCompassDeclination"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setConvoySeparation","operator":null,"title":"setConvoySeparation","type":"command","url":"https://community.bistudio.com/wiki/setConvoySeparation","revid":376358,"updated":"2025-10-07T21:39:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the distance to keep to the vehicle which is **in front**.\n\n- This command has to be applied to all vehicles in a convoy in order to have a separation of, for example, 50 m.\n- Vehicles in a convoy can also have different distances.\n- It's recommended that small values (<10m) should only be used for slowly moving convoys, otherwise AI driven vehicles will leave the road frequently to avoid collisions","syntaxes":[{"syntax":"vehicle setConvoySeparation distance","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"distance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"distance: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\ncursorObject setConvoySeparation 20;\n```","code":["cursorObject setConvoySeparation 20;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceFollowRoad","useAISteeringComponent"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"setCruiseControl","operator":null,"title":"setCruiseControl","type":"command","url":"https://community.bistudio.com/wiki/setCruiseControl","revid":377946,"updated":"2026-01-13T17:58:44Z","groups":["Unit Control","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Limits or sets **local player-controlled** vehicle's speed through cruise control.\n\n> [!NOTE]\n> - this command only works on CarX, TankX, ShipX simulation vehicles\n> - this command is implemented using a PID controller overwriting the vehicle's thrust/brakes input\n\n| Speed Limiter | Cruise Control |\n|---|---|\n| - the vehicle does not accelerate by itself<br>- manually accelerating is required to move forward<br>- accelerating beyond set speed limit is restricted by the PID controller<br>- applying brakes does not disable Speed Limiter<br>- behaviour:<br>  - if the speed is over 120% the set limit, the vehicle will apply 100% of braking and limit acceleration to 0%<br>  - if the speed is below 80% the set limit, the acceleration and braking are untouched<br>  - between 80 and 120%, the PID controller limits the acceleration and applies brakes if required | - the vehicle accelerates by itself<br>- manually accelerating is possible<br>- accelerating above set speed limit is possible<br>- applying brakes disables Cruise Control<br>- behaviour:<br>  - if the speed is over 120% the set limit, the vehicle will apply 100% of braking<br>  - if the speed is below 80% the set limit, the vehicle will apply 100% of acceleration<br>  - between 80 and 120%, the PID controller manages the speed |\n\n> [!IMPORTANT]\n> This command should only be called to *change* values and **not** be called every frame, as it resets the PID controller.","syntaxes":[{"syntax":"vehicle setCruiseControl [speed, autoThrust]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"the vehicle to limit; local player's vehicle (`vehicle player`)","types":["Object"],"since":null,"text":"vehicle: Object - the vehicle to limit; local player's vehicle (`vehicle player`)"},{"name":"speed","type":"Number","optional":false,"default":null,"description":"desired/top speed in km/h. 0 to disable any setting. Only positives values are valid, negative values will make the vehicle unable to move forward","types":["Number"],"since":null,"text":"speed: Number - desired/top speed in km/h. 0 to disable any setting. Only positives values are valid, negative values will make the vehicle unable to move forward"},{"name":"autoThrust","type":"Boolean","optional":false,"default":null,"description":"Boolean\n- true - Cruise Control: the vehicle will maintain this speed until brakes is applied or driver dies or leaves the vehicle\n- false - Speed Limiter: the vehicle will not accelerate above set speed","types":["Boolean"],"since":null,"text":"autoThrust: Boolean\n- true - Cruise Control: the vehicle will maintain this speed until brakes is applied or driver dies or leaves the vehicle\n- false - Speed Limiter: the vehicle will not accelerate above set speed"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[speed, autoThrust]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setCruiseControl [50, true]; // sets cruise control to 50 km/h\n```","code":["vehicle player setCruiseControl [50, true]; // sets cruise control to 50 km/h"]},{"text":"```sqf\nvehicle player setCruiseControl [5, false]; // limits player's vehicle speed to 5 km/h\n```","code":["vehicle player setCruiseControl [5, false]; // limits player's vehicle speed to 5 km/h"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getCruiseControl","limitSpeed","forceSpeed","setAirplaneThrottle"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setCuratorCameraAreaCeiling","operator":null,"title":"setCuratorCameraAreaCeiling","type":"command","url":"https://community.bistudio.com/wiki/setCuratorCameraAreaCeiling","revid":339085,"updated":"2023-04-26T10:54:07Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Sets maximal (ATL) height to which curator camera can move.","syntaxes":[{"syntax":"curatorObj setCuratorCameraAreaCeiling height","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"Curator module","types":["Object"],"since":null,"text":"curatorObj: Object - Curator module"},{"name":"height","type":"Number","optional":false,"default":null,"description":"ATL, in metres","types":["Number"],"since":null,"text":"height: Number - ATL, in metres"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\nmyCurator setCuratorCameraAreaCeiling 50;\n```","code":["myCurator setCuratorCameraAreaCeiling 50;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3 Curator","addCuratorCameraArea","removeCuratorCameraArea","removeAllCuratorCameraAreas","curatorCameraArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setCuratorCoef","operator":null,"title":"setCuratorCoef","type":"command","url":"https://community.bistudio.com/wiki/setCuratorCoef","revid":348442,"updated":"2023-11-08T13:00:15Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Sets coef for some action (coef have to be bigger than -1 000 000, anything lower is considered as disabled action).","syntaxes":[{"syntax":"curatorObj setCuratorCoef [action, coef]","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"},{"name":"action","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"Place\"\n- \"Edit\"\n- \"Delete\"\n- \"Destroy\"\n- \"Group\"\n- \"Synchronize\"","types":["String"],"since":null,"text":"action: String - can be one of:\n- \"Place\"\n- \"Edit\"\n- \"Delete\"\n- \"Destroy\"\n- \"Group\"\n- \"Synchronize\""},{"name":"coef","type":"Number or Boolean","optional":false,"default":null,"description":null,"types":["Number","Boolean"],"since":null,"text":"coef: Number or Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"[action, coef]","types":["Array"]}}],"examples":[{"text":"```sqf\ncuratorModule setCuratorCoef [\"Place\", 1];\n```","code":["curatorModule setCuratorCoef [\"Place\", 1];"]},{"text":"```sqf\ncuratorModule setCuratorCoef [\"Delete\", -1e10];\n```","code":["curatorModule setCuratorCoef [\"Delete\", -1e10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setCuratorEditingAreaType","operator":null,"title":"setCuratorEditingAreaType","type":"command","url":"https://community.bistudio.com/wiki/setCuratorEditingAreaType","revid":348452,"updated":"2023-11-08T13:00:17Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Set whether curator can edit in all editing areas (true) or outside of them (false).","syntaxes":[{"syntax":"curatorObj setCuratorEditingAreaType bool","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncuratorModule setCuratorEditingAreaType true;\n```","code":["curatorModule setCuratorEditingAreaType true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorEditingArea","removeCuratorEditingArea","removeAllCuratorEditingAreas","curatorEditingArea"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setCuratorSelected","operator":null,"title":"setCuratorSelected","type":"command","url":"https://community.bistudio.com/wiki/setCuratorSelected","revid":378373,"updated":"2026-04-03T16:53:54Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Clear and set the curator selected items. Leave the items array empty to clear curator selection.","syntaxes":[{"syntax":"setCuratorSelected items","since":null,"effect":null,"exec":null,"params":[{"name":"items","type":"Array of Objects, Groups, Waypoints, or Strings","optional":false,"default":null,"description":"flat array of items to set; strings are marker names","types":["Array","Object","Group","Waypoint","String"],"since":null,"text":"items: Array of Objects, Groups, Waypoints, or Strings - flat array of items to set; strings are marker names"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"items","types":["Array","Object","Group","Waypoint","String"]}}],"examples":[{"text":"```sqf\nsetCuratorSelected [unit1, group1, [group1, waypointIndex], markerName1];\n```","code":["setCuratorSelected [unit1, group1, [group1, waypointIndex], markerName1];"]},{"text":"```sqf\nsetCuratorSelected [vehicle1, unit1, unit2, unit3, unit4, group1];\n```","code":["setCuratorSelected [vehicle1, unit1, unit2, unit3, unit4, group1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["curatorMouseOver","curatorSelected","addCuratorSelected","curatorEditableObjects","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"setCuratorSelectionPreset","operator":null,"title":"setCuratorSelectionPreset","type":"command","url":"https://community.bistudio.com/wiki/setCuratorSelectionPreset","revid":377070,"updated":"2026-01-01T09:30:47Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the list of objects in the given selection preset. Only Object is supported in selection presets, unlike curatorSelected which also returns the selected Group, Waypoint, and Marker String","syntaxes":[{"syntax":"numkey setCuratorSelectionPreset objects","since":null,"effect":null,"exec":null,"params":[{"name":"numkey","type":"Number","optional":false,"default":null,"description":"number key under which the selection preset is saved","types":["Number"],"since":null,"text":"numkey: Number - number key under which the selection preset is saved"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":"objects to save to the selection preset","types":["Array","Object"],"since":null,"text":"objects: Array of Objects - objects to save to the selection preset"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"numkey","types":["Number"]},"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n1 setCuratorSelectionPreset [object1, object2];\n```","code":["1 setCuratorSelectionPreset [object1, object2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["curatorSelectionPreset","loadCuratorSelectionPreset","curatorSelected","setCuratorSelected","addCuratorSelected","Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"setCuratorWaypointCost","operator":null,"title":"setCuratorWaypointCost","type":"command","url":"https://community.bistudio.com/wiki/setCuratorWaypointCost","revid":348446,"updated":"2023-11-08T13:00:16Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Sets cost of waypoints (used for placing, editing and deleting).","syntaxes":[{"syntax":"curatorObj setCuratorWaypointCost cost","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module","types":["Object"],"since":null,"text":"curatorObj: Object - curator module"},{"name":"cost","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"cost: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"curatorObj","types":["Object"]},"right":{"text":"cost","types":["Number"]}}],"examples":[{"text":"```sqf\nmyCurator setCuratorWaypointCost 0.1;\n```","code":["myCurator setCuratorWaypointCost 0.1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setCurrentChannel","operator":null,"title":"setCurrentChannel","type":"command","url":"https://community.bistudio.com/wiki/setCurrentChannel","revid":376800,"updated":"2025-11-20T17:47:43Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets given channel as current chat channel. Scripted way of selecting desired channel on the UI.\nThe given channel may be disabled (see enableChannel), this is why this command returns boolean, true on success or false on failure.\n\n| channel ID number correspondence |  |  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| N/A | Global | Side | Command | Group | Vehicle | Direct | Custom1 | .. | Custom10 | Arma 3 v2.22 Custom11 | .. | Custom50 |\n| -1 | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 15 | 26 | 65 |  |  |","syntaxes":[{"syntax":"setCurrentChannel channelID","since":null,"effect":null,"exec":null,"params":[{"name":"channelID","type":"Number","optional":false,"default":null,"description":"channel ID","types":["Number"],"since":null,"text":"channelID: Number - channel ID"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"unary","operator":null,"left":null,"right":{"text":"channelID","types":["Number"]}}],"examples":[{"text":"```sqf\n_isDirectSelected = setCurrentChannel 5; // sets Direct channel as current active\n```","code":["_isDirectSelected = setCurrentChannel 5; // sets Direct channel as current active"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPlayerChannel","currentChannel","enableChannel","channelEnabled","radioChannelCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.42","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setCurrentTask","operator":null,"title":"setCurrentTask","type":"command","url":"https://community.bistudio.com/wiki/setCurrentTask","revid":319791,"updated":"2022-05-13T09:24:54Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the task as a current task of the person.","syntaxes":[{"syntax":"object setCurrentTask task","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"the unit having the task","types":["Object"],"since":null,"text":"object: Object - the unit having the task"},{"name":"task","type":"Task","optional":false,"default":null,"description":"the task you want to select","types":["Task"],"since":null,"text":"task: Task - the task you want to select"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\nplayer setCurrentTask tskKillSpongebob;\n```","code":["player setCurrentTask tskKillSpongebob;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleTask","simpleTasks","currentTask"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setCurrentWaypoint","operator":null,"title":"setCurrentWaypoint","type":"command","url":"https://community.bistudio.com/wiki/setCurrentWaypoint","revid":377752,"updated":"2026-01-03T00:58:07Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets the currently active waypoint for a group.","syntaxes":[{"syntax":"groupName setCurrentWaypoint waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"groupName: Object or Group"},{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Object","Group"]},"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_grp setCurrentWaypoint [_grp, 1];\n```","code":["_grp setCurrentWaypoint [_grp, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setCustomAimCoef","operator":null,"title":"setCustomAimCoef","type":"command","url":"https://community.bistudio.com/wiki/setCustomAimCoef","revid":319776,"updated":"2022-05-13T09:24:52Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set custom aim precision coefficient for weapon sway","syntaxes":[{"syntax":"unit setCustomAimCoef coef","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"coef","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"coef: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"coef","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setCustomAimCoef 3;\n```","code":["player setCustomAimCoef 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","getCustomAimCoef","getWeaponSway"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setCustomMissionData","operator":null,"title":"setCustomMissionData","type":"command","url":"https://community.bistudio.com/wiki/setCustomMissionData","revid":377102,"updated":"2026-01-01T09:58:54Z","groups":["Diagnostic"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines custom mission text that is sent to Arma 3: Analytics.","syntaxes":[{"syntax":"setCustomMissionData data","since":null,"effect":null,"exec":null,"params":[{"name":"data","type":"Array of Strings","optional":false,"default":null,"description":"A maximum of five strings is allowed, each string with a maximum length of 16 characters","types":["Array","String"],"since":null,"text":"data: Array of Strings - A maximum of five strings is allowed, each string with a maximum length of 16 characters"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"data","types":["Array","String"]}}],"examples":[{"text":"```sqf\nsetCustomMissionData [\"someData\", \"someMoreData\"];\n```","code":["setCustomMissionData [\"someData\", \"someMoreData\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Diagnostic","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"setCustomSoundController","operator":null,"title":"setCustomSoundController","type":"command","url":"https://community.bistudio.com/wiki/setCustomSoundController","revid":309208,"updated":"2022-05-03T22:18:23Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.86"}],"since":{"game":"arma3","name":"Arma 3","version":"1.86"},"arma3_since":"1.86","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets value of the specified custom sound controller to be used in simple expressions in config. Returns true if value was set to the controller, false if command fails, for example if vehicle is not a transport or controller name is not recognised.\n\n> [!IMPORTANT]\n> Custom sound controller name is case sensitive and of the following format:\n>\n> ```sqf\n> format [\"CustomSoundController%1\", _number];\n> ```\n>\n> Where `_number` is a number from 1 to getCustomSoundControllerCount (currently 32)","syntaxes":[{"syntax":"setCustomSoundController [vehicle, controller, value]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a transport type vehicle. Does not work on characters or buildings","types":["Object"],"since":null,"text":"vehicle: Object - a transport type vehicle. Does not work on characters or buildings"},{"name":"controller","type":"String","optional":false,"default":null,"description":"name of the custom sound controller - needs to be full string e.g \"CustomSoundController1\". It goes from \"CustomSoundController1\" to \"CustomSoundController32\"","types":["String"],"since":null,"text":"controller: String - name of the custom sound controller - needs to be full string e.g \"CustomSoundController1\". It goes from \"CustomSoundController1\" to \"CustomSoundController32\""},{"name":"value","type":"Number","optional":false,"default":null,"description":"desired value","types":["Number"],"since":null,"text":"value: Number - desired value"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, controller, value]","types":["Array"]}}],"examples":[{"text":"Change value of CustomSoundController1 to 12\n\n```sqf\nsetCustomSoundController [vehicle player, \"CustomSoundController1\", 12];\n```","code":["setCustomSoundController [vehicle player, \"CustomSoundController1\", 12];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Sound","getCustomSoundController","getCustomSoundControllerCount","getSoundController","getSoundControllerResult","getAllSoundControllers","getEnvSoundController","getAllEnvSoundControllers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 1.86","Scripting Commands"]},{"name":"setCustomWeightRTD","operator":null,"title":"setCustomWeightRTD","type":"command","url":"https://community.bistudio.com/wiki/setCustomWeightRTD","revid":377783,"updated":"2026-01-03T01:32:40Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add virtual custom weight to a helicopter's center of gravity. This can be used to simulate added internal payload for specific scenarios, and affects the flight model.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD setCustomWeightRTD weight","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD : ObjectRTD - helicopter"},{"name":"weight","type":"Number","optional":false,"default":null,"description":"weight (kilograms)","types":["Number"],"since":null,"text":"weight: Number - weight (kilograms)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"weight","types":["Number"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD setCustomWeightRTD 120;\n```","code":["myHelicopterRTD setCustomWeightRTD 120;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weightRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setDamage","operator":null,"title":"setDamage","type":"command","url":"https://community.bistudio.com/wiki/setDamage","revid":378306,"updated":"2026-04-01T22:21:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"|  |  |  |\n|---|---|---|\n| + | Event Handler | Triggered |\n| `Hit` | ✗ |  |\n| `HandleDamage` | ✗ |  |\n| `Killed` | ✓ |  |\n| `MPKilled` | ✓ |  |\n\nSets the damage (or lack thereof) of an object/unit. The alternative syntax allows to skip destruction effects for vehicles and buildings and set a tree/pole/wall fall direction (away from *killer*).","syntaxes":[{"syntax":"object setDamage damage","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"damage","type":"Number","optional":false,"default":null,"description":"range 0..1, 0 = pristine/healthy condition, 1 = entirely destroyed/killed","types":["Number"],"since":null,"text":"damage: Number - range 0..1, 0 = pristine/healthy condition, 1 = entirely destroyed/killed"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"damage","types":["Number"]}},{"syntax":"object setDamage [damage, useEffects, killer, instigator, allowResurrection]","since":"arma3 1.68","effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"damage","type":"Number","optional":false,"default":null,"description":"range 0..1, 0 = pristine/healthy condition, 1 = entirely destroyed/killed","types":["Number"],"since":null,"text":"damage: Number - range 0..1, 0 = pristine/healthy condition, 1 = entirely destroyed/killed"},{"name":"useEffects","type":"Boolean","optional":true,"default":"true","description":"false to skip destruction effects","types":["Boolean"],"since":null,"text":"useEffects: Boolean (Optional, default true) - false to skip destruction effects"},{"name":"Server Execution killer","type":"Object","optional":true,"default":"objNull","description":"the entity that caused the damage (can be anything). If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n- it can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n- it will alter the killer's rating as if the killer directly killed the unit\n- it will be listed as `_killer` parameter in the Killed event handler\n- it influences a tree/pole/wall fall direction (it will fall *away* from *killer*)\n- *killer* is ignored if setDamage is called on a player client machine unless *object* is one of these three entity types - see #Example 3\n- MP restricted similar to setShotParents, will be ignored unless executed on the server or headless client in MP","types":["Object"],"since":"arma3 2.12","text":"Server Execution killer: Object - (Optional, default objNull) the entity that caused the damage (can be anything). If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n- it can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n- it will alter the killer's rating as if the killer directly killed the unit\n- it will be listed as `_killer` parameter in the Killed event handler\n- it influences a tree/pole/wall fall direction (it will fall *away* from *killer*)\n- *killer* is ignored if setDamage is called on a player client machine unless *object* is one of these three entity types - see #Example 3\n- MP restricted similar to setShotParents, will be ignored unless executed on the server or headless client in MP"},{"name":"Server Execution instigator","type":"Object","optional":true,"default":"objNull","description":"the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler\n- MP restricted similar to setShotParents, will be ignored unless executed on the server or headless client in MP\n  - the above MP restriction does not apply to trees, poles and walls","types":["Object"],"since":"arma3 2.12","text":"Server Execution instigator: Object - (Optional, default objNull) the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler\n- MP restricted similar to setShotParents, will be ignored unless executed on the server or headless client in MP\n  - the above MP restriction does not apply to trees, poles and walls"},{"name":"allowResurrection","type":"Boolean","optional":true,"default":"false","description":"Will re-set alive state of previously dead object.","types":["Boolean"],"since":"arma3 2.22","text":"allowResurrection: Boolean - (Optional, default false) - Will re-set alive state of previously dead object."},{"name":"shot","type":"Object","optional":true,"default":"objNull","description":"shot that caused the damage.","types":["Object"],"since":"arma3 2.22","text":"shot: Object - (Optional, default objNull) - shot that caused the damage."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[damage, useEffects, killer, instigator, allowResurrection]","types":["Array"]}}],"examples":[{"text":"```sqf\n_soldier1 setDamage 1;\n```","code":["_soldier1 setDamage 1;"]},{"text":"```sqf\n_house1 setDamage [1, false];\n```","code":["_house1 setDamage [1, false];"]},{"text":"```sqf\n// executed on a client\n_remoteVehicle setDamage [1, true, player];    // killer (here, player) is not considered if the command is not called on the server\n                                            // the vehicle still gets destroyed\n\n_tree setDamage [1, true, player];            // the tree is destroyed and falls away from the player\n_pole setDamage [1, true, player];            // these three cases are the only ones where ''killer'' is considered\n_wall setDamage [1, true, player];            // when setDamage is called on a non-server machine (neither server or headless client)\n```","code":["// executed on a client\n_remoteVehicle setDamage [1, true, player];\t// killer (here, player) is not considered if the command is not called on the server\n\t\t\t\t\t\t\t\t\t\t\t// the vehicle still gets destroyed\n\n_tree setDamage [1, true, player];\t\t\t// the tree is destroyed and falls away from the player\n_pole setDamage [1, true, player];\t\t\t// these three cases are the only ones where ''killer'' is considered\n_wall setDamage [1, true, player];\t\t\t// when setDamage is called on a non-server machine (neither server or headless client)"]}],"multiplayer":null,"problems":null,"aliases":["setDammage"],"see_also":["setVehicleArmor","damage","setHit","getHit","getHitIndex","setHitIndex","getHitPointDamage","setHitPointDamage"],"notes":[{"user":"Fragorl","date":"2006-04-17T07:36:00Z","text":"In **Operation Flashpoint**, setting a unit's damage to a negative value will set it is health to full, but impair their aim."},{"user":"KamikazeXeX","date":"2015-05-29T11:23:00Z","text":"Using this possible overrides individual hit damages such as setHitPointDamage [\"HitHead\", _value]; if you're having issues try setting hitdamage *after* setdamage."},{"user":"Sarogahtyp","date":"2021-06-24T10:31:00Z","text":"You are able to repair buildings with this command if you just store the original object and use setDamage on this and not on the wreck which is shown after the building was destroyed. This works in debug console when pointing a house:\n\n```sqf\n0 spawn\n{\n    private _house = cursorObject;\n    _house setDamage 1;\n    sleep 5;\n    _house setDamage 0;\n};\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setDammage","operator":null,"title":"setDammage","type":"command","url":"https://community.bistudio.com/wiki/setDammage","revid":351537,"updated":"2023-12-06T23:01:31Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Entirely identical to setDamage that was introduced to fix a typographical error in the command's name.\n\n> [!NOTE]\n> See setDamage for this command's documentation.","syntaxes":[{"syntax":"-","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"-","types":[],"description":null,"text":"-"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":["setDamage"],"see_also":["setDamage"],"notes":[{"user":"Fragorl","date":"2006-04-17T07:39:00Z","text":"In **Operation Flashpoint**, setting a unit's damage to a negative value will set it is health to full, but impair their aim."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setDate","operator":null,"title":"setDate","type":"command","url":"https://community.bistudio.com/wiki/setDate","revid":377265,"updated":"2026-01-02T06:34:05Z","groups":["Mission Information","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets mission date and time. Players joining after mission start will get the current server date including the year.\n\n> [!IMPORTANT]\n> While the game creates February 29th in a leap year, it removes December 31st.\n>\n> For example, `setDate [1980,12,31,12,0]` will result in the game jumping to [1981,1,1,12,0] as 1980 is a leap year.","syntaxes":[{"syntax":"setDate date","since":null,"effect":null,"exec":null,"params":[{"name":"date","type":"Date","optional":false,"default":null,"description":null,"types":["Date"],"since":null,"text":"date: Date"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"date","types":["Date"]}}],"examples":[{"text":"```sqf\nsetDate [1986, 2, 25, 16, 0]; // 4:00pm February 25, 1986\n```","code":["setDate [1986, 2, 25, 16, 0]; // 4:00pm February 25, 1986"]},{"text":"```sqf\n// Set the real date:\nif (isServer) then\n{\n    waitUntil { time > 0 };\n    [systemTime select [0, 5]] remoteExec [\"setDate\"];\n};\n```","code":["// Set the real date:\nif (isServer) then\n{\n\twaitUntil { time > 0 };\n\t[systemTime select [0, 5]] remoteExec [\"setDate\"];\n};"]},{"text":"Using setDate with an incorrect (like negative or exceeding) value will still work properly:\n\n```sqf\nprivate _date = date;\n_date set [3, 25];    // set hour to 25\nsetDate _date;        // date = next day 1am\n```","code":["private _date = date;\n_date set [3, 25];\t// set hour to 25\nsetDate _date;\t\t// date = next day 1am"]}],"multiplayer":"> [!NOTE]\n> **Arma 3:** Clients' local date is automatically and periodically synchronised with the server date.\n>\n> In order to change the date without waiting for automatic synchronisation, use remote execution: `[[2001,6,22,12,0]] remoteExec [\"setDate\"];`.","problems":null,"aliases":[],"see_also":["date","skipTime","numberToDate","dateToNumber"],"notes":[{"user":"Alpha","date":"2012-12-07T11:10:00Z","text":"This command sets the date for the southern hemisphere only, i.e. when the map is in northern hemisphere a date [2010,12,7,17,0] is in day light and and date [2010,6,7,17,0] is in darkness."},{"user":"Osmo","date":"2011-10-31T21:07:00Z","text":"In multiplayer, the effect of this command is local, not global. The date from the server is synchronized with clients when they join the game (including start of the mission and joining in progress). E.g. if this command is executed on server in the init.sqf before the mission starts, every client will be synchronized with server as mission is started. However, if you run this command in the middle of the mission, effect is local."},{"user":"MulleDK13","date":"2014-10-04T17:43:00Z","text":"Since an unknown version of Arma 3, this command now has global effect when executed on the server."},{"user":"OOKexOo","date":"2017-04-23T02:58:00Z","text":"Regarding execution in the middle of a session, the post of MulleDK13 is not entirely true. If you don't change the year, you are perfectly fine when executing the command on the server only. However, the server does not sync the year. Hence, if you do change the year, you have to execute the command on the server, clients and JIP to account for the missing sync. e.g.\n\n```sqf\n[[], { setDate [1986, 2, 25, 16, 0] }] remoteExec [\"call\", 0, \"JIP_id_setDate\"];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Mission Information","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setDebriefingText","operator":null,"title":"setDebriefingText","type":"command","url":"https://community.bistudio.com/wiki/setDebriefingText","revid":363195,"updated":"2024-03-25T16:31:09Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets debriefing title, text, subtitle, picture and background for a mission ending.\nThe end type could be the engine-defined (\"CONTINUE\", \"KILLED\", \"LOSER\", \"END1\", \"END2\", \"END3\", \"END4\", \"END5\", \"END6\"), config-defined (see CfgDebriefing) or, with an alternative syntax of this command, any String.\nGiven texts will be used to replace the corresponding texts on the debriefing screen.\n\n> [!IMPORTANT]\n> In order to benefit from alternative syntax functionality, there will have to be at least **three** arguments passed to the command; **two** arguments will trigger the old behaviour.","syntaxes":[{"syntax":"endType setDebriefingText [title, description]","since":null,"effect":null,"exec":null,"params":[{"name":"endType","type":"String","optional":false,"default":null,"description":"engine type","types":["String"],"since":null,"text":"endType: String - engine type"},{"name":"title","type":"String","optional":false,"default":null,"description":"title text on the debriefing screen","types":["String"],"since":null,"text":"title: String - title text on the debriefing screen"},{"name":"description","type":"String","optional":false,"default":null,"description":"description text on the debriefing screen","types":["String"],"since":null,"text":"description: String - description text on the debriefing screen"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"endType","types":["String"]},"right":{"text":"[title, description]","types":["Array"]}},{"syntax":"endType setDebriefingText [title, description, subtitle, picture, background]","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"endType","type":"String","optional":false,"default":null,"description":"any name","types":["String"],"since":null,"text":"endType: String - any name"},{"name":"title","type":"String","optional":false,"default":null,"description":"title text on the debriefing screen","types":["String"],"since":null,"text":"title: String - title text on the debriefing screen"},{"name":"description","type":"String","optional":false,"default":null,"description":"description text on the debriefing screen","types":["String"],"since":null,"text":"description: String - description text on the debriefing screen"},{"name":"subtitle","type":"String","optional":false,"default":null,"description":"subtitle text on the debriefing screen (**must** be defined in order to trigger this syntax of the command)","types":["String"],"since":null,"text":"subtitle: String - subtitle text on the debriefing screen (**must** be defined in order to trigger this syntax of the command)"},{"name":"picture","type":"String","optional":true,"default":null,"description":"title picture","types":["String"],"since":null,"text":"picture: String - (Optional) title picture"},{"name":"background","type":"String","optional":true,"default":null,"description":"background picture","types":["String"],"since":null,"text":"background: String - (Optional) background picture"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"endType","types":["String"]},"right":{"text":"[title, description, subtitle, picture, background]","types":["Array"]}}],"examples":[{"text":"```sqf\n_currentObjective = (taskDescription currentTask player) select 2;\n\"endDeath\" setDebriefingText [\"You Lose\", \"All of your men were killed while assaulting the \" + _currentObjective];\n```","code":["_currentObjective = (taskDescription currentTask player) select 2;\n\"endDeath\" setDebriefingText [\"You Lose\", \"All of your men were killed while assaulting the \" + _currentObjective];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getDebriefingText","disableDebriefingStats","enableDebriefingStats","endMission","failMission","missionEnd"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setDefaultCamera","operator":null,"title":"setDefaultCamera","type":"command","url":"https://community.bistudio.com/wiki/setDefaultCamera","revid":377593,"updated":"2026-01-02T06:59:17Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.10"}],"since":{"game":"arma3","name":"Arma 3","version":"1.10"},"arma3_since":"1.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the position and direction for the camera used after camera is set on no object (log out view when leaving MP game for example)","syntaxes":[{"syntax":"setDefaultCamera [position, direction]","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"PositionASL","optional":false,"default":null,"description":"position of the camera","types":["PositionASL"],"since":null,"text":"position: PositionASL - position of the camera"},{"name":"direction","type":"Vector3D","optional":false,"default":null,"description":"direction of the camera","types":["Vector3D"],"since":null,"text":"direction: Vector3D - direction of the camera"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[position, direction]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetDefaultCamera [[5000, 5000, 200], [1, 1, -1]];\n```","code":["setDefaultCamera [[5000, 5000, 200], [1, 1, -1]];"]},{"text":"Lift camera 100m up above current player position and point downwards:\n\n```sqf\nsetDefaultCamera [ATLToASL (player modelToWorld [0, 0, 100]), [0, 0, -1]];\n```","code":["setDefaultCamera [ATLToASL (player modelToWorld [0, 0, 100]), [0, 0, -1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["camCreate","cameraOn","cameraView","cameraEffect","cameraEffectEnableHUD","switchCamera","positionCameraToWorld","cameraInterest","setCameraInterest","getEditorCamera","mapCenterOnCamera","preloadCamera","restartEditorCamera"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Arma 3 version 1.10","Scripting Commands"]},{"name":"setDestination","operator":null,"title":"setDestination","type":"command","url":"https://community.bistudio.com/wiki/setDestination","revid":377507,"updated":"2026-01-02T06:50:09Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set the destination for path planning of the pilot.\n\nPossible values for planningMode are:\n\n- \"DoNotPlan\" - used when not moving\n- \"DoNotPlanFormation\" - used in formation when simple path testing is used\n- \"LEADER PLANNED\" - used for formation leader (full path finding used)\n- \"LEADER DIRECT\" - used for DirectGo (like getin, supply)\n- \"FORMATION PLANNED\" - used in formation when full path finding is used\n- \"VEHICLE PLANNED\" - used for vehicle driver\n\nWorks best when used on agents. Using \"LEADER PLANNED\" will trigger `\"PathCalculated\"` Event Handler","syntaxes":[{"syntax":"object setDestination [position, planningMode, forceReplan]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"position: Position"},{"name":"planningMode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"planningMode: String"},{"name":"forceReplan","type":"Boolean","optional":false,"default":null,"description":"specifies if replanning of the path should be forced.","types":["Boolean"],"since":null,"text":"forceReplan: Boolean - specifies if replanning of the path should be forced."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[position, planningMode, forceReplan]","types":["Array"]}}],"examples":[{"text":"```sqf\nbob setDestination [screenToWorld [0.5,0.5], \"LEADER PLANNED\", true];\n```","code":["bob setDestination [screenToWorld [0.5,0.5], \"LEADER PLANNED\", true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["expectedDestination","doMove","calculatePath"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setDetailMapBlendPars","operator":null,"title":"setDetailMapBlendPars","type":"command","url":"https://community.bistudio.com/wiki/setDetailMapBlendPars","revid":321456,"updated":"2022-05-14T14:48:21Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the detail texture map blend pars. Allows for smooth transition between detailed and undetailed terrain texture at distance.\n- If *noDetail* > *fullDetail*, the texture detail will incur smooth transition in the area between the thresholds.\n- If *noDetail* <= *fullDetail*, there will be obvious visible edge between texture detail changes at *fullDetail* distance.","syntaxes":[{"syntax":"setDetailMapBlendPars [fullDetail, noDetail]","since":null,"effect":null,"exec":null,"params":[{"name":"fullDetail","type":"Number","optional":false,"default":null,"description":"threshold distance in metres up to which the terrain will have full texture detail","types":["Number"],"since":null,"text":"fullDetail: Number - threshold distance in metres up to which the terrain will have full texture detail"},{"name":"noDetail","type":"Number","optional":false,"default":null,"description":"threshold distance in metres after which the texture detail will be switched off","types":["Number"],"since":null,"text":"noDetail: Number - threshold distance in metres after which the texture detail will be switched off"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[fullDetail, noDetail]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetDetailMapBlendPars [20, 50];\n```","code":["setDetailMapBlendPars [20, 50];"]},{"text":"```sqf\nsetDetailMapBlendPars ([[20, 50], [300, 600]] select (currentWeapon player in [\"Binocular\", \"Rangefinder\", \"Laserdesignator\"]));\n```","code":["setDetailMapBlendPars ([[20, 50], [300, 600]] select (currentWeapon player in [\"Binocular\", \"Rangefinder\", \"Laserdesignator\"]));"]},{"text":"Reset to default:\n\n```sqf\nsetDetailMapBlendPars [-1, -1];\n```","code":["setDetailMapBlendPars [-1, -1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setViewDistance","viewDistance","setTerrainGrid","getObjectViewDistance","setObjectViewDistance"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setDiaryRecordText","operator":null,"title":"setDiaryRecordText","type":"command","url":"https://community.bistudio.com/wiki/setDiaryRecordText","revid":322036,"updated":"2022-05-23T22:41:48Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set text of a log record.","syntaxes":[{"syntax":"unit setDiaryRecordText [[subject, diaryRecord], [title, text, icon]]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"subject","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"subject: String"},{"name":"diaryRecord","type":"Diary Record","optional":false,"default":null,"description":null,"types":["Diary Record"],"since":null,"text":"diaryRecord: Diary Record"},{"name":"title","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"title: String"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"},{"name":"icon","type":"String","optional":true,"default":null,"description":"icon to show next to the title. \"\" to remove.","types":["String"],"since":"arma3 2.10","text":"icon: String - (Optional) icon to show next to the title. \"\" to remove."}],"returns":{"type":"Nothing","types":[],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[[subject, diaryRecord], [title, text, icon]]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setDiaryRecordText [[\"diary\", _diaryRec], [\"Kill all enemies.\", \"The enemies are the bad guys. Kill them because you are the good guy.\"]];\n```","code":["player setDiaryRecordText [[\"diary\", _diaryRec], [\"Kill all enemies.\", \"The enemies are the bad guys. Kill them because you are the good guy.\"]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allDiaryRecords","processDiaryLink","createDiaryRecord","createDiarySubject","diarySubjectExists"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"setDiarySubjectPicture","operator":null,"title":"setDiarySubjectPicture","type":"command","url":"https://community.bistudio.com/wiki/setDiarySubjectPicture","revid":349299,"updated":"2023-11-08T14:52:18Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets a picture to be displayed on the right of the Diary subject. The picture can also be set during custom Diary subject creation, but this command also allows to change icon for the fixed subjects, like \"Tasks\", \"Diary\", \"Units\", \"Players\" and \"Statistics\".","syntaxes":[{"syntax":"unit setDiarySubjectPicture [subject, picture]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"},{"name":"subject","type":"String","optional":false,"default":null,"description":"diary subject (see Diary)","types":["String"],"since":null,"text":"subject: String - diary subject (see Diary)"},{"name":"picture","type":"String","optional":false,"default":null,"description":"icon path","types":["String"],"since":null,"text":"picture: String - icon path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[subject, picture]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setDiarySubjectPicture [\"Diary\", \"\\A3\\ui_f\\data\\map\\markers\\nato\\o_mech_inf.paa\"];\n```","code":["player setDiarySubjectPicture [\"Diary\", \"\\A3\\ui_f\\data\\map\\markers\\nato\\o_mech_inf.paa\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createDiarySubject","removeDiarySubject","selectDiarySubject","diarySubjectExists","allDiarySubjects","Diary"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setDir","operator":null,"title":"setDir","type":"command","url":"https://community.bistudio.com/wiki/setDir","revid":373376,"updated":"2025-05-04T21:12:49Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets object heading. Angles are measured in degrees clockwise from north; the regular range goes from 0 to 360 (0° = N, 90° = E, 180° = S, 270° = W). Negative angles represent counter-clockwise angles.\n\n> [!IMPORTANT]\n> This command resets the object's velocity and vectorUp!\n\n> [!NOTE]\n> In *some* earlier titles (Operation Flashpoint?), this command was Local Effect.","syntaxes":[{"syntax":"object setDir heading","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"heading","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"heading: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"heading","types":["Number"]}}],"examples":[{"text":"```sqf\nmyUnit setDir 45; // will set myUnit to face North-East\n```","code":["myUnit setDir 45; // will set myUnit to face North-East"]},{"text":"```sqf\nmyUnit setDir -675; // will also set myUnit to face North-East (= 45-360-360)\n```","code":["myUnit setDir -675; // will also set myUnit to face North-East (= 45-360-360)"]},{"text":"```sqf\nMyUnit setDir 30;\nMyUnit setFormDir 30; // needed for AI to keep the given direction\n```","code":["MyUnit setDir 30;\nMyUnit setFormDir 30; // needed for AI to keep the given direction"]},{"text":"```sqf\n// provided _myMine is local\n_myMine setDir 45;\n_myMine setPosWorld getPosWorld _myMine;\n\n// or\n[_myMine, 45] remoteExec [\"setDir\"];\n```","code":["// provided _myMine is local\n_myMine setDir 45;\n_myMine setPosWorld getPosWorld _myMine;\n\n// or\n[_myMine, 45] remoteExec [\"setDir\"];"]},{"text":"```sqf\n// sets the direction of an object relative to a parent object's direction\n_child setDir (_parentDir + (_childDir - _parentDir));\n```","code":["// sets the direction of an object relative to a parent object's direction\n_child setDir (_parentDir + (_childDir - _parentDir));"]}],"multiplayer":"See the #Notes below","problems":"- The effect is Local Effect when using setDir on a mine. Use a position modification to broadcast setDir's change (see #Example 4)\n- setting direction *after* position may lead to weird behaviours - see #Notes","aliases":[],"see_also":["getDir","direction","setFormDir","setVectorDir","setVectorDirAndUp"],"notes":[{"user":"Manny","date":"2007-05-09T20:43:00Z","text":"Though effects of this command remain local, you can do a setPos* afterwards to synchronize the direction on all machines in MP.\n\n```sqf\nmyObj setDir 90;\nmyObj setPosASL getPosASL myObj;\n```"},{"user":".kju","date":"2001-04-05T10:54:00Z","text":"In Arma 2: Operation Arrowhead 1.59 the comment of Manny still holds true for createVehicle'd empty vehicles by the server.\nFor the player object a local setDir alone is enough."},{"user":"Killzone_Kid","date":"2013-11-25T11:47:00Z","text":"In Arma 3, setDir affects vectorUp, vectorDir and velocity of the object it applied to. While this is not noticeable with stationary objects, a moving objects will have its orientation and velocity reset. So if you are planning on using setDir on a moving object, make sure you read the velocity value before and restore it after if you want the object to continue to move.\n\n```sqf\n_vel = velocity _object;\n_object setDir 45;\n_object setVelocity _vel;\n```\n\nWith orientation it is a bit more complicated. setDir resets vectorUp to [0,0,1] and changes vectorDir accordingly to accommodate set direction. If your object's vectorUp is not [0,0,1] and you want to keep it this way, then you have to use setVectorDirAndUp to change object's direction not setDir. This is also the reason why it is better to use setVectorDirAndUp instead of setDir on attached objects for a better control of object's orientation."},{"user":"Killzone_Kid","date":"2013-11-27T23:09:00Z","text":"Make sure you setDir BEFORE you set position. **Setting direction after set position could lead to unpredictable behaviour**. For example main part of the hospital building in Arma 3 can lose collision detection near both side entrances. AI will also get confused and will stop detecting obstacles if setDir is called after setPos."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setDirection","operator":null,"title":"setDirection","type":"command","url":"https://community.bistudio.com/wiki/setDirection","revid":376967,"updated":"2026-01-01T05:58:28Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the orientation of a location. The location's area and map icon (if its type uses an icon) will be rotated to this orientation.","syntaxes":[{"syntax":"location setDirection direction","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"direction","type":"Number in range 0..360","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"direction: Number in range 0..360"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"direction","types":["Number"]}}],"examples":[{"text":"```sqf\n_location = createLocation [\"VegetationPalm\", getPos player, 200, 200];\n_location setText \"Benargee's Palm Tree\";\n_location setDirection 45;\n```","code":["_location = createLocation [\"VegetationPalm\", getPos player, 200, 200];\n_location setText \"Benargee's Palm Tree\";\n_location setDirection 45;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createLocation","setText","direction"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setDrawIcon","operator":null,"title":"setDrawIcon","type":"command","url":"https://community.bistudio.com/wiki/setDrawIcon","revid":363270,"updated":"2024-03-26T10:51:39Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the icon to be shown in 2D editor for the specified editor object. If maintain size is false,icon will not scale depending on the scale,of the map. If maintain size is a number,the icon will maintain size,if map scale is below that number. is3D,show line and priority are,optional.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setDrawIcon [object,texture,color,offset,width,height,maintain size?,angle,string identifier,shadow,is3D,draw line?,priority]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[object,texture,color,offset,width,height,maintain size?,angle,string identifier,shadow,is3D,draw line?,priority]: Array","type":null,"optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[object,texture,color,offset,width,height,maintain size?,angle,string identifier,shadow,is3D,draw line?,priority]: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object,texture,color,offset,width,height,maintain size?,angle,string identifier,shadow,is3D,draw line?,priority]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setDriveOnPath","operator":null,"title":"setDriveOnPath","type":"command","url":"https://community.bistudio.com/wiki/setDriveOnPath","revid":347683,"updated":"2023-10-10T16:57:57Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the path to follow for AI driver. Note that unitReady will return true even if AI is still driving through the points.\n\nUsing any other *move* command (e.g `_vehicle move getPosATL _vehicle`) or doStop will stop the effect of this command.\n\n> [!IMPORTANT]\n> This command does **not** work if the vehicle doesn't have an AI steering component defined in its config, or if the component is disabled. Thus, it never works on air vehicles and boats which don't use steering components. Only land vehicles may be compatible. (cars, tanks, APCs, etc.)\n\n> [!NOTE]\n> For the command to work properly, the unit must either be an agent, or in the case of normal AI, have been stopped using doStop.","syntaxes":[{"syntax":"vehicleName setDriveOnPath points","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"points","type":"Array","optional":false,"default":null,"description":"list of Positions to format [x,y,z] OR to format [x,y,z, speed], speed being **in m/s**.","types":["Array"],"since":null,"text":"points: Array - list of Positions to format [x,y,z] OR to format [x,y,z, speed], speed being **in m/s**."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"points","types":["Array"]}}],"examples":[{"text":"```sqf\nmyVehicle setDriveOnPath [getMarkerPos \"wp1\", getMarkerPos \"wp2\"];\n```","code":["myVehicle setDriveOnPath [getMarkerPos \"wp1\", getMarkerPos \"wp2\"];"]},{"text":"```sqf\nprivate _points = allMapMarkers apply { getMarkerPos _x; }; // getting all marker positions\n{ _x pushBack 15; } forEach _points; // setting speed\nmyVehicle setDriveOnPath _points;\n```","code":["private _points = allMapMarkers apply { getMarkerPos _x; }; // getting all marker positions\n{ _x pushBack 15; } forEach _points; // setting speed\nmyVehicle setDriveOnPath _points;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["move","forceSpeed","limitSpeed","Waypoint","useAISteeringComponent"],"notes":[{"user":"Leopard20","date":"2021-06-25T07:42:00Z","text":"To use this command, the AI must not have a formLeader. The easiest way to achieve this is to use doStop to stop the AI (warning! it'll break the AI waypoints)"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"setDropInterval","operator":null,"title":"setDropInterval","type":"command","url":"https://community.bistudio.com/wiki/setDropInterval","revid":336719,"updated":"2023-01-04T15:24:43Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set interval of emitting particles from particle source. In Arma 3 hardcoded limit of how many particles can exist at the same time is . Correspondence between CfgCloudlets class param name and command param:\n\n```sqf\nparticleSource setDropInterval interval;\n```","syntaxes":[{"syntax":"particleSource setDropInterval interval","since":null,"effect":null,"exec":null,"params":[{"name":"particleSource","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"particleSource: Object"},{"name":"interval","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"interval: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"particleSource","types":["Object"]},"right":{"text":"interval","types":["Number"]}}],"examples":[{"text":"```sqf\n_source setDropInterval 0.05;\n```","code":["_source setDropInterval 0.05;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["drop","setParticleParams","setParticleRandom","setParticleFire","setParticleCircle"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Particles","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setDynamicSimulationDistance","operator":null,"title":"setDynamicSimulationDistance","type":"command","url":"https://community.bistudio.com/wiki/setDynamicSimulationDistance","revid":363576,"updated":"2024-04-07T11:30:33Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets activation distance of Arma 3: Dynamic Simulation for given category.","syntaxes":[{"syntax":"category setDynamicSimulationDistance distance","since":null,"effect":null,"exec":null,"params":[{"name":"category","type":"String","optional":false,"default":null,"description":"can be one of:\n- `\"Group\"` - infantry units. Set to a reasonable distance, player should not see disabled infantry units. Default value 500m\n- `\"Vehicle\"` - vehicles with crew. Set to a reasonable distance, player should not see disabled vehicles. Default value 350m\n- `\"EmptyVehicle\"` - all vehicles without crew. Separated from Props as Empty Vehicles have often more complex damage states and selective destruction. Their activation distance should be larger than the one used for Props. Default value 250m\n- `\"Prop\"` - static objects. Anything from a small tin can to a building. Default value 50m","types":["String"],"since":null,"text":"category: String - can be one of:\n- `\"Group\"` - infantry units. Set to a reasonable distance, player should not see disabled infantry units. Default value 500m\n- `\"Vehicle\"` - vehicles with crew. Set to a reasonable distance, player should not see disabled vehicles. Default value 350m\n- `\"EmptyVehicle\"` - all vehicles without crew. Separated from Props as Empty Vehicles have often more complex damage states and selective destruction. Their activation distance should be larger than the one used for Props. Default value 250m\n- `\"Prop\"` - static objects. Anything from a small tin can to a building. Default value 50m"},{"name":"distance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"distance: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"category","types":["String"]},"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\n\"Group\" setDynamicSimulationDistance 1000;\n```","code":["\"Group\" setDynamicSimulationDistance 1000;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Dynamic Simulation","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef"],"notes":[{"user":"Demellion","date":"2017-03-19T19:52:00Z","text":"Desired distances for \"Group\" and \"Vehicle\" must be based on viewDistance and fog to exclude any rendering problems with frequently moving objects. Example:\n\n```sqf\n\"Group\" setDynamicSimulationDistance ((viewDistance * 0.8) - (viewDistance * fog)); // 80% of maximum rendering and fog distance\n```\n\nBut that might impair objects simulation if you are using long-scope optics, so there's an even better solution using cameraView with it:\n\n```sqf\n0 spawn {\n    while { true } do\n    {\n        if (cameraView isEqualTo \"GUNNER\") then\n        {\n            \"Group\" setDynamicSimulationDistance (viewDistance - (viewDistance * fog));\n            // Scoped\n        }\n        else\n        {\n            \"Group\" setDynamicSimulationDistance ((viewDistance * 0.8) - (viewDistance * fog));\n            // Not scoped\n        };\n\n        uiSleep 0.25;\n    };\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"setDynamicSimulationDistanceCoef","operator":null,"title":"setDynamicSimulationDistanceCoef","type":"command","url":"https://community.bistudio.com/wiki/setDynamicSimulationDistanceCoef","revid":348832,"updated":"2023-11-08T14:39:08Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets activation distance multiplier of Arma 3: Dynamic Simulation for the given class","syntaxes":[{"syntax":"class setDynamicSimulationDistanceCoef multiplier","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"multiplier class, currently only:\n- `\"IsMoving\"` - Multiplies the entity activation distance by set value if the entity is moving. Default: 2","types":["String"],"since":null,"text":"class: String - multiplier class, currently only:\n- `\"IsMoving\"` - Multiplies the entity activation distance by set value if the entity is moving. Default: 2"},{"name":"multiplier","type":"Number","optional":false,"default":null,"description":"distance multiplier","types":["Number"],"since":null,"text":"multiplier: Number - distance multiplier"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"class","types":["String"]},"right":{"text":"multiplier","types":["Number"]}}],"examples":[{"text":"```sqf\n\"IsMoving\" setDynamicSimulationDistanceCoef 3;\n```","code":["\"IsMoving\" setDynamicSimulationDistanceCoef 3;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"setEditorMode","operator":null,"title":"setEditorMode","type":"command","url":"https://community.bistudio.com/wiki/setEditorMode","revid":363278,"updated":"2024-03-26T10:51:48Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets map mode to MAP,3D or PREVIEW.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setEditorMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setEditorObjectScope","operator":null,"title":"setEditorObjectScope","type":"command","url":"https://community.bistudio.com/wiki/setEditorObjectScope","revid":363242,"updated":"2024-03-26T10:51:18Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"This command defines the level of access a user has to editor objects.\n\n\"objects\" is an array of either Editor Objects (eg [\"_unit_0\"]) or actual Game Objects (eg [player]). If the array is empty then the command will automatically parse all editor objects.\n\n\"editorType\" is the editor type to effect (eg \"unit\", \"vehicle\", \"center\") or \"\" for all types.\n\n\"condition\" is an executable string that must evaluate to true or false. If true, the scope of the evaluated editor object will be modified. \"_x\" can be used in the string as reference to the ingame representation of the currently processed array member.\n\n\"scope\" is one of \"HIDE\", \"VIEW\", \"SELECT\", \"LINKTO\", \"LINKFROM\", \"ALLNODRAG\", \"ALLNOTREE\", \"ALLNOCOPY\", \"ALLNOSELECT\" or \"ALL\".\n\n\"subordinatesAlso\" is a boolean value. If true then subordinates in the editor will be assigned the same scope as the parent.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setEditorObjectScope [objects, editorType, condition, scope, subordinatesAlso]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[objects, editorType, condition, scope, subordinatesAlso]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[objects, editorType, condition, scope, subordinatesAlso]: Array"},{"name":"objects","type":"Array of Objects and/or Editor Objects","optional":false,"default":null,"description":null,"types":["Array","Object","Editor Object"],"since":null,"text":"objects: Array of Objects and/or Editor Objects"},{"name":"editorType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"editorType: String"},{"name":"condition","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"condition: String"},{"name":"scope","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"scope: String"},{"name":"subordinatesAlso","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"subordinatesAlso: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[objects, editorType, condition, scope, subordinatesAlso]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map setEditorObjectScope [[],\"vehicle\", \"side effectiveCommander _x != side player\", \"HIDE\", false];\n```","code":["_map setEditorObjectScope [[],\"vehicle\", \"side effectiveCommander _x != side player\", \"HIDE\", false];"]},{"text":"```sqf\n((findDisplay 128) displayCtrl 51) setEditorObjectScope [[\"_unit_0\"], \"\", \"true\", \"ALLNODRAG\", false];\n```","code":["((findDisplay 128) displayCtrl 51) setEditorObjectScope [[\"_unit_0\"], \"\", \"true\", \"ALLNODRAG\", false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addEditorObject","deleteEditorObject","findEditorObject","getEditorObjectScope","insertEditorObject"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setEffectCondition","operator":null,"title":"setEffectCondition","type":"command","url":"https://community.bistudio.com/wiki/setEffectCondition","revid":377586,"updated":"2026-01-02T06:56:46Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The statement is executed when the trigger or waypoint is activated and the effects are launched depending on the result.\n\n- If the result is a boolean and true, the effect is launched.\n- If the result is an object, the effect is launched if the result is the player or the player vehicle.\n- If the result is an array, the effect is launched if the result contains the player or the player vehicle.","syntaxes":[{"syntax":"trigger setEffectCondition statement","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"statement","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"statement: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"statement","types":["String"]}},{"syntax":"waypoint setEffectCondition statement","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":"Waypoint","types":["Waypoint"],"since":null,"text":"waypoint: Waypoint - Waypoint"},{"name":"statement","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"statement: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"statement","types":["String"]}}],"examples":[{"text":"```sqf\n_triggerObj setEffectCondition \"thisList\";\n```","code":["_triggerObj setEffectCondition \"thisList\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setEffectiveCommander","operator":null,"title":"setEffectiveCommander","type":"command","url":"https://community.bistudio.com/wiki/setEffectiveCommander","revid":322840,"updated":"2022-06-26T21:14:08Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets effectiveCommander of the given vehicle. Effective commander is the person who commands the vehicle, i.e. gives commands to the driver.\nEvery time a person gets in or out of a vehicle, effective commander eligibility is recalculated by the engine based on the current crew.\nUse this command to force desired effective commander.","syntaxes":[{"syntax":"vehicle setEffectiveCommander person","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\nvehicle player setEffectiveCommander player;\n```","code":["vehicle player setEffectiveCommander player;"]}],"multiplayer":"In multiplayer, execute globally.","problems":null,"aliases":[],"see_also":["effectiveCommander","commander","vehicleMoveInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.96","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setEngineRpmRTD","operator":null,"title":"setEngineRpmRTD","type":"command","url":"https://community.bistudio.com/wiki/setEngineRpmRTD","revid":349351,"updated":"2023-11-08T15:35:07Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the RPM of given engines. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopter setEngineRpmRTD [rpm, engineIndex]","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"},{"name":"rpm","type":"Number","optional":false,"default":null,"description":"wanted RPM","types":["Number"],"since":null,"text":"rpm: Number - wanted RPM"},{"name":"engineIndex","type":"Number","optional":false,"default":null,"description":"index of the engine\n- engine index 0: engine #1\n- engine index 1: engine #2\n- engine index 2: engine #3\n- engine index -1: all engines","types":["Number"],"since":null,"text":"engineIndex: Number - index of the engine\n- engine index 0: engine #1\n- engine index 1: engine #2\n- engine index 2: engine #3\n- engine index -1: all engines"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopter","types":["Object"]},"right":{"text":"[rpm, engineIndex]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyHelicopter setEngineRpmRTD [1337, -1];\n```","code":["myHelicopter setEngineRpmRTD [1337, -1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWantedRPMRTD","rotorsRpmRTD","enginesRpmRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setFace","operator":null,"title":"setFace","type":"command","url":"https://community.bistudio.com/wiki/setFace","revid":369847,"updated":"2024-10-16T13:51:59Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set person's face. For a list of available faces, check CfgIdentities or `CfgFaces` config.\nIf the face is non-existent, the face is set to 'Default' and the error is logged in the .rpt file.\n\n- Operation Flashpoint faces\n- Armed Assault faces\n- Arma 2 faces\n- Arma 3 faces\n- Take On Helicopters faces","syntaxes":[{"syntax":"person setFace face","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"face","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"face: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"face","types":["String"]}}],"examples":[{"text":"```sqf\nsoldier1 setFace \"WhiteHead_02\";\n```","code":["soldier1 setFace \"WhiteHead_02\";"]},{"text":"Set persistent face for a unit in multiplayer:\n\n```sqf\nthis setFace \"AsianHead_A3_02\"; // in the init field if the unit already exists in Eden Editor\n```\n\n```sqf\nif (isServer) then { [_unit, \"AsianHead_A3_02\"] remoteExec [\"setFace\", 0, _unit] }; \n// if the unit is created later in the game.\n// This only works with stock faces; when a player joins with a custom face into this unit, \n// all current players need to be force-updated to the desired face as custom face overwrites current face.\n// Use [[BIS_fnc_setIdentity]] for persistent identity.\n```","code":["this setFace \"AsianHead_A3_02\"; // in the init field if the unit already exists in Eden Editor","if (isServer) then { [_unit, \"AsianHead_A3_02\"] remoteExec [\"setFace\", 0, _unit] }; \n// if the unit is created later in the game.\n// This only works with stock faces; when a player joins with a custom face into this unit, \n// all current players need to be force-updated to the desired face as custom face overwrites current face.\n// Use [[BIS_fnc_setIdentity]] for persistent identity."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["face","setIdentity","setSpeaker","hasCustomFace"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFaceAnimation","operator":null,"title":"setFaceAnimation","type":"command","url":"https://community.bistudio.com/wiki/setFaceAnimation","revid":340876,"updated":"2023-05-13T21:15:37Z","groups":["Animations","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets facial animation phase (eye blinking).\n\n> [!NOTE]\n> This command is not functional in Arma 3.","syntaxes":[{"syntax":"unit setFaceAnimation blink","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"blink","type":"Number","optional":false,"default":null,"description":"range 0..1","types":["Number"],"since":null,"text":"blink: Number - range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"blink","types":["Number"]}}],"examples":[{"text":"```sqf\n_soldier1 setFaceAnimation 0.5;\n```","code":["_soldier1 setFaceAnimation 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setRandomLip","setMimic","animate","animationPhase","animateDoor"],"notes":[{"user":"Lou Montana","date":"2008-12-23T09:01:00Z","text":"Setting face animation to 4 will give \"devilish\" features (Armed Assault)"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Broken Commands","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setFatigue","operator":null,"title":"setFatigue","type":"command","url":"https://community.bistudio.com/wiki/setFatigue","revid":310086,"updated":"2022-05-05T12:25:11Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the person's fatigue, from 0 to 1.","syntaxes":[{"syntax":"unit setFatigue value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":"in 0..1 *available* fatigue range: 0 is fully energised, 1 is fully exhausted","types":["Number"],"since":null,"text":"value: Number - in 0..1 *available* fatigue range: 0 is fully energised, 1 is fully exhausted"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setFatigue 1;\n```","code":["player setFatigue 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina","getFatigue","enableFatigue","setStamina","getStamina","enableStamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setFeatureType","operator":null,"title":"setFeatureType","type":"command","url":"https://community.bistudio.com/wiki/setFeatureType","revid":378060,"updated":"2026-02-04T23:41:20Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enable/disable object as a feature/landmark. Possible feature types:\n- 0 - Feature disabled\n- 1 - Object is always visible within object view distance\n- 2 - Object is always visible within terrain view distance\n\n> [!IMPORTANT]\n> The limit is **500** map/static objects and **200** dynamic objects including config features and auto features (flying helicopters, airplanes).\n>\n> The command returns false if the related limit is reached.","syntaxes":[{"syntax":"object setFeatureType type","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"type","type":"Number","optional":false,"default":null,"description":"the desired feature type","types":["Number"],"since":null,"text":"type: Number - the desired feature type"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the feature is set, false otherwise (limit reached)","text":"Boolean - true if the feature is set, false otherwise (limit reached)"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"type","types":["Number"]}}],"examples":[{"text":"Set a building to be always rendered:\n\n```sqf\nbuilding setFeatureType 2;\n```","code":["building setFeatureType 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setViewDistance","setObjectViewDistance"],"notes":[{"user":"Waffle SS.","date":"2017-10-10T16:18:00Z","text":"For world objects, command effect persists **after mission restart**. Map must be reloaded to automatically revert setting."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setFlagAnimationPhase","operator":null,"title":"setFlagAnimationPhase","type":"command","url":"https://community.bistudio.com/wiki/setFlagAnimationPhase","revid":348703,"updated":"2023-11-08T14:29:28Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets flag position on the flag pole. To animate flag use BIS_fnc_animateFlag.","syntaxes":[{"syntax":"flag setFlagAnimationPhase phase","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":"flag pole of the type `\"FlagCarrier\"`","types":["Object"],"since":null,"text":"flag: Object - flag pole of the type `\"FlagCarrier\"`"},{"name":"phase","type":"Number","optional":false,"default":null,"description":"flag position on the flag pole according to the given animation phase, where 0 is the bottom of the flag pole, 1 is the top of the flag pole.","types":["Number"],"since":null,"text":"phase: Number - flag position on the flag pole according to the given animation phase, where 0 is the bottom of the flag pole, 1 is the top of the flag pole."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"flag","types":["Object"]},"right":{"text":"phase","types":["Number"]}}],"examples":[{"text":"```sqf\n_flag1 setFlagAnimationPhase 0.5;\n```","code":["_flag1 setFlagAnimationPhase 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flagAnimationPhase","Arma 3: Flag Textures"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setFlagOwner","operator":null,"title":"setFlagOwner","type":"command","url":"https://community.bistudio.com/wiki/setFlagOwner","revid":369375,"updated":"2024-09-03T18:43:13Z","groups":["Flags","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets flag owner. When owner is set to objNull or any object other than a unit of class man or logic, flag is returned to the flagpole. A flag owned by a logic has no visual representation.","syntaxes":[{"syntax":"flag setFlagOwner owner","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"flag: Object"},{"name":"owner","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"owner: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"flag","types":["Object"]},"right":{"text":"owner","types":["Object"]}}],"examples":[{"text":"```sqf\n_flag1 setFlagOwner _soldier1;\n```","code":["_flag1 setFlagOwner _soldier1;"]},{"text":"To return the flag back to the flag pole:\n\n```sqf\n//Method 1: (set owner null)\nflag _flagCarrier setFlagOwner objNull;\n//Method 2: (set the flag mast as the owner)\nflag _flagCarrier setFlagOwner flag _flagCarrier;\n```","code":["//Method 1: (set owner null)\nflag _flagCarrier setFlagOwner objNull;\n//Method 2: (set the flag mast as the owner)\nflag _flagCarrier setFlagOwner flag _flagCarrier;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flag","flagOwner","setFlagSide","setFlagTexture","flagSide","flagTexture","forceFlagTexture","getForcedFlagTexture"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFlagSide","operator":null,"title":"setFlagSide","type":"command","url":"https://community.bistudio.com/wiki/setFlagSide","revid":369359,"updated":"2024-09-03T18:43:06Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets flag Side. A flag may be taken by any unit that is enemy to the side that owns the flag. Just like with setFlagTexture, if the command executed where unit is local effect of the command will be global and JIP compatible.","syntaxes":[{"syntax":"flag setFlagSide side","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"flag: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"flag","types":["Object"]},"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n_flag1 setFlagSide east;\n```","code":["_flag1 setFlagSide east;"]},{"text":"Capturable OPFOR flag:\n\n```sqf\nprivate _flag = \"FlagPole_F\" createVehicle position player;\n_flag setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_CSAT_CO.paa\";\n_flag setFlagSide east;\n```","code":["private _flag = \"FlagPole_F\" createVehicle position player;\n_flag setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_CSAT_CO.paa\";\n_flag setFlagSide east;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flag","flagOwner","setFlagOwner","setFlagTexture","flagSide","flagTexture","setFlagAnimationPhase","flagAnimationPhase","forceFlagTexture","getForcedFlagTexture"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFlagTexture","operator":null,"title":"setFlagTexture","type":"command","url":"https://community.bistudio.com/wiki/setFlagTexture","revid":378480,"updated":"2026-04-24T11:57:06Z","groups":["Flags"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets flag texture.","syntaxes":[{"syntax":"flag setFlagTexture texture","since":null,"effect":null,"exec":null,"params":[{"name":"flag","type":"Object","optional":false,"default":null,"description":"a flag pole","types":["Object"],"since":null,"text":"flag: Object - a flag pole"},{"name":"texture","type":"String","optional":false,"default":null,"description":"flag texture. If texture is `\"\"`, flag is not drawn. Custom texture can be used:\n- Prior Arma 3: Dimension 200×200, file extension .jpg\n- Since Arma 3: Dimension 512×256, file extension .paa","types":["String"],"since":null,"text":"texture: String - flag texture. If texture is `\"\"`, flag is not drawn. Custom texture can be used:\n- Prior Arma 3: Dimension 200×200, file extension .jpg\n- Since Arma 3: Dimension 512×256, file extension .paa"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"flag","types":["Object"]},"right":{"text":"texture","types":["String"]}}],"examples":[{"text":"```sqf\n_flagE setFlagTexture \"\\ca\\misc\\data\\sever_vlajka.paa\";\n```","code":["_flagE setFlagTexture \"\\ca\\misc\\data\\sever_vlajka.paa\";"]},{"text":"```sqf\n_flagW setFlagTexture \"\\ca\\misc\\data\\usa_vlajka.paa\";\n```","code":["_flagW setFlagTexture \"\\ca\\misc\\data\\usa_vlajka.paa\";"]},{"text":"```sqf\nflag1 setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";\n```","code":["flag1 setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_red_CO.paa\";"]},{"text":"```sqf\n_customFlag setFlagTexture \"myMissionFlag.paa\";\n```","code":["_customFlag setFlagTexture \"myMissionFlag.paa\";"]},{"text":"```sqf\n_flag_Arma_3 setFlagTexture \"\\a3\\ui_f\\data\\Logos\\arma3_expansion_ca.paa\";\n```","code":["_flag_Arma_3 setFlagTexture \"\\a3\\ui_f\\data\\Logos\\arma3_expansion_ca.paa\";"]},{"text":"Capturable OPFOR flag:\n\n```sqf\nprivate _flag = \"FlagPole_F\" createVehicle position player;\n_flag setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_CSAT_CO.paa\";\n_flag setFlagSide east;\n```","code":["private _flag = \"FlagPole_F\" createVehicle position player;\n_flag setFlagTexture \"\\A3\\Data_F\\Flags\\Flag_CSAT_CO.paa\";\n_flag setFlagSide east;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["flag","flagOwner","setFlagOwner","setFlagSide","setObjectTexture","setObjectTextureGlobal","flagSide","flagTexture","setFlagAnimationPhase","flagAnimationPhase","forceFlagTexture","getForcedFlagTexture"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Flags","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFog","operator":null,"title":"setFog","type":"command","url":"https://community.bistudio.com/wiki/setFog","revid":370471,"updated":"2024-12-16T18:09:58Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Smoothly change the fog over given time (in seconds). See also fogParams.\n\n> [!NOTE]\n> This command is MP synchronised, if executed on server, the changes will propagate globally. If executed on client effect is temporary as it will soon change to the server setting.","syntaxes":[{"syntax":"time setFog fog","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"transition time to the new value","types":["Number"],"since":null,"text":"time: Number - transition time to the new value"},{"name":"fog","type":"Number","optional":false,"default":null,"description":"fog density in range 0..1","types":["Number"],"since":null,"text":"fog: Number - fog density in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"fog","types":["Number"]}},{"syntax":"time setFog [fogValue, fogDecay, fogBase]","since":"arma3 0.50","effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"transition time to the new value","types":["Number"],"since":null,"text":"time: Number - transition time to the new value"},{"name":"fogValue","type":"Number","optional":false,"default":null,"description":"normal fog value that represents fog density at *fogBase* level, in range 0..1","types":["Number"],"since":null,"text":"fogValue: Number - normal fog value that represents fog density at *fogBase* level, in range 0..1"},{"name":"fogDecay","type":"Number","optional":false,"default":null,"description":"decay of fog density with altitude, in range -1..1; a negative value means a \"ceiling\" fog","types":["Number"],"since":null,"text":"fogDecay: Number - decay of fog density with altitude, in range -1..1; a negative value means a \"ceiling\" fog"},{"name":"fogBase","type":"Number","optional":false,"default":null,"description":"base altitude (ASL) of fog (in meters), in range -5000..5000","types":["Number"],"since":null,"text":"fogBase: Number - base altitude (ASL) of fog (in meters), in range -5000..5000"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"[fogValue, fogDecay, fogBase]","types":["Array"]}}],"examples":[{"text":"```sqf\n15 setFog 0.5;\n```","code":["15 setFog 0.5;"]},{"text":"Force no fog:\n\n```sqf\n0 setFog 0;\n// forceWeatherChange; // change is immediate\n999999 setFog 0;\n```","code":["0 setFog 0;\n// forceWeatherChange; // change is immediate\n999999 setFog 0;"]},{"text":"```sqf\n// Arma 3 examples:\n0 setFog [1, 0.01, 0];\n0 setFog [1, -1, 70];    // mountain fog, starts from 70m ASL and thickens the higher you climb\n0 setFog [1, 1, 60];    // valley fog, starts from 60m ASL and thickens the lower you descend\n0 setFog [1, 1, 0];        // fooooog on the waaaater\n```","code":["// Arma 3 examples:\n0 setFog [1, 0.01, 0];\n0 setFog [1, -1, 70];\t// mountain fog, starts from 70m ASL and thickens the higher you climb\n0 setFog [1, 1, 60];\t// valley fog, starts from 60m ASL and thickens the lower you descend\n0 setFog [1, 1, 0];\t\t// fooooog on the waaaater"]}],"multiplayer":"Before Arma 3, server and clients could have each a different (local) fog value.","problems":null,"aliases":[],"see_also":["Arma 3: Improved Fog","fog","fogParams","fogForecast","nextWeatherChange","forceWeatherChange","setRain"],"notes":[{"user":"Ceeeb","date":"2007-04-20T04:25:00Z","text":"Only one script command induced weather change (either setOvercast or setFog) can be happening at a time.\nStarting a new weather change will immediately halt the current weather change.\nsetRain changes are independent and can occur simultaneously to a weather change."},{"user":"Zapat","date":"2015-12-15T14:32:00Z","text":"setTimeMultiplier DOES affect transition time."},{"user":"Killzone_Kid","date":"2019-01-10T10:23:00Z","text":"A little information about how Alt Syntax works.\nThe *fogValue* is normal fog value that could be set independently with original setFog command.\n*fogBase* is the ASL altitude at which the fog will start. 0 is the sea level. *fogDecay* is how defined the fog start is. The more defined, the denser is the fog.\n1 (or -1) are the max values. If it is positive the fog will be generated below *fogBase* line, if negative, above it.\nIf *fogDecay* is small, the fog will transition more smoothly from no fog to full fog, and because of that it will cross *fogBase* line by quite a lot, depending on how small is *fogDecay* value.\nCurrent values of *fogDecay* and *fogBase* can be retrieved with fogParams."},{"user":"Sa-Matra","date":"2022-07-05T05:29:31Z","text":"Few notes about network behavior of the fog:\n- Fog is the only weather parameter that is *almost* properly network-synchronized by the engine. You can rely on it for both connected players and JIP players without jumping through hoops like other weather commands.\n- *time* is not synchronized over the network exactly, fog values changes will be linear over time where you run the command, while network-synced *time* will be non-linear, but in the end fog is still will be somewhat close between clients and servers, so its not much of a game breaker.\n- Say fog all 0 on both server and client, instantly setting fog on the server with `0 setFog 1` or even `0 setFog [1,1,1]` will not set it instantly on clients, but rather interpolate it there over few seconds (~10-15), non-linearly (slower the closer it gets to server values)\n- Setting *fogValue* to values above 1 is allowed where you run the command, but network sync will still clamp it to 1, so if you do `0 setFog 100`, clients will still interpolate *fogValue* to 1, including JIP, so make sure you don't set it above 1 if you expect consistent values between server and client for some calculations."},{"user":"Sa-Matra","date":"2022-08-01T09:43:29Z","text":"Be aware that this command is affected by setWindStr and windStr! Max fogValue = 1 - windStr, so if you do `0 setWindStr 1`, setting any fog with time>0 will actually set fog to 0! Doing instant fog changes with time=0 strangely still works though."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setForceGeneratorRTD","operator":null,"title":"setForceGeneratorRTD","type":"command","url":"https://community.bistudio.com/wiki/setForceGeneratorRTD","revid":351296,"updated":"2023-11-27T03:20:18Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"value setForceGeneratorRTD arr","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"},{"name":"arr","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"arr: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"value","types":["Number"]},"right":{"text":"arr","types":["Array"]}}],"examples":[{"text":"```sqf\nsomething1 setForceGeneratorRTD something2;\n```","code":["something1 setForceGeneratorRTD something2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["clearForcesRTD","forceGeneratorRTD","addForceGeneratorRTD"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands","Stubs","Take On Helicopters: Scripting Commands"]},{"name":"setFormation","operator":null,"title":"setFormation","type":"command","url":"https://community.bistudio.com/wiki/setFormation","revid":336294,"updated":"2022-12-21T11:10:07Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set group formation.","syntaxes":[{"syntax":"group setFormation formation","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"formation","type":"String","optional":false,"default":null,"description":"can be one of:\n- \"COLUMN\"\n- \"STAG COLUMN\"\n- \"WEDGE\"\n- \"ECH LEFT\"\n- \"ECH RIGHT\"\n- \"VEE\"\n- \"LINE\"\n- Armed Assault v1.00 \"FILE\"\n- Armed Assault v1.00 \"DIAMOND\"","types":["String"],"since":null,"text":"formation: String - can be one of:\n- \"COLUMN\"\n- \"STAG COLUMN\"\n- \"WEDGE\"\n- \"ECH LEFT\"\n- \"ECH RIGHT\"\n- \"VEE\"\n- \"LINE\"\n- Armed Assault v1.00 \"FILE\"\n- Armed Assault v1.00 \"DIAMOND\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"formation","types":["String"]}}],"examples":[{"text":"```sqf\n_groupOne setFormation \"LINE\";\n```","code":["_groupOne setFormation \"LINE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","formation"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFormationTask","operator":null,"title":"setFormationTask","type":"command","url":"https://community.bistudio.com/wiki/setFormationTask","revid":319792,"updated":"2022-05-13T09:24:53Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the current task of the formation member. \n\n> [!NOTE]\n> This command is not available in Arma 2.","syntaxes":[{"syntax":"unit setFormationTask task","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"task","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"task: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"task","types":["String"]}}],"examples":[{"text":"```sqf\n_unit setFormationTask \"MOVE\";\n```","code":["_unit setFormationTask \"MOVE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["formationTask"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setFormDir","operator":null,"title":"setFormDir","type":"command","url":"https://community.bistudio.com/wiki/setFormDir","revid":369299,"updated":"2024-09-03T18:42:52Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets group formation heading. Accepted heading range is 0 to 360. Formation is facing this direction unless enemy is seen. When group is moving, this value is overridden by movement direction. If the new direction is noticeably different from the old direction (approx +/- 15 degrees), units will change positions changing formationDirection.","syntaxes":[{"syntax":"group setFormDir heading","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"heading","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"heading: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"heading","types":["Number"]}}],"examples":[{"text":"```sqf\n_group1 setFormDir 180;\n```","code":["_group1 setFormDir 180;"]},{"text":"```sqf\n_unit1 setFormDir random 360;\n```","code":["_unit1 setFormDir random 360;"]},{"text":"```sqf\n//center the main turret\n(group BIS_Crew1) setFormDir (getDir BIS_Armor);\n```","code":["//center the main turret\n(group BIS_Crew1) setFormDir (getDir BIS_Armor);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDir","setVectorDir","setVectorDirAndUp","resetSubgroupDirection","formation","formationLeader","formationMembers","formationTask","formationDirection","formationPosition"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFriend","operator":null,"title":"setFriend","type":"command","url":"https://community.bistudio.com/wiki/setFriend","revid":341629,"updated":"2023-06-12T19:02:54Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Sets how friendly a side is with another. The friendliness is set for one side, not for the other.  See also Side Relations.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 this command can be used mid-mission. Before that it was intended to be used on mission start only, as changing value during mission could cause unexpected errors in AI behaviour (especially for groups already knowing about \"switched to enemy\" groups).","syntaxes":[{"syntax":"side1 setFriend [side2, value]","since":null,"effect":null,"exec":null,"params":[{"name":"side1","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side1: Side"},{"name":"side2","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side2: Side"},{"name":"value","type":"Number","optional":false,"default":null,"description":"a value smaller than 0.6 results in being enemy, otherwise *side1* is friendly to *side2*","types":["Number"],"since":null,"text":"value: Number - a value smaller than 0.6 results in being enemy, otherwise *side1* is friendly to *side2*"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"side1","types":["Side"]},"right":{"text":"[side2, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nwest setFriend [resistance, 0]; // west will not like resistance from now on\n```","code":["west setFriend [resistance, 0]; // west will not like resistance from now on"]},{"text":"```sqf\nresistance setFriend [east, 0];\neast setFriend [resistance, 0]; // both are enemies\n\nresistance setFriend [east, 1];\neast setFriend [resistance, 0]; // resistance likes east, but east does not like resistance\n```","code":["resistance setFriend [east, 0];\neast setFriend [resistance, 0]; // both are enemies\n\nresistance setFriend [east, 1];\neast setFriend [resistance, 0]; // resistance likes east, but east does not like resistance"]},{"text":"```sqf\nwest setFriend [west, 0]; // free for all deathmatch! works with west/blufor, east/opfor, independent/resistance and civilian\n```","code":["west setFriend [west, 0]; // free for all deathmatch! works with west/blufor, east/opfor, independent/resistance and civilian"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getFriend","BIS_fnc_sideIsFriendly","BIS_fnc_sideIsEnemy","Side Relations"],"notes":[{"user":"Ceeeb","date":"2007-11-30T11:25:00Z","text":"Setting the civilian side to be the enemy of any other side will result in the other side attacking inanimate mission editor placed objects such as empty vehicles and static objects, since these objects belong to the civilian side."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setFromEditor","operator":null,"title":"setFromEditor","type":"command","url":"https://community.bistudio.com/wiki/setFromEditor","revid":322969,"updated":"2022-06-28T21:42:52Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set if given team member was inserted directly from editor.","syntaxes":[{"syntax":"teamMember setFromEditor fromEditor","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"teamMember: Team Member"},{"name":"fromEditor","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"fromEditor: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"fromEditor","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_teamMember setFromEditor true;\n```","code":["_teamMember setFromEditor true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setFSMVariable","operator":null,"title":"setFSMVariable","type":"command","url":"https://community.bistudio.com/wiki/setFSMVariable","revid":330070,"updated":"2022-08-15T16:49:43Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set variable to given value in the variable space of given FSM.\n\nThe FSM handle is the number returned by the execFSM command.","syntaxes":[{"syntax":"handle setFSMVariable [name, value]","since":null,"effect":null,"exec":null,"params":[{"name":"handle","type":"Number","optional":false,"default":null,"description":"FSM handle","types":["Number"],"since":null,"text":"handle: Number - FSM handle"},{"name":"name","type":"String","optional":false,"default":null,"description":"name of the FSM variable","types":["String"],"since":null,"text":"name: String - name of the FSM variable"},{"name":"value","type":"Anything","optional":false,"default":null,"description":"new value of the FSM variable","types":["Anything"],"since":null,"text":"value: Anything - new value of the FSM variable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"handle","types":["Number"]},"right":{"text":"[name, value]","types":["Array"]}}],"examples":[{"text":"```sqf\n_handle = execFSM \"test.fsm\";\n_handle setFSMVariable [\"_foo\", 23]; // sets variable _foo in the FSM to 23\n```","code":["_handle = execFSM \"test.fsm\";\n_handle setFSMVariable [\"_foo\", 23]; // sets variable _foo in the FSM to 23"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","commandFSM","completedFSM","doFSM","execFSM","getFSMVariable"],"notes":[{"user":"Master85","date":"2014-03-23T00:53:00Z","text":"If the variable is not yet defined within the FSM it will be created."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setFuel","operator":null,"title":"setFuel","type":"command","url":"https://community.bistudio.com/wiki/setFuel","revid":376981,"updated":"2026-01-01T06:22:22Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets fuel level.","syntaxes":[{"syntax":"vehicle setFuel amount","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"amount","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"amount: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"amount","types":["Number"]}}],"examples":[{"text":"```sqf\n_jeepOne setFuel 0.5;\n```","code":["_jeepOne setFuel 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fuel","getFuelCargo","setFuelCargo","setHit","setAmmo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFuelCargo","operator":null,"title":"setFuelCargo","type":"command","url":"https://community.bistudio.com/wiki/setFuelCargo","revid":376961,"updated":"2026-01-01T05:53:10Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets fuel amount in cargo space of refuel vehicles. Note that the carrying capacity of each side's refuel trucks differ.","syntaxes":[{"syntax":"vehicle setFuelCargo amount","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle : Object"},{"name":"amount","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"amount : Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"amount","types":["Number"]}}],"examples":[{"text":"```sqf\n_refuelTruck setFuelCargo 0;\n```","code":["_refuelTruck setFuelCargo 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getFuelCargo","fuel","setFuel","setAmmoCargo","setRepairCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setFuelConsumptionCoef","operator":null,"title":"setFuelConsumptionCoef","type":"command","url":"https://community.bistudio.com/wiki/setFuelConsumptionCoef","revid":377716,"updated":"2026-01-02T09:11:12Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the fuel consumption coefficient, which is a multiplier of the fuel consumption rate in config. It doesn't affect fuel leakage or refueling.","syntaxes":[{"syntax":"vehicle setFuelConsumptionCoef coef","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle : Object"},{"name":"coef","type":"Number in range 0..1000","optional":false,"default":null,"description":"Values larger than 1 increase fuel consumption, and values between 0 and 1 decrease fuel consumption. 0 disables fuel consumption","types":["Number"],"since":null,"text":"coef: Number in range 0..1000 - Values larger than 1 increase fuel consumption, and values between 0 and 1 decrease fuel consumption. 0 disables fuel consumption"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"coef","types":["Number"]}}],"examples":[{"text":"```sqf\nmyTank setFuelConsumptionCoef 10; // consume 10x more fuel than default\n```","code":["myTank setFuelConsumptionCoef 10; // consume 10x more fuel than default"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getFuelConsumptionCoef"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setGroupIcon","operator":null,"title":"setGroupIcon","type":"command","url":"https://community.bistudio.com/wiki/setGroupIcon","revid":376586,"updated":"2025-10-29T23:11:37Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets group icon properties. Since Arma 3 v2.22 the offset can be set separately for 2d and 3d.","syntaxes":[{"syntax":"group setGroupIcon [id, icon, offset]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"id","type":"Number","optional":false,"default":null,"description":"the icon ID returned by addGroupIcon","types":["Number"],"since":null,"text":"id: Number - the icon ID returned by addGroupIcon"},{"name":"icon","type":"String","optional":false,"default":null,"description":"class name of desired icon from CfgGroupIcons","types":["String"],"since":null,"text":"icon: String - class name of desired icon from CfgGroupIcons"},{"name":"offset","type":"Array","optional":true,"default":"[0,0]","description":"X and Y offsets of the icon in form [offsetX, offsetY, (offsetX3d), (offsetY3d)]","types":["Array"],"since":null,"text":"offset: Array - (Optional, default [0,0]) X and Y offsets of the icon in form [offsetX, offsetY, (offsetX3d), (offsetY3d)]"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"[id, icon, offset]","types":["Array"]}}],"examples":[{"text":"```sqf\n_target setGroupIcon [_icon, \"hc_selectedEnemy\"];\n_target setGroupIcon [_icon, \"flag\"];\n\n_group setGroupIcon [_icon, _iconsClass, _offset];\n```","code":["_target setGroupIcon [_icon, \"hc_selectedEnemy\"];\n_target setGroupIcon [_icon, \"flag\"];\n\n_group setGroupIcon [_icon, _iconsClass, _offset];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIcons","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIconParams","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setGroupIconParams","operator":null,"title":"setGroupIconParams","type":"command","url":"https://community.bistudio.com/wiki/setGroupIconParams","revid":377887,"updated":"2026-01-04T16:31:07Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set group icons parameters.","syntaxes":[{"syntax":"group setGroupIconParams properties","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"properties","type":"Array with [color, text, scale, visibility, WPvisibility, WPcolor]","optional":false,"default":null,"description":"Array with [color, text, scale, visibility, WPvisibility, WPcolor]\n- color: Color (RGBA)\n- text: String\n- scale: Number\n- visibility: Boolean\n- WPvisibility: Boolean\n- WPcolor: Color (RGBA)","types":["Array"],"since":null,"text":"properties: Array with [color, text, scale, visibility, WPvisibility, WPcolor]\n- color: Color (RGBA)\n- text: String\n- scale: Number\n- visibility: Boolean\n- WPvisibility: Boolean\n- WPcolor: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"properties","types":["Array"]}}],"examples":[{"text":"```sqf\n_grp setGroupIconParams [[0.9,0,0,1], \"The Group\", 1.25, false];\n```","code":["_grp setGroupIconParams [[0.9,0,0,1], \"The Group\", 1.25, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconsSelectable","setGroupIconsVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setGroupIconsSelectable","operator":null,"title":"setGroupIconsSelectable","type":"command","url":"https://community.bistudio.com/wiki/setGroupIconsSelectable","revid":349137,"updated":"2023-11-08T14:49:45Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets if group icons raise onGroupIconClick, onGroupIconOverEnter and onGroupIconOverLeave events.","syntaxes":[{"syntax":"setGroupIconsSelectable selectable","since":null,"effect":null,"exec":null,"params":[{"name":"selectable","type":"Boolean","optional":false,"default":null,"description":"setting to true makes the icon selectable","types":["Boolean"],"since":null,"text":"selectable: Boolean - setting to true makes the icon selectable"}],"returns":{"type":"Nothing (objNull prior to Arma 3 v1.92)","types":["Nothing","objNull"],"description":null,"text":"Nothing (objNull prior to Arma 3 v1.92)"},"form":"unary","operator":null,"left":null,"right":{"text":"selectable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nsetGroupIconsSelectable true;\n```","code":["setGroupIconsSelectable true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["groupIconSelectable"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setGroupIconsVisible","operator":null,"title":"setGroupIconsVisible","type":"command","url":"https://community.bistudio.com/wiki/setGroupIconsVisible","revid":369184,"updated":"2024-09-03T10:34:45Z","groups":["High Command"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets if group icons added with addGroupIcon are visible on map and in the HUD.","syntaxes":[{"syntax":"setGroupIconsVisible [showOnMap, showOnHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"showOnMap","type":"Boolean","optional":false,"default":null,"description":"true to show on map. Default is false","types":["Boolean"],"since":null,"text":"showOnMap: Boolean - true to show on map. Default is false"},{"name":"showOnHUD","type":"Boolean","optional":false,"default":null,"description":"true to show on HUD. Default is false","types":["Boolean"],"since":null,"text":"showOnHUD: Boolean - true to show on HUD. Default is false"}],"returns":{"type":null,"types":["Nothing","Object","objNull"],"description":null,"text":"Nothing (prior to Arma 3 v1.94 this command returned Object of null value)"},"form":"unary","operator":null,"left":null,"right":{"text":"[showOnMap, showOnHUD]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetGroupIconsVisible [true, true];\n(group player) addGroupIcon [\"b_inf\", [0, 0]];\n```","code":["setGroupIconsVisible [true, true];\n(group player) addGroupIcon [\"b_inf\", [0, 0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addGroupIcon","clearGroupIcons","getGroupIcon","getGroupIconParams","groupIconSelectable","groupIconsVisible","onGroupIconClick","removeGroupIcon","setGroupIcon","setGroupIconParams","setGroupIconsSelectable"],"notes":[{"user":"Larrow","date":"2022-02-06T09:59:20Z","text":"If enabling for MARTA (Military Symbols) and using teamSwitch this command needs to be run again once switched to the new unit.\nPossibly do it in a mission eventHandler of TeamSwitch."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: High Command","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setGroupId","operator":null,"title":"setGroupId","type":"command","url":"https://community.bistudio.com/wiki/setGroupId","revid":376660,"updated":"2025-11-03T17:32:23Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the group radio callsign, how it will be displayed in radio chat. Two groups on the same side **cannot** have the same callsign (possible on different sides) - see #Example 4.\n\nThe identity setup can consist of format keywords (marked with **%**) and param keywords taken from **CfgWorlds** config.\nFormatting is almost like using the format command but with some special group keywords (see #Example 2).\n\n| %GroupSquad | %GroupPlatoon | %GroupCompany | %GroupNames | %GroupColors |\n|---|---|---|---|---|\n| - \"Squad1\" → 1<br>- \"Squad2\" → 2<br>- \"Squad3\" → 3<br>- \"Squad4\" → 4 | - \"Platoon1\" → 1<br>- \"Platoon2\" → 2<br>- \"Platoon3\" → 3<br>- \"Platoon4\" → 4 | - \"CompanyAlpha\" → Alpha<br>- \"CompanyBravo\" → Bravo<br>- \"CompanyCharlie\" → etc.<br>- \"CompanyDelta\"<br>- \"CompanyEcho\"<br>- \"CompanyFoxtrot\"<br>- \"CompanyGolf\"<br>- \"CompanyHotel\"<br>- \"CompanyIndia\"<br>- \"CompanyKilo\"<br>- \"CompanyLima\"<br>- \"CompanyMike\"<br>- \"CompanyNovember\"<br>- \"CompanyOscar\"<br>- \"CompanyPapa\"<br>- \"CompanyQuebec\"<br>- \"CompanyRomeo\"<br>- \"CompanySierra\"<br>- \"CompanyTango\"<br>- \"CompanyUniform\"<br>- \"CompanyVictor\"<br>- \"CompanyWhiskey\"<br>- \"CompanyXray\" → X-Ray<br>- \"CompanyYankee\"<br>- \"CompanyZulu\" | - \"Alpha\"<br>- \"Bravo\"<br>- \"Charlie\"<br>- \"Delta\"<br>- \"Echo\"<br>- \"Foxtrot\"<br>- \"Golf\"<br>- \"Hotel\"<br>- \"November\"<br>- \"Kilo\"<br>- \"Yankee\"<br>- \"Zulu\"<br>- \"Convoy\"<br>- \"Buffalo\"<br>- \"Guardian\"<br>- \"Two\"<br>- \"Three\"<br>- \"Fox\" | - \"GroupColor0\" → (nothing)<br>- \"GroupColor1\" → Black<br>- \"GroupColor2\" → Red<br>- \"GroupColor3\" → Green<br>- \"GroupColor4\" → Blue<br>- \"GroupColor5\" → Yellow<br>- \"GroupColor6\" → Orange<br>- \"GroupColor7\" → Pink<br>- \"Six\" → Six |\n\n| Letter | Colour |\n|---|---|\n| - \"Alpha\"<br>- \"Bravo\"<br>- \"Charlie\"<br>- \"Delta\"<br>- \"Echo\"<br>- \"Foxtrot\"<br>- \"Golf\"<br>- \"Hotel\"<br>- \"Kilo\"<br>- \"Yankee\"<br>- \"Zulu\"<br>- \"Buffalo\"<br>- \"Convoy\"<br>- \"Guardian\"<br>- \"November\"<br>- \"Two\"<br>- \"Three\"<br>- \"Fox\" | - \"GroupColor0\" → (nothing)<br>- \"GroupColor1\" → Black<br>- \"GroupColor2\" → Red<br>- \"GroupColor3\" → Green<br>- \"GroupColor4\" → Blue<br>- \"GroupColor5\" → Yellow<br>- \"GroupColor6\" → Orange<br>- \"GroupColor7\" → Pink<br>- \"Six\" → Six |\n\n> [!NOTE]\n> **Operation Flashpoint:** - In **Operation Flashpoint**, the group ID cannot be freely decided and format must be [letter, colour, picture] or [letter, colour] - *nameFormat* **cannot** be a custom text - see #Example 3.\n> - The radio callsign strings can be overwritten in a mission by writing Stringtable entries of the same name. Some entry names:\n> - STR_CFG_*GRPNAMES*_**ALPHA**\n> - STR_CFG_*GRPNAMES*_**FOX**\n> - STR_CFG_*GRPCOL*_**BLACK**\n> - STR_CFG_*GRPNAMES*_**SIX** (unlike its name suggests, this is a \"group colour\")\n> - STR_CFG_FIREFLYBASE\n> - STR_CFG_PAPABEAR\n> - STR_CFG_HQ_BASE","syntaxes":[{"syntax":"group setGroupId [nameFormat, nameParam1, nameParam2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"nameFormat","type":"String","optional":false,"default":null,"description":"format template (%keyword1 - %keyword2...etc)","types":["String"],"since":null,"text":"nameFormat: String - format template (%keyword1 - %keyword2...etc)"},{"name":"nameParamN","type":"String","optional":false,"default":null,"description":"param keyword","types":["String"],"since":null,"text":"nameParamN: String - param keyword"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"[nameFormat, nameParam1, nameParam2, ...]","types":["Array"]}}],"examples":[{"text":"**Arma 3**:\n\n```sqf\ngroup player setGroupId [\"Some name for the group\"];\nhint groupId group player;    // \"Some name for the group\"\nplayer sideChat \"lalala\";    // Some name for the group (KK): \"lalala\"\n```","code":["group player setGroupId [\"Some name for the group\"];\nhint groupId group player;\t// \"Some name for the group\"\nplayer sideChat \"lalala\";\t// Some name for the group (KK): \"lalala\""]},{"text":"**Arma 3**:\n\n```sqf\ngroup player setGroupId [\"%GroupNames :=: %GroupColors\", \"Alpha\", \"GroupColor2\"];\nhint groupId group player;    // \"Alpha :=: Red\"\nplayer sideChat \"lalala\";    // Alpha :=: Red (KK): \"lalala\"\n```","code":["group player setGroupId [\"%GroupNames :=: %GroupColors\", \"Alpha\", \"GroupColor2\"];\nhint groupId group player;\t// \"Alpha :=: Red\"\nplayer sideChat \"lalala\";\t// Alpha :=: Red (KK): \"lalala\""]},{"text":"**Armed Assault / Arma 2 / Arma 3**:\n\n```sqf\ngroup player setGroupId [\"First Assault Recon Team\"];\n```\n\n**Operation Flashpoint**:\n\n```sqf\n_group1 setGroupId [\"Delta\", \"GroupColor4\"]\n```","code":["group player setGroupId [\"First Assault Recon Team\"];","_group1 setGroupId [\"Delta\", \"GroupColor4\"]"]},{"text":"When trying to apply the same callsign to two groups of the same side, the callsigns will simply be swapped, e.g:\n\n```sqf\ngroup1 setGroupId [\"Active Group\"];\ngroup2 setGroupId [\"Inactive Group\"];\ngroup2 setGroupId [\"Active Group\"]; // group1 is \"Inactive Group\" now\n```","code":["group1 setGroupId [\"Active Group\"];\ngroup2 setGroupId [\"Inactive Group\"];\ngroup2 setGroupId [\"Active Group\"]; // group1 is \"Inactive Group\" now"]}],"multiplayer":"For the global variant of this command see setGroupIdGlobal.","problems":null,"aliases":[],"see_also":["setGroupIdGlobal","groupId","group"],"notes":[{"user":"Killzone_Kid","date":"2015-04-21T23:21:00Z","text":""}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setGroupIdGlobal","operator":null,"title":"setGroupIdGlobal","type":"command","url":"https://community.bistudio.com/wiki/setGroupIdGlobal","revid":369314,"updated":"2024-09-03T18:42:56Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"A global equivalent of  setGroupId.","syntaxes":[{"syntax":"group setGroupIdGlobal [format, keyword1, keyword2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"group: Object or Group"},{"name":"format","type":"String","optional":false,"default":null,"description":"format template (e.g \"%keyword1 - %keyword2 / %keyword4 (%keyword3)\")","types":["String"],"since":null,"text":"format: String - format template (e.g \"%keyword1 - %keyword2 / %keyword4 (%keyword3)\")"},{"name":"keywordN","type":"String","optional":false,"default":null,"description":"keyword value","types":["String"],"since":null,"text":"keywordN: String - keyword value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"group","types":["Object","Group"]},"right":{"text":"[format, keyword1, keyword2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\ngroup player setGroupIdGlobal [\"PAPA BEAR\"];\nhint groupId group player; // \"PAPA BEAR\"\n```","code":["group player setGroupIdGlobal [\"PAPA BEAR\"];\nhint groupId group player; // \"PAPA BEAR\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setGroupId","groupId","group"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Arma 3 version 1.48","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setGroupOwner","operator":null,"title":"setGroupOwner","type":"command","url":"https://community.bistudio.com/wiki/setGroupOwner","revid":364895,"updated":"2024-06-29T14:38:33Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Changes the ownership of a group (and all its units) to a given client. The group leader must not be a player. This command only works when called from the server. Returns true if locality was changed. For agents use setOwner command.","syntaxes":[{"syntax":"group setGroupOwner clientID","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"},{"name":"clientID","type":"Number","optional":false,"default":null,"description":"the machine network ID of the new owner.","types":["Number"],"since":null,"text":"clientID: Number - the machine network ID of the new owner."}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"clientID","types":["Number"]}}],"examples":[{"text":"```sqf\n_localityChanged = _someGroup setGroupOwner (owner _playerObject);\n```","code":["_localityChanged = _someGroup setGroupOwner (owner _playerObject);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["owner","setOwner","groupOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 3 version 1.40","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setGusts","operator":null,"title":"setGusts","type":"command","url":"https://community.bistudio.com/wiki/setGusts","revid":376959,"updated":"2026-01-01T05:50:49Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the gusts value smoothly during the given time (in seconds). A time of zero means there will be an immediate change.","syntaxes":[{"syntax":"time setGusts value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"value","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n60 setGusts 0.75;\n```","code":["60 setGusts 0.75;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["gusts","wind","setWind"],"notes":[{"user":"Sa-Matra","date":"2022-07-06T04:17:09Z","text":"Unlike most of weather commands, this one does not set gusts instantly but on next frame (in 2 frames in practice), so running it multiple times will overwrite each other. setRainbow has same behavior. In order to set gusts to some value and then have it change to another over time, you need to first do `0 setGusts 0` and then `100 setGusts 1` after 2 frames. Example:\n\n```sqf\n// Initial gusts you want\n0 setGusts 0;\n\n// A thread to wait for 2 frames\n(diag_frameNo + 2) spawn {\n    waitUntil {\n        // Code in braces is not executed until wanted frame is reached because of lazy evaluation\n        diag_frameNo >= _this && {\n            100 setGusts 1;\n            true; // positive condition result to end waitUntil and spawned thread\n        };\n    };\n};\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setHideBehind","operator":null,"title":"setHideBehind","type":"command","url":"https://community.bistudio.com/wiki/setHideBehind","revid":352191,"updated":"2024-02-01T23:25:57Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the data for hiding. objectWhereHide can be taken using findCover. hidePosition can be taken using getHideFrom. Command is not functional in Arma 2.\n\n> [!WARNING]\n> This command is not implemented!","syntaxes":[{"syntax":"object setHideBehind [objectWhereHide, hidePosition]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"objectWhereHide","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"objectWhereHide: Object"},{"name":"hidePosition","type":"Array","optional":false,"default":null,"description":"format getHideFrom","types":["Array"],"since":null,"text":"hidePosition: Array - format getHideFrom"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[objectWhereHide, hidePosition]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getHideFrom","findCover","isHidden"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setHit","operator":null,"title":"setHit","type":"command","url":"https://community.bistudio.com/wiki/setHit","revid":369851,"updated":"2024-10-16T13:52:03Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"|  |  |  |\n|---|---|---|\n| + | Event Handler | Triggered |\n| `Hit` | ✗ |  |\n| `HandleDamage` | ✗ |  |\n| `Killed` | ✓ |  |\n| `MPKilled` | ✓ |  |\n\nSet damage on a part of an object.\n\n> [!NOTE]\n> Some part names are in Czech; see the translation table.","syntaxes":[{"syntax":"object setHit [part, damage, useEffects, killer, instigator, breakRotor]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"local object","types":["Object"],"since":null,"text":"object: Object - local object"},{"name":"part","type":"String","optional":false,"default":null,"description":"name of the part (selection name)","types":["String"],"since":null,"text":"part: String - name of the part (selection name)"},{"name":"damage","type":"Number","optional":false,"default":null,"description":"damage value ranging 0..1, 0 being fully functional, 1 being destroyed","types":["Number"],"since":null,"text":"damage: Number - damage value ranging 0..1, 0 being fully functional, 1 being destroyed"},{"name":"useEffects","type":"Boolean","optional":true,"default":"true","description":"false to skip destruction effects","types":["Boolean"],"since":"arma3 1.68","text":"useEffects: Boolean - (Optional, default true) false to skip destruction effects"},{"name":"killer","type":"Object","optional":true,"default":"objNull","description":"the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n- it can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n- it will alter the killer's rating as if the killer directly killed the unit.\n- it will be listed as `_killer` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.08","text":"killer: Object - (Optional, default objNull) the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n- it can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n- it will alter the killer's rating as if the killer directly killed the unit.\n- it will be listed as `_killer` parameter in the Killed event handler."},{"name":"instigator","type":"Object","optional":true,"default":"objNull","description":"the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.12","text":"instigator: Object - (Optional, default objNull) the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler."},{"name":"breakRotor","type":"Boolean","optional":true,"default":"false","description":"if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true.","types":["Boolean"],"since":"arma3 2.18","text":"breakRotor: Boolean - (Optional, default false) if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[part, damage, useEffects, killer, instigator, breakRotor]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setHit [\"motor\", 1];\n```","code":["vehicle player setHit [\"motor\", 1];"]},{"text":"```sqf\nvehicle player setHit [\"mala vrtule\", 0.95];\n```","code":["vehicle player setHit [\"mala vrtule\", 0.95];"]},{"text":"```sqf\nif (local _heli) then\n{\n    _heli setHit [\"velka vrtule\", 0];\n}\nelse\n{\n    hint (\"Vehicle \" + str _heli + \" must be local to this machine to do that!\");\n};\n```","code":["if (local _heli) then\n{\n\t_heli setHit [\"velka vrtule\", 0];\n}\nelse\n{\n\thint (\"Vehicle \" + str _heli + \" must be local to this machine to do that!\");\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getHit","getHitPointDamage","setHitPointDamage","damage","setDamage","setFuel","setAmmo","getHitIndex","setHitIndex","forceHitPointsDamageSync"],"notes":[{"user":"Deadfast","date":"2009-08-24T11:09:00Z","text":"Damaging specific parts of the vehicle will not update its overall damage value (as of v1.03):\n\n```sqf\nplayer setHit [\"hands\", 0.9];\nhint str (damage player); // will return 0\n```"},{"user":"DenV","date":"2011-03-29T14:25:00Z","text":"Direct use of the names of sections of the model is likely a bad practice, and will not work on some addons.\nSo instead:\n\n```sqf\n_MH60S setHit [\"elektronika\", _hit];\n```\n\nshould be used:\n\n```sqf\n_MH60S setHit [getText (configFile >> \"cfgVehicles\" >> \"MH60S\" >> \"HitPoints\" >> \"HitAvionics\" >> \"name\"), _hit];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setHitIndex","operator":null,"title":"setHitIndex","type":"command","url":"https://community.bistudio.com/wiki/setHitIndex","revid":377888,"updated":"2026-01-04T16:34:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the current level of damage for a specific Hit Point. All hit points can be obtained with getAllHitPointsDamage command.","syntaxes":[{"syntax":"vehicle setHitIndex [hitPartIndex, damage, useEffects, killer, instigator, breakRotor]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be damaged","types":["Object"],"since":null,"text":"vehicle : Object - vehicle to be damaged"},{"name":"hitPartIndex","type":"Number","optional":false,"default":null,"description":"hit part index of the Hit Point","types":["Number"],"since":null,"text":"hitPartIndex: Number - hit part index of the Hit Point"},{"name":"damage","type":"Number in range 0..1","optional":false,"default":null,"description":"level of damage, 0 = no damage, 1 = full damage","types":["Number"],"since":null,"text":"damage: Number in range 0..1 - level of damage, 0 = no damage, 1 = full damage"},{"name":"useEffects","type":"Boolean","optional":true,"default":"true","description":"false to skip destruction effects","types":["Boolean"],"since":"arma3 1.68","text":"useEffects: Boolean - (Optional, default true) false to skip destruction effects"},{"name":"killer","type":"Object","optional":true,"default":"objNull","description":"the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n\n- It can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n\n- It will alter the killer's rating as if the killer directly killed the unit.\n\n- It will be listed as `_killer` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.08","text":"killer: Object - (Optional, default objNull) the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n\n- It can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n\n- It will alter the killer's rating as if the killer directly killed the unit.\n\n- It will be listed as `_killer` parameter in the Killed event handler."},{"name":"instigator","type":"Object","optional":true,"default":"objNull","description":"the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.12","text":"instigator: Object - (Optional, default objNull) the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler."},{"name":"breakRotor","type":"Boolean","optional":true,"default":"false","description":"if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true.","types":["Boolean"],"since":"arma3 2.18","text":"breakRotor: Boolean - (Optional, default false) if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[hitPartIndex, damage, useEffects, killer, instigator, breakRotor]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setHitIndex [1, 1];\n```","code":["vehicle player setHitIndex [1, 1];"]},{"text":"```sqf\nplayer setHitIndex [7, 0.5];\n```","code":["player setHitIndex [7, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getAllHitPointsDamage","getHitIndex","getHitPointDamage","setHitPointDamage","setHit","getHit","setDamage","damage","forceHitPointsDamageSync"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setHitPointDamage","operator":null,"title":"setHitPointDamage","type":"command","url":"https://community.bistudio.com/wiki/setHitPointDamage","revid":369857,"updated":"2024-10-16T13:52:06Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"| Event Handler | Triggered |\n|---|---|\n| `Hit` | ✗ |\n| `HandleDamage` | ✗ |\n| `Killed` | ✓ |\n| `MPKilled` | ✓ |\n\nSet the current level of damage for a specific Hit Point (specified by its config class). This command has no effect when allowDamage is set to false.\n\n> [!NOTE]\n> See also BIS_fnc_setHitPointDamage for setting hit with dependency.","syntaxes":[{"syntax":"vehicle setHitPointDamage [hitPointName, damage, useEffects, killer, instigator, breakRotor]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle to be damaged","types":["Object"],"since":null,"text":"vehicle: Object - vehicle to be damaged"},{"name":"hitPointName","type":"String","optional":false,"default":null,"description":"name of the Hit Point class","types":["String"],"since":null,"text":"hitPointName: String - name of the Hit Point class"},{"name":"damage","type":"Number","optional":false,"default":null,"description":"level of damage, in range 0..1","types":["Number"],"since":null,"text":"damage: Number - level of damage, in range 0..1"},{"name":"useEffects","type":"Boolean","optional":true,"default":"true","description":"false to skip destruction effects","types":["Boolean"],"since":"arma3 1.68","text":"useEffects: Boolean - (Optional, default true) false to skip destruction effects"},{"name":"killer","type":"Object","optional":true,"default":"objNull","description":"the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n\n- It can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n\n- It will alter the killer's rating as if the killer directly killed the unit.\n\n- It will be listed as `_killer` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.08","text":"killer: Object - (Optional, default objNull) the entity that caused the damage. If the damage leads to the death of the unit, the killer will be used as the object that caused the kill.\n\n- It can be used to show \"killed by player\" in debriefing statistics and kill messages in the chat (if death messages are enabled).\n\n- It will alter the killer's rating as if the killer directly killed the unit.\n\n- It will be listed as `_killer` parameter in the Killed event handler."},{"name":"instigator","type":"Object","optional":true,"default":"objNull","description":"the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler.","types":["Object"],"since":"arma3 2.12","text":"instigator: Object - (Optional, default objNull) the person that instigated the damage.\n- if a tank is a killer, the tank gunner that pulled the trigger is instigator\n- it will be listed as `_instigator` parameter in the Killed event handler."},{"name":"breakRotor","type":"Boolean","optional":true,"default":"false","description":"if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true.","types":["Boolean"],"since":"arma3 2.18","text":"breakRotor: Boolean - (Optional, default false) if the hitpoint is rotor on a helicopter, true will break the rotor as well as play corresponding sound if 'useEffects' is also true."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[hitPointName, damage, useEffects, killer, instigator, breakRotor]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setHitPointDamage [\"hitEngine2\", 1.0];\n```","code":["vehicle player setHitPointDamage [\"hitEngine2\", 1.0];"]},{"text":"```sqf\nplayer setHitPointDamage [\"hitHead\", 0.5];\nplayer setHitPointDamage [\"hitBody\", 0.5];\nplayer setHitPointDamage [\"hitHands\", 0.5];\nplayer setHitPointDamage [\"hitLegs\", 0.5];\n```","code":["player setHitPointDamage [\"hitHead\", 0.5];\nplayer setHitPointDamage [\"hitBody\", 0.5];\nplayer setHitPointDamage [\"hitHands\", 0.5];\nplayer setHitPointDamage [\"hitLegs\", 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getHitPointDamage","getAllHitPointsDamage","setHit","getHit","setDamage","damage","getHitIndex","setHitIndex","forceHitPointsDamageSync","BIS_fnc_setHitPointDamage"],"notes":[{"user":"Master85","date":"2012-08-30T13:54:00Z","text":"This command is using the Hit Points (defined in the `HitPoints` class in the config) while setHit is using Named Selections (defined in the model itself)."}],"categories":["Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Take On Helicopters version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setHorizonParallaxCoef","operator":null,"title":"setHorizonParallaxCoef","type":"command","url":"https://community.bistudio.com/wiki/setHorizonParallaxCoef","revid":309900,"updated":"2022-05-05T12:16:47Z","groups":["Camera Control","System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets coef used to shift horizon position based on camera height (use 0 to disable shifting).","syntaxes":[{"syntax":"setHorizonParallaxCoef coef","since":null,"effect":null,"exec":null,"params":[{"name":"coef","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"coef: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"coef","types":["Number"]}}],"examples":[{"text":"```sqf\nsetHorizonParallaxCoef 1;\n```","code":["setHorizonParallaxCoef 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setHUDMovementLevels","operator":null,"title":"setHUDMovementLevels","type":"command","url":"https://community.bistudio.com/wiki/setHUDMovementLevels","revid":323045,"updated":"2022-06-28T21:43:09Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set min/max movement borders displayed in HUD gauges. Use -1 to skip some value.","syntaxes":[{"syntax":"setHUDMovementLevels [minSpeed, maxSpeed, minAlt, maxAlt, minDir, maxDir, targetOrPosition]","since":null,"effect":null,"exec":null,"params":[{"name":"minSpeed","type":"Number","optional":false,"default":null,"description":"in m/s","types":["Number"],"since":null,"text":"minSpeed: Number - in m/s"},{"name":"maxSpeed","type":"Number","optional":false,"default":null,"description":"in m/s","types":["Number"],"since":null,"text":"maxSpeed: Number - in m/s"},{"name":"minAlt","type":"Number","optional":false,"default":null,"description":"in meters","types":["Number"],"since":null,"text":"minAlt: Number - in meters"},{"name":"maxAlt","type":"Number","optional":false,"default":null,"description":"in meters","types":["Number"],"since":null,"text":"maxAlt: Number - in meters"},{"name":"minDir","type":"Number","optional":false,"default":null,"description":"in degrees","types":["Number"],"since":null,"text":"minDir: Number - in degrees"},{"name":"maxDir","type":"Number","optional":false,"default":null,"description":"in degrees","types":["Number"],"since":null,"text":"maxDir: Number - in degrees"},{"name":"targetOrPosition","type":"Object or Position","optional":false,"default":null,"description":null,"types":["Object","Position"],"since":null,"text":"targetOrPosition: Object or Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[minSpeed, maxSpeed, minAlt, maxAlt, minDir, maxDir, targetOrPosition]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetHUDMovementLevels [20, 30, -1, -1, 0.23, 2.1, [0,0,0]];\n```","code":["setHUDMovementLevels [20, 30, -1, -1, 0.23, 2.1, [0,0,0]];"]},{"text":"```sqf\nsetHUDMovementLevels [20, 30, -1, -1, 0.23, 2.1, player];\n```","code":["setHUDMovementLevels [20, 30, -1, -1, 0.23, 2.1, player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setHumidity","operator":null,"title":"setHumidity","type":"command","url":"https://community.bistudio.com/wiki/setHumidity","revid":309121,"updated":"2022-05-03T10:45:24Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets surface humidity. Affects how footsteps sound (dry / wet). humidity is increasing when raining and decreasing when not raining. Exception is if the rain is set with 'snow' flag, then humidity is not updated.","syntaxes":[{"syntax":"setHumidity humidity","since":null,"effect":null,"exec":null,"params":[{"name":"humidity","type":"Number","optional":false,"default":null,"description":"surface humidity in the range 0..1","types":["Number"],"since":null,"text":"humidity: Number - surface humidity in the range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"humidity","types":["Number"]}}],"examples":[{"text":"```sqf\nsetHumidity 1;\n```","code":["setHumidity 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["humidity","setRain"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setIdentity","operator":null,"title":"setIdentity","type":"command","url":"https://community.bistudio.com/wiki/setIdentity","revid":369141,"updated":"2024-09-03T10:34:36Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets identity of a person. The identities could be defined in a custom config in Description.ext or in the main config. For a list of available main config values see CfgIdentities.\n\nThis command is an aggregate of the following commands: setName, setFace, setSpeaker, setNameSound, setPitch, only the values are loaded from the given config. It also includes value for glasses for which currently there is no direct command, instead there is an inventory command addGoggles.","syntaxes":[{"syntax":"person setIdentity identity","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit to which the identity will be applied","types":["Object"],"since":null,"text":"person: Object - unit to which the identity will be applied"},{"name":"identity","type":"String","optional":false,"default":null,"description":"name of the subclass in CfgIdentities","types":["String"],"since":null,"text":"identity: String - name of the subclass in CfgIdentities"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"identity","types":["String"]}}],"examples":[{"text":"```sqf\n_soldier1 setIdentity \"MyLittleSoldier\";\n```","code":["_soldier1 setIdentity \"MyLittleSoldier\";"]},{"text":"Clone factory in MP:\n\n```sqf\nfor \"_i\" from 1 to 10 do\n{\n    _bob = group player createUnit [typeOf player, position player, [], 0, \"none\"];\n    [_bob, \"MyLittleSoldier\"] remoteExec [\"setIdentity\", 0, _bob];\n};\n```","code":["for \"_i\" from 1 to 10 do\n{\n\t_bob = group player createUnit [typeOf player, position player, [], 0, \"none\"];\n\t[_bob, \"MyLittleSoldier\"] remoteExec [\"setIdentity\", 0, _bob];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setFace","setName","setNameSound","setSpeaker","setPitch","addGoggles","loadIdentity","lockIdentity","Arma 3: Event Handlers","hasCustomFace"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setImportance","operator":null,"title":"setImportance","type":"command","url":"https://community.bistudio.com/wiki/setImportance","revid":310106,"updated":"2022-05-05T12:25:20Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the importance value of location.","syntaxes":[{"syntax":"location setImportance value","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nmyLocation setImportance 2;\n```","code":["myLocation setImportance 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["importance"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setInfoPanel","operator":null,"title":"setInfoPanel","type":"command","url":"https://community.bistudio.com/wiki/setInfoPanel","revid":364317,"updated":"2024-05-06T09:38:47Z","groups":["Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Opens given component or first component of given component type on specified info panel.","syntaxes":[{"syntax":"setInfoPanel [infoPanelId, componentClassOrType]","since":null,"effect":null,"exec":null,"params":[{"name":"infoPanelId","type":"String","optional":false,"default":null,"description":"info panel classname, or \"left\" or \"right\"","types":["String"],"since":null,"text":"infoPanelId: String - info panel classname, or \"left\" or \"right\""},{"name":"componentClassOrType","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"componentClassOrType: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if panel was successfully opened, false otherwise (e.g. opening GPS on player without GPS item or setting panel to vehicle that doesn't have such capability configured)","text":"Boolean - true if panel was successfully opened, false otherwise (e.g. opening GPS on player without GPS item or setting panel to vehicle that doesn't have such capability configured)"},"form":"unary","operator":null,"left":null,"right":{"text":"[infoPanelId, componentClassOrType]","types":["Array"]}}],"examples":[{"text":"```sqf\n// opens slingload assistant on right panel\nprivate _result = setInfoPanel [\"VehicleSystemsDisplayManagerComponentRight\", \"SlingLoadDisplayComponent\"];\nif (!_result) then { hint \"could not open the slingload assistant, sorry\" };\n```","code":["// opens slingload assistant on right panel\nprivate _result = setInfoPanel [\"VehicleSystemsDisplayManagerComponentRight\", \"SlingLoadDisplayComponent\"];\nif (!_result) then { hint \"could not open the slingload assistant, sorry\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Custom Info","infoPanel","infoPanels","infoPanelComponents","enableInfoPanelComponent","infoPanelComponentEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"setJointDriveAngularVelocity","operator":null,"title":"setJointDriveAngularVelocity","type":"command","url":"https://community.bistudio.com/wiki/setJointDriveAngularVelocity","revid":378905,"updated":"2026-08-11T14:56:34Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Requires that a swing+twist or SLERP \"drive\" has been configured in attachChild.\nSets the joints target angular velocity (orientation relative to the joint's own orientation).\nThe drive will then behave like a spring (springParameters are configured in the drive), trying to accelerate the child object to the desired velocity.","syntaxes":[{"syntax":"joint setJointDriveAngularVelocity velocity","since":null,"effect":null,"exec":null,"params":[{"name":"joint","type":"Object or NetObject","optional":false,"default":null,"description":"The parent vehicle that has a joint to a child, or the joint itself to be manipulated","types":["Object","NetObject"],"since":null,"text":"joint : Object or NetObject - The parent vehicle that has a joint to a child, or the joint itself to be manipulated"},{"name":"velocity","type":"Vector3D","optional":false,"default":null,"description":"relative velocity vector","types":["Vector3D"],"since":null,"text":"velocity: Vector3D - relative velocity vector"},{"name":"","type":null,"optional":false,"default":null,"description":null,"types":[],"since":null,"text":""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"joint","types":["Object","NetObject"]},"right":{"text":"velocity","types":["Vector3D"]}}],"examples":[{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","setJointDrivePosition","setJointDriveOrientation","setJointDriveLinearVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect","WIP"]},{"name":"setJointDriveLinearVelocity","operator":null,"title":"setJointDriveLinearVelocity","type":"command","url":"https://community.bistudio.com/wiki/setJointDriveLinearVelocity","revid":378899,"updated":"2026-08-11T14:56:33Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Requires that a linear \"drive\" has been configured in attachChild.\nSets the joints target velocity (orientation relative to the joint's own orientation).\nThe drive will then behave like a spring (springParameters are configured in the drive), trying to accelerate the child object to the desired velocity.\nSimilar to setVelocityModelSpace","syntaxes":[{"syntax":"joint setJointDriveLinearVelocity velocity","since":null,"effect":null,"exec":null,"params":[{"name":"joint","type":"Object or NetObject","optional":false,"default":null,"description":"The parent vehicle that has a joint to a child, or the joint itself to be manipulated","types":["Object","NetObject"],"since":null,"text":"joint : Object or NetObject - The parent vehicle that has a joint to a child, or the joint itself to be manipulated"},{"name":"velocity","type":"Vector3D","optional":false,"default":null,"description":"relative velocity vector","types":["Vector3D"],"since":null,"text":"velocity: Vector3D - relative velocity vector"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"joint","types":["Object","NetObject"]},"right":{"text":"velocity","types":["Vector3D"]}}],"examples":[{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","setJointDrivePosition","setJointDriveOrientation","setJointDriveAngularVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect","WIP"]},{"name":"setJointDriveOrientation","operator":null,"title":"setJointDriveOrientation","type":"command","url":"https://community.bistudio.com/wiki/setJointDriveOrientation","revid":379088,"updated":"2026-09-27T09:40:35Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Requires that a swing+twist or SLERP \"drive\" has been configured in attachChild.\nSets the joints target orientation (relative to the joint's own orientation).\nThe drive will then behave like a spring (springParameters are configured in the drive), trying to pull the child object to the desired orientation.","syntaxes":[{"syntax":"joint setJointDriveOrientation [angle, axis]","since":null,"effect":null,"exec":null,"params":[{"name":"joint","type":"Object or NetObject","optional":false,"default":null,"description":"The parent vehicle that has a joint to a child, or the joint itself to be manipulated","types":["Object","NetObject"],"since":null,"text":"joint : Object or NetObject - The parent vehicle that has a joint to a child, or the joint itself to be manipulated"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"The angle (in radians to rotate around axis), clockwise","types":["Number"],"since":null,"text":"angle: Number - The angle (in radians to rotate around axis), clockwise"},{"name":"axis","type":"Vector3D","optional":false,"default":null,"description":"The vector around which to rotate","types":["Vector3D"],"since":null,"text":"axis: Vector3D - The vector around which to rotate"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"joint","types":["Object","NetObject"]},"right":{"text":"[angle, axis]","types":["Array"]}},{"syntax":"joint setJointDriveOrientation [vectorDir, vectorUp]","since":null,"effect":null,"exec":null,"params":[{"name":"joint","type":"Object or NetObject","optional":false,"default":null,"description":"The parent vehicle that has a joint to a child, or the joint itself to be manipulated","types":["Object","NetObject"],"since":null,"text":"joint : Object or NetObject - The parent vehicle that has a joint to a child, or the joint itself to be manipulated"},{"name":"vectorDir","type":"Vector3D","optional":false,"default":null,"description":"vectorDir","types":["Vector3D"],"since":null,"text":"vectorDir: Vector3D - vectorDir"},{"name":"vectorUp","type":"Vector3D","optional":false,"default":null,"description":"vectorUp","types":["Vector3D"],"since":null,"text":"vectorUp: Vector3D - vectorUp"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"joint","types":["Object","NetObject"]},"right":{"text":"[vectorDir, vectorUp]","types":["Array"]}}],"examples":[{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","setJointDrivePosition","setJointDriveLinearVelocity","setJointDriveAngularVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect","WIP"]},{"name":"setJointDrivePosition","operator":null,"title":"setJointDrivePosition","type":"command","url":"https://community.bistudio.com/wiki/setJointDrivePosition","revid":378904,"updated":"2026-08-11T14:56:34Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Requires that a linear \"drive\" has been configured in attachChild.\nSets the joints target position (relative to the joint's own position).\nThe drive will then behave like a spring (springParameters are configured in the drive), trying to pull the child object to the desired position.","syntaxes":[{"syntax":"joint setJointDrivePosition pos","since":null,"effect":null,"exec":null,"params":[{"name":"joint","type":"Object or NetObject","optional":false,"default":null,"description":"The parent vehicle that has a joint to a child, or the joint itself to be manipulated","types":["Object","NetObject"],"since":null,"text":"joint : Object or NetObject - The parent vehicle that has a joint to a child, or the joint itself to be manipulated"},{"name":"pos","type":"Array","optional":false,"default":null,"description":"target position in XYZ relative to the joint","types":["Array"],"since":null,"text":"pos: Array - target position in XYZ relative to the joint"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"joint","types":["Object","NetObject"]},"right":{"text":"pos","types":["Array"]}}],"examples":[{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]},{"text":"```sqf\n\n```","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachChild","setJointDriveOrientation","setJointDriveLinearVelocity","setJointDriveAngularVelocity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect","WIP"]},{"name":"setLeader","operator":null,"title":"setLeader","type":"command","url":"https://community.bistudio.com/wiki/setLeader","revid":330647,"updated":"2022-10-03T11:09:06Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"> [!IMPORTANT]\n> To set a Group leader, see selectLeader.\n\nSet the leader of the given Team. Effect is local, unless both leader unit and team are local to PC on which command is executed, then effect is global.","syntaxes":[{"syntax":"team setLeader leader","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"},{"name":"leader","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"leader: Team Member"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"team","types":["Team Member"]},"right":{"text":"leader","types":["Team Member"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandFollow","doFollow","formationLeader","formLeader","isFormationLeader","leader","selectLeader"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setLightAmbient","operator":null,"title":"setLightAmbient","type":"command","url":"https://community.bistudio.com/wiki/setLightAmbient","revid":377373,"updated":"2026-01-02T06:42:43Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set ambient color of light. This includes surfaces that **face away** from the light, unlike setLightColor.","syntaxes":[{"syntax":"light setLightAmbient color","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGB)","types":["Color"],"since":null,"text":"color: Color (RGB)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"color","types":["Color"]}}],"examples":[{"text":"```sqf\nmyLight setLightAmbient [0.5,0,0]; // produces red light around the origin source\n```","code":["myLight setLightAmbient [0.5,0,0]; // produces red light around the origin source"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightColor","setLightBrightness","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[{"user":"Feersum","date":"2006-12-01T16:42:00Z","text":"Light can be created with command createVehicleLocal with special vehicle class \"#lightpoint\".\n\nFor example:\n\n```sqf\n_light = \"#lightpoint\" createVehicleLocal pos;\n_light setLightBrightness 1.0;\n_light setLightAmbient [0.0, 1.0, 0.0];\n_light setLightColor [0.0, 1.0, 0.0];\n_light lightAttachObject [_object, [0,0,0]];\n```"},{"user":"ColonelSandersLite","date":"2007-08-17T07:15:00Z","text":"To clarify:\n\n- setLightAmbient - Terrain and surrounding objects are bathed in this colour.\n- setLightColor - Controls the \"haze\" seen around the lightsource (ex flares)."},{"user":"Ffur2007slx2_5","date":"2014-03-25T10:06:00Z","text":"When both setLightAmbient and setLightColor were [0,0,0], there won’t be any visual presentation on the light source."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setLightAttenuation","operator":null,"title":"setLightAttenuation","type":"command","url":"https://community.bistudio.com/wiki/setLightAttenuation","revid":369342,"updated":"2024-09-03T18:43:02Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets attenuation of light. Standard method of attenuation (1 / (constant + linear*dist + quadratic*dist*dist)).\n*start* param represents distance where the attenuation starts to take effects (dist = distance - start).","syntaxes":[{"syntax":"light setLightAttenuation [start, constant, linear, quadratic, hardlimitstart, hardlimitend]","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"start","type":"Number","optional":false,"default":null,"description":"distance with 100% intensity, falloff starts here","types":["Number"],"since":null,"text":"start: Number - distance with 100% intensity, falloff starts here"},{"name":"constant","type":"Number","optional":false,"default":null,"description":"constant attenuation coef","types":["Number"],"since":null,"text":"constant: Number - constant attenuation coef"},{"name":"linear","type":"Number","optional":false,"default":null,"description":"linear attenuation coef","types":["Number"],"since":null,"text":"linear: Number - linear attenuation coef"},{"name":"quadratic","type":"Number","optional":false,"default":null,"description":"quadratic attenuation coef","types":["Number"],"since":null,"text":"quadratic: Number - quadratic attenuation coef"},{"name":"hardlimitstart","type":"Number","optional":true,"default":null,"description":"max distance hard limit start (start of fading of intensity to 0) in m","types":["Number"],"since":null,"text":"hardlimitstart: Number - (Optional) max distance hard limit start (start of fading of intensity to 0) in m"},{"name":"hardlimitend","type":"Number","optional":true,"default":null,"description":"max distance hard limit end (end of fading of intensity to 0) in m","types":["Number"],"since":null,"text":"hardlimitend: Number - (Optional) max distance hard limit end (end of fading of intensity to 0) in m"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"[start, constant, linear, quadratic, hardlimitstart, hardlimitend]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyLight setLightAttenuation [2, 4, 4, 0, 9, 10];\n```","code":["myLight setLightAttenuation [2, 4, 4, 0, 9, 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightBrightness","setLightIntensity","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-25T12:31:00Z","text":"(A3 1.14) setLightAttenuation array will present fallowing visual effects:\n\n[start(SCALAR), constant(SCALAR), linear (SCALAR), quadratic(SCALAR)]\n\n**start(SCALAR)** – Number can be unlimited, this parameter determines the range that the light source takes effect. Terrain environmental color will be bathed by setLightAmbient within the range and its covered objects will reflect the color by setLightColor.\n\n**constant(SCALAR)** – Support signed number, this parameter determines the brightness proportion of the light source, higher the number is, less the brightness will be, vice versa. Any minus value passed will be treated as 0 (100% brightness). In other words, this parameter is related with setLightBrightness and setLightIntensity.\n\n**linear (SCALAR)** – Support signed number, effective range is from 0 ~ 100 (passed minus value will be treated as 0), this parameter determines the concentration of the light source, higher the number is, more will the light concentrate, vice versa. In other words, this parameter will turn the source into spotlight and sharpens its light circle border.\n\nPlease pay attention to a special value: **4.31918e-005**\n\ne.g.\n\n```sqf\n// This value will make the light source reach an ultra high effect range. Any initial param set before will be discarded and overwritten.\n_light setLightAttenuation [2, 4, 4.31918e-005, 0];\n```\n\n**quadratic(SCALAR)** – Support signed number (range unlimited, passed minus number will be treated as 0), this parameter determines the range that the light source is visible and its visual presentation looks similar to linear. 0 means the maximum visible range. In further explanation, a less bright source can’t be seen out of the range on the land but still visible on the sea, and a bright enough source won’t be effected by the passed range who is still visible out of the range.\n\nPlease pay attention to a special value: **4.31918e-005**\n\ne.g.\n\n```sqf\n// This value will make the light source reach an ultra high effect range. Any initial param set before will be discarded and overwritten.\n_light setLightAttenuation [6, 0, 0, 4.31918e-005];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightBrightness","operator":null,"title":"setLightBrightness","type":"command","url":"https://community.bistudio.com/wiki/setLightBrightness","revid":376672,"updated":"2025-11-04T00:17:20Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set brightness of light. Does nothing for light reflector, for light point the formula is setLightIntensity ((brightness * 50) ^ 2)\n\n> [!NOTE]\n> This command is outdated. Use setLightIntensity instead.","syntaxes":[{"syntax":"light setLightBrightness brightness","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"brightness","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"brightness: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"brightness","types":["Number"]}}],"examples":[{"text":"```sqf\nmyLight setLightBrightness 2;\n```","code":["myLight setLightBrightness 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightIntensity","setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[{"user":"Feersum","date":"2006-12-01T16:42:00Z","text":"Light can be created with command createVehicleLocal with special vehicle class `\"#lightpoint\"`\n\nfor example:\n\n```sqf\n_light = \"#lightpoint\" createVehicleLocal _posAGL;\n_light setLightBrightness 1.0;\n_light setLightAmbient [0.0, 1.0, 0.0];\n_light setLightColor [0.0, 1.0, 0.0];\n_light lightAttachObject [_object, [0,0,0]];\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setLightColor","operator":null,"title":"setLightColor","type":"command","url":"https://community.bistudio.com/wiki/setLightColor","revid":309010,"updated":"2022-04-25T11:42:18Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set diffuse color of light. Illuminates surfaces that are facing the light.","syntaxes":[{"syntax":"light setLightColor [r, g, b]","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"r","type":"Number","optional":false,"default":null,"description":"red value in range 0..1","types":["Number"],"since":null,"text":"r: Number - red value in range 0..1"},{"name":"g","type":"Number","optional":false,"default":null,"description":"green value in range 0..1","types":["Number"],"since":null,"text":"g: Number - green value in range 0..1"},{"name":"b","type":"Number","optional":false,"default":null,"description":"blue value in range 0..1","types":["Number"],"since":null,"text":"b: Number - blue value in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"[r, g, b]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyLight setLightColor [0.5,0,0]; // produces red\n```","code":["myLight setLightColor [0.5,0,0]; // produces red"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightBrightness","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight","setLightIR"],"notes":[{"user":"Feersum","date":"2006-12-01T16:42:00Z","text":"Light can be created with command createVehicleLocal with special vehicle class `\"#lightpoint\"`\n\nfor example:\n\n```sqf\n_light = \"#lightpoint\" createVehicleLocal pos;\n_light setLightBrightness 1.0;\n_light setLightAmbient [0.0, 1.0, 0.0];\n_light setLightColor [0.0, 1.0, 0.0];\n_light lightAttachObject [_object, [0,0,0]];\n```"},{"user":"ColonelSandersLite","date":"2017-08-17T07:15:00Z","text":"To clarify:\n- setLightAmbient - Terrain and surrounding objects are bathed in this colour.\n- setLightColor - Controls the \"haze\" seen around the lightsource (ex flares)."},{"user":"ffur2007slx2_5","date":"2014-03-24T23:58:00Z","text":"1. In Arma 3 ver 1.14 setLightColor will also change the color of the flare when setLightUseFlare, setLightFlareSize and setLightFlareMaxDistance were used on the same light source. For example:\n\n```sqf\n_light setLightUseFlare true;\n_light setLightFlareSize 2;\n_light setLightFlareMaxDistance 60;\n_light setLightColor [1, 1, 1];\n```\n\n2. When both setLightAmbient and setLightColor are [0,0,0], there won’t be any visual presentation on the light source."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setLightConePars","operator":null,"title":"setLightConePars","type":"command","url":"https://community.bistudio.com/wiki/setLightConePars","revid":376693,"updated":"2025-11-05T22:52:10Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the `1. lightreflector`'s cone params.","syntaxes":[{"syntax":"lightReflector setLightConePars [outerAngle, innerAngle, fadeCoef]","since":null,"effect":null,"exec":null,"params":[{"name":"lightReflector","type":"Object","optional":false,"default":null,"description":"object of class `1. lightreflector`","types":["Object"],"since":null,"text":"lightReflector: Object - object of class `1. lightreflector`"},{"name":"outerAngle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"outerAngle: Number"},{"name":"innerAngle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"innerAngle: Number"},{"name":"fadeCoef","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"fadeCoef: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"lightReflector","types":["Object"]},"right":{"text":"[outerAngle, innerAngle, fadeCoef]","types":["Array"]}}],"examples":[{"text":"```sqf\n_light setLightConePars [90, 45, 1];\n```","code":["_light setLightConePars [90, 45, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightColor","setLightAmbient","setLightBrightness","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight","setLightIR"],"notes":[{"user":"Waffle SS.","date":"2022-07-20T07:26:12Z","text":"Responds to setLightIntensity, **not** setLightBrightness:\n\n```sqf\nprivate _light = \"#lightreflector\" createVehicleLocal (player modelToWorld [0, 0.5, 0]);\n_light setLightIntensity 3000;\n_light setLightAmbient [0, 1, 0];\n_light setLightColor [0, 1, 0];\n_light setLightConePars [45, 10, 1];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightDayLight","operator":null,"title":"setLightDayLight","type":"command","url":"https://community.bistudio.com/wiki/setLightDayLight","revid":319755,"updated":"2022-05-13T09:24:49Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets if light can be used during the day.","syntaxes":[{"syntax":"light setLightDayLight bool","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyLight setLightDayLight true;\n```","code":["myLight setLightDayLight true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightBrightness"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightFlareMaxDistance","operator":null,"title":"setLightFlareMaxDistance","type":"command","url":"https://community.bistudio.com/wiki/setLightFlareMaxDistance","revid":310082,"updated":"2022-05-05T12:25:10Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets max distance where the flare is visible.","syntaxes":[{"syntax":"light setLightFlareMaxDistance distance","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"distance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"distance: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\nmyLight setLightFlareMaxDistance 500;\n```","code":["myLight setLightFlareMaxDistance 500;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightBrightness","setLightDayLight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightFlareSize","operator":null,"title":"setLightFlareSize","type":"command","url":"https://community.bistudio.com/wiki/setLightFlareSize","revid":310116,"updated":"2022-05-05T12:25:32Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets relative size of the flare for the light.","syntaxes":[{"syntax":"light setLightFlareSize size","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"size","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"size: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"size","types":["Number"]}}],"examples":[{"text":"```sqf\nmyLight setLightFlareSize 5;\n```","code":["myLight setLightFlareSize 5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightBrightness","setLightFlareMaxDistance","setLightDayLight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightIntensity","operator":null,"title":"setLightIntensity","type":"command","url":"https://community.bistudio.com/wiki/setLightIntensity","revid":376690,"updated":"2025-11-05T22:15:14Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets intensity of light directly. setLightBrightness uses setLightIntensity internally, therefore avoid using setLightBrightness alltogether to avoid confusion\n\n> [!NOTE]\n> Intensity formula is as follows (IF SET VIA setLightBrightness): \n>\n> ```sqf\n> Intensity = Brightness ^ 2 * 2500;\n> ```\n>\n> ```sqf\n> [4096, 4096, 10] spawn {\n>     private _brightness = 1;\n>     private _intensity = _brightness ^ 2 * 2500;\n>\n>     private _obj = \"Sign_Sphere10cm_F\" createVehicleLocal _this;\n>     private _light = \"#lightpoint\" createVehicleLocal _this;\n>     _light setLightDayLight true;\n>     _light setLightAmbient [1, 1, 1];\n>     _light setLightColor [1, 1, 1];\n>\n>     _light setLightBrightness _brightness;\n>     sleep 0.2;\n>     _brightness = getLightingAt _obj select 3;\n>\n>     _light setLightIntensity _intensity;\n>     sleep 0.2;\n>     _intensity = getLightingAt _obj select 3;\n>\n>     systemChat format [\"%1 (%2, %3)\", _brightness == _intensity, _brightness, _intensity];\n>\n>     deleteVehicle _light;\n>     deleteVehicle _obj;\n> };\n> ```","syntaxes":[{"syntax":"light setLightIntensity value","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nmyLight setLightIntensity 4;\n```","code":["myLight setLightIntensity 4;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightBrightness","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight","getLightInfo"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-24T23:37:00Z","text":"In Arma 3 ver1.14 setLightIntensity will overwrite the previous effect processed by setLightBrightness on the same light source, vice versa. And both of them currently play the same role on brightness, for example: \n\n```sqf\n_light setLightIntensity 3000;\n// same as\n_light setLightBrightness 1;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightIR","operator":null,"title":"setLightIR","type":"command","url":"https://community.bistudio.com/wiki/setLightIR","revid":310362,"updated":"2022-05-05T17:39:18Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets lightpoint in infrared range.","syntaxes":[{"syntax":"light setLightIR value","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":"object of class `\"#lightpoint\"` or similar","types":["Object"],"since":null,"text":"light: Object - object of class `\"#lightpoint\"` or similar"},{"name":"value","type":"Boolean","optional":false,"default":null,"description":"true to make it visible *only* with night vision goggles, false to make it a normal light","types":["Boolean"],"since":null,"text":"value: Boolean - true to make it visible *only* with night vision goggles, false to make it a normal light"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"value","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyLight setLightIR true; // visible with NVG only!\n```","code":["myLight setLightIR true; // visible with NVG only!"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightColor","setLightAmbient","setLightBrightness","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightnings","operator":null,"title":"setLightnings","type":"command","url":"https://community.bistudio.com/wiki/setLightnings","revid":349843,"updated":"2023-11-20T22:10:39Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the lightnings value smoothly during the given time (in seconds). A time of zero means there will be an immediate change.\n\n**NOTE**: This command will have no effect (even though the value of lightnings changes) unless `Manual Override` option is selected in the editor in the Intel, which is normally off.","syntaxes":[{"syntax":"time setLightnings value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n1800 setLightnings 0.7;\n```","code":["1800 setLightnings 0.7;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lightnings","overcast","setWaves"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setLightUseFlare","operator":null,"title":"setLightUseFlare","type":"command","url":"https://community.bistudio.com/wiki/setLightUseFlare","revid":341209,"updated":"2023-05-13T22:45:31Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets if light has flare.","syntaxes":[{"syntax":"light setLightUseFlare bool","since":null,"effect":null,"exec":null,"params":[{"name":"light","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"light: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"light","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyLight setLightUseFlare true;\n```","code":["myLight setLightUseFlare true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightAmbient","setLightColor","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightBrightness","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-25T18:50:00Z","text":"1. In Arma 3 ver 1.14 flare color can be changed via setLightColor.\n1. Flare won't have visual presentation in daytime.\n1. setLightUseFlare needs to be used together with setLightFlareSize and setLightFlareMaxDistance so that a flare can be seen."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLightVolumeShape","operator":null,"title":"setLightVolumeShape","type":"command","url":"https://community.bistudio.com/wiki/setLightVolumeShape","revid":378534,"updated":"2026-05-04T02:22:29Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the `1. lightreflector`'s volume shape. An empty shape will switch the light off.","syntaxes":[{"syntax":"lightReflector setLightVolumeShape [shapePath, scale]","since":null,"effect":null,"exec":null,"params":[{"name":"lightReflector","type":"Object","optional":false,"default":null,"description":"object of class `1. lightreflector`)","types":["Object"],"since":null,"text":"lightReflector : Object - object of class `1. lightreflector`)"},{"name":"shapePath","type":"String","optional":false,"default":null,"description":"\"\" to turn the light off","types":["String"],"since":null,"text":"shapePath: String - \"\" to turn the light off"},{"name":"scale","type":"Array with [sizeX, sizeY, sizeZ]","optional":false,"default":null,"description":"Array with [sizeX, sizeY, sizeZ]\n- sizeX: Number\n- sizeY: Number\n- sizeZ: Number","types":["Array"],"since":null,"text":"scale: Array with [sizeX, sizeY, sizeZ]\n- sizeX: Number\n- sizeY: Number\n- sizeZ: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"lightReflector","types":["Object"]},"right":{"text":"[shapePath, scale]","types":["Array"]}}],"examples":[{"text":"```sqf\n_light setLightVolumeShape [\"a3\\data_f\\VolumeLightFlashlight.p3d\", [1, 1, 1]];\n```","code":["_light setLightVolumeShape [\"a3\\data_f\\VolumeLightFlashlight.p3d\", [1, 1, 1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setLightColor","setLightAmbient","setLightBrightness","lightAttachObject","lightDetachObject","setLightIntensity","setLightAttenuation","setLightUseFlare","setLightFlareSize","setLightFlareMaxDistance","setLightDayLight","setLightIR"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setLocalWindParams","operator":null,"title":"setLocalWindParams","type":"command","url":"https://community.bistudio.com/wiki/setLocalWindParams","revid":321461,"updated":"2022-05-14T14:53:34Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets parameters for helicopter rotor wash.\nIt affects the visual effect of a rotor's downwash, such as blown particles, vegetation wind effect and area size.","syntaxes":[{"syntax":"setLocalWindParams [strength, diameter]","since":null,"effect":null,"exec":null,"params":[{"name":"strength","type":"Number","optional":false,"default":null,"description":"down-force wind strength","types":["Number"],"since":null,"text":"strength: Number - down-force wind strength"},{"name":"diameter","type":"Number","optional":false,"default":null,"description":"area affected","types":["Number"],"since":null,"text":"diameter: Number - area affected"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[strength, diameter]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetLocalWindParams [10, 5];\n```","code":["setLocalWindParams [10, 5];"]},{"text":"\"Disables\" the effects:\n\n```sqf\nsetLocalWindParams [0.0001, 0.0001]; // 0 values are ignored by the command\n```","code":["setLocalWindParams [0.0001, 0.0001]; // 0 values are ignored by the command"]},{"text":"Reset to default:\n\n```sqf\nsetLocalWindParams [1, 1];\n```","code":["setLocalWindParams [1, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWind","wind","setWindStr","setWindDir","setWindForce","windDir","windStr","gusts","setGusts"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setMagazineTurretAmmo","operator":null,"title":"setMagazineTurretAmmo","type":"command","url":"https://community.bistudio.com/wiki/setMagazineTurretAmmo","revid":377488,"updated":"2026-01-02T06:49:09Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets ammo count to given amount for given turret magazine.\n\n> [!NOTE]\n> Arma 3 v2.18 The magazine is first checked if it is loaded into the turret weapon, if not, the command falls back to old behaviour of selecting the first magazine from the list of available magazines.\n> In most cases it will be the loaded magazine.\n\n> [!IMPORTANT]\n> The turret itself **must** be local (see turretLocal, turretOwner).","syntaxes":[{"syntax":"vehicle setMagazineTurretAmmo [magazineClass, ammoCount, turretPath]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"magazineClass","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"magazineClass: String"},{"name":"ammoCount","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"ammoCount: Number"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"[-1] for driver turret is supported","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - [-1] for driver turret is supported"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[magazineClass, ammoCount, turretPath]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyMRAP setMagazineTurretAmmo [\"200Rnd_127x99_mag_Tracer_Red\", 30, [0]];\n```","code":["myMRAP setMagazineTurretAmmo [\"200Rnd_127x99_mag_Tracer_Red\", 30, [0]];"]},{"text":"Set ammo count on commander turret from server:\n\n```sqf\n_tank = tank;\n_turret = [0,0];\n_magazine = \"200Rnd_127x99_mag_Tracer_Red\";\n_ammo = 10;\n[_tank, [_magazine, _ammo, _turret]] remoteExec [\"setMagazineTurretAmmo\", _tank turretOwner _turret];\n```","code":["_tank = tank;\n_turret = [0,0];\n_magazine = \"200Rnd_127x99_mag_Tracer_Red\";\n_ammo = 10;\n[_tank, [_magazine, _ammo, _turret]] remoteExec [\"setMagazineTurretAmmo\", _tank turretOwner _turret];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazineTurretAmmo","setAmmoOnPylon","turretLocal","turretOwner"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"setMarkerAlpha","operator":null,"title":"setMarkerAlpha","type":"command","url":"https://community.bistudio.com/wiki/setMarkerAlpha","revid":370054,"updated":"2024-10-29T12:41:35Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the marker alpha. This is a modifier to the existing markerColor and will be applied on top of the marker color alpha. The marker is modified on all computers in a network session.\n\nWhen alpha equals `1`, the marker is visible, but if alpha equals `0`, then the marker is invisible.\n\nAlpha can be numbers and fractions.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"marker setMarkerAlpha alpha","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"},{"name":"alpha","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"alpha: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"alpha","types":["Number"]}}],"examples":[{"text":"```sqf\n\"my_marker\" setMarkerAlpha 0.5;\n```","code":["\"my_marker\" setMarkerAlpha 0.5;"]},{"text":"```sqf\n\"enemy_convoy_marker\" setMarkerAlpha 0;\n```","code":["\"enemy_convoy_marker\" setMarkerAlpha 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlphaLocal","setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","setMarkerType","createMarker"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerAlphaLocal","operator":null,"title":"setMarkerAlphaLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerAlphaLocal","revid":370053,"updated":"2024-10-29T12:41:01Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the marker alpha. See setMarkerAlpha.","syntaxes":[{"syntax":"marker setMarkerAlphaLocal alpha","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"},{"name":"alpha","type":"Number","optional":false,"default":null,"description":"alpha value from 0 (invisible) to 1 (fully visible)","types":["Number"],"since":null,"text":"alpha: Number - alpha value from 0 (invisible) to 1 (fully visible)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"alpha","types":["Number"]}}],"examples":[{"text":"```sqf\n\"my_marker\" setMarkerAlphaLocal 0.5;\n```","code":["\"my_marker\" setMarkerAlphaLocal 0.5;"]},{"text":"```sqf\n\"enemy_convoy_marker\" setMarkerAlphaLocal 0;\n```","code":["\"enemy_convoy_marker\" setMarkerAlphaLocal 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlpha","markerAlpha"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerBrush","operator":null,"title":"setMarkerBrush","type":"command","url":"https://community.bistudio.com/wiki/setMarkerBrush","revid":370036,"updated":"2024-10-28T20:28:34Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Selects the fill texture for the marker (\"RECTANGLE\" or \"ELLIPSE\"). Brush is the name of the subclass in `CfgMarkerBrushes`.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerBrush brush","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"brush","type":"String","optional":false,"default":null,"description":"(case-insensitive) can be one of:\n- \"Solid\"\n- Arma 3 v0.50 \"SolidFull\"\n- \"Horizontal\"\n- \"Vertical\"\n- \"Grid\"\n- \"FDiagonal\"\n- \"BDiagonal\"\n- \"DiagGrid\"\n- \"Cross\"\n- Arma 2 v1.00 \"Border\"\n- Arma 2 v1.00 \"SolidBorder\"","types":["String"],"since":null,"text":"brush: String - (case-insensitive) can be one of:\n- \"Solid\"\n- Arma 3 v0.50 \"SolidFull\"\n- \"Horizontal\"\n- \"Vertical\"\n- \"Grid\"\n- \"FDiagonal\"\n- \"BDiagonal\"\n- \"DiagGrid\"\n- \"Cross\"\n- Arma 2 v1.00 \"Border\"\n- Arma 2 v1.00 \"SolidBorder\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"brush","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerBrush \"DIAGGRID\";\n```","code":["\"Marker1\" setMarkerBrush \"DIAGGRID\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlpha","setMarkerAlphaLocal","setMarkerBrushLocal","setMarkerColor","setMarkerColorLocal","setMarkerDir","setMarkerDirLocal","setMarkerPos","setMarkerPosLocal","setMarkerShape","setMarkerShapeLocal","setMarkerSize","setMarkerSizeLocal","setMarkerText","setMarkerTextLocal","setMarkerType","setMarkerTypeLocal"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerBrushLocal","operator":null,"title":"setMarkerBrushLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerBrushLocal","revid":319560,"updated":"2022-05-13T09:24:29Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Selects the fill texture for the marker (\"RECTANGLE\" or \"ELLIPSE\"). Brush is the name of the subclass in CfgMarkerBrushes.\n\n*brush* can be:\n- \"Solid\"\n- \"SolidFull\" (A3 only)\n- \"Horizontal\"\n- \"Vertical\"\n- \"Grid\"\n- \"FDiagonal\"\n- \"BDiagonal\"\n- \"DiagGrid\"\n- \"Cross\"\n- \"Border\" (A2/A3 only)\n- \"SolidBorder\" (OA/A3 only)","syntaxes":[{"syntax":"markerName setMarkerBrushLocal brush","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"brush","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"brush: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"brush","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerBrushLocal \"DiagGrid\";\n```","code":["\"Marker1\" setMarkerBrushLocal \"DiagGrid\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlpha","setMarkerAlphaLocal","setMarkerBrush","setMarkerColor","setMarkerColorLocal","setMarkerDir","setMarkerDirLocal","setMarkerPos","setMarkerPosLocal","setMarkerShape","setMarkerShapeLocal","setMarkerSize","setMarkerSizeLocal","setMarkerText","setMarkerTextLocal","setMarkerType","setMarkerTypeLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerColor","operator":null,"title":"setMarkerColor","type":"command","url":"https://community.bistudio.com/wiki/setMarkerColor","revid":370055,"updated":"2024-10-29T12:42:44Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Set marker's colour. Arma 3's marker colour names and their corresponding RGBA values can be found here: Arma 3: CfgMarkerColors.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerColor colour","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"colour","type":"String","optional":false,"default":null,"description":"String\n- `CfgMarkerColors`'s class name\n- Arma 3 v2.20 direct colour definition in one of the following formats (values in range 0..1):\n  - \"#(r,g,b)\" (e.g `\"#(1,0,1)\"`, `1. FF00FF` equivalent)\n  - \"#(r,g,b,a)\" (e.g `\"#(0.678,0.749,0.514,0.5)\"`, `1. ADBF8380` equivalent). Alpha 'a' in this format is independent of markerAlpha","types":["String"],"since":null,"text":"colour: String\n- `CfgMarkerColors`'s class name\n- Arma 3 v2.20 direct colour definition in one of the following formats (values in range 0..1):\n  - \"#(r,g,b)\" (e.g `\"#(1,0,1)\"`, `1. FF00FF` equivalent)\n  - \"#(r,g,b,a)\" (e.g `\"#(0.678,0.749,0.514,0.5)\"`, `1. ADBF8380` equivalent). Alpha 'a' in this format is independent of markerAlpha"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"colour","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerColor \"ColorBlack\";\n```","code":["\"MarkerOne\" setMarkerColor \"ColorBlack\";"]},{"text":"```sqf\n\"MarkerOne\" setMarkerColor \"#(1,0,0,1)\"; // red color - since Arma 3 v2.20\n```","code":["\"MarkerOne\" setMarkerColor \"#(1,0,0,1)\"; // red color - since Arma 3 v2.20"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerColorLocal","markerColor","getMarkerColor","setMarkerBrush","createMarker","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","setMarkerType","setMarkerAlpha"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerColorLocal","operator":null,"title":"setMarkerColorLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerColorLocal","revid":370056,"updated":"2024-10-29T12:43:04Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set marker's colour. Arma 3's marker colour names and their corresponding RGBA values can be found here: Arma 3: CfgMarkerColors.","syntaxes":[{"syntax":"markerName setMarkerColorLocal colour","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"colour","type":"String","optional":false,"default":null,"description":"String\n- `CfgMarkerColors`'s class name\n- Arma 3 v2.20 direct colour definition in one of the following formats (values in range 0..1):\n  - \"#(r,g,b)\" (e.g `\"#(1,0,1)\"`, `1. FF00FF` equivalent)\n  - \"#(r,g,b,a)\" (e.g `\"#(0.678,0.749,0.514,0.5)\"`, `1. ADBF8380` equivalent). Alpha 'a' in this format is independent of markerAlpha","types":["String"],"since":null,"text":"colour: String\n- `CfgMarkerColors`'s class name\n- Arma 3 v2.20 direct colour definition in one of the following formats (values in range 0..1):\n  - \"#(r,g,b)\" (e.g `\"#(1,0,1)\"`, `1. FF00FF` equivalent)\n  - \"#(r,g,b,a)\" (e.g `\"#(0.678,0.749,0.514,0.5)\"`, `1. ADBF8380` equivalent). Alpha 'a' in this format is independent of markerAlpha"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"colour","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerColorLocal \"ColorBlack\";\n```","code":["\"MarkerOne\" setMarkerColorLocal \"ColorBlack\";"]},{"text":"```sqf\n\"MarkerOne\" setMarkerColorLocal \"#(1,0,0,1)\"; // red color (since Arma 3 v2.20)\n```","code":["\"MarkerOne\" setMarkerColorLocal \"#(1,0,0,1)\"; // red color (since Arma 3 v2.20)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["markerColor","getMarkerColor","setMarkerAlpha","setMarkerAlphaLocal","setMarkerBrush","setMarkerBrushLocal","setMarkerColor","setMarkerDir","setMarkerDirLocal","setMarkerPos","setMarkerPosLocal","setMarkerShape","setMarkerShapeLocal","setMarkerSize","setMarkerSizeLocal","setMarkerText","setMarkerTextLocal","setMarkerType","setMarkerTypeLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerDir","operator":null,"title":"setMarkerDir","type":"command","url":"https://community.bistudio.com/wiki/setMarkerDir","revid":370038,"updated":"2024-10-28T20:28:34Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the orientation of the marker. Angle is in degrees.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerDir angle","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"angle","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"angle: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"angle","types":["Number"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerDir 90;\n```","code":["\"Marker1\" setMarkerDir 90;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["markerDir","setMarkerBrush","createMarker","setMarkerColor","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","setMarkerType","setMarkerAlpha"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerDirLocal","operator":null,"title":"setMarkerDirLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerDirLocal","revid":348231,"updated":"2023-11-08T11:40:28Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the orientation of the marker.","syntaxes":[{"syntax":"markerName setMarkerDirLocal angle","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"angle of the marker in degree","types":["Number"],"since":null,"text":"angle: Number - angle of the marker in degree"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"angle","types":["Number"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerDirLocal 90;\n```","code":["\"Marker1\" setMarkerDirLocal 90;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerDir","markerDir"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerDrawPriority","operator":null,"title":"setMarkerDrawPriority","type":"command","url":"https://community.bistudio.com/wiki/setMarkerDrawPriority","revid":373673,"updated":"2025-06-09T15:29:58Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets marker draw priority. Higher priority markers are drawn on top. Default priority is 0.\n\n> [!IMPORTANT]\n> Be aware that this command has **local** effect despite the command name missing the word **local**!","syntaxes":[{"syntax":"markerName setMarkerDrawPriority priority","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"priority","type":"Number","optional":false,"default":null,"description":"draw priority","types":["Number"],"since":null,"text":"priority: Number - draw priority"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"priority","types":["Number"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerDrawPriority 0.5;\n```","code":["\"MarkerOne\" setMarkerDrawPriority 0.5;"]},{"text":"```sqf\n\"MarkerTwo\" setMarkerDrawPriority -2.1;\n```","code":["\"MarkerTwo\" setMarkerDrawPriority -2.1;"]}],"multiplayer":null,"problems":"setMarkerDrawPriority sorts allMapMarkers from least to most priority. Before Arma 3 v2.18 createMarker/createMarkerLocal did **not** care about drawing priority and added the created marker to the end of the array, making it top priority. Running setMarkerDrawPriority again sorted this issue.","aliases":[],"see_also":["markerDrawPriority","setMarkerType","setMarkerTypeLocal","markerType","setMarkerAlphaLocal","setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","createMarker","CfgMarkers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.14","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setMarkerPolyline","operator":null,"title":"setMarkerPolyline","type":"command","url":"https://community.bistudio.com/wiki/setMarkerPolyline","revid":370043,"updated":"2024-10-28T20:28:37Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets a polyline marker's path.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"marker setMarkerPolyline path","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"},{"name":"path","type":"Array of pairs Number, Number","optional":false,"default":null,"description":"`[x1, y1, x2, y2, ... xn, yn]`\n\n> [!IMPORTANT]\n> Be aware that this command expects an array with a minimum array size of 4 and that the array count always needs to be dividable by 2 and return a whole number. Code:\n>\n> ```sqf\n> count path >= 4 && count path mod 2 == 0; // true → valid path\n> ```","types":["Array","Number"],"since":null,"text":"path: Array of pairs Number, Number - `[x1, y1, x2, y2, ... xn, yn]`\n\n> [!IMPORTANT]\n> Be aware that this command expects an array with a minimum array size of 4 and that the array count always needs to be dividable by 2 and return a whole number. Code:\n>\n> ```sqf\n> count path >= 4 && count path mod 2 == 0; // true → valid path\n> ```"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"Changes `\"marker_1\"` into a polyline and draws a sine curve on player's position:\n\n```sqf\n// createMarker [\"marker_1\", [0,0,0]];\n\"marker_1\" setMarkerShape \"polyline\";\nprivate _return = [] ;\n\nfor \"_i\" from 0 to 100 step 0.1 do\n{\n    _return pushBack (_i + getPosASL player # 0);\n    _return pushBack ((sin (_i * 10)) * 10 + getPosASL player # 1);\n} ;\n\n\"marker_1\" setMarkerPolyline _return;\n```","code":["// createMarker [\"marker_1\", [0,0,0]];\n\"marker_1\" setMarkerShape \"polyline\";\nprivate _return = [] ;\n\nfor \"_i\" from 0 to 100 step 0.1 do\n{\n\t_return pushBack (_i + getPosASL player # 0);\n\t_return pushBack ((sin (_i * 10)) * 10 + getPosASL player # 1);\n} ;\n\n\"marker_1\" setMarkerPolyline _return;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["markerPolyline","setMarkerPolylineLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setMarkerPolylineLocal","operator":null,"title":"setMarkerPolylineLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerPolylineLocal","revid":378527,"updated":"2026-05-04T01:57:41Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets a polyline marker's path. Works only on the computer that executes this command.","syntaxes":[{"syntax":"marker setMarkerPolylineLocal path","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"marker: String"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":"`[x1, y1, x2, y2, ... xn, yn]`","types":["Array","Number"],"since":null,"text":"path: Array of Numbers - `[x1, y1, x2, y2, ... xn, yn]`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"Changes `\"marker_1\"` into a polyline and draws a sine curve on your position:\n\n```sqf\n\"marker_1\" setMarkerShape \"polyline\";\nprivate _return = [] ;\n\nfor \"_i\" from 0 to 100 step 0.1 do\n{\n    _return pushBack (_i + getPos player#0);\n    _return pushBack ((sin (_i*10))*10 + getPos player#1);\n} ;\n\n\"marker_1\" setMarkerPolylineLocal _return;\n```","code":["\"marker_1\" setMarkerShape \"polyline\";\nprivate _return = [] ;\n\nfor \"_i\" from 0 to 100 step 0.1 do\n{\n\t_return pushBack (_i + getPos player#0);\n\t_return pushBack ((sin (_i*10))*10 + getPos player#1);\n} ;\n\n\"marker_1\" setMarkerPolylineLocal _return;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["markerPolyline","setMarkerPolyline"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setMarkerPos","operator":null,"title":"setMarkerPos","type":"command","url":"https://community.bistudio.com/wiki/setMarkerPos","revid":377245,"updated":"2026-01-02T05:03:33Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Moves the marker. If position is given in 3D format, `z` coordinate is stored with the marker and will be used when marker is passed to commands like createVehicle, createUnit, createAgent, createMine, setVehiclePosition for example. In case of an object, the object's model [0,0,0] is used.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerPos position","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"position","type":null,"optional":false,"default":null,"description":"Position2D or PositionAGL or Arma 3 v1.94 Object. In case of an object, the object's model [0,0,0] is used.","types":["Position2D","PositionAGL","Object"],"since":null,"text":"position: Position2D or PositionAGL or Arma 3 v1.94 Object. In case of an object, the object's model [0,0,0] is used."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"position","types":["Position2D","PositionAGL","Object"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerPos getMarkerPos \"MarkerTwo\";\n```","code":["\"MarkerOne\" setMarkerPos getMarkerPos \"MarkerTwo\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerPosLocal","setMarkerBrush","setMarkerColor","setMarkerDir","createMarker","setMarkerShape","setMarkerSize","setMarkerText","setMarkerType","setMarkerAlpha"],"notes":[{"user":"Pulverizer","date":"2007-03-23T23:47:00Z","text":"Effect is local in OFP."},{"user":"Dr Eyeball","date":"2009-08-07T02:03:00Z","text":"The marker position can actually be set in 3D. This has a benefit for respawn markers, when placed at the correct altitude ASL on the LHD, the correct altitude will be used for respawn.\nThere is no particular benefit for regular markers since markerPos will still return 0 for the altitude array element. // Tip obtained from Xeno"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerPosLocal","operator":null,"title":"setMarkerPosLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerPosLocal","revid":377550,"updated":"2026-01-02T06:54:46Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Moves the marker. If position is given in 3D format, `z` coordinate is stored with the marker and will be used when marker is passed to commands like createVehicle, createUnit, createAgent, createMine, setVehiclePosition for example. In case of an object, the object's model [0,0,0] is used.","syntaxes":[{"syntax":"markerName setMarkerPosLocal position","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"position","type":null,"optional":false,"default":null,"description":"Position2D, PositionAGL or Arma 3 v1.94 Object. In case of an object, the object's model [0,0,0] is used.","types":["Position2D","PositionAGL","Object"],"since":null,"text":"position: Position2D, PositionAGL or Arma 3 v1.94 Object. In case of an object, the object's model [0,0,0] is used."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"position","types":["Position2D","PositionAGL","Object"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerPosLocal getMarkerPos \"MarkerTwo\";\n```","code":["\"MarkerOne\" setMarkerPosLocal getMarkerPos \"MarkerTwo\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerPos","setMarkerAlphaLocal","setMarkerBrushLocal","setMarkerColorLocal","setMarkerDirLocal","setMarkerShapeLocal","setMarkerSizeLocal","setMarkerTextLocal","setMarkerTypeLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerShadow","operator":null,"title":"setMarkerShadow","type":"command","url":"https://community.bistudio.com/wiki/setMarkerShadow","revid":349188,"updated":"2023-11-08T14:50:39Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the shadow property of given marker.","syntaxes":[{"syntax":"marker setMarkerShadow shadowState","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":"the marker","types":["String"],"since":null,"text":"marker: String - the marker"},{"name":"shadowState","type":"Boolean","optional":false,"default":null,"description":"true to enable the shadow, false to disable it","types":["Boolean"],"since":null,"text":"shadowState: Boolean - true to enable the shadow, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"shadowState","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_myMarker setMarkerShadow true; // enable shadow\n```","code":["_myMarker setMarkerShadow true; // enable shadow"]}],"multiplayer":null,"problems":"setMarkerType will reset the shadow value to the one defined in marker type.","aliases":[],"see_also":["markerShadow","setMarkerShadowLocal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setMarkerShadowLocal","operator":null,"title":"setMarkerShadowLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerShadowLocal","revid":349276,"updated":"2023-11-08T14:51:11Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the shadow property of given marker.","syntaxes":[{"syntax":"marker setMarkerShadowLocal shadowState","since":null,"effect":null,"exec":null,"params":[{"name":"marker","type":"String","optional":false,"default":null,"description":"the marker","types":["String"],"since":null,"text":"marker: String - the marker"},{"name":"shadowState","type":"Boolean","optional":false,"default":null,"description":"true to enable the shadow, false to disable it","types":["Boolean"],"since":null,"text":"shadowState: Boolean - true to enable the shadow, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"marker","types":["String"]},"right":{"text":"shadowState","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_myMarker setMarkerShadowLocal true; // enable shadow\n```","code":["_myMarker setMarkerShadowLocal true; // enable shadow"]}],"multiplayer":null,"problems":"setMarkerType will reset the shadow value to the one defined in marker type.","aliases":[],"see_also":["markerShadow","setMarkerShadow"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Arma 3 version 2.04","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setMarkerShape","operator":null,"title":"setMarkerShape","type":"command","url":"https://community.bistudio.com/wiki/setMarkerShape","revid":370121,"updated":"2024-11-01T19:51:56Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Selects shape (actual type) of the marker. Non-existing marker shape defaults to \"RECTANGLE\".","syntaxes":[{"syntax":"markerName setMarkerShape shape","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"shape","type":"String","optional":false,"default":null,"description":"the shape, can be one of:\n- `\"ICON\"`\n- `\"RECTANGLE\"`\n- `\"ELLIPSE\"`\n- Arma 3 v1.60 `\"POLYLINE\"`\n- Arma 3 v2.20 `\"TRIANGLE\"`\n- Arma 3 v2.20 `\"PENTAGON\"`\n- Arma 3 v2.20 `\"HEXAGON\"`\n- Arma 3 v2.20 `\"HEPTAGON\"`\n- Arma 3 v2.20 `\"OCTAGON\"`\n- Arma 3 v2.20 `\"NONAGON\"`\n- Arma 3 v2.20 `\"DECAGON\"`","types":["String"],"since":null,"text":"shape: String - the shape, can be one of:\n- `\"ICON\"`\n- `\"RECTANGLE\"`\n- `\"ELLIPSE\"`\n- Arma 3 v1.60 `\"POLYLINE\"`\n- Arma 3 v2.20 `\"TRIANGLE\"`\n- Arma 3 v2.20 `\"PENTAGON\"`\n- Arma 3 v2.20 `\"HEXAGON\"`\n- Arma 3 v2.20 `\"HEPTAGON\"`\n- Arma 3 v2.20 `\"OCTAGON\"`\n- Arma 3 v2.20 `\"NONAGON\"`\n- Arma 3 v2.20 `\"DECAGON\"`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"shape","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerShape \"RECTANGLE\";\n```","code":["\"Marker1\" setMarkerShape \"RECTANGLE\";"]}],"multiplayer":"> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","problems":null,"aliases":[],"see_also":["markerShape","setMarkerShapeLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerShapeLocal","operator":null,"title":"setMarkerShapeLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerShapeLocal","revid":370123,"updated":"2024-11-01T19:52:42Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Selects shape (actual type) of the local marker. Non-existing marker shape defaults to \"RECTANGLE\".","syntaxes":[{"syntax":"markerName setMarkerShapeLocal shape","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"shape","type":"String","optional":false,"default":null,"description":"the shape, can be one of:\n- `\"ICON\"`\n- `\"RECTANGLE\"`\n- `\"ELLIPSE\"`\n- Arma 3 v1.60 `\"POLYLINE\"`\n- Arma 3 v2.20 `\"TRIANGLE\"`\n- Arma 3 v2.20 `\"PENTAGON\"`\n- Arma 3 v2.20 `\"HEXAGON\"`\n- Arma 3 v2.20 `\"HEPTAGON\"`\n- Arma 3 v2.20 `\"OCTAGON\"`\n- Arma 3 v2.20 `\"NONAGON\"`\n- Arma 3 v2.20 `\"DECAGON\"`","types":["String"],"since":null,"text":"shape: String - the shape, can be one of:\n- `\"ICON\"`\n- `\"RECTANGLE\"`\n- `\"ELLIPSE\"`\n- Arma 3 v1.60 `\"POLYLINE\"`\n- Arma 3 v2.20 `\"TRIANGLE\"`\n- Arma 3 v2.20 `\"PENTAGON\"`\n- Arma 3 v2.20 `\"HEXAGON\"`\n- Arma 3 v2.20 `\"HEPTAGON\"`\n- Arma 3 v2.20 `\"OCTAGON\"`\n- Arma 3 v2.20 `\"NONAGON\"`\n- Arma 3 v2.20 `\"DECAGON\"`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"shape","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerShapeLocal \"RECTANGLE\";\n```","code":["\"Marker1\" setMarkerShapeLocal \"RECTANGLE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerShape","markerShape"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerSize","operator":null,"title":"setMarkerSize","type":"command","url":"https://community.bistudio.com/wiki/setMarkerSize","revid":370044,"updated":"2024-10-28T20:28:37Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the marker's size.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerSize [a-axis, b-axis]","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"a-axis","type":"Number","optional":false,"default":null,"description":"1/2 width of marker","types":["Number"],"since":null,"text":"a-axis: Number - 1/2 width of marker"},{"name":"b-axis","type":"Number","optional":false,"default":null,"description":"1/2 height of marker","types":["Number"],"since":null,"text":"b-axis: Number - 1/2 height of marker"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"[a-axis, b-axis]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerSize [100, 200];\n```","code":["\"MarkerOne\" setMarkerSize [100, 200];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerSizeLocal","getMarkerSize","markerSize"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.21","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerSizeLocal","operator":null,"title":"setMarkerSizeLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerSizeLocal","revid":330367,"updated":"2022-09-04T20:18:20Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set marker size.","syntaxes":[{"syntax":"markerName setMarkerSizeLocal [axisA, axisB]","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"axisA","type":"Number","optional":false,"default":null,"description":"1/2 width of marker","types":["Number"],"since":null,"text":"axisA: Number - 1/2 width of marker"},{"name":"axisB","type":"Number","optional":false,"default":null,"description":"1/2 height of marker","types":["Number"],"since":null,"text":"axisB: Number - 1/2 height of marker"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"[axisA, axisB]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerSizeLocal [100, 200];\n```","code":["\"MarkerOne\" setMarkerSizeLocal [100, 200];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerAlpha","setMarkerAlphaLocal","setMarkerBrush","setMarkerBrushLocal","setMarkerColor","setMarkerColorLocal","setMarkerDir","setMarkerDirLocal","setMarkerPos","setMarkerPosLocal","setMarkerShape","setMarkerShapeLocal","setMarkerSize","setMarkerText","setMarkerTextLocal","setMarkerType","setMarkerTypeLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerText","operator":null,"title":"setMarkerText","type":"command","url":"https://community.bistudio.com/wiki/setMarkerText","revid":370039,"updated":"2024-10-28T20:28:34Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the text label of an existing marker.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerText text","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerText \"You are here.\";\n```","code":["\"Marker1\" setMarkerText \"You are here.\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerType","setMarkerAlpha"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerTextLocal","operator":null,"title":"setMarkerTextLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerTextLocal","revid":319570,"updated":"2022-05-13T09:24:29Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the text label of an existing marker.","syntaxes":[{"syntax":"markerName setMarkerTextLocal text","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n\"Marker1\" setMarkerTextLocal \"You are here.\";\n```","code":["\"Marker1\" setMarkerTextLocal \"You are here.\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerType"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerType","operator":null,"title":"setMarkerType","type":"command","url":"https://community.bistudio.com/wiki/setMarkerType","revid":370037,"updated":"2024-10-28T20:28:34Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets marker type. Marker type is a class name from CfgMarkers.\n\n> [!NOTE]\n> **Multiplayer optimisation:** Global marker commands always broadcast the *entire* marker state over the network.\n> As such, the number of network messages exchanged when creating or editing a marker can be reduced by performing all but the last operation using local marker commands, then using a global marker command for the last change (and subsequent global broadcast of all changes applied to the marker).","syntaxes":[{"syntax":"markerName setMarkerType type","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"type","type":"String","optional":false,"default":null,"description":"see CfgMarkers","types":["String"],"since":null,"text":"type: String - see CfgMarkers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerType \"Warning\";\n```","code":["\"MarkerOne\" setMarkerType \"Warning\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["CfgMarkers","setMarkerDrawPriority","setMarkerTypeLocal","markerType","setMarkerAlphaLocal","setMarkerBrush","setMarkerColor","setMarkerDir","setMarkerPos","setMarkerShape","setMarkerSize","setMarkerText","createMarker"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMarkerTypeLocal","operator":null,"title":"setMarkerTypeLocal","type":"command","url":"https://community.bistudio.com/wiki/setMarkerTypeLocal","revid":349126,"updated":"2023-11-08T14:49:40Z","groups":["Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets marker type locally. Marker type is a class name in CfgMarkers.","syntaxes":[{"syntax":"markerName setMarkerTypeLocal type","since":null,"effect":null,"exec":null,"params":[{"name":"markerName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"markerName: String"},{"name":"type","type":"String","optional":false,"default":null,"description":"see CfgMarkers.","types":["String"],"since":null,"text":"type: String - see CfgMarkers."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"markerName","types":["String"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n\"MarkerOne\" setMarkerTypeLocal \"Warning\";\n```","code":["\"MarkerOne\" setMarkerTypeLocal \"Warning\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["CfgMarkers","setMarkerAlpha","setMarkerAlphaLocal","setMarkerBrush","setMarkerBrushLocal","setMarkerColor","setMarkerColorLocal","setMarkerDir","setMarkerDirLocal","setMarkerPos","setMarkerPosLocal","setMarkerShape","setMarkerShapeLocal","setMarkerSize","setMarkerSizeLocal","setMarkerText","setMarkerTextLocal","setMarkerType","markerType"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Markers","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMass","operator":null,"title":"setMass","type":"command","url":"https://community.bistudio.com/wiki/setMass","revid":373893,"updated":"2025-06-26T11:00:29Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Changes the mass of a PhysX object. When using the alternative syntax the mass change is gradual during the given time. A time of zero means immediate change.\n\n> [!IMPORTANT]\n> When main syntax is used on local vehicle, the change is global. When alternative syntax is used with time transition on local vehicle, the gradual mass change doesn't happen on remote clients, only final mass is applied after the given time. If you need gradual change on remote clients too, remote execute setMass globally.","syntaxes":[{"syntax":"myObject setMass mass","since":null,"effect":null,"exec":null,"params":[{"name":"myObject","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"myObject: Object"},{"name":"mass","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"mass: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"myObject","types":["Object"]},"right":{"text":"mass","types":["Number"]}},{"syntax":"myObject setMass [mass, time]","since":null,"effect":null,"exec":null,"params":[{"name":"myObject","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"myObject: Object"},{"name":"mass","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"mass: Number"},{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"myObject","types":["Object"]},"right":{"text":"[mass, time]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyObject setMass [10, 0.5];\n```","code":["myObject setMass [10, 0.5];"]},{"text":"```sqf\nmyObject setMass 10;\n```","code":["myObject setMass 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMass","setCenterOfMass","getCenterOfMass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setMaxLoad","operator":null,"title":"setMaxLoad","type":"command","url":"https://community.bistudio.com/wiki/setMaxLoad","revid":309142,"updated":"2022-05-03T11:53:13Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Sets maximum load limit for a uniform/vest/backpack containers, vehicle cargo, supply boxes and weapon holders. In MP this command should be executed on the server and will persist on given container for JIP.\n\n> [!NOTE]\n> Cannot be set on a unit, as unit max load value is static config type","syntaxes":[{"syntax":"container setMaxLoad maxLoadValue","since":null,"effect":null,"exec":null,"params":[{"name":"container","type":"Object","optional":false,"default":null,"description":"uniform/vest/backpack container, vehicle cargo, supply box, weapon holder","types":["Object"],"since":null,"text":"container: Object - uniform/vest/backpack container, vehicle cargo, supply box, weapon holder"},{"name":"maxLoadValue","type":"Number","optional":false,"default":null,"description":"max load limit","types":["Number"],"since":null,"text":"maxLoadValue: Number - max load limit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"container","types":["Object"]},"right":{"text":"maxLoadValue","types":["Number"]}}],"examples":[{"text":"```sqf\n_yaMum setMaxLoad _maxLoad;\n```","code":["_yaMum setMaxLoad _maxLoad;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["maxLoad","load","loadAbs","loadBackpack","loadUniform","loadVest","getContainerMaxLoad"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"setMimic","operator":null,"title":"setMimic","type":"command","url":"https://community.bistudio.com/wiki/setMimic","revid":341210,"updated":"2023-05-13T22:48:34Z","groups":["Object Manipulation","Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets person's facial expression. To set it back to default, use \"\".\n\n> [!NOTE]\n> **Arma 3:** Prior to Arma 3 v2.01.146630 Mimics must be written in all lower case letters.","syntaxes":[{"syntax":"person setMimic mimic","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"mimic","type":"String","optional":false,"default":null,"description":"can be one of:\n\n| Before Arma 2 OA v1.6x | Since Arma 2 OA v1.6x |\n|---|---|\n| - \"Default\"<br>- \"Normal\"<br>- \"Smile\"<br>- \"Hurt\"<br>- \"Ironic\"<br>- \"Sad\"<br>- \"Cynic\"<br>- \"Surprised\"<br>- \"Agresive\" [sic]<br>- \"Angry\" | - \"neutral\"<br>- \"dead\"<br>- \"danger\"<br>- \"hurt\"<br>- \"aware\"<br>- \"safe\"<br>- \"combat\"<br>- \"unconscious\" |","types":["String"],"since":null,"text":"mimic: String - can be one of:\n\n| Before Arma 2 OA v1.6x | Since Arma 2 OA v1.6x |\n|---|---|\n| - \"Default\"<br>- \"Normal\"<br>- \"Smile\"<br>- \"Hurt\"<br>- \"Ironic\"<br>- \"Sad\"<br>- \"Cynic\"<br>- \"Surprised\"<br>- \"Agresive\" [sic]<br>- \"Angry\" | - \"neutral\"<br>- \"dead\"<br>- \"danger\"<br>- \"hurt\"<br>- \"aware\"<br>- \"safe\"<br>- \"combat\"<br>- \"unconscious\" |"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"mimic","types":["String"]}}],"examples":[{"text":"```sqf\n_soldier1 setMimic \"hurt\";\n```","code":["_soldier1 setMimic \"hurt\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setIdentity","setFace","setFaceAnimation","enableMimics","setRandomLip"],"notes":[{"user":"Lou Montana","date":"2010-01-19T15:30:00Z","text":"Not working in **Arma 2 1.05**."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Identity","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setMissileTarget","operator":null,"title":"setMissileTarget","type":"command","url":"https://community.bistudio.com/wiki/setMissileTarget","revid":373564,"updated":"2025-05-22T22:04:50Z","groups":["Object Manipulation","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets a guided missile target. Does not work for all types of missiles. If the target is dead, it is ignored. The target has to be inside the missile's configured targeting cone for the command to work.","syntaxes":[{"syntax":"munition setMissileTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":"missile","types":["Object"],"since":null,"text":"munition: Object - missile"},{"name":"target","type":"Object","optional":false,"default":null,"description":"valid missile target or objNull to cancel targeting","types":["Object"],"since":null,"text":"target: Object - valid missile target or objNull to cancel targeting"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successful","text":"Boolean - true if successful"},"form":"binary","operator":null,"left":{"text":"munition","types":["Object"]},"right":{"text":"target","types":["Object"]}},{"syntax":"munition setMissileTarget [target, force]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":"missile","types":["Object"],"since":null,"text":"munition: Object - missile"},{"name":"target","type":"Object","optional":false,"default":null,"description":"valid missile target or objNull to cancel targeting","types":["Object"],"since":null,"text":"target: Object - valid missile target or objNull to cancel targeting"},{"name":"force","type":"Boolean","optional":false,"default":null,"description":"true to force target (for example to target countermeasure flare object)","types":["Boolean"],"since":null,"text":"force: Boolean - true to force target (for example to target countermeasure flare object)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successful","text":"Boolean - true if successful"},"form":"binary","operator":null,"left":{"text":"munition","types":["Object"]},"right":{"text":"[target, force]","types":["Array"]}}],"examples":[{"text":"```sqf\nmissile1 setMissileTarget tank1;\n```","code":["missile1 setMissileTarget tank1;"]},{"text":"```sqf\nprivate _missile = createVehicle [\"Missile_AGM_01_F\", player modelToWorld [0,0,50], [], 0, \"CAN_COLLIDE\"];\n_missile setDir getDir player;\nprivate _target = createVehicle [\"O_APC_Wheeled_02_rcws_v2_F\", player modelToWorld [0,300,0], [], 0, \"CAN_COLLIDE\"];\n_target setVehicleTiPars [1, 1, 1];\n[_missile, _target] spawn {\n    params [\"_missile\", \"_target\"];\n    sleep 0.1;\n    _missile setMissileTarget _target;\n};\n```","code":["private _missile = createVehicle [\"Missile_AGM_01_F\", player modelToWorld [0,0,50], [], 0, \"CAN_COLLIDE\"];\n_missile setDir getDir player;\nprivate _target = createVehicle [\"O_APC_Wheeled_02_rcws_v2_F\", player modelToWorld [0,300,0], [], 0, \"CAN_COLLIDE\"];\n_target setVehicleTiPars [1, 1, 1];\n[_missile, _target] spawn {\n\tparams [\"_missile\", \"_target\"];\n\tsleep 0.1;\n\t_missile setMissileTarget _target;\n};"]},{"text":"```sqf\n_missile setMissileTarget objNull; // cancels targeting\n```","code":["_missile setMissileTarget objNull; // cancels targeting"]},{"text":"```sqf\n_missile setMissileTarget [flare1, true];\n```","code":["_missile setMissileTarget [flare1, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missileTargetPos","setMissileTargetPos","missileTarget","missileState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Weapons","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"setMissileTargetPos","operator":null,"title":"setMissileTargetPos","type":"command","url":"https://community.bistudio.com/wiki/setMissileTargetPos","revid":377534,"updated":"2026-01-02T06:53:19Z","groups":["Object Manipulation","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets a guided munition target position.\nThe munition must have `manualControl` config entry to use this command.\nThe target position has to be inside the missile's configured targeting cone for the command to work.","syntaxes":[{"syntax":"munition setMissileTargetPos position","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"munition: Object"},{"name":"position","type":"PositionATL","optional":false,"default":null,"description":null,"types":["PositionATL"],"since":null,"text":"position: PositionATL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"munition","types":["Object"]},"right":{"text":"position","types":["PositionATL"]}}],"examples":[{"text":"```sqf\nmissile1 setMissileTargetPos unitAimPosition tank1;\n```","code":["missile1 setMissileTargetPos unitAimPosition tank1;"]},{"text":"```sqf\nprivate _missile = createVehicle [\"M_Scalpel_AT\", player modelToWorld [0,0,100], [], 0, \"CAN_COLLIDE\"];\n_missile setMissileTargetPos (player modelToWorld [0,100,0]);\n```","code":["private _missile = createVehicle [\"M_Scalpel_AT\", player modelToWorld [0,0,100], [], 0, \"CAN_COLLIDE\"];\n_missile setMissileTargetPos (player modelToWorld [0,100,0]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missileTargetPos","setMissileTarget","missileTarget","missileState"],"notes":[{"user":"Benargee","date":"2020-04-13T06:04:00Z","text":"To get list of compatible missiles with `manualControl = 1`, use the below script and paste the clipboard results to a text editor.\n\n```sqf\nprivate _cfgCount = count (configfile >> \"CfgAmmo\");\nprivate _pasteStr = \"\";\n\nfor \"_x\" from 0 to (_cfgCount - 1) do {\n    _cfg = (configFile >> \"CfgAmmo\") select _x;\n    _ammoClassName = configName _cfg;\n    private _manCtrl = getNumber (configFile >> \"CfgAmmo\" >> _ammoClassName >> \"manualControl\");\n    if (_manCtrl > 0) then {\n            _pasteStr = _pasteStr + _ammoClassName + endl;\n    };\n};\n\ncopyToClipboard _pasteStr;\n```"},{"user":"Lou Montana","date":"2022-08-12T22:06:00Z","text":"Tested with a player-controlled AH-99 firing DAGR, a civilian helicopter named `heli` above water/land, and the following code:\n\n```sqf\nif (!isNil \"EH\") then\n{\n    vehicle player removeEventHandler [\"Fired\", EH];\n};\nEH = vehicle player addEventHandler [\"Fired\", {\nparams [\"_unit\", \"_weapon\", \"_muzzle\", \"_mode\", \"_ammo\", \"_magazine\", \"_missile\", \"_gunner\"];\n    _missile setMissileTargetPos getPosATL heli; // changing here getPosATL / getPosASL / getPos\n    systemChat str [_missile, missileTarget _missile, missileTargetPos _missile];\n}];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Weapons","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"setMissionOptions","operator":null,"title":"setMissionOptions","type":"command","url":"https://community.bistudio.com/wiki/setMissionOptions","revid":378913,"updated":"2026-08-12T15:53:18Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets various mission options. The options are automatically reset between missions and are saved/restored with the save system.\n\nAvailable Options:\n\n- IgnoreNoDamage: Boolean - (default false) true to filter out no change in damage from HandleDamage calls\n- IgnoreFakeHeadHit: Boolean - (default false) true to filter out FakeHeadHit context from HandleDamage calls\n- IgnoreUpsideDownDamage: Boolean - (default false) true to ignore some minor upside down damage accumulation for a helicopter\n- Arma 3 v2.20 SnakesCanOpenDoors: Boolean - (default false) true to revert to legacy behaviour when snakes would open doors when entering houses\n- Arma 3 v2.20 AIThinkOnlyLocal: Boolean - (default false) true to disable processing targetting data for remote AI units, knowsAbout, targets and similar commands will cease to work on remote units. For a gain in client performance because they no longer have to calculate all AI units.\n- Arma 3 v2.24 MapSymbolIsHiddenWithTheObject: Boolean - (default true) true to hide map symbol when terrain object is hidden.\n- Arma 3 v2.24 MapHideForests: Boolean - (default false) true to hide map symbols for forests.\n- Arma 3 v2.24 MapHideRockFormations: Boolean - (default false) true to hide map symbols for rock formations.\n- Arma 3 v2.24 MapHideTowns: Boolean - (default false) true to hide map symbols for towns.\n- Arma 3 v2.24 MapHideRoads: Boolean - (default false) true to hide map symbols for roads.\n- Arma 3 v2.24 MapHideRivers: Boolean - (default false) true to hide map symbols for rivers.\n- Arma 3 v2.24 MapHideSigns: Boolean - (default false) true to hide map icons for objects.\n- Arma 3 v2.24 MapHideSmallSigns: Boolean - (default false) true to hide map icons for trees, bushes, rocks.\n- Arma 3 v2.24 MapHideLocations: Boolean - (default false) true to hide map icons for trees, bushes, rocks.\n\nProviding a empty HashMap will reset all options to defaults.","syntaxes":[{"syntax":"setMissionOptions options","since":null,"effect":null,"exec":null,"params":[{"name":"options","type":"HashMap","optional":false,"default":null,"description":"a HashMap containing all the options to be changed","types":["HashMap"],"since":null,"text":"options: HashMap - a HashMap containing all the options to be changed"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"options","types":["HashMap"]}}],"examples":[{"text":"```sqf\nsetMissionOptions createHashMapFromArray [[\"IgnoreNoDamage\", true], [\"IgnoreFakeHeadHit\", true], [\"IgnoreUpsideDownDamage\", true]];\n```","code":["setMissionOptions createHashMapFromArray [[\"IgnoreNoDamage\", true], [\"IgnoreFakeHeadHit\", true], [\"IgnoreUpsideDownDamage\", true]];"]},{"text":"```sqf\nsetMissionOptions createHashMap; // reset options to default\n```","code":["setMissionOptions createHashMap; // reset options to default"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMissionOptions","getResolution","getAudioOptionVolumes","getSubtitleOptions"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setMousePosition","operator":null,"title":"setMousePosition","type":"command","url":"https://community.bistudio.com/wiki/setMousePosition","revid":340820,"updated":"2023-05-07T11:05:54Z","groups":["GUI Control - Positioning"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Moves mouse pointer to specified position on the screen. **x** and **y** could be any number, but will be clipped so mouse never leaves the screen area.","syntaxes":[{"syntax":"setMousePosition [x, y]","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"x in screen coordinates","types":["Number"],"since":null,"text":"x: Number - x in screen coordinates"},{"name":"y","type":"Number","optional":false,"default":null,"description":"y in screen coordinates","types":["Number"],"since":null,"text":"y: Number - y in screen coordinates"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[x, y]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetMousePosition [0.5, 0.5];\n```","code":["setMousePosition [0.5, 0.5];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getMousePosition","ctrlSetMousePosition","ctrlMousePosition","ctrlMapCursor","reversedMouseY"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Positioning","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setMusicEffect","operator":null,"title":"setMusicEffect","type":"command","url":"https://community.bistudio.com/wiki/setMusicEffect","revid":377584,"updated":"2026-01-02T06:56:42Z","groups":["Sounds","Triggers","Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines a music track played on activation. If another track is playing already, this will stop it and start the new track.\n\nTrack is a subclass name of CfgMusic. In addition, \"$STOP$\" (stops the current music track) or use `playMusic \"\"`.\nWhen used in a trigger, the track starts on activation but does not automatically stop on deactivation.","syntaxes":[{"syntax":"trigger setMusicEffect track","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"track","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"track: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"track","types":["String"]}},{"syntax":"waypoint setMusicEffect track","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"track","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"track: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"track","types":["String"]}}],"examples":[{"text":"```sqf\n_trigger setMusicEffect \"Track1\";\n```","code":["_trigger setMusicEffect \"Track1\";"]},{"text":"```sqf\n[_group1,1] setMusicEffect \"$STOP$\";\n```","code":["[_group1,1] setMusicEffect \"$STOP$\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","setSoundEffect","setTitleEffect"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Command Group: Triggers","Command Group: Waypoints"]},{"name":"setMusicEventHandler","operator":null,"title":"setMusicEventHandler","type":"command","url":"https://community.bistudio.com/wiki/setMusicEventHandler","revid":319639,"updated":"2022-05-13T09:24:37Z","groups":["Event Handlers","Sounds"],"status":"deprecated","replaced_by":["addMusicEventHandler"],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets given music track event handler. Will overwrite other music event handlers.\n\n> [!CAUTION]\n> This information is **obsolete**. Use addMusicEventHandler instead as it can stack music event handlers.","syntaxes":[{"syntax":"setMusicEventHandler [type, function]","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"String","optional":false,"default":null,"description":"\"MusicStart\" or \"MusicStop\"","types":["String"],"since":null,"text":"type: String - \"MusicStart\" or \"MusicStop\""},{"name":"function","type":"String","optional":false,"default":null,"description":"script to be executed. Passes params array 0: class name of the sound in CfgMusic, 1: event handler id","types":["String"],"since":null,"text":"function: String - script to be executed. Passes params array 0: class name of the sound in CfgMusic, 1: event handler id"}],"returns":{"type":"Number","types":["Number"],"description":"id of the event handler","text":"Number - id of the event handler"},"form":"unary","operator":null,"left":null,"right":{"text":"[type, function]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ehID = setMusicEventHandler [\"MusicStart\", \"hint str _this\"];\n```","code":["_ehID = setMusicEventHandler [\"MusicStart\", \"hint str _this\"];"]},{"text":"```sqf\n_ehID = setMusicEventHandler [\"MusicStop\", \"hint str _this\"];\n```","code":["_ehID = setMusicEventHandler [\"MusicStop\", \"hint str _this\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMusicEventHandler","removeMusicEventHandler","playMusic","removeAllMusicEventHandlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Event Handlers","Command Group: Sounds","Introduced with Arma 3 version 1.02","Scripting Commands"]},{"name":"setName","operator":null,"title":"setName","type":"command","url":"https://community.bistudio.com/wiki/setName","revid":370891,"updated":"2025-02-21T10:44:05Z","groups":["Unit Identity","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the name of a location or a person (person only in single player).","syntaxes":[{"syntax":"thing setName name","since":null,"effect":null,"exec":null,"params":[{"name":"thing","type":"Location or Arma 3 v1.02 Object","optional":false,"default":null,"description":null,"types":["Location","Object"],"since":null,"text":"thing: Location or Arma 3 v1.02 Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"thing","types":["Location","Object"]},"right":{"text":"name","types":["String"]}},{"syntax":"unit setName [name, firstName, lastName]","since":"arma3 1.02","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"},{"name":"firstName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"firstName: String"},{"name":"lastName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"lastName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[name, firstName, lastName]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyLocation setName \"My Location Name\";\n```","code":["myLocation setName \"My Location Name\";"]},{"text":"```sqf\nplayer setName \"New Name\";\n```","code":["player setName \"New Name\";"]},{"text":"```sqf\nplayer setName [\"Ben Kerry\",\"Ben\",\"Kerry\"];\n```","code":["player setName [\"Ben Kerry\",\"Ben\",\"Kerry\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["name","nameSound","setNameSound","setIdentity"],"notes":[{"user":"Pierre MGI","date":"2014-08-18T22:15:00Z","text":"Only last name will appear in command bar i.e. `this setName _myNameArray` will display `_myNameArray select 2`.\nIf setName is used with a string e.g `this setName \"blah\"`, nothing occurs in the command bar and the default randomized name is displayed.\n\nDealing with the units' names in a script, _x (in a `forEach units _group`, for example) will return the \"object\" as `B ALFA 4-1:2` or the name written in ai unit name field in editor (if exists).\nThis context is rather a \"variable name\" for each object (ai) than an \"identity name\" as given via the setName command."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Unit Identity","Introduced with Armed Assault version 1.08","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setNameSound","operator":null,"title":"setNameSound","type":"command","url":"https://community.bistudio.com/wiki/setNameSound","revid":363769,"updated":"2024-04-19T09:01:30Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the nameSound of a person. By default, when giving orders, the units are addressed by their number.\nWhen nameSound is set, it will be used instead to address the unit. For example instead of \"Two, hold fire!\", one can have \"Miller, hold fire!\".\n\n> [!NOTE]\n> See Arma 3: CfgIdentities#NameSounds for common values.\n>\n> Note that any word from `configFile >> \"RadioProtocolENG\" >> \"Words\"` is accepted (e.g `\"veh_infantry_Sniper_s\"`).","syntaxes":[{"syntax":"person setNameSound name","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nunit1 setNameSound \"dixon\";\n```","code":["unit1 setNameSound \"dixon\";"]},{"text":"```sqf\nunit1 setNameSound \"\"; // will reset to default behaviour\n```","code":["unit1 setNameSound \"\"; // will reset to default behaviour"]},{"text":"```sqf\n_name = \"Masood\";\nunit1 setNameSound _name;\nunit1 setName _name;\n```","code":["_name = \"Masood\";\nunit1 setNameSound _name;\nunit1 setName _name;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nameSound","name","setName","setIdentity"],"notes":[{"user":"Lou Montana","date":"2013-12-22T19:08:00Z","text":"setting an incorrect value like \"0\" or \"randomString\" will remove the callsign (\" */* 2, */* fall back\")"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setObjectArguments","operator":null,"title":"setObjectArguments","type":"command","url":"https://community.bistudio.com/wiki/setObjectArguments","revid":363285,"updated":"2024-03-26T10:51:56Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set object arguments in mission editor.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setObjectArguments [object,[name1,value1,...]]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[object,[name1,value1,...]]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[object,[name1,value1,...]]: Array"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object,[name1,value1,...]]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setObjectMaterial","operator":null,"title":"setObjectMaterial","type":"command","url":"https://community.bistudio.com/wiki/setObjectMaterial","revid":370026,"updated":"2024-10-27T23:18:53Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets material of object selection. The selection number is defined through the hiddenselection[] = {} array in the vehicle's config (starting with 0).","syntaxes":[{"syntax":"obj setObjectMaterial [selectionNumber, material]","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"selectionNumber","type":null,"optional":false,"default":null,"description":"Number or String (since Arma 3 v2.10).","types":["Number","String"],"since":null,"text":"selectionNumber: Number or String (since Arma 3 v2.10)."},{"name":"material","type":"String","optional":false,"default":null,"description":"material path. Since Arma 3 v2.20 using **\"#reset\"** would reset to default material.","types":["String"],"since":null,"text":"material: String - material path. Since Arma 3 v2.20 using **\"#reset\"** would reset to default material."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"[selectionNumber, material]","types":["Array"]}}],"examples":[{"text":"```sqf\ncar setObjectMaterial [0,\"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\ncar setObjectMaterial [1,\"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\n```","code":["car setObjectMaterial [0,\"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\ncar setObjectMaterial [1,\"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectMaterials","setObjectTextureGlobal","getObjectTextures","setObjectTexture","setObjectMaterialGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setObjectMaterialGlobal","operator":null,"title":"setObjectMaterialGlobal","type":"command","url":"https://community.bistudio.com/wiki/setObjectMaterialGlobal","revid":370027,"updated":"2024-10-27T23:19:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Set the material of the given selection on all computers in a network session.","syntaxes":[{"syntax":"obj setObjectMaterialGlobal [selection, material]","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"selection","type":"Number or Arma 3 v2.10 String","optional":false,"default":null,"description":null,"types":["Number","String"],"since":null,"text":"selection: Number or Arma 3 v2.10 String"},{"name":"material","type":"String","optional":false,"default":null,"description":"material path. Since Arma 3 v2.20 using **\"#reset\"** would reset to default material.","types":["String"],"since":null,"text":"material: String - material path. Since Arma 3 v2.20 using **\"#reset\"** would reset to default material."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"[selection, material]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setObjectMaterialGlobal [0, \"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];\n```","code":["player setObjectMaterialGlobal [0, \"A3\\Structures_F\\Data\\Windows\\window_set.rvmat\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setObjectTexture","setObjectTextureGlobal","getObjectTextures","setObjectMaterial","getObjectMaterials"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setObjectProxy","operator":null,"title":"setObjectProxy","type":"command","url":"https://community.bistudio.com/wiki/setObjectProxy","revid":353301,"updated":"2024-03-15T17:11:43Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the proxy object associated with the given editor object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setObjectProxy [object, proxy]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"object: String"},{"name":"proxy","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"proxy: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object, proxy]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map setObjectProxy [\"_group_0\", vehicle (leader _group)];\n```","code":["_map setObjectProxy [\"_group_0\", vehicle (leader _group)];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectProxy"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setObjectScale","operator":null,"title":"setObjectScale","type":"command","url":"https://community.bistudio.com/wiki/setObjectScale","revid":364325,"updated":"2024-05-06T09:38:47Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Scales an attached object or a Simple Object's model - see #Example 3 for various configurations' examples.","syntaxes":[{"syntax":"object setObjectScale scale","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"must be either an attached object or Simple Object - see #Example 3","types":["Object"],"since":null,"text":"object: Object - must be either an attached object or Simple Object - see #Example 3"},{"name":"scale","type":"Number","optional":false,"default":null,"description":"in range 0.0001..65504, relative to the object model's normal scale","types":["Number"],"since":null,"text":"scale: Number - in range 0.0001..65504, relative to the object model's normal scale"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"scale","types":["Number"]}}],"examples":[{"text":"```sqf\n_vehicle attachTo [player, [0,0,0]];\n_vehicle setObjectScale 0.1;\n```","code":["_vehicle attachTo [player, [0,0,0]];\n_vehicle setObjectScale 0.1;"]},{"text":"```sqf\n// select an object in Eden Editor and execute the following code in the Debug Console. When moving the object, the effect is reset!\nprivate _object = get3DENSelected \"Object\" select 0;\n_object setObjectScale 0.1;\n```","code":["// select an object in Eden Editor and execute the following code in the Debug Console. When moving the object, the effect is reset!\nprivate _object = get3DENSelected \"Object\" select 0;\n_object setObjectScale 0.1;"]},{"text":"```sqf\n// multiple MP-compatible options\n\n// global simple object\nprivate _globalSimpleObject = createSimpleObject [\"C_Offroad_01_F\", getPosASL player, false];\n_globalSimpleObject setObjectScale 0.1; // once is enough as long as it is not moved\n\n// local normal object\nprivate _localNormalObject = \"C_Offroad_01_F\" createVehicleLocal getPosATL player;\n_localNormalObject attachTo [player, [0, 2, 1.5]]; // normal object must be attached\n_localNormalObject setObjectScale 0.1; // once is enough as long as it is not moved\n\n// local simple object\nprivate _localSimpleObject = createSimpleObject [\"C_Offroad_01_F\", getPosASL player, true];\n_localSimpleObject setObjectScale 0.1; // once is enough as long as it is not moved\n```","code":["// multiple MP-compatible options\n\n// global simple object\nprivate _globalSimpleObject = createSimpleObject [\"C_Offroad_01_F\", getPosASL player, false];\n_globalSimpleObject setObjectScale 0.1; // once is enough as long as it is not moved\n\n// local normal object\nprivate _localNormalObject = \"C_Offroad_01_F\" createVehicleLocal getPosATL player;\n_localNormalObject attachTo [player, [0, 2, 1.5]]; // normal object must be attached\n_localNormalObject setObjectScale 0.1; // once is enough as long as it is not moved\n\n// local simple object\nprivate _localSimpleObject = createSimpleObject [\"C_Offroad_01_F\", getPosASL player, true];\n_localSimpleObject setObjectScale 0.1; // once is enough as long as it is not moved"]},{"text":"```sqf\n// a not-so-great EachFrame workaround for a non-attached object\n\n// a normal object that is not attached must be scaled each frame\n// make sure the object is LOCAL in order to not saturate the network!\nprivate _localNormalObject = \"C_Offroad_01_F\" createVehicleLocal getPosATL player;\n// the object is not attached to anything\naddMissionEventHandler [\n    \"EachFrame\",\n    { _thisArgs params [\"_obj\", \"_scale\"]; _obj setObjectScale _scale; },\n    [_localNormalObject, 0.1]\n];\n```","code":["// a not-so-great EachFrame workaround for a non-attached object\n\n// a normal object that is not attached must be scaled each frame\n// make sure the object is LOCAL in order to not saturate the network!\nprivate _localNormalObject = \"C_Offroad_01_F\" createVehicleLocal getPosATL player;\n// the object is not attached to anything\naddMissionEventHandler [\n\t\"EachFrame\",\n\t{ _thisArgs params [\"_obj\", \"_scale\"]; _obj setObjectScale _scale; },\n\t[_localNormalObject, 0.1]\n];"]},{"text":"```sqf\n// only do the following in single player;\n// NEVER do such EachFrame in multiplayer!!\n// the performance will be terrible, the network will be saturated, the scaling may desync and not be perfect\nprivate _globalNormalObject = \"C_Offroad_01_F\" createVehicle getPosATL player;\naddMissionEventHandler [\n    \"EachFrame\",\n    { _thisArgs params [\"_obj\", \"_scale\"]; _obj setObjectScale _scale; },\n    [_globalNormalObject, 0.1]\n];\n```","code":["// only do the following in single player;\n// NEVER do such EachFrame in multiplayer!!\n// the performance will be terrible, the network will be saturated, the scaling may desync and not be perfect\nprivate _globalNormalObject = \"C_Offroad_01_F\" createVehicle getPosATL player;\naddMissionEventHandler [\n\t\"EachFrame\",\n\t{ _thisArgs params [\"_obj\", \"_scale\"]; _obj setObjectScale _scale; },\n\t[_globalNormalObject, 0.1]\n];"]}],"multiplayer":null,"problems":"The Arma 3 LOD limits still apply, meaning walkable surfaces can only be (~70?)m in size, and collision in general will only work up to (?)m from object center.\nThis command works on all objects in Eden Editor or scenario preview, but it will not save and will reset when objects get moved. Eden Editor support is only intended for artists.\n\n> [!NOTE]\n> Setting the scale of non-simple objects, such as vehicles with players/AI in them, static objects (`simulation = \"house\"` in config), etc. might be possible,\n> but not officially supported. You may encounter issues.\n\n> [!IMPORTANT]\n> Changing the direction of the object (e.g. using setDir, setVectorDir, etc.) will reset the object back to its original size (probably because the engine normalises the directions,\n> thus the scale in the transformation matrix becomes 1), so those commands should be run **before** resizing the object.","aliases":[],"see_also":["getObjectScale","createVehicleLocal","createSimpleObject","BIS_fnc_createSimpleObject","Multiplayer Scripting"],"notes":[{"user":"P1ker1","date":"2022-01-04T22:17:33Z","text":"Note that\n\n```sqf\n_obj setObjectScale 2;\n```\n\ndoubles the scale factor of an object, not the volume. In the case of a cube this would be the length of an edge.\nIf you want to multiply the volume, raise the *scale* to the power of 1/3.\n\n```sqf\n// Example with 1x1x1 m^3 helper objects\n// vectorAdds elevate the cubes so they touch the ground after scaling.\n_cube1 = createSimpleObject [\"Land_VR_Shape_01_cube_1m_F\", getPosASL player vectorAdd [1,3,0.5]];\n_cube2 = createSimpleObject [\"Land_VR_Shape_01_cube_1m_F\", getPosASL player vectorAdd [3,1,0.5]];\n_cube3 = createSimpleObject [\"Land_VR_Shape_01_cube_1m_F\", getPosASL player vectorAdd [1.35,1.35,0.13]];\n\n// Double the side length. V=2^3=8\n_cube1 setObjectScale 2;\n\n// Octuple(8x) the volume.    V=(8^(1/3))^3=8\n_cube2 setObjectScale 8^(1/3);\n\n// Double the volume.        V=(2^(1/3))^3=2\n_cube3 setObjectScale 2^(1/3);\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.02","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setObjectTexture","operator":null,"title":"setObjectTexture","type":"command","url":"https://community.bistudio.com/wiki/setObjectTexture","revid":370028,"updated":"2024-10-27T23:20:14Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Applies given texture to object's selection. See also Procedural Textures and Retexturing with setObjectTexture.\n\n> [!NOTE]\n> - Not all objects can be textured this way. To find out, run getObjectTextures command on an object. Empty array `[]` usually indicates it cannot be textured.\n> - All textures must have a resolution of 2a × 2b (e.g. 16×16, 16×32, 64×256, 512×512, ...). The largest texture size supported by the RV engine is 4096×4096.\n> - Supported formats: .pac, .paa, .jpg, .jpeg, .ogg, .ogv","syntaxes":[{"syntax":"object setObjectTexture [selection, texture]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selection","type":"Number or Arma 3 v2.10 String","optional":false,"default":null,"description":"index of the selection. It is defined in the hiddenSelections array in the vehicle's config (starting with 0). If a string is given, it referes to a hiddenSelection name or clan selection instead of an index.","types":["Number","String"],"since":null,"text":"selection: Number or Arma 3 v2.10 String - index of the selection. It is defined in the hiddenSelections array in the vehicle's config (starting with 0). If a string is given, it referes to a hiddenSelection name or clan selection instead of an index."},{"name":"texture","type":"String","optional":false,"default":null,"description":"path to texture. Since Arma 3 v2.20 using **\"#reset\"** would reset to default texture.","types":["String"],"since":null,"text":"texture: String - path to texture. Since Arma 3 v2.20 using **\"#reset\"** would reset to default texture."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selection, texture]","types":["Array"]}}],"examples":[{"text":"```sqf\n_objectname setObjectTexture [0, \"\\pboname\\texture.paa\"];\n_objectname setObjectTexture [1, \"\\pboname\\texture2.paa\"];\n```","code":["_objectname setObjectTexture [0, \"\\pboname\\texture.paa\"];\n_objectname setObjectTexture [1, \"\\pboname\\texture2.paa\"];"]},{"text":"```sqf\n_obj setObjectTexture [0, \"#(rgb,8,8,3)color(1,0,0,1)\"];\n```","code":["_obj setObjectTexture [0, \"#(rgb,8,8,3)color(1,0,0,1)\"];"]},{"text":"```sqf\n_obj setObjectTexture [0, \"#(argb,512,512,1)r2t(rendersurface,1.333)\"];\n```","code":["_obj setObjectTexture [0, \"#(argb,512,512,1)r2t(rendersurface,1.333)\"];"]},{"text":"Disable randomization before applying a texture to a vehicle in the Editor (if it is a vehicle that supports randomization):\n\n```sqf\nthis setVariable [\"BIS_enableRandomization\", false];\nthis setObjectTexture [0,\"#(rgb,8,8,3)color(1,0,0,1)\"];\n```","code":["this setVariable [\"BIS_enableRandomization\", false];\nthis setObjectTexture [0,\"#(rgb,8,8,3)color(1,0,0,1)\"];"]},{"text":"The `\"clan\"` selection can be used to apply a texture to the areas that usually display the squad.xml logo:\n\n```sqf\nMyVehicle setObjectTexture [\"clan\", \"\\a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\"];\n```","code":["MyVehicle setObjectTexture [\"clan\", \"\\a3\\missions_f_epa\\data\\img\\orbat\\b_111_texture_ca.paa\"];"]}],"multiplayer":"See setObjectTextureGlobal.","problems":null,"aliases":[],"see_also":["getObjectTextures","setObjectTextureGlobal","setObjectMaterial","getObjectMaterials","setObjectMaterialGlobal","forceFlagTexture"],"notes":[{"user":"Benargee","date":"2014-08-25T22:27:00Z","text":"Also works with absolute path and .jpg files.\n\n```sqf\n_obj setObjectTexture [0, \"C:\\Folder\\Folder\\Texture.paa\"];\n_obj setObjectTexture [0, \"C:\\Folder\\Folder\\Texture.jpg\"];\n```\n\nTexture can also be blank:\n\n```sqf\n_obj setObjectTexture [2,\"\"];\n```\n\nThis will make the texture selection invisible on certain units without an error message. In some cases this is a desirable effect"},{"user":"Longbow","date":"2015-03-18T03:09:00Z","text":"It is also possible to apply texture to unit's backpack, as it also has hidden selection (unfortunately does not work for vests)\n\n```sqf\nbackpackContainer player setObjectTexture [0,\"#(argb,8,8,3)color(0,0,0,1)\"]\n```\n\nAlso keep in mind that player's custom texture is being reset when you open BIS Arsenal (even without changing any gear)"},{"user":"Moerderhoschi","date":"2015-05-13T14:37:00Z","text":"You can also use the game's internal skins: [List of MH9 Skins](http://forums.bistudio.com/showthread.php?169734-paint-MH-9-different-colour)\n\n```sqf\n_obj setObjectTexture [0, \"\\a3\\air_f\\heli_light_01\\data\\skins\\heli_light_01_ext_digital_co.paa\"];\n```"},{"user":"Killzone_Kid","date":"2016-10-24T12:09:00Z","text":"Sometimes it could be necessary to set default material on an object for the texture to take effect:\n\n```sqf\n_block = createVehicle [\"Land_VR_Block_02_F\", player getPos [20, getDir player], [], 0, \"CAN_COLLIDE\"];\n_block setObjectMaterial [0, \"\\a3\\data_f\\default.rvmat\"];\n_block setObjectTexture [0, \"#(rgb,8,8,3)color(1,0,0,1)\"];\n```\n\nCourtesy of **Larrow**"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setObjectTextureGlobal","operator":null,"title":"setObjectTextureGlobal","type":"command","url":"https://community.bistudio.com/wiki/setObjectTextureGlobal","revid":370029,"updated":"2024-10-27T23:21:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.06"}],"since":{"game":"arma3","name":"Arma 3","version":"1.06"},"arma3_since":"1.06","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Set the texture of the given selection on all computers in a network session.\n\n> [!NOTE]\n> - Not all objects can be textured this way. To find out, run getObjectTextures command on an object. Empty array `[]` usually indicates it cannot be textured.\n> - All textures must have a resolution of 2a × 2b (e.g. 16×16, 16×32, 64×256, 512×512, ...). The largest texture size supported by the RV engine is 4096×4096.\n> - Supported formats: .pac, .paa, .jpg, .jpeg, .ogg, .ogv","syntaxes":[{"syntax":"object setObjectTextureGlobal [selection, texture]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"selection","type":"Number or Arma 3 v2.10 String","optional":false,"default":null,"description":"index of the selection. It is defined in the hiddenSelections array in the vehicle's config (starting with 0). If a string is given, it referes to a hiddenSelection name or clan selection instead of an index.","types":["Number","String"],"since":null,"text":"selection: Number or Arma 3 v2.10 String - index of the selection. It is defined in the hiddenSelections array in the vehicle's config (starting with 0). If a string is given, it referes to a hiddenSelection name or clan selection instead of an index."},{"name":"texture","type":"String","optional":false,"default":null,"description":"path to texture. Since Arma 3 v2.20 using **\"#reset\"** would reset to default texture.","types":["String"],"since":null,"text":"texture: String - path to texture. Since Arma 3 v2.20 using **\"#reset\"** would reset to default texture."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[selection, texture]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setObjectTextureGlobal [0, \"\\MyAddon\\blue.paa\"];\n```","code":["player setObjectTextureGlobal [0, \"\\MyAddon\\blue.paa\"];"]},{"text":"```sqf\n// Set up a persistent texture keeper\nplayer addEventHandler [\"Take\", {\n    (getObjectTextures player + [uniformContainer player getVariable \"texture\"])\n    params [\"_texUniform\", \"_texInsignia\", \"_texCustom\"];\n    if (isNil \"_texCustom\") exitWith {};\n    if (_texUniform == _texCustom) exitWith {};\n    player setObjectTextureGlobal [0, _texCustom];\n    false\n}];\n\n// Example: make current uniform persistently blue\n\nprivate _texture = \"#(rgb,8,8,3)color(0,0,1,1)\"; // blue texture\nplayer setObjectTextureGlobal [0, _texture]; // set it on player\nuniformContainer player setVariable [\"texture\", _texture, true]; // store it on uniform\n```","code":["// Set up a persistent texture keeper\nplayer addEventHandler [\"Take\", {\n\t(getObjectTextures player + [uniformContainer player getVariable \"texture\"])\n\tparams [\"_texUniform\", \"_texInsignia\", \"_texCustom\"];\n\tif (isNil \"_texCustom\") exitWith {};\n\tif (_texUniform == _texCustom) exitWith {};\n\tplayer setObjectTextureGlobal [0, _texCustom];\n\tfalse\n}];\n\n// Example: make current uniform persistently blue\n\nprivate _texture = \"#(rgb,8,8,3)color(0,0,1,1)\"; // blue texture\nplayer setObjectTextureGlobal [0, _texture]; // set it on player\nuniformContainer player setVariable [\"texture\", _texture, true]; // store it on uniform"]}],"multiplayer":"The effect is JIP compatible.","problems":"If executed from an object's init field (which should not be done anyway for Global Effect commands), execution may happen too early and fail to broadcast over the network and to be JIP compatible.","aliases":[],"see_also":["setObjectTexture","getObjectTextures","setObjectMaterial","forceFlagTexture"],"notes":[{"user":"Killzone_Kid","date":"2016-10-24T12:13:00Z","text":"Sometimes it could be necessary to set default material on an object for the texture to take effect:\n\n```sqf\nprivate _block = createVehicle [\"Land_VR_Block_02_F\", player getPos [20, getDir player], [], 0, \"CAN_COLLIDE\"];\n_block setObjectMaterialGlobal [0, \"\\a3\\data_f\\default.rvmat\"];\n_block setObjectTextureGlobal [0, \"#(rgb,8,8,3)color(1,0,0,1)\"];\n```\n\nCourtesy of **Larrow**"},{"user":"whiztler","date":"2022-09-13T21:04:01Z","text":"Following Killzone_Kid's note, a sleep after the  setObjectMaterialGlobal and before the setObjectTextureGlobal command is sometimes needed to ensure the texture effect is  carried out correctly.\n\n```sqf\nprivate _block = createVehicle [\"Land_VR_Block_02_F\", player getPos [20, getDir player], [], 0, \"CAN_COLLIDE\"];\n_block setObjectMaterialGlobal [0, \"\\a3\\data_f\\default.rvmat\"];\nsleep 0.01;\n_block setObjectTextureGlobal [0, \"#(rgb,8,8,3)color(1,0,0,1)\"];\n```\n\nNote that you need to run above code in a scheduled environment."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.06","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setObjectViewDistance","operator":null,"title":"setObjectViewDistance","type":"command","url":"https://community.bistudio.com/wiki/setObjectViewDistance","revid":309992,"updated":"2022-05-05T12:19:42Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the rendering distance of objects and shadows.","syntaxes":[{"syntax":"setObjectViewDistance objectDistance","since":null,"effect":null,"exec":null,"params":[{"name":"objectDistance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"objectDistance: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"objectDistance","types":["Number"]}},{"syntax":"setObjectViewDistance [objectDistance, shadowDistance]","since":null,"effect":null,"exec":null,"params":[{"name":"objectDistance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"objectDistance: Number"},{"name":"shadowDistance","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"shadowDistance: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[objectDistance, shadowDistance]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetObjectViewDistance 2000;\n```","code":["setObjectViewDistance 2000;"]},{"text":"```sqf\nsetObjectViewDistance [2000, 800];\n```","code":["setObjectViewDistance [2000, 800];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getObjectViewDistance","setViewDistance","viewDistance","setDetailMapBlendPars","setTerrainGrid"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setOpticsMode","operator":null,"title":"setOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/setOpticsMode","revid":377651,"updated":"2026-01-02T09:01:57Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the optic mode of the current weapon to the given class name or the index.","syntaxes":[{"syntax":"unit setOpticsMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mode","type":"String, Number or Array:","optional":false,"default":null,"description":"String, Number or Array:\n- String - class name defined in the optic's `OpticsModes` config class\n- Number - 0-based index of the optic mode with 0 being the default optic mode\n- Array with [slotIndex, opticsModeIndexOrClassName]\n  - slotIndex: Number, can be one of:\n    - 0 - Current weapon\n    - 1 - Primary weapon\n    - 2 - Secondary weapon\n    - 3 - Handgun\n  - opticsModeIndexOrClassName: String or Number as above","types":["String","Number","Array"],"since":null,"text":"mode: String, Number or Array:\n- String - class name defined in the optic's `OpticsModes` config class\n- Number - 0-based index of the optic mode with 0 being the default optic mode\n- Array with [slotIndex, opticsModeIndexOrClassName]\n  - slotIndex: Number, can be one of:\n    - 0 - Current weapon\n    - 1 - Primary weapon\n    - 2 - Secondary weapon\n    - 3 - Handgun\n  - opticsModeIndexOrClassName: String or Number as above"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mode","types":["String","Number","Array"]}}],"examples":[{"text":"```sqf\nplayer setOpticsMode \"Hamr2Scope\"; // Default optic mode for optic_Hamr\n```","code":["player setOpticsMode \"Hamr2Scope\"; // Default optic mode for optic_Hamr"]},{"text":"```sqf\nplayer setOpticsMode 0;\n```","code":["player setOpticsMode 0;"]},{"text":"```sqf\nplayer setOpticsMode [1, 0]; // reset the optics mode of the player's primary weapon to the default\n```","code":["player setOpticsMode [1, 0]; // reset the optics mode of the player's primary weapon to the default"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"setOvercast","operator":null,"title":"setOvercast","type":"command","url":"https://community.bistudio.com/wiki/setOvercast","revid":376723,"updated":"2025-11-12T14:34:03Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set overcast to given value smoothly during given time (in seconds). Zero time means immediate change.\nAn overcast setting of zero means clear (sunny) weather, and one means storms and rain are very likely. Higher overcast values also result in higher wind speeds.","syntaxes":[{"syntax":"time setOvercast overcast","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"in seconds","types":["Number"],"since":null,"text":"time: Number - in seconds"},{"name":"overcast","type":"Number","optional":false,"default":null,"description":"in range 0..1","types":["Number"],"since":null,"text":"overcast: Number - in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"overcast","types":["Number"]}}],"examples":[{"text":"```sqf\n60 setOvercast 0.5;\n```","code":["60 setOvercast 0.5;"]}],"multiplayer":"**Pre Arma 3:** Each client and the server can have differing overcast values. \n\n> [!NOTE]\n> **Arma 3:** In Arma 3 weather values are periodically synchronised with the server.","problems":null,"aliases":[],"see_also":["overcast","nextWeatherChange","simulSetHumidity"],"notes":[{"user":"Hardrock","date":"2006-08-04T14:00:00Z","text":"*Notes from before the conversion:*\n\nUse setRain if you want to make sure it rains."},{"user":"Ceeeb","date":"2007-04-20T04:24:00Z","text":"Only one script command induced weather change (either setOvercast or setFog) can be happening at a time. Starting a new weather change will immediately halt the current weather change. SetRain changes are independent and can occur simultaneously to a weather change."},{"user":"DnA","date":"2013-08-14T11:22:00Z","text":"Arma 3's volumetric clouds cannot be instantly changed (it would take up to a few seconds to do a full recompute). Therefore, *0 setOvercast 0* will not have the desired effect. You can use skipTime to get to the desired cloud coverage.\n\nNOTE: To get instant, seamless overcast change to overcast 1 advance the time 24 hours with skipTime while setting overcast transition time to 86400 seconds (24 hours) - Killzone_Kid (12:08, 15 August 2013)\n\n```sqf\n86400 setOvercast 1;\nskipTime 24;\n\n// to remain on the same date:\nskipTime -24;\n86400 setOvercast 1;\nskipTime 24;\n```"},{"user":"Killzone_Kid","date":"2013-10-28T11:06:00Z","text":"With removal of simulSetHumidity, in order to add instant cloud cover, execute simulWeatherSync with delay (for now):\n\n```sqf\nskipTime -24;\n86400 setOvercast 1;\nskipTime 24;\n0 spawn {\n    sleep 0.1;\n    simulWeatherSync;\n};\n```\n\nThere is slight freeze with simul command."},{"user":"Adanteh","date":"2015-08-21T19:58:00Z","text":"Delay in Arma 3 doesn't work for quick changes. Using 120 setOvercast 1 only reaches full overcast after about 50 minutes.\nUsing setTimeMultiplier does speed up the overcast, but it doesn't render any clouds.\nYou will need to skipTime or forceWeatherChange to render clouds if you want it to happen within the hour."},{"user":"AgentRev","date":"2016-05-05T00:41:00Z","text":"Actual transition time is inversely proportional to the timeMultiplier. For example, a time of 7200 (2 hours) and a timeMultiplier of 2 will result in a real-life transition time of 7200 / 2 = 3600 (1 hour).\n\nIn case of overcast, a timeMultiplier > 1 will cause gradual desyncing of the cloud cover with the overcast value, so it is advised that you multiply the transition time by the multiplier, i.e. :\n\n```sqf\n(7200 * timeMultiplier) setOvercast 1\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setOwner","operator":null,"title":"setOwner","type":"command","url":"https://community.bistudio.com/wiki/setOwner","revid":351991,"updated":"2024-02-01T23:23:57Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":true},"exec":null,"description":"From server machine, change the ownership of an object to a given client. Using command in an unintended way will log a message to .rpt file. To transfer ownership of all AI units in a group properly, use setGroupOwner instead.","syntaxes":[{"syntax":"object setOwner clientID","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to transfer","types":["Object"],"since":null,"text":"object: Object - object to transfer"},{"name":"clientID","type":"Number","optional":false,"default":null,"description":"the machine network ID of the new owner.","types":["Number"],"since":null,"text":"clientID: Number - the machine network ID of the new owner."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if ownership was successfully transferred, otherwise false","text":"Boolean - returns true if ownership was successfully transferred, otherwise false"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"clientID","types":["Number"]}}],"examples":[{"text":"```sqf\n_someObject setOwner 12;\n```","code":["_someObject setOwner 12;"]},{"text":"```sqf\n_someObject setOwner (owner _playerObject);\n```","code":["_someObject setOwner (owner _playerObject);"]}],"multiplayer":null,"problems":"> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.40, this command should not be used to transfer ownership of units with AI with the exception of agents.\n\n> [!IMPORTANT]\n> **Prior to Arma 3 v1.40** it was not possible to transfer the ownership from a client back to the server.","aliases":[],"see_also":["owner","setGroupOwner","groupOwner","didJIPOwner"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setOxygenRemaining","operator":null,"title":"setOxygenRemaining","type":"command","url":"https://community.bistudio.com/wiki/setOxygenRemaining","revid":377982,"updated":"2026-01-20T14:37:17Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets oxygen remaining. It has no effect when soldier is not diving.","syntaxes":[{"syntax":"unit setOxygenRemaining value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"value","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nif (!isAbleToBreathe player) then\n{\n    player setOxygenRemaining 0; // drowns player\n};\n```","code":["if (!isAbleToBreathe player) then\n{\n\tplayer setOxygenRemaining 0; // drowns player\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isAbleToBreathe","getOxygenRemaining"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setParticleCircle","operator":null,"title":"setParticleCircle","type":"command","url":"https://community.bistudio.com/wiki/setParticleCircle","revid":378393,"updated":"2026-04-04T07:54:48Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Updates particle source, creates particles in circle with given radius. Velocity is transformed and added to total velocity. The random particle positioning is calculated in relation to the nearest surface. Since Arma 3 2.22, this could be overridden (will also override onSurface = true).","syntaxes":[{"syntax":"particleSource setParticleCircle [circleRadius, circleVelocity, ignoreSurfaces]","since":null,"effect":null,"exec":null,"params":[{"name":"particleSource","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"particleSource: Object"},{"name":"circleRadius","type":"Number","optional":false,"default":null,"description":"the radius (x,y plain) in which particles are generated","types":["Number"],"since":null,"text":"circleRadius: Number - the radius (x,y plain) in which particles are generated"},{"name":"circleVelocity","type":"Vector3D","optional":false,"default":null,"description":"direction and speed of particles movement","types":["Vector3D"],"since":null,"text":"circleVelocity: Vector3D - direction and speed of particles movement"},{"name":"ignoreSurfaces","type":"Boolean","optional":true,"default":null,"description":"true to calculate particle position relative to the source position. Default: false","types":["Boolean"],"since":"arma3 2.22","text":"ignoreSurfaces: Boolean - (Optional) true to calculate particle position relative to the source position. Default: false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"particleSource","types":["Object"]},"right":{"text":"[circleRadius, circleVelocity, ignoreSurfaces]","types":["Array"]}}],"examples":[{"text":"```sqf\n_myParticleSource setParticleCircle [3, [0,0,5]];\n```","code":["_myParticleSource setParticleCircle [3, [0,0,5]];"]},{"text":"```sqf\n_myParticleSource setParticleCircle [3, [0,0,5], true];\n```","code":["_myParticleSource setParticleCircle [3, [0,0,5], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setParticleParams","setParticleRandom","ParticleTemplates","setParticleClass","particlesQuality","setParticleFire"],"notes":[],"categories":[]},{"name":"setParticleClass","operator":null,"title":"setParticleClass","type":"command","url":"https://community.bistudio.com/wiki/setParticleClass","revid":369209,"updated":"2024-09-03T10:34:52Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets particle source parameters using existing particle config from `CfgCloudlets` class. Use setParticleParams subsequently if you need to overwrite some values.\n\n> [!IMPORTANT]\n> If `CfgCloudlets` class contains simple expressions, they will not be evaluated by this command, which might make the whole class unusable in script.","syntaxes":[{"syntax":"source setParticleClass className","since":null,"effect":null,"exec":null,"params":[{"name":"source","type":"Object","optional":false,"default":null,"description":"particle source","types":["Object"],"since":null,"text":"source: Object - particle source"},{"name":"className","type":"String","optional":false,"default":null,"description":"CfgCloudlets class","types":["String"],"since":null,"text":"className: String - CfgCloudlets class"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"source","types":["Object"]},"right":{"text":"className","types":["String"]}}],"examples":[{"text":"```sqf\n_source01 = \"#particlesource\" createVehicleLocal _pos01;\n_source01 setParticleClass \"ObjectDestructionFire1Smallx\";\n_source01 attachTo [_object,[0,0,0]];\n```","code":["_source01 = \"#particlesource\" createVehicleLocal _pos01;\n_source01 setParticleClass \"ObjectDestructionFire1Smallx\";\n_source01 attachTo [_object,[0,0,0]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Particle Effects","ParticleArray","setParticleParams","setParticleRandom","setParticleCircle","setParticleFire","setDropInterval","drop"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Particles","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setParticleFire","operator":null,"title":"setParticleFire","type":"command","url":"https://community.bistudio.com/wiki/setParticleFire","revid":330030,"updated":"2022-08-15T14:55:31Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set fire parameters to particle effect.\n\nNote: You need to create emitter at first. Basic parameters of particle effect must be defined too. You can use script commands setParticleClass or setParticleParams to do so (see example). Correspondence between CfgCloudlets class param names and command array of params:\n\n```sqf\nparticleSource setParticleFire\n[\n    coreIntensity,\n    coreDistance,\n    damageTime\n];\n```","syntaxes":[{"syntax":"source setParticleFire [coreIntensity, coreDistance, damageTime]","since":null,"effect":null,"exec":null,"params":[{"name":"source","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"source: Object"},{"name":"coreIntensity","type":"Number","optional":false,"default":null,"description":"damage in the center of fire","types":["Number"],"since":null,"text":"coreIntensity: Number - damage in the center of fire"},{"name":"coreDistance","type":"Number","optional":false,"default":null,"description":"how far can unit get damage","types":["Number"],"since":null,"text":"coreDistance: Number - how far can unit get damage"},{"name":"damageTime","type":"Number","optional":false,"default":null,"description":"how often is unit getting damage","types":["Number"],"since":null,"text":"damageTime: Number - how often is unit getting damage"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"source","types":["Object"]},"right":{"text":"[coreIntensity, coreDistance, damageTime]","types":["Array"]}}],"examples":[{"text":"```sqf\n_emitter = \"#particlesource\" createVehicleLocal (getPos player);\n_emitter setParticleClass \"MediumSmoke\";\n_emitter setParticleFire [0.3,1.0,0.1];\n```","code":["_emitter = \"#particlesource\" createVehicleLocal (getPos player);\n_emitter setParticleClass \"MediumSmoke\";\n_emitter setParticleFire [0.3,1.0,0.1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Particle Effects","ParticleArray","setParticleParams","setParticleRandom","setParticleCircle","setDropInterval","drop","setParticleClass"],"notes":[{"user":"AgentRev","date":"2018-04-09T20:44:00Z","text":"Using this command on a dedicated server or headless client seems to have no effect on local AI units, they will walk thru the fire unscathed."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Particles","Introduced with Arma 3 version 1.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setParticleParams","operator":null,"title":"setParticleParams","type":"command","url":"https://community.bistudio.com/wiki/setParticleParams","revid":377766,"updated":"2026-01-03T01:02:12Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set parameters to particle source. Array is in format ParticleArray.\n\nSince Arma 3 version 1.11.114706 you can use this command to overwrite many values set by setParticleClass, particularity those defined in ParticleArray. Correspondence between CfgCloudlets class param names and command array of params:\n\n```sqf\nparticleSource setParticleParams\n[\n    /*\n        String or Array - If string then the name of the particleShape. And following default values are used:\n            particleFSNtieth = 1\n            particleFSIndex = 0\n            particleFSFrameCount = 1\n            particleFSLoop = 1\n    */\n    [\n        particleShape,            /* String */\n        particleFSNtieth,        /* Number */\n        particleFSIndex,        /* Number */\n        particleFSFrameCount,    /* Number */\n        particleFSLoop            /* Optional - Number. Default: 1 */\n    ],\n    animationName,                /* String */\n    particleType,                /* String - Enum: Billboard, SpaceObject */\n    timerPeriod,                /* Number */\n    lifeTime,                    /* Number */\n    pos3D,                        /* 3D Array of numbers as relative position to particleSource or (if object at index 18 is set) object. \n                                    Or (if object at index 18 is set) String as memoryPoint of object. */\n    moveVelocity,                /* 3D Array of numbers. */\n    rotationVelocity,            /* Number */\n    weight,                        /* Number */\n    volume,                        /* Number */\n    rubbing,                    /* Number */\n    sizeOverLifetime,            /* Array of Numbers */\n    color,                        /* Array of Array of RGBA Numbers */\n    animationSpeed,                /* Array of Number */\n    randomDirectionPeriod,        /* Number */\n    randomDirectionIntensity,    /* Number */\n    onTimerScript,                /* String */\n    beforeDestroyScript,        /* String */\n    obj,                        /* Object */\n    angle,                        /* Optional Number - Default: 0 */\n    onSurface,                    /* Optional Boolean - Default: true */\n    bounceOnSurface,            /* Optional Number - Default: -1 */\n    emissiveColor,                /* Optional Array of Array of RGBA Numbers - Default [0,0,0,0] */\n    vectorDirOrVectorDirAndUp    /* Optional vector dir or [vectorDir, vectorUp]\n        Since Arma 3 v1.92 it is possible to set the initial direction of the SpaceObject\n        Since Arma 3 v2.12 it is possible to use a [vectorDir, vectorUp] array */\n];\n```","syntaxes":[{"syntax":"particleSource setParticleParams array","since":null,"effect":null,"exec":null,"params":[{"name":"particleSource","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"particleSource: Object"},{"name":"array","type":"ParticleArray","optional":false,"default":null,"description":null,"types":["ParticleArray"],"since":null,"text":"array: ParticleArray"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"particleSource","types":["Object"]},"right":{"text":"array","types":["ParticleArray"]}}],"examples":[{"text":"see ParticleArray","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Particle Effects","ParticleArray","setParticleClass","setParticleRandom","setParticleCircle","setParticleFire","setDropInterval","drop"],"notes":[],"categories":[]},{"name":"setParticleRandom","operator":null,"title":"setParticleRandom","type":"command","url":"https://community.bistudio.com/wiki/setParticleRandom","revid":378785,"updated":"2026-06-05T12:18:37Z","groups":["Particles"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets randomization of particle source parameters. Correspondence between CfgCloudlets class param names and command array of params:\n\n```sqf\nparticleSource setParticleRandom\n[\n    lifeTimeVar,\n    positionVar,\n    moveVelocityVar,\n    rotationVelocityVar,\n    sizeVar,\n    colorVar,\n    randomDirectionPeriodVar,\n    randomDirectionIntensityVar,\n    angleVar,\n    bounceOnSurfaceVar\n];\n```","syntaxes":[{"syntax":"particleSource setParticleRandom [lifeTime, position, moveVelocity, rotationVelocity, size, color, directionPeriod, directionIntensity, angle, bounceOnSurface]","since":null,"effect":null,"exec":null,"params":[{"name":"particleSource","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"particleSource: Object"},{"name":"lifeTime","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"lifeTime: Number"},{"name":"position","type":"Array of Number","optional":false,"default":null,"description":"in format [randomX, randomY, randomZ]","types":["Array","Number"],"since":null,"text":"position: Array of Number - in format [randomX, randomY, randomZ]"},{"name":"moveVelocity","type":"Array of Number","optional":false,"default":null,"description":"in format [randomX, randomY, randomZ]","types":["Array","Number"],"since":null,"text":"moveVelocity: Array of Number - in format [randomX, randomY, randomZ]"},{"name":"rotationVelocity","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rotationVelocity: Number"},{"name":"size","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"size: Number"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"},{"name":"directionPeriod","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"directionPeriod: Number"},{"name":"directionIntensity","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"directionIntensity: Number"},{"name":"angle","type":"Number","optional":true,"default":null,"description":null,"types":["Number"],"since":null,"text":"angle: Number - (Optional)"},{"name":"bounceOnSurface","type":"Number","optional":true,"default":null,"description":null,"types":["Number"],"since":"arma3 0.74","text":"bounceOnSurface: Number - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"particleSource","types":["Object"]},"right":{"text":"[lifeTime, position, moveVelocity, rotationVelocity, size, color, directionPeriod, directionIntensity, angle, bounceOnSurface]","types":["Array"]}}],"examples":[{"text":"```sqf\n_particleSource setParticleRandom [0, [0.1, 0.1, 0.1], [0, 0, 0.5], 0, 0.1, [0, 0, 0, 0], 0, 0, 45, 0];\n```","code":["_particleSource setParticleRandom [0, [0.1, 0.1, 0.1], [0, 0, 0.5], 0, 0.1, [0, 0, 0, 0], 0, 0, 45, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ParticleArray","setParticleCircle","setParticleParams","ParticleTemplates","setParticleClass","particlesQuality","setParticleFire"],"notes":[{"user":"DarkDruid","date":"2013-07-03T15:35:00Z","text":"Support of parameter *bounceOnSurface* (Number - 0-1) is in the game since Arma 3 version 0.74. It's variability in speed's loosing in collision with ground. Requires collisions with ground enabled by script command setParticleParams."}],"categories":[]},{"name":"setPhysicsCollisionFlag","operator":null,"title":"setPhysicsCollisionFlag","type":"command","url":"https://community.bistudio.com/wiki/setPhysicsCollisionFlag","revid":373888,"updated":"2025-06-26T10:59:15Z","groups":["PhysX"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets physics collision flags for PhysX and geometry LODs. Roadway LOD interactions remain.\n\nFor example, if collision is disabled for a house, it is now possible to walk through its walls but still possible to walk on its floors.\n\n> [!NOTE]\n> Use the allLODs command to check if an object has a roadway LOD (normally, if an object is intended to be walkable, it does have a roadway LOD).","syntaxes":[{"syntax":"object setPhysicsCollisionFlag value","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"value","type":"Boolean","optional":false,"default":null,"description":"true to enable collision, false to disable it","types":["Boolean"],"since":null,"text":"value: Boolean - true to enable collision, false to disable it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"value","types":["Boolean"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideObject","isObjectHidden","getPhysicsCollisionFlag","disableCollisionWith","enableCollisionWith"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Introduced with Arma 3 version 2.18","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setPilotCameraDirection","operator":null,"title":"setPilotCameraDirection","type":"command","url":"https://community.bistudio.com/wiki/setPilotCameraDirection","revid":377431,"updated":"2026-01-02T06:46:14Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets the direction of airplane's or helicopter's pilotCamera.","syntaxes":[{"syntax":"object setPilotCameraDirection vector3D","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"a vehicle equipped with pilot camera","types":["Object"],"since":null,"text":"object: Object - a vehicle equipped with pilot camera"},{"name":"vector3D","type":"Vector3D","optional":false,"default":null,"description":"in model space, relative to the model centre (In a similar fashion to PositionRelative)","types":["Vector3D"],"since":null,"text":"vector3D: Vector3D - in model space, relative to the model centre (In a similar fashion to PositionRelative)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"vector3D","types":["Vector3D"]}}],"examples":[{"text":"```sqf\nvehicle player setPilotCameraDirection [0,1,0] // re-centers the camera\n```","code":["vehicle player setPilotCameraDirection [0,1,0] // re-centers the camera"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraRotation","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"setPilotCameraOpticsMode","operator":null,"title":"setPilotCameraOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/setPilotCameraOpticsMode","revid":347224,"updated":"2023-09-05T17:11:27Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets the optics mode index (zoom) for the pilotCamera","syntaxes":[{"syntax":"object setPilotCameraOpticsMode index","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"index","types":["Number"]}}],"examples":[{"text":"```sqf\nvehicle player setPilotCameraOpticsMode 0\n```","code":["vehicle player setPilotCameraOpticsMode 0"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPilotCameraOpticsMode","hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","setPilotCameraDirection","setPilotCameraRotation","setPilotCameraTarget","getPilotCameraTarget","getTurretOpticsMode","setTurretOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"setPilotCameraRotation","operator":null,"title":"setPilotCameraRotation","type":"command","url":"https://community.bistudio.com/wiki/setPilotCameraRotation","revid":323076,"updated":"2022-06-28T21:43:12Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets rotation (relative to the centered camera position) of the object airplane or helicopter pilotCamera .","syntaxes":[{"syntax":"object setPilotCameraRotation rotation","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"rotation","type":"Array","optional":false,"default":null,"description":"[x,y] - format [yaw (turn), pitch (elevation)]. Values are in radians, positive values are left yaw and down pitch from the center.","types":["Array"],"since":null,"text":"rotation: Array - [x,y] - format [yaw (turn), pitch (elevation)]. Values are in radians, positive values are left yaw and down pitch from the center."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"rotation","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setPilotCameraRotation [rad 90, rad 45];\n```","code":["vehicle player setPilotCameraRotation [rad 90, rad 45];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"setPilotCameraTarget","operator":null,"title":"setPilotCameraTarget","type":"command","url":"https://community.bistudio.com/wiki/setPilotCameraTarget","revid":377764,"updated":"2026-01-03T01:00:05Z","groups":["Pilot Camera"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets an area or target to be tracked by the object airplane or helicopter pilotCamera.\nTo track an object the vehicle has to have appropriate sensors (scanners) that can detect the given target type.\nUsing objNull will unlock the camera","syntaxes":[{"syntax":"object setPilotCameraTarget target","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"target","type":"Object or PositionASL","optional":false,"default":null,"description":null,"types":["Object","PositionASL"],"since":null,"text":"target: Object or PositionASL"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"target","types":["Object","PositionASL"]}}],"examples":[{"text":"```sqf\n_pilotCamTrack = vehicle player setPilotCameraTarget [2100,4200,4.2];\n```","code":["_pilotCamTrack = vehicle player setPilotCameraTarget [2100,4200,4.2];"]},{"text":"```sqf\n_pilotCamTrack = vehicle player setPilotCameraTarget BIS_Edita;\n```","code":["_pilotCamTrack = vehicle player setPilotCameraTarget BIS_Edita;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hasPilotCamera","getPilotCameraPosition","getPilotCameraDirection","getPilotCameraRotation","getPilotCameraTarget","setPilotCameraDirection","setPilotCameraRotation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Pilot Camera","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"setPilotLight","operator":null,"title":"setPilotLight","type":"command","url":"https://community.bistudio.com/wiki/setPilotLight","revid":369321,"updated":"2024-09-03T18:42:57Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Switches headlights of a vehicle on/off. Note that the vehicle has to be local, for global variant use Arma 3: Actions \"LightOn\"/\"LightOff\"","syntaxes":[{"syntax":"vehicle setPilotLight set","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"set","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"set: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\ncar setPilotLight true;\n```","code":["car setPilotLight true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isLightOn","isCollisionLightOn","setCollisionLight","isIRLaserOn"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setPiPEffect","operator":null,"title":"setPiPEffect","type":"command","url":"https://community.bistudio.com/wiki/setPiPEffect","revid":351291,"updated":"2023-11-27T03:13:48Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets Render Target's visual effect (Picture-in-Picture).\n\n| Mode | Description | Parameters |\n|---|---|---|\n| 0 | Normal | [0] |\n| 1 | Night Vision | [1] |\n| 2 | Thermal Imaging | [2] |\n| 3 | Color Correction | [3, enabled, brightness, contrast, offset, blend [r,g,b,a], lerp [r,g,b,a], rgb [r,g,b,a]] |\n| 7 | Alt. Thermal Imaging 1 (Inverted) | [7] |\n| 8 | Alt. Thermal Imaging 2 (Green) | [8] |\n| 9..70 | Arma 3 v2.10 Alt. Thermal Imaging 3..64 | *[n]* |","syntaxes":[{"syntax":"name setPiPEffect [effect, optionalParam1, optionalParam2, ...]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"render surface reference from Render To Texture","types":["String"],"since":null,"text":"name : String - render surface reference from Render To Texture"},{"name":"effect","type":"Number","optional":false,"default":null,"description":"effect type","types":["Number"],"since":null,"text":"effect : Number - effect type"},{"name":"optionalParamN","type":"Number","optional":true,"default":null,"description":"parameters based on selected effect","types":["Number"],"since":null,"text":"optionalParamN: Number - (Optional) parameters based on selected effect"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"name","types":["String"]},"right":{"text":"[effect, optionalParam1, optionalParam2, ...]","types":["Array"]}}],"examples":[{"text":"```sqf\n\"rendersurface\" setPiPEffect [0];\n```","code":["\"rendersurface\" setPiPEffect [0];"]},{"text":"```sqf\n\"rendertarget0\" setPiPEffect [3, 1, 1.0, 1.0, 0.0, [0.0, 1.0, 0.0, 0.25], [1.0, 0.0, 1.0, 1.0],  [0.199, 0.587, 0.114, 0.0]];\n```","code":["\"rendertarget0\" setPiPEffect [3, 1, 1.0, 1.0, 0.0, [0.0, 1.0, 0.0, 0.25], [1.0, 0.0, 1.0, 1.0],  [0.199, 0.587, 0.114, 0.0]];"]},{"text":"```sqf\nprivate _cam = \"camera\" camCreate (player modelToWorld [0,-5,2]);\n_cam cameraEffect [\"internal\", \"back\", \"rtt\"];\n\"rtt\" setPiPEffect [2];\nwith uiNamespace do {\n    private _pic = findDisplay 46 ctrlCreate [\"RscPicture\", -1];\n    _pic ctrlSetPosition [0,0,1,1];\n    _pic ctrlCommit 0;\n    _pic ctrlSetText \"#(argb,512,512,1)r2t(rtt,1.0)\";\n};\n```","code":["private _cam = \"camera\" camCreate (player modelToWorld [0,-5,2]);\n_cam cameraEffect [\"internal\", \"back\", \"rtt\"];\n\"rtt\" setPiPEffect [2];\nwith uiNamespace do {\n\tprivate _pic = findDisplay 46 ctrlCreate [\"RscPicture\", -1];\n\t_pic ctrlSetPosition [0,0,1,1];\n\t_pic ctrlCommit 0;\n\t_pic ctrlSetText \"#(argb,512,512,1)r2t(rtt,1.0)\";\n};"]},{"text":"Black & White:\n\n```sqf\n\"rtt\" setPiPEffect [3, 1, 1.0, 0.4, 0, [0,0,0,0], [1,1,1,0], [1,1,1,1]];\n```","code":["\"rtt\" setPiPEffect [3, 1, 1.0, 0.4, 0, [0,0,0,0], [1,1,1,0], [1,1,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Procedural Textures","camCreate","cameraEffect","Post Process Effects"],"notes":[{"user":"Killzone_Kid","date":"2017-07-09T20:04:00Z","text":"If Color Corrections effect has been used, going back to Normal will have no effect. In order to unset Color Corrections, set the 2nd param in it (enable) to 0."}],"categories":["Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setPiPViewDistance","operator":null,"title":"setPiPViewDistance","type":"command","url":"https://community.bistudio.com/wiki/setPiPViewDistance","revid":309141,"updated":"2022-05-03T11:52:25Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.08"}],"since":{"game":"arma3","name":"Arma 3","version":"2.08"},"arma3_since":"2.08","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set the PiP (Picture-in-Picture) view distance. This has no impact if PiP is disabled (see isPiPEnabled).","syntaxes":[{"syntax":"setPiPViewDistance distance","since":null,"effect":null,"exec":null,"params":[{"name":"distance","type":"Number","optional":false,"default":null,"description":"distance in meters, minimum value is 100, maximum is current view distance","types":["Number"],"since":null,"text":"distance: Number - distance in meters, minimum value is 100, maximum is current view distance"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\nsetPiPViewDistance 100;\n```","code":["setPiPViewDistance 100;"]},{"text":"```sqf\nsetPiPViewDistance viewDistance;\n```","code":["setPiPViewDistance viewDistance;"]},{"text":"```sqf\nsetPiPViewDistance getObjectViewDistance;\n```","code":["setPiPViewDistance getObjectViewDistance;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPiPViewDistance","setViewDistance","setObjectViewDistance","viewDistance","getObjectViewDistance"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.08","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setPitch","operator":null,"title":"setPitch","type":"command","url":"https://community.bistudio.com/wiki/setPitch","revid":319600,"updated":"2022-05-13T09:24:33Z","groups":["Unit Identity","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the pitch of a persons voice.","syntaxes":[{"syntax":"person setPitch pitch","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"pitch","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"pitch: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"pitch","types":["Number"]}}],"examples":[{"text":"```sqf\nunit1 setPitch 0.5;\n```","code":["unit1 setPitch 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["pitch","setIdentity"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setPlateNumber","operator":null,"title":"setPlateNumber","type":"command","url":"https://community.bistudio.com/wiki/setPlateNumber","revid":353037,"updated":"2024-03-12T11:54:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.82"}],"since":{"game":"arma3","name":"Arma 3","version":"1.82"},"arma3_since":"1.82","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Change the license plates on any vehicle which has plates configured. Max 15 characters are allowed!","syntaxes":[{"syntax":"vehicle setPlateNumber string","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player setPlateNumber \"K2000\";\n```","code":["vehicle player setPlateNumber \"K2000\";"]},{"text":"Reset plate to the world's randomised template:\n\n```sqf\nprivate _return = \"\";\nprivate _cfg = (configFile >> \"CfgWorlds\" >> worldName);\n\n{\n    _return = _return + (call {\n        if (_x == \"$\") exitWith {\n            selectRandom (getText (_cfg >> \"plateLetters\") splitString \"\")\n        };\n        if (_x == \"#\") exitWith {\n            selectRandom [\"0\",\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"7\",\"8\",\"9\"]\n        };\n        _x\n    });\n} forEach (getText (_cfg >> \"plateFormat\") splitString \"\");\n\n_car setPlateNumber _return;\n```","code":["private _return = \"\";\nprivate _cfg = (configFile >> \"CfgWorlds\" >> worldName);\n\n{\n\t_return = _return + (call {\n\t\tif (_x == \"$\") exitWith {\n\t\t\tselectRandom (getText (_cfg >> \"plateLetters\") splitString \"\")\n\t\t};\n\t\tif (_x == \"#\") exitWith {\n\t\t\tselectRandom [\"0\",\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"7\",\"8\",\"9\"]\n\t\t};\n\t\t_x\n\t});\n} forEach (getText (_cfg >> \"plateFormat\") splitString \"\");\n\n_car setPlateNumber _return;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPlateNumber"],"notes":[{"user":"Demellion","date":"2018-04-19T05:34:00Z","text":"**NOTICE**: If this command is performed where the argument is remote, the plate will change and getPlateNumber will also return the new value, until vehicle owner sync it back to original in ~10 seconds after."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.82","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setPlayable","operator":null,"title":"setPlayable","type":"command","url":"https://community.bistudio.com/wiki/setPlayable","revid":341452,"updated":"2023-05-30T10:27:23Z","groups":["Broken Commands","Multiplayer"],"status":"broken","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create a multiplayer role for the unit. The roles created this way are used for Join In Progress and Team Switch.","syntaxes":[{"syntax":"setPlayable unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nsetPlayable _aPerson;\n```","code":["setPlayable _aPerson;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> This command does not work as intended and currently does nothing in Arma 3.","aliases":[],"see_also":["addSwitchableUnit"],"notes":[{"user":"Lou Montana","date":"2009-12-19T22:48:00Z","text":"If you want to add a TeamSwitchable unit (at least in Arma 2), better use addSwitchableUnit."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Multiplayer","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setPlayerRespawnTime","operator":null,"title":"setPlayerRespawnTime","type":"command","url":"https://community.bistudio.com/wiki/setPlayerRespawnTime","revid":378018,"updated":"2026-01-22T12:47:44Z","groups":["Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.57"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the time interval (in seconds) that the player must wait before respawn, for the next respawn only.\nIt resets to mission default on mission start.\nIn Single Player or when respawn type is GROUP or SIDE in Multiplayer, setting player respawn time has no effect, and playerRespawnTime will always return -1.","syntaxes":[{"syntax":"setPlayerRespawnTime interval","since":null,"effect":null,"exec":null,"params":[{"name":"interval","type":"Number","optional":false,"default":null,"description":"respawn time in seconds","types":["Number"],"since":null,"text":"interval: Number - respawn time in seconds"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"interval","types":["Number"]}}],"examples":[{"text":"```sqf\nsetPlayerRespawnTime 5; // next respawn (and only this one) will happen 5s after death\n```","code":["setPlayerRespawnTime 5; // next respawn (and only this one) will happen 5s after death"]},{"text":"Set the respawn duration through variable:\n\n```sqf\nplayer addEventHandler [\"Killed\", {\n    setPlayerRespawnTime (player getVariable [\"TAG_RespawnDelay\", 10]);\n}];\n```\n\nSomewhere else, e.g on objective completion:\n\n```sqf\nplayer setVariable [\"TAG_RespawnDelay\", 5];\n```\n\nor if that player is on another machine:\n\n```sqf\nwaitUntil { not alive _target };\n_thatPlayer setVariable [\"TAG_RespawnDelay\", 5, true];\n```","code":["player addEventHandler [\"Killed\", {\n\tsetPlayerRespawnTime (player getVariable [\"TAG_RespawnDelay\", 10]);\n}];","player setVariable [\"TAG_RespawnDelay\", 5];","waitUntil { not alive _target };\n_thatPlayer setVariable [\"TAG_RespawnDelay\", 5, true];"]},{"text":"Increase respawn duration every death:\n\n```sqf\nplayer addEventHandler [\"Killed\", {\n    private _respawnTime = player getVariable [\"TAG_RespawnDelay\", 8];\n    setPlayerRespawnTime _respawnTime;\n    player setVariable [\"TAG_RespawnDelay\", _respawnTime + 1]; // don't die too many times\n}];\n```","code":["player addEventHandler [\"Killed\", {\n\tprivate _respawnTime = player getVariable [\"TAG_RespawnDelay\", 8];\n\tsetPlayerRespawnTime _respawnTime;\n\tplayer setVariable [\"TAG_RespawnDelay\", _respawnTime + 1]; // don't die too many times\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playerRespawnTime","respawnVehicle"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Introduced with Arma 2: Operation Arrowhead version 1.57","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setPlayerVoNVolume","operator":null,"title":"setPlayerVoNVolume","type":"command","url":"https://community.bistudio.com/wiki/setPlayerVoNVolume","revid":309265,"updated":"2022-05-04T11:09:04Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets provided player's Voice over Network (VoN) volume.","syntaxes":[{"syntax":"unit setPlayerVoNVolume volume","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the other player's unit","types":["Object"],"since":null,"text":"unit: Object - the other player's unit"},{"name":"volume","type":"Number","optional":false,"default":null,"description":"the wanted volume","types":["Number"],"since":null,"text":"volume: Number - the wanted volume"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"volume","types":["Number"]}}],"examples":[{"text":"```sqf\n_loudPlayer setPlayerVoNVolume 0.5;\n```","code":["_loudPlayer setPlayerVoNVolume 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPlayerVoNVolume","fadeSound","fadeRadio","fadeMusic"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.00","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setPos","operator":null,"title":"setPos","type":"command","url":"https://community.bistudio.com/wiki/setPos","revid":377794,"updated":"2026-01-03T03:50:30Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets object position to format PositionAGLS (over surface). The Z value is used to calculate the nearest surface below the provided position. If the surface is close, it uses the Z position of the surface. Otherwise, Z value becomes the offset from that surface.\n\n> [!IMPORTANT]\n> It is recommended to **avoid** this command when placing objects above other objects, due to the unpredictable behavior described above.","syntaxes":[{"syntax":"object setPos pos","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"pos","type":"PositionAGL or Position2D","optional":false,"default":null,"description":"if Position2D, Z will be set to 0","types":["PositionAGL","Position2D"],"since":null,"text":"pos: PositionAGL or Position2D - if Position2D, Z will be set to 0"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"pos","types":["PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\nplayer setPos [getPos player select 0, getPos player select 1, (getPos player select 2) +10];\n\n// the same as above using set (OFP:R v1.75)\n_pos = getPos player;\n_pos set [2, _pos select 2 + 10];\nplayer setPos _pos;\n\n// the same as above using modelToWorld (ArmA v1.00)\nplayer setPos (player modelToWorld [0,0,10]);\n\n// the same as above using vectorAdd (Arma 3 v1.22)\nplayer setPos (getPos player vectorAdd [0,0,10]);\n```","code":["player setPos [getPos player select 0, getPos player select 1, (getPos player select 2) +10];\n\n// the same as above using set (OFP:R v1.75)\n_pos = getPos player;\n_pos set [2, _pos select 2 + 10];\nplayer setPos _pos;\n\n// the same as above using modelToWorld (ArmA v1.00)\nplayer setPos (player modelToWorld [0,0,10]);\n\n// the same as above using vectorAdd (Arma 3 v1.22)\nplayer setPos (getPos player vectorAdd [0,0,10]);"]},{"text":"```sqf\n_obj setPos [getPos _obj select 0, getPos _obj select 1, -5];\n```","code":["_obj setPos [getPos _obj select 0, getPos _obj select 1, -5];"]},{"text":"```sqf\nplayer setPos (getPos _obj);\n```","code":["player setPos (getPos _obj);"]}],"multiplayer":"> [!NOTE]\n> **Armed Assault:** ArmA 1.00 to 1.06: this command has local effect, but some simulation types do synchronise their changes over the network whilst others do not.\n>\n> So far, the only known simulation type that doesn't synchronise its position over the net is \"static\" ().","problems":null,"aliases":[],"see_also":["setPosASL","getPos","setVehiclePosition","Position"],"notes":[{"user":"Hduregger","date":"2011-02-06T20:20:00Z","text":"Calling setPos on an object can cause the object's orientation to change. This depends on the terrain and/or objects below the object. This was tested by calling setPos on a test object with the position of a helicopter (modelToWorld with some offset). When flying over land the orientation of the test object would rapidly change depending on the slope of the ground and objects beneath it.\nComment applicable to Ver **1.96** and **earlier**:\n\n```sqf\nobj1 setPos [x,y,z]\n```\n\nWill place most objects z metres above ground level (negative numbers for underground). But if obj1 is a trigger then it will be placed z metres above sea level. This can be very useful if you want to check a unit's height above sea level but it can be a problem if you want to move a trigger to create an explosion or a sound. To move a trigger to a location at ground level:\n\n```sqf\ntriggername setPos [x,y,0];\ntriggername setPos [x,y,abs(getPos triggername select 2)];\n```\n\nNote for ArmA: Using setPos for a trigger will work in exactly the same way that setPos works for other objects - namely that setPos [x,y,z] will place the trigger z metres above ground level.\nsetPos for static objects like an ammo crate do not work in MP."},{"user":"Tankbuster","date":"2012-11-23T13:06:00Z","text":"You can use getPos and setPos on triggers."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setPosASL","operator":null,"title":"setPosASL","type":"command","url":"https://community.bistudio.com/wiki/setPosASL","revid":377438,"updated":"2026-01-02T06:46:46Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"ofp","name":"Operation Flashpoint","version":"1.99"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets the object position above sea level. Given position must be in PositionASL format.","syntaxes":[{"syntax":"object setPosASL pos","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"pos","type":"PositionASL","optional":false,"default":null,"description":null,"types":["PositionASL"],"since":null,"text":"pos: PositionASL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"pos","types":["PositionASL"]}}],"examples":[{"text":"```sqf\nplayer setPosASL [getPosASL player select 0, (getPosASL player select 1) + 10, getPosASL player select 2];\n```","code":["player setPosASL [getPosASL player select 0, (getPosASL player select 1) + 10, getPosASL player select 2];"]},{"text":"```sqf\n_position = getPosASL _object;\n_position set [2, 10]; // 10m above sea level\n_object setPosASL _position;\n```","code":["_position = getPosASL _object;\n_position set [2, 10]; // 10m above sea level\n_object setPosASL _position;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ASLToATL","ATLToASL","getPos","getPosASL","getPosATL","position","setPos","setPosASL2","setPosATL","getTerrainHeightASL","setPosWorld","setVehiclePosition"],"notes":[{"user":"Hypoxic125","date":"2023-02-26T03:59:06Z","text":"As of Verson 2.10, if you use setPosX commands on a remote unit within a vehicle, the unit will remain in the vehicle. In order to avoid this, remoteExec the command to the remote client.\n\n```sqf\nif !(isNull objectParent _unit) then {\n    [_unit, [0,0,0]] remoteExec [\"setPosASL\", _unit];\n};\n```"}],"categories":[]},{"name":"setPosASL2","operator":null,"title":"setPosASL2","type":"command","url":"https://community.bistudio.com/wiki/setPosASL2","revid":378100,"updated":"2026-02-13T10:46:49Z","groups":["Broken Commands","Positions"],"status":"broken","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the object position. The pos array uses the PositionASL format.\nThe version of the command does not offset based on object center.\n\n> [!WARNING]\n> This command was deactivated and has no effect. Use setPosWorld instead.","syntaxes":[{"syntax":"obj setPosASL2 pos","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"pos","type":"PositionASL","optional":false,"default":null,"description":null,"types":["PositionASL"],"since":null,"text":"pos: PositionASL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"pos","types":["PositionASL"]}}],"examples":[{"text":"```sqf\nprivate _aslPos = getPosASL player;\n_aslPos set [1, _aslPos select 1 + 10];\nplayer setPosASL2 _aslPos;\n```","code":["private _aslPos = getPosASL player;\n_aslPos set [1, _aslPos select 1 + 10];\nplayer setPosASL2 _aslPos;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPosWorld","getPosWorld","setPosASL","getPosASL"],"notes":[{"user":"Killzone_Kid","date":"2013-08-21T20:07:00Z","text":"This command appears to do nothing in both Arma 2 and Arma 3."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setPosASLW","operator":null,"title":"setPosASLW","type":"command","url":"https://community.bistudio.com/wiki/setPosASLW","revid":377592,"updated":"2026-01-02T06:59:02Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets the object position above sea surface. The pos array uses the PositionASLW format.","syntaxes":[{"syntax":"obj setPosASLW pos","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"pos","type":"PositionASLW","optional":false,"default":null,"description":null,"types":["PositionASLW"],"since":null,"text":"pos: PositionASLW"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"pos","types":["PositionASLW"]}}],"examples":[{"text":"```sqf\n_diver setPosASLW [(position _diver) select 0, (position _diver) select 1, -10];\n```","code":["_diver setPosASLW [(position _diver) select 0, (position _diver) select 1, -10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosASLW","setPosASL","setPosATL","setPos","setPosWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setPosATL","operator":null,"title":"setPosATL","type":"command","url":"https://community.bistudio.com/wiki/setPosATL","revid":377533,"updated":"2026-01-02T06:53:18Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.03"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.03"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets the position of an object relative to the terrain.","syntaxes":[{"syntax":"object setPosATL pos","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"pos","type":"PositionATL","optional":false,"default":null,"description":null,"types":["PositionATL"],"since":null,"text":"pos: PositionATL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"pos","types":["PositionATL"]}}],"examples":[{"text":"```sqf\nplayer setPosATL [getPosATL player select 0, (getPosATL player select 1) - 10, getPosATL player select 2];\n```","code":["player setPosATL [getPosATL player select 0, (getPosATL player select 1) - 10, getPosATL player select 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosATL","getPos","getPosASL","setPos","setPosASL"],"notes":[{"user":"DreadedEntity","date":"2014-11-11T20:39:00Z","text":"If you plan on creating bases through script, setPosATL and getPosATL will be your friends. Other commands like getPos or getPosASL **will** return the position relative to any objects that are underneath / to the terrain.\nI wrote a base building helper script and through multiple tests, I have found that getPosATL is the absolute best way to get position for objects that are over land."},{"user":"Hypoxic125","date":"2022-09-30T04:03:03Z","text":"As of **Verson 2.10**, if you use **setPosX** commands on a remote unit within a vehicle, the unit will remain in the vehicle. In order to avoid this, **remoteExec** the command to the remote client.\n\n```sqf\nif !(isNull objectParent _unit) then {\n    [_unit, [0,0,0]] remoteExec [\"setPosATL\", _unit];\n};\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.03","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setPosition","operator":null,"title":"setPosition","type":"command","url":"https://community.bistudio.com/wiki/setPosition","revid":377520,"updated":"2026-01-02T06:52:07Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the position of a location.","syntaxes":[{"syntax":"location setPosition pos","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"pos","types":["Position"]}}],"examples":[{"text":"```sqf\nmyLocation setPosition getPosATL player;\n```","code":["myLocation setPosition getPosATL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["locationPosition"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setPosWorld","operator":null,"title":"setPosWorld","type":"command","url":"https://community.bistudio.com/wiki/setPosWorld","revid":377460,"updated":"2026-01-02T06:47:29Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets position of an object based on the model's centre position (see getPosWorld).","syntaxes":[{"syntax":"object setPosWorld position","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"PositionASL","optional":false,"default":null,"description":null,"types":["PositionASL"],"since":null,"text":"position: PositionASL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"position","types":["PositionASL"]}}],"examples":[{"text":"```sqf\n_obj setPosWorld getPosWorld _obj;\n```","code":["_obj setPosWorld getPosWorld _obj;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosWorld","setPos","setPosATL","setPosASL","setPosASLW","setMarkerPos","setVehiclePosition"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 1.32","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setPylonLoadout","operator":null,"title":"setPylonLoadout","type":"command","url":"https://community.bistudio.com/wiki/setPylonLoadout","revid":378820,"updated":"2026-07-01T10:02:12Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Adds/overrides loadout to a vehicle pylon. `TransportPylonsComponent` in vehicle config and `pylonWeapon` in the magazine config are required to run.\n\n> [!NOTE]\n> This command also adds the corresponding weapon if the vehicle does not have one, but will not remove one that is no longer used.","syntaxes":[{"syntax":"vehicle setPylonLoadout [pylon, magazine, forced, turret]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"pylon","type":"Number or String","optional":false,"default":null,"description":"pylon index (index starts from 1) or pylon name (see #Example 1)","types":["Number","String"],"since":null,"text":"pylon: Number or String - pylon index (index starts from 1) or pylon name (see #Example 1)"},{"name":"magazine","type":"String","optional":false,"default":null,"description":"magazine name","types":["String"],"since":null,"text":"magazine: String - magazine name"},{"name":"forced","type":"Boolean","optional":true,"default":"false","description":"true to force an incompatible magazine","types":["Boolean"],"since":null,"text":"forced: Boolean - (Optional, default false) true to force an incompatible magazine"},{"name":"turret","type":"Turret Path","optional":true,"default":"`[]`","description":"turret path","types":["Turret Path"],"since":null,"text":"turret: Turret Path - (Optional, default `[]`) turret path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[pylon, magazine, forced, turret]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setPylonLoadout [\"pylon1\", \"\"];\n```","code":["vehicle player setPylonLoadout [\"pylon1\", \"\"];"]},{"text":"Make all of your pylon weapons Twin Cannon 30 mm:\n\n```sqf\nprivate _vehicle = vehicle player;\nprivate _pylonsIndices = getAllPylonsInfo _vehicle apply { _x select 0 };\n{\n    _vehicle setPylonLoadout [_x, \"PylonWeapon_300Rnd_20mm_shells\", true];\n} forEach _pylonsIndices;\n```","code":["private _vehicle = vehicle player;\nprivate _pylonsIndices = getAllPylonsInfo _vehicle apply { _x select 0 };\n{\n\t_vehicle setPylonLoadout [_x, \"PylonWeapon_300Rnd_20mm_shells\", true];\n} forEach _pylonsIndices;"]},{"text":"Showcase all possible magazines:\n\n```sqf\n0 spawn {\n    private _allPylonMagazines = \"getText (_x >> 'pylonWeapon') != ''\" configClasses (configFile >> \"CfgMagazines\");\n    private _vehicle = vehicle player;\n    private _pylonsIndices = getAllPylonsInfo _vehicle apply { _x select 0 };\n\n    {\n        private _configName = configName _x;\n        {\n            _vehicle setPylonLoadout [_x, _configName, true];\n        } forEach _pylonsIndices;\n\n        hint _configName;\n        sleep 1.5;\n    } forEach _allPylonMagazines;\n};\n```","code":["0 spawn {\n\tprivate _allPylonMagazines = \"getText (_x >> 'pylonWeapon') != ''\" configClasses (configFile >> \"CfgMagazines\");\n\tprivate _vehicle = vehicle player;\n\tprivate _pylonsIndices = getAllPylonsInfo _vehicle apply { _x select 0 };\n\n\t{\n\t\tprivate _configName = configName _x;\n\t\t{\n\t\t\t_vehicle setPylonLoadout [_x, _configName, true];\n\t\t} forEach _pylonsIndices;\n\n\t\thint _configName;\n\t\tsleep 1.5;\n\t} forEach _allPylonMagazines;\n};"]},{"text":"MP compatible usage:\n\n```sqf\n[myPlane, [1, \"PylonWeapon_300Rnd_20mm_shells\", true]] remoteExec [\"setPylonLoadout\", myPlane];\n```","code":["[myPlane, [1, \"PylonWeapon_300Rnd_20mm_shells\", true]] remoteExec [\"setPylonLoadout\", myPlane];"]}],"multiplayer":"> [!IMPORTANT]\n> This command should run locally to the vehicle itself or it will cause desync issue! (especially upon the locality change, e.g getting in the vehicle).\n> See #Example 4 for an MP-compatible usage.","problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","getPylonMagazines","setAmmoOnPylon","ammoOnPylon","animatePylon","animateBay","setPylonsPriority"],"notes":[{"user":"POLPOX","date":"2020-04-30T13:01:00Z","text":"**Before Arma 3 v2.02:** *turret* must be `[]` if you wanted to equip the magazine to the pilot. `[-1]` returns false and fails unlike other turret-related commands."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setPylonsPriority","operator":null,"title":"setPylonsPriority","type":"command","url":"https://community.bistudio.com/wiki/setPylonsPriority","revid":310928,"updated":"2022-05-07T20:51:11Z","groups":["Vehicle Loadouts"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Overrides default pylons priorities.","syntaxes":[{"syntax":"vehicle setPylonsPriority priorities","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"priorities","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"priorities: Array of Numbers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"priorities","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n(vehicle player) setPylonsPriority [0,1,2,3,4,5,5,4,3,2,1,0];\n```","code":["(vehicle player) setPylonsPriority [0,1,2,3,4,5,5,4,3,2,1,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle Loadouts","getCompatiblePylonMagazines","getPylonMagazines","setAmmoOnPylon","ammoOnPylon","animatePylon","animateBay","setPylonLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Loadouts","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setRadioMsg","operator":null,"title":"setRadioMsg","type":"command","url":"https://community.bistudio.com/wiki/setRadioMsg","revid":378813,"updated":"2026-06-30T23:28:57Z","groups":["Triggers","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets radio trigger menu title text (0 -> 0 -> map radio). Use \"NULL\" to disable radio slot. Use \"\" to restore default title.\n\n> [!NOTE]\n> The same effect could be achieved by using setTriggerText (see Example 2)","syntaxes":[{"syntax":"index setRadioMsg text","since":null,"effect":null,"exec":null,"params":[{"name":"index","type":"Number","optional":false,"default":null,"description":"from 1 to 10\n\n- 1 - Alpha (key 1)\n- 2 - Bravo (key 2)\n- 3 - Charlie (key 3)\n- 4 - Delta (key 4)\n- 5 - Echo (key 5)\n- 6 - Foxtrot (key 6)\n- 7 - Golf (key 7)\n- 8 - Hotel (key 8)\n- 9 - India (key 9)\n- 10 - Juliet (key 0)","types":["Number"],"since":null,"text":"index: Number - from 1 to 10\n\n- 1 - Alpha (key 1)\n- 2 - Bravo (key 2)\n- 3 - Charlie (key 3)\n- 4 - Delta (key 4)\n- 5 - Echo (key 5)\n- 6 - Foxtrot (key 6)\n- 7 - Golf (key 7)\n- 8 - Hotel (key 8)\n- 9 - India (key 9)\n- 10 - Juliet (key 0)"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"index","types":["Number"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n1 setRadioMsg \"Click meeeeeeeeee\"; //changes title of radio Alpha\n```","code":["1 setRadioMsg \"Click meeeeeeeeee\"; //changes title of radio Alpha"]},{"text":"```sqf\n_radioTrigger setTriggerText \"Click meeeeeeeeee\"; //changes title of whatever radio the trigger was set to\n```","code":["_radioTrigger setTriggerText \"Click meeeeeeeeee\"; //changes title of whatever radio the trigger was set to"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","setTriggerActivation","setTriggerText","showCommandingMenu"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Triggers","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setRain","operator":null,"title":"setRain","type":"command","url":"https://community.bistudio.com/wiki/setRain","revid":377884,"updated":"2026-01-04T16:27:04Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Sets rain density smoothly over the given transition time. A transition time of zero means an immediate change.\nA rain density of zero is no rain, one is maximum rain. Rain is not possible when overcast is less than 0.7.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 this command is multiplayer-synchronised:\n> - if executed on the server, the changes will propagate globally.\n> - if executed on a client, the effect is local, temporary and will soon change to the server setting.\n> Minimum overcast needed for rain in Arma 3 is **0.5**.\n\n> [!IMPORTANT]\n> Alternative syntaxes (#Syntax 2 and #Syntax 3):\n> - set rain particle params. Rain particles params are client-side params and are ignored on dedicated server. Use helper function BIS_fnc_setRain if sync is needed in Multiplayer\n> - have a **local** Local Effect effect","syntaxes":[{"syntax":"time setRain rain","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"transition time in seconds to the new value","types":["Number"],"since":null,"text":"time: Number - transition time in seconds to the new value"},{"name":"rain","type":"Number in range 0..1","optional":false,"default":null,"description":"new rain value","types":["Number"],"since":null,"text":"rain: Number in range 0..1 - new rain value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"rain","types":["Number"]}},{"syntax":"setRain rainParams","since":"arma3 2.08","effect":"local","exec":null,"params":[{"name":"rainParams","type":"Array of Anything","optional":false,"default":null,"description":"custom `RainParticles` params - see rainParams. Use empty array [] to reset to default config values","types":["Array","Anything"],"since":null,"text":"rainParams: Array of Anything - custom `RainParticles` params - see rainParams. Use empty array [] to reset to default config values"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"rainParams","types":["Array","Anything"]}},{"syntax":"setRain config","since":"arma3 2.08","effect":"local","exec":null,"params":[{"name":"config","type":"Config","optional":false,"default":null,"description":"config path to a custom class, which contains `RainParticles` class. Use configNull to reset to default config values","types":["Config"],"since":null,"text":"config: Config - config path to a custom class, which contains `RainParticles` class. Use configNull to reset to default config values"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n60 setRain 1;\n```","code":["60 setRain 1;"]},{"text":"Force no rain:\n\n```sqf\n0 setRain 0;\nforceWeatherChange;\n999999 setRain 0;\n```","code":["0 setRain 0;\nforceWeatherChange;\n999999 setRain 0;"]},{"text":"See also BIS_fnc_setRain since Arma 3 v2.10:\n\n```sqf\n0 setOvercast 1;\n0 setRain 1;\n0 setFog 0.1;        // snow affects visibility at distance\nsetHumidity 0.9;    // don't want to see dust clouds\nenableEnvironment [false, true];    // don't want to see snakes and butterflies either\nforceWeatherChange;\n[\n    \"a3\\data_f\\snowflake4_ca.paa\",    // rainDropTexture - 4 means it has 4 flakes in it. Other available textures: snowflake8_ca.paa, snowflake16_ca.paa\n    4,                // texDropCount - 4 because we are using texture with 4 flakes. Change to 8 or 16 in accordance with other textures used\n    0.01,            // minRainDensity\n    25,                // effectRadius\n    0.05,            // windCoef\n    2.5,            // dropSpeed\n    0.5,            // rndSpeed\n    0.5,            // rndDir\n    0.07,            // dropWidth\n    0.07,            // dropHeight\n    [1, 1, 1, 0.5],    // dropColor\n    0.0,            // lumSunFront\n    0.2,            // lumSunBack\n    0.5,            // refractCoef\n    0.5,            // refractSaturation\n    true,            // snow\n    false            // dropColorStrong\n]\ncall BIS_fnc_setRain;\n```","code":["0 setOvercast 1;\n0 setRain 1;\n0 setFog 0.1;\t\t// snow affects visibility at distance\nsetHumidity 0.9;\t// don't want to see dust clouds\nenableEnvironment [false, true];\t// don't want to see snakes and butterflies either\nforceWeatherChange;\n[\n\t\"a3\\data_f\\snowflake4_ca.paa\",\t// rainDropTexture - 4 means it has 4 flakes in it. Other available textures: snowflake8_ca.paa, snowflake16_ca.paa\n\t4,\t\t\t\t// texDropCount - 4 because we are using texture with 4 flakes. Change to 8 or 16 in accordance with other textures used\n\t0.01,\t\t\t// minRainDensity\n\t25,\t\t\t\t// effectRadius\n\t0.05,\t\t\t// windCoef\n\t2.5,\t\t\t// dropSpeed\n\t0.5,\t\t\t// rndSpeed\n\t0.5,\t\t\t// rndDir\n\t0.07,\t\t\t// dropWidth\n\t0.07,\t\t\t// dropHeight\n\t[1, 1, 1, 0.5],\t// dropColor\n\t0.0,\t\t\t// lumSunFront\n\t0.2,\t\t\t// lumSunBack\n\t0.5,\t\t\t// refractCoef\n\t0.5,\t\t\t// refractSaturation\n\ttrue,\t\t\t// snow\n\tfalse\t\t\t// dropColorStrong\n]\ncall BIS_fnc_setRain;"]}],"multiplayer":"Prior to Arma 3, each client and the server could have different rain values.","problems":null,"aliases":[],"see_also":["rainParams","BIS_fnc_setRain","overcast","setOvercast","rain","nextWeatherChange","forceWeatherChange","setFog","setHumidity"],"notes":[{"user":"Zapat","date":"2015-12-15T14:31:00Z","text":"setTimeMultiplier does **not** affect transition time."},{"user":"Killzone_Kid","date":"2016-11-16T22:06:00Z","text":"Using #Example 2 on dedicated server might need additional interference on JIP clients. The reason is that JIP has rain value > 0 slowly changing to 0. To force client to sync one can execute this on client:\n\n```sqf\nskipTime 1; skipTime -1;\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setRainbow","operator":null,"title":"setRainbow","type":"command","url":"https://community.bistudio.com/wiki/setRainbow","revid":370469,"updated":"2024-12-16T18:09:58Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the rainbow value smoothly during the given time (in seconds). A time of zero means there will be an immediate change.","syntaxes":[{"syntax":"time setRainbow value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n360 setRainbow 1;\n```","code":["360 setRainbow 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rainbow"],"notes":[{"user":"Sa-Matra","date":"2022-07-01T07:24:42Z","text":"This command seems to be completely local, no synchronization with other clients, no JIP, nothing, you have to do it all yourself."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setRandomLip","operator":null,"title":"setRandomLip","type":"command","url":"https://community.bistudio.com/wiki/setRandomLip","revid":310244,"updated":"2022-05-05T13:11:05Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Enables/Disables random lip. When enabled, the unit continuously moves its lips as if it is talking.","syntaxes":[{"syntax":"unit setRandomLip bool","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer setRandomLip true;\n```","code":["player setRandomLip true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["say","setMimic","setFaceAnimation","setFace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setRank","operator":null,"title":"setRank","type":"command","url":"https://community.bistudio.com/wiki/setRank","revid":340311,"updated":"2023-04-29T17:00:34Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets rank of given unit.\n\n> [!NOTE]\n> **Arma 3:** Before Arma 3 v1.68 and in previous titles, this command was Global Argument Local Effect.","syntaxes":[{"syntax":"unitName setRank rank","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"rank","type":"String","optional":false,"default":null,"description":"one of:\n- `\"PRIVATE\"`\n- `\"CORPORAL\"`\n- `\"SERGEANT\"`\n- `\"LIEUTENANT\"`\n- `\"CAPTAIN\"`\n- `\"MAJOR\"`\n- `\"COLONEL\"`","types":["String"],"since":null,"text":"rank: String - one of:\n- `\"PRIVATE\"`\n- `\"CORPORAL\"`\n- `\"SERGEANT\"`\n- `\"LIEUTENANT\"`\n- `\"CAPTAIN\"`\n- `\"MAJOR\"`\n- `\"COLONEL\"`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"rank","types":["String"]}}],"examples":[{"text":"```sqf\nplayer setRank \"COLONEL\";\n```","code":["player setRank \"COLONEL\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["rank","setUnitRank"],"notes":[{"user":"Wolfrug","date":"2009-03-26T19:24:00Z","text":"Changing a unit's rank using either setUnitRank or setRank will also REPLACE their current rating dependent on their new rank (colonels have a rating of 7500 etc).\nThat is to say REPLACE, not add to: the unit's old rating will disappear with the rank change."},{"user":"Waffle SS.","date":"2014-04-12T20:39:00Z","text":"Behavior when used on players in multiplayer seems unpredictable. (Arma 3 1.00)"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setRectangular","operator":null,"title":"setRectangular","type":"command","url":"https://community.bistudio.com/wiki/setRectangular","revid":319790,"updated":"2022-05-13T09:24:53Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the shape of a location to be either rectangular or elliptical. Locations default shape is elliptical.","syntaxes":[{"syntax":"location setRectangular set","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"set","type":"Boolean","optional":false,"default":null,"description":"true set rectangular, false set elliptical","types":["Boolean"],"since":null,"text":"set: Boolean - true set rectangular, false set elliptical"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\nmyLocation setRectangular true;\n```","code":["myLocation setRectangular true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setText","nearestLocation","nearestLocations","locationPosition","nearestLocationWithDubbing","createLocation","rectangular"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setRepairCargo","operator":null,"title":"setRepairCargo","type":"command","url":"https://community.bistudio.com/wiki/setRepairCargo","revid":376963,"updated":"2026-01-01T05:55:08Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set amount of repair resources in cargo space of repair vehicle.\nAmount 1 is full cargo.","syntaxes":[{"syntax":"vehicleName setRepairCargo amount","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"amount","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"amount: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"amount","types":["Number"]}}],"examples":[{"text":"```sqf\n_repairTruck1 setRepairCargo 0;\n```","code":["_repairTruck1 setRepairCargo 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getRepairCargo","setAmmoCargo","setFuelCargo"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setRotorBrakeRTD","operator":null,"title":"setRotorBrakeRTD","type":"command","url":"https://community.bistudio.com/wiki/setRotorBrakeRTD","revid":363578,"updated":"2024-04-07T14:41:13Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggles a helicopter's rotor brake. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD setRotorBrakeRTD enable","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"Object","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD : Object - helicopter"},{"name":"enable","type":"Number","optional":false,"default":null,"description":"can be:\n- 0: off\n- 1: on","types":["Number"],"since":null,"text":"enable: Number - can be:\n- 0: off\n- 1: on"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"enable","types":["Number"]}}],"examples":[{"text":"```sqf\nmyHelicopterRTD setRotorBrakeRTD 1;\n```","code":["myHelicopterRTD setRotorBrakeRTD 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getRotorBrakeRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setShadowDistance","operator":null,"title":"setShadowDistance","type":"command","url":"https://community.bistudio.com/wiki/setShadowDistance","revid":321940,"updated":"2022-05-22T12:55:27Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the shadows rendering distance.","syntaxes":[{"syntax":"setShadowDistance value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nsetShadowDistance 200;\n```","code":["setShadowDistance 200;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getShadowDistance","isPipEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setShotParents","operator":null,"title":"setShotParents","type":"command","url":"https://community.bistudio.com/wiki/setShotParents","revid":349182,"updated":"2023-11-08T14:50:39Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Sets vehicle and instigator pair for the given projectile.","syntaxes":[{"syntax":"projectile setShotParents [vehicle, instigator]","since":null,"effect":null,"exec":null,"params":[{"name":"projectile","type":"Object","optional":false,"default":null,"description":"the actual projectile shot","types":["Object"],"since":null,"text":"projectile: Object - the actual projectile shot"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle shooting projectile (appears as the 'killer' in \"Killed\" EH)","types":["Object"],"since":null,"text":"vehicle: Object - vehicle shooting projectile (appears as the 'killer' in \"Killed\" EH)"},{"name":"instigator","type":"Object","optional":false,"default":null,"description":"person pulling the trigger (appears as the 'instigator' in \"Killed\" EH)","types":["Object"],"since":null,"text":"instigator: Object - person pulling the trigger (appears as the 'instigator' in \"Killed\" EH)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"projectile","types":["Object"]},"right":{"text":"[vehicle, instigator]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyProjectile setShotParents [vehicle bob, bob];\n```","code":["myProjectile setShotParents [vehicle bob, bob];"]},{"text":"```sqf\ntank addEventHandler [\"Fired\", {_this select 6 setShotParents [tank, commander tank]}];\n```","code":["tank addEventHandler [\"Fired\", {_this select 6 setShotParents [tank, commander tank]}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getShotParents"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.66","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"setSide","operator":null,"title":"setSide","type":"command","url":"https://community.bistudio.com/wiki/setSide","revid":341632,"updated":"2023-06-12T19:02:54Z","groups":["Sides","Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets a location's side. The default side is Unknown.\n\n> [!IMPORTANT]\n> To change a *unit*'s side, see #Notes.","syntaxes":[{"syntax":"location setSide side","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"side","type":"Side","optional":false,"default":null,"description":null,"types":["Side"],"since":null,"text":"side: Side"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"side","types":["Side"]}}],"examples":[{"text":"```sqf\n_myLocation setSide resistance;\n```","code":["_myLocation setSide resistance;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side","side","west","east","resistance","civilian","sideUnknown","sideFriendly","sideEnemy","playerSide","Side Relations","independent"],"notes":[{"user":"Ondřejkuzel","date":"2013-12-03T16:00:00Z","text":"For units, vehicles you can use: `_unitsArray joinSilent createGroup _side`, e.g. in init: `[this] joinSilent createGroup EAST;` *described in the note below*"},{"user":"Jtgibson","date":"2009-08-06T19:05:00Z","text":"This is a frequent question on OFPEC, but produced here because it was difficult to find an answer to. **setSide** does not work for men, vehicles, etc.: it is intended for locations (*i.e.*, territory).  If you want to switch a unit's (*e.g.*, the player's) side in the middle of a battle, make the unit **joinSilent** a group on the given side instead.  If you want the unit to become the group leader after joining, use **selectLeader**.  I have not tested the idea of spawning a temporary unit of that side, assigning the player to that unit, setting the player as the leader, then deleting the original unit, but I don't see why it wouldn't work.  (It begs the question why we don't have a setSide object function, though.)"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Sides","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setSimpleTaskAlwaysVisible","operator":null,"title":"setSimpleTaskAlwaysVisible","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskAlwaysVisible","revid":304127,"updated":"2022-01-20T16:59:47Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets task's visibility.","syntaxes":[{"syntax":"taskID setSimpleTaskAlwaysVisible state","since":null,"effect":null,"exec":null,"params":[{"name":"taskID","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"taskID: Task"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true for always visible, false for fade out","types":["Boolean"],"since":null,"text":"state: Boolean - true for always visible, false for fade out"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"taskID","types":["Task"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"currentTask player setSimpleTaskAlwaysVisible true;","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskAlwaysVisible","createSimpleTask"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setSimpleTaskCustomData","operator":null,"title":"setSimpleTaskCustomData","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskCustomData","revid":351289,"updated":"2023-11-27T03:11:48Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set custom data for the task. Tooltip will be drawn in task list on the right side. Description will be drawn in task description panel on the bottom.","syntaxes":[{"syntax":"task setSimpleTaskCustomData [iconPath, tooltip, description]","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":"task the custom data are being added to","types":["Task"],"since":null,"text":"task: Task - task the custom data are being added to"},{"name":"iconPath","type":"String","optional":false,"default":null,"description":"icon path","types":["String"],"since":null,"text":"iconPath: String - icon path"},{"name":"tooltip","type":"String","optional":false,"default":null,"description":"text displayed next to the icon; max. 3 charactersc","types":["String"],"since":null,"text":"tooltip: String - text displayed next to the icon; max. 3 charactersc"},{"name":"description","type":"String","optional":false,"default":null,"description":"text displayed on the task description panel; html format","types":["String"],"since":null,"text":"description: String - text displayed on the task description panel; html format"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"[iconPath, tooltip, description]","types":["Array"]}}],"examples":[{"text":"```sqf\n_task setSimpleTaskCustomData [\"\\A3\\Ui_f\\data\\IGUI\\Cfg\\simpleTasks\\letters\\h_ca.paa\", \"This is the tooltip\", \"This is the description\"];\n```","code":["_task setSimpleTaskCustomData [\"\\A3\\Ui_f\\data\\IGUI\\Cfg\\simpleTasks\\letters\\h_ca.paa\", \"This is the tooltip\", \"This is the description\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskCustomData","setSimpleTaskType","taskType","Arma 3: Task Framework"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"setSimpleTaskDescription","operator":null,"title":"setSimpleTaskDescription","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskDescription","revid":330122,"updated":"2022-08-21T19:56:15Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attach descriptions to the simple task.","syntaxes":[{"syntax":"task setSimpleTaskDescription [description, descriptionShort, descriptionHUD]","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"description","type":"String","optional":false,"default":null,"description":"task description","types":["String"],"since":null,"text":"description: String - task description"},{"name":"descriptionShort","type":"String","optional":false,"default":null,"description":"task title","types":["String"],"since":null,"text":"descriptionShort: String - task title"},{"name":"descriptionHUD","type":"String","optional":false,"default":null,"description":"task waypoint description","types":["String"],"since":null,"text":"descriptionHUD: String - task waypoint description"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"[description, descriptionShort, descriptionHUD]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyTask setSimpleTaskDescription [\"Today you have to kill Spongebob\", \"Kill Spongebob\", \"There he is!\"];\n```","code":["myTask setSimpleTaskDescription [\"Today you have to kill Spongebob\", \"Kill Spongebob\", \"There he is!\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskDescription","Tasks","createSimpleTask","removeSimpleTask","setSimpleTaskDestination","setTaskState","setTaskResult","taskState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setSimpleTaskDestination","operator":null,"title":"setSimpleTaskDestination","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskDestination","revid":377515,"updated":"2026-01-02T06:50:22Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attach a destination to the simple task.\nOverrides setSimpleTaskTarget","syntaxes":[{"syntax":"task setSimpleTaskDestination pos","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"pos","types":["Position"]}}],"examples":[{"text":"```sqf\n_tskGoHere setSimpleTaskDestination (getMarkerPos \"obj1\");\n```","code":["_tskGoHere setSimpleTaskDestination (getMarkerPos \"obj1\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","createSimpleTask","removeSimpleTask","setSimpleTaskDescription","setTaskState","setTaskResult","taskState","taskDestination","cancelSimpleTaskDestination"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setSimpleTaskTarget","operator":null,"title":"setSimpleTaskTarget","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskTarget","revid":376222,"updated":"2025-09-20T13:11:55Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attach a target to the simple task.\nOverrides setSimpleTaskDestination.","syntaxes":[{"syntax":"task setSimpleTaskTarget [target, precisePosition]","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"},{"name":"precisePosition","type":"Boolean","optional":false,"default":null,"description":"use exact position of the target for map marker / HUD indicator instead of the position known to the task's owner (depending on the unit's knowledge of the target)","types":["Boolean"],"since":null,"text":"precisePosition: Boolean - use exact position of the target for map marker / HUD indicator instead of the position known to the task's owner (depending on the unit's knowledge of the target)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"[target, precisePosition]","types":["Array"]}}],"examples":[{"text":"```sqf\n_task setSimpleTaskTarget [targetVehicle, true];\n```","code":["_task setSimpleTaskTarget [targetVehicle, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["briefing","createSimpleTask","setSimpleTaskDestination"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setSimpleTaskType","operator":null,"title":"setSimpleTaskType","type":"command","url":"https://community.bistudio.com/wiki/setSimpleTaskType","revid":349265,"updated":"2023-11-08T14:51:08Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attach type to the simple task. See Default Task Types.","syntaxes":[{"syntax":"task setSimpleTaskType taskType","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"taskType","type":"String","optional":false,"default":null,"description":"type of task","types":["String"],"since":null,"text":"taskType: String - type of task"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"taskType","types":["String"]}}],"examples":[{"text":"```sqf\n(currentTask player) setSimpleTaskType \"attack\";\n```","code":["(currentTask player) setSimpleTaskType \"attack\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskType","currentTask","setSimpleTaskCustomData","taskCustomData","Arma 3 Tasks Overhaul"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"setSimulWeatherLayers","operator":null,"title":"setSimulWeatherLayers","type":"command","url":"https://community.bistudio.com/wiki/setSimulWeatherLayers","revid":370511,"updated":"2024-12-30T12:00:46Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets number of simul weather layers, affects quality of simul weather clouds.","syntaxes":[{"syntax":"setSimulWeatherLayers layers","since":null,"effect":null,"exec":null,"params":[{"name":"layers","type":"Number","optional":false,"default":null,"description":"cloud layers. -1 to reset to defaults (since 2.20), 0 to disable simul weather.","types":["Number"],"since":null,"text":"layers: Number - cloud layers. -1 to reset to defaults (since 2.20), 0 to disable simul weather."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"layers","types":["Number"]}}],"examples":[{"text":"```sqf\nsetSimulWeatherLayers 0; // Very flat clouds\n```","code":["setSimulWeatherLayers 0; // Very flat clouds"]}],"multiplayer":null,"problems":"Prior to Arma 3 v2.20 the effect of this command seems to be persistent across the game instance, e.g. restarting a mission will not reset it.","aliases":[],"see_also":["simulCloudDensity","simulCloudOcclusion","simulInClouds"],"notes":[{"user":"Sa-Matra","date":"2022-08-01T12:09:41Z","text":"You can revert clouds back to volumetric ones by executing this script:\n\n```sqf\nprivate _display_menu = findDisplay 46 createDisplay \"RscDisplayInterrupt\"; // ESC menu\nctrlActivate (_display_menu displayCtrl 301); // Pressing \"Video\" button\nctrlActivate (findDisplay 5 displayCtrl 2); // Pressing \"Cancel\" in Video menu\n_display_menu closeDisplay 2; // Closing ESC menu\n```\n\nPressing \"Cancel\" button in Video menu makes engine re-init the clouds, reverting results of this command. Make sure its in unscheduled environment, otherwise players might see flashing menu and you'll have a serialization error message."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"setSize","operator":null,"title":"setSize","type":"command","url":"https://community.bistudio.com/wiki/setSize","revid":377130,"updated":"2026-01-01T10:24:37Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the size (radius)  of a location.\n\nThe width  is 2 * x, the height is 2 * y.","syntaxes":[{"syntax":"location setSize [x,y]","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"},{"name":"y","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"y: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"[x,y]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyLocation setSize [10,30];\n```","code":["myLocation setSize [10,30];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["size"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setSkill","operator":null,"title":"setSkill","type":"command","url":"https://community.bistudio.com/wiki/setSkill","revid":364244,"updated":"2024-05-06T09:38:17Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the skill level of given unit. The value of a sub-skill is interpolated into a range defined in CfgAISkill.","syntaxes":[{"syntax":"unit setSkill skill","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skill","type":"Number","optional":false,"default":null,"description":"general skill in range 0..1","types":["Number"],"since":null,"text":"skill: Number - general skill in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"skill","types":["Number"]}},{"syntax":"unit setSkill [skillName, value]","since":"arma1 1.00","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skillName","type":"String","optional":false,"default":null,"description":"available sub-skills are:\n- `\"general\"`\n- `\"courage\"`\n- `\"aimingAccuracy\"`\n- `\"aimingShake\"`\n- `\"aimingSpeed\"`\n- `\"commanding\"`\n- `\"endurance\"`\n- `\"spotDistance\"`\n- `\"spotTime\"`\n- `\"reloadSpeed\"`","types":["String"],"since":null,"text":"skillName: String - available sub-skills are:\n- `\"general\"`\n- `\"courage\"`\n- `\"aimingAccuracy\"`\n- `\"aimingShake\"`\n- `\"aimingSpeed\"`\n- `\"commanding\"`\n- `\"endurance\"`\n- `\"spotDistance\"`\n- `\"spotTime\"`\n- `\"reloadSpeed\"`"},{"name":"value","type":"Number","optional":false,"default":null,"description":"value in range 0..1","types":["Number"],"since":null,"text":"value: Number - value in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[skillName, value]","types":["Array"]}}],"examples":[{"text":"```sqf\n_hero setSkill 1;\n```","code":["_hero setSkill 1;"]},{"text":"```sqf\n_finalBoss setSkill [\"reloadSpeed\", 0.8];\n_finalBoss setSkill [\"aimingSpeed\", 0.33];\n```","code":["_finalBoss setSkill [\"reloadSpeed\", 0.8];\n_finalBoss setSkill [\"aimingSpeed\", 0.33];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["skill","setUnitAbility","Arma 3: AI Skill","Combat Modes","skillFinal"],"notes":[{"user":"Hardrock","date":"2006-08-04T12:01:00Z","text":"Approximate ranges are:\n- Novice < 0.25\n- Rookie >= 0.25 and <= 0.45\n- Recruit > 0.45 and <= 0.65\n- Veteran > 0.65 and <= 0.85\n- Expert > 0.85"},{"user":"Kronzky","date":"2007-06-30T21:16:00Z","text":"If \"SuperAI\" is turned on in the Difficulty Menu, the skill level is always 1, no matter what was defined in the editor or via this command."}],"categories":["AI","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setSlingLoad","operator":null,"title":"setSlingLoad","type":"command","url":"https://community.bistudio.com/wiki/setSlingLoad","revid":353299,"updated":"2024-03-15T17:11:43Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a sling loading from a helicopter to an entity if possible. To unload cargo, pass objNull as second param. \n\n> [!NOTE]\n> FROM object has to be a helicoper, alive with rope attachment enabled, TO object has to be an entity, alive with rope attachment enabled.","syntaxes":[{"syntax":"heli setSlingLoad cargo","since":null,"effect":null,"exec":null,"params":[{"name":"heli","type":"Object","optional":false,"default":null,"description":"the helicopter slinging the load","types":["Object"],"since":null,"text":"heli: Object - the helicopter slinging the load"},{"name":"cargo","type":"Object","optional":false,"default":null,"description":"the cargo load entity","types":["Object"],"since":null,"text":"cargo: Object - the cargo load entity"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"heli","types":["Object"]},"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"```sqf\n_success = heli1 setSlingLoad veh1;\n```","code":["_success = heli1 setSlingLoad veh1;"]},{"text":"To unload cargo:\n\n```sqf\n_success = heli setSlingLoad objNull;\n```","code":["_success = heli setSlingLoad objNull;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind","slingLoadAssistantShown"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"setSoundEffect","operator":null,"title":"setSoundEffect","type":"command","url":"https://community.bistudio.com/wiki/setSoundEffect","revid":377738,"updated":"2026-01-03T00:57:45Z","groups":["Sounds","Triggers","Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines the different sound effects for a trigger or a waypoint. To stop any sound, deactivate the trigger (might take up to 0.5 seconds to stop) or delete the trigger/waypoint (immediate).","syntaxes":[{"syntax":"trigger setSoundEffect [sound, voice, soundEnv, soundDet]","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"sound","type":"String","optional":false,"default":null,"description":"plays a 2D sound as if playSound was used from CfgSounds (mission or main config). Use `\"$NONE$\"` for an empty sound","types":["String"],"since":null,"text":"sound: String - plays a 2D sound as if playSound was used from CfgSounds (mission or main config). Use `\"$NONE$\"` for an empty sound"},{"name":"voice","type":"String","optional":false,"default":null,"description":"attaches a 3D sound from CfgSounds (mission or main config) to the object that activated the trigger and plays it as if say3D was used","types":["String"],"since":null,"text":"voice: String - attaches a 3D sound from CfgSounds (mission or main config) to the object that activated the trigger and plays it as if say3D was used"},{"name":"soundEnv","type":"String","optional":false,"default":null,"description":"plays an environmental sound from CfgEnvSounds (mission or main config)","types":["String"],"since":null,"text":"soundEnv: String - plays an environmental sound from CfgEnvSounds (mission or main config)"},{"name":"soundDet","type":"String","optional":false,"default":null,"description":"creates a dynamic sound object attached to a trigger defined in CfgSFX (mission or main config)","types":["String"],"since":null,"text":"soundDet: String - creates a dynamic sound object attached to a trigger defined in CfgSFX (mission or main config)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"[sound, voice, soundEnv, soundDet]","types":["Array"]}},{"syntax":"waypoint setSoundEffect [sound, voice]","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"sound","type":"String","optional":false,"default":null,"description":"plays a 2D sound as if playSound was used from CfgSounds (mission or main config)","types":["String"],"since":null,"text":"sound: String - plays a 2D sound as if playSound was used from CfgSounds (mission or main config)"},{"name":"voice","type":"String","optional":false,"default":null,"description":"attaches a 3D sound from CfgSounds (mission or main config) to the object that activated the trigger and plays it as if say3D was used","types":["String"],"since":null,"text":"voice: String - attaches a 3D sound from CfgSounds (mission or main config) to the object that activated the trigger and plays it as if say3D was used"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"[sound, voice]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trigger setSoundEffect [\"Alarm\", \"\", \"\", \"\"];\n```","code":["_trigger setSoundEffect [\"Alarm\", \"\", \"\", \"\"];"]},{"text":"```sqf\n[_group1, 2] setSoundEffect [\"Alarm\", \"\"];\n```","code":["[_group1, 2] setSoundEffect [\"Alarm\", \"\"];"]},{"text":"```sqf\n_trigger setSoundEffect [\"$NONE$\", \"Alarm\", \"\", \"\"];\n```","code":["_trigger setSoundEffect [\"$NONE$\", \"Alarm\", \"\", \"\"];"]},{"text":"```sqf\n_trigger setSoundEffect [\"$NONE$\", \"\", \"BattlefieldExplosions3\", \"\"];\n```","code":["_trigger setSoundEffect [\"$NONE$\", \"\", \"BattlefieldExplosions3\", \"\"];"]},{"text":"```sqf\n_trigger setSoundEffect [\"$NONE$\", \"\", \"\", \"Owl\"];\n```","code":["_trigger setSoundEffect [\"$NONE$\", \"\", \"\", \"Owl\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","setMusicEffect","setTitleEffect"],"notes":[],"categories":[]},{"name":"setSpeaker","operator":null,"title":"setSpeaker","type":"command","url":"https://community.bistudio.com/wiki/setSpeaker","revid":364908,"updated":"2024-06-30T09:06:33Z","groups":["Unit Identity","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the speaker of a person.","syntaxes":[{"syntax":"person setSpeaker speaker","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"},{"name":"speaker","type":"String","optional":false,"default":null,"description":"the used voice type, see Arma 3 Speakers","types":["String"],"since":null,"text":"speaker: String - the used voice type, see Arma 3 Speakers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"speaker","types":["String"]}}],"examples":[{"text":"```sqf\nunit1 setSpeaker \"Male02GRE\";\n```","code":["unit1 setSpeaker \"Male02GRE\";"]}],"multiplayer":"The command needs to run on every computer with exactly the same arguments, otherwise the speaking unit could appear silent on other PCs.","problems":null,"aliases":[],"see_also":["speaker","disableConversation","enableRadio","enableSentences","showSubtitles","setIdentity","setFace","hasCustomFace"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setSpeech","operator":null,"title":"setSpeech","type":"command","url":"https://community.bistudio.com/wiki/setSpeech","revid":319558,"updated":"2022-05-13T09:24:28Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.12"}],"since":{"game":"arma3","name":"Arma 3","version":"1.12"},"arma3_since":"1.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Add speech to location.","syntaxes":[{"syntax":"location setSpeech speech","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"speech","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"speech: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"speech","types":["String"]}}],"examples":[{"text":"```sqf\n_location setSpeech \"SomeSpeech\";\n```","code":["_location setSpeech \"SomeSpeech\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearestLocationWithDubbing"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Arma 3 version 1.12","Scripting Commands"]},{"name":"setSpeedMode","operator":null,"title":"setSpeedMode","type":"command","url":"https://community.bistudio.com/wiki/setSpeedMode","revid":336415,"updated":"2023-01-02T16:21:11Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets group speed mode. If unit is passed as param, unit's group is used. Mode may be one of:\n- **\"UNCHANGED\"** (unchanged)\n- **\"LIMITED\"** (half speed)\n- **\"NORMAL\"** (full speed, maintain formation)\n- **\"FULL\"** (do not wait for any other units in formation)","syntaxes":[{"syntax":"groupName setSpeedMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"groupName: Object or Group"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"groupName","types":["Object","Group"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_groupOne setSpeedMode \"LIMITED\";\n```","code":["_groupOne setSpeedMode \"LIMITED\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["speedMode","getSpeed","forceSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setStamina","operator":null,"title":"setStamina","type":"command","url":"https://community.bistudio.com/wiki/setStamina","revid":369292,"updated":"2024-09-03T18:42:49Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set units' stamina (seconds until depletion)","syntaxes":[{"syntax":"unit setStamina stamina","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"stamina","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"stamina: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"stamina","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setStamina 42;\n```","code":["player setStamina 42;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setStaminaScheme","getStamina","enableStamina","setFatigue","getFatigue","Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setStaminaScheme","operator":null,"title":"setStaminaScheme","type":"command","url":"https://community.bistudio.com/wiki/setStaminaScheme","revid":364828,"updated":"2024-06-16T09:53:48Z","groups":["Stamina System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.54"}],"since":{"game":"arma3","name":"Arma 3","version":"1.54"},"arma3_since":"1.54","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the scheme used for the Stamina system.","syntaxes":[{"syntax":"setStaminaScheme scheme","since":null,"effect":null,"exec":null,"params":[{"name":"scheme","type":"String Enum","optional":false,"default":null,"description":"String Enum\n- \"Normal\"\n- \"FastDrain\"\n- \"Exhausted\"\n- \"Default\"","types":["String"],"since":null,"text":"scheme: String Enum\n- \"Normal\"\n- \"FastDrain\"\n- \"Exhausted\"\n- \"Default\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"scheme","types":["String"]}}],"examples":[{"text":"```sqf\nsetStaminaScheme \"Default\";\n```","code":["setStaminaScheme \"Default\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Stamina"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Stamina System","Introduced with Arma 3 version 1.54","Scripting Commands"]},{"name":"setStatValue","operator":null,"title":"setStatValue","type":"command","url":"https://community.bistudio.com/wiki/setStatValue","revid":319644,"updated":"2022-05-13T09:24:37Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets a value to a given stat.\n\nA list of possible StatNames can be found here: Arma 3: Stat Names\n\nIts important to note that most Stats are restricted to scripts and missions in certain paths.\n\nFor example \"ExpWarlockDown\" is restricted to scripts in any subdirectory of `\"a3\\Missions_F_Exp\\Campaign\\Missions\\\"`","syntaxes":[{"syntax":"setStatValue [name, value]","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[name, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetStatValue [\"ExpWarlockDown\", 1]; // Unlocks the \"Warlock Down\" Steam achivement\n```","code":["setStatValue [\"ExpWarlockDown\", 1]; // Unlocks the \"Warlock Down\" Steam achivement"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getStatValue","Arma 3: Stat Names"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 1.18","Scripting Commands"]},{"name":"setSuppression","operator":null,"title":"setSuppression","type":"command","url":"https://community.bistudio.com/wiki/setSuppression","revid":376979,"updated":"2026-01-01T06:08:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.42"}],"since":{"game":"arma3","name":"Arma 3","version":"1.42"},"arma3_since":"1.42","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Sets the given suppression value for the given unit.","syntaxes":[{"syntax":"unit setSuppression value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"value","type":"Number in range 0..1","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nunit_1 setSuppression 1;\n```","code":["unit_1 setSuppression 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSuppression","suppressFor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.42","Scripting Commands"]},{"name":"setSystemOfUnits","operator":null,"title":"setSystemOfUnits","type":"command","url":"https://community.bistudio.com/wiki/setSystemOfUnits","revid":339090,"updated":"2023-04-26T10:54:08Z","groups":["System","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set system of units. This will only impact gauges from advanced flight model.\n\n> [!IMPORTANT]\n> This command is buggy: any value other than 0 (metric) will display both units at the same time.","syntaxes":[{"syntax":"setSystemOfUnits value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Number","optional":false,"default":null,"description":"possible values are:\n- 0 - metric\n- 1 - mixed\n- 2 - imperial","types":["Number"],"since":null,"text":"value: Number - possible values are:\n- 0 - metric\n- 1 - mixed\n- 2 - imperial"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nif (player in _myHelicopter) then { setSystemOfUnits 2; };\n```","code":["if (player in _myHelicopter) then { setSystemOfUnits 2; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Description.ext","Advanced Helicopter Flight Model in Arma3","systemOfUnits"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: System","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setTargetAge","operator":null,"title":"setTargetAge","type":"command","url":"https://community.bistudio.com/wiki/setTargetAge","revid":363641,"updated":"2024-04-09T21:20:52Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets how the target is known to the other centers. They behave like the target was seen age seconds ago.","syntaxes":[{"syntax":"object setTargetAge age","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"age","type":"String","optional":false,"default":null,"description":"can be:\n- \"ACTUAL\"\n- \"5 MIN\"\n- \"10 MIN\"\n- \"15 MIN\"\n- \"30 MIN\"\n- \"60 MIN\"\n- \"120 MIN\"\n- \"UNKNOWN\"","types":["String"],"since":null,"text":"age: String - can be:\n- \"ACTUAL\"\n- \"5 MIN\"\n- \"10 MIN\"\n- \"15 MIN\"\n- \"30 MIN\"\n- \"60 MIN\"\n- \"120 MIN\"\n- \"UNKNOWN\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"age","types":["String"]}}],"examples":[{"text":"```sqf\nplayer setTargetAge \"10 MIN\";\n```","code":["player setTargetAge \"10 MIN\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targets","targetsQuery","nearTargets","targetsAggregate","targetKnowledge","knowsAbout","reveal","forgetTarget","getHideFrom"],"notes":[],"categories":[]},{"name":"setTargetSize","operator":null,"title":"setTargetSize","type":"command","url":"https://community.bistudio.com/wiki/setTargetSize","revid":378903,"updated":"2026-08-11T14:56:33Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets target size (see `irTargetSize` and others from vehicle config) override on vehicle.\n\n> [!NOTE]\n> Passing an empty array returns the current values without modifying them, so this commands works as both getter and setter.","syntaxes":[{"syntax":"vehicle setTargetSize [visualTargetSize, irTargetSize, radarTargetSize]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"a transport vehicle","types":["Object"],"since":null,"text":"vehicle: Object - a transport vehicle"},{"name":"visualTargetSize","type":"Number","optional":false,"default":null,"description":"0..2 value, set to -1 to disable override and use config values","types":["Number"],"since":null,"text":"visualTargetSize: Number - 0..2 value, set to -1 to disable override and use config values"},{"name":"irTargetSize","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"irTargetSize: Number"},{"name":"radarTargetSize","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radarTargetSize: Number"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array with previous [visualTargetSize, irTargetSize, radarTargetSize] values"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[visualTargetSize, irTargetSize, radarTargetSize]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _previousSizes = vehicle player setTargetSize [0,0,0]; // set\n```","code":["private _previousSizes = vehicle player setTargetSize [0,0,0]; // set"]},{"text":"```sqf\nprivate _currentSizes = vehicle player setTargetSize []; // get\n```","code":["private _currentSizes = vehicle player setTargetSize []; // get"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getSensorTargets"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 2.22","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setTaskMarkerOffset","operator":null,"title":"setTaskMarkerOffset","type":"command","url":"https://community.bistudio.com/wiki/setTaskMarkerOffset","revid":377378,"updated":"2026-01-02T06:43:41Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the task marker position in model space.","syntaxes":[{"syntax":"obj setTaskState position","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"position","type":"PositionRelative","optional":false,"default":null,"description":null,"types":["PositionRelative"],"since":null,"text":"position: PositionRelative"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nplayer setTaskMarkerOffset [0,0.5,1];\n```","code":["player setTaskMarkerOffset [0,0.5,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskMarkerOffset"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"setTaskResult","operator":null,"title":"setTaskResult","type":"command","url":"https://community.bistudio.com/wiki/setTaskResult","revid":351333,"updated":"2023-11-27T09:50:12Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set a result of the task.","syntaxes":[{"syntax":"task setTaskResult [state,result]","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"[state,result]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","createSimpleTask","removeSimpleTask","setSimpleTaskDescription","setSimpleTaskDestination","setTaskState","taskState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTaskState","operator":null,"title":"setTaskState","type":"command","url":"https://community.bistudio.com/wiki/setTaskState","revid":349143,"updated":"2023-11-08T14:49:48Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the state of a given task.","syntaxes":[{"syntax":"task setTaskState state","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"},{"name":"state","type":"String","optional":false,"default":null,"description":"state value may be one of:\n- \"None\"\n- \"Created\"\n- \"Assigned\"\n- \"Succeeded\"\n- \"Failed\"\n- \"Canceled\"","types":["String"],"since":null,"text":"state: String - state value may be one of:\n- \"None\"\n- \"Created\"\n- \"Assigned\"\n- \"Succeeded\"\n- \"Failed\"\n- \"Canceled\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"task","types":["Task"]},"right":{"text":"state","types":["String"]}}],"examples":[{"text":"```sqf\n_tskKillSpongebob setTaskState \"Succeeded\";\n```","code":["_tskKillSpongebob setTaskState \"Succeeded\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","createSimpleTask","removeSimpleTask","setSimpleTaskDescription","setSimpleTaskDestination","setTaskResult","taskState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTerrainGrid","operator":null,"title":"setTerrainGrid","type":"command","url":"https://community.bistudio.com/wiki/setTerrainGrid","revid":364727,"updated":"2024-05-30T11:49:11Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Sets the desired terrain resolution in meters.","syntaxes":[{"syntax":"setTerrainGrid grid","since":null,"effect":null,"exec":null,"params":[{"name":"grid","type":"Number","optional":false,"default":null,"description":"for default landscapes the supported resolutions are:\n\n- **50** - smoothest, less lag\n- **25** - default in multiplayer\n- **12.5** - default in single player\n- **6.25**\n- **3.125** - bumpiest, higher lag\n\n> [!NOTE]\n> If unsupported resolution is selected, the nearest supported resolution is used instead. Higher number means less vertices are used for terrain rendering, making distant hills less smooth. Value 12.5 corresponds to selecting Terrain Detail Normal in Video options, 50 to Very Low, 3.125 to Very High. In older games like Armed Assault terrain resolution is fixed, determined by the world created.","types":["Number"],"since":null,"text":"grid: Number - for default landscapes the supported resolutions are:\n\n- **50** - smoothest, less lag\n- **25** - default in multiplayer\n- **12.5** - default in single player\n- **6.25**\n- **3.125** - bumpiest, higher lag\n\n> [!NOTE]\n> If unsupported resolution is selected, the nearest supported resolution is used instead. Higher number means less vertices are used for terrain rendering, making distant hills less smooth. Value 12.5 corresponds to selecting Terrain Detail Normal in Video options, 50 to Very Low, 3.125 to Very High. In older games like Armed Assault terrain resolution is fixed, determined by the world created."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"grid","types":["Number"]}}],"examples":[{"text":"```sqf\nsetTerrainGrid 12.5;\n```","code":["setTerrainGrid 12.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTerrainGrid","setViewDistance","viewDistance","setDetailMapBlendPars","getObjectViewDistance","setObjectViewDistance"],"notes":[{"user":"Hardrock","date":"2006-08-04T12:02:00Z","text":"*Notes from before the conversion:*\n\nThis is like opening up your video preferences and changing \"terrain detail\", i.e.: setTerrainGrid 50 = lowest detail\nsetTerrainGrid 3.125 = highest detail It is similar to the command setViewDistance."},{"user":"WGL.Q","date":"2007-08-18T09:46:00Z","text":"*Effects on grass:*\n- 50: disables/removes grass altogether.\n- 25: grass is visible.\n- Lower values make grass drawn a bit further at distance. However the effect is decreasing rapidly: Grass radius of 25 is 100%. 12.5 is now like 100% + 20%,  6.25 is like 100% + 20% + 5% and 3.125 is  100% + 20% + 5% + 1%. Note these are estimates!\n\n[Demo Mission Test_VD_TD.Sara.rar](http://ofpc.de/wargames//files/arma/biki/Test_VD_TD.Sara.rar): ViewDistance and TerrainGrid can be changed via RadioTriggers"},{"user":"Rommel","date":"2019-12-15T05:50:00Z","text":"*Arma 2 Supported Reso:*\n\nIn Arma 2 you are not stuck to 50, 25, 12 etc. 45 is a lower setting than 25!"},{"user":"Galzohar","date":"2013-03-13T17:05:00Z","text":"*Arma 3 Multiplayer default:*\n\nSome testing indicates that the default value for Arma 3 multiplayer is 10 - just like before. 10 is between \"Normal\" and \"High\".\n\nAn user's terrain detail setting is ignored in multiplayer just like in Arma 2."},{"user":"MrPineapple","date":"2014-11-19T17:44:00Z","text":"**TerrainGrid values for Arma 3 1.34:**\n\nLow = 50 (NoGrass)\n\nStandard = 25\n\nHigh = 12.5\n\nVery High = 6.25\n\nUltra = 3.125"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTerrainHeight","operator":null,"title":"setTerrainHeight","type":"command","url":"https://community.bistudio.com/wiki/setTerrainHeight","revid":377594,"updated":"2026-01-02T06:59:43Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Set the current terrain's altitude on provided location(s).\n\n> [!IMPORTANT]\n> - Heightmap changes:\n>   - are internally converted (rounded) to heightmap coordinates\n>   - are stored in the JIP queue\n>   - are **not** removed from the JIP queue if the values are set back to terrain's default value\n>   - are updated in the JIP queue for updated positions **if** the same group of positions are edited (order does not matter, but amount does);\n> editing positions by terrain *sections* is good for multiplayer optimisation (see #Example 2)\n>   - are **not** updated and sent twice (old one then new one) if position edits are not exactly the same (see point above and #Example 2).\n> - Edited terrain heights are **not** saved inside savegames, they need to be restored manually on savegame load.\n> - Known issues:\n>   - Terrain sections can become invisible if the change is too extreme\n>   - Walking on the edge of extreme height changes can catapult the player away","syntaxes":[{"syntax":"setTerrainHeight [positionAndAltitudeArray, adjustObjects]","since":null,"effect":null,"exec":null,"params":[{"name":"positionAndAltitudeArray","type":"Array of PositionASL","optional":false,"default":null,"description":"[[x1, y1, newASLHeight1], [x2, y2, newASLHeight2], ...]","types":["Array","PositionASL"],"since":null,"text":"positionAndAltitudeArray: Array of PositionASL - [[x1, y1, newASLHeight1], [x2, y2, newASLHeight2], ...]"},{"name":"adjustObjects","type":"Boolean","optional":true,"default":"true","description":"if true then objects on modified points are moved up/down to keep the same ATL height\n\n> [!IMPORTANT]\n> **All** objects above modified terrain will be adjusted, even flying ones.","types":["Boolean"],"since":null,"text":"adjustObjects: Boolean - (Optional, default true) if true then objects on modified points are moved up/down to keep the same ATL height\n\n> [!IMPORTANT]\n> **All** objects above modified terrain will be adjusted, even flying ones."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[positionAndAltitudeArray, adjustObjects]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _fnc_flattenTerrain =\n{\n    params [\"_start\", \"_a\", \"_b\", \"_h\"];\n    private _newPositions = [];\n\n    for \"_xStep\" from 0 to _a do\n    {\n        for \"_yStep\" from 0 to _b do\n        {\n            private _newHeight = _start vectorAdd [_xStep, _yStep, 0];\n            _newHeight set [2, _h];\n            _newPositions pushBack _newHeight;\n        };\n    };\n\n    _newPositions;\n};\n\nprivate _desiredTerrainHeight = 150;\nprivate _positionsAndHeights = [getPosWorld player, 50, 50, _desiredTerrainHeight] call _fnc_flattenTerrain;\nsetTerrainHeight [_positionsAndHeights, true];\n```","code":["private _fnc_flattenTerrain =\n{\n\tparams [\"_start\", \"_a\", \"_b\", \"_h\"];\n\tprivate _newPositions = [];\n\n\tfor \"_xStep\" from 0 to _a do\n\t{\n\t\tfor \"_yStep\" from 0 to _b do\n\t\t{\n\t\t\tprivate _newHeight = _start vectorAdd [_xStep, _yStep, 0];\n\t\t\t_newHeight set [2, _h];\n\t\t\t_newPositions pushBack _newHeight;\n\t\t};\n\t};\n\n\t_newPositions;\n};\n\nprivate _desiredTerrainHeight = 150;\nprivate _positionsAndHeights = [getPosWorld player, 50, 50, _desiredTerrainHeight] call _fnc_flattenTerrain;\nsetTerrainHeight [_positionsAndHeights, true];"]},{"text":"Bad example:\n\n```sqf\n// first update\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 25], [1000, 1005, 25], [1005, 1005, 25]]];\n\n// second update - this will make the JIP queue keep both messages\nsetTerrainHeight [[[1005, 1000, 50]]];\n```\n\nGood example:\n\n```sqf\n// first update\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 25], [1000, 1005, 25], [1005, 1005, 25]]];\n\n// second update - this will update the JIP queue properly\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 50], [1000, 1005, 25], [1005, 1005, 25]]];\n```","code":["// first update\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 25], [1000, 1005, 25], [1005, 1005, 25]]];\n\n// second update - this will make the JIP queue keep both messages\nsetTerrainHeight [[[1005, 1000, 50]]];","// first update\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 25], [1000, 1005, 25], [1005, 1005, 25]]];\n\n// second update - this will update the JIP queue properly\nsetTerrainHeight [[[1000, 1000, 25], [1005, 1000, 50], [1000, 1005, 25], [1005, 1005, 25]]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTerrainInfo","getTerrainHeight"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"setText","operator":null,"title":"setText","type":"command","url":"https://community.bistudio.com/wiki/setText","revid":322962,"updated":"2022-06-28T21:42:51Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the text associated with a location. This text will be displayed on the game map at the location's position.","syntaxes":[{"syntax":"location setText text","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\nmyLocation setText \"Rahmadi Village\";\n```","code":["myLocation setText \"Rahmadi Village\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["text","createLocation"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTimeMultiplier","operator":null,"title":"setTimeMultiplier","type":"command","url":"https://community.bistudio.com/wiki/setTimeMultiplier","revid":378416,"updated":"2026-04-04T08:44:07Z","groups":["Time","Mission Information","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Sets a time multiplier for in-game time. The command range is capped at 0.1 - 120 to avoid performance problems.","syntaxes":[{"syntax":"setTimeMultiplier value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":null,"optional":false,"default":null,"description":"Number in range 0.1 .. 120","types":["Number"],"since":null,"text":"value: Number in range 0.1 .. 120"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nsetTimeMultiplier 60;\n```","code":["setTimeMultiplier 60;"]},{"text":"```sqf\nsetTimeMultiplier 0.5;\n```","code":["setTimeMultiplier 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["timeMultiplier","skipTime","setAccTime","accTime","time","serverTime","date","dayTime"],"notes":[{"user":"Hypoxic125","date":"2023-02-14T17:07:34Z","text":"**timeMultiplier = 24 / IRL Hours per Game Day**\n\nDesired: 4 IRL Hours for Full In-Game Day\n\ntimeMultiplier = 24 / 4\n\ntimeMultiplier = 6"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Mission Information","Command Group: Time","Introduced with Arma 3 version 1.26","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"setTIParameter","operator":null,"title":"setTIParameter","type":"command","url":"https://community.bistudio.com/wiki/setTIParameter","revid":330291,"updated":"2022-08-30T11:36:06Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the provided Thermal Imaging parameter's value.\n\n> [!IMPORTANT]\n> The settings are **not** saved in savegame and must be reapplied after loading.","syntaxes":[{"syntax":"setTIParameter [paramName, newValue]","since":null,"effect":null,"exec":null,"params":[{"name":"paramName","type":"String","optional":false,"default":null,"description":"the parameter name. See getTIParameters for a list of possible values","types":["String"],"since":null,"text":"paramName: String - the parameter name. See getTIParameters for a list of possible values"},{"name":"newValue","type":"Number","optional":false,"default":null,"description":"the set number","types":["Number"],"since":null,"text":"newValue: Number - the set number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[paramName, newValue]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetTIParameter [\"OutputRangeStart\", 0];\nsetTIParameter [\"OutputRangeWidth\", 1];\n```","code":["setTIParameter [\"OutputRangeStart\", 0];\nsetTIParameter [\"OutputRangeWidth\", 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTIParameters","setCamUseTI","disableTIEquipment"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"setTitleEffect","operator":null,"title":"setTitleEffect","type":"command","url":"https://community.bistudio.com/wiki/setTitleEffect","revid":377582,"updated":"2026-01-02T06:56:39Z","groups":["Triggers","Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines the title effect to show on activation via [Type, Effect, Text] where\n\n'Type'\n\nThe title effect does not disappear on deactivation, this should be done manually if required.","syntaxes":[{"syntax":"triggerOrWaypoint setTitleEffect [type, effect, text]","since":null,"effect":null,"exec":null,"params":[{"name":"triggerOrWaypoint","type":"Object or Waypoint","optional":false,"default":null,"description":null,"types":["Object","Waypoint"],"since":null,"text":"triggerOrWaypoint: Object or Waypoint"},{"name":"type","type":"String","optional":false,"default":null,"description":"defines Title Effect Type when not NONE, can be one of:\n- \"NONE\"\n- \"OBJECT\" - *text* defines the shown object , a subclass of `CfgTitles` (see cutObj)\n- \"RES\" - *text* defines a resource class, a subclass of RscTitles (see cutRsc)\n- \"TEXT\" - *text* defines text string to show (see cutText)","types":["String"],"since":null,"text":"type: String - defines Title Effect Type when not NONE, can be one of:\n- \"NONE\"\n- \"OBJECT\" - *text* defines the shown object , a subclass of `CfgTitles` (see cutObj)\n- \"RES\" - *text* defines a resource class, a subclass of RscTitles (see cutRsc)\n- \"TEXT\" - *text* defines text string to show (see cutText)"},{"name":"effect","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"effect: String"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"triggerOrWaypoint","types":["Object","Waypoint"]},"right":{"text":"[type, effect, text]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trigger setTitleEffect [\"TEXT\", \"PLAIN DOWN\", \"Hello world.\"];\n```","code":["_trigger setTitleEffect [\"TEXT\", \"PLAIN DOWN\", \"Hello world.\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","setSoundEffect","setMusicEffect"],"notes":[],"categories":[]},{"name":"setTowParent","operator":null,"title":"setTowParent","type":"command","url":"https://community.bistudio.com/wiki/setTowParent","revid":373896,"updated":"2025-06-26T11:04:54Z","groups":["PhysX","Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"| Simulation | Towable | Can Tow |\n|---|---|---|\n| CarX | ✓ | ✓ |\n| TankX | ✗ | ✓ |\n| AirplaneX | ✗ | ✗ |\n| BoatX | ✗ | ✗ |\n\nAllows a vehicle to be towed by another. This loosens the towed vehicle's brakes and turns its steering wheels toward the towing vehicle.\nSupposed to be used together with a rope connecting both vehicles.","syntaxes":[{"syntax":"towedVehicle setTowParent towingVehicle","since":null,"effect":null,"exec":null,"params":[{"name":"towedVehicle","type":"Object","optional":false,"default":null,"description":"vehicle of type CarX (no tanks, no aircrafts, no boats)","types":["Object"],"since":null,"text":"towedVehicle: Object - vehicle of type CarX (no tanks, no aircrafts, no boats)"},{"name":"towingVehicle","type":"Object","optional":false,"default":null,"description":"vehicle of type CarX or TankX (no aircrafts, no boats)","types":["Object"],"since":null,"text":"towingVehicle: Object - vehicle of type CarX or TankX (no aircrafts, no boats)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"towedVehicle","types":["Object"]},"right":{"text":"towingVehicle","types":["Object"]}}],"examples":[{"text":"```sqf\n{ moveOut _x } forEach crew _towedVehicle;    // make sure nobody is in the towed vehicle\n_towedVehicle lock true;                    // make sure everybody stays out of it\nropeCreate [_bobcat, [0,-5,0], _towedVehicle, [0,2,0]];\n_towedVehicle setTowParent _bobcat;\n```","code":["{ moveOut _x } forEach crew _towedVehicle;\t// make sure nobody is in the towed vehicle\n_towedVehicle lock true;\t\t\t\t\t// make sure everybody stays out of it\nropeCreate [_bobcat, [0,-5,0], _towedVehicle, [0,2,0]];\n_towedVehicle setTowParent _bobcat;"]}],"multiplayer":"> [!WARNING]\n> If a player enters the towing vehicle, the towed one will try to change its locality to be local to that player. This might be problematic if there is another player already in the towed vehicle. It is recommended to not have anyone in the towed vehicle!","problems":null,"aliases":[],"see_also":["getTowParent","ropeCreate"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: PhysX","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 2.06","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setTrafficDensity","operator":null,"title":"setTrafficDensity","type":"command","url":"https://community.bistudio.com/wiki/setTrafficDensity","revid":310000,"updated":"2022-05-05T12:20:39Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the density of ambient cars in a rectangle (in cars per kilometer). \n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"setTrafficDensity [density, xMin, xMax, zMin, zMax]","since":null,"effect":null,"exec":null,"params":[{"name":"density","type":"Number","optional":false,"default":null,"description":"density (in cars per kilometer)","types":["Number"],"since":null,"text":"density: Number - density (in cars per kilometer)"},{"name":"xMin","type":"Number","optional":false,"default":null,"description":"western border of the affected rectangle","types":["Number"],"since":null,"text":"xMin: Number - western border of the affected rectangle"},{"name":"xMax","type":"Number","optional":false,"default":null,"description":"eastern border of the affected rectangle","types":["Number"],"since":null,"text":"xMax: Number - eastern border of the affected rectangle"},{"name":"zMin","type":"Number","optional":false,"default":null,"description":"southern border of the affected rectangle","types":["Number"],"since":null,"text":"zMin: Number - southern border of the affected rectangle"},{"name":"zMax","type":"Number","optional":false,"default":null,"description":"northern border of the affected rectangle","types":["Number"],"since":null,"text":"zMax: Number - northern border of the affected rectangle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[density, xMin, xMax, zMin, zMax]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetTrafficDensity [40, 31000, 32000, 30000, 32000];\n```","code":["setTrafficDensity [40, 31000, 32000, 30000, 32000];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableTraffic","setTrafficDistance","setTrafficGap","setTrafficSpeed"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Environment","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTrafficDistance","operator":null,"title":"setTrafficDistance","type":"command","url":"https://community.bistudio.com/wiki/setTrafficDistance","revid":341171,"updated":"2023-05-13T22:13:32Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set maximum ambient traffic draw distance (in 2D). \n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"setTrafficDistance distance","since":null,"effect":null,"exec":null,"params":[{"name":"distance","type":"Number","optional":false,"default":null,"description":"draw distance (in meter)","types":["Number"],"since":null,"text":"distance: Number - draw distance (in meter)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\nsetTrafficDistance 1000;\n```","code":["setTrafficDistance 1000;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableTraffic","setTrafficDensity","setTrafficGap","setTrafficSpeed"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Environment","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTrafficGap","operator":null,"title":"setTrafficGap","type":"command","url":"https://community.bistudio.com/wiki/setTrafficGap","revid":319775,"updated":"2022-05-13T09:24:52Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set the average gap between ambient cars in a rectangle (in meters). \n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"setTrafficGap [gap, xMin, xMax, zMin, zMax]","since":null,"effect":null,"exec":null,"params":[{"name":"gap","type":"Number","optional":false,"default":null,"description":"average gap between ambient cars (in meters)","types":["Number"],"since":null,"text":"gap: Number - average gap between ambient cars (in meters)"},{"name":"xMin","type":"Number","optional":false,"default":null,"description":"western border of the affected rectangle","types":["Number"],"since":null,"text":"xMin: Number - western border of the affected rectangle"},{"name":"xMax","type":"Number","optional":false,"default":null,"description":"eastern border of the affected rectangle","types":["Number"],"since":null,"text":"xMax: Number - eastern border of the affected rectangle"},{"name":"zMin","type":"Number","optional":false,"default":null,"description":"southern border of the affected rectangle","types":["Number"],"since":null,"text":"zMin: Number - southern border of the affected rectangle"},{"name":"zMax","type":"Number","optional":false,"default":null,"description":"northern border of the affected rectangle","types":["Number"],"since":null,"text":"zMax: Number - northern border of the affected rectangle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[gap, xMin, xMax, zMin, zMax]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetTrafficGap [50, 31000, 32500, 28000, 32000];\n```","code":["setTrafficGap [50, 31000, 32500, 28000, 32000];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableTraffic","setTrafficDensity","setTrafficDistance","setTrafficSpeed"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Environment","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTrafficSpeed","operator":null,"title":"setTrafficSpeed","type":"command","url":"https://community.bistudio.com/wiki/setTrafficSpeed","revid":310009,"updated":"2022-05-05T12:20:43Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.01"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set ambient traffic speed in a rectangle (in kilometers per hour). \n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"setTrafficSpeed [speed, xMin, xMax, zMin, zMax]","since":null,"effect":null,"exec":null,"params":[{"name":"speed","type":"Number","optional":false,"default":null,"description":"traffic speed (in kilometers per hour)","types":["Number"],"since":null,"text":"speed: Number - traffic speed (in kilometers per hour)"},{"name":"xMin","type":"Number","optional":false,"default":null,"description":"western border of the affected rectangle","types":["Number"],"since":null,"text":"xMin: Number - western border of the affected rectangle"},{"name":"xMax","type":"Number","optional":false,"default":null,"description":"eastern border of the affected rectangle","types":["Number"],"since":null,"text":"xMax: Number - eastern border of the affected rectangle"},{"name":"zMin","type":"Number","optional":false,"default":null,"description":"southern border of the affected rectangle","types":["Number"],"since":null,"text":"zMin: Number - southern border of the affected rectangle"},{"name":"zMax","type":"Number","optional":false,"default":null,"description":"northern border of the affected rectangle","types":["Number"],"since":null,"text":"zMax: Number - northern border of the affected rectangle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[speed, xMin, xMax, zMin, zMax]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetTrafficSpeed [50, _xMin, _xMax, _zMin, _zMax];\n```","code":["setTrafficSpeed [50, _xMin, _xMax, _zMin, _zMax];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableTraffic","setTrafficDensity","setTrafficDistance","setTrafficGap"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: Environment","Introduced with Take On Helicopters version 1.01","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerActivation","operator":null,"title":"setTriggerActivation","type":"command","url":"https://community.bistudio.com/wiki/setTriggerActivation","revid":378817,"updated":"2026-07-01T00:11:02Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Defines the trigger activation type.\n\nSee ArmA:Mission Editor - Triggers for a thorough overview of triggers and its fields for activation, effects, etc.","syntaxes":[{"syntax":"trigger setTriggerActivation [by, type, repeating, persistent]","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger object","types":["Object"],"since":null,"text":"trigger: Object - trigger object"},{"name":"by","type":"String","optional":false,"default":null,"description":"who activates trigger. Can be `\"NONE\"`, or:\n\n| Side | Radio | Object | Status |\n|---|---|---|---|\n| - `\"EAST\"`<br>- `\"WEST\"`<br>- `\"GUER\"`<br>- `\"CIV\"`<br>- `\"LOGIC\"`<br>- `\"ANY\"`<br>- Arma 3 v1.68 `\"ANYPLAYER\"` | - `\"ALPHA\"`<br>- `\"BRAVO\"`<br>- `\"CHARLIE\"`<br>- `\"DELTA\"`<br>- `\"ECHO\"`<br>- `\"FOXTROT\"`<br>- `\"GOLF\"`<br>- `\"HOTEL\"`<br>- `\"INDIA\"`<br>- `\"JULIET\"` | - `\"STATIC\"`<br>- `\"VEHICLE\"`<br>- `\"GROUP\"`<br>- `\"LEADER\"`<br>- `\"MEMBER\"` | - `\"WEST SEIZED\"`<br>- `\"EAST SEIZED\"`<br>- `\"GUER SEIZED\"` |","types":["String"],"since":null,"text":"by: String - who activates trigger. Can be `\"NONE\"`, or:\n\n| Side | Radio | Object | Status |\n|---|---|---|---|\n| - `\"EAST\"`<br>- `\"WEST\"`<br>- `\"GUER\"`<br>- `\"CIV\"`<br>- `\"LOGIC\"`<br>- `\"ANY\"`<br>- Arma 3 v1.68 `\"ANYPLAYER\"` | - `\"ALPHA\"`<br>- `\"BRAVO\"`<br>- `\"CHARLIE\"`<br>- `\"DELTA\"`<br>- `\"ECHO\"`<br>- `\"FOXTROT\"`<br>- `\"GOLF\"`<br>- `\"HOTEL\"`<br>- `\"INDIA\"`<br>- `\"JULIET\"` | - `\"STATIC\"`<br>- `\"VEHICLE\"`<br>- `\"GROUP\"`<br>- `\"LEADER\"`<br>- `\"MEMBER\"` | - `\"WEST SEIZED\"`<br>- `\"EAST SEIZED\"`<br>- `\"GUER SEIZED\"` |"},{"name":"type","type":"String","optional":false,"default":null,"description":"how trigger is it activated. Can be:\n\n| Presence | Detection |\n|---|---|\n| - `\"PRESENT\"`<br>- `\"NOT PRESENT\"` | - `\"WEST D\"`<br>- `\"EAST D\"`<br>- `\"GUER D\"`<br>- `\"CIV D\"` |","types":["String"],"since":null,"text":"type: String - how trigger is it activated. Can be:\n\n| Presence | Detection |\n|---|---|\n| - `\"PRESENT\"`<br>- `\"NOT PRESENT\"` | - `\"WEST D\"`<br>- `\"EAST D\"`<br>- `\"GUER D\"`<br>- `\"CIV D\"` |"},{"name":"repeating","type":"Boolean","optional":false,"default":null,"description":"activation can happen repeatedly","types":["Boolean"],"since":null,"text":"repeating: Boolean - activation can happen repeatedly"},{"name":"persistent (Optional)","type":"Boolean","optional":false,"default":null,"description":"when false stops persistent condition execution and vehicle list building on non-repeating trigger; is ignored in radio and repeating triggers. Default: true","types":["Boolean"],"since":"arma3 2.24","text":"persistent (Optional): Boolean - when false stops persistent condition execution and vehicle list building on non-repeating trigger; is ignored in radio and repeating triggers. Default: true"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"[by, type, repeating, persistent]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trigger setTriggerActivation [\"WEST\", \"EAST D\", true];\n```","code":["_trigger setTriggerActivation [\"WEST\", \"EAST D\", true];"]}],"multiplayer":"Activation changes are local.","problems":null,"aliases":[],"see_also":["triggerActivation","triggerActivated","createTrigger","setTriggerArea","setTriggerStatements","setTriggerText","setTriggerTimeout","setTriggerType","triggerAttachVehicle","triggerAttachObject","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerArea","operator":null,"title":"setTriggerArea","type":"command","url":"https://community.bistudio.com/wiki/setTriggerArea","revid":364460,"updated":"2024-05-16T20:41:48Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Defines the area monitored by the given trigger. The area could be either rectangular or elliptical.\n\n> [!NOTE]\n> Just like with a and b dimensions, c dimension will alter area in opposite directions from the trigger position along z axis. Therefore if the trigger position is on the surface, half of the trigger area will be above the surface and half below. To place the whole area above the surface, adjust trigger position (move it up c meters). If c is not specified or <= 0, the trigger's height is considered infinite like 2D triggers.","syntaxes":[{"syntax":"trigger setTriggerArea [a, b, angle, isRectangle, c]","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"object of the type \"EmptyDetector\"","types":["Object"],"since":null,"text":"trigger: Object - object of the type \"EmptyDetector\""},{"name":"a","type":"Number","optional":false,"default":null,"description":"trigger area X size / 2, in meters","types":["Number"],"since":null,"text":"a: Number - trigger area X size / 2, in meters"},{"name":"b","type":"Number","optional":false,"default":null,"description":"trigger area Y size / 2, in meters","types":["Number"],"since":null,"text":"b: Number - trigger area Y size / 2, in meters"},{"name":"angle","type":"Number","optional":false,"default":null,"description":"trigger area rotation in degrees","types":["Number"],"since":null,"text":"angle: Number - trigger area rotation in degrees"},{"name":"isRectangle","type":"Boolean","optional":false,"default":null,"description":"true if rectangle","types":["Boolean"],"since":null,"text":"isRectangle: Boolean - true if rectangle"},{"name":"c","type":"Number","optional":true,"default":"-1","description":"trigger area Z size / 2, in meters. -1 for infinite height","types":["Number"],"since":"arma3 1.60","text":"c: Number - (Optional, default -1) trigger area Z size / 2, in meters. -1 for infinite height"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"[a, b, angle, isRectangle, c]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trigger setTriggerArea [100, 50, 45, false];\n```","code":["_trigger setTriggerArea [100, 50, 45, false];"]},{"text":"```sqf\n_trigger setTriggerArea [100, 50, 45, false, 100];\n```","code":["_trigger setTriggerArea [100, 50, 45, false, 100];"]},{"text":"```sqf\n_trg = createTrigger [\"EmptyDetector\", getPos player, false];\n_trg setTriggerArea [5, 5, 0, false];\n_trg setTriggerActivation [\"CIV\", \"PRESENT\", true];\n_trg setTriggerStatements [\"this\", \"hint 'Civilian near player'\", \"hint 'no civilian near'\"];\n```","code":["_trg = createTrigger [\"EmptyDetector\", getPos player, false];\n_trg setTriggerArea [5, 5, 0, false];\n_trg setTriggerActivation [\"CIV\", \"PRESENT\", true];\n_trg setTriggerStatements [\"this\", \"hint 'Civilian near player'\", \"hint 'no civilian near'\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerArea","createTrigger","setTriggerActivation","setTriggerStatements","setTriggerText","setTriggerTimeout","setTriggerType","inArea","inAreaArray","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerInterval","operator":null,"title":"setTriggerInterval","type":"command","url":"https://community.bistudio.com/wiki/setTriggerInterval","revid":353312,"updated":"2024-03-15T17:11:45Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.98"}],"since":{"game":"arma3","name":"Arma 3","version":"1.98"},"arma3_since":"1.98","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the interval in seconds for trigger condition check.\n\n> [!NOTE]\n> Triggers are configured to check condition approx. every 0.5 second by default. This command allows either to slow down or to speed up default check interval per trigger. Setting interval to 0 will make the trigger check its condition every frame. However, when trigger is attached to some object, the trigger will inherit the simulation frequency of the object it is attached to. This command cannot change the interval of the attached trigger. The trigger can also be \"frozen\" with enableSimulation command.","syntaxes":[{"syntax":"trigger setTriggerInterval interval","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger object","types":["Object"],"since":null,"text":"trigger: Object - trigger object"},{"name":"interval","type":"Number","optional":false,"default":null,"description":"interval in seconds with which trigger condition is checked","types":["Number"],"since":null,"text":"interval: Number - interval in seconds with which trigger condition is checked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"interval","types":["Number"]}}],"examples":[{"text":"```sqf\n_trigger setTriggerInterval 5;\n```","code":["_trigger setTriggerInterval 5;"]}],"multiplayer":"Interval changes are local.","problems":null,"aliases":[],"see_also":["triggerInterval","triggerActivation","triggerActivated","createTrigger","setTriggerActivation","setTriggerArea","setTriggerStatements","setTriggerText","setTriggerTimeout","setTriggerType","triggerAttachVehicle","triggerAttachObject","enableSimulation","simulationEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 3 version 1.98","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setTriggerStatements","operator":null,"title":"setTriggerStatements","type":"command","url":"https://community.bistudio.com/wiki/setTriggerStatements","revid":378812,"updated":"2026-06-30T19:31:33Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Defines trigger condition, activation and deactivation statements. Trigger condition has to return Boolean. true will activate the trigger, false will deactivate it (only if activation is set to repeat). thisList returns the same result as list command, which includes all entities in the trigger area that are capable of activating the trigger. Dead entities are excluded as well as crew in vehicles, vehicles themselves are included.","syntaxes":[{"syntax":"trigger setTriggerStatements [condition, activation, deactivation]","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger object","types":["Object"],"since":null,"text":"trigger: Object - trigger object"},{"name":"condition","type":"String","optional":false,"default":null,"description":"code containing trigger condition. Special variables available here:\n- this (Boolean) - detection event\n- thisTrigger (Object) - trigger instance\n- thisList (Array) - array of all detected entities","types":["String"],"since":null,"text":"condition: String - code containing trigger condition. Special variables available here:\n- this (Boolean) - detection event\n- thisTrigger (Object) - trigger instance\n- thisList (Array) - array of all detected entities"},{"name":"activation","type":"String","optional":false,"default":null,"description":"code that is executed when the trigger is activated. Special variables available here:\n- thisTrigger (Object) - trigger instance\n- thisList (Array) - array of all detected entities\n- thisActivator (Object) Arma 3 v2.22 -  what or who activated the trigger, default: thisTrigger","types":["String"],"since":null,"text":"activation: String - code that is executed when the trigger is activated. Special variables available here:\n- thisTrigger (Object) - trigger instance\n- thisList (Array) - array of all detected entities\n- thisActivator (Object) Arma 3 v2.22 -  what or who activated the trigger, default: thisTrigger"},{"name":"deactivation","type":"String","optional":false,"default":null,"description":"code that is executed when the trigger is deactivated. Special variable available here:\n- thisTrigger (Object) - trigger instance","types":["String"],"since":null,"text":"deactivation: String - code that is executed when the trigger is deactivated. Special variable available here:\n- thisTrigger (Object) - trigger instance"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"[condition, activation, deactivation]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trg setTriggerStatements [\"this\", \"hint 'trigger on'\", \"hint 'trigger off'\"];\n```","code":["_trg setTriggerStatements [\"this\", \"hint 'trigger on'\", \"hint 'trigger off'\"];"]},{"text":"Since Arma 3 v2.22:\n\n```sqf\n_trg setTriggerStatements [\"this\", \"hint ('Activated by ' + str thisActivator)\", \"\"];\n```","code":["_trg setTriggerStatements [\"this\", \"hint ('Activated by ' + str thisActivator)\", \"\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerStatements","createTrigger","setTriggerActivation","setTriggerArea","setTriggerText","setTriggerTimeout","setTriggerType","Magic Variables","thisList","thisTrigger","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[{"user":"Scifer","date":"2011-03-14T20:52:00Z","text":"An array with three arguments is mandatory for this function."},{"user":"Heeeere's Johnny!","date":"2014-09-16T17:41:00Z","text":"Magic variable *thisList* does not contain dead units."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerText","operator":null,"title":"setTriggerText","type":"command","url":"https://community.bistudio.com/wiki/setTriggerText","revid":319703,"updated":"2022-05-13T09:24:44Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the text label attached to the trigger object. This is used for example as a radio slot label for radio activated triggers.","syntaxes":[{"syntax":"trigger setTriggerText text","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\ntrigger setTriggerText \"Call for support\";\n```","code":["trigger setTriggerText \"Call for support\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerText","createTrigger","setTriggerActivation","setTriggerArea","setTriggerStatements","setTriggerTimeout","setTriggerType","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerTimeout","operator":null,"title":"setTriggerTimeout","type":"command","url":"https://community.bistudio.com/wiki/setTriggerTimeout","revid":337985,"updated":"2023-02-23T21:11:05Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Defines the time between condition satisfaction and trigger activation (randomly from min to max, with an average value mid). If the last argument is true, the condition must be fullfilled all the time.\n\nFor a normal trigger, *min*, *mid* and *max* are used to generate random duration according to [Gaussian Distribution](https://en.wikipedia.org/wiki/Normal_distribution) (ref: Technically, it is a rescaled [Bates distribution](https://en.wikipedia.org/wiki/Bates_distribution) with n = 4. The distribution is split in two at its midpoint and scaled linearly such that its maximum lies at the specified midpoint.). For a \"Seized\" type of trigger, the duration value is generated using side ruling power","syntaxes":[{"syntax":"trigger setTriggerTimeout [min, mid, max, interruptable]","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"min","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"min: Number"},{"name":"mid","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"mid: Number"},{"name":"max","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"max: Number"},{"name":"interruptable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"interruptable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"[min, mid, max, interruptable]","types":["Array"]}}],"examples":[{"text":"```sqf\n_trigger setTriggerTimeout [5, 10, 7, false];\n```","code":["_trigger setTriggerTimeout [5, 10, 7, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerTimeout","triggerTimeoutCurrent","createTrigger","setTriggerActivation","setTriggerArea","setTriggerStatements","setTriggerText","setTriggerType","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTriggerType","operator":null,"title":"setTriggerType","type":"command","url":"https://community.bistudio.com/wiki/setTriggerType","revid":323090,"updated":"2022-06-28T21:43:14Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the type of action processed by the trigger after activation (no action, a waypoints switch or an end of mission):\n\n- `\"NONE\"`\n- `\"EAST G\"` - Guarded by OPFOR - (It is better to use createGuardedPoint instead)\n- `\"WEST G\"` - Guarded by BLUFOR - (It is better to use createGuardedPoint instead)\n- `\"GUER G\"` - Guarded by Independent - (It is better to use createGuardedPoint instead)\n- `\"SWITCH\"` - Switch waypoints/break loop (see Triggers)\n- `\"END1\"` - End #1\n- `\"END2\"` - End #2\n- `\"END3\"` - End #3\n- `\"END4\"` - End #4\n- `\"END5\"` - End #5\n- `\"END6\"` - End #6\n- `\"LOOSE\"` - (Meant to say LOSE but is misspelt in the game engine).\n- `\"WIN\"` - (Not in editor. Valid enum name but when set, defaults to `\"END1\"`)","syntaxes":[{"syntax":"trigger setTriggerType action","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"},{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\n_trigger setTriggerType \"END1\";\n```","code":["_trigger setTriggerType \"END1\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerType","createTrigger","setTriggerActivation","setTriggerArea","setTriggerStatements","setTriggerText","setTriggerTimeout","createGuardedPoint","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setTurretLimits","operator":null,"title":"setTurretLimits","type":"command","url":"https://community.bistudio.com/wiki/setTurretLimits","revid":379081,"updated":"2026-09-27T07:57:22Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the rotation and elevation limits for the given turret. The limits are relative to model orientation of the turret. For example to allow 360 degree turning it is enough to set turn limits to (-180, 180). The limits can only be set within the limits defined in config and cannot exceed them. To reset to config defaults pass the turret argument only (Example 2).","syntaxes":[{"syntax":"vehicle setTurretLimits [turret, minTurn, maxTurn, minElev, maxElev, soft]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle the turret belongs to","types":["Object"],"since":null,"text":"vehicle: Object - vehicle the turret belongs to"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":"turret path","types":["Turret Path"],"since":null,"text":"turret: Turret Path - turret path"},{"name":"minTurn","type":"Number","optional":false,"default":null,"description":"from 0 to -angle in degrees (left)","types":["Number"],"since":null,"text":"minTurn: Number - from 0 to -angle in degrees (left)"},{"name":"maxTurn","type":"Number","optional":false,"default":null,"description":"from 0 to +angle in degrees (right)","types":["Number"],"since":null,"text":"maxTurn: Number - from 0 to +angle in degrees (right)"},{"name":"minElev","type":"Number","optional":false,"default":null,"description":"from 0 to -angle in degrees (down)","types":["Number"],"since":null,"text":"minElev: Number - from 0 to -angle in degrees (down)"},{"name":"maxElev","type":"Number","optional":false,"default":null,"description":"from 0 to +angle in degrees (up)","types":["Number"],"since":null,"text":"maxElev: Number - from 0 to +angle in degrees (up)"},{"name":"soft","type":"Boolean","optional":true,"default":null,"description":"true to gradually move turret to the new limits (if turret is currenty oriented out of new limts). false to snap to the new limits. Default: false","types":["Boolean"],"since":"arma3 2.22","text":"soft: Boolean - (Optional) true to gradually move turret to the new limits (if turret is currenty oriented out of new limts). false to snap to the new limits. Default: false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turret, minTurn, maxTurn, minElev, maxElev, soft]","types":["Array"]}},{"syntax":"vehicle setTurretLimits [turret]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle the turret belongs to","types":["Object"],"since":null,"text":"vehicle: Object - vehicle the turret belongs to"},{"name":"turret","type":"Turret Path","optional":false,"default":null,"description":"turret path (to reset)","types":["Turret Path"],"since":null,"text":"turret: Turret Path - turret path (to reset)"}],"returns":null,"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[turret]","types":["Array"]}},{"syntax":"","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":null,"operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nm2 setTurretLimits [[0], -45, 45, -10, 10];\n```","code":["m2 setTurretLimits [[0], -45, 45, -10, 10];"]},{"text":"```sqf\nm2 setTurretLimits [[0]]; //reset\n```","code":["m2 setTurretLimits [[0]]; //reset"]},{"text":"```sqf\nm2 setTurretLimits [[0], -45, 45, -10, 10, true];\n```","code":["m2 setTurretLimits [[0], -45, 45, -10, 10, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTurretLimits","setTurretOpticsMode","turretLocal","selectWeaponTurret","lockCameraTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.12","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setTurretOpticsMode","operator":null,"title":"setTurretOpticsMode","type":"command","url":"https://community.bistudio.com/wiki/setTurretOpticsMode","revid":377497,"updated":"2026-01-02T06:49:23Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set the current optics mode of the optics in the turret occupied by the specified unit. Alternatively, you can specify a vehicle and turret path instead of a unit. Optic modes refer to the different fields of view (FOV) or zoom levels of an optic.","syntaxes":[{"syntax":"obj setTurretOpticsMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"mode","type":"Number","optional":false,"default":null,"description":"optic mode index","types":["Number"],"since":null,"text":"mode: Number - optic mode index"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"mode","types":["Number"]}},{"syntax":"obj setTurretOpticsMode [turretPath, opticModeIndex]","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"obj: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"opticModeIndex","type":"Number","optional":false,"default":null,"description":"optic mode index","types":["Number"],"since":null,"text":"opticModeIndex: Number - optic mode index"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"[turretPath, opticModeIndex]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setTurretOpticsMode 0;\n```","code":["player setTurretOpticsMode 0;"]},{"text":"```sqf\nmyTank setTurretOpticsMode [[-1], 1];\n```","code":["myTank setTurretOpticsMode [[-1], 1];"]},{"text":"```sqf\nmyAircraft setTurretOpticsMode [[0, 0], 0];\n```","code":["myAircraft setTurretOpticsMode [[0, 0], 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getTurretOpticsMode","turretLocal","selectWeaponTurret","getPilotCameraOpticsMode","setPilotCameraOpticsMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setType","operator":null,"title":"setType","type":"command","url":"https://community.bistudio.com/wiki/setType","revid":323021,"updated":"2022-06-28T21:43:07Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes a location to the specified class. Location classes are defined in CfgLocationTypes.","syntaxes":[{"syntax":"location setType name","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"location","types":["Location"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nmyLocation setType \"RockArea\";\n```","code":["myLocation setType \"RockArea\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["type"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setUnconscious","operator":null,"title":"setUnconscious","type":"command","url":"https://community.bistudio.com/wiki/setUnconscious","revid":310114,"updated":"2022-05-05T12:25:30Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"In Arma 2 and since Arma 3 v1.64, this command sets unit into incapacitated state.\n\nlifeState results:\n- Arma 2: \"UNCONSCIOUS\"\n- Arma 3: \"INCAPACITATED\"\n\n> [!NOTE]\n> **Arma 3:** The unit goes in ragdoll mode and animation played while incapacitated depends on the injuries received.","syntaxes":[{"syntax":"unit setUnconscious set","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"set","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"set: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"set","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_unit setUnconscious true;\n```","code":["_unit setUnconscious true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lifeState","incapacitatedState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setUnitAbility","operator":null,"title":"setUnitAbility","type":"command","url":"https://community.bistudio.com/wiki/setUnitAbility","revid":369306,"updated":"2024-09-03T18:42:54Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets skill of given unit. Unlike setSkill, setUnitAbility can set values > 1. Even though the skill command will correctly return set value, the actual unit ability will be capped to max available.","syntaxes":[{"syntax":"unit setUnitAbility value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n_unit setUnitAbility 1;\n```","code":["_unit setUnitAbility 1;"]},{"text":"```sqf\nbob setUnitAbility -log 0;\nhint str skill bob; //1.#INF\n```","code":["bob setUnitAbility -log 0;\nhint str skill bob; //1.#INF"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["skill","setSkill","CfgAISkill","Combat Modes"],"notes":[],"categories":["AI","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setUnitCombatMode","operator":null,"title":"setUnitCombatMode","type":"command","url":"https://community.bistudio.com/wiki/setUnitCombatMode","revid":322932,"updated":"2022-06-28T21:42:41Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets **unit's** combat mode (engagement rules). For AI group combat mode see setCombatMode. Mode may be one of the following:\n- `\"BLUE\"` : Never fire, keep formation\n- `\"GREEN\"` : Hold fire, keep formation\n- `\"WHITE\"` : Hold fire, engage at will/loose formation\n- `\"YELLOW\"` : Fire at will, keep formation\n- `\"RED\"` : Fire at will, engage at will/loose formation\nSee Combat Modes for more information on combat modes.","syntaxes":[{"syntax":"unit setUnitCombatMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_unit setUnitCombatMode \"YELLOW\";\n```","code":["_unit setUnitCombatMode \"YELLOW\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitCombatMode","setCombatMode","combatMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"setUnitFreefallHeight","operator":null,"title":"setUnitFreefallHeight","type":"command","url":"https://community.bistudio.com/wiki/setUnitFreefallHeight","revid":364759,"updated":"2024-06-07T23:35:13Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets minimum freefall height AGL per unit, at which the unit assumes HALO pose. Engine default is 100m. Use -1 to reset the height to default.","syntaxes":[{"syntax":"unit setUnitFreefallHeight minHeight","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"unit: Object - unit"},{"name":"minHeight","type":"Number","optional":false,"default":null,"description":"min freefall height, -1 to set default","types":["Number"],"since":null,"text":"minHeight: Number - min freefall height, -1 to set default"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"minHeight","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setUnitFreefallHeight 1000;\n```","code":["player setUnitFreefallHeight 1000;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUnitFreefallInfo","getPosASL","ASLToAGL"],"notes":[{"user":"Hypoxic125","date":"2024-06-07T23:35:13Z","text":"For player units, you must reapply setUnitFreefallHeight upon respawning."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.10","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setUnitLoadout","operator":null,"title":"setUnitLoadout","type":"command","url":"https://community.bistudio.com/wiki/setUnitLoadout","revid":370162,"updated":"2024-11-02T23:29:35Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Creates a loadout from given inventory structure and applies it to a unit.\nWhen String for class name is supplied, the command will search `CfgVehicles` for the given class in order to extract the loadout from config.\nIf Config is given, it will search given config (including mission config) for the loadout information.\nIn either case, the config should contain the following entries, which is standard for any unit class, for example:\n\n```cpp\nclass MyLoadout\n{\n    uniformClass = \"U_B_CombatUniform_mcam\";\n    backpack = \"B_AssaultPack_mcamo\";\n    linkedItems[] = { \"V_PlateCarrier1_rgr\", \"H_HelmetB\", \"ItemCompass\", \"ItemWatch\", \"ItemRadio\", \"NVGoggles\" };\n    weapons[] = { \"arifle_MX_ACO_pointer_F\", \"hgun_P07_F\" };\n    items[] = { \"FirstAidKit\", \"FirstAidKit\", \"FirstAidKit\" };\n    magazines[] = {\n        \"30Rnd_65x39_caseless_mag\", \"16Rnd_9x21_Mag\", \"SmokeShell\",\n        \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n        \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n        \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n        \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\",\n        \"HandGrenade\", \"HandGrenade\", \"HandGrenade\", \"HandGrenade\"\n    };\n};\n```\n\n> [!IMPORTANT]\n> Since Arma 3 v2.20 if the command is executed while the unit is in the process of switching weapon, the command will be aborted. To check if unit is switching weapon use isSwitchingWeapon.","syntaxes":[{"syntax":"unit setUnitLoadout loadout","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"loadout","type":"Array","optional":false,"default":null,"description":"Unit Loadout Array","types":["Array"],"since":null,"text":"loadout: Array - Unit Loadout Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"loadout","types":["Array"]}},{"syntax":"unit setUnitLoadout [loadout, fullMagazines]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"loadout","type":"Array","optional":false,"default":null,"description":"Unit Loadout Array","types":["Array"],"since":null,"text":"loadout: Array - Unit Loadout Array"},{"name":"fullMagazines","type":"Boolean","optional":false,"default":null,"description":"partially emptied magazines will be refilled when the loadout is applied","types":["Boolean"],"since":null,"text":"fullMagazines: Boolean - partially emptied magazines will be refilled when the loadout is applied"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[loadout, fullMagazines]","types":["Array"]}},{"syntax":"unit setUnitLoadout name","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":"class name (see description)","types":["String"],"since":null,"text":"name: String - class name (see description)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"name","types":["String"]}},{"syntax":"unit setUnitLoadout config","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"config","type":"Config","optional":false,"default":null,"description":"config class (see description)","types":["Config"],"since":null,"text":"config: Config - config class (see description)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"config","types":["Config"]}}],"examples":[{"text":"```sqf\n_unit setUnitLoadout \"B_Soldier_F\";                                        // by class name\n_unit setUnitLoadout (configFile >> \"CfgVehicles\" >> \"B_Soldier_F\");    // by config entry\n_unit setUnitLoadout (missionConfigFile >> \"MyLoadout\");                // (also works for mission config)\n_unit setUnitLoadout getUnitLoadout _otherUnit;                            // by loadout array\n```","code":["_unit setUnitLoadout \"B_Soldier_F\";\t\t\t\t\t\t\t\t\t\t// by class name\n_unit setUnitLoadout (configFile >> \"CfgVehicles\" >> \"B_Soldier_F\");\t// by config entry\n_unit setUnitLoadout (missionConfigFile >> \"MyLoadout\");\t\t\t\t// (also works for mission config)\n_unit setUnitLoadout getUnitLoadout _otherUnit;\t\t\t\t\t\t\t// by loadout array"]},{"text":"```sqf\nplayer_2 setUnitLoadout (getUnitLoadout player_1);            // Copies loadout from player_1 and applies it to player_2\nplayer_2 setUnitLoadout [getUnitLoadout player_1, true];    // Copies loadout from player_1 and applies it to player_2 while topping up all magazines\n```","code":["player_2 setUnitLoadout (getUnitLoadout player_1);\t\t\t// Copies loadout from player_1 and applies it to player_2\nplayer_2 setUnitLoadout [getUnitLoadout player_1, true];\t// Copies loadout from player_1 and applies it to player_2 while topping up all magazines"]},{"text":"Strip unit of everything:\n\n```sqf\n_unit setUnitLoadout (configFile >> \"EmptyLoadout\");\n```","code":["_unit setUnitLoadout (configFile >> \"EmptyLoadout\");"]},{"text":"Make sure the unit is not switching weapon:\n\n```sqf\nplayer spawn \n{\n    waitUntil {!isSwitchingWeapon _this};\n    _this setUnitLoadout (configFile >> \"EmptyLoadout\");\n};\n```","code":["player spawn \n{\n\twaitUntil {!isSwitchingWeapon _this};\n\t_this setUnitLoadout (configFile >> \"EmptyLoadout\");\n};"]}],"multiplayer":null,"problems":"> [!IMPORTANT]\n> If this command is used on the player, it makes the inventory window bug (if opened) - vest and backpack tabs disappear. Closing and re-opening the inventory solves the issue.","aliases":[],"see_also":["getUnitLoadout","isSwitchingWeapon"],"notes":[{"user":"Demellion","date":"2019-12-17T23:08:00Z","text":"Empty or used magazines in loadouts will be refilled under specific circumstance, even if the refill argument is false. This seems to happen if amount of used magazines is 2 or more.\n\n```sqf\nplayer setUnitLoadout [\n    [\"arifle_MX_ACO_pointer_F\", \"\", \"acc_pointer_IR\", \"optic_Aco\", [], [], \"\"],\n    [],\n    [\"hgun_P07_F\", \"\", \"\", \"\", [\"16Rnd_9x21_Mag\", 16], [], \"\"],\n    [\"U_B_CombatUniform_mcam\", [[\"30Rnd_65x39_caseless_mag\", 1, 1]]],\n    [\"V_PlateCarrier1_rgr\", []],\n    [\"B_AssaultPack_mcamo_Ammo\", []],\n    \"H_HelmetB_grass\", \"\", [], [\"ItemMap\", \"\", \"ItemRadio\", \"ItemCompass\", \"ItemWatch\", \"NVGoggles\"]\n];\n```\n\nWill result in 30Rnd magazine with one bullet in it.\n\n```sqf\nplayer setUnitLoadout [\n    [\"arifle_MX_ACO_pointer_F\", \"\", \"acc_pointer_IR\", \"optic_Aco\", [], [], \"\"],\n    [],\n    [\"hgun_P07_F\", \"\", \"\", \"\", [\"16Rnd_9x21_Mag\", 16], [], \"\"],\n    [\"U_B_CombatUniform_mcam\", [[\"30Rnd_65x39_caseless_mag\", 2, 1]]],\n    [\"V_PlateCarrier1_rgr\", []],\n    [\"B_AssaultPack_mcamo_Ammo\", []],\n    \"H_HelmetB_grass\", \"\", [], [\"ItemMap\", \"\", \"ItemRadio\", \"ItemCompass\", \"ItemWatch\", \"NVGoggles\"]\n];\n```\n\nWill result in 2 magazines but full, 30 rounds in it. This applies to any magazines count >2. They will never be with specified amount of rounds, even if you force the refill argument to false."},{"user":"Andrew_S90","date":"2020-10-23T21:16:00Z","text":"Here is a command I wrote up that provides a fix for the ammo bug described by Demellion above.\nhttps://pastebin.com/SHX41Jkk\nPass a loadout to your compiled command and it will provide one back that will not refill ammo."},{"user":"POLPOX","date":"2022-08-23T08:27:09Z","text":"```sqf\nplayer setUnitLoadout [\n    nil, nil, nil, nil, nil,\n    [\"B_Bergen_sgg\", nil],\n    nil, nil, nil, nil\n];\n```\n\nYou can use nil to skip some desired parameter. The skipped part will be ignored and remain the same with old loadout.\n\nThis method is *very slightly* faster than the latter method:\n\n```sqf\nprivate _loadout = getUnitLoadout player;\n_loadout#5 set [0, \"B_Bergen_mcamo_F\"];\nplayer setUnitLoadout _loadout;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setUnitPos","operator":null,"title":"setUnitPos","type":"command","url":"https://community.bistudio.com/wiki/setUnitPos","revid":369297,"updated":"2024-09-03T18:42:52Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set unit position rules. This command will not change the stance of the human player, even though it will change the output of unitPos command. To change player stance use playAction or playActionNow:\n\n```sqf\nplayer playAction \"PlayerProne\"; // DOWN\nplayer playAction \"PlayerStand\"; // UP\nplayer playAction \"PlayerCrouch\"; // MIDDLE\n```","syntaxes":[{"syntax":"unit setUnitPos mode","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be:\n- \"DOWN\" - Unit goes prone and stays prone.\n- \"UP\" - Unit stands and stays standing.\n- \"MIDDLE\" - Kneel Position. Armed Assault v1.04 - Unit will not kneel if it is unarmed\n- \"AUTO\" - Unit chooses mode according to circumstances.","types":["String"],"since":null,"text":"mode: String - can be:\n- \"DOWN\" - Unit goes prone and stays prone.\n- \"UP\" - Unit stands and stays standing.\n- \"MIDDLE\" - Kneel Position. Armed Assault v1.04 - Unit will not kneel if it is unarmed\n- \"AUTO\" - Unit chooses mode according to circumstances."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_soldier setUnitPos \"UP\";\n```","code":["_soldier setUnitPos \"UP\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitPosWeak","unitPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setUnitPosWeak","operator":null,"title":"setUnitPosWeak","type":"command","url":"https://community.bistudio.com/wiki/setUnitPosWeak","revid":369195,"updated":"2024-09-03T10:34:47Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.04"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set unit position rules. This command is the lowest level of priority for setting unit position and to be used in scripted\nFSM's. Priorities are:\n1. Unit pos commanded (from the commanding menu, higher priority).\n1. Unit pos scripted (from setUnitPos scripting command, medium priority).\n1. Unit pos FSM / **setUnitPosWeak** (used in the formation FSM, lowest priority).","syntaxes":[{"syntax":"unit setUnitPosWeak mode","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be:\n- \"DOWN\" - Unit goes prone and stays prone.\n- \"UP\" - Unit stands and stays standing.\n- \"MIDDLE\" - Kneel Position. Armed Assault v1.04 - Unit will not kneel if it is unarmed\n- \"AUTO\" - Unit chooses mode according to circumstances.","types":["String"],"since":null,"text":"mode: String - can be:\n- \"DOWN\" - Unit goes prone and stays prone.\n- \"UP\" - Unit stands and stays standing.\n- \"MIDDLE\" - Kneel Position. Armed Assault v1.04 - Unit will not kneel if it is unarmed\n- \"AUTO\" - Unit chooses mode according to circumstances."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n_soldier disableAI \"FSM\";\n_soldier setUnitPosWeak \"DOWN\";\n```","code":["_soldier disableAI \"FSM\";\n_soldier setUnitPosWeak \"DOWN\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["FSM","doFSM","setUnitPos","unitPos"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.04","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setUnitRank","operator":null,"title":"setUnitRank","type":"command","url":"https://community.bistudio.com/wiki/setUnitRank","revid":340312,"updated":"2023-04-29T17:03:09Z","groups":["Unit Identity"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Sets rank of given unit.\n\nPossible rank values, and the associated rating that is **set** (not added, the value replaces previous rating) with it:\n\n| Ranks | PRIVATE | CORPORAL | SERGEANT | LIEUTENANT | CAPTAIN | MAJOR | COLONEL |  |\n|---|---|---|---|---|---|---|---|---|\n| Ratings | ArmA<br>Arma 2<br>Arma 2:OA<br>Take On Helicopters | 0 | 500 | 1500 | 2500 | 3500 | 5000 | 7500 |\n| Arma 3 (ca 2015) | 0 | 50 | 150 | 250 | 350 | 500 | 750 |  |\n| Arma 3 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |  |\n\n> [!NOTE]\n> **Arma 3:** Before Arma 3 v1.68 and in previous titles, this command was Global Argument Local Effect.","syntaxes":[{"syntax":"unitName setUnitRank rank","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"rank","type":"String","optional":false,"default":null,"description":"see above. If a wrong string is provided, the command errors and reverts to using \"PRIVATE\"","types":["String"],"since":null,"text":"rank: String - see above. If a wrong string is provided, the command errors and reverts to using \"PRIVATE\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"rank","types":["String"]}}],"examples":[{"text":"```sqf\nplayer setUnitRank \"COLONEL\";\n```","code":["player setUnitRank \"COLONEL\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ArmA: Armed Assault: Rating Values","rating","addRating","rank","setRank"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Identity","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setUnitRecoilCoefficient","operator":null,"title":"setUnitRecoilCoefficient","type":"command","url":"https://community.bistudio.com/wiki/setUnitRecoilCoefficient","revid":341018,"updated":"2023-05-13T22:06:26Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Proportionaly increase/decrease unit's recoil. Drives muzzle up with every shot when supplied positive number and down when negative. 0 cancels recoil.","syntaxes":[{"syntax":"unitName setUnitRecoilCoefficient coefficient","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"coefficient","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"coefficient: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"coefficient","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setUnitRecoilCoefficient 10;\n```","code":["player setUnitRecoilCoefficient 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitRecoilCoefficient"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setUnitTrait","operator":null,"title":"setUnitTrait","type":"command","url":"https://community.bistudio.com/wiki/setUnitTrait","revid":379077,"updated":"2026-09-26T23:03:38Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enables or disables a trait or alters a trait of the given unit. Unit traits consist of unit abilities, which are Booleans and modifiers, which are Numbers. Custom trait can only be a bool.\n\n> [!NOTE]\n> The command can also be used on vehicles (and drones), and it will get applied to the effectiveCommander of the vehicle. In addition, if the effectiveCommander has a trait, it will get applied to the entire vehicle (for example, the vehicle can become harder to spot due to low **camouflageCoef**)\n\nAbilities:\n- Boolean **engineer** - Ability to partially repair vehicles with toolkit, equivalent to  in CfgVehicles\n- Boolean **explosiveSpecialist** - Ability to defuse mines with toolkit, equivalent to  in CfgVehicles\n- Boolean **medic** - Ability to treat self and others with medikit, equivalent to  in CfgVehicles\n- Boolean **UAVHacker** - Ability to hack enemy and friendly drones, equivalent to  in CfgVehicles\nModifiers:\n- Number **audibleCoef** - A lower value means the unit is harder to hear\n- Number **camouflageCoef** - A lower value means the unit is harder to spot\n- Number **loadCoef** - Equipment weight multiplier affecting stamina regeneration and max stamina\n- Number **staminaDrainCoef** - Since Arma 3 v2.22, Influences how quickly stamina is drained. **Do not set negative values!**","syntaxes":[{"syntax":"unit setUnitTrait [skillName, value, isCustom]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"the unit whose trait should be set","types":["Object"],"since":null,"text":"unit: Object - the unit whose trait should be set"},{"name":"skillName","type":"String","optional":false,"default":null,"description":"name of the skill","types":["String"],"since":null,"text":"skillName: String - name of the skill"},{"name":"value","type":"Boolean or Number","optional":false,"default":null,"description":"value (see above)","types":["Boolean","Number"],"since":null,"text":"value: Boolean or Number - value (see above)"},{"name":"isCustom","type":"Boolean","optional":true,"default":null,"description":"Must be set to true in case of custom","types":["Boolean"],"since":null,"text":"isCustom: Boolean - (Optional) Must be set to true in case of custom"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[skillName, value, isCustom]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setUnitTrait [\"Medic\", true];\n```","code":["player setUnitTrait [\"Medic\", true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUnitTrait","getAllUnitTraits"],"notes":[{"user":"R3vo","date":"2016-04-27T18:12:00Z","text":"The higher the value for the loadCoef the less stamina a unit has. Negative values will dramatically increase the stamina actually to a point where it extends the stamina bar."},{"user":"Midnight","date":"2017-10-20T05:49:00Z","text":"The `explosiveSpecialist` trait can defuse mines (i.e. satchel charges), whilst the engineer trait alone cannot."},{"user":"Honger","date":"2026-09-26T23:03:38Z","text":"Setting **staminaDrainCoef** to a negative value will gradually replenish stamina/reduce fatigue when running/sprinting. Walking or standing will not be affected."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.58","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setUnloadInCombat","operator":null,"title":"setUnloadInCombat","type":"command","url":"https://community.bistudio.com/wiki/setUnloadInCombat","revid":336388,"updated":"2022-12-31T20:54:06Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.36"}],"since":{"game":"arma3","name":"Arma 3","version":"1.36"},"arma3_since":"1.36","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets whether or not cargo or turret units *should* get out of vehicle when in combat. If **true**, vehicle will stop and units will dismount. Vehicle must be local. The command resets last time unit had reacted to an enemy as well as forcing orderGetIn false if canUnloadInCombat is permitted by config","syntaxes":[{"syntax":"vehicle setUnloadInCombat [allowCargo, allowTurrets]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"allowCargo","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allowCargo: Boolean"},{"name":"allowTurrets","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"allowTurrets: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[allowCargo, allowTurrets]","types":["Array"]}}],"examples":[{"text":"```sqf\n_veh setUnloadInCombat [true, false];\n```","code":["_veh setUnloadInCombat [true, false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUnloadInCombat","canUnloadInCombat","allowCrewInImmobile","isAllowedCrewInImmobile"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 1.36","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setUserActionText","operator":null,"title":"setUserActionText","type":"command","url":"https://community.bistudio.com/wiki/setUserActionText","revid":369154,"updated":"2024-09-03T10:34:39Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Changes user added action (see addAction) menu item text.","syntaxes":[{"syntax":"object setUserActionText [actionIndex, textMenu, textWindowBackground, textWindowForeground]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object the action is added to","types":["Object"],"since":null,"text":"object: Object - object the action is added to"},{"name":"actionIndex","type":"Number","optional":false,"default":null,"description":"action id returned by addAction","types":["Number"],"since":null,"text":"actionIndex: Number - action id returned by addAction"},{"name":"textMenu","type":"String or Structured Text","optional":false,"default":null,"description":"text title shown in scroll action menu","types":["String","Structured Text"],"since":null,"text":"textMenu: String or Structured Text - text title shown in scroll action menu"},{"name":"textWindowBackground","type":"String or Structured Text","optional":true,"default":"\"\"","description":"background text","types":["String","Structured Text"],"since":"arma3 1.62","text":"textWindowBackground: String or Structured Text - (Optional, default \"\") background text"},{"name":"textWindowForeground","type":"String or Structured Text","optional":true,"default":"\"\"","description":"foreground text","types":["String","Structured Text"],"since":"arma3 1.62","text":"textWindowForeground: String or Structured Text - (Optional, default \"\") foreground text"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[actionIndex, textMenu, textWindowBackground, textWindowForeground]","types":["Array"]}}],"examples":[{"text":"```sqf\n_id = player addAction [\"Hello\", \"\"];\nplayer setUserActionText [_id, \"Good Bye\"];\n```","code":["_id = player addAction [\"Hello\", \"\"];\nplayer setUserActionText [_id, \"Good Bye\"];"]},{"text":"```sqf\n_id = billboard addAction [\"Some Action\", {}];\nbillboard setUserActionText [\n    _id, \n    \"Some Action\", \n    \"<t color='#ff0000'>Background-----------------</t><br>Multiline<br>Multiline<br>Multiline<br>. . .\", \n    \"<t color='#00ff00'>-----------------Foreground</t>\"\n];\n```","code":["_id = billboard addAction [\"Some Action\", {}];\nbillboard setUserActionText [\n\t_id, \n\t\"Some Action\", \n\t\"<t color='#ff0000'>Background-----------------</t><br>Multiline<br>Multiline<br>Multiline<br>. . .\", \n\t\"<t color='#00ff00'>-----------------Foreground</t>\"\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["actionIDs","actionParams","addAction","inGameUISetEventHandler","showHUD","inputAction","removeAction","removeAllActions","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setUserMFDText","operator":null,"title":"setUserMFDText","type":"command","url":"https://community.bistudio.com/wiki/setUserMFDText","revid":309223,"updated":"2022-05-04T10:05:28Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.78"}],"since":{"game":"arma3","name":"Arma 3","version":"1.78"},"arma3_since":"1.78","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Stored user text value in MFD, limit is 50, user0...user49","syntaxes":[{"syntax":"vehicle setUserMFDText [index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle with MFD","types":["Object"],"since":null,"text":"vehicle: Object - vehicle with MFD"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"},{"name":"value","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"value: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[index, value]","types":["Array"]}}],"examples":[{"text":"```sqf\n_vehicle setUserMFDText [0, \"some text\"];\n```","code":["_vehicle setUserMFDText [0, \"some text\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUserMFDText","setUserMFDValue","getUserMFDValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Arma 3 version 1.78","Scripting Commands"]},{"name":"setUserMFDValue","operator":null,"title":"setUserMFDValue","type":"command","url":"https://community.bistudio.com/wiki/setUserMFDValue","revid":373032,"updated":"2025-03-18T16:50:36Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"When MFD is using user controllers, this command can set values on them. For example, MFD config for Blackfoot has an entry\n\n```cpp\n// ...\nclass Draw\n{\n    alpha = \"user3\";\n    color[] = {\"user0\",\"user1\",\"user2\"};\n// ...\n```\n\nwhich could control color of the MFD. See Example 2-3-4 on how to set different colors of the Blackfoot MFD\n\n> [!NOTE]\n> **Since Arma 3 v2.20:** Vehicles can be configured to support more than 50 user sources with \"mfdMaxUserValues = 50\" entry in CfgVehicles config class. As of 2.20 the limit is 256. It is recommended to configure this also for vehicles that use fewer MFD sources, it improves performance to only set as many as are being used.","syntaxes":[{"syntax":"vehicle setUserMFDValue [index, value]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"an vehicle with MFD","types":["Object"],"since":null,"text":"vehicle: Object - an vehicle with MFD"},{"name":"index","type":"Number","optional":false,"default":null,"description":"index of custom MFD user actions","types":["Number"],"since":null,"text":"index: Number - index of custom MFD user actions"},{"name":"value","type":"Number","optional":false,"default":null,"description":"value which should custom source return in MFD","types":["Number"],"since":null,"text":"value: Number - value which should custom source return in MFD"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[index, value]","types":["Array"]}}],"examples":[{"text":"```sqf\nBIS_Plane setUserMFDValue [0,1]; // user0 in MFD will return 1\n```","code":["BIS_Plane setUserMFDValue [0,1]; // user0 in MFD will return 1"]},{"text":"Set MFD Red:\n\n```sqf\nBlackfoot setUserMFDValue [0, 1];    // \"user0\" - 1\nBlackfoot setUserMFDValue [1, 0];    // \"user1\" - 0\nBlackfoot setUserMFDValue [2, 0];    // \"user2\" - 0\nBlackfoot setUserMFDValue [3, 1];    // \"user3\" - 1\n```","code":["Blackfoot setUserMFDValue [0, 1];\t// \"user0\" - 1\nBlackfoot setUserMFDValue [1, 0];\t// \"user1\" - 0\nBlackfoot setUserMFDValue [2, 0];\t// \"user2\" - 0\nBlackfoot setUserMFDValue [3, 1];\t// \"user3\" - 1"]},{"text":"Set MFD pale Blue:\n\n```sqf\nBlackfoot setUserMFDValue [0, 0];    // \"user0\" - 0\nBlackfoot setUserMFDValue [1, 0];    // \"user1\" - 0\nBlackfoot setUserMFDValue [2, 1];    // \"user2\" - 1\nBlackfoot setUserMFDValue [3, 0.1];    // \"user3\" - 0.1\n```","code":["Blackfoot setUserMFDValue [0, 0];\t// \"user0\" - 0\nBlackfoot setUserMFDValue [1, 0];\t// \"user1\" - 0\nBlackfoot setUserMFDValue [2, 1];\t// \"user2\" - 1\nBlackfoot setUserMFDValue [3, 0.1];\t// \"user3\" - 0.1"]},{"text":"Hide MFD:\n\n```sqf\nBlackfoot setUserMFDValue [3, 0];    // \"user3\" - 0\n```","code":["Blackfoot setUserMFDValue [3, 0];\t// \"user3\" - 0"]},{"text":"Arma 3 v1.72 multiple changes at once:\n\n```sqf\nmyPlane setUserMFDValue [10, 16, 404, 64];    // \"user10\" - 16\n                                            // \"user11\" - 404\n                                            // \"user12\" - 64\n```","code":["myPlane setUserMFDValue [10, 16, 404, 64];\t// \"user10\" - 16\n\t\t\t\t\t\t\t\t\t\t\t// \"user11\" - 404\n\t\t\t\t\t\t\t\t\t\t\t// \"user12\" - 64"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUserMFDValue","setUserMFDText","getUserMFDText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setVariable","operator":null,"title":"setVariable","type":"command","url":"https://community.bistudio.com/wiki/setVariable","revid":369355,"updated":"2024-09-03T18:43:04Z","groups":["Variables","Namespaces","Multiplayer"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Set variable to given value in the variable space of given element. Can be used to broadcast variables over the network.\n\nTo remove a variable, set it to nil (see #Example 5) - note that this does not work on Object and scripted Location namespaces (the variable will be set to nil but will remain listed by allVariables).\n\n> [!WARNING]\n> missionNamespace, uiNamespace, parsingNamespace and profileNamespace variables **cannot** be named as commands - e.g `missionNamespace setVariable [\"west\", 123];` conflicts with the west command and will result in a `Reserved variable in expression` error, west being a scripting command (other namespaces do not have such limitation).\n> See also all available script commands.","syntaxes":[{"syntax":"varspace setVariable [name, value, public]","since":null,"effect":null,"exec":null,"params":[{"name":"varspace","type":null,"optional":false,"default":null,"description":"variable space in which variable can be set. Can be one of:\n- Namespace\n- Object\n  - ✓ Arma 3 v2.10 `CfgAmmo` Objects (bullets, mines etc)\n  - ✗ `CfgNonAIVehicles` Objects (butterflies, proxies etc - `EmptyDetector`s (triggers) work)\n  - ✗ `1. local` Objects (`1. lightpoint`, `1. soundsource` etc - see createVehicleLocal)\n- Group\n- Location (Arma 3 v2.10 scripted ones only)\n- Arma 2 v1.00 Team Member\n- Arma 2 v1.00 Task - *value* will actually be set on the Task's FSM **if** it exists.\n- Arma 3 v0.50 Control\n- Arma 3 v0.50 Display","types":[],"since":null,"text":"varspace: variable space in which variable can be set. Can be one of:\n- Namespace\n- Object\n  - ✓ Arma 3 v2.10 `CfgAmmo` Objects (bullets, mines etc)\n  - ✗ `CfgNonAIVehicles` Objects (butterflies, proxies etc - `EmptyDetector`s (triggers) work)\n  - ✗ `1. local` Objects (`1. lightpoint`, `1. soundsource` etc - see createVehicleLocal)\n- Group\n- Location (Arma 3 v2.10 scripted ones only)\n- Arma 2 v1.00 Team Member\n- Arma 2 v1.00 Task - *value* will actually be set on the Task's FSM **if** it exists.\n- Arma 3 v0.50 Control\n- Arma 3 v0.50 Display"},{"name":"name","type":"String","optional":false,"default":null,"description":"variable name (Identifier)","types":["String"],"since":null,"text":"name: String - variable name (Identifier)"},{"name":"value","type":"Anything","optional":false,"default":null,"description":"variable value","types":["Anything"],"since":null,"text":"value: Anything - variable value"},{"name":"public","type":null,"optional":true,"default":"false","description":"can be one of:\n- Boolean - if set to true, the variable is broadcast globally and is persistent (JIP compatible) Global Effect\n- Number - the variable is only set on the client with the given Machine network ID. If the number is negative, the variable is set on every client except for the one with the given ID.\n- Array of Numbers - array of Machine network IDs\n\nThis parameter is only available if the **varspace** parameter is a Namespace, Object or Group. Furthermore, only the following Data Types can be broadcast:\n\n|  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|\n| Type | Number | Boolean | Object | Group | String | Text | Array | Code | Nothing (nil) | HashMap |\n| Since | Armed Assault v1.00 | Armed Assault v1.09 | Arma 3 v1.26 | Arma 3 v2.02 |  |  |  |  |  |  |","types":[],"since":"arma2 1.00","text":"public - (Optional, default false) can be one of:\n- Boolean - if set to true, the variable is broadcast globally and is persistent (JIP compatible) Global Effect\n- Number - the variable is only set on the client with the given Machine network ID. If the number is negative, the variable is set on every client except for the one with the given ID.\n- Array of Numbers - array of Machine network IDs\n\nThis parameter is only available if the **varspace** parameter is a Namespace, Object or Group. Furthermore, only the following Data Types can be broadcast:\n\n|  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|\n| Type | Number | Boolean | Object | Group | String | Text | Array | Code | Nothing (nil) | HashMap |\n| Since | Armed Assault v1.00 | Armed Assault v1.09 | Arma 3 v1.26 | Arma 3 v2.02 |  |  |  |  |  |  |"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"varspace","types":[]},"right":{"text":"[name, value, public]","types":["Array"]}}],"examples":[{"text":"```sqf\n_myTruck setVariable [\"TAG_myPublicVariable\", 123, true];\n```","code":["_myTruck setVariable [\"TAG_myPublicVariable\", 123, true];"]},{"text":"```sqf\n_myTruck setVariable [\"TAG_myLocalVariable\", [\"321\", _var], owner driver _myTruck];\n```","code":["_myTruck setVariable [\"TAG_myLocalVariable\", [\"321\", _var], owner driver _myTruck];"]},{"text":"```sqf\nmissionNamespace setVariable [\"TAG_myName\", \"Brian\"];\nhint TAG_myName; // hints \"Brian\"\n```","code":["missionNamespace setVariable [\"TAG_myName\", \"Brian\"];\nhint TAG_myName; // hints \"Brian\""]},{"text":"Get the current value of a variable or, if it is undefined, define it and then get the value:\n\n```sqf\nprivate _var = missionNamespace getVariable \"VarName\";\nif (isNil \"_var\") then\n{\n    _var = 123;\n    missionNamespace setVariable [\"VarName\", _var];\n};\n// _var now contains the current value of the missionNamespace's variable varName\n```","code":["private _var = missionNamespace getVariable \"VarName\";\nif (isNil \"_var\") then\n{\n\t_var = 123;\n\tmissionNamespace setVariable [\"VarName\", _var];\n};\n// _var now contains the current value of the missionNamespace's variable varName"]},{"text":"Remove `TAG_myPublicVariable` from missionNamespace (globally):\n\n```sqf\nmissionNamespace setVariable [\"TAG_myPublicVariable\", nil, true];\n```","code":["missionNamespace setVariable [\"TAG_myPublicVariable\", nil, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getVariable","allVariables","setFSMVariable"],"notes":[{"user":"Killswitch","date":"2007-08-18T09:51:00Z","text":"According to Suma, beginning with ArmA version 1.08:\n\n> setVariable now should work on any entity which can be targeted by AI, including soldier and game logic units. This includes most buildings, but not other static objects.\n> **Using it with buildings one should be aware the building may be discarded because of streaming**. In such case the variable space is lost. When used for buildings, the storage should therefore be considered non-reliable."},{"user":"Commy2","date":"2015-12-09T20:18:00Z","text":"This command does not work with CfgAmmo or CfgNonAIVehicles objects, like bullets, mines or butterflies."},{"user":"Leopard20","date":"2022-03-23T08:59:50Z","text":"Since Arma 3 v2.10 setVariable works on CfgAmmo objects (such as bullets, missiles, grenades, mines, etc) as well."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Namespaces","Command Group: Variables","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVectorDir","operator":null,"title":"setVectorDir","type":"command","url":"https://community.bistudio.com/wiki/setVectorDir","revid":377248,"updated":"2026-01-02T05:42:47Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set object's direction vector. Up vector will remain unchanged.","syntaxes":[{"syntax":"object setVectorDir vectorDir","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"vectorDir","type":"Vector3D","optional":false,"default":null,"description":null,"types":["Vector3D"],"since":null,"text":"vectorDir: Vector3D"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"vectorDir","types":["Vector3D"]}}],"examples":[{"text":"```sqf\nplayer setVectorDir [5,6,1];\n```","code":["player setVectorDir [5,6,1];"]},{"text":"```sqf\n// provided _myMine is local\n_myMine setVectorDir [0.3, 1, 0];\n_myMine setPosWorld getPosWorld _myMine; // synchronises the mine's direction over the network (special case)\n```","code":["// provided _myMine is local\n_myMine setVectorDir [0.3, 1, 0];\n_myMine setPosWorld getPosWorld _myMine; // synchronises the mine's direction over the network (special case)"]}],"multiplayer":null,"problems":"The effect is Local Effect when using setVectorDir on a mine. Use a position modification to broadcast setVectorDir's change (see #Example 2).","aliases":[],"see_also":["vectorDir","vectorUp","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo"],"notes":[{"user":"Str","date":"2008-03-16T09:50:00Z","text":"Command can be also used to rotate camera in all three axis."},{"user":"General Barron","date":"2009-03-03T21:06:00Z","text":"setVectorDir can only influence an object's pitch. It can not influence bank. Example:\n\n```sqf\nplayer setVectorDir [0,0,1];\n```\n\n- If the player is facing 0 degrees (north), then this will do NOTHING.\n- If the player is facing 90 degrees (east), then this will make him pitch 90 degrees up.\nYou can't directly pitch an object beyond 90 degrees, because this would change its facing direction. You must first flip it is direction using setDir, then you must bank the object 180 degrees, THEN you pitch the object appropriately."},{"user":"DreadedEntity","date":"2015-08-17T03:27:00Z","text":"In Arma 3, setVectorDir does not control an object's pitch or bank, in fact, it is not possible to change either of those solely using setVectorDir. This command can only affect horizontal rotation along the x-plane, unless an object first has it is vectorUp changed to something other than [0,0,1]. Correct input to setVectorDir should be calculated using the trigonometric functions sin and cos.\n\nexamples:\n\n```sqf\n// 0 degrees (north)\nplayer setVectorDir\n[\n    sin 0, // equals 0\n    cos 0, // equals 1\n    1\n];\n// 45 degrees (north-east)\nplayer setVectorDir\n[\n    sin 45, // equals 0.707\n    cos 45, // equals 0.707\n    1\n];\n```\n\nIf you are doing trigonometric calculations, it may be better to use setVectorDir rather than setDir, since sine and cosine have already been calculated and will not need to be re-calculated\n(also, setDir probably uses setVectorDir anyway.)"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVectorDirAndUp","operator":null,"title":"setVectorDirAndUp","type":"command","url":"https://community.bistudio.com/wiki/setVectorDirAndUp","revid":378407,"updated":"2026-04-04T08:14:53Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets orientation of an object.\nThe command takes 2 vector arrays, one for vectorDir and one for vectorUp.\nDefault object orientation will always have vectorDir pointing forward (North) along Y axis and vectorUp pointing up along Z axis - [[0,1,0],[0,0,1]], as shown on the diagram below (see also BIS_fnc_transformVectorDirAndUp).\n\nWhen attaching object to an object the axes are relative to the object that gets the attachment.\nIf it is player object for example, then X goes from left to right, Y goes from back to front, and Z goes from down up.\n\nThe setDir command is incompatible with setVectorDirAndUp and should not be used together on the same object.\nUsing setVectorDirAndUp alone should be sufficient for any orientation.","syntaxes":[{"syntax":"vehicle setVectorDirAndUp [vectorDir, vectorUp]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"vectorDir","type":"Vector3D","optional":false,"default":null,"description":"vectorDir","types":["Vector3D"],"since":null,"text":"vectorDir: Vector3D - vectorDir"},{"name":"vectorUp","type":"Vector3D","optional":false,"default":null,"description":"vectorUp","types":["Vector3D"],"since":null,"text":"vectorUp: Vector3D - vectorUp"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[vectorDir, vectorUp]","types":["Array"]}}],"examples":[{"text":"```sqf\n// set exact yaw, pitch, and roll\n_yaw = 45; _pitch = -80; _roll = 0;\n_myObject setVectorDirAndUp [\n    [sin _yaw * cos _pitch, cos _yaw * cos _pitch, sin _pitch],\n    [[sin _roll, -sin _pitch, cos _roll * cos _pitch], -_yaw] call BIS_fnc_rotateVector2D\n];\n```","code":["// set exact yaw, pitch, and roll\n_yaw = 45; _pitch = -80; _roll = 0;\n_myObject setVectorDirAndUp [\n\t[sin _yaw * cos _pitch, cos _yaw * cos _pitch, sin _pitch],\n\t[[sin _roll, -sin _pitch, cos _roll * cos _pitch], -_yaw] call BIS_fnc_rotateVector2D\n];"]},{"text":"To rotate _myObject on Z axis 90 degrees clockwise, change its vectorDir but leave vectorUp unchanged.\n\n```sqf\n_myObject setVectorDirAndUp [[1,0,0], [0,0,1]];\n```","code":["_myObject setVectorDirAndUp [[1,0,0], [0,0,1]];"]},{"text":"To rotate _myObject on Y axis 90 degrees clockwise, change its vectorUp but leave vectorDir unchanged.\n\n```sqf\n_myObject setVectorDirAndUp [[0,1,0], [1,0,0]];\n```","code":["_myObject setVectorDirAndUp [[0,1,0], [1,0,0]];"]},{"text":"To rotate _myObject on X axis 90 degrees (tilt forward), change both vectorDir and vectorUp accordingly.\n\n```sqf\n_myObject setVectorDirAndUp [[0,0,-1], [0,1,0]];\n```","code":["_myObject setVectorDirAndUp [[0,0,-1], [0,1,0]];"]},{"text":"More complex orientations\n\n```sqf\n// tilt forward 90 + rotate left 90\n_myObject setVectorDirAndUp [[1,0,0], [0,1,0]];\n// tilt backward 45 degrees\n_myObject setVectorDirAndUp [[0,0.5,0.5], [0,-0.5,0.5]];\n// tilt forward 30 degrees\n_myObject setVectorDirAndUp [[0,0.66,-0.33], [0,0.33,0.66]];\n```","code":["// tilt forward 90 + rotate left 90\n_myObject setVectorDirAndUp [[1,0,0], [0,1,0]];\n// tilt backward 45 degrees\n_myObject setVectorDirAndUp [[0,0.5,0.5], [0,-0.5,0.5]];\n// tilt forward 30 degrees\n_myObject setVectorDirAndUp [[0,0.66,-0.33], [0,0.33,0.66]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDir","vectorUp","setVectorDir","setVectorUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo","BIS_fnc_transformVectorDirAndUp"],"notes":[{"user":"Str","date":"2008-03-16T09:50:00Z","text":"Command can be also used to rotate camera in all three axis (which also mean it is possible to set camera bank)."},{"user":"General Barron","date":"2008-05-09T09:32:00Z","text":"The object's vectorDir can only control its pitch, while its vectorUp can only control its bank. To set an object's yaw (direction), use the setdir command, before using this command.\nYou would think vectorUp would control pitch as well, but any pitch that would be set due to vectorUp is ignored. The same is true with vectorDir and yaw; any vectorDir that would adjust yaw is also ignored. If this doesn't make sense, try to visualize it with a box or soda can.\nThis command does NOT work with values relative to a unit, but rather it works with world vectors (think world coordinates as opposed to model coordinates). As a result, this command can be difficult to use in many situations, because the input values needed to get a certain pitch / bank for an object vary, depending on what direction the object is facing (yaw).\nA function to set an object's pitch / bank can be found"},{"user":"Chris330","date":"2009-10-23T18:39:00Z","text":"Note this odd command may now be better understood. There's a thread about it here:"},{"user":"ffur2007slx2_5","date":"2014-06-01T18:45:00Z","text":"Arma 3 v1.20 setDir overwrites setVectorDirAndUp (P.S. setVectorDirAndUp also affects setVelocity.), so use setDir before BIS_fnc_setPitchBank, which is an easier workaround on vector, if changing yaw, pitch and bank are needed. setVectorDirAndUp is CCW, so if we wanna to set an obj 40 degrees CW, 170 degrees pitch and 85 degrees bank:\n\n```sqf\n_obj setDir (40 - 180); [_obj, 170, 85] call BIS_fnc_setPitchBank;\n```\n\nSame as:\n\n```sqf\n_obj setVectorDirAndUp [[0.63,0.75,0.17],[-0.75,0.65,-0.084]];\n```\n\nBe aware that attachTo may flip vectorDir if pitch beyond 90 degrees and cause unexpected behavior to BIS_fnc_setPitchBank, e.g.\n\n```sqf\n[_obj, 100, 0] call BIS_fnc_setPitchBank; // vector: [-0.14,-0.09,0.98],[-0.83,-0.51,-0.17]\n```\n\n```sqf\n_obj attachTo [_logic,[0,0,2]];\n[_obj, 100, 0] call BIS_fnc_setPitchBank; // vector: [0.11,0.33,0.93],[-0.06,0.94,-0.32]\n```\n\ncompass direction algorithm failed if obj was attached at present.\nTo overcome such limitation we can use fallowing function for a better workaround. (code originated from '''bapedibupa'', remodified)\n\n```sqf\n_obj attachTo [_logic,[0,0,2]];\n[_obj,[120,-78,37]] call fnc_SetPitchBankYaw; // pitch: 120, bank: -78, yaw: 37\n```\n\n```sqf\nfnc_SetPitchBankYaw = {\n    private [\"_object\", \"_rotations\", \"_aroundX\", \"_aroundY\", \"_aroundZ\", \"_dirX\", \"_dirY\",\n    \"_dirZ\", \"_upX\", \"_upY\", \"_upZ\", \"_dir\", \"_up\", \"_dirXTemp\", \"_upXTemp\"];\n    _object = _this select 0;\n    _rotations = _this select 1;\n    _aroundX = _rotations select 0;\n    _aroundY = _rotations select 1;\n    _aroundZ = (360 - (_rotations select 2)) - 360;\n    _dirX = 0;\n    _dirY = 1;\n    _dirZ = 0;\n    _upX = 0;\n    _upY = 0;\n    _upZ = 1;\n    if (_aroundX != 0) then {\n        _dirY = cos _aroundX;\n        _dirZ = sin _aroundX;\n        _upY = -sin _aroundX;\n        _upZ = cos _aroundX;\n    };\n    if (_aroundY != 0) then {\n        _dirX = _dirZ * sin _aroundY;\n        _dirZ = _dirZ * cos _aroundY;\n        _upX = _upZ * sin _aroundY;\n        _upZ = _upZ * cos _aroundY;\n    };\n    if (_aroundZ != 0) then {\n        _dirXTemp = _dirX;\n        _dirX = (_dirXTemp* cos _aroundZ) - (_dirY * sin _aroundZ);\n        _dirY = (_dirY * cos _aroundZ) + (_dirXTemp * sin _aroundZ);\n        _upXTemp = _upX;\n        _upX = (_upXTemp * cos _aroundZ) - (_upY * sin _aroundZ);\n        _upY = (_upY * cos _aroundZ) + (_upXTemp * sin _aroundZ);\n    };\n    _dir = [_dirX,_dirY,_dirZ];\n    _up = [_upX,_upY,_upZ];\n    _object setVectorDirAndUp [_dir,_up];\n};\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Armed Assault version 1.09","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVectorUp","operator":null,"title":"setVectorUp","type":"command","url":"https://community.bistudio.com/wiki/setVectorUp","revid":377596,"updated":"2026-01-02T07:00:50Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set object's up vector. Direction of the object remain unchanged. Default object's vectorUp is [0,0,1].","syntaxes":[{"syntax":"object setVectorUp vectorUp","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"vectorUp","type":null,"optional":false,"default":null,"description":"Vector3D (normalised)","types":["Vector3D"],"since":null,"text":"vectorUp: Vector3D (normalised)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"vectorUp","types":["Vector3D"]}}],"examples":[{"text":"Turn object upside down:\n\n```sqf\n_obj setVectorUp [0, 0, -1];\n```","code":["_obj setVectorUp [0, 0, -1];"]},{"text":"Align object with the terrain underneath:\n\n```sqf\n_obj setVectorUp surfaceNormal getPosASL _obj;\n```","code":["_obj setVectorUp surfaceNormal getPosASL _obj;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDir","vectorUp","setVectorDir","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo"],"notes":[{"user":"General Barron","date":"2009-03-03T21:07:00Z","text":"setVectorUp can only influence an object's bank. It can not influence pitch. Example:\n\n```sqf\nplayer setVectorUp [0, 1, 0]\n```\n\nIf the player is facing 0 degrees (north), then this will do NOTHING.\n\nIf the player is facing 90 degrees (east), then this will make him bank 90 degrees to his left."},{"user":"Kronzky","date":"2007-03-22T05:07:00Z","text":"An in-depth discussion on the concept of vectors is available [here](http://forums.bistudio.com/showthread.php?t=50914)."},{"user":"Str","date":"2008-03-16T09:49:00Z","text":"Command can be also used to rotate camera in all three axis (which also mean it is possible to set camera bank)."},{"user":"Killzone_Kid","date":"2013-10-03T09:04:00Z","text":"It is possible to change both pitch and bank of an object (surfaceNormal application for instance).\nAssuming an ammo box in the following example is facing North (default direction is 0):\n\n```sqf\n_ammobox setVectorUp [0, 1, 0]; // box is pitched 90 degrees forward\n_ammobox setVectorUp [1, 0, 0]; // box is banked 90 degrees to the right\n```\n\nHowever the above will stop working as soon as you attach the box to something. The following trick however will work in this case:\n\n```sqf\n_ammobox attachTo [player, [0, 2, 1]];\n_ammobox setVectorUp [0, 0.99, 0.01]; // box is pitched ~90 degrees forward\n_ammobox setVectorUp [0.99, 0, 0.01]; // box is banked ~90 degrees to the right\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleAmmo","operator":null,"title":"setVehicleAmmo","type":"command","url":"https://community.bistudio.com/wiki/setVehicleAmmo","revid":376973,"updated":"2026-01-01T06:03:41Z","groups":["Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets how much ammunition (compared to a full state defined by the vehicle type) the vehicle has. Note that the ammo will be added only to local turrets. To check locality of turret use turretLocal.","syntaxes":[{"syntax":"vehicleName setVehicleAmmo value","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"value","type":"Number in range 0..1","optional":false,"default":null,"description":"0: empty, 1: full","types":["Number"],"since":null,"text":"value: Number in range 0..1 - 0: empty, 1: full"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setVehicleAmmo 0;\n```","code":["player setVehicleAmmo 0;"]},{"text":"```sqf\n_vehicle setVehicleAmmo 1;\n```","code":["_vehicle setVehicleAmmo 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleAmmoDef","ammo","setAmmo","setAmmoCargo","turretLocal"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle Inventory","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleAmmoDef","operator":null,"title":"setVehicleAmmoDef","type":"command","url":"https://community.bistudio.com/wiki/setVehicleAmmoDef","revid":378138,"updated":"2026-02-25T12:58:23Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets how much ammunition (compared to the configuration of magazines defined in the vehicle's class) the vehicle has. Note that the ammo will only be added to local turrets. To check the locality of turret use turretLocal.","syntaxes":[{"syntax":"unit setVehicleAmmoDef value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit or vehicle.","types":["Object"],"since":null,"text":"unit: Object - unit or vehicle."},{"name":"value","type":"Number","optional":false,"default":null,"description":"from 0 (no ammo) to 1 (fully loaded).","types":["Number"],"since":null,"text":"value: Number - from 0 (no ammo) to 1 (fully loaded)."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setVehicleAmmoDef 0;\n```","code":["player setVehicleAmmoDef 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleAmmo","ammo","setAmmo","setAmmoCargo","turretLocal"],"notes":[{"user":"Actium","date":"2014-12-20T22:49:00Z","text":"For vehicles this command operates relative to its stock magazine loadout (i.e. its CfgVehicles magazines[] values).\nThus *setVehicleAmmoDef 1* will fully restore a vehicle to its default ammunition capacity, resetting any changes made by intentionally/implicitly adding/removing magazines.\nUse setVehicleAmmo to operate in relation to a vehicle's current magazine loadout."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setVehicleArmor","operator":null,"title":"setVehicleArmor","type":"command","url":"https://community.bistudio.com/wiki/setVehicleArmor","revid":369388,"updated":"2024-09-03T18:43:16Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the armor (or health for men) state of the vehicle (a value from 0 to 1).\n\nWorks like setDamage, but the other way around: 1 is full health - see #Example 2.","syntaxes":[{"syntax":"vehicleName setVehicleArmor value","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":"in range 0..1","types":["Number"],"since":null,"text":"value: Number - in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setVehicleArmor 0.5;\n```","code":["player setVehicleArmor 0.5;"]},{"text":"```sqf\nplayer setVehicleArmor 1;\n// is the same as\nplayer setDamage 0;\n\nplayer setVehicleArmor 0;\n// is the same as\nplayer setDamage 0.97;\n```","code":["player setVehicleArmor 1;\n// is the same as\nplayer setDamage 0;\n\nplayer setVehicleArmor 0;\n// is the same as\nplayer setDamage 0.97;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDamage"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleCargo","operator":null,"title":"setVehicleCargo","type":"command","url":"https://community.bistudio.com/wiki/setVehicleCargo","revid":349523,"updated":"2023-11-08T17:15:54Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Load cargo vehicle inside vehicle if possible, returns bool based on whether the vehicle was able to be loaded.  Can also be used to unload a specific loaded vehicle or all loaded vehicles.","syntaxes":[{"syntax":"vehicle setVehicleCargo cargo","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle for carrying cargo, objNull to unload specific loaded cargo","types":["Object"],"since":null,"text":"vehicle: Object - vehicle for carrying cargo, objNull to unload specific loaded cargo"},{"name":"cargo","type":"Object","optional":false,"default":null,"description":"cargo to put/loaded in vehicle, objNull to unload all loaded cargo","types":["Object"],"since":null,"text":"cargo: Object - cargo to put/loaded in vehicle, objNull to unload all loaded cargo"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"whether or not operation was a success","text":"Boolean - whether or not operation was a success"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"cargo","types":["Object"]}}],"examples":[{"text":"Blackfish with no vehicle cargo loaded\n\n```sqf\nprivate _success = blackfish setVehicleCargo offroad; // true\n```","code":["private _success = blackfish setVehicleCargo offroad; // true"]},{"text":"Blackfish with full cargo already loaded\n\n```sqf\nprivate _success = blackfish setVehicleCargo offroad; // false\n```","code":["private _success = blackfish setVehicleCargo offroad; // false"]},{"text":"Unload specific loaded vehicle (will paradrop if dropped from high altitude)\n\n```sqf\nprivate _success = objNull setVehicleCargo offroad;\n```","code":["private _success = objNull setVehicleCargo offroad;"]},{"text":"Unload all vehicles (will paradrop if dropped from high altitude)\n\n```sqf\nprivate _success = blackfish setVehicleCargo objNull;\n```","code":["private _success = blackfish setVehicleCargo objNull;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle in Vehicle Transport","canVehicleCargo","enableVehicleCargo","getVehicleCargo","isVehicleCargo","vehicleCargoEnabled"],"notes":[{"user":"ImperialAlex","date":"2016-07-04T18:46:00Z","text":"`objNull setVehicleCargo _cargoVehicle` - will unload specific loaded vehicle, and `_trasportVehicle setVehicleCargo objNull` will unload all vehicles. The unloaded vehicles will be paradropped if the altitude is high enough. See:"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setVehicleId","operator":null,"title":"setVehicleId","type":"command","url":"https://community.bistudio.com/wiki/setVehicleId","revid":364524,"updated":"2024-05-16T20:46:23Z","groups":["Object Manipulation","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets ID to vehicle. By this ID vehicle is referenced by triggers and waypoints.\n\n> [!WARNING]\n> This command is **not** to be used.","syntaxes":[{"syntax":"vehicleName setVehicleId id","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"id","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"id: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"id","types":["Number"]}}],"examples":[{"text":"```sqf\nplayer setVehicleId 1;\n```","code":["player setVehicleId 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleVarName"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleLock","operator":null,"title":"setVehicleLock","type":"command","url":"https://community.bistudio.com/wiki/setVehicleLock","revid":364112,"updated":"2024-05-04T22:05:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets vehicle lock. Possible values:\n\n- \"UNLOCKED\"\n- \"DEFAULT\"\n- \"LOCKED\"\n- \"LOCKEDPLAYER\"","syntaxes":[{"syntax":"vehicleName setVehicleLock lockState","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"lockState","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"lockState: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"lockState","types":["String"]}}],"examples":[{"text":"```sqf\n_veh1 setVehicleLock \"LOCKED\";\n```","code":["_veh1 setVehicleLock \"LOCKED\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lock","locked","lockDriver","lockCargo","lockTurret"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehiclePosition","operator":null,"title":"setVehiclePosition","type":"command","url":"https://community.bistudio.com/wiki/setVehiclePosition","revid":377535,"updated":"2026-01-02T06:53:22Z","groups":["Positions","Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Moves the object to a given position (same as createVehicle placement algorithm). Uses either the position that's defined by the *position* param, or one of the marker positions from the markers array. The object is placed inside a circle with *position* as its center and *placement* as its radius. The type of placement could also be controlled with *special*.\n\nIf position is in water and the vehicle can float, it is placed on water surface, otherwise it is placed on the ground, even if the ground is under water. If roof surfaces support walking, units will be placed on roofs if such position is given.","syntaxes":[{"syntax":"object setVehiclePosition [position, markers, placement, special]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"position","type":"PositionATL (PositionAGL if boat or amphibious), Position2D, or Object","optional":false,"default":null,"description":"desired placement position.\nIf object is given, object position is used for *position*. Normally only *x* and *y* are considered, unless \"CAN_COLLIDE\" is used for special placement","types":["PositionATL","PositionAGL","Position2D","Object"],"since":null,"text":"position: PositionATL (PositionAGL if boat or amphibious), Position2D, or Object - desired placement position.\nIf object is given, object position is used for *position*. Normally only *x* and *y* are considered, unless \"CAN_COLLIDE\" is used for special placement"},{"name":"markers","type":"Array of Strings","optional":false,"default":null,"description":"if the markers array contains one or more marker names, the position is chosen randomly and could be one of the marker positions or just the supplied main position.\nIf marker had z coordinate set with setMarkerPos, the vehicle will be placed on the nearest surface below this z coordinate","types":["Array","String"],"since":null,"text":"markers: Array of Strings - if the markers array contains one or more marker names, the position is chosen randomly and could be one of the marker positions or just the supplied main position.\nIf marker had z coordinate set with setMarkerPos, the vehicle will be placed on the nearest surface below this z coordinate"},{"name":"placement","type":"Number","optional":false,"default":null,"description":"the vehicle is randomly placed inside a circle with given position as center and placement as its radius","types":["Number"],"since":null,"text":"placement: Number - the vehicle is randomly placed inside a circle with given position as center and placement as its radius"},{"name":"special","type":"String","optional":true,"default":"\"NONE\"","description":"can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used.","types":["String"],"since":null,"text":"special: String - (Optional, default \"NONE\") can be one of the following:\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\nIf *special* is \"\" or not specified, default `\"NONE\"` is used."}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success, false on failure","text":"Boolean - true on success, false on failure"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[position, markers, placement, special]","types":["Array"]}}],"examples":[{"text":"```sqf\n// place the player at either [1000,2000], or one of the three markers positions\nplayer setVehiclePosition [[1000,2000], [\"Pos1\",\"Pos2\",\"Pos3\"], 0, \"CAN_COLLIDE\"];\n```","code":["// place the player at either [1000,2000], or one of the three markers positions\nplayer setVehiclePosition [[1000,2000], [\"Pos1\",\"Pos2\",\"Pos3\"], 0, \"CAN_COLLIDE\"];"]},{"text":"```sqf\nheli setVehiclePosition [player, [], 0, \"FLY\"];\n```","code":["heli setVehiclePosition [player, [], 0, \"FLY\"];"]},{"text":"```sqf\n_cam = \"camera\" camCreate [0,0,0];\n_cam setDir random 360;\n_cam setVehiclePosition [[5000,5000], [], 1000, \"NONE\"];\n_cam setPosWorld (getPosWorld _cam vectorAdd [0,0,1.8]);\n_cam cameraEffect [\"Internal\", \"Back\"];\n```","code":["_cam = \"camera\" camCreate [0,0,0];\n_cam setDir random 360;\n_cam setVehiclePosition [[5000,5000], [], 1000, \"NONE\"];\n_cam setPosWorld (getPosWorld _cam vectorAdd [0,0,1.8]);\n_cam cameraEffect [\"Internal\", \"Back\"];"]},{"text":"```sqf\nprivate _tablePos = player getRelPos [3, 0];\nprivate _table = \"Land_CampingTable_F\" createVehicle [0,0,0];\nprivate _laptop = \"Land_Laptop_unfolded_F\" createVehicle [0,0,0];\n_table setPos _tablePos;\n_laptop setVehiclePosition [_tablePos vectorAdd [0.5, 0.2, 10], [], 0, \"CAN_COLLIDE\"];\n_laptop attachTo [_table];\n```","code":["private _tablePos = player getRelPos [3, 0];\nprivate _table = \"Land_CampingTable_F\" createVehicle [0,0,0];\nprivate _laptop = \"Land_Laptop_unfolded_F\" createVehicle [0,0,0];\n_table setPos _tablePos;\n_laptop setVehiclePosition [_tablePos vectorAdd [0.5, 0.2, 10], [], 0, \"CAN_COLLIDE\"];\n_laptop attachTo [_table];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setPos","createUnit","setPosASL","setPosWorld","createVehicle","Position"],"notes":[{"user":"Killzone_Kid","date":"2015-06-24T15:43:00Z","text":"If you need to set direction as well, set it before using setVehiclePosition. The command will use existing dir of the object for its calculations.\n\n```sqf\nplayer setDir random 360;\nplayer setVehiclePosition [player, [], 100, \"none\"];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Positions","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleRadar","operator":null,"title":"setVehicleRadar","type":"command","url":"https://community.bistudio.com/wiki/setVehicleRadar","revid":348315,"updated":"2023-11-08T12:59:38Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the AI rule of Radar usage (Emission Control). Automatic means Radar switched on only when in Combat. The command doesn't affect player-controlled vehicles.","syntaxes":[{"syntax":"vehicle setVehicleRadar rule","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"an AI-controlled vehicle","types":["Object"],"since":null,"text":"vehicle: Object - an AI-controlled vehicle"},{"name":"rule","type":"Number","optional":false,"default":null,"description":"can be one of the following:\n- 0 - automatic\n- 1 - forced on\n- 2 - forced off","types":["Number"],"since":null,"text":"rule: Number - can be one of the following:\n- 0 - automatic\n- 1 - forced on\n- 2 - forced off"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"rule","types":["Number"]}}],"examples":[{"text":"```sqf\n_vehicle setVehicleRadar 1;\n```","code":["_vehicle setVehicleRadar 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isVehicleRadarOn","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setVehicleReceiveRemoteTargets","operator":null,"title":"setVehicleReceiveRemoteTargets","type":"command","url":"https://community.bistudio.com/wiki/setVehicleReceiveRemoteTargets","revid":311071,"updated":"2022-05-07T20:56:47Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets that the vehicle will be able to receive targets acquired by someone else via datalink from the Side center.","syntaxes":[{"syntax":"vehicle setVehicleReceiveRemoteTargets bool","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player setVehicleReceiveRemoteTargets true;\n```","code":["vehicle player setVehicleReceiveRemoteTargets true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setVehicleReportOwnPosition","operator":null,"title":"setVehicleReportOwnPosition","type":"command","url":"https://community.bistudio.com/wiki/setVehicleReportOwnPosition","revid":311072,"updated":"2022-05-07T20:57:10Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets that the vehicle will share its own position via datalink to the Side center.","syntaxes":[{"syntax":"vehicle setVehicleReportOwnPosition report","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"report","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"report: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"report","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player setVehicleReportOwnPosition true;\n```","code":["vehicle player setVehicleReportOwnPosition true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setVehicleReportRemoteTargets","operator":null,"title":"setVehicleReportRemoteTargets","type":"command","url":"https://community.bistudio.com/wiki/setVehicleReportRemoteTargets","revid":311073,"updated":"2022-05-07T20:57:55Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets that the vehicle will share targets that were acquired by its own sensors via datalink to the Side center.","syntaxes":[{"syntax":"vehicle setVehicleReportRemoteTargets bool","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nvehicle player setVehicleReportRemoteTargets true;\n```","code":["vehicle player setVehicleReportRemoteTargets true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"setVehicleTIPars","operator":null,"title":"setVehicleTIPars","type":"command","url":"https://community.bistudio.com/wiki/setVehicleTIPars","revid":348636,"updated":"2023-11-08T13:46:10Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets the \"heat\" state of different vehicle parts for Thermal Imaging detection.\nThis allows simulation of heated up parts of a vehicle without it actually having to utilize them - on a 0..1 range - 0 being cold, 1 being hot.\n\n> [!NOTE]\n> This command does not work on infantry weapons.","syntaxes":[{"syntax":"vehicle setVehicleTIPars [engine, wheels, weapon]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle whose components are manipulated","types":["Object"],"since":null,"text":"vehicle: Object - vehicle whose components are manipulated"},{"name":"engine","type":"Number","optional":false,"default":null,"description":"engine and body's heat","types":["Number"],"since":null,"text":"engine: Number - engine and body's heat"},{"name":"wheels","type":"Number","optional":false,"default":null,"description":"tracks/wheels' heat","types":["Number"],"since":null,"text":"wheels: Number - tracks/wheels' heat"},{"name":"weapon","type":"Number","optional":false,"default":null,"description":"main weapon's heat","types":["Number"],"since":null,"text":"weapon: Number - main weapon's heat"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[engine, wheels, weapon]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setVehicleTIPars [1, 1, 1];            // set all parts hot\nvehicle player setVehicleTIPars [0, 0, 0];            // set all parts cold\nvehicle player setVehicleTIPars [0.5, 0.5, 0.5];    // set all parts warm\n```","code":["vehicle player setVehicleTIPars [1, 1, 1];\t\t\t// set all parts hot\nvehicle player setVehicleTIPars [0, 0, 0];\t\t\t// set all parts cold\nvehicle player setVehicleTIPars [0.5, 0.5, 0.5];\t// set all parts warm"]},{"text":"```sqf\nvehicle player setVehicleTIPars [1, 0, 0]; // set the engine warm, perfect for winter\n```","code":["vehicle player setVehicleTIPars [1, 0, 0]; // set the engine warm, perfect for winter"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableTIEquipment","setCamUseTI"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVehicleVarName","operator":null,"title":"setVehicleVarName","type":"command","url":"https://community.bistudio.com/wiki/setVehicleVarName","revid":338577,"updated":"2023-03-20T15:21:44Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sets string representation of an object to a custom string.\n\nWhen a vehicle is created and named in the editor, the name becomes both the variable containing the vehicle object and the string representation of the vehicle object.\nIn scripts an extra step is needed to achieve the same effect - see #Example 1.\n\n> [!NOTE]\n> This does not work with Simple Objects.","syntaxes":[{"syntax":"object setVehicleVarName name","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nprivate _playersCar = vehicle player;\nsystemChat str _playersCar; // displays e.g \"ce06b00# 164274: offroad_01_unarmed_f.p3d\"\n\n_playersCar setVehicleVarName \"MyOffroad\";\nsystemChat str _playersCar;    // displays \"MyOffroad\"\n\nisNil \"MyOffroad\";            // true - the MyOffroad variable is not set\nMyOffroad = _playersCar;    // now it is\npublicVariable \"MyOffroad\";    // broadcasts it over the network\n```","code":["private _playersCar = vehicle player;\nsystemChat str _playersCar; // displays e.g \"ce06b00# 164274: offroad_01_unarmed_f.p3d\"\n\n_playersCar setVehicleVarName \"MyOffroad\";\nsystemChat str _playersCar;\t// displays \"MyOffroad\"\n\nisNil \"MyOffroad\";\t\t\t// true - the MyOffroad variable is not set\nMyOffroad = _playersCar;\t// now it is\npublicVariable \"MyOffroad\";\t// broadcasts it over the network"]},{"text":"```sqf\n_offroad setVehicleVarName \"\"; // Reset string representation to the default value\n```","code":["_offroad setVehicleVarName \"\"; // Reset string representation to the default value"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vehicleVarName","BIS_fnc_objectVar"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setVelocity","operator":null,"title":"setVelocity","type":"command","url":"https://community.bistudio.com/wiki/setVelocity","revid":378408,"updated":"2026-04-04T08:14:56Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets velocity vector of an object in m/s.\n\n> [!IMPORTANT]\n> Since Arma 3 v2.06 each velocity component is limited to the range +-5000 m/s.","syntaxes":[{"syntax":"object setVelocity vector","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"vector","type":"Vector3D","optional":false,"default":null,"description":null,"types":["Vector3D"],"since":null,"text":"vector: Vector3D"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"vector","types":["Vector3D"]}}],"examples":[{"text":"```sqf\n_truck1 setVelocity [20, 0, 0];\n```","code":["_truck1 setVelocity [20, 0, 0];"]},{"text":"Advanced method used for relative acceleration:\n\n```sqf\n_vel = velocity _vehicle;\n_dir = getDir _vehicle;\n_additionalSpeed = 10; // in m/s\n_vehicle setVelocity [\n    (_vel select 0) + (sin _dir * _additionalSpeed), \n    (_vel select 1) + (cos _dir * _additionalSpeed), \n    (_vel select 2) // horizontal only\n];\n```","code":["_vel = velocity _vehicle;\n_dir = getDir _vehicle;\n_additionalSpeed = 10; // in m/s\n_vehicle setVelocity [\n\t(_vel select 0) + (sin _dir * _additionalSpeed), \n\t(_vel select 1) + (cos _dir * _additionalSpeed), \n\t(_vel select 2) // horizontal only\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocity","velocityModelSpace","setVelocityModelSpace","setVelocityTransformation","speed"],"notes":[{"user":"ffur2007slx2_5","date":"2014-06-20T16:50:00Z","text":"Arma 3 v1.22 setVelocity will be affected by setDir and setVectorDirAndUp, so use it after them."}],"categories":[]},{"name":"setVelocityModelSpace","operator":null,"title":"setVelocityModelSpace","type":"command","url":"https://community.bistudio.com/wiki/setVelocityModelSpace","revid":377260,"updated":"2026-01-02T06:33:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Sets the velocity (i.e. speed) vector of the given vehicle relative to its model.\n\n> [!IMPORTANT]\n> Since Arma 3 v2.06, each velocity component is limited to ±5000 m/s.","syntaxes":[{"syntax":"vehicle setVelocityModelSpace velocity","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"velocity","type":"Vector3D","optional":false,"default":null,"description":"relative velocity vector","types":["Vector3D"],"since":null,"text":"velocity: Vector3D - relative velocity vector"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"velocity","types":["Vector3D"]}}],"examples":[{"text":"```sqf\nMyCar setVelocityModelSpace [0, 10, 0]; // Pushes MyCar forward.\n```","code":["MyCar setVelocityModelSpace [0, 10, 0]; // Pushes MyCar forward."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocityModelSpace","velocity","setVelocity","setVelocityTransformation","speed","disableBrakes","brakesDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.68","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setVelocityTransformation","operator":null,"title":"setVelocityTransformation","type":"command","url":"https://community.bistudio.com/wiki/setVelocityTransformation","revid":377448,"updated":"2026-01-02T06:47:04Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Interpolates and applies PositionASL, velocity, vectorDir and vectorUp to the given object based on the interval value.\n\nWhen interval is 0 the \"fromXXX\" values are used for the beginning of the interpolation. When interval is 1, the \"toXXX\" values are used for the end of interpolation.\nWhen interval value is in between, interpolated values are used (see diagram below). The interpolation is linear and along straight line between \"from\" and \"to\" positions.\nIf curve is needed, then it should be constructed from multiple straight sections or by dynamically changing value of position params during the interpolation cycle, similar to [Quadratic Curve animation](https://en.wikipedia.org/wiki/B%C3%A9zier_curve#Quadratic_curves) (see #Example 3).\n\nThe velocity param does not do much in SP, but in MP, provided the velocity component is set correctly, it helps the engine to figure out what the next position of the moving object should be on other clients.\n\nThe actual approximate interpolation formula for this command is:\n\n```sqf\n_vecCurrent = _vecFrom vectorAdd (_vecTo vectorDiff _vecFrom vectorMultiply _interval);\n```\n\n> [!NOTE]\n> For continuous movement this command should be executed each frame while changing the interval value.\n> For example to apply interpolation for 10 seconds one could use the following command to translate 10 seconds into 0..1 interval:\n>\n> ```sqf\n> t1 = time;\n> t2 = time + 10;\n> ```\n>\n> Later inside some on frame event...\n>\n> ```sqf\n> _interval = linearConversion [t1, t2, time, 0, 1];\n> ```","syntaxes":[{"syntax":"object setVelocityTransformation [fromPosASL, toPosASL, fromVelocity, toVelocity, fromVectorDir, toVectorDir, fromVectorUp, toVectorUp, interval, customCenter]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"object to be interpolated","types":["Object"],"since":null,"text":"object: Object - object to be interpolated"},{"name":"fromPosASL","type":"PositionASL","optional":false,"default":null,"description":"starting getPosASL of the object","types":["PositionASL"],"since":null,"text":"fromPosASL: PositionASL - starting getPosASL of the object"},{"name":"toPosASL","type":"PositionASL","optional":false,"default":null,"description":"ending getPosASL of the object","types":["PositionASL"],"since":null,"text":"toPosASL: PositionASL - ending getPosASL of the object"},{"name":"fromVelocity","type":"Vector3D","optional":false,"default":null,"description":"starting velocity of the object","types":["Vector3D"],"since":null,"text":"fromVelocity: Vector3D - starting velocity of the object"},{"name":"toVelocity","type":"Vector3D","optional":false,"default":null,"description":"ending velocity of the object","types":["Vector3D"],"since":null,"text":"toVelocity: Vector3D - ending velocity of the object"},{"name":"fromVectorDir","type":"Vector3D","optional":false,"default":null,"description":"starting vectorDir of the object","types":["Vector3D"],"since":null,"text":"fromVectorDir: Vector3D - starting vectorDir of the object"},{"name":"toVectorDir","type":"Vector3D","optional":false,"default":null,"description":"ending vectorDir of the object","types":["Vector3D"],"since":null,"text":"toVectorDir: Vector3D - ending vectorDir of the object"},{"name":"fromVectorUp","type":"Vector3D","optional":false,"default":null,"description":"starting vectorUp of the object","types":["Vector3D"],"since":null,"text":"fromVectorUp: Vector3D - starting vectorUp of the object"},{"name":"toVectorUp","type":"Vector3D","optional":false,"default":null,"description":"ending vectorUp of the object","types":["Vector3D"],"since":null,"text":"toVectorUp: Vector3D - ending vectorUp of the object"},{"name":"interval","type":"Number","optional":false,"default":null,"description":"interpolation interval (variable value, normally between 0 and 1)","types":["Number"],"since":null,"text":"interval: Number - interpolation interval (variable value, normally between 0 and 1)"},{"name":"customCenter","type":"PositionRelative","optional":true,"default":"placing point of the model (see getModelInfo)","description":"custom center [x, y, z] to which transformation would be applied in model coordinates","types":["PositionRelative"],"since":"arma3 2.08","text":"customCenter: PositionRelative - (Optional, default placing point of the model (see getModelInfo)) custom center [x, y, z] to which transformation would be applied in model coordinates"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[fromPosASL, toPosASL, fromVelocity, toVelocity, fromVectorDir, toVectorDir, fromVectorUp, toVectorUp, interval, customCenter]","types":["Array"]}}],"examples":[{"text":"```sqf\n_tracker setVelocityTransformation\n[\n    _currentPos,\n    _nextPos,\n    _currentVelocity,\n    _nextVelocity,\n    _currentVectorDir,\n    _nextVectorDir,\n    _currentVectorUp,\n    _nextVectorUp,\n    _interval\n];\n```","code":["_tracker setVelocityTransformation\n[\n\t_currentPos,\n\t_nextPos,\n\t_currentVelocity,\n\t_nextVelocity,\n\t_currentVectorDir,\n\t_nextVectorDir,\n\t_currentVectorUp,\n\t_nextVectorUp,\n\t_interval\n];"]},{"text":"Bob on imaginary stairway to heaven:\n\n```sqf\nbob = createAgent [\"C_man_1\", player getRelPos [5, 0], [], 0, \"CAN_COLLIDE\"];\nbob switchMove \"ladderCivilUpLoop\";\npos1 = getPosASL bob;\npos2 = pos1 vectorAdd [0,0,0.75];\nbob addEventHandler [\"AnimDone\",\n{\n    pos1 = pos2;\n    pos2 = pos2 vectorAdd [0,0,0.75]\n}];\n\nonEachFrame\n{\n    if (!alive bob) then\n    {\n        onEachFrame {};\n        bob switchMove \"\";\n        bob removeAllEventHandlers \"AnimDone\";\n    };\n    bob setVelocityTransformation [\n        pos1,\n        pos2,\n        [0,0,0],\n        [0,0,0],\n        [0,1,0],\n        [0,1,0],\n        [0,0,1],\n        [0,0,1],\n        moveTime bob\n    ];\n};\n```","code":["bob = createAgent [\"C_man_1\", player getRelPos [5, 0], [], 0, \"CAN_COLLIDE\"];\nbob switchMove \"ladderCivilUpLoop\";\npos1 = getPosASL bob;\npos2 = pos1 vectorAdd [0,0,0.75];\nbob addEventHandler [\"AnimDone\",\n{\n\tpos1 = pos2;\n\tpos2 = pos2 vectorAdd [0,0,0.75]\n}];\n\nonEachFrame\n{\n\tif (!alive bob) then\n\t{\n\t\tonEachFrame {};\n\t\tbob switchMove \"\";\n\t\tbob removeAllEventHandlers \"AnimDone\";\n\t};\n\tbob setVelocityTransformation [\n\t\tpos1,\n\t\tpos2,\n\t\t[0,0,0],\n\t\t[0,0,0],\n\t\t[0,1,0],\n\t\t[0,1,0],\n\t\t[0,0,1],\n\t\t[0,0,1],\n\t\tmoveTime bob\n\t];\n};"]},{"text":"Advanced trickery with curved movement. The curve is controlled with one control point (controlPointASL), just like quadratic Bézier curve:\n\n```sqf\ndisableSerialization;\nplayer setDir 0;\ninterval = 0;\n_disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n_ctrl = _disp ctrlCreate [\"RscSlider\", -1];\n_ctrl ctrlSetPosition [safeZoneX + 0.1, 1, safeZoneW - 0.2, 0.1];\n_ctrl ctrlSetActiveColor [1,0,0,1];\n_ctrl ctrlCommit 0;\n_ctrl sliderSetPosition 0;\n_ctrl sliderSetRange [0,1];\n_ctrl sliderSetSpeed [0.1,0.5];\n_ctrl ctrlAddEventHandler [\"SliderPosChanged\", {interval = _this select 1}];\nctrlSetFocus _ctrl;\nbox = \"Land_VR_Shape_01_cube_1m_F\" createVehicle [0,0,0];\ncontrolPointASL = AGLToASL (player getRelPos [70, -30]) vectorAdd [0, 0, 30];\nfromPosASL = AGLToASL (player getRelPos [10, -45]);\ntoPosASL = AGLToASL (player getRelPos [10, 45]);\nfromControlPointOffset = controlPointASL vectorDiff fromPosASL;\ntoControlPointOffset = toPosASL vectorDiff controlPointASL;\nonEachFrame\n{\n    hintSilent format [\"Interval: %1\", interval];\n    box setVelocityTransformation\n    [\n        fromPosASL vectorAdd (fromControlPointOffset vectorMultiply interval),\n        controlPointASL vectorAdd (toControlPointOffset vectorMultiply interval),\n        [0,0,0],\n        [0,0,0],\n        [0,1,0],\n        [1,0,0],\n        [0,0,1],\n        [0,1,0],\n        interval\n    ];\n};\n```","code":["disableSerialization;\nplayer setDir 0;\ninterval = 0;\n_disp = findDisplay 46 createDisplay \"RscDisplayEmpty\";\n_ctrl = _disp ctrlCreate [\"RscSlider\", -1];\n_ctrl ctrlSetPosition [safeZoneX + 0.1, 1, safeZoneW - 0.2, 0.1];\n_ctrl ctrlSetActiveColor [1,0,0,1];\n_ctrl ctrlCommit 0;\n_ctrl sliderSetPosition 0;\n_ctrl sliderSetRange [0,1];\n_ctrl sliderSetSpeed [0.1,0.5];\n_ctrl ctrlAddEventHandler [\"SliderPosChanged\", {interval = _this select 1}];\nctrlSetFocus _ctrl;\nbox = \"Land_VR_Shape_01_cube_1m_F\" createVehicle [0,0,0];\ncontrolPointASL = AGLToASL (player getRelPos [70, -30]) vectorAdd [0, 0, 30];\nfromPosASL = AGLToASL (player getRelPos [10, -45]);\ntoPosASL = AGLToASL (player getRelPos [10, 45]);\nfromControlPointOffset = controlPointASL vectorDiff fromPosASL;\ntoControlPointOffset = toPosASL vectorDiff controlPointASL;\nonEachFrame\n{\n\thintSilent format [\"Interval: %1\", interval];\n\tbox setVelocityTransformation\n\t[\n\t\tfromPosASL vectorAdd (fromControlPointOffset vectorMultiply interval),\n\t\tcontrolPointASL vectorAdd (toControlPointOffset vectorMultiply interval),\n\t\t[0,0,0],\n\t\t[0,0,0],\n\t\t[0,1,0],\n\t\t[1,0,0],\n\t\t[0,0,1],\n\t\t[0,1,0],\n\t\tinterval\n\t];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocity","setVelocity","velocityModelSpace","setVelocityModelSpace","speed","moveTime","disableBrakes","brakesDisabled","getModelInfo"],"notes":[{"user":"ffur2007slx2_5","date":"2014-08-04T12:35:00Z","text":"(A3 1.24) Generally speaking setVelocityTransformation is more likely a combination of setPosASL, setVectorDirAndUp (or BIS_fnc_setPitchBank) and time multiplier.\nIt can be used as a position tracker with all necessary information collected, copied and then released within one function. Here’s a simple reproduction on how setVelocityTransformation works in game:\n\n```sqf\nprivate [\"_dataOld\",\"_dataNext\",\"_capturedData\",\"_obj\",\"_fps\",\"_startTrackingTime\",\"_stepOld\",\"_stepNext\",\"_tracker\",\"_tempTime\"];\n_stepOld = 0;\n_tempTime = 0;\n_stepNext = 1;\nwhile {true} do\n{\n    _capturedData = _capturedData + [[getPosASL _obj,velocity _obj,vectorDir _obj,vectorUp _obj]];\n    sleep _fps;\n    _tempTime = _tempTime + _fps;\n    if (_tempTime >= _startTrackingTime) then\n    {\n        _dataOld = _capturedData select _stepOld;\n        _dataNext = _capturedData select _stepNext;\n        _stepOld = _stepOld + 1;\n        _stepNext = if (_stepNext >= (count _capturedData)) then { _stepOld } else { _stepNext + 1 };\n        _tracker setVelocityTransformation [\n            _dataOld select 0,\n            _dataNext select 0,\n            _dataOld select 1,\n            _dataNext select 1,\n            _dataOld select 2,\n            _dataNext select 2,\n            _dataOld select 3,\n            _dataNext select 3,\n            1\n        ];\n    };\n};\n```\n\nTracker starts coping the route and stance from the object when time start counting. TimeDiff determines the distance multiply between the current position and the next position."},{"user":"DrSova","date":"2020-07-04T08:11:00Z","text":"You can't apply this command to the dead body in ragdoll."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setViewDistance","operator":null,"title":"setViewDistance","type":"command","url":"https://community.bistudio.com/wiki/setViewDistance","revid":364699,"updated":"2024-05-25T17:28:31Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Set rendering distance. Setting view distance to <= 0 resets the value to the client's options (set in `Options → Video → General → Visibility → Overall`).\n\n> [!NOTE]\n> In previous versions, client's max view distance was limited by the server's view distance.\n\n> [!IMPORTANT]\n> View distance also defines the maximum distance between a unit and any other unit they can know about.\n> Higher view distance will involve more AI simulation cycles for every unit, which causes low performance. See Arma 3: Performance Optimisation.\n\n| Game | min. scripted | min. UI | default | max. UI | max. scripted |\n|---|---|---|---|---|---|\n| Arma 3 | 200 | 500 | **1600** | 12000 | 40000 |\n| Arma 2: Operation Arrowhead | 200 | 500 | **2500** | 10000 | 15000 |\n| Arma 2 | 200 | 500 | **3000** | 10000 | 15000 |\n| Armed Assault | 200 | 500 | **1200** | 10000 | 15000 |\n| Operation Flashpoint | 500 | 500 | **900** | 5000 | 5000 |","syntaxes":[{"syntax":"setViewDistance distance","since":null,"effect":null,"exec":null,"params":[{"name":"distance","type":"Number","optional":false,"default":null,"description":"distance in metres; Arma 3 v1.00 a negative value resets the view distance to user video setting","types":["Number"],"since":null,"text":"distance: Number - distance in metres; Arma 3 v1.00 a negative value resets the view distance to user video setting"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"distance","types":["Number"]}}],"examples":[{"text":"```sqf\nsetViewDistance 2250;\n```","code":["setViewDistance 2250;"]},{"text":"```sqf\nsetViewDistance -1; // reset view distance in Arma 3\n```","code":["setViewDistance -1; // reset view distance in Arma 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["viewDistance","setDetailMapBlendPars","setTerrainGrid","getObjectViewDistance","setObjectViewDistance"],"notes":[],"categories":[]},{"name":"setVisibleIfTreeCollapsed","operator":null,"title":"setVisibleIfTreeCollapsed","type":"command","url":"https://community.bistudio.com/wiki/setVisibleIfTreeCollapsed","revid":378401,"updated":"2026-04-04T08:10:10Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets whether or not the object is visible even if the tree is collapsed.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map setVisibleIfTreeCollapsed [object, visible]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"object","type":"EditorObject","optional":false,"default":null,"description":null,"types":["Editor Object"],"since":null,"text":"object: EditorObject"},{"name":"visible","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"visible: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object, visible]","types":["Array"]}}],"examples":[{"text":"```sqf\n_map setVisibleIfTreeCollapsed [\"_unit_0\", true];\n```","code":["_map setVisibleIfTreeCollapsed [\"_unit_0\", true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWantedRPMRTD","operator":null,"title":"setWantedRPMRTD","type":"command","url":"https://community.bistudio.com/wiki/setWantedRPMRTD","revid":377768,"updated":"2026-01-03T01:32:15Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Tell the helicopter engine RPMs to reach the given value within a period of time. The simulation will try to reach the RPMs, but it does not guarantee it will reach the precise value!\n- engine index 0: engine #1\n- engine index 1: engine #2\n- engine index 2: engine #3\n- engine index -1: all engines\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD setWantedRPMRTD [value, time, engineIndex]","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD : ObjectRTD - helicopter"},{"name":"value","type":"Number","optional":false,"default":null,"description":"engine RPMs","types":["Number"],"since":null,"text":"value : Number - engine RPMs"},{"name":"time","type":"Number","optional":false,"default":null,"description":"time to reach desired RPMs (seconds)","types":["Number"],"since":null,"text":"time : Number - time to reach desired RPMs (seconds)"},{"name":"engineIndex","type":"Number","optional":false,"default":null,"description":"engine index","types":["Number"],"since":null,"text":"engineIndex : Number - engine index"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"[value, time, engineIndex]","types":["Array"]}}],"examples":[{"text":"```sqf\nvehicle player setWantedRPMRTD [2500, 30, 0];\n```","code":["vehicle player setWantedRPMRTD [2500, 30, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setEngineRPMRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaterFillPercentage","operator":null,"title":"setWaterFillPercentage","type":"command","url":"https://community.bistudio.com/wiki/setWaterFillPercentage","revid":363324,"updated":"2024-03-26T16:41:40Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Set an object's water filling.","syntaxes":[{"syntax":"obj setWaterFillPercentage level","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"object to manipulate","types":["Object"],"since":null,"text":"obj: Object - object to manipulate"},{"name":"level","type":"Number","optional":false,"default":null,"description":"water level in range 0..1 (empty to full)","types":["Number"],"since":null,"text":"level: Number - water level in range 0..1 (empty to full)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"level","types":["Number"]}}],"examples":[{"text":"```sqf\nif (getWaterLeakiness _myCar > 0 && surfaceIsWater getPosASL _myCar) then\n{\n    _myCar setWaterFillPercentage 1;\n    hint \"I told you not to go in the water!\";\n};\n```","code":["if (getWaterLeakiness _myCar > 0 && surfaceIsWater getPosASL _myCar) then\n{\n\t_myCar setWaterFillPercentage 1;\n\thint \"I told you not to go in the water!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaterLeakiness","getWaterLeakiness","getWaterFillPercentage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setWaterLeakiness","operator":null,"title":"setWaterLeakiness","type":"command","url":"https://community.bistudio.com/wiki/setWaterLeakiness","revid":363318,"updated":"2024-03-26T16:41:37Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.16"}],"since":{"game":"arma3","name":"Arma 3","version":"2.16"},"arma3_since":"2.16","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Set an object's water intake ratio when immersed.","syntaxes":[{"syntax":"obj setWaterLeakiness leakiness","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object","optional":false,"default":null,"description":"object to manipulate","types":["Object"],"since":null,"text":"obj: Object - object to manipulate"},{"name":"leakiness","type":"Number","optional":false,"default":null,"description":"in range 0..1 where 0 is waterproof and 1 is full leak","types":["Number"],"since":null,"text":"leakiness: Number - in range 0..1 where 0 is waterproof and 1 is full leak"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"obj","types":["Object"]},"right":{"text":"leakiness","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _veh = vehicle player;\nif (surfaceIsWater getPosASL _veh) then\n{\n    _veh setWaterLeakiness 1;\n};\n```","code":["private _veh = vehicle player;\nif (surfaceIsWater getPosASL _veh) then\n{\n\t_veh setWaterLeakiness 1;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getWaterLeakiness","setWaterFillPercentage","getWaterFillPercentage"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.16","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"setWaves","operator":null,"title":"setWaves","type":"command","url":"https://community.bistudio.com/wiki/setWaves","revid":349863,"updated":"2023-11-20T22:10:45Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Changes the waves value smoothly during the given time (in seconds). A time of zero means there will be an immediate change.\n\n**NOTE**: This command will have no effect (even though the value of waves changes) unless `Manual Override` option is selected in the editor in the Intel, which is normally off.","syntaxes":[{"syntax":"time setWaves value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n180 setWaves .5;\n```","code":["180 setWaves .5;"]},{"text":"```sqf\n0 setWaves 1;\n```","code":["0 setWaves 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waves","fog","overcast","setLightnings"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"setWaypointBehaviour","operator":null,"title":"setWaypointBehaviour","type":"command","url":"https://community.bistudio.com/wiki/setWaypointBehaviour","revid":340921,"updated":"2023-05-13T21:59:51Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Switches the unit behaviour when the waypoint becomes active.\n\nPossible values are:\n- \"UNCHANGED\"\n- \"CARELESS\"\n- \"SAFE\"\n- \"AWARE\"\n- \"COMBAT\"\n- \"STEALTH\"\n\nSee the AIBehaviour page for details of the effect of this command on AI units.","syntaxes":[{"syntax":"waypoint setWaypointBehaviour mode","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointBehaviour \"AWARE\";\n```","code":["[_grp, 2] setWaypointBehaviour \"AWARE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","AIBehaviour","waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointCombatMode","operator":null,"title":"setWaypointCombatMode","type":"command","url":"https://community.bistudio.com/wiki/setWaypointCombatMode","revid":377750,"updated":"2026-01-03T00:58:04Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes a group's combat mode when the waypoint becomes active.","syntaxes":[{"syntax":"waypoint setWaypointCombatMode mode","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"mode","type":"String","optional":false,"default":null,"description":"can be:\n- \"NO CHANGE\"\n- \"BLUE\"\n- \"GREEN\"\n- \"WHITE\"\n- \"YELLOW\"\n- \"RED\"","types":["String"],"since":null,"text":"mode: String - can be:\n- \"NO CHANGE\"\n- \"BLUE\"\n- \"GREEN\"\n- \"WHITE\"\n- \"YELLOW\"\n- \"RED\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointCombatMode \"RED\";\n```","code":["[_grp, 2] setWaypointCombatMode \"RED\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Combat Modes","setWaypointBehaviour"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointCompletionRadius","operator":null,"title":"setWaypointCompletionRadius","type":"command","url":"https://community.bistudio.com/wiki/setWaypointCompletionRadius","revid":377571,"updated":"2026-01-02T06:56:23Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The completion radius allows units to call the waypoint completed once they are inside of the given circle. If the given radius is less than unit’s or vehicle’s configured 'precision' then the latter is used. For example tank precision is 10m, if the given radius is 5m, the final radius will be 10m. For units in player’s group there is an additional multiplier x5 to the configured precision. Units that are fleeing and are not in player's Group will ignore the completion radius and would not be able to complete by proximity until they stop fleeing.","syntaxes":[{"syntax":"waypoint setWaypointCompletionRadius radius","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint:  Waypoint"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"radius","types":["Number"]}}],"examples":[{"text":"```sqf\n[grp, 2] setWaypointCompletionRadius 30;\n```","code":["[grp, 2] setWaypointCompletionRadius 30;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointDescription","operator":null,"title":"setWaypointDescription","type":"command","url":"https://community.bistudio.com/wiki/setWaypointDescription","revid":377757,"updated":"2026-01-03T00:58:15Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the description shown in the HUD while the waypoint is active.","syntaxes":[{"syntax":"waypoint setWaypointDescription text","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointDescription \"Move here.\";\n```","code":["[_grp, 2] setWaypointDescription \"Move here.\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointForceBehaviour","operator":null,"title":"setWaypointForceBehaviour","type":"command","url":"https://community.bistudio.com/wiki/setWaypointForceBehaviour","revid":377890,"updated":"2026-01-05T17:35:07Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Forces the behavior of waypoint, disables AUTOCOMBAT.","syntaxes":[{"syntax":"waypoint setWaypointForceBehaviour state","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"state","type":"Boolean","optional":false,"default":null,"description":"force or not","types":["Boolean"],"since":null,"text":"state: Boolean - force or not"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\n[grp, 2] setWaypointForceBehaviour true;\n```","code":["[grp, 2] setWaypointForceBehaviour true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointForceBehaviour","setWaypointBehaviour","waypointBehaviour","Mission Editor: Waypoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"setWaypointFormation","operator":null,"title":"setWaypointFormation","type":"command","url":"https://community.bistudio.com/wiki/setWaypointFormation","revid":377761,"updated":"2026-01-03T00:58:21Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Switches the group formation when the waypoint becomes active.\n\nPossible values are:\n- \"NO CHANGE\"\n- \"COLUMN\"\n- \"STAG COLUMN\"\n- \"WEDGE\"\n- \"ECH LEFT\"\n- \"ECH RIGHT\"\n- \"VEE\"\n- \"LINE\"\n- \"FILE\"\n- \"DIAMOND\"","syntaxes":[{"syntax":"waypoint setWaypointFormation formation","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"formation","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"formation: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"formation","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointFormation \"LINE\";\n```","code":["[_grp, 2] setWaypointFormation \"LINE\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointHousePosition","operator":null,"title":"setWaypointHousePosition","type":"command","url":"https://community.bistudio.com/wiki/setWaypointHousePosition","revid":377754,"updated":"2026-01-03T00:58:10Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"For waypoints attached to a house, this defines the target buildingPos index.","syntaxes":[{"syntax":"waypoint setWaypointHousePosition pos","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"pos","type":"Number","optional":false,"default":null,"description":"buildingPos index","types":["Number"],"since":null,"text":"pos: Number - buildingPos index"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"pos","types":["Number"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointHousePosition 1;\n```","code":["[_grp, 2] setWaypointHousePosition 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed","buildingPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointLoiterAltitude","operator":null,"title":"setWaypointLoiterAltitude","type":"command","url":"https://community.bistudio.com/wiki/setWaypointLoiterAltitude","revid":377129,"updated":"2026-01-01T10:23:44Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns loiter altitude to the provided waypoint.","syntaxes":[{"syntax":"waypoint setWaypointLoiterAltitude loiterAltitude","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"loiterAltitude","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"loiterAltitude: Number"}],"returns":{"type":"Nothing","types":[],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"loiterAltitude","types":["Number"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointLoiterAltitude 100;\n```","code":["[_grp, 2] setWaypointLoiterAltitude 100;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointLoiterAltitude"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"setWaypointLoiterRadius","operator":null,"title":"setWaypointLoiterRadius","type":"command","url":"https://community.bistudio.com/wiki/setWaypointLoiterRadius","revid":319763,"updated":"2022-05-13T09:24:51Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assignes loiter radius to waypoint","syntaxes":[{"syntax":"waypoint setWaypointLoiterRadius radius","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"radius","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"radius: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"radius","types":["Number"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointLoiterRadius 200;\n```","code":["[_grp, 2] setWaypointLoiterRadius 200;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","currentWaypoint","waypointSpeed","setWPPos"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"setWaypointLoiterType","operator":null,"title":"setWaypointLoiterType","type":"command","url":"https://community.bistudio.com/wiki/setWaypointLoiterType","revid":319603,"updated":"2022-05-13T09:24:33Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the waypoint loiter type.","syntaxes":[{"syntax":"waypoint setWaypointLoiterType type","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"type","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"type: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointLoiterType \"CIRCLE\";\n```","code":["[_grp, 2] setWaypointLoiterType \"CIRCLE\";"]},{"text":"```sqf\n[_grp, 2] setWaypointLoiterType \"CIRCLE_L\";\n```","code":["[_grp, 2] setWaypointLoiterType \"CIRCLE_L\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","currentWaypoint","waypointSpeed","setWPPos","waypointName"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"setWaypointName","operator":null,"title":"setWaypointName","type":"command","url":"https://community.bistudio.com/wiki/setWaypointName","revid":319666,"updated":"2022-05-13T09:24:40Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the waypoint name.","syntaxes":[{"syntax":"waypoint setWaypointName name","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp,2] setWaypointName \"myName\";\n```","code":["[_grp,2] setWaypointName \"myName\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addWaypoint","waypointName","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointLoiterRadius","setWaypointLoiterType","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setWaypointPosition","operator":null,"title":"setWaypointPosition","type":"command","url":"https://community.bistudio.com/wiki/setWaypointPosition","revid":377573,"updated":"2026-01-02T06:56:26Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attempts to move given waypoint to a random position inside a circle with the given center and radius.\nThe waypoint will be placed similar to `\"NONE\"` attribute in setVehiclePosition, even if the radius is 0, which means it could still be off center. In order to force waypoint to the exact position, similar to `\"CAN_COLLIDE\"` attribute, use a negative radius (see #Example 2).","syntaxes":[{"syntax":"waypoint setWaypointPosition [center, radius]","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"center","type":"Object or PositionAGL or PositionASL if radius is negative","optional":false,"default":null,"description":null,"types":["Object","PositionAGL","PositionASL"],"since":null,"text":"center: Object or PositionAGL or PositionASL if *radius* is negative"},{"name":"radius","type":"Number","optional":false,"default":null,"description":"random placement radius in meters. Set it to -1 and convert center to PositionASL for the exact center placement","types":["Number"],"since":null,"text":"radius: Number - random placement radius in meters. Set it to -1 and convert center to PositionASL for the exact center placement"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"[center, radius]","types":["Array"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointPosition [position player, 0];\n```","code":["[_grp, 2] setWaypointPosition [position player, 0];"]},{"text":"Exact placement using a negative *radius* and PositionASL:\n\n```sqf\n_wp setWaypointPosition [getPosASL player, -1];\n```","code":["_wp setWaypointPosition [getPosASL player, -1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointPosition","setWPPos","waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[{"user":"Killzone_Kid","date":"2018-11-14T22:52:00Z","text":"If you want AI to understand height of the waypoint, for example set waypoint at the top of Military Cargo Tower, use #Example 2 with position in ASL format and -1 radius."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointScript","operator":null,"title":"setWaypointScript","type":"command","url":"https://community.bistudio.com/wiki/setWaypointScript","revid":377760,"updated":"2026-01-03T00:58:20Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attaches a script to a scripted waypoint. In early versions of Arma, command consisted of a script name and additional script arguments and the script had to use SQS Syntax. The script receives the following arguments in _this variable: [group, position, target] + [the optional passed arguments]. The optional arguments are appended to the end of the arguments array.\n\n> [!NOTE]\n> **Arma 3:** In Arma 3, *command* argument can be a reference to .sqf script (it will have to explicitly end with **`.sqf`**) or a reference to `.sqs` script.","syntaxes":[{"syntax":"waypoint setWaypointScript command","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"command","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointScript \"find.sqs player\";\n```","code":["[_grp, 2] setWaypointScript \"find.sqs player\";"]},{"text":"```sqf\n[_grp, 2] setWaypointScript \"somescript.sqf [1,2,3,4,5,6,7,8]\";\n```","code":["[_grp, 2] setWaypointScript \"somescript.sqf [1,2,3,4,5,6,7,8]\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointSpeed","operator":null,"title":"setWaypointSpeed","type":"command","url":"https://community.bistudio.com/wiki/setWaypointSpeed","revid":377759,"updated":"2026-01-03T00:58:18Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Switches the group speed mode when the waypoint becomes active.\n\nPossible values are:\n- \"UNCHANGED\"\n- \"LIMITED\"\n- \"NORMAL\"\n- \"FULL\"","syntaxes":[{"syntax":"waypoint setWaypointSpeed mode","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointSpeed \"FULL\";\n```","code":["[_grp, 2] setWaypointSpeed \"FULL\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointStatements","operator":null,"title":"setWaypointStatements","type":"command","url":"https://community.bistudio.com/wiki/setWaypointStatements","revid":377577,"updated":"2026-01-02T06:56:32Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The waypoint is done only when the condition is fulfilled. When the waypoint is done, the statement expression is executed.\n\nWithin the Condition & Statement code string:\n- this refers to the group leader\n- thisList refers to the group's units\n\n> [!IMPORTANT]\n> The **Condition** code is evaluated on the group owner's machine. When condition returns true, for some strange reason, the condition is evaluated one more time. The **OnActivation** code is executed **globally**, a.k.a on every client! See Waypoints.","syntaxes":[{"syntax":"waypoint setWaypointStatements [condition, statement]","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"condition","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"condition: String"},{"name":"statement","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"statement: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"[condition, statement]","types":["Array"]}}],"examples":[{"text":"```sqf\n_waypoint setWaypointStatements [\"true\", \"hint 'hello'; hint 'goodbye'\"];\n```","code":["_waypoint setWaypointStatements [\"true\", \"hint 'hello'; hint 'goodbye'\"];"]},{"text":"```sqf\n_waypoint setWaypointStatements [\"true\", \"diag_log ['GroupLeader: ', this]; diag_log ['Units: ', thislist]\"];\n```","code":["_waypoint setWaypointStatements [\"true\", \"diag_log ['GroupLeader: ', this]; diag_log ['Units: ', thislist]\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointStatements"],"notes":[{"user":"SilentSpike","date":"2016-05-21T16:19:00Z","text":"Within the completion statement currentWaypoint will give the index of the waypoint being completed (as opposed to the following one).\n\nThis is particularly useful if you need a self deleting waypoint:\n\n```sqf\n_waypoint setWaypointStatements [\"true\", \"deleteWaypoint [group this, currentWaypoint group this]\"]\n```"},{"user":"RHfront","date":"2017-05-09T16:35:00Z","text":"The condition block carries the same rules as functions which return a value.\nThe return value must be a Boolean.\nOne can bypass the use of triggers in this manner:\n\n```sqf\n_waypoint setWaypointStatements [\"code code code; _returnBool\", \"onActivation block;\"];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointTimeout","operator":null,"title":"setWaypointTimeout","type":"command","url":"https://community.bistudio.com/wiki/setWaypointTimeout","revid":377755,"updated":"2026-01-03T00:58:12Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines the time between condition satisfaction and waypoint finish (randomly from min to max, with an average value mid).","syntaxes":[{"syntax":"waypoint setWaypointTimeout [min, mid, max]","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"min","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"min: Number"},{"name":"mid","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"mid: Number"},{"name":"max","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"max: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"[min, mid, max]","types":["Array"]}}],"examples":[{"text":"```sqf\n[_grp, 2] setWaypointTimeout [5, 10, 6];\n```","code":["[_grp, 2] setWaypointTimeout [5, 10, 6];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointTimeoutCurrent","waypointSpeed"],"notes":[{"user":"Lucky44","date":"2010-12-12T00:32:00Z","text":"The example doesn't seem to make sense, according to the listed syntax. It seems to set a Max time greater than the Mid time."},{"user":"Tom 48 97","date":"2010-12-12T03:30:00Z","text":"If mid is greater than max, the result will be really near the mid value.\nResults with the values of the example: 8.237, 9.383, 10.425, 9.417, 9.43401, 10.425, 9.90601, 9.96701, 9.42401, 9.42502, 9.96698, 9.89999..."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointType","operator":null,"title":"setWaypointType","type":"command","url":"https://community.bistudio.com/wiki/setWaypointType","revid":377747,"updated":"2026-01-03T00:58:00Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the waypoint type of given waypoint.\n\nMore details at Waypoints.","syntaxes":[{"syntax":"waypoint setWaypointType type","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"type","type":"String","optional":false,"default":null,"description":"waypoint type. Can be:\n- `\"MOVE\"`\n- `\"DESTROY\"`\n- `\"GETIN\"`\n- `\"SAD\"` *(Seek And Destroy)*\n- `\"JOIN\"`\n- `\"LEADER\"`\n- `\"GETOUT\"`\n- `\"CYCLE\"`\n- `\"LOAD\"`\n- `\"UNLOAD\"`\n- `\"TR UNLOAD\"`\n- `\"HOLD\"`\n- `\"SENTRY\"`\n- `\"GUARD\"` (used with GUARDED BY trigger or createGuardedPoint)\n- `\"TALK\"`\n- `\"SCRIPTED\"`\n- `\"SUPPORT\"`\n- `\"GETIN NEAREST\"`\n- `\"DISMISS\"`\n- `\"LOITER\"` (Arma 3)\n- Arma 3 v1.34 `\"HOOK\"` (slingload object)\n- Arma 3 v1.34 `\"UNHOOK\"` (slingload drop)\n- `\"AND\"` (only for game logics)\n- `\"OR\"` (only for game logics)","types":["String"],"since":null,"text":"type: String - waypoint type. Can be:\n- `\"MOVE\"`\n- `\"DESTROY\"`\n- `\"GETIN\"`\n- `\"SAD\"` *(Seek And Destroy)*\n- `\"JOIN\"`\n- `\"LEADER\"`\n- `\"GETOUT\"`\n- `\"CYCLE\"`\n- `\"LOAD\"`\n- `\"UNLOAD\"`\n- `\"TR UNLOAD\"`\n- `\"HOLD\"`\n- `\"SENTRY\"`\n- `\"GUARD\"` (used with GUARDED BY trigger or createGuardedPoint)\n- `\"TALK\"`\n- `\"SCRIPTED\"`\n- `\"SUPPORT\"`\n- `\"GETIN NEAREST\"`\n- `\"DISMISS\"`\n- `\"LOITER\"` (Arma 3)\n- Arma 3 v1.34 `\"HOOK\"` (slingload object)\n- Arma 3 v1.34 `\"UNHOOK\"` (slingload drop)\n- `\"AND\"` (only for game logics)\n- `\"OR\"` (only for game logics)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"type","types":["String"]}}],"examples":[{"text":"```sqf\n_myWaypoint setWaypointType \"HOLD\";\n```","code":["_myWaypoint setWaypointType \"HOLD\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["2D Editor: Waypoints","waypointType"],"notes":[{"user":"ArmAtec","date":"2007-11-23T07:44:00Z","text":"Using **MOVE** on a game logic group will move the logic to the set location just like setPos. In the editor, only **AND** and **OR** type of waypoints are available for GAME LOGICS but you can use CYCLE type as well with setWaypointType."},{"user":"RHfront","date":"2017-05-06T16:09:00Z","text":"To use the **LAND** function in a waypoint, you must set *\"A3\\functions_f\\waypoints\\fn_wpLand.sqf\"* as the script for that waypoint."},{"user":"Nelis75733126","date":"2017-05-30T09:14:00Z","text":"In **Arma 3 v1.70**, if you add a **MOVE** waypoint very soon after a **LOITER** waypoint, (assuming that the index of the MOVE waypoint is HIGHER than the index of the LOITER waypoint) then the LOITER waypoint will be considered as a MOVE waypoint.\n\nAnd, if you add another waypoint after ( for example ) more than 1 second after adding the LOITER waypoint,\nthen the LOITER waypoint will never complete even when its condition has been met.\n\nThere are two ways to quit an existing LOITER waypoint that was added more than about 1 second before adding a MOVE waypoint:\n- use the setCurrentWaypoint command\n- create a waypoint that has the same ID as the LOITER waypoint.\nThe difference between those two methods is that the latter prevents the LOITER waypoint from executing its statement."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWaypointVisible","operator":null,"title":"setWaypointVisible","type":"command","url":"https://community.bistudio.com/wiki/setWaypointVisible","revid":377758,"updated":"2026-01-03T00:58:16Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Sets the visibility of the given waypoint in 3D HUD view (for map visibility see showWaypoint).","syntaxes":[{"syntax":"waypoint setWaypointVisible visible","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"visible","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"visible: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"visible","types":["Boolean"]}}],"examples":[{"text":"```sqf\n[grp, 2] setWaypointVisible false;\n```","code":["[grp, 2] setWaypointVisible false;"]},{"text":"```sqf\n[group player, currentWaypoint group player] setWaypointVisible false;\n```","code":["[group player, currentWaypoint group player] setWaypointVisible false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointVisible","showWaypoint"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setWeaponReloadingTime","operator":null,"title":"setWeaponReloadingTime","type":"command","url":"https://community.bistudio.com/wiki/setWeaponReloadingTime","revid":364086,"updated":"2024-05-03T19:33:29Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets reloading **phase** on the given weapon's current ammo round.\n\n> [!IMPORTANT]\n> This command does **not** change a weapon's (e.g soldier's rifle) *magazine* reloading time but changes **the ammo reloading state** before the next round is shot.","syntaxes":[{"syntax":"vehicle setWeaponReloadingTime [gunner, muzzleName, reloadTime]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"gunner","type":"Object","optional":false,"default":null,"description":"alive and able gunner operating the targeted turret","types":["Object"],"since":null,"text":"gunner: Object - alive and able gunner operating the targeted turret"},{"name":"muzzleName","type":"String","optional":false,"default":null,"description":"turret's muzzle","types":["String"],"since":null,"text":"muzzleName: String - turret's muzzle"},{"name":"reloadTime","type":"Number","optional":false,"default":null,"description":"in range 0..1 where 0: reload complete, 1: reload started","types":["Number"],"since":null,"text":"reloadTime: Number - in range 0..1 where 0: reload complete, 1: reload started"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if given weapon is found","text":"Boolean - true if given weapon is found"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[gunner, muzzleName, reloadTime]","types":["Array"]}}],"examples":[{"text":"```sqf\n_success = _vehicle setWeaponReloadingTime [gunner vehicle player, currentMuzzle gunner vehicle player, 0.5];\n```","code":["_success = _vehicle setWeaponReloadingTime [gunner vehicle player, currentMuzzle gunner vehicle player, 0.5];"]},{"text":"Boost RPM:\n\n```sqf\nunit addEventHandler [\"Fired\", {\n    _this # 0 setWeaponReloadingTime [_this # 0, _this # 2, 1/3];\n}];\n```","code":["unit addEventHandler [\"Fired\", {\n\t_this # 0 setWeaponReloadingTime [_this # 0, _this # 2, 1/3];\n}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponReloadingTime","weapons","magazines","selectWeapon","loadMagazine","weaponState","reload"],"notes":[{"user":".kju","date":"","text":"The description is confusing to me. What the command essential does is to set the reloading state/time of the given weapon. For example you can fire a missile, and make the weapon available to fire again instantly if you apply 0.\nOr you can delay or stop the reload event indefinitely. The 0-1 range is a percentage - the reload time is taken from the weapons's config value (either reloadTime or magazineReloadTime - not sure). The effect is one time only each - it does not modify the weapon's general reload time.\n\nWorks also for infantry weapons - probably useful weapons with longer reload time like sniper weapons or launchers:\n player setWeaponReloadingTime [player,currentWeapon player,0];\nNo idea what's point of the return value."},{"user":"Demellion","date":"","text":"Note that **setWeaponReloadingTime** is only having effect on a current weapon state (loaded projectile) so since the projectile is fired the next one will be reverted to a weapon config defaults. To keep the fire rate speed changed over time, use this code:\n\n```sqf\nplayer addEventHandler [\"FiredMan\", {\n    params [\"\", \"_weapon\", \"_muzzle\"];\n    private _type = _weapon call BIS_fnc_itemType;\n    private _time = -1;\n    switch (_type select 1) do {\n        case \"SniperRifle\" : {_time = 0.5};\n        case \"AssaultRifle\" : {};\n        case \"Handgun\" : {};\n        case \"Rifle\" : {};\n        case \"SubmachineGun\" : {};\n        case \"MachineGun\" : {};\n        case \"Mortar\" : {};\n        case \"GrenadeLauncher\" : {};\n        case \"BombLauncher\" : {};\n        case \"MissileLauncher\" : {};\n        case \"RocketLauncher\" : {};\n        case \"Cannon\" : {};\n        case \"Throw\" : {};\n    };\n    if (_time isEqualTo -1) exitWith {};\n    (vehicle player) setWeaponReloadingTime [(vehicle player), _muzzle, _time];\n}];\n```\n\nThis Event Handler makes the gun of specific type shoot at a desired rate on each weapon state (sniper rifle will shoot 50% faster in this example). For more information about weapon kinds are there, visit BIS_fnc_itemType."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"setWeaponZeroing","operator":null,"title":"setWeaponZeroing","type":"command","url":"https://community.bistudio.com/wiki/setWeaponZeroing","revid":348618,"updated":"2023-11-08T13:45:39Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets zeroing of given weapon and muzzle for given unit or vehicle.","syntaxes":[{"syntax":"object setWeaponZeroing [weaponClass, muzzleClass, zeroingIndex]","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"object: Object - unit or vehicle"},{"name":"weaponClass","type":"String","optional":false,"default":null,"description":"class name of weapon","types":["String"],"since":null,"text":"weaponClass: String - class name of weapon"},{"name":"muzzleClass","type":"String","optional":false,"default":null,"description":"class name of the muzzle","types":["String"],"since":null,"text":"muzzleClass: String - class name of the muzzle"},{"name":"zeroingIndex","type":"Number","optional":false,"default":null,"description":"zeroing index. See currentZeroing","types":["Number"],"since":null,"text":"zeroingIndex: Number - zeroing index. See currentZeroing"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if successful, otherwise false is returned (e.g. weapon, muzzle, or zeroing index is invalid)","text":"Boolean - true if successful, otherwise false is returned (e.g. weapon, muzzle, or zeroing index is invalid)"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"[weaponClass, muzzleClass, zeroingIndex]","types":["Array"]}}],"examples":[{"text":"```sqf\nplayer setWeaponZeroing [\"arifle_MX_GL_F\", \"GL_3GL_F\", 8]; // Set zeroing for underbarrel grenade launcher to 400m\n```","code":["player setWeaponZeroing [\"arifle_MX_GL_F\", \"GL_3GL_F\", 8]; // Set zeroing for underbarrel grenade launcher to 400m"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["currentZeroing"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"setWind","operator":null,"title":"setWind","type":"command","url":"https://community.bistudio.com/wiki/setWind","revid":348903,"updated":"2023-11-08T14:39:59Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"description":"Set current or permanent wind vector.\n\n> [!IMPORTANT]\n> The effect is global only if it is executed on the server. Wind set locally will sync back to server value in a while.","syntaxes":[{"syntax":"setWind [x, y, forced]","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"easterly component (in m/s, positive = to the east)","types":["Number"],"since":null,"text":"x: Number - easterly component (in m/s, positive = to the east)"},{"name":"y","type":"Number","optional":false,"default":null,"description":"northerly component (in m/s, positive = to the north)","types":["Number"],"since":null,"text":"y: Number - northerly component (in m/s, positive = to the north)"},{"name":"forced","type":"Boolean","optional":true,"default":"false","description":"set to true to lock the wind to constantly blows in set direction","types":["Boolean"],"since":null,"text":"forced: Boolean - (Optional, default false) set to true to lock the wind to constantly blows in set direction"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[x, y, forced]","types":["Array"]}}],"examples":[{"text":"```sqf\nsetWind [10, 10, true];\n```","code":["setWind [10, 10, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["wind","setWindDir","gusts","setGusts"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"setWindDir","operator":null,"title":"setWindDir","type":"command","url":"https://community.bistudio.com/wiki/setWindDir","revid":377549,"updated":"2026-01-02T06:54:45Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"global","server_exec":true},"exec":null,"description":"Changes the wind direction smoothly.","syntaxes":[{"syntax":"time setWindDir value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":"transition time in seconds. `0` will cause the change to be immediate","types":["Number"],"since":null,"text":"time: Number - transition time in seconds. `0` will cause the change to be immediate"},{"name":"value","type":"Number","optional":false,"default":null,"description":"azimuth","types":["Number"],"since":null,"text":"value: Number - azimuth"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}},{"syntax":"setWindDir direction","since":null,"effect":null,"exec":null,"params":[{"name":"direction","type":"Position2D","optional":false,"default":null,"description":"flat wind direction and strength","types":["Position2D"],"since":null,"text":"direction: Position2D - flat wind direction and strength"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"direction","types":["Position2D"]}}],"examples":[{"text":"```sqf\n60 setWindDir 180;\n```","code":["60 setWindDir 180;"]},{"text":"```sqf\nsetWindDir [1, -15];\n```","code":["setWindDir [1, -15];"]}],"multiplayer":"Effect is global only when executed on the server. On clients wind direction will sync to server value in a while.","problems":null,"aliases":[],"see_also":["windDir"],"notes":[{"user":"Waffle SS.","date":"2014-04-12T20:46:00Z","text":"Seems to make wind [0, 0] in MP. (Arma 3 v1.00)"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]},{"name":"setWindForce","operator":null,"title":"setWindForce","type":"command","url":"https://community.bistudio.com/wiki/setWindForce","revid":322971,"updated":"2022-06-28T21:42:53Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set max. wind overall wind changes in time. A time of zero means there will be an immediate change. A wind level of zero is minimal changes and a wind level of one means that wind can change rapidly.","syntaxes":[{"syntax":"time setWindForce wind","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"wind","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"wind: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"wind","types":["Number"]}}],"examples":[{"text":"```sqf\n1800 setWindForce 0.5;\n```","code":["1800 setWindForce 0.5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWindStr","setWind"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setWindStr","operator":null,"title":"setWindStr","type":"command","url":"https://community.bistudio.com/wiki/setWindStr","revid":370475,"updated":"2024-12-16T18:10:00Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Changes the wind strength smoothly during the given time (in seconds). A time of zero means there will be an immediate change.","syntaxes":[{"syntax":"time setWindStr value","since":null,"effect":null,"exec":null,"params":[{"name":"time","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"time: Number"},{"name":"value","type":"Number","optional":false,"default":null,"description":"new value in range 0..1","types":["Number"],"since":null,"text":"value: Number - new value in range 0..1"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"time","types":["Number"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\n60 setWindStr 0.8; // set the wind strength to 0.8 gradually over the next 60 seconds\n```","code":["60 setWindStr 0.8; // set the wind strength to 0.8 gradually over the next 60 seconds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWind","setWindForce"],"notes":[{"user":"Sa-Matra","date":"2022-08-01T09:39:46Z","text":"This weird command affects `setFog` by limiting maximum number of fogValue you can have. If you do `0 setWindStr 1`, setting any fog with time > 0 will reduce the fog to 0 over provided time. Setting fog instantly with time = 0 will set the desired value properly though. The formula is: max fogValue = 1 - windStr"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"setWingForceScaleRTD","operator":null,"title":"setWingForceScaleRTD","type":"command","url":"https://community.bistudio.com/wiki/setWingForceScaleRTD","revid":377776,"updated":"2026-01-03T01:32:29Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Set effectivity of wings. \n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"helicopterRTD setWingForceScaleRTD [leftHorizontal, rightHorizontal, vertical]","since":null,"effect":null,"exec":null,"params":[{"name":"helicopterRTD","type":"ObjectRTD","optional":false,"default":null,"description":"helicopter","types":["Object"],"since":null,"text":"helicopterRTD: ObjectRTD - helicopter"},{"name":"leftHorizontal","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"leftHorizontal: Number"},{"name":"rightHorizontal","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"rightHorizontal: Number"},{"name":"vertical","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"vertical: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"helicopterRTD","types":["Object"]},"right":{"text":"[leftHorizontal, rightHorizontal, vertical]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"setWPPos","operator":null,"title":"setWPPos","type":"command","url":"https://community.bistudio.com/wiki/setWPPos","revid":377575,"updated":"2026-01-02T06:56:29Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.21"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets waypoint position.\n\n> [!NOTE]\n> This command is identical to `setWaypointPosition [pos, -1]` (see setWaypointPosition description for more information).","syntaxes":[{"syntax":"waypoint setWPPos pos","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"pos","type":"PositionAGL","optional":false,"default":null,"description":null,"types":["PositionAGL"],"since":null,"text":"pos: PositionAGL"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"pos","types":["PositionAGL"]}}],"examples":[{"text":"```sqf\n[_groupOne, 1] setWPPos markerPos \"MarkerOne\";\n```","code":["[_groupOne, 1] setWPPos markerPos \"MarkerOne\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypoints","waypointSpeed"],"notes":[{"user":"Killzone_Kid","date":"2018-11-15T14:27:00Z","text":"Even though this command can accept Position2D, it is better to always explicitly state the elevation of waypoint by providing PositionAGL."}],"categories":[]},{"name":"show3DIcons","operator":null,"title":"show3DIcons","type":"command","url":"https://community.bistudio.com/wiki/show3DIcons","revid":363229,"updated":"2024-03-26T10:51:07Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle the drawing of 3D icons.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map show3DIcons bool","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showChat","operator":null,"title":"showChat","type":"command","url":"https://community.bistudio.com/wiki/showChat","revid":310212,"updated":"2022-05-05T13:10:43Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Shows/hides the whole chat window.","syntaxes":[{"syntax":"showChat bool","since":null,"effect":null,"exec":null,"params":[{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowChat false;\n```","code":["showChat false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownChat"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"showCinemaBorder","operator":null,"title":"showCinemaBorder","type":"command","url":"https://community.bistudio.com/wiki/showCinemaBorder","revid":310208,"updated":"2022-05-05T13:10:42Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Forces drawing of cinema borders when using custom camera camCreate. This is normally used in cutscenes to indicate player has no control.","syntaxes":[{"syntax":"showCinemaBorder show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowCinemaBorder false;\n```","code":["showCinemaBorder false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showHUD"],"notes":[],"categories":[]},{"name":"showCommandingMenu","operator":null,"title":"showCommandingMenu","type":"command","url":"https://community.bistudio.com/wiki/showCommandingMenu","revid":363591,"updated":"2024-04-07T18:31:09Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Create the commanding menu described by the given config class or menu name. When the name is empty, the current menu is hidden.\n\nIf commanding menu has \"expression\" set up, the expression will receive the following arguments when user activated the menu item:\n- Local variable `_target`: Object - Target under the cursor. This works in both 3D and 2D (when cursor is over the unit icon on the map).\n- Local variable `_pos`: Array - Cursor position.\n- Local variable `_is3D`: Boolean - false if cursor is over the map, otherwise true.","syntaxes":[{"syntax":"showCommandingMenu name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"class name or user menu name (with \"#USER:\" prefix and \"_#\" page number suffix, where # is the page number starting with 0).","types":["String"],"since":null,"text":"name: String - class name or user menu name (with \"#USER:\" prefix and \"_#\" page number suffix, where # is the page number starting with 0)."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nshowCommandingMenu \"\";\n```","code":["showCommandingMenu \"\";"]},{"text":"```sqf\nshowCommandingMenu \"MyClassName\";\n```","code":["showCommandingMenu \"MyClassName\";"]},{"text":"```sqf\nshowCommandingMenu \"#USER:Tag_Menu_myMenu_0\";\n```","code":["showCommandingMenu \"#USER:Tag_Menu_myMenu_0\";"]},{"text":"```sqf\nshowCommandingMenu \"RscMainMenu\";\n```","code":["showCommandingMenu \"RscMainMenu\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["commandingMenu","Arma 3: Communication Menu","BIS_fnc_createMenu"],"notes":[{"user":"LaKing","date":"2010-01-25T17:20:00Z","text":"```sqf\n// This script will create a custom menu, and display it once.\n\nMY_SUBMENU_inCommunication =\n[\n    [\"User submenu\", true],\n    [\"Option-1\", [2], \"\", -5, [[\"expression\", \"player sidechat \"\"-1\"\" \"]], \"0\", \"0\", \"\\ca\\ui\\data\\cursor_support_ca\"],\n    [\"Option 0\", [3], \"\", -5, [[\"expression\", \"player sidechat \"\" 0\"\" \"]], \"1\", \"0\", \"\\ca\\ui\\data\\cursor_support_ca\"],\n    [\"Option 1\", [4], \"\", -5, [[\"expression\", \"player sidechat \"\" 1\"\" \"]], \"1\", \"CursorOnGround\", \"\\ca\\ui\\data\\cursor_support_ca\"]\n];\n\nMY_MENU_inCommunication =\n[\n    // First array: \"User menu\" This will be displayed under the menu, bool value: has Input Focus or not.\n    // Note that as to version Template:arma2 1.05, if the bool value set to false, Custom Icons will not be displayed.\n    [\"User menu\", false],\n\n    // Syntax and semantics for following array elements:\n    // [\"Title_in_menu\", [assigned_key], \"Submenu_name\", CMD, [[\"expression\",script-string]], \"isVisible\", \"isActive\" <, optional icon path>]\n    // Title_in_menu: string that will be displayed for the player\n    // Assigned_key: 0 - no key, 1 - escape key, 2 - key-1, 3 - key-2, ... , 10 - key-9, 11 - key-0, 12 and up... the whole keyboard\n    // Submenu_name: User menu name string (eg \"#USER:MY_SUBMENU_NAME\" ), \"\" for script to execute.\n    // CMD: (for main menu:) CMD_SEPARATOR -1; CMD_NOTHING -2; CMD_HIDE_MENU -3; CMD_BACK -4; (for custom menu:) CMD_EXECUTE -5\n    // script-string: command to be executed on activation. (no arguments passed)\n    // isVisible - Boolean 1 or 0 for yes or no, - or optional argument string, eg: \"CursorOnGround\"\n    // isActive - Boolean 1 or 0 for yes or no - if item is not active, it appears gray.\n    // optional icon path: The path to the texture of the cursor, that should be used on this menuitem.\n    [\"First\", [0], \"\", -5, [[\"expression\", \"player sidechat \"\"First\"\" \"]], \"1\", \"1\"],\n    [\"Second\", [2], \"\", -5, [[\"expression\", \"player sidechat \"\"Second\"\" \"]], \"1\", \"1\"],\n    [\"Submenu\", [3], \"#USER:MY_SUBMENU_inCommunication\", -5, [[\"expression\", \"player sidechat \"\"Submenu\"\" \"]], \"1\", \"1\"]\n];\n\nshowCommandingMenu \"#USER:MY_MENU_inCommunication\";\n```\n\nAppendix, list of optional argument strings:\n- `AmmoLow`\n- `AreActions`\n- `CanAnswer`\n- `CanDeselectTeamFromBar`\n- `CanDeselectUnitFromBar`\n- `CanDeselectVehicleFromBar`\n- `CanSelectTeamFromBar`\n- `CanSelectUnitFromBar`\n- `CanSelectVehicleFromBar`\n- `CommandsToGunner`\n- `CommandsToPilot`\n- `CursorOnEmptyVehicle`\n- `CursorOnEnemy`\n- `CursorOnFriendly`\n- `CursorOnGround`\n- `CursorOnGroupMember`\n- `CursorOnGroupMemberSelected`\n- `CursorOnHoldingFire`\n- `CursorOnNeedFirstAID`\n- `CursorOnNeedHeal`\n- `CursorOnNotEmptySubgroups`\n- `CursorOnVehicleCanGetIn`\n- `FormationDiamond`\n- `FormationLine`\n- `FuelLow`\n- `HasRadio`\n- `HCCanDeselectTeamFromBar`\n- `HCCanDeselectUnitFromBar`\n- `HCCanSelectTeamFromBar`\n- `HCCanSelectUnitFromBar`\n- `HCCursorOnIcon`\n- `HCCursorOnIconenemy`\n- `HCCursorOnIconSelectable`\n- `HCCursorOnIconSelectableSelected`\n- `HCIsLeader`\n- `HCNotEmpty`\n- `Injured`\n- `IsAlone`\n- `IsAloneInVehicle`\n- `IsCommander`\n- `IsLeader`\n- `IsSelectedToAdd`\n- `IsTeamSwitch`\n- `IsWatchCommanded`\n- `IsXbox`\n- `Multiplayer`\n- `NotEmpty`\n- `NotEmptyBlueTeam`\n- `NotEmptyCommanders`\n- `NotEmptyGreenTeam`\n- `NotEmptyInVehicle`\n- `NotEmptyMainTeam`\n- `NotEmptyRedTeam`\n- `NotEmptySoldiers`\n- `NotEmptySubgroups`\n- `NotEmptyYellowTeam`\n- `PlayableLeader`\n- `PlayableSelected`\n- `PlayerOwnRadio`\n- `PlayerVehicleCanGetIn`\n- `SelectedTeam`\n- `SelectedUnit`\n- `SomeSelectedHaveTarget`\n- `SomeSelectedHoldingFire`\n- `VehicleCommander`"},{"user":"SilentSpike","date":"2016-07-23T15:40:00Z","text":"You can combine the argument strings (see the above note) together to create OR conditions.\n\nHence `\"HasRadioIsLeader\"` is true when the unit is a leader or has a radio."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showCompass","operator":null,"title":"showCompass","type":"command","url":"https://community.bistudio.com/wiki/showCompass","revid":310192,"updated":"2022-05-05T13:10:33Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides the compass on the map screen, if enabled for the mission and you possess the item. (default true)","syntaxes":[{"syntax":"showCompass show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowCompass false;\n```","code":["showCompass false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownCompass","visibleCompass","showGPS","showRadio","showWatch","showPad","showMap"],"notes":[],"categories":[]},{"name":"showCuratorCompass","operator":null,"title":"showCuratorCompass","type":"command","url":"https://community.bistudio.com/wiki/showCuratorCompass","revid":319912,"updated":"2022-05-13T09:25:43Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Hides or shows compass in curator interface.","syntaxes":[{"syntax":"showCuratorCompass bool","since":null,"effect":null,"exec":null,"params":[{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowCuratorCompass true;\n```","code":["showCuratorCompass true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"showGPS","operator":null,"title":"showGPS","type":"command","url":"https://community.bistudio.com/wiki/showGPS","revid":364728,"updated":"2024-05-30T11:49:12Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides the GPS receiver on the map screen, if enabled for the mission and you possess the item. (default false). \n\n> [!NOTE]\n> This command does nothing in Arma 3. Use the command openGPS that is available since v2.04.","syntaxes":[{"syntax":"showGPS show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowGPS true;\n```","code":["showGPS true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["openGPS","shownGPS","visibleGPS","showCompass","showRadio","showWatch","showPad"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showHUD","operator":null,"title":"showHUD","type":"command","url":"https://community.bistudio.com/wiki/showHUD","revid":377971,"updated":"2026-01-19T13:33:47Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enable / disable showing of HUD. Defines visibility of weapon crosshair and any informational tags that appear when pointing the weapon at an object as well as availability of the default action menu. Unfortunately, it also hides icons drawn with drawIcon3D.\n\n> [!NOTE]\n> **Arma 3:** **Since Arma 3 v1.50** there is a Description.ext's showHUD[] array param that is identical in format to the extended showHUD command.\n> When present, it will disable showHUD command entirely, allowing mission makers to permanently alter visibility of some HUD elements.\n>\n> **Since Arma 3 v2.04** it is possible to force drawing of drawIcon3D icons when HUD is hidden.\n> The icons will also show when custom camera is created and the view is switched to it via switchCamera or cameraEffect provided cameraEffectEnableHUD is enabled.\n> For more information see drawIcon3D.","syntaxes":[{"syntax":"showHUD enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}},{"syntax":"showHUD [scriptedHUD, info, radar, compass, direction, menu, group, cursors, panels, kills, showIcon3D]","since":null,"effect":null,"exec":null,"params":[{"name":"scriptedHUD","type":"Boolean","optional":false,"default":null,"description":"show scripted HUD such as weapon crosshair, action menu and overlays created with cutRsc and titleRsc. Same as showHUD's first syntax","types":["Boolean"],"since":null,"text":"scriptedHUD: Boolean - show scripted HUD such as weapon crosshair, action menu and overlays created with cutRsc and titleRsc. Same as showHUD's first syntax"},{"name":"info","type":"Boolean","optional":true,"default":"true","description":"show vehicle, soldier and weapon info","types":["Boolean"],"since":null,"text":"info: Boolean - (Optional, default true) show vehicle, soldier and weapon info"},{"name":"radar","type":"Boolean","optional":true,"default":"true","description":"show vehicle radar","types":["Boolean"],"since":null,"text":"radar: Boolean - (Optional, default true) show vehicle radar"},{"name":"compass","type":"Boolean","optional":true,"default":"true","description":"show vehicle compass","types":["Boolean"],"since":null,"text":"compass: Boolean - (Optional, default true) show vehicle compass"},{"name":"direction","type":"Boolean","optional":true,"default":"true","description":"show tank direction indicator. Not present in vanilla Arma 3","types":["Boolean"],"since":null,"text":"direction: Boolean - (Optional, default true) show tank direction indicator. Not present in vanilla Arma 3"},{"name":"menu","type":"Boolean","optional":true,"default":"true","description":"show commanding menu (HC related menus)","types":["Boolean"],"since":null,"text":"menu: Boolean - (Optional, default true) show commanding menu (HC related menus)"},{"name":"group","type":"Boolean","optional":true,"default":"true","description":"show group info bar (Squad leader info bar)","types":["Boolean"],"since":null,"text":"group: Boolean - (Optional, default true) show group info bar (Squad leader info bar)"},{"name":"cursors","type":"Boolean","optional":true,"default":"true","description":"show HUD weapon cursors (connected with scripted HUD)","types":["Boolean"],"since":null,"text":"cursors: Boolean - (Optional, default true) show HUD weapon cursors (connected with scripted HUD)"},{"name":"panels","type":"Boolean","optional":true,"default":"true","description":"show Arma 3: Custom Info","types":["Boolean"],"since":"arma3 1.70","text":"panels: Boolean - (Optional, default true) show Arma 3: Custom Info"},{"name":"kills","type":"Boolean","optional":true,"default":"true","description":"show \"x killed by y\" systemChat messages","types":["Boolean"],"since":null,"text":"kills: Boolean - (Optional, default true) show \"x killed by y\" systemChat messages"},{"name":"showIcon3D","type":"Boolean","optional":true,"default":"false","description":"show icons drawn with drawIcon3D even when the HUD is hidden","types":["Boolean"],"since":"arma3 2.04","text":"showIcon3D: Boolean - (Optional, default false) show icons drawn with drawIcon3D even when the HUD is hidden"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[scriptedHUD, info, radar, compass, direction, menu, group, cursors, panels, kills, showIcon3D]","types":["Array"]}}],"examples":[{"text":"```sqf\nshowHUD false;\n```","code":["showHUD false;"]},{"text":"Hide vehicle radar and compass:\n\n```sqf\nshowHUD [\n    true,  // scriptedHUD\n    true,  // info\n    false, // radar\n    false, // compass\n    true,  // direction\n    true,  // menu\n    true,  // group\n    true,  // cursors\n    true,  // panels\n    true,  // kills\n    true   // showIcon3D\n];\n```","code":["showHUD [\n\ttrue,  // scriptedHUD\n\ttrue,  // info\n\tfalse, // radar\n\tfalse, // compass\n\ttrue,  // direction\n\ttrue,  // menu\n\ttrue,  // group\n\ttrue,  // cursors\n\ttrue,  // panels\n\ttrue,  // kills\n\ttrue   // showIcon3D\n];"]},{"text":"Check if HUD visibility is hardcoded in mission config and showHUD command is overridden:\n\n```sqf\nprivate _disabledShowHUD = isArray (missionConfigFile >> \"showHUD\");\n```","code":["private _disabledShowHUD = isArray (missionConfigFile >> \"showHUD\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownHUD","showCinemaBorder","showSubtitles","showWatch","showRadio","showMap","showGPS","showCompass","showPad"],"notes":[{"user":"Killzone_Kid","date":"2015-08-17T19:08:00Z","text":"The \"cursors\" parameter controls visibility of the action menu as well as weapon cursors.\nHowever if 1st param \"hud\" hides and disables action menu, param \"cursors\" only hides it. So you get invisible action menu that is fully operational.\ninGameUISetEventHandler will still fire on interaction, giving the information about selected item on the action menu even if you cannot see it.\nUnfortunately it also hides icons drawn with drawIcon3D."},{"user":"POLPOX","date":"2020-03-01T14:33:00Z","text":"```sqf\nshowHUD false;\n```\n\n removes Contact's compass that is shown at the top of the screen."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"showLegend","operator":null,"title":"showLegend","type":"command","url":"https://community.bistudio.com/wiki/showLegend","revid":363238,"updated":"2024-03-26T10:51:16Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Show/hide map legend.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map showLegend bool","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"bool","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"bool: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"bool","types":["Boolean"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showMap","operator":null,"title":"showMap","type":"command","url":"https://community.bistudio.com/wiki/showMap","revid":377943,"updated":"2026-01-11T23:01:48Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable Map (default true).\n\n> [!NOTE]\n> In Arma 2 and later this command no longer works, the map now being an inventory item (\"ItemMap\" class name).\n>\n> ```sqf\n> unitName removeWeapon \"ItemMap\";\n> unitName addWeapon \"ItemMap\";\n> ```","syntaxes":[{"syntax":"showMap show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowMap false;\n```","code":["showMap false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showCompass","showGPS","showRadio","showWatch","showPad","shownMap"],"notes":[],"categories":[]},{"name":"shownAction","operator":null,"title":"shownAction","type":"command","url":"https://community.bistudio.com/wiki/shownAction","revid":378590,"updated":"2026-05-13T12:13:00Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.22"}],"since":{"game":"arma3","name":"Arma 3","version":"2.22"},"arma3_since":"2.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get the internal enum of the displayed action (or 0 if none are displayed). Action enums:\n1. GetInCommander\n1. GetInDriver\n1. GetInPilot\n1. GetInGunner\n1. GetInCargo\n1. GetInTurret\n1. Heal\n1. Repair\n1. Refuel\n1. Rearm\n1. GetOut\n1. LightOn\n1. LightOff\n1. EngineOn\n1. EngineOff\n1. SwitchWeapon\n1. HideWeapon\n1. SwitchMagazine\n1. UseWeapon\n1. LoadMagazine\n1. LoadOtherMagazine\n1. LoadEmptyMagazine\n1. TakeWeapon\n1. MountWeaponFromInv\n1. UnmountWeaponToInv\n1. MountItem\n1. UnmountItem\n1. TakeItem\n1. DropItem\n1. UnloadMagazine\n1. ChangeUniformWithBody\n1. DropItemFromBody\n1. ChangeBackpackFromBackpack\n1. TakeItemFromBody\n1. TakeBackpackFromBody\n1. UnmountUniformItem\n1. MountUniformItem\n1. UseContainerMagazine\n1. TakeDropWeapon\n1. TakeMagazine\n1. TakeDropMagazine\n1. TakeFlag\n1. ReturnFlag\n1. TurnIn\n1. TurnOut\n1. WeaponInHand\n1. WeaponOnBack\n1. SitDown\n1. Land\n1. CancelLand\n1. Eject\n1. MoveToDriver\n1. MoveToPilot\n1. MoveToGunner\n1. MoveToCommander\n1. MoveToCargo\n1. MoveToTurret\n1. HideBody\n1. TouchOff\n1. TouchOffMines\n1. StartTimer\n1. SetTimer\n1. Deactivate\n1. NVGoggles\n1. NVGogglesOff\n1. ManualFire\n1. ManualFireCancel\n1. AutoHover\n1. AutoHoverCancel\n1. VTOLVectoring\n1. VTOLVectoringCancel\n1. StrokeFist\n1. StrokeGun\n1. LadderUp\n1. LadderDown\n1. LadderOnDown\n1. LadderOnUp\n1. LadderOff\n1. FireInflame\n1. FirePutDown\n1. LandGear\n1. LandGearUp\n1. FlapsDown\n1. FlapsUp\n1. VectoringDown\n1. VectoringUp\n1. Salute\n1. ScudLaunch\n1. ScudStart\n1. ScudCancel\n1. **User** (*via* addAction)\n1. DropWeapon\n1. PutWeapon\n1. DropMagazine\n1. PutMagazine\n1. UserType\n1. HandGunOn\n1. HandGunOnStand\n1. HandGunOff\n1. HandGunOffStand\n1. TakeMine\n1. ActivateMine\n1. DeactivateMine\n1. UseMagazine\n1. IngameMenu\n1. CancelTakeFlag\n1. CancelAction\n1. MarkEntity\n1. MarkWeapon\n1. TeamSwitch\n1. Gear\n1. GearOpen\n1. HealSoldier\n1. HealSoldierAuto\n1. HealSoldierSelf\n1. PatchSoldier\n1. Surrender\n1. GetOver\n1. FirstAid\n1. OpenBag\n1. TakeBag\n1. DropBag\n1. PutBag\n1. AddBag\n1. Assemble\n1. DisAssemble\n1. IRLaserOn\n1. IRLaserOff\n1. GunLightOn\n1. GunLightOff\n1. ArtilleryComputer\n1. RepairVehicle\n1. DragSoldier\n1. CarrySoldier\n1. CarrySoldierInterrupt\n1. DragSoldierInterrupt\n1. DropCarried\n1. OpenParachute\n1. TakeVehicleControl\n1. SuspendVehicleControl\n1. LockVehicleControl\n1. UnlockVehicleControl\n1. SearchLightOn\n1. SearchLightOff\n1. CollisionLightOn\n1. CollisionLightOff\n1. PutInDriver\n1. PutInPilot\n1. PutInCargo\n1. PutInGunner\n1. PutInCommander\n1. PutInTurret\n1. UnloadFromDriver\n1. UnloadFromPilot\n1. UnloadFromCargo\n1. UnloadFromGunner\n1. UnloadFromCommander\n1. UnloadFromTurret\n1. PeriscopeDepthOn\n1. PeriscopeDepthOff\n1. UAVTerminalOpen\n1. UAVTerminalMakeConnection\n1. UAVTerminalReleaseConnection\n1. BackFromUAV\n1. SwitchToUAVDriver\n1. SwitchToUAVGunner\n1. UAVTerminalHackConnection\n1. ActiveSensorsOn\n1. ActiveSensorsOff\n1. ListLeftVehicleDisplay\n1. ListRightVehicleDisplay\n1. ListPrevLeftVehicleDisplay\n1. ListPrevRightVehicleDisplay\n1. CloseLeftVehicleDisplay\n1. CloseRightVehicleDisplay\n1. NextModeLeftVehicleDisplay\n1. NextModeRightVehicleDisplay\n1. UnloadUnconsciousUnits\n1. Talk\n1. Tell\n1. HookCargo\n1. UnhookCargo\n1. HelicopterAutoTrimOn\n1. HelicopterAutoTrimOff\n1. HelicopterTrimOn\n1. HelicopterTrimOff\n1. WheelsBrakeOn\n1. WheelsBrakeOff\n1. LoadVehicle\n1. UnloadVehicle\n1. UnloadAllVehicles\n\n> [!NOTE]\n> - **91** is the enum number for a user-added action (addAction)\n> - note the difference between `GetIn*Driver*` and `GetIn*Pilot*`.","syntaxes":[{"syntax":"shownAction","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"action enum (see description) or 0 otherwise","text":"Number - action enum (see description) or 0 otherwise"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownAction == 91) then { hint \"User added action is shown\" };\n```","code":["if (shownAction == 91) then { hint \"User added action is shown\" };"]},{"text":"```sqf\nif (shownAction == 111) then { hint \"Open inventory action is shown\" };\n```","code":["if (shownAction == 111) then { hint \"Open inventory action is shown\" };"]},{"text":"```sqf\nif (shownAction == 79) then { hint \"Drop that lighter, now\" };\n```","code":["if (shownAction == 79) then { hint \"Drop that lighter, now\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["hideActions","hiddenActions","visibleMap","shownGPS","shownWatch","shownCompass","shownUAVFeed","shownHUD","addAction","action","isActionMenuVisible"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 2.22","Scripting Commands"]},{"name":"shownArtilleryComputer","operator":null,"title":"shownArtilleryComputer","type":"command","url":"https://community.bistudio.com/wiki/shownArtilleryComputer","revid":321212,"updated":"2022-05-13T15:31:01Z","groups":["Artillery"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the player has the artillery computer currently open.","syntaxes":[{"syntax":"shownArtilleryComputer","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownArtilleryComputer) then { hint \"Artillery Computer shown on screen\"; };\n```","code":["if (shownArtilleryComputer) then { hint \"Artillery Computer shown on screen\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableEngineArtillery","getArtilleryComputerSettings","inRangeOfArtillery","commandArtilleryFire","doArtilleryFire","getArtilleryETA"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Artillery","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"shownChat","operator":null,"title":"shownChat","type":"command","url":"https://community.bistudio.com/wiki/shownChat","revid":310766,"updated":"2022-05-07T20:21:39Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.36"}],"since":{"game":"arma3","name":"Arma 3","version":"1.36"},"arma3_since":"1.36","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if chat window is enabled. Chat window can be disabled with showChat command.","syntaxes":[{"syntax":"shownChat","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_bool = shownChat;\n```","code":["_bool = shownChat;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showChat","showUAVFeed","shownMap","shownArtilleryComputer","shownCuratorCompass","slingLoadAssistantShown","ctrlShown","hcShownBar","shownGPS","shownCompass","shownPad","shownRadio","shownWatch"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 1.36","Scripting Commands"]},{"name":"shownCompass","operator":null,"title":"shownCompass","type":"command","url":"https://community.bistudio.com/wiki/shownCompass","revid":341000,"updated":"2023-05-13T22:05:59Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if client has Compass enabled in description.ext (*showCompass* param) or force enabled with showCompass command.","syntaxes":[{"syntax":"shownCompass","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownCompass) then {hint \"You have Compass enabled\"};\n```","code":["if (shownCompass) then {hint \"You have Compass enabled\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showCompass","visibleCompass","shownGPS","shownWatch","shownHUD"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownCuratorCompass","operator":null,"title":"shownCuratorCompass","type":"command","url":"https://community.bistudio.com/wiki/shownCuratorCompass","revid":310778,"updated":"2022-05-07T20:21:45Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if compass is shown.","syntaxes":[{"syntax":"shownCuratorCompass","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_isShown = shownCuratorCompass;\n```","code":["_isShown = shownCuratorCompass;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"showNewEditorObject","operator":null,"title":"showNewEditorObject","type":"command","url":"https://community.bistudio.com/wiki/showNewEditorObject","revid":363251,"updated":"2024-03-26T10:51:24Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Show the add editor object dialog,type is editor object type,class is,class definition to automatically select,side filters by a certain,side,pos is position to create the object.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map showNewEditorObject [type,class,side,position]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[type,class,side,position]","type":"Array","optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[type,class,side,position]: Array"}],"returns":{"type":"Anything","types":["Anything"],"description":null,"text":"Anything"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[type,class,side,position]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownGPS","operator":null,"title":"shownGPS","type":"command","url":"https://community.bistudio.com/wiki/shownGPS","revid":363942,"updated":"2024-04-26T21:33:55Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if client has GPS receiver enabled in description.ext (*showGPS* param) or force enabled with showGPS command.","syntaxes":[{"syntax":"shownGPS","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownGPS) then { hint \"You have the GPS receiver enabled\" };\n```","code":["if (shownGPS) then { hint \"You have the GPS receiver enabled\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showGPS","visibleGPS","openGPS","shownWatch","shownCompass","shownHUD"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownHUD","operator":null,"title":"shownHUD","type":"command","url":"https://community.bistudio.com/wiki/shownHUD","revid":378387,"updated":"2026-04-04T04:54:34Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.52"}],"since":{"game":"arma3","name":"Arma 3","version":"1.52"},"arma3_since":"1.52","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of Booleans corresponding to the visibility of various HUD elements (see extended showHUD).","syntaxes":[{"syntax":"shownHUD","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [hud, info, radar, compass, direction, menu, group, cursors, panels, kills, icon3d]","types":["Array"],"description":"hud: Boolean - show scripted HUD such as weapon crosshair, action menu and overlays created with cutRsc and titleRsc - info: Boolean - (Optional, default true) show vehicle, soldier and weapon info - radar: Boolean - (Optional, default true) show vehicle radar - compass: Boolean - (Optional, default true) show vehicle compass - direction: Boolean - (Optional, default true) show tank direction indicator. Not present in vanilla Arma 3 - menu: Boolean - (Optional, default true) show commanding menu (HC related menus) - group: Boolean - (Optional, default true) show group info bar (Squad leader info bar) - cursors: Boolean - (Optional, default true) show HUD weapon cursors (connected with scripted HUD) - panels: Boolean - (Optional, default true) show Arma 3: Custom Info - kills: Boolean - (Optional, default true) show \"x killed by y\" systemChat messages - icon3d: Boolean - (Optional, default false) show icons drawn with drawIcon3D even when the HUD is hidden","text":"Array with [hud, info, radar, compass, direction, menu, group, cursors, panels, kills, icon3d]\n- hud: Boolean - show scripted HUD such as weapon crosshair, action menu and overlays created with cutRsc and titleRsc\n- info: Boolean - (Optional, default true) show vehicle, soldier and weapon info\n- radar: Boolean - (Optional, default true) show vehicle radar\n- compass: Boolean - (Optional, default true) show vehicle compass\n- direction: Boolean - (Optional, default true) show tank direction indicator. Not present in vanilla Arma 3\n- menu: Boolean - (Optional, default true) show commanding menu (HC related menus)\n- group: Boolean - (Optional, default true) show group info bar (Squad leader info bar)\n- cursors: Boolean - (Optional, default true) show HUD weapon cursors (connected with scripted HUD)\n- panels: Boolean - (Optional, default true) show Arma 3: Custom Info\n- kills: Boolean - (Optional, default true) show \"x killed by y\" systemChat messages\n- icon3d: Boolean - (Optional, default false) show icons drawn with drawIcon3D even when the HUD is hidden"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_hudStatus = shownHUD;\n```","code":["_hudStatus = shownHUD;"]},{"text":"```sqf\nshownHUD params [\"_hud\", \"_info\", \"_radar\", \"_compass\", \"_direction\", \"_menu\", \"_group\", \"_cursors\", \"_panels\", \"_kills\", \"_icon3d\"];\n```","code":["shownHUD params [\"_hud\", \"_info\", \"_radar\", \"_compass\", \"_direction\", \"_menu\", \"_group\", \"_cursors\", \"_panels\", \"_kills\", \"_icon3d\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showHUD","shownMap","visibleMap","forceMap","shownGPS","shownWatch","shownCompass","shownUAVFeed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.52","Scripting Commands"]},{"name":"shownMap","operator":null,"title":"shownMap","type":"command","url":"https://community.bistudio.com/wiki/shownMap","revid":319962,"updated":"2022-05-13T09:25:48Z","groups":["Map"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if client has Map enabled in description.ext (*showMap* param) or force enabled with showMap command.","syntaxes":[{"syntax":"shownMap","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownMap) then {hint \"You have Map enabled\"};\n```","code":["if (shownMap) then {hint \"You have Map enabled\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showMap","visibleMap","forceMap","shownGPS","shownWatch","shownCompass","shownUAVFeed","shownHUD"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Map","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownPad","operator":null,"title":"shownPad","type":"command","url":"https://community.bistudio.com/wiki/shownPad","revid":319883,"updated":"2022-05-13T09:25:39Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if client has Notepad enabled.","syntaxes":[{"syntax":"shownPad","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownPad) then {hint \"You have Notepad enabled.\"};\n```","code":["if (shownPad) then {hint \"You have Notepad enabled.\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownMap","shownGPS","shownWatch","shownCompass","shownUAVFeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownRadio","operator":null,"title":"shownRadio","type":"command","url":"https://community.bistudio.com/wiki/shownRadio","revid":353339,"updated":"2024-03-15T17:11:51Z","groups":["Interaction","Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if player has Radio enabled.\n\n> [!NOTE]\n> This command exists in Arma 3 but doesn't do much","syntaxes":[{"syntax":"shownRadio","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownRadio) then {hint \"You have Radio enabled.\"};\n```","code":["if (shownRadio) then {hint \"You have Radio enabled.\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showRadio","shownMap","shownGPS","shownWatch","shownCompass","shownUAVFeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownScoretable","operator":null,"title":"shownScoretable","type":"command","url":"https://community.bistudio.com/wiki/shownScoretable","revid":363424,"updated":"2024-03-29T21:13:39Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the state of the score table set with showScoretable command.","syntaxes":[{"syntax":"shownScoretable","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"0: Force hidden, 1: Force shown, -1: Default","text":"Number - 0: Force hidden, 1: Force shown, -1: Default"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_state = shownScoretable;\n```","code":["_state = shownScoretable;"]}],"multiplayer":null,"problems":"> [!WARNING]\n> Since Arma 3 v1.64, the previous functionality of this command (score table visibility check) is moved to visibleScoretable command. Please update your scripts and sorry for any inconvenience.","aliases":[],"see_also":["showScoretable","visibleScoretable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"shownSubtitles","operator":null,"title":"shownSubtitles","type":"command","url":"https://community.bistudio.com/wiki/shownSubtitles","revid":349059,"updated":"2023-11-08T14:47:19Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for showSubtitles.","syntaxes":[{"syntax":"shownSubtitles","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if subtitles are set to show","text":"Boolean - returns true if subtitles are set to show"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _setToShow = shownSubtitles;\n```","code":["private _setToShow = shownSubtitles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showSubtitles"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"shownUAVFeed","operator":null,"title":"shownUAVFeed","type":"command","url":"https://community.bistudio.com/wiki/shownUAVFeed","revid":310779,"updated":"2022-05-07T20:21:45Z","groups":["Remote Control","Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if video feed transmitted from UAV is shown. A getter for showUAVFeed.","syntaxes":[{"syntax":"shownUAVFeed","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_bool = shownUAVFeed;\n```","code":["_bool = shownUAVFeed;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showUAVFeed","allUnitsUAV","getConnectedUAV","UAVControl","connectTerminalToUAV","isUAVConnected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Command Group: Remote Control","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"shownWarrant","operator":null,"title":"shownWarrant","type":"command","url":"https://community.bistudio.com/wiki/shownWarrant","revid":319867,"updated":"2022-05-13T09:25:38Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if player has ID card enabled. Obsolete command.","syntaxes":[{"syntax":"shownWarrant","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint format [\"Your ID is %1\", [\"off\", \"on\"] select shownWarrant];\n```","code":["hint format [\"Your ID is %1\", [\"off\", \"on\"] select shownWarrant];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showWarrant"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"shownWatch","operator":null,"title":"shownWatch","type":"command","url":"https://community.bistudio.com/wiki/shownWatch","revid":319901,"updated":"2022-05-13T09:25:41Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if client has Watch enabled in description.ext (*showWatch* param) or force enabled with showWatch command.","syntaxes":[{"syntax":"shownWatch","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (shownWatch) then {hint \"You have Watch enabled\"};\n```","code":["if (shownWatch) then {hint \"You have Watch enabled\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showWatch","visibleWatch","shownGPS","shownCompass","shownHUD"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showPad","operator":null,"title":"showPad","type":"command","url":"https://community.bistudio.com/wiki/showPad","revid":322923,"updated":"2022-06-28T21:42:28Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides the notebook on the map screen, if enabled for the mission. (default true). It is no longer relevant to Arma 2.","syntaxes":[{"syntax":"showPad show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowPad false;\n```","code":["showPad false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownPad","showCompass","showGPS","showRadio","showWatch"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showRadio","operator":null,"title":"showRadio","type":"command","url":"https://community.bistudio.com/wiki/showRadio","revid":370852,"updated":"2025-02-18T00:23:17Z","groups":["Interaction","Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides the radio on the map screen, if enabled for the mission and you possess the item. (default true).\n\n> [!NOTE]\n> This command does nothing in Arma 3.","syntaxes":[{"syntax":"showRadio show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowRadio false;\n```","code":["showRadio false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownRadio","showCompass","showGPS","showWatch","showPad"],"notes":[{"user":"GeneralCarver","date":"2009-08-16T21:02:00Z","text":"The radio is now an item in Arma 2.\nClass path is `\"CfgWeapons\" >> \"ItemRadio\"`.\nUse the addWeapon and removeWeapon commands to add/remove it from a unit's inventory. e.g:\n\n```sqf\nplayer removeWeapon \"ItemRadio\";\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showScoretable","operator":null,"title":"showScoretable","type":"command","url":"https://community.bistudio.com/wiki/showScoretable","revid":309918,"updated":"2022-05-05T12:16:57Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Forces the score table to be shown, hidden or reset to default functionality. Forcing score table will make it show even in SP. When score table is forced opened it cannot be  closed manually, when it is force closed, it cannot be opened manually.","syntaxes":[{"syntax":"showScoretable force","since":null,"effect":null,"exec":null,"params":[{"name":"force","type":"Number","optional":false,"default":null,"description":"1 to force visible, 0 to force invisible, -1 default","types":["Number"],"since":null,"text":"force: Number - 1 to force visible, 0 to force invisible, -1 default"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"force","types":["Number"]}}],"examples":[{"text":"```sqf\nshowScoretable 1;\n```","code":["showScoretable 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownScoretable","visibleScoretable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"showSubtitles","operator":null,"title":"showSubtitles","type":"command","url":"https://community.bistudio.com/wiki/showSubtitles","revid":363292,"updated":"2024-03-26T10:51:59Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Enables / disables showing of subtitles in a chat. Only scripted/engine chatter is affected, player manual chat is unaffected. Returns the previous state.","syntaxes":[{"syntax":"showSubtitles enable","since":null,"effect":null,"exec":null,"params":[{"name":"enable","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enable: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"enable","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowSubtitles false;\n```","code":["showSubtitles false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownSubtitles","setSpeaker","disableConversation","enableRadio","enableSentences"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"showUAVFeed","operator":null,"title":"showUAVFeed","type":"command","url":"https://community.bistudio.com/wiki/showUAVFeed","revid":364255,"updated":"2024-05-06T09:38:21Z","groups":["Remote Control","Custom Panels"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows/hides video feed transmitted from UAV in its custom info panel.","syntaxes":[{"syntax":"showUAVFeed show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"always true unless error","text":"Boolean - always true unless error"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowUAVFeed true;\n```","code":["showUAVFeed true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownUAVFeed","allUnitsUAV","getConnectedUAV","UAVControl","connectTerminalToUAV","isUAVConnected","BIS_fnc_liveFeed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Custom Panels","Command Group: Remote Control","Introduced with Arma 3 version 1.16","Scripting Commands"]},{"name":"showWarrant","operator":null,"title":"showWarrant","type":"command","url":"https://community.bistudio.com/wiki/showWarrant","revid":352093,"updated":"2024-02-01T23:24:49Z","groups":["Interaction","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Enable ID card. \n\n> [!WARNING]\n> Obsolete command.","syntaxes":[{"syntax":"showWarrant show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":"(default false)","types":["Boolean"],"since":null,"text":"show: Boolean - (default false)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowWarrant true;\n```","code":["showWarrant true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showCompass","showGPS","showMap","showWatch"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showWatch","operator":null,"title":"showWatch","type":"command","url":"https://community.bistudio.com/wiki/showWatch","revid":310211,"updated":"2022-05-05T13:10:43Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows or hides the watch on the map screen, if enabled for the mission and you possess the item. (default true)","syntaxes":[{"syntax":"showWatch show","since":null,"effect":null,"exec":null,"params":[{"name":"show","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"show: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"show","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowWatch false;\n```","code":["showWatch false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["shownWatch","visibleWatch","showCompass","showGPS","showRadio","showPad"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showWaypoint","operator":null,"title":"showWaypoint","type":"command","url":"https://community.bistudio.com/wiki/showWaypoint","revid":348989,"updated":"2023-11-08T14:45:47Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines how waypoints are shown to the player in map view. For 3D HUD visibility see setWaypointVisible.","syntaxes":[{"syntax":"waypoint showWaypoint show","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"show","type":"String","optional":false,"default":null,"description":"possible values are:\n- \"NEVER\" - Never show\n- \"EASY\" - Show only if `showCadetWP` is enabled in global difficulty.\n- \"ALWAYS\" - Always show","types":["String"],"since":null,"text":"show: String - possible values are:\n- \"NEVER\" - Never show\n- \"EASY\" - Show only if `showCadetWP` is enabled in global difficulty.\n- \"ALWAYS\" - Always show"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"show","types":["String"]}}],"examples":[{"text":"```sqf\n[_grp, 2] showWaypoint \"ALWAYS\";\n```","code":["[_grp, 2] showWaypoint \"ALWAYS\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointShow"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"showWaypoints","operator":null,"title":"showWaypoints","type":"command","url":"https://community.bistudio.com/wiki/showWaypoints","revid":329411,"updated":"2022-07-27T15:11:51Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows/Hides task HUD markers and waypoints that will fade out in time. Dependable on difficulty settings.","syntaxes":[{"syntax":"showWaypoints enabled","since":null,"effect":null,"exec":null,"params":[{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enabled","types":["Boolean"]}}],"examples":[{"text":"```sqf\nshowWaypoints true;\n```","code":["showWaypoints true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showWaypoint","waypointShow"],"notes":[{"user":"PierreMGI","date":"2020-05-27T07:20:00Z","text":"Even if you set your difficulty with \"waypoints: hide\", if you are using addWaypoint command for player, you will see your waypoints displayed on map, with the track to follow.\nSome other cases using addWaypoint will allow this unexpected behaviour on map and the code `showWaypoints false;` will not change anything for map.\n\nYou need to use showWaypoint command instead, on each added waypoints:\n\n```sqf\n_wp = group player addWaypoint [getMarkerPos \"aMarker\", 0];\n_wp showWaypoint \"NEVER\";\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"side","operator":null,"title":"side","type":"command","url":"https://community.bistudio.com/wiki/side","revid":341641,"updated":"2023-06-12T19:02:58Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the side of a unit, vehicle, object or location.\n- side of a renegade soldier is sideEnemy\n- side of an empty vehicle is civilian\n- side of a crewed vehicle is, if present, commander's > gunner's > driver's or > cargo's side, in this order\n- side of a captive or dead unit is civilian. Use `side group _unit` to get the underlying side (see #Example 2)\n- you can use playerSide to know the real player's side\n\n> [!NOTE]\n> Converting a side to string will **not** always return the side command text: e.g `str resistance; // returns \"GUER\"`.\n>\n> See Side page to see the return value of all side commands.","syntaxes":[{"syntax":"side target","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object, Group or Location","optional":false,"default":null,"description":null,"types":["Object","Group","Location"],"since":null,"text":"target: Object, Group or Location"}],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object","Group","Location"]}}],"examples":[{"text":"```sqf\nif (side player == west) then { hint \"Player is on the West side\" };\n```","code":["if (side player == west) then { hint \"Player is on the West side\" };"]},{"text":"```sqf\n_sideAlsoWorkingForDead = side group _deadUnit;\n```","code":["_sideAlsoWorkingForDead = side group _deadUnit;"]},{"text":"```sqf\n_sideLocation = side myLocation;\n```","code":["_sideLocation = side myLocation;"]},{"text":"```sqf\nif (side player != playerSide) then { hint \"player is renegade or dead\"; };\n```","code":["if (side player != playerSide) then { hint \"player is renegade or dead\"; };"]},{"text":"Check the side of the vehicle:\n\n```sqf\n_vehicleSide = side group _vehicle; // sideUnknown (CIV for Arma 3) if empty or dead crew, otherwise the appropriate side\n```","code":["_vehicleSide = side group _vehicle; // sideUnknown (CIV for Arma 3) if empty or dead crew, otherwise the appropriate side"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["CfgVehicles Config Reference","Side","playerSide","west","east","resistance","civilian","sideLogic","sideFriendly","sideEnemy","sideUnknown","sideEmpty","sideAmbientLife","Side Relations","BIS_fnc_sideID","BIS_fnc_objectSide"],"notes":[{"user":"Ceeeb","date":"2007-03-23T04:51:00Z","text":"In **Arma**, the following objects are on side civilian: dead bodies and vehicles, empty vehicles, all mission editor placed objects (that do not have an inherit side), all objects with interactive components such as ladders and doors, man made structures such as buildings (including classless wrp placed objects), docks, high tension powerlines, see-saws, large rubbish bins, fountains. Basically if an object uses a non-simple damage or physics simulation it is likely to be on the civilian side.\n\n**NOTE:** If you need to know the side of a dead body, you can use faction command as a workaround -- Killzone_Kid"},{"user":"Ceeeb","date":"2007-02-12T06:28:00Z","text":"In **Operation Flashpoint v1.96**, the side return value for a vehicle is based on the side of its commander, then gunner, then driver, then cargo. It will retain its side value until it is either empty, or a unit of another side takes over in a equal or higher role, irrespective of the side of other units still on board. This can be used to simulate friendly fire, as a vehicle can be made to appear to be an enemy even though all units on board are actually friendly."},{"user":"Tankbuster","date":"2010-03-19T16:48:00Z","text":"As Ceeeb says above, in **Arma 2**, side for a vehicle often depends on who the command or driver is, for example, A KA52, piloted by a USMC guy will have side WEST. For an accurate result of what 'where the vehicle was made', use faction. This ignores the pilot/commander, so in my example here, this KA52 will always return faction \"RU\". Note that faction returns different values to side though."},{"user":"RKurtzDmitriyev","date":"2011-02-04T18:11:00Z","text":"Side values for ambient life (animals) are bizarre. `side _unit` returns \"CIV\", but playerSide returns \"AMBIENT LIFE\" when the player is an animal. In that case, `playerSide == side player;` returns false!\n\nFortunately, you can easily check if a unit is an animal with `_unit isKindOf \"ANIMAL\";`"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sideAmbientLife","operator":null,"title":"sideAmbientLife","type":"command","url":"https://community.bistudio.com/wiki/sideAmbientLife","revid":342224,"updated":"2023-07-09T12:27:27Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns side of ambient life, for example ambient life placed in Eden Editor.","syntaxes":[{"syntax":"sideAmbientLife","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_sideAmbientLife = sideAmbientLife;\n```","code":["_sideAmbientLife = sideAmbientLife;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["side","west","blufor","east","opfor","resistance","independent","civilian","sideLogic","sideFriendly","sideEnemy","sideUnknown","playerSide","sideEmpty"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"sideChat","operator":null,"title":"sideChat","type":"command","url":"https://community.bistudio.com/wiki/sideChat","revid":376777,"updated":"2025-11-17T00:06:09Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Types text to the side radio channel by the specified unit. Use clearRadio to clear chat history\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property \n>\n> ```cpp\n> simulation = \"ItemRadio\";\n> ```\n>\n>  in its CfgWeapons config.","syntaxes":[{"syntax":"unit sideChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit transmitting message","types":["Object"],"since":null,"text":"unit: Object - unit transmitting message"},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"chatText","types":["String"]}},{"syntax":"[side, identity] sideChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"side to which the message will be seen","types":["Side"],"since":null,"text":"side: Side - side to which the message will be seen"},{"name":"identity","type":"String","optional":false,"default":null,"description":"class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\"","types":["String"],"since":null,"text":"identity: String - class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\""},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[side, identity]","types":["Array"]},"right":{"text":"chatText","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne sideChat \"Show this text\";\n```","code":["_soldierOne sideChat \"Show this text\";"]},{"text":"```sqf\n[west, \"HQ\"] sideChat \"Hi there\";\n```","code":["[west, \"HQ\"] sideChat \"Hi there\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]},{"text":"```sqf\n[[blufor, \"BLU\"], \"message\"] remoteExec [\"sideChat\"]; // shows the message to all players\n```","code":["[[blufor, \"BLU\"], \"message\"] remoteExec [\"sideChat\"]; // shows the message to all players"]},{"text":"```sqf\nunit setGroupId [\"Cpt. Miller\"]; // changes the group's callsign\nunit sideChat \"Hello ladies!\";\n```","code":["unit setGroupId [\"Cpt. Miller\"]; // changes the group's callsign\nunit sideChat \"Hello ladies!\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","groupChat","vehicleChat","commandChat","customChat","systemChat","sideRadio"],"notes":[{"user":"Ceeeb","date":"2007-02-12T04:31:00Z","text":"In **Operation Flashpoint v1.96**, sideChat messages can be sent from two abstract sources: \"Papa_Bear\" and \"Base FireFly\".\n\nUse sideChat on an array in the form [SIDE, \"base\"], [SIDE, \"HQ\"], [SIDE, \"Papa_bear\"] or [SIDE, \"airbase\"], where SIDE is the side broadcasting. \"HQ\", \"base\" and \"Papa_bear\" seem to be the same object. The callsign strings can be re-defined using a stringTable.csv file, using `STR_CFG_PAPABEAR` and `STR_CFG_FIREFLYBASE`.\n\nExample :\n\n```sqf\n[east, \"base\"] sideChat \"Return to base!\"\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"sideEmpty","operator":null,"title":"sideEmpty","type":"command","url":"https://community.bistudio.com/wiki/sideEmpty","revid":342117,"updated":"2023-07-09T12:26:40Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns empty side, for example static buildings in Eden Editor.","syntaxes":[{"syntax":"sideEmpty","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_sideEmpty = sideEmpty;\n```","code":["_sideEmpty = sideEmpty;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["side","west","blufor","east","opfor","resistance","independent","civilian","sideLogic","sideFriendly","sideEnemy","sideUnknown","playerSide","sideAmbientLife"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"sideEnemy","operator":null,"title":"sideEnemy","type":"command","url":"https://community.bistudio.com/wiki/sideEnemy","revid":369191,"updated":"2024-09-03T10:34:47Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The enemy side which is used for renegades. Units of this side are hostile to everyone.\n- To join sideEnemy, you can attack members of your own side or use addRating.\n- When below a rating of -2000 units switch automatically to this side.","syntaxes":[{"syntax":"sideEnemy","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side player == sideEnemy) then\n{\n    hint \"We've got a renegade!\";\n};\n```","code":["if (side player == sideEnemy) then\n{\n\thint \"We've got a renegade!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addRating","rating","Side","side","west","east","resistance","civilian","sideLogic","sideFriendly","sideUnknown","playerSide","sideEmpty","sideAmbientLife","Side Relations"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.78","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sideFriendly","operator":null,"title":"sideFriendly","type":"command","url":"https://community.bistudio.com/wiki/sideFriendly","revid":341634,"updated":"2023-06-12T19:02:54Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.78"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The Friendly side - friendly to all, see Side Relations.","syntaxes":[{"syntax":"sideFriendly","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side player == sideFriendly) then { hint \"I feel friendly today!\"; };\n```","code":["if (side player == sideFriendly) then { hint \"I feel friendly today!\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side","side","west","east","resistance","civilian","sideLogic","sideUnknown","sideEnemy","playerSide","sideEmpty","sideAmbientLife","Side Relations"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.78","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sideLogic","operator":null,"title":"sideLogic","type":"command","url":"https://community.bistudio.com/wiki/sideLogic","revid":341626,"updated":"2023-06-12T19:02:53Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The Logic side. Side of Game Logics and Modules.","syntaxes":[{"syntax":"sideLogic","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (side _obj == sideLogic) then\n{\n    hint \"It is a logic!\";\n};\n```","code":["if (side _obj == sideLogic) then\n{\n\thint \"It is a logic!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Side","side","west","east","resistance","civilian","sideUnknown","sideFriendly","sideEnemy","playerSide","Side Relations"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands"]},{"name":"sideRadio","operator":null,"title":"sideRadio","type":"command","url":"https://community.bistudio.com/wiki/sideRadio","revid":364536,"updated":"2024-05-16T20:46:45Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the audio message to the side radio channel. The message is defined in CfgRadio in the description.ext file or config radio protocol. The transmission will play only on the PC where command was executed. If you need the transmission to play on all computers, you have to execute it globally (see remoteExec).\n\n> [!IMPORTANT]\n> The unit must have an assigned radio item (such as ***\"ItemRadio\"***) to see or transmit the messages. A radio item must have the property `simulation = \"ItemRadio\";` in its CfgWeapons config.\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit sideRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from `CfgRadio`","types":["String"],"since":null,"text":"radioName: String - class name from `CfgRadio`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}},{"syntax":"[side, identity] sideRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"side","type":"Side","optional":false,"default":null,"description":"side to which the transmission will be played","types":["Side"],"since":null,"text":"side: Side - side to which the transmission will be played"},{"name":"identity","type":"String","optional":false,"default":null,"description":"class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\"","types":["String"],"since":null,"text":"identity: String - class name of one of the identities in CfgHQIdentities. Possible identities in Arma 3 are:\n- \"Base\"\n- \"HQ\"\n- \"PAPA_BEAR\"\n- \"AirBase\"\n- \"BLU\"\n- \"OPF\"\n- \"IND\"\n- \"IND_G\""},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from `CfgRadio`","types":["String"],"since":null,"text":"radioName: String - class name from `CfgRadio`"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"[side, identity]","types":["Array"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne sideRadio \"messageOne\";\n```","code":["_soldierOne sideRadio \"messageOne\";"]},{"text":"```sqf\nplayer sideRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["player sideRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]},{"text":"```sqf\n[west, \"Base\"] sideRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["[west, \"Base\"] sideRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideChat","groupRadio","customRadio","vehicleRadio","globalRadio","directSay","commandRadio"],"notes":[{"user":"Ceeeb","date":"2007-02-12T03:47:00Z","text":"In **OFP v1.96**, sideRadio messages can be sent from 2 abstract sources: \"Papa_Bear\" and \"Base FireFly\". Use sideRadio on an array in the form [SIDE,\"base\"],[SIDE,\"HQ\"],[SIDE,\"Papa_bear\"] or [SIDE,\"airbase\"], where SIDE is the side broadcasting. \"HQ\", \"base\" and \"Papa_bear\" seem to be the same object. The callsign strings can be re-defined using a stringTable.csv file, using STR_CFG_PAPABEAR and STR_CFG_FIREFLYBASE.  *Example : [EAST,\"base\"] sideRadio \"returnToBase\"*."},{"user":"Killzone_Kid","date":"2016-12-03T21:32:00Z","text":"To transmit user custom sounds (see Multiplayer_Custom_Sounds_Tutorial), prefix the full filename including file extension with #. For example if there is a custom user sound file called `MySound.ogg`, to play it on the radio use:\n\n```sqf\nplayer sideRadio \"#MySound.ogg\";\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"sideUnknown","operator":null,"title":"sideUnknown","type":"command","url":"https://community.bistudio.com/wiki/sideUnknown","revid":369295,"updated":"2024-09-03T18:42:51Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"The unknown side.\n\nUsed when the side of a unit is unknown, e.g. for spotted targets with insufficient information.","syntaxes":[{"syntax":"sideUnknown","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n//soldier1 and soldier2 of different sides and out of sight\nsoldier1 reveal soldier2;\nhint str (soldier1 nearTargets 1000);\n//returns: [[[1557.96,5047.4,1.32402],\"SoldierWB\",UNKNOWN,0.0155183,soldier2,5]]\nsoldier1 reveal [soldier2,1.5];\n//returns: [[[1556.52,5050.08,1.32402],\"SoldierWB\",WEST,0.0211193,soldier2,5]]\n```","code":["//soldier1 and soldier2 of different sides and out of sight\nsoldier1 reveal soldier2;\nhint str (soldier1 nearTargets 1000);\n//returns: [[[1557.96,5047.4,1.32402],\"SoldierWB\",UNKNOWN,0.0155183,soldier2,5]]\nsoldier1 reveal [soldier2,1.5];\n//returns: [[[1556.52,5050.08,1.32402],\"SoldierWB\",WEST,0.0211193,soldier2,5]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["nearTargets","reveal","Side","side","west","east","resistance","civilian","sideLogic","sideFriendly","sideEnemy","playerSide","sideEmpty","sideAmbientLife","Side Relations"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"simpleTasks","operator":null,"title":"simpleTasks","type":"command","url":"https://community.bistudio.com/wiki/simpleTasks","revid":378353,"updated":"2026-04-02T16:35:09Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return all simple tasks assigned to given unit.","syntaxes":[{"syntax":"simpleTasks unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Tasks","types":["Array","Task"],"description":null,"text":"Array of Tasks"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_tasks = simpleTasks player;\n```","code":["_tasks = simpleTasks player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createSimpleTask","currentTask"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"simulationEnabled","operator":null,"title":"simulationEnabled","type":"command","url":"https://community.bistudio.com/wiki/simulationEnabled","revid":310189,"updated":"2022-05-05T13:10:32Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Check if the entity has enabled simulation.\n\n> [!IMPORTANT]\n> The entity could be local or remote but the result returned by this command will be for the entity simulation set up locally on the client that executed the command.\n> See enableSimulation for more info.","syntaxes":[{"syntax":"simulationEnabled entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"entity: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\nsimulationEnabled player;\n```","code":["simulationEnabled player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableSimulation","enableSimulationGlobal","enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","triggerDynamicSimulation","canTriggerDynamicSimulation"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"simulCloudDensity","operator":null,"title":"simulCloudDensity","type":"command","url":"https://community.bistudio.com/wiki/simulCloudDensity","revid":365017,"updated":"2024-07-10T18:22:01Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns density of clouds at given position.","syntaxes":[{"syntax":"simulCloudDensity pos","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"}],"returns":{"type":"- Number","types":["Number"],"description":"density (0-1) - Nothing - If arguments are incorrect - Boolean - Returns false if simulWeather is disabled","text":"- Number - density (0-1)\n- Nothing - If arguments are incorrect\n- Boolean - Returns false if simulWeather is disabled"},"form":"unary","operator":null,"left":null,"right":{"text":"pos","types":["Position"]}}],"examples":[{"text":"```sqf\nsimulCloudDensity getPos player;\n```","code":["simulCloudDensity getPos player;"]}],"multiplayer":null,"problems":"> [!NOTE]\n> **Eden Editor:** SimulWeather seems to be disabled in Eden Editor and scenario preview.","aliases":[],"see_also":["setSimulWeatherLayers","simulCloudOcclusion","simulInClouds"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"simulCloudOcclusion","operator":null,"title":"simulCloudOcclusion","type":"command","url":"https://community.bistudio.com/wiki/simulCloudOcclusion","revid":369177,"updated":"2024-09-03T10:34:44Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns clouds occlusion between two given points.","syntaxes":[{"syntax":"simulCloudOcclusion [pos1, pos2]","since":null,"effect":null,"exec":null,"params":[{"name":"pos1","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos1: Position"},{"name":"pos2","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos2: Position"}],"returns":{"type":"- Number","types":["Number"],"description":"(0 - no clouds, 1 - full clouds) - Nothing - If arguments are incorrect - Boolean - Returns false if simulWeather is disabled","text":"- Number - (0 - no clouds, 1 - full clouds)\n- Nothing - If arguments are incorrect\n- Boolean - Returns false if simulWeather is disabled"},"form":"unary","operator":null,"left":null,"right":{"text":"[pos1, pos2]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _posPlayer = getPos player;\nprivate _posAbovePlayer = +_posPlayer; _posAbovePlayer set [2,200];\nsimulCloudOcclusion [_posPlayer, _posAbovePlayer];\n```","code":["private _posPlayer = getPos player;\nprivate _posAbovePlayer = +_posPlayer; _posAbovePlayer set [2,200];\nsimulCloudOcclusion [_posPlayer, _posAbovePlayer];"]}],"multiplayer":null,"problems":"> [!NOTE]\n> **Eden Editor:** SimulWeather seems to be disabled in Eden Editor and scenario preview.","aliases":[],"see_also":["setSimulWeatherLayers","simulCloudDensity","simulInClouds"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"simulInClouds","operator":null,"title":"simulInClouds","type":"command","url":"https://community.bistudio.com/wiki/simulInClouds","revid":378513,"updated":"2026-05-03T17:21:12Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns if given position is in clouds.","syntaxes":[{"syntax":"simulInClouds pos","since":null,"effect":null,"exec":null,"params":[{"name":"pos","type":"Position","optional":false,"default":null,"description":null,"types":["Position"],"since":null,"text":"pos: Position"}],"returns":{"type":"Boolean, Nothing","types":["Boolean","Nothing"],"description":"true if given position is in clouds. Nothing if given arguments are incorrect","text":"Boolean, Nothing - true if given position is in clouds. Nothing if given arguments are incorrect"},"form":"unary","operator":null,"left":null,"right":{"text":"pos","types":["Position"]}}],"examples":[{"text":"```sqf\nsimulInClouds getPos player;\n```","code":["simulInClouds getPos player;"]}],"multiplayer":null,"problems":"> [!NOTE]\n> **Eden Editor:** SimulWeather seems to be disabled in Eden Editor and scenario preview.","aliases":[],"see_also":["setSimulWeatherLayers","simulCloudDensity","simulCloudOcclusion"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"simulSetHumidity","operator":null,"title":"simulSetHumidity","type":"command","url":"https://community.bistudio.com/wiki/simulSetHumidity","revid":373025,"updated":"2025-03-18T15:57:35Z","groups":["Environment","Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets simul cloud cover. This command does not affect overcast value.\n\nThis command was not implemented up until Arma 3 v2.18","syntaxes":[{"syntax":"simulSetHumidity humidity","since":null,"effect":null,"exec":null,"params":[{"name":"humidity","type":"Number","optional":false,"default":null,"description":"0 (min): clear sky, 1 (max): heavy cloud cover","types":["Number"],"since":null,"text":"humidity: Number - 0 (min): clear sky, 1 (max): heavy cloud cover"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"humidity","types":["Number"]}}],"examples":[{"text":"```sqf\nsimulSetHumidity 1;\n```","code":["simulSetHumidity 1;"]},{"text":"When combined with setOvercast 1 this command will also start random strength rain.\n\n```sqf\nskipTime -24;\n86400 setOvercast 1;\nskipTime 24;\nsimulSetHumidity 1;\n```\n\nCreates rainy looking weather, followed by thunder in about 10 seconds and rain in about 20.","code":["skipTime -24;\n86400 setOvercast 1;\nskipTime 24;\nsimulSetHumidity 1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["overcast","setOvercast"],"notes":[{"user":"Dedmen","date":"2025-03-18T15:57:35Z","text":"setOvercast 1 and simulSetHumidity 0, can cause thunderstorm with lightning on a clear sky.\n\nYou can also setOvercast 0 to have a cloudless sky, but use SetHumidity to bring the clouds back"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"simulWeatherSync","operator":null,"title":"simulWeatherSync","type":"command","url":"https://community.bistudio.com/wiki/simulWeatherSync","revid":363572,"updated":"2024-04-07T08:45:59Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Synchronizes Simul Weather with Arma weather, generates all keyframes.","syntaxes":[{"syntax":"simulWeatherSync","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nsimulWeatherSync;\n```","code":["simulWeatherSync;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceWeatherChange"],"notes":[{"user":"AgentRev","date":"2016-05-04T22:24:00Z","text":"The behavior of this command is similar to forceWeatherChange, however it leaves current weather transitions intact.\nIts main purpose would be to refresh the cloud cover to properly reflect current overcast, as they can sometime get out of sync, especially when using setTimeMultiplier and setAccTime."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"sin","operator":null,"title":"sin","type":"command","url":"https://community.bistudio.com/wiki/sin","revid":349344,"updated":"2023-11-08T14:53:30Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sine of x.","syntaxes":[{"syntax":"sin x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"value in degree","types":["Number"],"since":null,"text":"x: Number - value in degree"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_sine = sin 30; // result is 0.5\n```","code":["_sine = sin 30; // result is 0.5"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cos","tan"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"size","operator":null,"title":"size","type":"command","url":"https://community.bistudio.com/wiki/size","revid":378398,"updated":"2026-04-04T08:01:25Z","groups":["Locations"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a location's size.","syntaxes":[{"syntax":"size location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"Array with [x,y]","types":["Array"],"description":"x: Number - horizontal distance in meters - y: Number - vertical distance in meters","text":"Array with [x,y]\n- x: Number - horizontal distance in meters\n- y: Number - vertical distance in meters"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_locSize = size myLocation;\n```","code":["_locSize = size myLocation;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSize"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sizeOf","operator":null,"title":"sizeOf","type":"command","url":"https://community.bistudio.com/wiki/sizeOf","revid":349136,"updated":"2023-11-08T14:49:45Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the diameter of bounding sphere of the object of given classname in meters. If you need to estimate the size of the object more precisely, use boundingBox or boundingBoxReal.\n\n> [!IMPORTANT]\n> At least one object of the given classname has to be present in the current mission otherwise zero will be returned.","syntaxes":[{"syntax":"sizeOf classname","since":null,"effect":null,"exec":null,"params":[{"name":"classname","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"classname: String"}],"returns":{"type":"Number","types":["Number"],"description":"size returned is usually bigger than the biggest size of the object along any of the axes. For example if object is 10 x 4 x 5 the sizeOf value returned expected to be around 10.","text":"Number - size returned is usually bigger than the biggest size of the object along any of the axes. For example if object is 10 x 4 x 5 the sizeOf value returned expected to be around 10."},"form":"unary","operator":null,"left":null,"right":{"text":"classname","types":["String"]}}],"examples":[{"text":"```sqf\n_dimension = sizeOf \"M1Abrams\"; // Returns 10.7833\n```","code":["_dimension = sizeOf \"M1Abrams\"; // Returns 10.7833"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["boundingBox","boundingBoxReal","boundingCenter"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"skill","operator":null,"title":"skill","type":"command","url":"https://community.bistudio.com/wiki/skill","revid":364271,"updated":"2024-05-06T09:38:30Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current skill of a unit, in range between 0 to 1, 1 being the highest level of skill.\n\n> [!NOTE]\n> - Skill of AI units set via the slider in unit placement screen varies from 0.2 to 1.0.\n> - If the **superAI** difficulty settings is enabled, all units have skill of 1.0 regardless of the skill slider.","syntaxes":[{"syntax":"skill unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"unit skill skillName","since":"arma1 1.00","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skillName","type":"String","optional":false,"default":null,"description":"possible values are:\n- \"aimingAccuracy\"\n- \"aimingShake\"\n- \"aimingSpeed\"\n- \"endurance\"\n- \"spotDistance\"\n- \"spotTime\"\n- \"courage\"\n- \"reloadSpeed\"\n- \"commanding\"\n- \"general\"","types":["String"],"since":null,"text":"skillName: String - possible values are:\n- \"aimingAccuracy\"\n- \"aimingShake\"\n- \"aimingSpeed\"\n- \"endurance\"\n- \"spotDistance\"\n- \"spotTime\"\n- \"courage\"\n- \"reloadSpeed\"\n- \"commanding\"\n- \"general\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"skillName","types":["String"]}}],"examples":[{"text":"```sqf\n_skill = skill unit1;\n```","code":["_skill = skill unit1;"]},{"text":"```sqf\n_myCourage = player skill \"courage\";\n```","code":["_myCourage = player skill \"courage\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["skillFinal","setSkill","setUnitAbility","Arma 3: AI Skill","Combat Modes"],"notes":[],"categories":["AI","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"skillFinal","operator":null,"title":"skillFinal","type":"command","url":"https://community.bistudio.com/wiki/skillFinal","revid":378482,"updated":"2026-04-24T12:46:59Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns final, recalculated sub skill value of given unit. (with regard to AI Level coefficient (Difficulty settings)).","syntaxes":[{"syntax":"unit skillFinal skillName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"skillName","type":"String","optional":false,"default":null,"description":"see sub-skill. Possible values are:\n- \"aimingAccuracy\"\n- \"aimingShake\"\n- \"aimingSpeed\"\n- \"endurance\" - Has no effect in Arma 3\n- \"spotDistance\"\n- \"spotTime\"\n- \"courage\"\n- \"reloadSpeed\"\n- \"commanding\"\n- \"general\"","types":["String"],"since":null,"text":"skillName: String - see sub-skill. Possible values are:\n- \"aimingAccuracy\"\n- \"aimingShake\"\n- \"aimingSpeed\"\n- \"endurance\" - Has no effect in Arma 3\n- \"spotDistance\"\n- \"spotTime\"\n- \"courage\"\n- \"reloadSpeed\"\n- \"commanding\"\n- \"general\""}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"skillName","types":["String"]}}],"examples":[{"text":"```sqf\n_unitTrueCourage = unit1 skillFinal \"courage\";\n```","code":["_unitTrueCourage = unit1 skillFinal \"courage\";"]}],"multiplayer":"Since Arma 3 v1.40 the command works in multiplayer.","problems":null,"aliases":[],"see_also":["skill","setSkill","setUnitAbility","CfgAISkill","Combat Modes"],"notes":[],"categories":["AI","Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"skipTime","operator":null,"title":"skipTime","type":"command","url":"https://community.bistudio.com/wiki/skipTime","revid":369075,"updated":"2024-09-02T20:25:00Z","groups":["Time","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Jumps the specified number of hours forward or backward.\nThe time of day and tides are adjusted, but no changes are made to any units. If present, the lower level of clouds instantly jump to the position they would be in if time had passed normally.","syntaxes":[{"syntax":"skipTime duration","since":null,"effect":null,"exec":null,"params":[{"name":"duration","type":"Number","optional":false,"default":null,"description":"hours to skip. A positive value will create a forward time jump, a negative value will jump backwards.","types":["Number"],"since":null,"text":"duration: Number - hours to skip. A positive value will create a forward time jump, a negative value will jump backwards."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"duration","types":["Number"]}}],"examples":[{"text":"```sqf\nskipTime 5;\n```","code":["skipTime 5;"]},{"text":"```sqf\nskipTime (5/60); // be sure to use parentheses, otherwise here (skipTime 5)/60 will happen\n```","code":["skipTime (5/60); // be sure to use parentheses, otherwise here (skipTime 5)/60 will happen"]},{"text":"```sqf\nwhile {true} do \n{\n    skipTime 0.00333;\n    sleep 0.1; // smooth time transition\n};\n```","code":["while {true} do \n{\n\tskipTime 0.00333;\n\tsleep 0.1; // smooth time transition\n};"]},{"text":"```sqf\nskipTime ((_timeToSkipTo - dayTime + 24) % 24); // skip forward to a specific time, irrespective of the current mission time\n```","code":["skipTime ((_timeToSkipTo - dayTime + 24) % 24); // skip forward to a specific time, irrespective of the current mission time"]}],"multiplayer":"In Arma 3 (around v1.14) skipTime executed on the server will get synced in 5 seconds or so with all the clients. It will also be JIP compatible. skipTime executed on a client will change time on client for about 5 seconds after which it will sync back to server time.\n\nFor other games' behaviour, see Multiplayer Scripting#Join In Progress.\n\n> [!IMPORTANT]\n> Since Arma 3 v2.10 skipTime is limited to max +/- 1000 hours per skip for game stability. The command is intended for short time jumps. For large intervals, use setDate.","problems":null,"aliases":[],"see_also":["setDate","accTime","setTimeMultiplier","timeMultiplier","BIS_fnc_setDate"],"notes":[{"user":"Ceeeb","date":"2007-04-17T04:01:00Z","text":"In ArmA & OFP, skipTime does not actually estimate weather changes beyond moving the clouds across the sky.\nWeather counters continue as if no time has passed.\nThe setDate command can be used instead of skiptime to change the time *without* the visual give-away of the lower clouds jumping."},{"user":".kju","date":"2011-11-02T22:06:00Z","text":"I cannot confirm this for OA 1.60 beta (85889):\nMP: Even though the immediate effect of skipTime is only local,\nthe new time will propagate through the network after 30 seconds or so.\nInstead the date, which includes time, is synced automatically for new JIP clients - NOT for present instances.\nSo one has to apply skipTime on all instances in MP (server + all present clients)."},{"user":"Killzone_Kid","date":"2013-08-25T02:45:00Z","text":"This command is blocking and in some cases it may take up to 1.5 seconds (probably depends on CPU) for it to calculate the changes to the environment, during which the game will microfreeze. It largely depends on weather changes, which are quite random. However one thing remains consistent, skipTime 24 hours is always almost instant. This is quite helpful when used in conjunction with commands such as setOvercast for instant and seamless effect. To try it yourself use this script:\n\n```sqf\n0 spawn {\n    for \"_i\" from 1 to 24 do {\n        _time = diag_tickTime;\n        skipTime _i;\n        diag_log  [_i, diag_tickTime - _time];\n        sleep 3;\n    };\n};\n```\n\nOne of the results (results will vary depending on weather conditions):\n\n```\n[1,1.44507]\n[2,1.46118]\n[3,1.33105]\n[4,1.396]\n[5,0.0310059]\n[6,1.37891]\n[7,1.4502]\n[8,1.37817]\n[9,1.37695]\n[10,1.37012]\n[11,1.448]\n[12,1.32593]\n[13,1.45508]\n[14,1.448]\n[15,0.0349121]\n[16,0.0368652]\n[17,1.25903]\n[18,1.38599]\n[19,1.4519]\n[20,0.052002]\n[21,0.0400391]\n[22,0.0490723]\n[23,1.35205]\n[24,0.0151367] // this is always the lowest\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Time","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Server Execution","Take On Helicopters: Scripting Commands"]},{"name":"sleep","operator":null,"title":"sleep","type":"command","url":"https://community.bistudio.com/wiki/sleep","revid":370495,"updated":"2024-12-26T17:40:41Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Suspends code execution for given time in seconds. The sleep precision is given by a framerate, the delay given is the minimal delay expected. Must be called inside of a context which is interruptible, i.e. a script executed by execVM or spawn.\n\n> [!NOTE]\n> - this command will suspend the code for ***at least*** the given amount of time, and can be way more if the script scheduler is busy.\n> - this command will suspend the script as the game gets paused in single player (and will resume with it). To avoid this, use uiSleep.","syntaxes":[{"syntax":"sleep delay","since":null,"effect":null,"exec":null,"params":[{"name":"delay","type":"Number","optional":false,"default":null,"description":"in seconds. Negative values will not be considered.","types":["Number"],"since":null,"text":"delay: Number - in seconds. Negative values will not be considered."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"delay","types":["Number"]}}],"examples":[{"text":"```sqf\n0 spawn {\n    sleep 5;\n    hint \"after (at least) 5 seconds...\";\n};\n```","code":["0 spawn {\n\tsleep 5;\n\thint \"after (at least) 5 seconds...\";\n};"]},{"text":"```sqf\nsleep 5 + random 10;    // incorrect - will only sleep for 5 seconds, as it will be interpreted as (sleep 5) (+(random 10))\nsleep (5 + random 10);    // correct\n```","code":["sleep 5 + random 10;\t// incorrect - will only sleep for 5 seconds, as it will be interpreted as (sleep 5) (+(random 10))\nsleep (5 + random 10);\t// correct"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["time","uiSleep","waitUntil","canSuspend","execVM","spawn","sleep vs uiSleep","Control Structures"],"notes":[{"user":"CrashDome","date":"2006-12-20T20:53:00Z","text":"Sleep suspends both SQF functions and SQF scripts. In functions, the calling script is still in suspension due to waiting for a return from the call command. The game engine will continue, however. See Function for more detail."},{"user":"Kronzky","date":"2007-02-12T20:16:00Z","text":"Sleep durations between .0005 and .02 will cause the same delay (roughly .02 seconds).\n\nDelays of .0005 and less have **no** effect (i.e, the sleep call will return immediately)."},{"user":"Sbsmac","date":"2007-02-13T22:32:00Z","text":"The comment above is a little misleading. The game engine appears to work by processing frames and then checking to see whether scripts are available to execute.\nSleep causes the script/function to be suspended until at least the specified time has elapsed.\nTo wait for the next frame, or give other scripts a chance to run, use Sleep 0.001."},{"user":"Inkompetent","date":"2007-06-16T00:13:00Z","text":"For scripts called by the Init Event Handler the first sleep command will suspend the script at the briefing screen at the start of a mission. The script will continue after the briefing screen, when actually \"in game\"."}],"categories":[]},{"name":"sliderPosition","operator":null,"title":"sliderPosition","type":"command","url":"https://community.bistudio.com/wiki/sliderPosition","revid":310899,"updated":"2022-05-07T20:31:43Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current thumb position of CT_SLIDER or CT_XSLIDER with given idc of topmost user dialog.","syntaxes":[{"syntax":"sliderPosition idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"sliderPosition control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\n_slidepos1 = sliderPosition 105;\n```","code":["_slidepos1 = sliderPosition 105;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderSetPosition"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sliderRange","operator":null,"title":"sliderRange","type":"command","url":"https://community.bistudio.com/wiki/sliderRange","revid":379084,"updated":"2026-09-27T08:27:05Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns limits of CT_SLIDER or CT_XSLIDER.","syntaxes":[{"syntax":"sliderRange idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of the control","types":["Number"],"since":null,"text":"idc: Number - idc of the control"}],"returns":{"type":"Array with [minValue, maxValue]","types":["Array"],"description":"minValue: Number - maxValue: Number","text":"Array with [minValue, maxValue]\n- minValue: Number\n- maxValue: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"sliderRange control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array with [minValue, maxValue]","types":["Array"],"description":"minValue: Number - maxValue: Number","text":"Array with [minValue, maxValue]\n- minValue: Number\n- maxValue: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nsliderRange _ctrlSlider params [\"_minValue\", \"_maxValue\"];\n```","code":["sliderRange _ctrlSlider params [\"_minValue\", \"_maxValue\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderPosition","sliderSetPosition","sliderSetRange","sliderSetSpeed","sliderSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sliderSetPosition","operator":null,"title":"sliderSetPosition","type":"command","url":"https://community.bistudio.com/wiki/sliderSetPosition","revid":348781,"updated":"2023-11-08T14:33:16Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets current thumb position of CT_SLIDER or CT_XSLIDER.","syntaxes":[{"syntax":"sliderSetPosition [idc, pos]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of the control","types":["Number"],"since":null,"text":"idc: Number - idc of the control"},{"name":"pos","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"pos: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, pos]","types":["Array"]}},{"syntax":"control sliderSetPosition pos","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"pos","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"pos: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"pos","types":["Number"]}}],"examples":[{"text":"```sqf\n_ctrlSlider sliderSetPosition 50;\n```","code":["_ctrlSlider sliderSetPosition 50;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderPosition","sliderRange","sliderSetRange","sliderSetSpeed","sliderSpeed","ctrlSetScrollValues","progressSetPosition"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sliderSetRange","operator":null,"title":"sliderSetRange","type":"command","url":"https://community.bistudio.com/wiki/sliderSetRange","revid":348823,"updated":"2023-11-08T14:39:08Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets limits of CT_SLIDER or CT_XSLIDER.","syntaxes":[{"syntax":"sliderSetRange [idc, min, max]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"idc of the control","types":["Number"],"since":null,"text":"idc: Number - idc of the control"},{"name":"min","type":"Number","optional":false,"default":null,"description":"minimal value","types":["Number"],"since":null,"text":"min: Number - minimal value"},{"name":"max","type":"Number","optional":false,"default":null,"description":"maximum value","types":["Number"],"since":null,"text":"max: Number - maximum value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, min, max]","types":["Array"]}},{"syntax":"control sliderSetRange [min, max]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"min","type":"Number","optional":false,"default":null,"description":"minimal value","types":["Number"],"since":null,"text":"min: Number - minimal value"},{"name":"max","type":"Number","optional":false,"default":null,"description":"maximum value","types":["Number"],"since":null,"text":"max: Number - maximum value"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[min, max]","types":["Array"]}}],"examples":[{"text":"```sqf\nsliderSetRange [101, 0, 100];\n```","code":["sliderSetRange [101, 0, 100];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderPosition","sliderRange","sliderSetPosition","sliderSetSpeed","sliderSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sliderSetSpeed","operator":null,"title":"sliderSetSpeed","type":"command","url":"https://community.bistudio.com/wiki/sliderSetSpeed","revid":376729,"updated":"2025-11-15T04:49:49Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets slider line step and page step delta amount as well as optional step amount of CT_SLIDER or CT_XSLIDER with given idc of topmost user dialog.\n- Click to arrow - move by line\n- Click to scale outside thumb - move by page.\n\n> [!NOTE]\n> CT_XSLIDER does not use the *page* parameter, it acts as scrollbar when clicked on the bar. It also can only be horizontal.","syntaxes":[{"syntax":"sliderSetSpeed [idc, line, page, step]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control's idc","types":["Number"],"since":null,"text":"idc: Number - control's idc"},{"name":"line","type":"Number","optional":false,"default":null,"description":"value delta to move the slider when clicking on the outer arrows","types":["Number"],"since":null,"text":"line: Number - value delta to move the slider when clicking on the outer arrows"},{"name":"page","type":"Number","optional":false,"default":null,"description":"value delta to move the slider when clicking inside the slider bar","types":["Number"],"since":null,"text":"page: Number - value delta to move the slider when clicking inside the slider bar"},{"name":"step","type":"Number","optional":true,"default":"0","description":"slider step","types":["Number"],"since":null,"text":"step: Number - (Optional, default 0) slider step"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, line, page, step]","types":["Array"]}},{"syntax":"control sliderSetSpeed [line, page, step]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"line","type":"Number","optional":false,"default":null,"description":"value delta to move the slider when clicking on the outer arrows","types":["Number"],"since":null,"text":"line: Number - value delta to move the slider when clicking on the outer arrows"},{"name":"page","type":"Number","optional":false,"default":null,"description":"value delta to move the slider when clicking inside the slider bar","types":["Number"],"since":null,"text":"page: Number - value delta to move the slider when clicking inside the slider bar"},{"name":"step","type":"Number","optional":true,"default":"0","description":"slider step","types":["Number"],"since":null,"text":"step: Number - (Optional, default 0) slider step"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[line, page, step]","types":["Array"]}}],"examples":[{"text":"```sqf\nsliderSetSpeed [101, 0.5, 2];\n```","code":["sliderSetSpeed [101, 0.5, 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sliderSpeed","operator":null,"title":"sliderSpeed","type":"command","url":"https://community.bistudio.com/wiki/sliderSpeed","revid":378110,"updated":"2026-02-16T11:24:51Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns slider step value for line and page movement of CT_SLIDER or CT_XSLIDER.","syntaxes":[{"syntax":"sliderSpeed idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number: idc of the control","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number: idc of the control"}],"returns":{"type":"Array format [minSpeed, maxSpeed, Arma 3 v2.08 step]","types":["Array"],"description":null,"text":"Array format [minSpeed, maxSpeed, Arma 3 v2.08 step]"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"sliderSpeed control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Array format [minSpeed, maxSpeed, Arma 3 v2.08 step]","types":["Array"],"description":null,"text":"Array format [minSpeed, maxSpeed, Arma 3 v2.08 step]"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nsliderSpeed _ctrlSlider params [\"_min\", \"_max\", \"_step\"];\n```","code":["sliderSpeed _ctrlSlider params [\"_min\", \"_max\", \"_step\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sliderPosition","sliderRange","sliderSetPosition","sliderSetRange","sliderSetSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"slingLoadAssistantShown","operator":null,"title":"slingLoadAssistantShown","type":"command","url":"https://community.bistudio.com/wiki/slingLoadAssistantShown","revid":369265,"updated":"2024-09-03T18:42:42Z","groups":["Ropes and Sling Loading"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if Sling Load Assistant is open.","syntaxes":[{"syntax":"slingLoadAssistantShown","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if sling load assistant is shown, false otherwise","text":"Boolean - true if sling load assistant is shown, false otherwise"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nwaitUntil { slingLoadAssistantShown };\nhint \"You lack rudimentary motor skills and basic eye-hand coordination.\"; // scold user for unethical practices\n```","code":["waitUntil { slingLoadAssistantShown };\nhint \"You lack rudimentary motor skills and basic eye-hand coordination.\"; // scold user for unethical practices"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ropes","canSlingLoad","enableRopeAttach","getSlingLoad","ropeAttachedObjects","ropeAttachTo","ropeDestroy","ropeLength","ropeUnwound","ropeAttachedTo","ropeCreate","ropeDetach","ropeAttachEnabled","ropeCut","ropeEndPosition","ropeUnwind"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Ropes and Sling Loading","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"soldierMagazines","operator":null,"title":"soldierMagazines","type":"command","url":"https://community.bistudio.com/wiki/soldierMagazines","revid":369271,"updated":"2024-09-03T18:42:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all magazines of the given unit.","syntaxes":[{"syntax":"soldierMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of String","types":["Array","String"],"description":null,"text":"Array of String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nsoldierMagazines player;\n// returns:\n[\n    \"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:1/0](5x)\",\n    \"9mm 16Rnd Mag(16/16)[id/cr:7/0](2x)\",\n    \"RGO Frag Grenade(1/1)[id/cr:10/0](2x)\",\n    \"Smoke Grenade (White)(1/1)[id/cr:12/0](1x)\",\n    \"Smoke Grenade (Green)(1/1)[id/cr:13/0](1x)\",\n    \"Chemlight (Green)(1/1)[id/cr:14/0](2x)\",\n    \"Titan AT Missile(1/1)[id/cr:16/0](2x)\"\n]\n```","code":["soldierMagazines player;\n// returns:\n[\n\t\"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:1/0](5x)\",\n\t\"9mm 16Rnd Mag(16/16)[id/cr:7/0](2x)\",\n\t\"RGO Frag Grenade(1/1)[id/cr:10/0](2x)\",\n\t\"Smoke Grenade (White)(1/1)[id/cr:12/0](1x)\",\n\t\"Smoke Grenade (Green)(1/1)[id/cr:13/0](1x)\",\n\t\"Chemlight (Green)(1/1)[id/cr:14/0](2x)\",\n\t\"Titan AT Missile(1/1)[id/cr:16/0](2x)\"\n]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformMagazines","vestMagazines","backpackMagazines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"someAmmo","operator":null,"title":"someAmmo","type":"command","url":"https://community.bistudio.com/wiki/someAmmo","revid":338255,"updated":"2023-02-24T18:01:51Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if unit has some ammo.","syntaxes":[{"syntax":"someAmmo unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqs\n? not (someAmmo _loon1) : hint \"Loon1 is out of ammo!\"\n```","code":["? not (someAmmo _loon1) : hint \"Loon1 is out of ammo!\""]},{"text":"```sqf\nif (not someAmmo _loon1) then { hint \"Loon1 is out of ammo!\" };\n```","code":["if (not someAmmo _loon1) then { hint \"Loon1 is out of ammo!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ammo","magazines"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sort","operator":null,"title":"sort","type":"command","url":"https://community.bistudio.com/wiki/sort","revid":377104,"updated":"2026-01-01T10:00:38Z","groups":["Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.44"}],"since":{"game":"arma3","name":"Arma 3","version":"1.44"},"arma3_since":"1.44","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attempts to sort given array either in ascending (true) or descending (false) order. \n\n> [!IMPORTANT]\n> This will **modify** the original array!","syntaxes":[{"syntax":"array sort order","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Anything","optional":false,"default":null,"description":"array to be sorted, can also be a nested array.\n\nAll array elements should be one of the following types:\n- String - Array of strings `[\"a\",\"b\",\"c\"...]`\n- Number - Array of numbers `[1,2,3...]`\n- Array - Array of subarrays `[[\"a\",1,2],[\"b\",3,4],[\"c\",5,6]...]`. Subarrays should be of the same structure. Subarray elements other than String or Number will be ignored during sorting.\nMixed arrays `[\"a\",1,[true], ...]` are not supported and results are undefined.","types":["Array","Anything"],"since":null,"text":"array: Array of Anything - array to be sorted, can also be a nested array.\n\nAll array elements should be one of the following types:\n- String - Array of strings `[\"a\",\"b\",\"c\"...]`\n- Number - Array of numbers `[1,2,3...]`\n- Array - Array of subarrays `[[\"a\",1,2],[\"b\",3,4],[\"c\",5,6]...]`. Subarrays should be of the same structure. Subarray elements other than String or Number will be ignored during sorting.\nMixed arrays `[\"a\",1,[true], ...]` are not supported and results are undefined."},{"name":"order","type":"Boolean","optional":false,"default":null,"description":"sorting order.\n- true: ascending\n- false: descending","types":["Boolean"],"since":null,"text":"order: Boolean - sorting order.\n- true: ascending\n- false: descending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"array","types":["Array","Anything"]},"right":{"text":"order","types":["Boolean"]}}],"examples":[{"text":"```sqf\n_arr = [5.21725,1.30859,4,5.03028,1];\n_arr sort true;\nhint str _arr; //[1,1.30859,4,5.03028,5.21725]\n```","code":["_arr = [5.21725,1.30859,4,5.03028,1];\n_arr sort true;\nhint str _arr; //[1,1.30859,4,5.03028,5.21725]"]},{"text":"```sqf\n_dev = [\"ja\",\"pa\",\"pa\",\"tram\",\"tara\"];\n_dev sort false;\nhint str _dev; //[\"tram\",\"tara\",\"pa\",\"pa\",\"ja\"]\n```","code":["_dev = [\"ja\",\"pa\",\"pa\",\"tram\",\"tara\"];\n_dev sort false;\nhint str _dev; //[\"tram\",\"tara\",\"pa\",\"pa\",\"ja\"]"]},{"text":"```sqf\n#define ASC true\n#define DESC false\n_scores = [[123,\"bob\",15],[123,\"bill\",20],[200,\"dave\",21],[200,\"steve\",11]];\n_scores sort DESC;\nhint str _scores; //[[200,\"steve\",11],[200,\"dave\",21],[123,\"bob\",15],[123,\"bill\",20]]\n```","code":["#define ASC true\n#define DESC false\n_scores = [[123,\"bob\",15],[123,\"bill\",20],[200,\"dave\",21],[200,\"steve\",11]];\n_scores sort DESC;\nhint str _scores; //[[200,\"steve\",11],[200,\"dave\",21],[123,\"bob\",15],[123,\"bill\",20]]"]},{"text":"Sort buildings by distance and return position of the most distant building:\n\n```sqf\n_buildings = player nearObjects [\"Land_Cargo_Patrol_V1_F\", 500];\n_buildings = _buildings apply { [_x distance player, _x] };\n_buildings sort false;\nhint format [\n    \"Most distant building is at %1, distance %2 m\", \n    getPos (_buildings select 0 select 1),\n    round (_buildings select 0 select 0)\n];\n```","code":["_buildings = player nearObjects [\"Land_Cargo_Patrol_V1_F\", 500];\n_buildings = _buildings apply { [_x distance player, _x] };\n_buildings sort false;\nhint format [\n\t\"Most distant building is at %1, distance %2 m\", \n\tgetPos (_buildings select 0 select 1),\n\tround (_buildings select 0 select 0)\n];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","BIS_fnc_sortAlphabetically","BIS_fnc_sortBy","BIS_fnc_sortNum"],"notes":[{"user":"Killzone_Kid","date":"2015-04-16T18:14:00Z","text":"The algorithm for sorting subarrays: compare 1st element, if equal compare 2nd, if equal compare 3rd...etc."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Introduced with Arma 3 version 1.44","Scripting Commands"]},{"name":"soundParams","operator":null,"title":"soundParams","type":"command","url":"https://community.bistudio.com/wiki/soundParams","revid":379075,"updated":"2026-09-26T11:21:04Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns various params for the given sound. The sound has to be playing otherwise command returns empty array []. In case of say3D, the sound is put in the queue so unless the sound is started instantly with 'playMode' 1 or 2, it will also return [].","syntaxes":[{"syntax":"soundParams id or sound","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"Number","optional":false,"default":null,"description":"id returned by playSoundUI and playSound3D commands, -1 to return all currently playing ids","types":["Number"],"since":null,"text":"id: Number - id returned by playSoundUI and playSound3D commands, -1 to return all currently playing ids"},{"name":"sound","type":"Object or NetObject","optional":false,"default":null,"description":"sound returned by say3D command or the unit, in which case current say3D unit's sound params are returned","types":["Object","NetObject"],"since":"arma3 2.24","text":"sound: Object or NetObject - sound returned by say3D command or the unit, in which case current say3D unit's sound params are returned"}],"returns":{"type":"- id != -1 : Array with [path, curPos, length, time, volume, source]","types":["Array"],"description":"path: String - the path to the played sound file - curPos: Number - current play position in 0...1 range - length: Number - total sound duration in seconds - time: Number - time passed since the start of playback - volume: Number - playback volume - Arma 3 v2.22 loop: Boolean - true if the sound is looping - Arma 3 v2.24 source: Object - Source object to which say3D sound is attached or objNull - Arma 3 v2.22 id == -1: Array with [sid1, sid2, sid3..., sidn], where sid is sound id returned by playSoundUI and playSound3D but not say3D","text":"- *id* != -1 : Array with [path, curPos, length, time, volume, source]\n  - path: String - the path to the played sound file\n  - curPos: Number - current play position in 0...1 range\n  - length: Number - total sound duration in seconds\n  - time: Number - time passed since the start of playback\n  - volume: Number - playback volume\n  - Arma 3 v2.22 loop: Boolean - true if the sound is looping\n  - Arma 3 v2.24 source: Object - Source object to which say3D sound is attached or objNull\n- Arma 3 v2.22 *id* == -1: Array with [sid1, sid2, sid3..., sidn], where sid is sound id returned by playSoundUI and playSound3D but not say3D"},"form":"unary","operator":null,"left":null,"right":{"text":"id or sound","types":[]}}],"examples":[{"text":"```sqf\nprivate _params = soundParams 10;\n```","code":["private _params = soundParams 10;"]},{"text":"Wait for sound to end:\n\n```sqf\nprivate _sound = playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player];\nwaitUntil { soundParams _sound isEqualTo [] };\n```","code":["private _sound = playSound3D [\"A3\\Sounds_F\\sfx\\blip1.wss\", player];\nwaitUntil { soundParams _sound isEqualTo [] };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playSoundUI","playSound3D","stopSound"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.12","Scripting Commands"]},{"name":"soundVolume","operator":null,"title":"soundVolume","type":"command","url":"https://community.bistudio.com/wiki/soundVolume","revid":376984,"updated":"2026-01-01T06:23:46Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current sound volume (set by fadeSound).","syntaxes":[{"syntax":"soundVolume","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..1","types":["Number"],"description":null,"text":"Number in range 0..1"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str soundVolume;\n```","code":["hint str soundVolume;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeSound","musicVolume","radioVolume","speechVolume","environmentVolume","getAudioOptionVolumes"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"spawn","operator":null,"title":"spawn","type":"command","url":"https://community.bistudio.com/wiki/spawn","revid":373975,"updated":"2025-07-10T15:33:35Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds given set of compiled instructions to the scheduler.\nExactly when the code will be executed is unknown, it depends on how busy is the engine and how filled up is the scheduler.\nTherefore spawn does not wait for the supplied code to finish, instead, spawn returns a Script handle to the scheduler task.\nscriptDone command can be used to check the code completion. Additional arguments are passed to the code in local variable _this.\nSince Arma 3 v1.56 the script handle also exists inside the code in `_thisScript` variable.\nTo see what spawned scripts are currently in the scheduler, use diag_activeSQFScripts command.\n\n> [!WARNING]\n> When multiple Code is spawned in an order, there is no guarantee that the spawned Code will execute in the same order (see #Example 2). If the order is important, use BIS_fnc_spawnOrdered.","syntaxes":[{"syntax":"arguments spawn code","since":null,"effect":null,"exec":null,"params":[{"name":"arguments","type":"Anything","optional":false,"default":null,"description":"arguments passed to the script, which later available in `_this` variable inside the script.","types":["Anything"],"since":null,"text":"arguments: Anything - arguments passed to the script, which later available in `_this` variable inside the script."},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Script Handle","types":["Script Handle"],"description":"can be used to determine (via scriptDone (also via isNull in Arma 3)) when the spawned script has finished. In Arma 3, the handle is also available inside the spawned script in `_thisScript` variable","text":"Script Handle - can be used to determine (via scriptDone (also via isNull in Arma 3)) when the spawned script has finished. In Arma 3, the handle is also available inside the spawned script in `_thisScript` variable"},"form":"binary","operator":null,"left":{"text":"arguments","types":["Anything"]},"right":{"text":"code","types":["Code"]}},{"syntax":"spawn code","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Script Handle","types":["Script Handle"],"description":null,"text":"Script Handle"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}},{"syntax":"spawn name","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"The name of a \"Empty Handle\". Behaves like scriptName inside a function.","types":["String"],"since":null,"text":"name: String - The name of a \"Empty Handle\". Behaves like scriptName inside a function."}],"returns":{"type":"Script Handle","types":["Script Handle"],"description":"A \"Empty Handle\" to be used as a Promise","text":"Script Handle - A \"Empty Handle\" to be used as a Promise"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_handle = 0 spawn { player globalChat \"Hello world!\" };\n```","code":["_handle = 0 spawn { player globalChat \"Hello world!\" };"]},{"text":"There is no guarantee that spawned scripts will be executed in the same order they spawned:\n\n```sqf\nfor \"_i\" from 0 to 100 do\n{\n    _i spawn\n    {\n        diag_log _this;\n    };\n}; // Result: 51,1,2...49,50,0,52,53...100\n```","code":["for \"_i\" from 0 to 100 do\n{\n\t_i spawn\n\t{\n\t\tdiag_log _this;\n\t};\n}; // Result: 51,1,2...49,50,0,52,53...100"]},{"text":"Local variables declared in the main scope are not available in the spawned code. You have to pass them as parameters:\n\n```sqf\nprivate _localVariable = 1234;\n[_localVariable] spawn \n{\n    systemChat format [\"_localVariable does not exist: %1\", isNil \"_localVariable\"]; // _localVariable does not exist: true\n    params [\"_localVariable\"];\n    systemChat format [\"_localVariable is now: %1\", _localVariable]; // _localVariable is now: 1234\n};\n```","code":["private _localVariable = 1234;\n[_localVariable] spawn \n{\n\tsystemChat format [\"_localVariable does not exist: %1\", isNil \"_localVariable\"]; // _localVariable does not exist: true\n\tparams [\"_localVariable\"];\n\tsystemChat format [\"_localVariable is now: %1\", _localVariable]; // _localVariable is now: 1234\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["call","execVM","execFSM","exec","compile","preprocessFileLineNumbers","preprocessFile","terminate","scriptDone","remoteExec","sleep","uiSleep","canSuspend"],"notes":[{"user":"Kronzky","date":"2009-03-06T00:20:00Z","text":"spawn cannot call other local functions on the same scope as itself.\n\nIt can, however, call other global functions:\n\n```sqf\n_addOne = { TST = TST + 1 };\nTST_addOne = { TST = TST + 1 };\n\n_add = {\n    TST = TST+1;\n    player sideChat format [\"added: %1\",TST];\n    call _addOne;\n    player sideChat format [\"called local: %1\",TST];\n    call TST_addOne;\n    player sideChat format [\"called global: %1\",TST];\n};\nTST = 0;\ncall _add;\n0 spawn _add;\n```\n\nThe call of _addOne from the spawned function does not do anything."},{"user":"DreadedEntity","date":"2014-10-21T23:33:00Z","text":"Arma 3 v0.50 spawn requires a script handle when used in the 2D-Editor.\n\nArma 3 v2.04 In Eden Editor this is no longer necessary.\n\nIn scripts and in the debug console, it is not required, but very useful for keeping track of running scripts. Having a script handle also makes it easy to terminate scripts at any time.\n\nSince spawn creates a new scheduled environment, having an excess of open threads can make the scheduler queue extremely long, significantly increasing the execution time of each thread. (it takes an extremely large amount of threads, though)"},{"user":"Nelis75733126","date":"2015-08-25T13:39:00Z","text":"If you have a local (private) function that you want to access from within code created with `spawn`, you can pass that private function to the code of `spawn`, like so:\n\n```sqf\n_someFunction = {};\n[ _someFunction ] spawn { call( _this select 0 ) };\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"speaker","operator":null,"title":"speaker","type":"command","url":"https://community.bistudio.com/wiki/speaker","revid":319837,"updated":"2022-05-13T09:25:34Z","groups":["Unit Identity","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.02"}],"since":{"game":"arma3","name":"Arma 3","version":"1.02"},"arma3_since":"1.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the speaker class name of a unit.","syntaxes":[{"syntax":"speaker unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nspeaker player; // Can return \"male09eng\"\n```","code":["speaker player; // Can return \"male09eng\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSpeaker"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Command Group: Unit Identity","Introduced with Arma 3 version 1.02","Scripting Commands"]},{"name":"speechVolume","operator":null,"title":"speechVolume","type":"command","url":"https://community.bistudio.com/wiki/speechVolume","revid":376983,"updated":"2026-01-01T06:23:31Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current speech volume (set by fadeSpeech)","syntaxes":[{"syntax":"speechVolume","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number in range 0..2","types":["Number"],"description":null,"text":"Number in range 0..2"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint str speechVolume;\n```","code":["hint str speechVolume;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fadeSpeech","musicVolume","soundVolume","radioVolume","environmentVolume","getAudioOptionVolumes"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"speed","operator":null,"title":"speed","type":"command","url":"https://community.bistudio.com/wiki/speed","revid":376345,"updated":"2025-10-07T16:59:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Object speed (in km/h). Returns relative speed of given object along Y axis. An equivalent to: `3.6 * (velocityModelSpace _obj select 1)`","syntaxes":[{"syntax":"speed object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nif (speed _truck1 >= 100) then { hint \"You're going too fast!\" };\n```","code":["if (speed _truck1 >= 100) then { hint \"You're going too fast!\" };"]},{"text":"```sqf\nif ((speed objectParent player) < 0) then { hint \"You're going reverse!\" };\n```","code":["if ((speed objectParent player) < 0) then { hint \"You're going reverse!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["velocity","setVelocity","velocityModelSpace","setVelocityModelSpace","setVelocityTransformation","limitSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"speedMode","operator":null,"title":"speedMode","type":"command","url":"https://community.bistudio.com/wiki/speedMode","revid":336416,"updated":"2023-01-02T16:21:28Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns speed mode of the group, which can be any of the following:\n- **\"LIMITED\"**\n- **\"NORMAL\"**\n- **\"FULL\"**","syntaxes":[{"syntax":"speedMode groupName","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Object or Group","optional":false,"default":null,"description":null,"types":["Object","Group"],"since":null,"text":"groupName: Object or Group"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"groupName","types":["Object","Group"]}}],"examples":[{"text":"```sqf\n_speed = speedMode group player;\n```","code":["_speed = speedMode group player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSpeedMode","getSpeed","forceSpeed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"splitString","operator":null,"title":"splitString","type":"command","url":"https://community.bistudio.com/wiki/splitString","revid":377128,"updated":"2026-01-01T10:23:07Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Splits the provided **ANSI** string into an array of tokens according to given delimiters.\n\n> [!NOTE]\n> For Unicode support, see forceUnicode.","syntaxes":[{"syntax":"str splitString delimiters","since":null,"effect":null,"exec":null,"params":[{"name":"str","type":"String","optional":false,"default":null,"description":"the string to split","types":["String"],"since":null,"text":"str: String - the string to split"},{"name":"delimiters","type":"String","optional":false,"default":null,"description":"one or more characters, each used as a separate delimiter; if empty, *str* is split by each character","types":["String"],"since":null,"text":"delimiters: String - one or more characters, each used as a separate delimiter; if empty, *str* is split by each character"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"binary","operator":null,"left":{"text":"str","types":["String"]},"right":{"text":"delimiters","types":["String"]}}],"examples":[{"text":"```sqf\n_str = \"- This, is a sample string.\" splitString \"-,. \"; // [\"This\",\"is\",\"a\",\"sample\",\"string\"]\n_str joinString \"#\"; // \"This#is#a#sample#string\"\n```","code":["_str = \"- This, is a sample string.\" splitString \"-,. \"; // [\"This\",\"is\",\"a\",\"sample\",\"string\"]\n_str joinString \"#\"; // \"This#is#a#sample#string\""]},{"text":"```sqf\n\"\\A3\\ui_f\\data\\map\\vehicleicons\\iconLogic_ca.paa\" splitString \"\\.\"; // [\"A3\",\"ui_f\",\"data\",\"map\",\"vehicleicons\",\"iconLogic_ca\",\"paa\"]\n```","code":["\"\\A3\\ui_f\\data\\map\\vehicleicons\\iconLogic_ca.paa\" splitString \"\\.\"; // [\"A3\",\"ui_f\",\"data\",\"map\",\"vehicleicons\",\"iconLogic_ca\",\"paa\"]"]},{"text":"```sqf\n\"1:2:3\" splitString \":\"; // [\"1\",\"2\",\"3\"]\n```","code":["\"1:2:3\" splitString \":\"; // [\"1\",\"2\",\"3\"]"]},{"text":"```sqf\n\"Japa is the best!\" splitString \"\" joinString \" \"; // \"J a p a   i s   t h e   b e s t !\"\n```","code":["\"Japa is the best!\" splitString \"\" joinString \" \"; // \"J a p a   i s   t h e   b e s t !\""]},{"text":"```sqf\n_cmd = currentMagazineDetail player; // \"9mm 16Rnd Mag(13/16)[id/cr:10000011/0]\"\n_cmd splitString \"([ ]/:)\"; // [\"9mm\",\"16Rnd\",\"Mag\",\"13\",\"16\",\"id\",\"cr\",\"10000011\",\"0\"]\n```","code":["_cmd = currentMagazineDetail player; // \"9mm 16Rnd Mag(13/16)[id/cr:10000011/0]\"\n_cmd splitString \"([ ]/:)\"; // [\"9mm\",\"16Rnd\",\"Mag\",\"13\",\"16\",\"id\",\"cr\",\"10000011\",\"0\"]"]},{"text":"Remove all \\r\\n from file:\n\n```sqf\nloadFile \"somefile.txt\" splitString toString [13,10] joinString \" \";\n```","code":["loadFile \"somefile.txt\" splitString toString [13,10] joinString \" \";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["joinString","set","resize","reverse","select","in","find","toArray","forEach","count","deleteAt","deleteRange","append","sort","param","params","arrayIntersect","toString","endl","forceUnicode"],"notes":[{"user":"BaerMitUmlaut","date":"2016-05-17T14:18:00Z","text":"This command is unreliable/broken when it comes to some non-ASCII characters (as of Arma 3 v1.58):\n\n```sqf\n\"Mörser\" splitString \"\" // -> [\"M\",\" \",\" \",\"r\",\"s\",\"e\",\"r\"]\n\"Mörser\" splitString \"ö\" // -> [\"M\",\"rser\"]\n\"Mörser\" splitString \"ä\" // -> [\"M\",\" rser\"]\n```"},{"user":"Killzone_Kid","date":"2016-10-17T14:03:00Z","text":"This commands works only with ASCII chars, any chars with codes > 127, also used in different languages, will be converted to [\" \", \" \"]. Use toArray to preserve special characters:\n\n```sqf\n_spaced = toArray \"Mörser\" apply {toString [_x]} joinString \" \"; // M ö r s e r\n```"},{"user":"R3vo","date":"2019-07-19T11:17:00Z","text":"When working with string which contain linebreaks...\n\n```sqf\n\"stringWith\" + endl + \"Linebreak\" splitString \",; \";\n/*\nresult is [\"someStringWith\nLinebreak\"]\n*/\n```\n\n...one can remove those by adding endl as delimiter\n\n```sqf\n\"stringWith\" + endl + \"Linebreak\" splitString \",; \" + endl; // result is [\"someStringWith\",\"Linebreak\"]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"sqrt","operator":null,"title":"sqrt","type":"command","url":"https://community.bistudio.com/wiki/sqrt","revid":369402,"updated":"2024-09-03T18:43:22Z","groups":["Math"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns square root of x.","syntaxes":[{"syntax":"sqrt x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\nprivate _squareRoot = sqrt 9;  // returns 3\n```","code":["private _squareRoot = sqrt 9;  // returns 3"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands","a %5E b"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"squadParams","operator":null,"title":"squadParams","type":"command","url":"https://community.bistudio.com/wiki/squadParams","revid":377683,"updated":"2026-01-02T09:02:50Z","groups":["Object Manipulation","System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.18"}],"since":{"game":"arma3","name":"Arma 3","version":"1.18"},"arma3_since":"1.18","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns data about squad of given unit loaded from squad.xml as well as the unit itself.\n\n> [!NOTE]\n> This command returns an empty array in single player.","syntaxes":[{"syntax":"squadParams unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [squadInfo, memberInfo, squadId, a3unitsId]","types":["Array"],"description":"squadInfo: Array with [nick, name, email, web, picture, title] - nick: String - squad nickname - name: String - squad full name - email: String - squad contact email - web: String - squad website URL - picture: String - squad picture URL - title: String - squad title - memberInfo: Array with [uid, name, fullname, email, icq, remark] - uid: String - member unique ID - name: String - member name - fullname: String - member full name - email: String - member email - icq: String - member ICQ number - remark: String - member remark - Arma 3 v2.06 squadId: String - unique squad ID - Arma 3 v2.06 a3unitsId: String - unique Arma 3 Units ID","text":"Array with [squadInfo, memberInfo, squadId, a3unitsId]\n- squadInfo: Array with [nick, name, email, web, picture, title]\n  - nick: String - squad nickname\n  - name: String - squad full name\n  - email: String - squad contact email\n  - web: String - squad website URL\n  - picture: String - squad picture URL\n  - title: String - squad title\n- memberInfo: Array with [uid, name, fullname, email, icq, remark]\n  - uid: String - member unique ID\n  - name: String - member name\n  - fullname: String - member full name\n  - email: String - member email\n  - icq: String - member ICQ number\n  - remark: String - member remark\n- Arma 3 v2.06 squadId: String - unique squad ID\n- Arma 3 v2.06 a3unitsId: String - unique Arma 3 Units  ID"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_info = squadParams player;\n```","code":["_info = squadParams player;"]},{"text":"```sqf\nsquadParams player params [\"_squadInfo\", \"_memberInfo\", \"_squadID\", \"_a3unitsID\"];\n```","code":["squadParams player params [\"_squadInfo\", \"_memberInfo\", \"_squadID\", \"_a3unitsID\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["squad.xml"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: System","Introduced with Arma 3 version 1.18","Scripting Commands"]},{"name":"stance","operator":null,"title":"stance","type":"command","url":"https://community.bistudio.com/wiki/stance","revid":363221,"updated":"2024-03-25T22:48:35Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the stance of the given unit.","syntaxes":[{"syntax":"stance unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"can be: - `\"STAND\"` - `\"CROUCH\"` - `\"PRONE\"` - `\"UNDEFINED\"` (for example, swimming) - `\"\"` (on non-person object)","text":"String - can be:\n- `\"STAND\"`\n- `\"CROUCH\"`\n- `\"PRONE\"`\n- `\"UNDEFINED\"` (for example, swimming)\n- `\"\"` (on non-person object)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nif (stance player == \"STAND\") then { hint \"I am standing!\" };\n```","code":["if (stance player == \"STAND\") then { hint \"I am standing!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["animationState","unitPos","pose","getLeaning"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"startLoadingScreen","operator":null,"title":"startLoadingScreen","type":"command","url":"https://community.bistudio.com/wiki/startLoadingScreen","revid":369458,"updated":"2024-09-06T08:44:54Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows loading screen with the given text, using the given resource.\nWhile loading screen is shown, simulation and scene drawing is disabled, user control is disabled, mouse cursor is hidden, scripts run at full speed (50ms per frame instead of 3ms per frame for Scheduled Scripts).\n\n> [!NOTE]\n>\n\n> [!WARNING]\n> - The loading screen does **not** end by itself and absolutely needs a call to endLoadingScreen command\n> - Game simulation is disabled during Loading Screen operation (at least in single player):\n>   - do **not** use the sleep command between startLoadingScreen and endLoadingScreen as **it may freeze the game** - use uiSleep instead\n>   - waitUntil *can* be used to wait for variable initialisation or script loading\n\n> [!NOTE]\n> **Arma 3:** - Use BIS_fnc_startLoadingScreen to prevent potential usage conflicts.\n> - The loading screen can be force-ended with the ENDLOAD cheat code.","syntaxes":[{"syntax":"startLoadingScreen [text, resource]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"},{"name":"resource","type":"String","optional":true,"default":null,"description":null,"types":["String"],"since":null,"text":"resource: String - (Optional)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, resource]","types":["Array"]}}],"examples":[{"text":"```sqf\nstartLoadingScreen [\"Loading My Mission, please wait...\"];\n```","code":["startLoadingScreen [\"Loading My Mission, please wait...\"];"]},{"text":"```sqf\nstartLoadingScreen [\"Can't skip loading time...\", \"MyLoadingRsc\"];\n```","code":["startLoadingScreen [\"Can't skip loading time...\", \"MyLoadingRsc\"];"]},{"text":"```sqf\nstartLoadingScreen [\"Loading My Mission\"];\n// code\nprogressLoadingScreen 0.5;\n// code\nendLoadingScreen;\n```","code":["startLoadingScreen [\"Loading My Mission\"];\n// code\nprogressLoadingScreen 0.5;\n// code\nendLoadingScreen;"]},{"text":"```sqf\n// this structure prevents error-prone or lengthy code to miss endLoadingScreen.\nprivate _maxTime = diag_tickTime + 30; // max 30s of loading\n\nstartLoadingScreen [\"Loading\"];\nprivate _handle = 0 spawn {\n    // code that may crash or take too long\n};\n\nwaitUntil { uiSleep .1; scriptDone _handle || diag_tickTime > _maxTime };\nendLoadingScreen;\n```","code":["// this structure prevents error-prone or lengthy code to miss endLoadingScreen.\nprivate _maxTime = diag_tickTime + 30; // max 30s of loading\n\nstartLoadingScreen [\"Loading\"];\nprivate _handle = 0 spawn {\n\t// code that may crash or take too long\n};\n\nwaitUntil { uiSleep .1; scriptDone _handle || diag_tickTime > _maxTime };\nendLoadingScreen;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["endLoadingScreen","progressLoadingScreen","BIS_fnc_startLoadingScreen","import (Config)"],"notes":[{"user":"Killzone_Kid","date":"2015-11-21T18:38:00Z","text":"The default Arma 3 loading screen has no control to display text."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"steamGameRecordingEvent","operator":null,"title":"steamGameRecordingEvent","type":"command","url":"https://community.bistudio.com/wiki/steamGameRecordingEvent","revid":377704,"updated":"2026-01-02T09:03:36Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Triggers a [Steam Timeline](https://partner.steamgames.com/doc/features/timeline) event within the [Game Recording](https://store.steampowered.com/gamerecording) feature. Read Arma 3: Steam Game Recording for more information and a list of all available event icons.","syntaxes":[{"syntax":"steamGameRecordingEvent parameters","since":null,"effect":null,"exec":null,"params":[{"name":"parameters","type":"Array with [eventClass, eventDuration, eventArguments, startOffset]","optional":false,"default":null,"description":"Array with [eventClass, eventDuration, eventArguments, startOffset]\n- eventClass: String - class in description.ext >> \"SteamGameRecording\" or config \"SteamManagerConfig\" >> \"GameRecording\" or a special utility string\n- eventDuration: Number - 0 for an instant event, or an amount of seconds this event lasted\n- eventArguments: Array of String - arguments that can be used to add dynamic info to the event (texts)\n- startOffset: Number - amount of seconds relative to the even trigger time","types":["Array"],"since":null,"text":"parameters: Array with [eventClass, eventDuration, eventArguments, startOffset]\n- eventClass: String - class in description.ext >> \"SteamGameRecording\" or config \"SteamManagerConfig\" >> \"GameRecording\" or a special utility string\n- eventDuration: Number - 0 for an instant event, or an amount of seconds this event lasted\n- eventArguments: Array of String - arguments that can be used to add dynamic info to the event (texts)\n- startOffset: Number - amount of seconds relative to the even trigger time"}],"returns":{"type":"String","types":["String"],"description":"event handle (which can be used to edit an event after it has been triggered)","text":"String - event handle (which can be used to edit an event after it has been triggered)"},"form":"unary","operator":null,"left":null,"right":{"text":"parameters","types":["Array"]}}],"examples":[{"text":"```sqf\nsteamGameRecordingEvent [\"UnitKilled\", 0, [\"Player1\", \"50\"]]; //\"UnitKilled\" event, happening now, with arguments\n```","code":["steamGameRecordingEvent [\"UnitKilled\", 0, [\"Player1\", \"50\"]]; //\"UnitKilled\" event, happening now, with arguments"]},{"text":"```sqf\nsteamGameRecordingEvent [\"ZeusUI\", 5, [], -5]; //Was in the Zeus UI during the last 5 seconds\n```","code":["steamGameRecordingEvent [\"ZeusUI\", 5, [], -5]; //Was in the Zeus UI during the last 5 seconds"]},{"text":"```sqf\nsteamGameRecordingEvent [\"StartGamePhase\", \"ArmaInvaders\"]; //Starting a game phase for [[Arma 3: Invaders]] with a unique ID\n```","code":["steamGameRecordingEvent [\"StartGamePhase\", \"ArmaInvaders\"]; //Starting a game phase for [[Arma 3: Invaders]] with a unique ID"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Steam Game Recording"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Arma 3 version 2.20","Scripting Commands"]},{"name":"step","operator":null,"title":"step","type":"command","url":"https://community.bistudio.com/wiki/step","revid":369298,"updated":"2024-09-03T18:42:52Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Optional step value. A countdown can be made with a negative value. If not set, the default step is 1.","syntaxes":[{"syntax":"for step stepSize","since":null,"effect":null,"exec":null,"params":[{"name":"for","type":"For Type","optional":false,"default":null,"description":null,"types":["For Type"],"since":null,"text":"for: For Type"},{"name":"stepSize","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"stepSize: Number"}],"returns":{"type":"For Type","types":["For Type"],"description":null,"text":"For Type"},"form":"binary","operator":null,"left":{"text":"for","types":["For Type"]},"right":{"text":"stepSize","types":["Number"]}}],"examples":[{"text":"```sqf\nfor \"_i\" from 20 to 10 step -2 do\n{\n    // ...\n};\n```","code":["for \"_i\" from 20 to 10 step -2 do\n{\n\t// ...\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"stop","operator":null,"title":"stop","type":"command","url":"https://community.bistudio.com/wiki/stop","revid":369977,"updated":"2024-10-22T13:04:51Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Stop an AI unit from turning or moving, preventing it to follow a watched object or engage an enemy properly - although if properly aligned, the unit -will- shoot the enemy. In essense, this is a scripted flag to suppress some of the AI procedures (to check the flag use stopped).\nIt may still change the stance if deemed appropriate (e.g. under fire). Use disableAI to disable specific AI capabilities.","syntaxes":[{"syntax":"unitName stop toggle","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"},{"name":"toggle","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"toggle: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unitName","types":["Object"]},"right":{"text":"toggle","types":["Boolean"]}}],"examples":[{"text":"```sqf\nloon1 stop true;\n```","code":["loon1 stop true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["stopped","doStop","commandStop"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"stopEngineRTD","operator":null,"title":"stopEngineRTD","type":"command","url":"https://community.bistudio.com/wiki/stopEngineRTD","revid":281862,"updated":"2021-06-16T21:15:36Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Instant engines stop.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"stopEngineRTD heli","since":null,"effect":null,"exec":null,"params":[{"name":"heli","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"heli: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"heli","types":["Object"]}}],"examples":[{"text":"stopEngineRTD myHeli","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enginesIsOnRTD"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"stopped","operator":null,"title":"stopped","type":"command","url":"https://community.bistudio.com/wiki/stopped","revid":329504,"updated":"2022-07-29T13:33:06Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if unit is stopped by stop command.","syntaxes":[{"syntax":"stopped unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqs\n? (stopped _loon1) : hint \"Loon1 is stopped\"\n```","code":["? (stopped _loon1) : hint \"Loon1 is stopped\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["stop"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"stopSound","operator":null,"title":"stopSound","type":"command","url":"https://community.bistudio.com/wiki/stopSound","revid":379071,"updated":"2026-09-25T11:47:34Z","groups":["Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Terminates the given sound. If sound object provided, such as say3D and there is .lip file playback attached, this playback will also terminate.","syntaxes":[{"syntax":"stopSound id or sound","since":null,"effect":null,"exec":null,"params":[{"name":"id","type":"Number","optional":false,"default":null,"description":"id returned by playSoundUI and playSound3D commands\n\n> [!IMPORTANT]\n> Sound ids are **local**.","types":["Number"],"since":null,"text":"id: Number - id returned by playSoundUI and playSound3D commands\n\n> [!IMPORTANT]\n> Sound ids are **local**."},{"name":"sound","type":"Object","optional":false,"default":null,"description":"sound object such as say3D, in which case the particular sound is stopped, or entity such as soldier, then all say3D sounds current and queued are stopped. Note that passing NetObject, when say3D is executed with 'isGlobal' option, will cause error. To stop global sound one needs to destroy the source, i.e. kill the speaking unit.","types":["Object"],"since":"arma3 2.24","text":"sound: Object - sound object such as say3D, in which case the particular sound is stopped, or entity such as soldier, then all say3D sounds current and queued are stopped. Note that passing NetObject, when say3D is executed with 'isGlobal' option, will cause error. To stop global sound one needs to destroy the source, i.e. kill the speaking unit."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"id or sound","types":[]}}],"examples":[{"text":"```sqf\nstopSound 10;\n```","code":["stopSound 10;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playSoundUI","playSound3D","soundParams"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sounds","Introduced with Arma 3 version 2.12","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"str","operator":null,"title":"str","type":"command","url":"https://community.bistudio.com/wiki/str","revid":347635,"updated":"2023-10-03T08:38:22Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts any value into a string, depending on its type. If an Object has a vehicleVarName, it is returned (see #Example 4).","syntaxes":[{"syntax":"str value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"}],"returns":{"type":"String","types":["String"],"description":"if value is a String, double quotes `\"\"` will surround it (see #Example 3)","text":"String - if *value* is a String, double quotes `\"\"` will surround it (see #Example 3)"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Anything"]}}],"examples":[{"text":"```sqf\n_s = str (5 + 2); // The value of _s is the string \"7\"\n```","code":["_s = str (5 + 2); // The value of _s is the string \"7\""]},{"text":"```sqf\na = [];\nac = 0;\nwhile { ac < 5 } do\n{\n    ac = count a;\n    a set [ac, format [\"Index %1\", ac]];\n};\nhintSilent str a; // hints all of [\"Index 0\",\"Index 1\",\"Index 2\",\"Index 3\",\"Index 4\"] including brackets, quotes and commas\n```","code":["a = [];\nac = 0;\nwhile { ac < 5 } do\n{\n\tac = count a;\n\ta set [ac, format [\"Index %1\", ac]];\n};\nhintSilent str a; // hints all of [\"Index 0\",\"Index 1\",\"Index 2\",\"Index 3\",\"Index 4\"] including brackets, quotes and commas"]},{"text":"```sqf\nstr [0, 0, 0] == \"[0, 0, 0]\";    // false\nstr [0, 0, 0] == \"[0,0,0]\";        // true\n\nstr \"a\";            // \"\"\"a\"\"\"\ncount str \"a\";        // 3\nstr text \"a\";        // \"a\"\ncount str text \"a\";    // 1\n```","code":["str [0, 0, 0] == \"[0, 0, 0]\";\t// false\nstr [0, 0, 0] == \"[0,0,0]\";\t\t// true\n\nstr \"a\";\t\t\t// \"\"\"a\"\"\"\ncount str \"a\";\t\t// 3\nstr text \"a\";\t\t// \"a\"\ncount str text \"a\";\t// 1"]},{"text":"```sqf\nstr objNull;        // \"<NULL-object>\"\nstr player;            // e.g \"B Alpha 1-1:1 (PlayerName)\"\nplayer setVehicleVarName \"PlayerUnit\";\nstr player;            // \"PlayerUnit\"\n```","code":["str objNull;\t\t// \"<NULL-object>\"\nstr player;\t\t\t// e.g \"B Alpha 1-1:1 (PlayerName)\"\nplayer setVehicleVarName \"PlayerUnit\";\nstr player;\t\t\t// \"PlayerUnit\""]}],"multiplayer":null,"problems":"Before Arma 3 v1.64 this command did not escape a String's double quotes `\"\"` properly.","aliases":[],"see_also":["toArray","toString","isText","select","count","find","endl","format","formatText"],"notes":[{"user":"Sbsmac","date":"2009-09-29T20:17:00Z","text":"When applied to a unit, this returns the variable name that was assigned to the unit in the editor (see also vehicleVarName).\nFor example, if you have created a playable unit with the name 'thePlayer' then you can use 'str player' to return \"thePlayer\"."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"sunOrMoon","operator":null,"title":"sunOrMoon","type":"command","url":"https://community.bistudio.com/wiki/sunOrMoon","revid":363669,"updated":"2024-04-14T20:21:37Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"| Time | sunOrMoon |\n|---|---|\n| 12:00 | 1 |\n| (...) | 1 |\n| 18:39 | 0.911201 |\n| 18:42 | 0.576303 |\n| 18:45 | 0.240862 |\n| 18:48 | 0 |\n| (...) | 0 |\n| 06:00 | 0.695308 |\n| 06:03 | 0.739519 |\n| 06:09 | 1 |\n| (...) | 1 |\n\nReturns the moon to sun transition state in range 0..1.\n\nThe return value is either 0 or 1 most of the time, the in-between values only returned during a few minutes in the morning and in the evening, depending on the date, and could be similar to shown here:","syntaxes":[{"syntax":"sunOrMoon","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"0 for night (moon), 1 for day (sun)","text":"Number - 0 for night (moon), 1 for day (sun)"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _transitionState = sunOrMoon;\n```","code":["private _transitionState = sunOrMoon;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["moonIntensity","moonPhase"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"supportInfo","operator":null,"title":"supportInfo","type":"command","url":"https://community.bistudio.com/wiki/supportInfo","revid":353306,"updated":"2024-03-15T17:11:45Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a list of supported operators and type. Each field of array has the format: \"x:name\" Where x can be:\n- 't' - type\n- 'n' - nullar operator\n- 'u' - unary operator\n- 'b' - binary operator.\n\n'name' is the operator or type name (in case operator, type of input operands is included).\n*mask* parameter can be an empty string, or one of field. In this case, function returns empty array, if operator is not included in the list. Limited wildcard support is available. Type *x* may be replaced with ***, meaning all types. For the *mask* partial match may be used, like *abc**, meaning any operators starting with 'abc' are reported, for example:\n- `\"\"` - list all types and commands\n- `\"t:*\"` - list all types\n- `\"*:<command>*\"` - list all entries for script *<command>*\n- Arma 3 v2.00 `\"i:<command>\"` - extended information about script *<command>*, Array of Array of Strings in format:\n[type, lowerCaseName, camelCaseName, description, example, result, resultType, leftArgType, rightArgType, Arma 3 v2.02 syntax]\n\n> [!NOTE]\n> `\"i:*\"` is not a wildcard but returns information about the multiplication operator instead.","syntaxes":[{"syntax":"supportInfo mask","since":null,"effect":null,"exec":null,"params":[{"name":"mask","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mask: String"}],"returns":{"type":"Array","types":["Array"],"description":"array with requested info or empty array `[]`","text":"Array - array with requested info or empty array `[]`"},"form":"unary","operator":null,"left":null,"right":{"text":"mask","types":["String"]}}],"examples":[{"text":"```sqf\nsupportInfo \"b:select*\"; // returns [\"b:ARRAY select SCALAR\",\"b:ARRAY select BOOL\",\"b:CONFIG select SCALAR\"]\n```","code":["supportInfo \"b:select*\"; // returns [\"b:ARRAY select SCALAR\",\"b:ARRAY select BOOL\",\"b:CONFIG select SCALAR\"]"]},{"text":"Return all available commands:\n\n```sqf\n_commands = supportInfo \"\";\n```","code":["_commands = supportInfo \"\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["productVersion","requiredVersion"],"notes":[{"user":"Killzone_Kid","date":"2014-09-24T19:27:00Z","text":"To get the list of all supported commands in Arma 3 one can simply:\n\n```sqf\n{ diag_log _x } forEach supportInfo \"\";\n```"},{"user":"7erra","date":"2020-10-19T10:23:00Z","text":"Since you can't use `supportInfo \"i:*\"` as a wildcard to get a list of all commands with detailed information, use this code instead:\n\n```sqf\n_allCommands = [];\nsupportInfo \"\" apply {\n    _x splitString \":\" params [\"_t\", \"_x\"];\n    if (_t != \"t\") then {\n        _x = _x splitString \" \";\n        _command = switch count _x do {\n            case 1;\n            case 2: { _x # 0 };\n            case 3: { _x # 1 };\n            default {nil};\n        };\n        _allCommands pushBackUnique _command;\n    };\n};\n_allCommands sort true;\n_allCommands = _allCommands apply {\n    supportInfo format[\"i:%1\", _x]\n};\n_allCommands;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: System","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"suppressFor","operator":null,"title":"suppressFor","type":"command","url":"https://community.bistudio.com/wiki/suppressFor","revid":321213,"updated":"2022-05-13T15:31:19Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Force suppressive fire from the unit.","syntaxes":[{"syntax":"unit suppressFor duration","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"duration","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"duration: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"duration","types":["Number"]}}],"examples":[{"text":"```sqf\n_soldier1 suppressFor 10; // Will force soldier1 to do suppressive fire to known enemies for 10 seconds\n```","code":["_soldier1 suppressFor 10; // Will force soldier1 to do suppressive fire to known enemies for 10 seconds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSuppression","getSuppression","commandSuppressiveFire","doSuppressiveFire"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"surfaceIsWater","operator":null,"title":"surfaceIsWater","type":"command","url":"https://community.bistudio.com/wiki/surfaceIsWater","revid":377565,"updated":"2026-01-02T06:55:29Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether there is water at given position. In Arma 3, it also detects pond objects, but only if they are loaded in memory (normally only true if the objects are within the object view distance)","syntaxes":[{"syntax":"surfaceIsWater position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D  or Position3D","optional":false,"default":null,"description":"when using Position3D Z will be ignored","types":["Position2D","Position3D"],"since":null,"text":"position: Position2D  or Position3D - when using Position3D Z will be ignored"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\nprivate _result = surfaceIsWater [1000, 3000];\n```","code":["private _result = surfaceIsWater [1000, 3000];"]},{"text":"```sqf\n_isWater = surfaceIsWater position player;\n```","code":["_isWater = surfaceIsWater position player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["surfaceType","surfaceNormal","nearRoads","roadsConnectedTo","roadAt","isOnRoad"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"surfaceNormal","operator":null,"title":"surfaceNormal","type":"command","url":"https://community.bistudio.com/wiki/surfaceNormal","revid":377547,"updated":"2026-01-02T06:54:42Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns terrain's [surface normal](https://en.wikipedia.org/wiki/Normal_(geometry)) on given position.","syntaxes":[{"syntax":"surfaceNormal position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D or Position3D","optional":false,"default":null,"description":"when using Position3D, Z is ignored","types":["Position2D","Position3D"],"since":null,"text":"position: Position2D or Position3D - when using Position3D, Z is ignored"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position2D","Position3D"]}}],"examples":[{"text":"```sqf\n_normal = surfaceNormal [300, 500];\n```","code":["_normal = surfaceNormal [300, 500];"]},{"text":"```sqf\n_normal = surfaceNormal getPosASL player;\n```","code":["_normal = surfaceNormal getPosASL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVectorUp","surfaceIsWater","surfaceType"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"surfaceTexture","operator":null,"title":"surfaceTexture","type":"command","url":"https://community.bistudio.com/wiki/surfaceTexture","revid":379082,"updated":"2026-09-27T08:09:04Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Same as surfaceType, but returns texture path to ground texture as string.\n\n> [!NOTE]\n> The texture returned is of the ground, even if there is a road at that position. To get road texture use getRoadInfo command.","syntaxes":[{"syntax":"surfaceTexture [x, y, useLayerMask]","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"world x coordinate of the position","types":["Number"],"since":null,"text":"x: Number - world x coordinate of the position"},{"name":"y","type":"Number","optional":false,"default":null,"description":"world y coordinate of the position","types":["Number"],"since":null,"text":"y: Number - world y coordinate of the position"},{"name":"useLayerMask","type":"Number or Boolean","optional":false,"default":null,"description":"When a number is provided (Z in 3D positions), it is ignored. When a boolean is provided, it defines whether the layer mask should be used. Using the layer mask is more accurate but slightly slower.","types":["Number","Boolean"],"since":"arma3 2.18","text":"useLayerMask: Number or Boolean - When a number is provided (Z in 3D positions), it is ignored. When a boolean is provided, it defines whether the layer mask should be used. Using the layer mask is more accurate but slightly slower."}],"returns":{"type":"String","types":["String"],"description":"Surface texture","text":"String - Surface texture"},"form":"unary","operator":null,"left":null,"right":{"text":"[x, y, useLayerMask]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _groundTexture = surfaceTexture getPosATL player;\n```","code":["private _groundTexture = surfaceTexture getPosATL player;"]},{"text":"```sqf\nprivate _pos = getPosATL player;\n_pos set [2, true]; // use layer mask\nprivate _groundTexture = surfaceTexture _pos;\n```","code":["private _pos = getPosATL player;\n_pos set [2, true]; // use layer mask\nprivate _groundTexture = surfaceTexture _pos;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["surfaceType","getRoadInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"surfaceType","operator":null,"title":"surfaceType","type":"command","url":"https://community.bistudio.com/wiki/surfaceType","revid":379085,"updated":"2026-09-27T08:28:22Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns what surface type is at the given position. For surface texture see surfaceTexture command.\n\n> [!NOTE]\n> The command returns surface type of the ground, even underneath objects such as buildings and roads\n\n- #GRASSSOUTH\n- #GRASSGENERAL\n- #SANDGENERAL\n\n- #UTGRASS - for natural surfaces\n- #UTCONCRETE - for urban surfaces\n\n- BuildingRubble\n- BuildingRubble_exp\n- cardboard\n- cardboard_exp\n- carpet\n- carpet_exp\n- carpet_inside\n- carpet_in_exp\n- concrete\n- concrete_exp\n- concrete_hall\n- concrete_hall_exp\n- concrete_inside\n- concrete_in_exp\n- concrete_out\n- Default\n- dirtrunway\n- floor\n- floor_exp\n- floor_inside\n- floor_in_exp\n- GdtAsphalt\n- GdtBeach\n- GdtCliff\n- GdtConcrete\n- GdtDead\n- GdtDesert\n- GdtDirt\n- GdtField\n- GdtForest\n- GdtForestMalden\n- GdtForestPine\n- GdtGrassDry\n- GdtGrassGreen\n- GdtGrassLong\n- GdtGrassShort\n- GdtGrassTall\n- GdtGrassWild\n- GdtKLCobblestone\n- GdtKLDirt\n- GdtKlField\n- GdtKLForestCon\n- GdtKLForestDec\n- GdtKLGrass1\n- GdtKLGrass2\n- GdtKlSoil\n- GdtKlStubble\n- GdtKlTarmac\n- GdtKlWeatheredTarmac\n- GdtMarsh\n- GdtMud\n- GdtRedDirt\n- GdtRock\n- GdtRubble\n- GdtSeabed\n- GdtSeabedExp\n- GdtSoil\n- GdtStony\n- GdtStonyThistle\n- GdtStratisBeach\n- GdtStratisConcrete\n- GdtStratisDirt\n- GdtStratisDryGrass\n- GdtStratisForestPine\n- GdtStratisGreenGrass\n- GdtStratisRocky\n- GdtStratisSeabed\n- GdtStratisSeabedCluttered\n- GdtStratisThistles\n- GdtThorn\n- GdtVolcano\n- GdtVolcanoBeach\n- GdtVRsurface01\n- GdtWeed\n- GdtWildField\n- grid\n- grid_exp\n- lino\n- lino_exp\n- lino_in_exp\n- mat_in_exp\n- metalPlate\n- metalPlatePressed_exp\n- metalPlate_exp\n- metalPlate_in_exp\n- mud\n- mud_exp\n- parquet\n- planks\n- planks_exp\n- planks_inside\n- planks_in_exp\n- road\n- road_exp\n- roof_tiles_exp\n- rubble\n- rubble_exp\n- sand\n- sand_exp\n- softwood_in_exp\n- steel\n- steel_exp\n- stones\n- stones_exp\n- straw_exp\n- SurfIntConcrete\n- SurfIntMetal\n- SurfIntTiles\n- SurfIntWood\n- surfint_concrete\n- surfint_metal\n- surfint_tiles\n- surfint_wood\n- SurfMetal\n- SurfRoadConcrete\n- SurfRoadConcrete_exp\n- SurfRoadDirt\n- SurfRoadDirt_Enoch\n- SurfRoadDirt_exp\n- SurfRoadTarmac\n- SurfRoadTarmac1_Enoch\n- SurfRoadTarmac2_Enoch\n- SurfRoadTarmac3_Enoch\n- SurfRoadTarmac_exp\n- SurfRoofTiles\n- SurfRoofTin\n- SurfTrailDirt_Enoch\n- SurfTrailDirt_exp\n- SurfWater\n- SurfWood\n- surf_metal\n- surf_roadconcrete\n- surf_roaddirt\n- surf_roadtarmac\n- surf_rooftiles\n- surf_rooftin\n- surf_wood\n- TEST_SurfNormal\n- tiling\n- trash\n- trash_exp\n- Water\n- wavyMetal\n- wavyMetal_exp\n- woodenFloor","syntaxes":[{"syntax":"surfaceType [x, y, z or useLayerMask]","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":"world x coordinate of the position","types":["Number"],"since":null,"text":"x: Number - world x coordinate of the position"},{"name":"y","type":"Number","optional":false,"default":null,"description":"world y coordinate of the position","types":["Number"],"since":null,"text":"y: Number - world y coordinate of the position"},{"name":"z or useLayerMask","type":"Number or Boolean","optional":true,"default":null,"description":"When a number is provided (Z in 3D positions), it is ignored. When a boolean is provided, it defines whether the layer mask should be used. Using the layer mask is more accurate but slightly slower.","types":["Number","Boolean"],"since":"arma3 2.18","text":"z or useLayerMask: Number or Boolean - (Optional) When a number is provided (Z in 3D positions), it is ignored. When a boolean is provided, it defines whether the layer mask should be used. Using the layer mask is more accurate but slightly slower."}],"returns":{"type":"String","types":["String"],"description":"Surface type","text":"String - Surface type"},"form":"unary","operator":null,"left":null,"right":{"text":"[x, y, z or useLayerMask]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _surface = surfaceType [4500, 4500];\n```","code":["private _surface = surfaceType [4500, 4500];"]},{"text":"```sqf\nhint surfaceType getPosWorld player;\n```","code":["hint surfaceType getPosWorld player;"]},{"text":"```sqf\nprivate _pos = getPosWorld player;\n_pos set [2, true]; // use layer mask\nsurfaceType _pos;\n```","code":["private _pos = getPosWorld player;\n_pos set [2, true]; // use layer mask\nsurfaceType _pos;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["surfaceTexture","surfaceIsWater","surfaceNormal","getAllEnvSoundControllers"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"swimInDepth","operator":null,"title":"swimInDepth","type":"command","url":"https://community.bistudio.com/wiki/swimInDepth","revid":369202,"updated":"2024-09-03T10:34:50Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the target depth level for swimming soldier. Depth should be a negative number.","syntaxes":[{"syntax":"unit swimInDepth value","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"value","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"value: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"value","types":["Number"]}}],"examples":[{"text":"```sqf\nsoldier swimInDepth -20;\n```","code":["soldier swimInDepth -20;"]},{"text":"```sqf\nbob swimInDepth -10;\nbob doMove ASLToAGL getPosASL player;\n```","code":["bob swimInDepth -10;\nbob doMove ASLToAGL getPosASL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["underwater"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"switch","operator":null,"title":"switch","type":"command","url":"https://community.bistudio.com/wiki/switch","revid":352209,"updated":"2024-02-01T23:26:04Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the given parameter matches any case. If so, the code block of that case will be executed. After that the switch ends so no further cases will be checked.\n\nIf a case has no code block the code of the next case will automatically be executed, making it possible to formulate a logical \"or\" for cases which would otherwise contain the exact same code (see #Example 2).\n\nThe default block will be executed **only** if no case matches, no matter its position inside the code block. It is not a case, and will **never** be entered by fallthrough.\n\n> [!NOTE]\n> - String comparison is case-sensitive. Use toUpper, toLower, toLowerANSI or toUpperANSI to force all strings to the same case.\n> - if no default block is provided and no case is matched, the switch block returns the default value true, otherwise it returns what the valid case block returns.","syntaxes":[{"syntax":"switch value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"value: Anything"}],"returns":{"type":"Switch Type","types":["Switch Type"],"description":null,"text":"Switch Type"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Anything"]}}],"examples":[{"text":"```sqf\nswitch (floor random 5) do\n{\n    case 1: { hint \"one\"; };\n    case 2: { hint \"two\"; };\n    default { hint \"zero, three or four\" };\n};\n```","code":["switch (floor random 5) do\n{\n\tcase 1: { hint \"one\"; };\n\tcase 2: { hint \"two\"; };\n\tdefault { hint \"zero, three or four\" };\n};"]},{"text":"```sqf\nswitch (_condition) do\n{\n    case \"string1\";\n    case \"string2\": { hint \"string1 or string2\" };\n    case \"string3\";\n    case \"string4\": { hint \"string3 or string4\" };\n    case \"string5\"; // will never enter default's code\n    default { hint \"default\" };\n};\n```","code":["switch (_condition) do\n{\n\tcase \"string1\";\n\tcase \"string2\": { hint \"string1 or string2\" };\n\tcase \"string3\";\n\tcase \"string4\": { hint \"string3 or string4\" };\n\tcase \"string5\"; // will never enter default's code\n\tdefault { hint \"default\" };\n};"]},{"text":"```sqf\nprivate _color = switch (side player) do\n{\n    case west: { \"ColorGreen\" };\n    case east: { \"ColorRed\" };\n};\n```","code":["private _color = switch (side player) do\n{\n\tcase west: { \"ColorGreen\" };\n\tcase east: { \"ColorRed\" };\n};"]},{"text":"```sqf\nprivate _fn_moveForward =    { /*...code...*/ };\nprivate _fn_moveBackward =    { /*...code...*/ };\nprivate _fn_invalidKey =    { /*...code...*/ };\n\nswitch true do\n{\n    case (_dikCode in actionKeys \"MoveForward\"):    _fn_moveForward;\n    case (_dikCode in actionKeys \"MoveBackward\"):    _fn_moveBackward;\n    default _fn_invalidKey;\n};\n```","code":["private _fn_moveForward =\t{ /*...code...*/ };\nprivate _fn_moveBackward =\t{ /*...code...*/ };\nprivate _fn_invalidKey =\t{ /*...code...*/ };\n\nswitch true do\n{\n\tcase (_dikCode in actionKeys \"MoveForward\"):\t_fn_moveForward;\n\tcase (_dikCode in actionKeys \"MoveBackward\"):\t_fn_moveBackward;\n\tdefault _fn_invalidKey;\n};"]},{"text":"```sqf\nswitch _var do\n{\n    case \"0\";\n    default { hint str [\"default\", _var] };\n    case \"3\": { hint str [\"3\", _var] };\n    case \"1\";\n    case \"4\";\n    case \"2\": { hint str [\"2\", _var] };\n};\n\n_var = \"0\"; // -> [\"3\", \"0\"]\n_var = \"1\"; // -> [\"2\", \"1\"]\n_var = \"2\"; // -> [\"2\", \"2\"]\n_var = \"3\"; // -> [\"3\", \"3\"]\n_var = \"4\"; // -> [\"2\", \"4\"]\n_var = \"5\"; // -> [\"default\", \"5\"]\n```","code":["switch _var do\n{\n\tcase \"0\";\n\tdefault { hint str [\"default\", _var] };\n\tcase \"3\": { hint str [\"3\", _var] };\n\tcase \"1\";\n\tcase \"4\";\n\tcase \"2\": { hint str [\"2\", _var] };\n};\n\n_var = \"0\"; // -> [\"3\", \"0\"]\n_var = \"1\"; // -> [\"2\", \"1\"]\n_var = \"2\"; // -> [\"2\", \"2\"]\n_var = \"3\"; // -> [\"3\", \"3\"]\n_var = \"4\"; // -> [\"2\", \"4\"]\n_var = \"5\"; // -> [\"default\", \"5\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","a:b","case","default"],"notes":[{"user":"ColonelSandersLite","date":"2007-08-07T07:49:00Z","text":"Be careful of the parentheses around the variable you're switching on.\nIf you accidentally use braces instead (e.g: `switch { _myVar } do { /*... */ }`), it won't error, but will always return default.\n\n> [!NOTE]\n> This is due to `{ _myvar }` being Code."},{"user":"Iva","date":"2009-10-06T14:43:00Z","text":"It's possible to use Boolean value as a switch and Code as case. One thing to take special care in such case is that code must be in parentheses. Example:\n\n```sqf\nswitch (true) do\n{\n    case (_boolVar): { someCode };\n    case (unit1 distance unit2 > 5): { someCode };\n};\n```"},{"user":"Freddo3000","date":"2020-11-01T10:05:00Z","text":"You are able to call code within the switch statements, such as:\n\n```sqf\nprivate _myFunc = {\n    systemChat \"0\";\n    case 1: { systemChat \"1\" };\n    systemChat \"2\";\n};\n\nprivate _myParameter = 1;\n\nswitch (_myParameter) do\n{\n    _myParameter call _myFunc;\n    case 1: { systemChat \"4\" };\n    systemChat \"3\";\n    default { systemChat \"-1\"; };\n};\n```\n\nHowever the order in which it is executed is difficult to make sense of, see the code comment.\n\nThis is used by BIS_fnc_missionConversations and BIS_fnc_missionTasks"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"switchableUnits","operator":null,"title":"switchableUnits","type":"command","url":"https://community.bistudio.com/wiki/switchableUnits","revid":376986,"updated":"2026-01-01T07:13:49Z","groups":["Multiplayer","Team Switch","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Returns a list of playable units available for switching to\n- Command is relative to the client on which it is executed and will only show playable units for the same side as player's group + player himself\n- In singleplayer where playable units from all sides will be accessible via this command\n- Dead and player-controlled units are automatically removed from the resulting array\n- In order to get all *playable* units regardless of their side, see the playableUnits command","syntaxes":[{"syntax":"switchableUnits","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_availableUnits = switchableUnits;\n```","code":["_availableUnits = switchableUnits;"]}],"multiplayer":"In Multiplayer, switchableUnits are only available when respawn type is set to SIDE or GROUP, the mission contains units marked playable and player is able to switch to any of those units. On dedicated servers, this command returns an empty array,.","problems":null,"aliases":[],"see_also":["Team Switch","playableUnits","allPlayers","teamSwitch"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Multiplayer","Command Group: Object Detection","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"switchAction","operator":null,"title":"switchAction","type":"command","url":"https://community.bistudio.com/wiki/switchAction","revid":323082,"updated":"2022-06-28T21:43:13Z","groups":["Unit Control","Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"When used on a person, the given action is started immediately (there is no transition). Use switchmove \"\" to switch back to the default movement if there is no transition back, otherwise the person may be stuck.","syntaxes":[{"syntax":"soldier switchAction action","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"action","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"action: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"action","types":["String"]}}],"examples":[{"text":"```sqf\nsoldierOne switchAction \"SitDown\";\n```","code":["soldierOne switchAction \"SitDown\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playAction","playActionNow","switchMove"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Command Group: Unit Control","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"switchCamera","operator":null,"title":"switchCamera","type":"command","url":"https://community.bistudio.com/wiki/switchCamera","revid":376544,"updated":"2025-10-27T12:56:35Z","groups":["Camera Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Switch camera to given vehicle / camera. Mode is one of:\n- **\"INTERNAL\"**: 1st person\n- **\"GUNNER\"**: optics / sights\n- **\"EXTERNAL\"**: 3rd person (inaccessible if difficulty settings do not allow for it)\n- **\"GROUP\"**: group\n- **\"CARGO\"**: same as \"INTERNAL\"\n\nIf you switch to a unit in a vehicle, this command uses the correct turret.\n\n> [!IMPORTANT]\n> - Control over the unit is not given to the player. Use selectPlayer or a combination of switchCamera and remoteControl to achieve this.\n> - Always switchCamera first (when needed) **before** using remoteControl as doing it after may lead to unpredictable results.","syntaxes":[{"syntax":"target switchCamera mode","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"},{"name":"mode","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"mode: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"target","types":["Object"]},"right":{"text":"mode","types":["String"]}},{"syntax":"switchCamera target","since":"arma3 1.66","effect":null,"exec":null,"params":[{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\nplayer switchCamera \"Gunner\";\n```","code":["player switchCamera \"Gunner\";"]},{"text":"```sqf\nvehicle player switchCamera \"External\";\n```","code":["vehicle player switchCamera \"External\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cameraView","cameraOn","cameraEffect","selectPlayer","remoteControl"],"notes":[{"user":"Killzone_Kid","date":"2015-05-16T13:14:00Z","text":"Force top down view:\n\n```sqf\nprivate _cameraObject = \"Land_HandyCam_F\" createVehicleLocal [0, 0, 0];\n_cameraObject hideObject true;\n_cameraObject attachTo [player, [0, 0, 10]];\n_cameraObject setVectorUp [0, 0.99, 0.01];\n_cameraObject switchCamera \"Internal\";\n\nfindDisplay 46 displayAddEventHandler [\"MouseButtonDown\", {\n    if (_this select 1 == 0) then\n    {\n        player forceWeaponFire [currentMuzzle player, currentWeaponMode player];\n    };\n\n    false;\n}];\n\nfindDisplay 46 displayAddEventHandler [\"KeyDown\", {\n    if (_this select 1 in actionKeys \"ReloadMagazine\") then\n    {\n        reload player;\n    };\n\n    false;\n}];\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Camera Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"switchGesture","operator":null,"title":"switchGesture","type":"command","url":"https://community.bistudio.com/wiki/switchGesture","revid":376921,"updated":"2025-12-29T12:08:48Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"When used on a person,the given move is started immediately (without transition).\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v2.18 it is possible to play gesture states (define in config under `\"CfgGesturesMale\" >> \"states\"` for male soldiers).\n> In addition, it is also possible to play move states (define in config under `\"CfgMovesMaleSdr\" >> \"states\"` for male soldiers) as gestures if they have a valid mask defined in their configs (for example, weapon switching animations have a \"WeaponSwitching\" mask that only affects the upper body, so they work correctly with this command).","syntaxes":[{"syntax":"soldier switchGesture moveName","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"moveName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"moveName: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"moveName","types":["String"]}},{"syntax":"soldier switchGesture [moveName, time, blendFactor, resetAim]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"moveName","type":"String","optional":false,"default":null,"description":"entry from `\"CfgMovesMaleSdr\" >> \"states\"` or `\"CfgGesturesMale\" >> \"states\"`","types":["String"],"since":null,"text":"moveName: String - entry from `\"CfgMovesMaleSdr\" >> \"states\"` or `\"CfgGesturesMale\" >> \"states\"`"},{"name":"time","type":"Number","optional":true,"default":"0","description":"normalised time, in range 0..1, where 0 = beginning of the animation, and 1 = end of the animation","types":["Number"],"since":null,"text":"time: Number - (Optional, default 0) normalised time, in range 0..1, where 0 = beginning of the animation, and 1 = end of the animation"},{"name":"blendFactor","type":"Number","optional":true,"default":"1","description":"how much to blend the current animation with the new animation, in range 0..1, where 0 = current animation, and 1 = new animation. When 1 is used, the switching is instant (not smooth).","types":["Number"],"since":null,"text":"blendFactor: Number -  (Optional, default 1) how much to blend the current animation with the new animation, in range 0..1, where 0 = current animation, and 1 = new animation. When 1 is used, the switching is instant (not smooth)."},{"name":"resetAim","type":"Boolean","optional":true,"default":"true","description":"whether the aim/head direction should be reset after switching","types":["Boolean"],"since":null,"text":"resetAim: Boolean - (Optional, default true) whether the aim/head direction should be reset after switching"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"[moveName, time, blendFactor, resetAim]","types":["Array"]}}],"examples":[{"text":"```sqf\nsoldierOne switchGesture \"Wave\";\n```","code":["soldierOne switchGesture \"Wave\";"]},{"text":"```sqf\n// Create a dummy agent that copies your moves\nai1 = createAgent [typeOf player, getPosATL player, [], 0, \"NONE\"];\nai1 disableAI \"ALL\";\n\nonEachFrame\n{\n    ai1 setAnimSpeedCoef getAnimSpeedCoef player;\n    ai1 setVectorDir vectorDir player;\n    private _m = animationState player;\n    private _g = gestureState player;\n    private _i = getUnitMovesInfo player;\n    private _a = getUnitMovesInfo ai1;\n\n    if (animationState ai1 != _m || abs(_i # 1 - _a # 1) > 0.1) then\n    {\n        ai1 switchMove [_m, _i # 0, _i # 3, false];\n    };\n\n    if ((gestureState ai1 != _g || abs(_i # 6 - _a # 6) > 0.1) && (_g != \"<none>\" && _g find \"_player\" < 0)) then\n    {\n        ai1 switchGesture [_g, _i # 5, _i # 8, false];\n    };\n}\n```","code":["// Create a dummy agent that copies your moves\nai1 = createAgent [typeOf player, getPosATL player, [], 0, \"NONE\"];\nai1 disableAI \"ALL\";\n\nonEachFrame\n{\n\tai1 setAnimSpeedCoef getAnimSpeedCoef player;\n\tai1 setVectorDir vectorDir player;\n\tprivate _m = animationState player;\n\tprivate _g = gestureState player;\n\tprivate _i = getUnitMovesInfo player;\n\tprivate _a = getUnitMovesInfo ai1;\n\n\tif (animationState ai1 != _m || abs(_i # 1 - _a # 1) > 0.1) then\n\t{\n\t\tai1 switchMove [_m, _i # 0, _i # 3, false];\n\t};\n\n\tif ((gestureState ai1 != _g || abs(_i # 6 - _a # 6) > 0.1) && (_g != \"<none>\" && _g find \"_player\" < 0)) then\n\t{\n\t\tai1 switchGesture [_g, _i # 5, _i # 8, false];\n\t};\n}"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["playGesture","getUnitMovesInfo","switchMove"],"notes":[{"user":".kju","date":"2010-08-31T18:42:00Z","text":"Rpt says \"Not implemented\" as of OA 1.54."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"switchLight","operator":null,"title":"switchLight","type":"command","url":"https://community.bistudio.com/wiki/switchLight","revid":364994,"updated":"2024-07-04T19:58:05Z","groups":["Lights"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Controls whether a lamp is lit or not.\n\n> [!NOTE]\n> This command was originally designed to only work with `CfgNonAIVehicles` class `\"StreetLamp\"` only.\n> Since Arma 3 v1.92 this command was extended to work with street lights and some prop lights, like portable construction light.","syntaxes":[{"syntax":"lamp switchLight mode","since":null,"effect":null,"exec":null,"params":[{"name":"lamp","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"lamp: Object"},{"name":"mode","type":"String","optional":false,"default":null,"description":"mode can be: \"ON\", \"OFF\" or \"AUTO\" (*lamp* is on only during nighttime, default)","types":["String"],"since":null,"text":"mode: String - mode can be: \"ON\", \"OFF\" or \"AUTO\" (*lamp* is on only during nighttime, default)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"lamp","types":["Object"]},"right":{"text":"mode","types":["String"]}}],"examples":[{"text":"```sqf\n(object 12345) switchLight \"OFF\";\n```","code":["(object 12345) switchLight \"OFF\";"]},{"text":"```sqf\nnearestObject [player, \"Streetlamp\"] switchLight \"OFF\";\n```","code":["nearestObject [player, \"Streetlamp\"] switchLight \"OFF\";"]},{"text":"```sqf\ncursorObject switchLight \"ON\";\n```","code":["cursorObject switchLight \"ON\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lightIsOn","BIS_fnc_switchLamp"],"notes":[{"user":"Killzone_Kid","date":"2013-09-16T11:14:00Z","text":"*Before Arma 3 v1.92* use setHit instead:\n\n```sqf\n_lamp = nearestObject [player, \"Lamps_base_F\"];\n_lamp setHit [\"light_1_hitpoint\", 0.97];    // off\n_lamp setHit [\"light_1_hitpoint\", 0];        // on\n```\n\nSwitch all lights off in the 500 radius of player:\n\n```sqf\nprivate _lamps = nearestObjects [player, [\"Lamps_base_F\", \"PowerLines_base_F\", \"PowerLines_Small_base_F\"], 500];\n\n{\n    for \"_i\" from 0 to (count getAllHitPointsDamage _x -1) do\n    {\n        _x setHitIndex [_i, 0.97];\n    };\n} forEach _lamps;\n```"},{"user":"Sa-Matra","date":"2023-03-01T14:12:31Z","text":"How to disable all lamps using the latest Arma 3 commands, a modern method. Disable all lights that are pre-placed on the map, on the entire map:\n\n```sqf\n{\n    _x switchLight \"OFF\";\n} forEach (1 allObjects 0);\n```\n\nDisable all script-spawned and editor-placed lamps:\n\n```sqf\n{\n    _x switchLight \"OFF\";\n} forEach (8 allObjects 0);\n```\n\nThese snippets iterate through all buildings and run switchLight on them. If they're lamps, they'll be turned off."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Lights","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"switchMove","operator":null,"title":"switchMove","type":"command","url":"https://community.bistudio.com/wiki/switchMove","revid":378292,"updated":"2026-04-01T13:01:19Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Immediately applies given animation to the unit. For a smooth transition from the current animation (by connecting animations successively, e.g `CurrentAnim -> Intermediate1 -> Intermediate2 -> TargetAnim`), use playMove or playMoveNow.\n\n> [!NOTE]\n> see Category:Moves for respective games animations.\n\nThis command first resets the unit's animation states (including aiming state, gesture state, etc.) then puts the unit in the first frame of the animation (therefore showing no transition).\nIf an invalid animation is provided, the unit's animations will be reset but no new animation will be played (see #Example 3).\n\n> [!NOTE]\n> It is a good practice to always use playMoveNow after switchMove to make sure the animation plays correctly when using the first syntax:\n>\n> ```sqf\n> _unit switchMove \"myMove\";\n> _unit playMoveNow \"myMove\";\n> ```\n>\n> The alternative syntax does this automatically.","syntaxes":[{"syntax":"person switchMove moveName","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"person: Object - unit"},{"name":"moveName","type":"String","optional":false,"default":null,"description":"animation state (see animationState)","types":["String"],"since":null,"text":"moveName: String - animation state (see animationState)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"moveName","types":["String"]}},{"syntax":"person switchMove [moveName, time, blendFactor, resetAim]","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":"unit","types":["Object"],"since":null,"text":"person: Object - unit"},{"name":"moveName","type":"String","optional":false,"default":null,"description":"entry from `\"CfgMovesMaleSdr\" >> \"states\"` or `\"CfgGesturesMale\" >> \"states\"`","types":["String"],"since":null,"text":"moveName: String - entry from `\"CfgMovesMaleSdr\" >> \"states\"` or `\"CfgGesturesMale\" >> \"states\"`"},{"name":"time","type":"Number","optional":true,"default":"0","description":"normalized time, in range 0..1, where 0 = beginning of the animation, and 1 = end of the animation","types":["Number"],"since":null,"text":"time: Number - (Optional, default 0) normalized time, in range 0..1, where 0 = beginning of the animation, and 1 = end of the animation"},{"name":"blendFactor","type":"Number","optional":true,"default":"1","description":"how much to blend the current animation with the new animation, in range 0..1, where 0 = current animation, and 1 = new animation. When 1 is used, the switching is instant (not smooth), similar to the first syntax.","types":["Number"],"since":null,"text":"blendFactor: Number - (Optional, default 1) how much to blend the current animation with the new animation, in range 0..1, where 0 = current animation, and 1 = new animation. When 1 is used, the switching is instant (not smooth), similar to the first syntax."},{"name":"resetAim","type":"Boolean","optional":true,"default":"true","description":"whether the aim/head direction should be reset after switching","types":["Boolean"],"since":null,"text":"resetAim: Boolean - (Optional, default true) whether the aim/head direction should be reset after switching"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"person","types":["Object"]},"right":{"text":"[moveName, time, blendFactor, resetAim]","types":["Array"]}}],"examples":[{"text":"Prone:\n\n```sqf\nplayer switchMove \"AmovPpneMstpSrasWrflDnon\";\n```","code":["player switchMove \"AmovPpneMstpSrasWrflDnon\";"]},{"text":"Sit player immediately and globally:\n\n```sqf\n[player, \"AmovPsitMstpSlowWrflDnon\"] remoteExec [\"switchMove\"];\n```","code":["[player, \"AmovPsitMstpSlowWrflDnon\"] remoteExec [\"switchMove\"];"]},{"text":"Resets unit's animation:\n\n```sqf\n_unit switchMove \"\";\n```","code":["_unit switchMove \"\";"]},{"text":"```sqf\n// Create a dummy agent that copies your moves\nai1 = createAgent [typeOf player, getPosATL player, [], 0, \"NONE\"];\nai1 disableAI \"ALL\";\nonEachFrame\n{\n    ai1 setAnimSpeedCoef getAnimSpeedCoef player;\n    ai1 setVectorDir vectorDir player;\n    private _m = animationState player;\n    private _g = gestureState player;\n    private _i = getUnitMovesInfo player;\n    private _a = getUnitMovesInfo ai1;\n    \n    if (animationState ai1 != _m || abs(_i#1 - _a#1) > 0.1) then\n    {\n        ai1 switchMove [_m, _i#0, _i#3, false];\n    };\n\n    if ((gestureState ai1 != _g || abs(_i#6 - _a#6) > 0.1) && (_g != \"<none>\" && _g find \"_player\" < 0)) then\n    {\n        ai1 switchGesture [_g, _i#5, _i#8, false];\n    };\n}\n```","code":["// Create a dummy agent that copies your moves\nai1 = createAgent [typeOf player, getPosATL player, [], 0, \"NONE\"];\nai1 disableAI \"ALL\";\nonEachFrame\n{\n\tai1 setAnimSpeedCoef getAnimSpeedCoef player;\n\tai1 setVectorDir vectorDir player;\n\tprivate _m = animationState player;\n\tprivate _g = gestureState player;\n\tprivate _i = getUnitMovesInfo player;\n\tprivate _a = getUnitMovesInfo ai1;\n\t\n\tif (animationState ai1 != _m || abs(_i#1 - _a#1) > 0.1) then\n\t{\n\t\tai1 switchMove [_m, _i#0, _i#3, false];\n\t};\n\n\tif ((gestureState ai1 != _g || abs(_i#6 - _a#6) > 0.1) && (_g != \"<none>\" && _g find \"_player\" < 0)) then\n\t{\n\t\tai1 switchGesture [_g, _i#5, _i#8, false];\n\t};\n}"]}],"multiplayer":"This command has a global effect when executed locally to the unit and will synchronise properly for JIP.\nIn this case the animation on the executing machine is immediate while on remote machines it will be transitional.\nIn order for the animation to change immediately on every PC in multiplayer, use global remote execution (see #Example 2).\nWhen the argument is remote, the animation change on the executing PC is only temporary.","problems":null,"aliases":[],"see_also":["switchGesture","playMove","playMoveNow","switchAction","playAction","playActionNow","animationState","getUnitMovesInfo"],"notes":[{"user":"Hurricane","date":"2007-03-25T23:48:00Z","text":"In some cases the movement won't stay. I.e. AI hostages that put their hands behind their heads (_hostage switchMove \"AmovPercMstpSsurWnonDnon\") won't hold their hands up, unless you first use disableAI \"autoTarget\" on them. They mostly put their hands down because they 'noticed' unknown objects."},{"user":"Killswitch","date":"2008-08-03T22:43:00Z","text":"This command will not cause an AnimChanged or AnimDone event. However, playMove will."},{"user":"AgentRev","date":"2016-11-12T20:11:00Z","text":"When using this command on the player unit outside unscheduled UI contexts, it will cause a minor camera glitch for a single frame.\n\nFor example,  Draw3D and KeyDown are UI contexts and so are not affected by the glitch, but EachFrame and scheduled scripts are not UI contexts and are affected by the glitch."},{"user":"Leopard20","date":"2021-08-08T15:59:00Z","text":"If the animation you're trying to use with this command has no connection/interpolation to the unit's base animation (usually \"AmovPercMstpSrasWrflDnon\"), the move might not play using switchMove alone. In such cases you have to do this:\n\n```sqf\n_unit switchMove _move; _unit playMoveNow _move;\n```\n\nThis must run in **unscheduled environment** (see isNil)\n\nAlternatively, just use the second syntax:\n\n```sqf\n_unit switchMove [_move];\n```"},{"user":"Leopard20","date":"2025-11-04T09:44:03Z","text":"You can loop an animation using a function like this (it's recommended to do `ai disableAI \"ANIM\"` first)\n\n```sqf\n// TAG_fnc_loopAnim\nparams [\"_unit\", \"_anim\"];\n\n// remove old EH\n_unit removeEventHandler [\"AnimStateChanged\", _unit getVariable [\"TAG_AnimStateChangedEH\", -1]];\n\nprivate _EH = -1;\n// if anim is empty, just stop looping\nif (_anim != \"\") then\n{\n    _EH = _unit addEventHandler [\"AnimStateChanged\", {  \n        params [\"_unit\", \"_anim\"]; \n        private _loopedAnim = _unit getVariable [\"TAG_LoopedAnim\", \"\"];\n        if (alive _unit && _anim != _loopedAnim) then {\n            _unit switchMove [_loopedAnim, 0, 0, false];\n        };\n    }];\n};\n\n_unit setVariable [\"TAG_AnimStateChangedEH\", _EH];\n_unit setVariable [\"TAG_LoopedAnim\", _anim];\n\n// start the anim\n_unit switchMove [_anim, 0, 0, false];\n```\n\nThen use the above code in a function, either by defining it in the function library or by doing \n\n```sqf\nTAG_fnc_loopAnim = { above code }\n```\n\nHow to use the function:\n\n```sqf\n// start looping\n[testUnit, \"HubSittingChairUA_move1\"] call TAG_fnc_loopAnim;\n\n// stop looping\n[testUnit, \"\"] call TAG_fnc_loopAnim;\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"synchronizedObjects","operator":null,"title":"synchronizedObjects","type":"command","url":"https://community.bistudio.com/wiki/synchronizedObjects","revid":377127,"updated":"2026-01-01T10:22:42Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Return the list of objects synchronized with the given unit.\n\n> [!NOTE]\n> synchronizedObjects only works on triggers and entities with AI (logics, soldiers/players, or vehicles that contain soldiers as the effective commander)","syntaxes":[{"syntax":"synchronizedObjects unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_objects = synchronizedObjects _logic;\n```","code":["_objects = synchronizedObjects _logic;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizeObjectsAdd","synchronizeObjectsRemove","synchronizedTriggers","synchronizedWaypoints"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"synchronizedTriggers","operator":null,"title":"synchronizedTriggers","type":"command","url":"https://community.bistudio.com/wiki/synchronizedTriggers","revid":377126,"updated":"2026-01-01T10:22:24Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of triggers synchronized with a given waypoint.","syntaxes":[{"syntax":"synchronizedTriggers waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"Trigger objects","text":"Array of Objects - Trigger objects"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nsynchronizedTriggers _someWaypoint;\n```","code":["synchronizedTriggers _someWaypoint;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizeObjectsAdd","synchronizeObjectsRemove","synchronizedWaypoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"synchronizedWaypoints","operator":null,"title":"synchronizedWaypoints","type":"command","url":"https://community.bistudio.com/wiki/synchronizedWaypoints","revid":377125,"updated":"2026-01-01T10:21:46Z","groups":["Waypoints","Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the list of waypoints synchronized with a given trigger or waypoint.","syntaxes":[{"syntax":"synchronizedWaypoints obj","since":null,"effect":null,"exec":null,"params":[{"name":"obj","type":"Object or Waypoint","optional":false,"default":null,"description":null,"types":["Object","Waypoint"],"since":null,"text":"obj: Object or Waypoint"}],"returns":{"type":"Array of Waypoints","types":["Array","Waypoint"],"description":null,"text":"Array of Waypoints"},"form":"unary","operator":null,"left":null,"right":{"text":"obj","types":["Object","Waypoint"]}}],"examples":[{"text":"```sqf\nsynchronizedWaypoints _someTrigger;\n```","code":["synchronizedWaypoints _someTrigger;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizeWaypoint"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Command Group: Waypoints","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"synchronizeObjectsAdd","operator":null,"title":"synchronizeObjectsAdd","type":"command","url":"https://community.bistudio.com/wiki/synchronizeObjectsAdd","revid":377071,"updated":"2026-01-01T09:31:05Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Add given objects to the unit's list of synchronized objects.","syntaxes":[{"syntax":"unit synchronizeObjectsAdd objects","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\n_acm = _groupLogic createUnit [\"AmbientCombatManager\", position player, [], 0, \"NONE\"];\n_acm synchronizeObjectsAdd [player];\n```","code":["_acm = _groupLogic createUnit [\"AmbientCombatManager\", position player, [], 0, \"NONE\"];\n_acm synchronizeObjectsAdd [player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizeObjectsRemove"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"synchronizeObjectsRemove","operator":null,"title":"synchronizeObjectsRemove","type":"command","url":"https://community.bistudio.com/wiki/synchronizeObjectsRemove","revid":377072,"updated":"2026-01-01T09:31:25Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Removes given objects from the unit's list of synchronized objects.","syntaxes":[{"syntax":"unit synchronizeObjectsRemove objects","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\nplayer synchronizeObjectsRemove [_object1, _object2, _object3];\n```","code":["player synchronizeObjectsRemove [_object1, _object2, _object3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizeObjectsAdd"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"synchronizeTrigger","operator":null,"title":"synchronizeTrigger","type":"command","url":"https://community.bistudio.com/wiki/synchronizeTrigger","revid":330384,"updated":"2022-09-04T21:38:28Z","groups":["Triggers","Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Synchronizes the trigger with zero or more waypoints.","syntaxes":[{"syntax":"trigger synchronizeTrigger waypoints","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger to synchronize","types":["Object"],"since":null,"text":"trigger: Object - trigger to synchronize"},{"name":"waypoints","type":"Array of Waypoints","optional":false,"default":null,"description":"waypoints to synchronize with trigger. Array can be empty to unset","types":["Array","Waypoint"],"since":null,"text":"waypoints: Array of Waypoints - waypoints to synchronize with trigger. Array can be empty to unset"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"trigger","types":["Object"]},"right":{"text":"waypoints","types":["Array","Waypoint"]}}],"examples":[{"text":"```sqf\n_trigger synchronizeTrigger [];\n```","code":["_trigger synchronizeTrigger [];"]},{"text":"```sqf\n_trigger synchronizeTrigger [_waypoint1];\n```","code":["_trigger synchronizeTrigger [_waypoint1];"]},{"text":"```sqf\n_trigger synchronizeTrigger [_waypoint1, [_group5, 7], _waypoint3];\n```","code":["_trigger synchronizeTrigger [_waypoint1, [_group5, 7], _waypoint3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["createTrigger","synchronizeWaypoint"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"synchronizeWaypoint","operator":null,"title":"synchronizeWaypoint","type":"command","url":"https://community.bistudio.com/wiki/synchronizeWaypoint","revid":377321,"updated":"2026-01-02T06:38:53Z","groups":["Waypoints","Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Synchronizes the trigger or the waypoint with an array of waypoints.","syntaxes":[{"syntax":"triggerOrWaypoint synchronizeWaypoint waypoints","since":null,"effect":null,"exec":null,"params":[{"name":"triggerOrWaypoint","type":"Object or Waypoint","optional":false,"default":null,"description":"can be:\n- Object - trigger\n- Waypoint - Array format of Waypoint","types":["Object","Waypoint"],"since":null,"text":"triggerOrWaypoint: Object or Waypoint - can be:\n- Object - trigger\n- Waypoint - Array format of Waypoint"},{"name":"waypoints","type":"Array of Waypoints","optional":false,"default":null,"description":null,"types":["Array","Waypoint"],"since":null,"text":"waypoints: Array of Waypoints"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"triggerOrWaypoint","types":["Object","Waypoint"]},"right":{"text":"waypoints","types":["Array","Waypoint"]}}],"examples":[{"text":"```sqf\n_myTrigger synchronizeWaypoint [[_group2, 3]];\n```","code":["_myTrigger synchronizeWaypoint [[_group2, 3]];"]},{"text":"```sqf\n[_group1, 2] synchronizeWaypoint [[_group2, 3]];\n```","code":["[_group1, 2] synchronizeWaypoint [[_group2, 3]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["synchronizedWaypoints","createTrigger","synchronizeTrigger"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"systemChat","operator":null,"title":"systemChat","type":"command","url":"https://community.bistudio.com/wiki/systemChat","revid":376770,"updated":"2025-11-17T00:03:10Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.63"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Types text to the system radio channel. The text will be visible only on the PC where command was executed. If you need the message to show on all computers, you have to execute it globally (see remoteExec). Use clearRadio to clear chat history","syntaxes":[{"syntax":"systemChat text","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"text: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"text","types":["String"]}}],"examples":[{"text":"```sqf\nsystemChat \"Hello world!\";\n```","code":["systemChat \"Hello world!\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","groupChat","vehicleChat","commandChat","customChat","sideChat","directSay","clearRadio"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Arma 2: Operation Arrowhead version 1.63","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"systemOfUnits","operator":null,"title":"systemOfUnits","type":"command","url":"https://community.bistudio.com/wiki/systemOfUnits","revid":321214,"updated":"2022-05-13T15:31:34Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the currently selected system of units.\n- 0: Metric\n- 1: Mixed (ground vehicles use Metric / air vehicles use Imperial)\n- 2: Imperial","syntaxes":[{"syntax":"systemOfUnits","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_system = systemOfUnits;\n```","code":["_system = systemOfUnits;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_convertUnits","setSystemOfUnits"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: System","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"systemTime","operator":null,"title":"systemTime","type":"command","url":"https://community.bistudio.com/wiki/systemTime","revid":347950,"updated":"2023-11-07T05:40:08Z","groups":["Time"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns system time.","syntaxes":[{"syntax":"systemTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":null,"types":["Array","Number"],"description":null,"text":"Array of Numbers in format [year, month, day, hour, minute, second, millisecond]"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _currentTime = systemTime;\n```","code":["private _currentTime = systemTime;"]},{"text":"```sqf\nsystemTime apply {if (_x < 10) then {\"0\" + str _x} else {str _x}}; // [\"2021\",\"05\",\"03\",\"14\",\"09\",\"37\",\"593\"]\n```","code":["systemTime apply {if (_x < 10) then {\"0\" + str _x} else {str _x}}; // [\"2021\",\"05\",\"03\",\"14\",\"09\",\"37\",\"593\"]"]},{"text":"```sqf\nsystemTime params [\"_year\", \"_month\", \"_day\", \"_hour\", \"_minute\", \"_second\", \"_millisecond\"];\n```","code":["systemTime params [\"_year\", \"_month\", \"_day\", \"_hour\", \"_minute\", \"_second\", \"_millisecond\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["systemTimeUTC","date","time","dayTime","diag_tickTime","serverTime","missionStart","diag_deltaTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Time","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"systemTimeUTC","operator":null,"title":"systemTimeUTC","type":"command","url":"https://community.bistudio.com/wiki/systemTimeUTC","revid":378414,"updated":"2026-04-04T08:38:50Z","groups":["Time"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns systemTime according to **U**niversal **T**ime **C**oordinated time scale.","syntaxes":[{"syntax":"systemTimeUTC","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [year, month, day, hour, minute, second, millisecond]","types":["Array"],"description":"year: Number - month: Number - day: Number - hour: Number - minute: Number - second: Number - millisecond: Number","text":"Array with [year, month, day, hour, minute, second, millisecond]\n- year: Number\n- month: Number\n- day: Number\n- hour: Number\n- minute: Number\n- second: Number\n- millisecond: Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _UKTime = systemTimeUTC;\n```","code":["private _UKTime = systemTimeUTC;"]},{"text":"```sqf\nsystemTimeUTC apply { if (_x < 10) then { \"0\" + str _x } else { str _x } }; // [\"2021\",\"05\",\"03\",\"14\",\"09\",\"37\",\"593\"]\n```","code":["systemTimeUTC apply { if (_x < 10) then { \"0\" + str _x } else { str _x } }; // [\"2021\",\"05\",\"03\",\"14\",\"09\",\"37\",\"593\"]"]},{"text":"```sqf\nprivate _timeUTC = systemTimeUTC;\nprivate _time = systemTime;\nprivate _timeDiffH = (_time select 3) - (_timeUTC select 3);\nprivate _timeDiffM = (_time select 4) - (_timeUTC select 4);\nif (_timeDiffM < 0) then\n{\n    _timeDiffH = _timeDiffH - 1;\n    _timeDiffM = _timeDiffM + 60;\n};\nif (_timeDiffH < -12) then\n{\n    _timeDiffH = _timeDiffH + 24;\n};\nif (_timeDiffH > 12) then\n{\n    _timeDiffH = _timeDiffH - 24;\n};\nprivate _timeZone = [_timeDiffH, _timeDiffM]; // hour (_timeDiffH) is in range -12..+12\n```","code":["private _timeUTC = systemTimeUTC;\nprivate _time = systemTime;\nprivate _timeDiffH = (_time select 3) - (_timeUTC select 3);\nprivate _timeDiffM = (_time select 4) - (_timeUTC select 4);\nif (_timeDiffM < 0) then\n{\n\t_timeDiffH = _timeDiffH - 1;\n\t_timeDiffM = _timeDiffM + 60;\n};\nif (_timeDiffH < -12) then\n{\n\t_timeDiffH = _timeDiffH + 24;\n};\nif (_timeDiffH > 12) then\n{\n\t_timeDiffH = _timeDiffH - 24;\n};\nprivate _timeZone = [_timeDiffH, _timeDiffM]; // hour (_timeDiffH) is in range -12..+12"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["systemTime","date","time","dayTime","diag_tickTime","serverTime","missionStart","diag_deltaTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Time","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"tan","operator":null,"title":"tan","type":"command","url":"https://community.bistudio.com/wiki/tan","revid":310889,"updated":"2022-05-07T20:31:30Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Tangent of x, argument in Degrees.","syntaxes":[{"syntax":"tan x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_tangent = tan 45;\n```\n\nResult is 1","code":["_tangent = tan 45;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Math Commands"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"targetKnowledge","operator":null,"title":"targetKnowledge","type":"command","url":"https://community.bistudio.com/wiki/targetKnowledge","revid":377833,"updated":"2026-01-03T04:31:58Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.50"}],"since":{"game":"arma3","name":"Arma 3","version":"1.50"},"arma3_since":"1.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unit's knowledge about target.","syntaxes":[{"syntax":"unit targetKnowledge target","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"target","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"target: Object"}],"returns":{"type":"Array with [knownByGroup, knownByUnit, lastSeen, lastThreat, side, errorMargin, position, ignoreTarget]","types":["Array"],"description":"knownByGroup: Boolean - target known by group - knownByUnit: Boolean - target known by the unit - lastSeen: Number - last time the target was seen by the unit - lastThreat: Number - last time the target endangered the unit - side: Side - target side - errorMargin: Number - position error - position: Position - target position - Arma 3 v2.18 ignoreTarget: Boolean - target is ignored (ignoreTarget)","text":"Array with [knownByGroup, knownByUnit, lastSeen, lastThreat, side, errorMargin, position, ignoreTarget]\n- knownByGroup: Boolean - target known by group\n- knownByUnit: Boolean - target known by the unit\n- lastSeen: Number - last time the target was seen by the unit\n- lastThreat: Number - last time the target endangered the unit\n- side: Side - target side\n- errorMargin: Number - position error\n- position: Position - target position\n- Arma 3 v2.18 ignoreTarget: Boolean - target is ignored (ignoreTarget)"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"target","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _allInfo = _soldierOne targetKnowledge _jeepOne;\n_allInfo params [\"_knownByGroup\", \"_knownByUnit\", \"_lastSeen\", \"_lastThreat\", \"_side\", \"_errorMargin\", \"_position\", \"_ignoreTarget\"];\n```","code":["private _allInfo = _soldierOne targetKnowledge _jeepOne;\n_allInfo params [\"_knownByGroup\", \"_knownByUnit\", \"_lastSeen\", \"_lastThreat\", \"_side\", \"_errorMargin\", \"_position\", \"_ignoreTarget\"];"]},{"text":"```sqf\nprivate _posError = (_soldierOne targetKnowledge _jeepOne) select 5;\n```","code":["private _posError = (_soldierOne targetKnowledge _jeepOne) select 5;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["knowsAbout","targets","targetsQuery","nearTargets","targetsAggregate","reveal","forgetTarget","setTargetAge","getHideFrom","ignoreTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.50","Scripting Commands"]},{"name":"targets","operator":null,"title":"targets","type":"command","url":"https://community.bistudio.com/wiki/targets","revid":377208,"updated":"2026-01-01T11:46:32Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Retrieves list of given unit targets matching specified filter. If the filter is not specified, all targets are returned.\n\n> [!NOTE]\n> If a unit is provided, the unit itself will be excluded from results. If a group is provided, its units will be excluded (even if renegades).","syntaxes":[{"syntax":"unitOrGroup targets [enemyOnly, maxDistance, sides, maxAge, alternateCenter]","since":null,"effect":null,"exec":null,"params":[{"name":"unitOrGroup","type":"Object or Arma 3 v2.12 Group","optional":false,"default":null,"description":"unit or group which target knowledge is retrieved","types":["Object","Group"],"since":null,"text":"unitOrGroup: Object or Arma 3 v2.12 Group - unit or group which target knowledge is retrieved"},{"name":"enemyOnly","type":"Boolean","optional":true,"default":"false","description":"true to include only enemy targets, false to include all targets","types":["Boolean"],"since":null,"text":"enemyOnly: Boolean - (Optional, default false) true to include only enemy targets, false to include all targets"},{"name":"maxDistance","type":"Number","optional":true,"default":"-1","description":"maximum **2D** distance based on target's expected position; use 0 to ignore the filter","types":["Number"],"since":null,"text":"maxDistance: Number - (Optional, default -1) maximum **2D** distance based on target's expected position; use 0 to ignore the filter"},{"name":"sides","type":"Array of Sides","optional":true,"default":"`[]`","description":"array of accepted sides; use `[]` to ignore the side filter","types":["Array","Side"],"since":null,"text":"sides: Array of Sides - (Optional, default `[]`) array of accepted sides; use `[]` to ignore the side filter"},{"name":"maxAge","type":"Number","optional":true,"default":"0","description":"max. target age, targets that are known to unit for longer than maxAge are ignored; use 0 to ignore the maxAge filter","types":["Number"],"since":null,"text":"maxAge: Number - (Optional, default 0) max. target age, targets that are known to unit for longer than maxAge are ignored; use 0 to ignore the maxAge filter"},{"name":"alternateCenter","type":"Array","optional":true,"default":"unitOrGroups position","description":"alternate (2D or 3D) position used for** 2D*' distance check","types":["Array"],"since":null,"text":"alternateCenter: Array - (Optional, default *unitOrGroup**s position) alternate (2D or 3D) position used for** 2D*' distance check"}],"returns":{"type":"Array","types":["Array"],"description":"unitOrGroup's targets matching the criteria","text":"Array - *unitOrGroup*'s targets matching the criteria"},"form":"binary","operator":null,"left":{"text":"unitOrGroup","types":["Object","Group"]},"right":{"text":"[enemyOnly, maxDistance, sides, maxAge, alternateCenter]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _targets = _unit targets [false, 300, [east, sideEnemy]]; // all targets of east or renegade side in 300m\n```","code":["private _targets = _unit targets [false, 300, [east, sideEnemy]]; // all targets of east or renegade side in 300m"]},{"text":"```sqf\nprivate _targets = _unit targets [true, 300]; // enemy targets in 300m\n```","code":["private _targets = _unit targets [true, 300]; // enemy targets in 300m"]},{"text":"```sqf\nprivate _targets = _unit targets []; // all targets\n```","code":["private _targets = _unit targets []; // all targets"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targetsQuery","nearTargets","targetsAggregate","targetKnowledge","knowsAbout","reveal","forgetTarget","setTargetAge","getHideFrom","side"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"targetsAggregate","operator":null,"title":"targetsAggregate","type":"command","url":"https://community.bistudio.com/wiki/targetsAggregate","revid":377663,"updated":"2026-01-02T09:02:16Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Aggregate candidates.","syntaxes":[{"syntax":"[speaker, side, classname, position, timeMax] targetsAggregate candidates","since":null,"effect":null,"exec":null,"params":[{"name":"speaker","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"speaker: Object"},{"name":"side","type":"Side","optional":false,"default":null,"description":"if provided, a target with a side matching *side* will see it replaced by `\"$\"`","types":["Side"],"since":null,"text":"side: Side - if provided, a target with a side matching *side* will see it replaced by `\"$\"`"},{"name":"classname","type":"String","optional":false,"default":null,"description":"`CfgVehicles` classname - if provided, a target with a type matching *classname* will see it replaced by `\"$\"`","types":["String"],"since":null,"text":"classname: String - `CfgVehicles` classname - if provided, a target with a type matching *classname* will see it replaced by `\"$\"`"},{"name":"position","type":"Position (Z-value is ignored)","optional":false,"default":null,"description":"centre of a hardcoded 200m radius","types":["Position"],"since":null,"text":"position: Position (Z-value is ignored) - centre of a hardcoded 200m radius"},{"name":"timeMax","type":"Number","optional":false,"default":null,"description":"max age of the target","types":["Number"],"since":null,"text":"timeMax: Number - max age of the target"},{"name":"candidates","type":null,"optional":false,"default":null,"description":"Array of Arrays with [accuracy, target, targetSide, targetType, targetPosition, targetAge]\n- accuracy: Number - a coefficient, which reflects how close the returned result to the query filter. Range: 0..1, 1 being the best match\n- target: Object - the actual target object\n- targetSide: Side - side of the target\n- targetType: String - target typeOf\n- targetPosition: Position2D - [x,y] of the target\n- targetAge: Number - the actual target age in seconds (can be negative)\n\n> [!NOTE]\n> See targetsQuery format.","types":["Array"],"since":null,"text":"candidates: Array of Arrays with [accuracy, target, targetSide, targetType, targetPosition, targetAge]\n- accuracy: Number - a coefficient, which reflects how close the returned result to the query filter. Range: 0..1, 1 being the best match\n- target: Object - the actual target object\n- targetSide: Side - side of the target\n- targetType: String - target typeOf\n- targetPosition: Position2D - [x,y] of the target\n- targetAge: Number - the actual target age in seconds (can be negative)\n\n> [!NOTE]\n> See targetsQuery format."}],"returns":{"type":"Array with [countInfo, sideInfo, unitInfo, placeInfo, timeInfo, uCountInfo, uTypeInfo]","types":["Array"],"description":"countInfo: Array - [format [\"COUNT%1\", index], count on index] - sideInfo: Array - [format [\"SIDE%1\", index], side or string] if string then $ == \"equal to queried\" - unitInfo: Array - [format [\"UNIT%1\", index], string] $ == \"equal to queried\", otherwise the \"type\" of the unit? Should be CfgVehicles config type I think - placeInfo: Array - [format [\"PLACE%1\", index], [[centerX, centerY], radius]] - timeInfo: Array - [format [\"TIME%1\", index], string or array] if string then $ == \"equal to queried\", otherwise [timeMin, timeMax] - uCountInfo: Array - [format [\"UCOUNT%1\", index], scalar count] - uTypeInfo: Array - [format [\"UTYPE%1\", index], string name] a classname? Will be format [\"*%1\", classname] if count > 1","text":"Array with [countInfo, sideInfo, unitInfo, placeInfo, timeInfo, uCountInfo, uTypeInfo]\n- countInfo: Array - [format [\"COUNT%1\", index], count on index]\n- sideInfo: Array - [format [\"SIDE%1\", index], side or string] if string then $ == \"equal to queried\"\n- unitInfo: Array - [format [\"UNIT%1\", index], string]  $ == \"equal to queried\", otherwise the \"type\" of the unit? Should be CfgVehicles config type I think\n- placeInfo: Array - [format [\"PLACE%1\", index], [[centerX, centerY], radius]]\n- timeInfo: Array - [format [\"TIME%1\", index], string or array] if string then $ == \"equal to queried\", otherwise [timeMin, timeMax]\n- uCountInfo: Array - [format [\"UCOUNT%1\", index], scalar count]\n- uTypeInfo: Array - [format [\"UTYPE%1\", index], string name] a classname? Will be format [\"*%1\", classname] if count > 1"},"form":"binary","operator":null,"left":{"text":"[speaker, side, classname, position, timeMax]","types":["Array"]},"right":{"text":"candidates","types":["Array"]}}],"examples":[{"text":"```sqf\n_aggregation = [player, sideEnemy, \"\", [], 0] targetsAggregate (player targetsQuery [objNull, sideUnknown, \"\", [], 0]);\n/*\n    returns e.g\n    [\n        [\n            [\"COUNT0\", 1],\n            [\"SIDE0\", WEST],\n            [\"UNIT0\", \"B_Soldier_F\"],\n            [\"PLACE0\", [[<null>,<null>], 0, <null>]],\n            [\"TIME0\", [-0.9, -0.9]],\n            [\"UCOUNT0\", 1],\n            [\"UTYPE0\", ...\n        ]\n    ]\n*/\n```\n\nwith e.g\n- one Orca Helicopter\n- one T-100 Varsuk tank\n- one T-140K Angara tank\n- one MBT-52 Kuma tank (independent, set as enemy to blufor)\n\n```sqf\n/*\n    [\n        [[\"COUNT0\",1],[\"SIDE0\",EAST],[\"UNIT0\",\"O_Heli_Light_02_dynamicLoadout_F\"],[\"PLACE0\",[[<null>,<null>],0,<null>]],[\"TIME0\",[-0.982,-0.982]],[\"UCOUNT0\",1],[\"UTYPE0\",\"O_Heli_Light_02_dynamicLoadout_F\"]],\n        [[\"COUNT1\",1],[\"SIDE1\",GUER],[\"UNIT1\",\"I_MBT_03_cannon_F\"],[\"PLACE1\",[[<null>,<null>],0,<null>]],[\"TIME1\",[-0.982,-0.982]],[\"UCOUNT1\",1],[\"UTYPE1\",\"I_MBT_03_cannon_F\"]],\n        [[\"COUNT2\",2],[\"SIDE2\",EAST],[\"UNIT2\",\"*Tank_F\"],[\"PLACE2\",[[<null>,<null>],4.34554,<null>]],[\"TIME2\",[-0.982,-0.982]],[\"UCOUNT2\",2],[\"UTYPE2\",\"*O_MBT_02_cannon_F\"]]]\n    [\n        [[\"COUNT0\",1],[\"SIDE0\",EAST],[\"UNIT0\",\"O_Heli_Light_02_dynamicLoadout_F\"],[\"PLACE0\",[[<null>,<null>],0,<null>]],[\"TIME0\",[-1,-1]],[\"UCOUNT0\",1],[\"UTYPE0\",\"O_Heli_Light_02_dynamicLoadout_F\"]],\n        [[\"COUNT1\",1],[\"SIDE1\",GUER],[\"UNIT1\",\"I_MBT_03_cannon_F\"],[\"PLACE1\",[[<null>,<null>],0,<null>]],[\"TIME1\",[-1,-1]],[\"UCOUNT1\",1],[\"UTYPE1\",\"I_MBT_03_cannon_F\"]],\n        [[\"COUNT2\",2],[\"SIDE2\",EAST],[\"UNIT2\",\"*Tank_F\"],[\"PLACE2\",[[<null>,<null>],4.34565,<null>]],[\"TIME2\",[-1,-1]],[\"UCOUNT2\",2],[\"UTYPE2\",\"*O_MBT_02_cannon_F\"]]\n    ]\n*/\n```","code":["_aggregation = [player, sideEnemy, \"\", [], 0] targetsAggregate (player targetsQuery [objNull, sideUnknown, \"\", [], 0]);\n/*\n\treturns e.g\n\t[\n\t\t[\n\t\t\t[\"COUNT0\", 1],\n\t\t\t[\"SIDE0\", WEST],\n\t\t\t[\"UNIT0\", \"B_Soldier_F\"],\n\t\t\t[\"PLACE0\", [[<null>,<null>], 0, <null>]],\n\t\t\t[\"TIME0\", [-0.9, -0.9]],\n\t\t\t[\"UCOUNT0\", 1],\n\t\t\t[\"UTYPE0\", ...\n\t\t]\n\t]\n*/","/*\n\t[\n\t\t[[\"COUNT0\",1],[\"SIDE0\",EAST],[\"UNIT0\",\"O_Heli_Light_02_dynamicLoadout_F\"],[\"PLACE0\",[[<null>,<null>],0,<null>]],[\"TIME0\",[-0.982,-0.982]],[\"UCOUNT0\",1],[\"UTYPE0\",\"O_Heli_Light_02_dynamicLoadout_F\"]],\n\t\t[[\"COUNT1\",1],[\"SIDE1\",GUER],[\"UNIT1\",\"I_MBT_03_cannon_F\"],[\"PLACE1\",[[<null>,<null>],0,<null>]],[\"TIME1\",[-0.982,-0.982]],[\"UCOUNT1\",1],[\"UTYPE1\",\"I_MBT_03_cannon_F\"]],\n\t\t[[\"COUNT2\",2],[\"SIDE2\",EAST],[\"UNIT2\",\"*Tank_F\"],[\"PLACE2\",[[<null>,<null>],4.34554,<null>]],[\"TIME2\",[-0.982,-0.982]],[\"UCOUNT2\",2],[\"UTYPE2\",\"*O_MBT_02_cannon_F\"]]]\n\t[\n\t\t[[\"COUNT0\",1],[\"SIDE0\",EAST],[\"UNIT0\",\"O_Heli_Light_02_dynamicLoadout_F\"],[\"PLACE0\",[[<null>,<null>],0,<null>]],[\"TIME0\",[-1,-1]],[\"UCOUNT0\",1],[\"UTYPE0\",\"O_Heli_Light_02_dynamicLoadout_F\"]],\n\t\t[[\"COUNT1\",1],[\"SIDE1\",GUER],[\"UNIT1\",\"I_MBT_03_cannon_F\"],[\"PLACE1\",[[<null>,<null>],0,<null>]],[\"TIME1\",[-1,-1]],[\"UCOUNT1\",1],[\"UTYPE1\",\"I_MBT_03_cannon_F\"]],\n\t\t[[\"COUNT2\",2],[\"SIDE2\",EAST],[\"UNIT2\",\"*Tank_F\"],[\"PLACE2\",[[<null>,<null>],4.34565,<null>]],[\"TIME2\",[-1,-1]],[\"UCOUNT2\",2],[\"UTYPE2\",\"*O_MBT_02_cannon_F\"]]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targets","targetsQuery","nearTargets","targetKnowledge","knowsAbout","reveal","forgetTarget","setTargetAge","getHideFrom"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"targetsQuery","operator":null,"title":"targetsQuery","type":"command","url":"https://community.bistudio.com/wiki/targetsQuery","revid":377711,"updated":"2026-01-02T09:03:51Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns sorted array of targets, **known** to the enquirer (including own troops), where the accuracy coefficient reflects how close the result matches the query. This command could be CPU intensive.","syntaxes":[{"syntax":"enquirer targetsQuery [targetIgnore, targetSide, targetType, targetPosition, targetMaxAge]","since":null,"effect":null,"exec":null,"params":[{"name":"enquirer","type":"Object","optional":false,"default":null,"description":"for whom the query will be made","types":["Object"],"since":null,"text":"enquirer: Object - for whom the query will be made"},{"name":"targetIgnore","type":"Object","optional":false,"default":null,"description":"target object to exclude from results. objNull - return every target","types":["Object"],"since":null,"text":"targetIgnore: Object - target object to exclude from results. objNull - return every target"},{"name":"targetSide","type":"Side","optional":false,"default":null,"description":"desired side of the target. sideUnknown - any side","types":["Side"],"since":null,"text":"targetSide: Side - desired side of the target. sideUnknown - any side"},{"name":"targetType","type":"String","optional":false,"default":null,"description":"desired target typeOf. \"\" - any type","types":["String"],"since":null,"text":"targetType: String - desired target typeOf. \"\" - any type"},{"name":"targetPosition","type":"Position2D or Position3D","optional":false,"default":null,"description":"desired target position (only [x,y] is considered). Position tolerance is 200m from the actual position of the target. [] - any position","types":["Position2D","Position3D"],"since":null,"text":"targetPosition: Position2D or Position3D - desired target position (only [x,y] is considered). Position tolerance is 200m from the actual position of the target. [] - any position"},{"name":"targetMaxAge","type":"Number","optional":false,"default":null,"description":"desired max age of the target. This will limit returned results to the targets younger than specified age. 0 - any age","types":["Number"],"since":null,"text":"targetMaxAge: Number - desired max age of the target. This will limit returned results to the targets younger than specified age. 0 - any age"}],"returns":{"type":"Array of Arrays with [accuracy, target, targetSide, targetType, targetPosition, targetAge]","types":["Array"],"description":"accuracy: Number in range 0..1 - a coefficient, which reflects how close the returned result to the query filter. (1 - best match) - target: Object - the actual target object - targetSide: Side - side of the target - targetType: String - target typeOf - targetPosition: Array - [x,y] of the target - targetAge: Number - the actual target age in seconds (can be negative)","text":"Array of Arrays with [accuracy, target, targetSide, targetType, targetPosition, targetAge]\n- accuracy: Number in range 0..1 - a coefficient, which reflects how close the returned result to the query filter. (1 - best match)\n- target: Object - the actual target object\n- targetSide: Side - side of the target\n- targetType: String - target typeOf\n- targetPosition: Array - [x,y] of the target\n- targetAge: Number - the actual target age in seconds (can be negative)"},"form":"binary","operator":null,"left":{"text":"enquirer","types":["Object"]},"right":{"text":"[targetIgnore, targetSide, targetType, targetPosition, targetMaxAge]","types":["Array"]}}],"examples":[{"text":"Return all known targets for player:\n\n```sqf\n_targets = player targetsQuery [objNull, sideUnknown, \"\", [], 0];\n```","code":["_targets = player targetsQuery [objNull, sideUnknown, \"\", [], 0];"]},{"text":"Prioritise all known OPFOR targets and return targets less than 10 seconds old:\n\n```sqf\n_targets = player targetsQuery [objNull, east, \"\", [], 10];\n```","code":["_targets = player targetsQuery [objNull, east, \"\", [], 10];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["targets","nearTargets","targetsAggregate","targetKnowledge","knowsAbout","reveal","forgetTarget","setTargetAge","getHideFrom"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskAlwaysVisible","operator":null,"title":"taskAlwaysVisible","type":"command","url":"https://community.bistudio.com/wiki/taskAlwaysVisible","revid":339143,"updated":"2023-04-26T10:55:03Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the task is flagged to be always visible or false if not.","syntaxes":[{"syntax":"taskAlwaysVisible task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_isAlwaysVisible = taskAlwaysVisible (currentTask player);\n```","code":["_isAlwaysVisible = taskAlwaysVisible (currentTask player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSimpleTaskAlwaysVisible","taskType","BIS_fnc_taskSetAlwaysVisible","BIS_fnc_taskAlwaysVisible","Arma 3: Task Framework"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"taskChildren","operator":null,"title":"taskChildren","type":"command","url":"https://community.bistudio.com/wiki/taskChildren","revid":377724,"updated":"2026-01-02T09:28:47Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the child tasks of the specified task.","syntaxes":[{"syntax":"taskChildren task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Array of Tasks","types":["Array","Task"],"description":null,"text":"Array of Tasks"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_children = taskChildren someTask;\n```","code":["_children = taskChildren someTask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_taskCreate","BIS_fnc_taskCurrent","BIS_fnc_taskExists","BIS_fnc_taskParent","BIS_fnc_taskType","BIS_fnc_taskTypeIcon","BIS_fnc_taskVar","Arma 3: Task Framework"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskCompleted","operator":null,"title":"taskCompleted","type":"command","url":"https://community.bistudio.com/wiki/taskCompleted","revid":376412,"updated":"2025-10-11T01:03:52Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return if task is completed. (state Succeeded, Failed or Canceled)","syntaxes":[{"syntax":"taskCompleted task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if task has been Succeeded, Failed or Canceled","text":"Boolean - true if task has been Succeeded, Failed or Canceled"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_task = player createSimpleTask [\"task_1\"];\n_done = taskCompleted _task;\n```","code":["_task = player createSimpleTask [\"task_1\"];\n_done = taskCompleted _task;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_deleteTask","BIS_fnc_setTask","BIS_fnc_setTaskLocal","BIS_fnc_sharedObjectives","BIS_fnc_taskAlwaysVisible","BIS_fnc_taskCompleted","BIS_fnc_taskCreate","BIS_fnc_taskCurrent","BIS_fnc_taskDescription","BIS_fnc_taskDestination","BIS_fnc_taskExists","BIS_fnc_taskHint","BIS_fnc_taskParent","BIS_fnc_taskReal","BIS_fnc_taskSetAlwaysVisible","BIS_fnc_taskSetCurrent","BIS_fnc_taskSetDescription","BIS_fnc_taskSetDestination","BIS_fnc_taskSetState","BIS_fnc_taskSetType","BIS_fnc_taskState","BIS_fnc_tasksUnit","BIS_fnc_taskType","BIS_fnc_taskTypeIcon","BIS_fnc_taskVar","Arma 3: Task Framework"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskCustomData","operator":null,"title":"taskCustomData","type":"command","url":"https://community.bistudio.com/wiki/taskCustomData","revid":376365,"updated":"2025-10-07T21:46:44Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns custom data attached to the local task or an empty array if there are no custom data attached.","syntaxes":[{"syntax":"taskCustomData task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Array of string","types":["Array"],"description":"iconPath, iconText, descriptionText","text":"Array of string - iconPath, iconText, descriptionText"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_data = taskCustomData someTask;\n```","code":["_data = taskCustomData someTask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSimpleTaskCustomData","setSimpleTaskType","taskType","Arma 3: Task Framework"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"taskDescription","operator":null,"title":"taskDescription","type":"command","url":"https://community.bistudio.com/wiki/taskDescription","revid":378417,"updated":"2026-04-04T08:44:52Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the sub-parts of the task description.","syntaxes":[{"syntax":"taskDescription task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Array with [description, title, waypoint]","types":["Array"],"description":"description: String - title: String - waypoint: Waypoint","text":"Array with [description, title, waypoint]\n- description: String\n- title: String\n- waypoint: Waypoint"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_taskDescArray = taskDescription _task;\n```","code":["_taskDescArray = taskDescription _task;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSimpleTaskDescription","createSimpleTask"],"notes":[{"user":"Tajin","date":"2014-11-14T19:48:00Z","text":"Be careful if you want to use this to retrieve the title of a task.\nIf the task has no description set, then \"taskDescription\" will only return an array of empty Strings.\n\nTherefore always use setSimpleTaskDescription directly after creating a new task, even if you set the Description to \"\"."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskDestination","operator":null,"title":"taskDestination","type":"command","url":"https://community.bistudio.com/wiki/taskDestination","revid":349537,"updated":"2023-11-08T17:18:22Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the position of the task (as specified by destination parameter in config).","syntaxes":[{"syntax":"taskDestination task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Array (A3 1.28 Returns Nothing if identity is taskNull)","types":["Array","Nothing","taskNull"],"description":null,"text":"Array (A3 1.28 Returns Nothing if identity is taskNull)"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\nif (!isNull currentTask player) then { hint str taskDestination currentTask player };\n```","code":["if (!isNull currentTask player) then { hint str taskDestination currentTask player };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cancelSimpleTaskDestination","setSimpleTaskDestination"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskHint","operator":null,"title":"taskHint","type":"command","url":"https://community.bistudio.com/wiki/taskHint","revid":377725,"updated":"2026-01-02T09:36:56Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Shows info about new, changed or failed task. The text can contain several lines. `\\n` is used to set a line return.\n\n> [!NOTE]\n> **Arma 3:** It is recommended to use BIS_fnc_showNotification in order to maintain Arma 3's visual style.","syntaxes":[{"syntax":"taskHint [text, color, icon]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"},{"name":"icon","type":"String","optional":false,"default":null,"description":"one of:\n- \"taskNew\"\n- \"taskCurrent\"\n- \"taskDone\"\n- \"taskFailed\"","types":["String"],"since":null,"text":"icon: String - one of:\n- \"taskNew\"\n- \"taskCurrent\"\n- \"taskDone\"\n- \"taskFailed\""}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, color, icon]","types":["Array"]}}],"examples":[{"text":"```sqf\ntaskHint [\"Task failed.\\nBad job!\", [1, 0, 0, 1], \"taskFailed\"];\n```","code":["taskHint [\"Task failed.\\nBad job!\", [1, 0, 0, 1], \"taskFailed\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_showNotification","Task"],"notes":[{"user":"Kylania","date":"2011-07-15T03:37:00Z","text":"Here are the BIS colors:\n\n```sqf\ntaskHint [\"New Task!\\nHere's your new task!\",    [1, 1, 1, 1],                    \"taskNew\"];\ntaskHint [\"Task Assigned!\\nDo this now!\",        [1, 1, 1, 1],                    \"taskCurrent\"];\ntaskHint [\"Task Succeeded!\\nGood job!\",            [0.60,0.839215,0.466666,1],        \"taskDone\"];\ntaskHint [\"Task Failed!\\nBad job!\",                [0.972549,0.121568,0,1],        \"taskFailed\"];\ntaskHint [\"Task Canceled!\\nNever mind!\",        [0.75,0.75,0.75,1],                \"taskFailed\"];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"taskMarkerOffset","operator":null,"title":"taskMarkerOffset","type":"command","url":"https://community.bistudio.com/wiki/taskMarkerOffset","revid":319857,"updated":"2022-05-13T09:25:36Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns model space position for the task marker","syntaxes":[{"syntax":"taskMarkerOffset unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array","types":["Array"],"description":"offset in format [x, y, z]","text":"Array - offset in format [x, y, z]"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_offset = taskMarkerOffset player;\n```","code":["_offset = taskMarkerOffset player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTaskMarkerOffset"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"taskName","operator":null,"title":"taskName","type":"command","url":"https://community.bistudio.com/wiki/taskName","revid":310323,"updated":"2022-05-05T16:32:29Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the name of the given task.","syntaxes":[{"syntax":"taskName task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"String","types":["String"],"description":"task name","text":"String - task name"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\nprivate _taskName = taskName _mytask;\n```","code":["private _taskName = taskName _mytask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskType","createSimpleTask"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"taskNull","operator":null,"title":"taskNull","type":"command","url":"https://community.bistudio.com/wiki/taskNull","revid":369300,"updated":"2024-09-03T18:42:52Z","groups":["Briefing","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existing Task. To compare non-existent tasks use isNull or isEqualTo:\n\n```sqf\ntaskNull == taskNull;            // false\nisNull taskNull;                // true\ntaskNull isEqualTo taskNull;    // true\n```","syntaxes":[{"syntax":"taskNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Task","types":["Task"],"description":null,"text":"Task"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n!isNull taskNull; // false\n```","code":["!isNull taskNull; // false"]},{"text":"```sqf\nstr taskNull; // no task\n```","code":["str taskNull; // no task"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["controlNull","displayNull","grpNull","locationNull","objNull","teamMemberNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskParent","operator":null,"title":"taskParent","type":"command","url":"https://community.bistudio.com/wiki/taskParent","revid":376362,"updated":"2025-10-07T21:43:45Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the parent task of the specified task.","syntaxes":[{"syntax":"taskParent task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Task","types":["Task"],"description":null,"text":"Task"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_parent = taskParent someTask;\n```","code":["_parent = taskParent someTask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["taskChildren"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskResult","operator":null,"title":"taskResult","type":"command","url":"https://community.bistudio.com/wiki/taskResult","revid":319905,"updated":"2022-05-13T09:25:42Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Send a result of the task to the task sender.","syntaxes":[{"syntax":"taskResult task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"Array","types":["Array"],"description":"format [state, result] (see setTaskResult)","text":"Array - format [state, result] (see setTaskResult)"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\ntaskResult (player createSimpleTask [\"NewTask\"]);\n```","code":["taskResult (player createSimpleTask [\"NewTask\"]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTaskResult"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskState","operator":null,"title":"taskState","type":"command","url":"https://community.bistudio.com/wiki/taskState","revid":320998,"updated":"2022-05-13T10:30:31Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current state of a task.","syntaxes":[{"syntax":"taskState task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":"the task you want to query","types":["Task"],"since":null,"text":"task: Task - the task you want to query"}],"returns":{"type":"String","types":["String"],"description":"current state of task - can be one of: - \"None\" - \"Created\" - \"Assigned\" - \"Succeeded\" - \"Failed\" - \"Canceled\"","text":"String - current state of task - can be one of:\n- \"None\"\n- \"Created\"\n- \"Assigned\"\n- \"Succeeded\"\n- \"Failed\"\n- \"Canceled\""},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\ntskSomeTask = player createSimpleTask [\"NewTask\"];\nhint format[\"Taskstate: %1\", taskState tskSomeTask];\n```","code":["tskSomeTask = player createSimpleTask [\"NewTask\"];\nhint format[\"Taskstate: %1\", taskState tskSomeTask];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Tasks","createSimpleTask","removeSimpleTask","setSimpleTaskDescription","setSimpleTaskDestination","setTaskResult","setTaskState"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"taskType","operator":null,"title":"taskType","type":"command","url":"https://community.bistudio.com/wiki/taskType","revid":339088,"updated":"2023-04-26T10:54:07Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the type of the given task. A new task returns \"Default\" for the type.","syntaxes":[{"syntax":"taskType task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_type = taskType (currentTask player);\n```","code":["_type = taskType (currentTask player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setSimpleTaskType","taskName","currentTask","setSimpleTaskCustomData","taskCustomData","Arma 3: Task Framework"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"teamMember","operator":null,"title":"teamMember","type":"command","url":"https://community.bistudio.com/wiki/teamMember","revid":320997,"updated":"2022-05-13T10:29:17Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return an agent for given person.","syntaxes":[{"syntax":"teamMember person","since":null,"effect":null,"exec":null,"params":[{"name":"person","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"person: Object"}],"returns":{"type":"Team Member","types":["Team Member"],"description":null,"text":"Team Member"},"form":"unary","operator":null,"left":null,"right":{"text":"person","types":["Object"]}}],"examples":[{"text":"```sqf\n_agent = teamMember player;\n```","code":["_agent = teamMember player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamName","teams","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teamMemberNull","operator":null,"title":"teamMemberNull","type":"command","url":"https://community.bistudio.com/wiki/teamMemberNull","revid":330231,"updated":"2022-08-27T14:58:59Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A non-existent Team Member. To compare non-existent team members use isNull or isEqualTo:\n\n```sqf\nteamMemberNull == teamMemberNull;            // false\nisNull teamMemberNull;                        // true\nteamMemberNull isEqualTo teamMemberNull;    // true\n```","syntaxes":[{"syntax":"teamMemberNull","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Team Member","types":["Team Member"],"description":null,"text":"Team Member"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n!isNull teamMemberNull; // false\n```","code":["!isNull teamMemberNull; // false"]},{"text":"```sqf\nstr teamMemberNull; // <NULL - team member>\n```","code":["str teamMemberNull; // <NULL - team member>"]},{"text":"```sqf\nif (_teamMember isEqualTo teamMemberNull) then\n{\n    hint \"team member is null\";\n};\n```","code":["if (_teamMember isEqualTo teamMemberNull) then\n{\n\thint \"team member is null\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","teamType","controlNull","displayNull","grpNull","locationNull","objNull","taskNull","scriptNull","configNull","typeName","isNull"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teamName","operator":null,"title":"teamName","type":"command","url":"https://community.bistudio.com/wiki/teamName","revid":310870,"updated":"2022-05-07T20:24:10Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a name of given team.","syntaxes":[{"syntax":"teamName team","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"team","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_name = teamName _team;\n```","code":["_name = teamName _team;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teams","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teams","operator":null,"title":"teams","type":"command","url":"https://community.bistudio.com/wiki/teams","revid":377122,"updated":"2026-01-01T10:19:31Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return a list of teams in the current mission.","syntaxes":[{"syntax":"teams","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Team Members","types":["Array","Team Member"],"description":null,"text":"Array of Team Members"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_teams = teams;\n```","code":["_teams = teams;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["agents","addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teamType","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teamSwitch","operator":null,"title":"teamSwitch","type":"command","url":"https://community.bistudio.com/wiki/teamSwitch","revid":351299,"updated":"2023-11-27T03:59:30Z","groups":["Team Switch"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Invoke the Team Switch dialog (force it even when conditions are not met).\nThere has to be at least one playable unit for team switch to work, and for this command to work in MP, respawn type in description.ext should be 5 (SIDE).\n\n> [!NOTE]\n> When player switches and leaves behind AI unit, you need to enable \"TeamSwitch\" AI on it `_unit enableAI \"TeamSwitch\"` so that the unit continues with waypoints.","syntaxes":[{"syntax":"teamSwitch","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nteamSwitch;\n```","code":["teamSwitch;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Team Switch","enableTeamSwitch","onBriefingTeamSwitch","onTeamSwitch","teamSwitchEnabled","selectPlayer"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teamSwitchEnabled","operator":null,"title":"teamSwitchEnabled","type":"command","url":"https://community.bistudio.com/wiki/teamSwitchEnabled","revid":351297,"updated":"2023-11-27T03:58:49Z","groups":["Team Switch"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if Team Switch is currently enabled.\nTeam Switch is enabled by default.","syntaxes":[{"syntax":"teamSwitchEnabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_isTeamSwitchEnabled = teamSwitchEnabled;\n```","code":["_isTeamSwitchEnabled = teamSwitchEnabled;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Team Switch","enableTeamSwitch","onBriefingTeamSwitch","onTeamSwitch","teamSwitch"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Team Switch","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"teamType","operator":null,"title":"teamType","type":"command","url":"https://community.bistudio.com/wiki/teamType","revid":320996,"updated":"2022-05-13T10:29:03Z","groups":["Teams"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a type of given team.","syntaxes":[{"syntax":"teamType team","since":null,"effect":null,"exec":null,"params":[{"name":"team","type":"Team Member","optional":false,"default":null,"description":null,"types":["Team Member"],"since":null,"text":"team: Team Member"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"team","types":["Team Member"]}}],"examples":[{"text":"```sqf\n_type = teamType _team;\n```","code":["_type = teamType _team;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addTeamMember","createTeam","deleteTeam","forEachMemberTeam","removeTeamMember","teamMember","teamName","teams","forEachMember","forEachMemberAgent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Teams","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"terminate","operator":null,"title":"terminate","type":"command","url":"https://community.bistudio.com/wiki/terminate","revid":376945,"updated":"2025-12-31T22:54:37Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Terminates (aborts) spawned or execVMed script.\n\n> [!IMPORTANT]\n> The given script will not terminate immediately upon terminate command execution, it will do so the next time the script is processed by the scheduler","syntaxes":[{"syntax":"terminate scriptHandle","since":null,"effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":null,"types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"scriptHandle","types":["Script Handle"]}},{"syntax":"terminate FSMHandle","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"FSMHandle","type":"Number","optional":false,"default":null,"description":"The FSM script must be launched with 'allowTermination' flag for this command to work (see execFSM).","types":["Number"],"since":null,"text":"FSMHandle: Number - The FSM script must be launched with 'allowTermination' flag for this command to work (see execFSM)."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"FSMHandle","types":["Number"]}},{"syntax":"scriptHandle terminate result","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":"Only \"Empty Handle\"'s can have their result set.","types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle - Only \"Empty Handle\"'s can have their result set."},{"name":"result","type":"Anything","optional":false,"default":null,"description":"The result to write into the Promise","types":["Anything"],"since":null,"text":"result: Anything - The result to write into the Promise"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"scriptHandle","types":["Script Handle"]},"right":{"text":"result","types":["Anything"]}}],"examples":[{"text":"```sqf\n_script = [] execVM \"script.sqf\";\nsleep 5;\nterminate _script;\n```","code":["_script = [] execVM \"script.sqf\";\nsleep 5;\nterminate _script;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["execVM","spawn","scriptDone","halt","execFSM"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"terrainIntersect","operator":null,"title":"terrainIntersect","type":"command","url":"https://community.bistudio.com/wiki/terrainIntersect","revid":377407,"updated":"2026-01-02T06:45:07Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks for intersection of terrain between two AGL positions. Returns true if intersects with terrain. For ASL variant see terrainIntersectASL.","syntaxes":[{"syntax":"terrainIntersect [start, end]","since":null,"effect":null,"exec":null,"params":[{"name":"start","type":"PositionAGL","optional":false,"default":null,"description":"start position","types":["PositionAGL"],"since":null,"text":"start: PositionAGL - start position"},{"name":"end","type":"PositionAGL","optional":false,"default":null,"description":"end position","types":["PositionAGL"],"since":null,"text":"end: PositionAGL - end position"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[start, end]","types":["Array"]}}],"examples":[{"text":"```sqf\n_intersects = terrainIntersect [getPos player, getPos chopper];\n```","code":["_intersects = terrainIntersect [getPos player, getPos chopper];"]},{"text":"```sqf\n_intersects = terrainIntersect [position player, position enemy1];\n```","code":["_intersects = terrainIntersect [position player, position enemy1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["terrainIntersectAtASL","lineIntersectsSurfaces","intersect","lineIntersects","lineIntersectsWith","terrainIntersectASL","lineIntersectsObjs","checkVisibility"],"notes":[{"user":"Lou Montana","date":"2012-05-31T10:40:00Z","text":"Please note the difference:\n- terrainIntersect\n- terrainIntersectASL\n- lineIntersect***s***\n- lineIntersect***s***With\n- lineIntersect***s***Objs\n- intersect"},{"user":"Rocket","date":"2012-06-01T15:55:00Z","text":"This command is CPU intensive on the engine, be careful with its use."},{"user":"Dwarden","date":"2012-06-23T17:15:00Z","text":"This command was changed to ATL and counterpart for ASL was added in build 94049."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"terrainIntersectASL","operator":null,"title":"terrainIntersectASL","type":"command","url":"https://community.bistudio.com/wiki/terrainIntersectASL","revid":377458,"updated":"2026-01-02T06:47:25Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks for intersection of terrain between two ASL positions. Returns true if intersects with terrain.\nFor AGL variant, see terrainIntersect.","syntaxes":[{"syntax":"terrainIntersectASL [start, end]","since":null,"effect":null,"exec":null,"params":[{"name":"start","type":"PositionASL","optional":false,"default":null,"description":"start position","types":["PositionASL"],"since":null,"text":"start: PositionASL - start position"},{"name":"end","type":"PositionASL","optional":false,"default":null,"description":"end position","types":["PositionASL"],"since":null,"text":"end: PositionASL - end position"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"[start, end]","types":["Array"]}}],"examples":[{"text":"```sqf\n_intersects = terrainIntersectASL [getPosASL player, getPosASL chopper];\n```","code":["_intersects = terrainIntersectASL [getPosASL player, getPosASL chopper];"]},{"text":"```sqf\n_intersects = terrainIntersectASL [eyePos player, eyePos enemy1];\n```","code":["_intersects = terrainIntersectASL [eyePos player, eyePos enemy1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["terrainIntersectAtASL","lineIntersectsSurfaces","intersect","lineIntersects","lineIntersectsWith","terrainIntersect","lineIntersectsObjs","checkVisibility"],"notes":[{"user":"Lou Montana","date":"2012-05-31T10:40:00Z","text":"Please note the difference:\n- terrainIntersect\n- terrainIntersectASL\n- lineIntersect***s***\n- lineIntersect***s***With\n- lineIntersect***s***Objs\n- intersect"},{"user":"Rocket","date":"2012-06-01T15:55:00Z","text":"This command is CPU intensive on the engine, be careful with its use."},{"user":"bloodwyn1756","date":"2019-03-02T20:29:00Z","text":"If one of the two positions is below sea level, the command always returns true."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"terrainIntersectAtASL","operator":null,"title":"terrainIntersectAtASL","type":"command","url":"https://community.bistudio.com/wiki/terrainIntersectAtASL","revid":377440,"updated":"2026-01-02T06:46:49Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks for intersection of terrain between two ASL positions. Same as terrainIntersectASL but returns the intersection ASL position.","syntaxes":[{"syntax":"terrainIntersectAtASL [start, end]","since":null,"effect":null,"exec":null,"params":[{"name":"start","type":"PositionASL","optional":false,"default":null,"description":"start position","types":["PositionASL"],"since":null,"text":"start: PositionASL - start position"},{"name":"end","type":"PositionASL","optional":false,"default":null,"description":"end position","types":["PositionASL"],"since":null,"text":"end: PositionASL - end position"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":"intersect position","text":"PositionASL - intersect position"},"form":"unary","operator":null,"left":null,"right":{"text":"[start, end]","types":["Array"]}}],"examples":[{"text":"```sqf\n_posASL = terrainIntersectAtASL [eyePos player, getPosASL chopper];\n```","code":["_posASL = terrainIntersectAtASL [eyePos player, getPosASL chopper];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["terrainIntersectASL","lineIntersectsSurfaces","intersect","lineIntersects","lineIntersectsWith","terrainIntersect","lineIntersectsObjs","checkVisibility"],"notes":[{"user":"POLPOX","date":"2023-12-10T08:55:23Z","text":"This command will tell you that it finds an intersect if either of argument position is under the sea eg `[0,0,-10]` even if there is no clear intersection with a terrain surface between them."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"text","operator":null,"title":"text","type":"command","url":"https://community.bistudio.com/wiki/text","revid":320624,"updated":"2022-05-13T09:38:21Z","groups":["Locations","Strings","Structured Text"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a structured text containing the given plain text if argument is String. Use setAttributes to set additional attributes on the text. If the argument is location, returns location's text value (see Alt Syntax).","syntaxes":[{"syntax":"text string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"}],"returns":{"type":"Structured Text","types":["Structured Text"],"description":null,"text":"Structured Text"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}},{"syntax":"text location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}}],"examples":[{"text":"```sqf\n_stxt2 = text \"Hello world.\";\n```","code":["_stxt2 = text \"Hello world.\";"]},{"text":"```sqf\n_townName = text myTownLocation;\n```","code":["_townName = text myTownLocation;"]},{"text":"```sqf\n_loc = text nearestLocation [position player, \"NameMarine\"]; //\"Marina Bay\"\n```","code":["_loc = text nearestLocation [position player, \"NameMarine\"]; //\"Marina Bay\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["parseText","composeText","image","lineBreak","setText","createLocation","deleteLocation","drawLocation","locationPosition","locationNull","nearestLocation","nearestLocations","nearestLocationWithDubbing","name"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Locations","Command Group: Strings","Command Group: Structured Text","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"textLog","operator":null,"title":"textLog","type":"command","url":"https://community.bistudio.com/wiki/textLog","revid":352200,"updated":"2024-02-01T23:26:02Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dump argument value to debugging output.\n\n> [!WARNING]\n> This command is non-functional in the retail version","syntaxes":[{"syntax":"textLog anything","since":null,"effect":null,"exec":null,"params":[{"name":"anything","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"anything: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"anything","types":["Anything"]}}],"examples":[{"text":"```sqf\ntextLog player;\n```","code":["textLog player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"textLogFormat","operator":null,"title":"textLogFormat","type":"command","url":"https://community.bistudio.com/wiki/textLogFormat","revid":363577,"updated":"2024-04-07T14:40:20Z","groups":["Broken Commands"],"status":"broken","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Debugging output.\n\n> [!WARNING]\n> This command is non-functional in the retail version","syntaxes":[{"syntax":"textLogFormat [format, arg1, arg2, argN]","since":null,"effect":null,"exec":null,"params":[{"name":"format","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"format: String"},{"name":"arg1","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"arg1: Anything"},{"name":"arg2","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"arg2: Anything"},{"name":"argN","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"argN: Anything"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[format, arg1, arg2, argN]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["diag_log","BIS_fnc_log","BIS_fnc_logFormat"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"tg","operator":null,"title":"tg","type":"command","url":"https://community.bistudio.com/wiki/tg","revid":319798,"updated":"2022-05-13T09:25:29Z","groups":["Math - Geometry"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Identical to tan","syntaxes":[{"syntax":"tg x","since":null,"effect":null,"exec":null,"params":[{"name":"x","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"x: Number"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"x","types":["Number"]}}],"examples":[{"text":"```sqf\n_tangent = tg 45; // Result is 1\n```","code":["_tangent = tg 45; // Result is 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tan","sin","cos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Geometry","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"then","operator":null,"title":"then","type":"command","url":"https://community.bistudio.com/wiki/then","revid":351752,"updated":"2024-01-03T10:15:29Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Links an If Type with Code to be executed if said If Type's condition is true; otherwise, \"else\" code is executed if provided.\n\nThe alternative syntax allows to set \"then\" code and \"else\" code in one array.\n\n> [!NOTE]\n> Variables declared inside *thenCode* are private to that code block - see Variables#Local Variables Scope.","syntaxes":[{"syntax":"ifType then thenCode","since":null,"effect":null,"exec":null,"params":[{"name":"ifType","type":"If Type","optional":false,"default":null,"description":null,"types":["If Type"],"since":null,"text":"ifType: If Type"},{"name":"thenCode","type":"Code or Array of Code:","optional":false,"default":null,"description":"Code or Array of Code:\n- Code - code block to execute if *ifType*'s condition is true\n- Array of Code - array of two Code elements in format [thenCode, elseCode]; see #Example 3","types":["Code","Array"],"since":null,"text":"thenCode: Code or Array of Code:\n- Code - code block to execute if *ifType*'s condition is true\n- Array of Code - array of two Code elements in format [thenCode, elseCode]; see #Example 3"}],"returns":{"type":"Anything","types":["Anything"],"description":"result of the executed code","text":"Anything - result of the executed code"},"form":"binary","operator":null,"left":{"text":"ifType","types":["If Type"]},"right":{"text":"thenCode","types":["Code","Array"]}}],"examples":[{"text":"```sqf\nif (a > b) then { hint \"a is greater than b!\"; };\n```","code":["if (a > b) then { hint \"a is greater than b!\"; };"]},{"text":"```sqf\nprivate _c = 0;\nif (_a > _b) then\n{\n    _c = 1;\n}\nelse\n{\n    _c = 2;\n};\n```","code":["private _c = 0;\nif (_a > _b) then\n{\n\t_c = 1;\n}\nelse\n{\n\t_c = 2;\n};"]},{"text":"```sqf\nif (alive player) then [{ hint \"player is alive\"; }, { hint \"player is dead\"; }];\n```","code":["if (alive player) then [{ hint \"player is alive\"; }, { hint \"player is dead\"; }];"]},{"text":"```sqf\nprivate _value = if (alive player) then { 1 } else { 0 };\n```","code":["private _value = if (alive player) then { 1 } else { 0 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","if","else"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"throw","operator":null,"title":"throw","type":"command","url":"https://community.bistudio.com/wiki/throw","revid":377911,"updated":"2026-01-07T16:33:15Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Throws an exception. The exception is processed by first catch block. This command will terminate further execution of the code.\n\n> [!IMPORTANT]\n> Avoid using alternative shorthand syntax if you are planning on preparing your exception information dynamically, as it will have to be generated first regardless of the condition of the if statement before it, as shown in #Example 3.","syntaxes":[{"syntax":"throw exception","since":null,"effect":null,"exec":null,"params":[{"name":"exception","type":"Anything","optional":false,"default":null,"description":"value that is put into the `_exception` variable inside catch block","types":["Anything"],"since":null,"text":"exception: Anything - value that is put into the `_exception` variable inside catch block"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"exception","types":["Anything"]}},{"syntax":"ifType throw exception","since":"arma3 1.54","effect":null,"exec":null,"params":[{"name":"ifType","type":"If Type","optional":false,"default":null,"description":"if the condition returns true, *exception* is thrown","types":["If Type"],"since":null,"text":"ifType: If Type - if the condition returns true, *exception* is thrown"},{"name":"exception","type":"Anything","optional":false,"default":null,"description":"value that is put into the `_exception` variable inside catch block","types":["Anything"],"since":null,"text":"exception: Anything - value that is put into the `_exception` variable inside catch block"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ifType","types":["If Type"]},"right":{"text":"exception","types":["Anything"]}}],"examples":[{"text":"```sqf\ntry { throw \"invalid argument\" } catch { hint str _exception };\n```","code":["try { throw \"invalid argument\" } catch { hint str _exception };"]},{"text":"```sqf\n123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };\n```","code":["123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };"]},{"text":"The correct usage of shorthand alt syntax:\n\n```sqf\ntry\n{\n    if (a > b)\n        throw \"Error: some error\";                // OK - the command argument is static\n}\ncatch\n{\n    hint str _exception;\n};\n```\n\n```sqf\ntry\n{\n    if (a > b)\n        throw (call _someFunc);                    // NOT OK - the command argument is dynamic\n        // _someFunc is called first to get the value regardless of (a > b) outcome\n}\ncatch\n{\n    hint str _exception;\n};\n```\n\n```sqf\ntry\n{\n    if (a > b) then { throw (call _someFunc) };    // OK - the command argument is dynamic\n    // _someFunc is only called when (a > b) is true\n}\ncatch\n{\n    hint str _exception;\n};\n```","code":["try\n{\n\tif (a > b)\n\t\tthrow \"Error: some error\";\t\t\t\t// OK - the command argument is static\n}\ncatch\n{\n\thint str _exception;\n};","try\n{\n\tif (a > b)\n\t\tthrow (call _someFunc);\t\t\t\t\t// NOT OK - the command argument is dynamic\n\t\t// _someFunc is called first to get the value regardless of (a > b) outcome\n}\ncatch\n{\n\thint str _exception;\n};","try\n{\n\tif (a > b) then { throw (call _someFunc) };\t// OK - the command argument is dynamic\n\t// _someFunc is only called when (a > b) is true\n}\ncatch\n{\n\thint str _exception;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Exception handling","try","catch"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"throwables","operator":null,"title":"throwables","type":"command","url":"https://community.bistudio.com/wiki/throwables","revid":377684,"updated":"2026-01-02T09:02:52Z","groups":["Weapons","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all throwables in unit inventory in currentThrowable format.","syntaxes":[{"syntax":"throwables unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Arrays with [magazineName, muzzleName, id, ammoCount]","types":["Array"],"description":"magazineName: String - muzzleName: String - id: Array with [itemWorldID, creatorID] - itemWorldID: Number - unique ID of the item in the world - creatorID: Number - unique ID of the player who created the item - ammoCount: Number magazine ammo (Since Arma 3 2.22)","text":"Array of Arrays with [magazineName, muzzleName, id, ammoCount]\n- magazineName: String\n- muzzleName: String\n- id: Array with [itemWorldID, creatorID]\n  - itemWorldID: Number - unique ID of the item in the world\n  - creatorID: Number - unique ID of the player who created the item\n- ammoCount: Number magazine ammo (Since Arma 3 2.22)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"throwables [unit, includeEmpty]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"includeEmpty","type":"Boolean","optional":true,"default":"false","description":"when true returns empty throwables as well.","types":["Boolean"],"since":null,"text":"includeEmpty: Boolean - (Optional, default: false) when true returns empty throwables as well."}],"returns":{"type":"Array of Arrays with [magazineName, muzzleName, id, ammoCount]","types":["Array"],"description":"magazineName: String - muzzleName: String - id: Array with [itemWorldID, creatorID] - itemWorldID: Number - unique ID of the item in the world - creatorID: Number - unique ID of the player who created the item - ammoCount: Number magazine ammo (Since Arma 3 2.22)","text":"Array of Arrays with [magazineName, muzzleName, id, ammoCount]\n- magazineName: String\n- muzzleName: String\n- id: Array with [itemWorldID, creatorID]\n  - itemWorldID: Number - unique ID of the item in the world\n  - creatorID: Number - unique ID of the player who created the item\n- ammoCount: Number magazine ammo (Since Arma 3 2.22)"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, includeEmpty]","types":["Array"]}}],"examples":[{"text":"```sqf\nthrowables player;\n/*\n    [\n        [\"HandGrenade\",\"HandGrenadeMuzzle\",[1e+007,0],1],\n        [\"SmokeShell\",\"SmokeShellMuzzle\",[1e+007,0],1],\n        [\"SmokeShellGreen\",\"SmokeShellGreenMuzzle\",[1e+007,0],1],\n        [\"Chemlight_green\",\"ChemlightGreenMuzzle\",[1e+007,0],1],\n        [\"Chemlight_green\",\"\",[1e+007,0],1],\n        [\"HandGrenade\",\"\",[1e+007,0],1]\n    ]\n*/\n```","code":["throwables player;\n/*\n\t[\n\t\t[\"HandGrenade\",\"HandGrenadeMuzzle\",[1e+007,0],1],\n\t\t[\"SmokeShell\",\"SmokeShellMuzzle\",[1e+007,0],1],\n\t\t[\"SmokeShellGreen\",\"SmokeShellGreenMuzzle\",[1e+007,0],1],\n\t\t[\"Chemlight_green\",\"ChemlightGreenMuzzle\",[1e+007,0],1],\n\t\t[\"Chemlight_green\",\"\",[1e+007,0],1],\n\t\t[\"HandGrenade\",\"\",[1e+007,0],1]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["selectThrowable","currentThrowable","isThrowable","selectWeapon","currentWeapon","currentMagazine","currentMuzzle","BIS_fnc_isThrowable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Weapons","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"time","operator":null,"title":"time","type":"command","url":"https://community.bistudio.com/wiki/time","revid":370500,"updated":"2024-12-26T17:48:11Z","groups":["Time","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns time elapsed since mission started (in seconds). The value is different on each client. If you need unified time, use serverTime. Unlike uiTime the time stops when game is paused.","syntaxes":[{"syntax":"time","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _future = time + 30;\nwaitUntil { time >= _future };  // continue after 30 seconds\n```","code":["private _future = time + 30;\nwaitUntil { time >= _future };  // continue after 30 seconds"]},{"text":"Wait until mission fully started:\n\n```sqf\nwaitUntil { time > 0 };\n```","code":["waitUntil { time > 0 };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uiTime","sleep","date","dayTime","serverTime","skipTime","accTime","dateToNumber","timeMultiplier","setTimeMultiplier","missionStart","diag_tickTime","diag_deltaTime","systemTime","systemTimeUTC","BIS_fnc_timeToString"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Time","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"timeMultiplier","operator":null,"title":"timeMultiplier","type":"command","url":"https://community.bistudio.com/wiki/timeMultiplier","revid":310775,"updated":"2022-05-07T20:21:45Z","groups":["Time","Mission Information","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the value set with setTimeMultiplier.","syntaxes":[{"syntax":"timeMultiplier","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"current time multiplier","text":"Number - current time multiplier"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_multiplier = timeMultiplier;\n```","code":["_multiplier = timeMultiplier;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTimeMultiplier","skipTime","setAccTime","accTime","time","serverTime","date","dayTime"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: Mission Information","Command Group: Time","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"titleCut","operator":null,"title":"titleCut","type":"command","url":"https://community.bistudio.com/wiki/titleCut","revid":319886,"updated":"2022-05-13T09:25:39Z","groups":["GUI Control"],"status":"deprecated","replaced_by":["cutText"],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Displays text on screen.\n\n> [!CAUTION]\n> This information is **obsolete**. cutText should be used instead.","syntaxes":[{"syntax":"titleCut [text, type, speed]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"text to be displayed on screen","types":["String"],"since":null,"text":"text: String - text to be displayed on screen"},{"name":"type","type":"String","optional":false,"default":null,"description":"can be one of Title Effect Types","types":["String"],"since":null,"text":"type: String - can be one of Title Effect Types"},{"name":"speed","type":"Number","optional":true,"default":"1","description":null,"types":["Number"],"since":null,"text":"speed: Number - (Optional, default 1)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, type, speed]","types":["Array"]}}],"examples":[{"text":"```sqf\ntitleCut [\"Hello, how are you?\",\"Plain Down\",3];\n```","code":["titleCut [\"Hello, how are you?\",\"Plain Down\",3];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["cutText"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"titleFadeOut","operator":null,"title":"titleFadeOut","type":"command","url":"https://community.bistudio.com/wiki/titleFadeOut","revid":369166,"updated":"2024-09-03T10:34:41Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Terminate the title effect and set duration of the fade out phase to the given time. Same as cutFadeOut but for the title layer.","syntaxes":[{"syntax":"titleFadeOut duration","since":null,"effect":null,"exec":null,"params":[{"name":"duration","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"duration: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"duration","types":["Number"]}}],"examples":[{"text":"```sqf\ntitleText [\"Hi\", \"plain\"];\ntitleFadeOut 2;\n```","code":["titleText [\"Hi\", \"plain\"];\ntitleFadeOut 2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["titleText","titleRsc","titleObj","cutFadeOut","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"titleObj","operator":null,"title":"titleObj","type":"command","url":"https://community.bistudio.com/wiki/titleObj","revid":363770,"updated":"2024-04-19T09:05:40Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Shows object defined in global config in CfgTitles","syntaxes":[{"syntax":"titleObj [class, type, speed, showInMap]","since":null,"effect":null,"exec":null,"params":[{"name":"class","type":"String","optional":false,"default":null,"description":"defined in `configFile >> \"CfgTitles\" >> class`","types":["String"],"since":null,"text":"class: String - defined in `configFile >> \"CfgTitles\" >> class`"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values"},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[class, type, speed, showInMap]","types":["Array"]}}],"examples":[{"text":"```sqf\ntitleObj [\"BISLogo\", \"PLAIN\"];\n```","code":["titleObj [\"BISLogo\", \"PLAIN\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["titleText","titleRsc","cutRsc","cutObj","cutText","allActiveTitleEffects","activeTitleEffectParams"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"titleRsc","operator":null,"title":"titleRsc","type":"command","url":"https://community.bistudio.com/wiki/titleRsc","revid":348002,"updated":"2023-11-08T10:24:40Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Displays a resource defined in RscTitles. Also see cutRsc, with these two commands you can show two different resources at once.\n\n> [!NOTE]\n> **Arma 3:** Arma 3 v1.58 Multiple layers and map overlays are possible with cutRsc which provides more options and handles layers better.","syntaxes":[{"syntax":"titleRsc [text, type, speed, showInMap]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"the class name of the resource. (\"Default\" will remove the current resource)","types":["String"],"since":null,"text":"text: String - the class name of the resource. (\"Default\" will remove the current resource)"},{"name":"type","type":"String","optional":false,"default":null,"description":"can be one of: \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\"; see Title Effect Types for more information about these values","types":["String"],"since":null,"text":"type: String - can be one of: \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\"; see Title Effect Types for more information about these values"},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, type, speed, showInMap]","types":["Array"]}}],"examples":[{"text":"```sqf\ntitleRsc [\"BIS\", \"PLAIN\"];\n```","code":["titleRsc [\"BIS\", \"PLAIN\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["titleText","titleObj","cutRsc","allActiveTitleEffects","activeTitleEffectParams"],"notes":[{"user":"Dr_Eyeball","date":"2008-06-30T08:44:00Z","text":"Using titleRsc (unlike cutRsc) for a HUD will mean:\n- the HUD will remain visible when you access the map and overlay it.\n- using the 'Direct communication' chat channel messages will interfere with the HUD by hiding it, since it appears to use the same 'resource layer'."},{"user":"Kenoxite","date":"2014-09-25T10:04:00Z","text":"In OFP/CWA any *<x>*Rsc will hide all the elements of the HUD, including the map."},{"user":"Honger","date":"2023-08-28T16:34:24Z","text":"The \"Default\" resource class does not exist in Arma 3 as of 2.12 version. Use a different class to remove resources that are not finite."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"titleText","operator":null,"title":"titleText","type":"command","url":"https://community.bistudio.com/wiki/titleText","revid":336846,"updated":"2023-01-04T16:43:44Z","groups":["GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Displays text across the screen. If used along with cutText two different texts (in different type styles) can be shown at once.\nThe text can be displayed on multiple lines by using \"\\n\" new line characters (see #Example 3).","syntaxes":[{"syntax":"titleText [text, type, speed, showInMap, isStructuredText]","since":null,"effect":null,"exec":null,"params":[{"name":"text","type":"String","optional":false,"default":null,"description":"text to be displayed","types":["String"],"since":null,"text":"text: String - text to be displayed"},{"name":"type","type":"String","optional":false,"default":null,"description":"one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values.","types":["String"],"since":null,"text":"type: String - one of \"PLAIN\", \"PLAIN DOWN\", \"BLACK\", \"BLACK FADED\", \"BLACK OUT\", \"BLACK IN\", \"WHITE OUT\" and \"WHITE IN\". See Title Effect Types for more information about these values."},{"name":"speed","type":"Number","optional":true,"default":"-1","description":"time in seconds to fade in resource","types":["Number"],"since":null,"text":"speed: Number - (Optional, default -1) time in seconds to fade in resource"},{"name":"showInMap","type":"Boolean","optional":true,"default":"true","description":"false to hide the text when the map is opened","types":["Boolean"],"since":null,"text":"showInMap: Boolean - (Optional, default true) false to hide the text when the map is opened"},{"name":"isStructuredText","type":"Boolean","optional":true,"default":"false","description":"true to switch support for Structured Text formatting - see #Example 4","types":["Boolean"],"since":"arma3 1.74","text":"isStructuredText: Boolean - (Optional, default false) true to switch support for Structured Text formatting - see #Example 4"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[text, type, speed, showInMap, isStructuredText]","types":["Array"]}}],"examples":[{"text":"```sqf\ntitleText [\"Show this text\", \"PLAIN\"];\n```","code":["titleText [\"Show this text\", \"PLAIN\"];"]},{"text":"```sqf\ntitleText [\"Your message\", \"BLACK\", 2];\n```","code":["titleText [\"Your message\", \"BLACK\", 2];"]},{"text":"```sqf\ntitleText [\"line1\\nline2\\nline3\", \"PLAIN\"];\n```","code":["titleText [\"line1\\nline2\\nline3\", \"PLAIN\"];"]},{"text":"```sqf\ntitleText [\"<t color='#ff0000' size='5'>RED ALERT!</t><br/>***********\", \"PLAIN\", -1, true, true];\n```","code":["titleText [\"<t color='#ff0000' size='5'>RED ALERT!</t><br/>***********\", \"PLAIN\", -1, true, true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["titleFadeOut","cutText","cutObj","allActiveTitleEffects","activeTitleEffectParams"],"notes":[{"user":"DreadedEntity","date":"2014-11-21T09:03:00Z","text":"The third parameter or 'speed', as it is called in the description, refers to the amount of time the message will be shown on-screen. Multiply each number by 10 to get the number of seconds it will be shown. You can even use floats as input, like 0.1, to show a message for only 1 second.\n\n**Note**: Calculating the time with that method does not include the time it takes to fade in/out, which is about 1 second unless you use numbers lower than 1.\n\n**Note**: Using anything lower than 0.001 seems to have no effect, or the effect is so little it is negligible.\n\n**(A3 1.34.128075)**"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"to","operator":null,"title":"to","type":"command","url":"https://community.bistudio.com/wiki/to","revid":311163,"updated":"2022-05-12T09:48:15Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Continue sequence of for construct. It sets the end value of the index variable.","syntaxes":[{"syntax":"forType to b","since":null,"effect":null,"exec":null,"params":[{"name":"forType","type":"For Type","optional":false,"default":null,"description":null,"types":["For Type"],"since":null,"text":"forType: For Type"},{"name":"b","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"b: Number"}],"returns":{"type":"For Type","types":["For Type"],"description":null,"text":"For Type"},"form":"binary","operator":null,"left":{"text":"forType","types":["For Type"]},"right":{"text":"b","types":["Number"]}}],"examples":[{"text":"```sqf\nfor \"_i\" from 10 to 20 do\n{\n    hint str _i; // will hint from 10 to 20, spaced by 1 second\n    sleep 1;\n};\n```","code":["for \"_i\" from 10 to 20 do\n{\n\thint str _i; // will hint from 10 to 20, spaced by 1 second\n\tsleep 1;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","for","from","step"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"toArray","operator":null,"title":"toArray","type":"command","url":"https://community.bistudio.com/wiki/toArray","revid":377121,"updated":"2026-01-01T10:18:13Z","groups":["Arrays","HashMap","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied String into an Array of Numbers. The numbers in the created array are the decimal [Unicode](https://en.wikipedia.org/wiki/Unicode) representations of characters.\n\n> [!NOTE]\n> **Arma 3:** Since v2.04 this command can also handle HashMaps. See alternative syntax.","syntaxes":[{"syntax":"toArray string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}},{"syntax":"toArray hashMap","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"}],"returns":{"type":"Array","types":["Array"],"description":"array in format [[key, key, ...], [value, value, ...]]","text":"Array - array in format [[key, key, ...], [value, value, ...]]"},"form":"unary","operator":null,"left":null,"right":{"text":"hashMap","types":["HashMap"]}},{"syntax":"hashMap toArray splitArrays","since":"arma3 2.04","effect":null,"exec":null,"params":[{"name":"hashMap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashMap: HashMap"},{"name":"splitArrays","type":"Boolean","optional":false,"default":null,"description":"see return value","types":["Boolean"],"since":null,"text":"splitArrays: Boolean - see return value"}],"returns":{"type":"Array","types":["Array"],"description":"array in either one of the following formats: - splitArrays: true - `[[key1, key2, ...], [value1, value2, ...]]` - splitArrays: false - `[[key1, value1], [key2, value2], ...]` This is very inefficient since the engine has to create many small arrays","text":"Array - array in either one of the following formats:\n- splitArrays: true - `[[key1, key2, ...], [value1, value2, ...]]`\n- splitArrays: false - `[[key1, value1], [key2, value2], ...]` This is **very inefficient** since the engine has to create many small arrays"},"form":"binary","operator":null,"left":{"text":"hashMap","types":["HashMap"]},"right":{"text":"splitArrays","types":["Boolean"]}}],"examples":[{"text":"```sqf\nhint format [\"%1\", toArray \"AaŒ\"];// Returns \"[65,97,338]\"\n```","code":["hint format [\"%1\", toArray \"AaŒ\"];// Returns \"[65,97,338]\""]},{"text":"```sqf\ntoArray _hashMap params [\"_keys\", \"_values\"];\n```","code":["toArray _hashMap params [\"_keys\", \"_values\"];"]},{"text":"```sqf\nprivate _hashmap = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [10000, 20000, 20000];\n_hashmap toArray true;    // returns [[\"cow\", \"cat\", \"chicken\"], [10000, 20000, 20000]] - same as Syntax 2\n_hashmap toArray false;    // returns [[\"cow\", 10000], [\"cat\", 20000], [\"chicken\", 20000]]\n```","code":["private _hashmap = [\"cow\", \"cat\", \"chicken\"] createHashMapFromArray [10000, 20000, 20000];\n_hashmap toArray true;\t// returns [[\"cow\", \"cat\", \"chicken\"], [10000, 20000, 20000]] - same as Syntax 2\n_hashmap toArray false;\t// returns [[\"cow\", 10000], [\"cat\", 20000], [\"chicken\", 20000]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["set","resize","reverse","select","in","find","toString","count","deleteAt","splitString","joinString","toUpperANSI"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: HashMap","Command Group: Strings","Introduced with Armed Assault version 1.09","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"toFixed","operator":null,"title":"toFixed","type":"command","url":"https://community.bistudio.com/wiki/toFixed","revid":369349,"updated":"2024-09-03T18:43:03Z","groups":["Math","Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts a number into a string, keeping the specified number of decimals. If the desired number of decimals is higher than the actual number, nulls are added to create the desired decimal length. This command is almost identical in behaviour to JavaScript [toFixed()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/toFixed)\n\nThe alternative syntax acts as keyword and switches engine's Number to String global conversion into desired format, from the moment it is applied until the end of script.\nTo reset output back to default at any time, use `toFixed -1` - see #Example 5.\n\n> [!NOTE]\n> Converted number is never presented in scientific notation unlike with other number to string commands. Also Arma's default string conversion limits numbers to 6 [significant figures](https://en.wikipedia.org/wiki/Significant_figures), whereas with this command it is possible to preserve some extra precision - see #Example 6.","syntaxes":[{"syntax":"number toFixed decimals","since":null,"effect":null,"exec":null,"params":[{"name":"number","type":"Number","optional":false,"default":null,"description":"number to convert","types":["Number"],"since":null,"text":"number: Number - number to convert"},{"name":"decimals","type":"Number","optional":false,"default":null,"description":"number of decimals to display (range 0-20)","types":["Number"],"since":null,"text":"decimals: Number - number of decimals to display (range 0-20)"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"number","types":["Number"]},"right":{"text":"decimals","types":["Number"]}},{"syntax":"toFixed decimals","since":"arma3 1.72","effect":null,"exec":null,"params":[{"name":"decimals","type":"Number","optional":false,"default":null,"description":"number of decimals to display (range 0-20). -1 to reset to default number of decimals","types":["Number"],"since":null,"text":"decimals: Number - number of decimals to display (range 0-20). -1 to reset to default number of decimals"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"decimals","types":["Number"]}}],"examples":[{"text":"```sqf\n123 toFixed 2; // \"123.00\"\n```","code":["123 toFixed 2; // \"123.00\""]},{"text":"```sqf\n2.34 toFixed 1; // \"2.3\"\n2.35 toFixed 1; // \"2.4\"\n```","code":["2.34 toFixed 1; // \"2.3\"\n2.35 toFixed 1; // \"2.4\""]},{"text":"Convert position to string preserving position precision:\n\n```sqf\nfn_posToString = \n{\n    format [\n        \"[%1,%2,%3]\", \n        _this select 0 toFixed 8, \n        _this select 1 toFixed 8, \n        _this select 2 toFixed 8\n    ]\n};\nstr getPos player;                    // \"[3231.05,171.802,0.00143862]\"\ngetPos player call fn_posToString;    // \"[3231.04882813,171.80192566,0.00143862]\"\n```","code":["fn_posToString = \n{\n\tformat [\n\t\t\"[%1,%2,%3]\", \n\t\t_this select 0 toFixed 8, \n\t\t_this select 1 toFixed 8, \n\t\t_this select 2 toFixed 8\n\t]\n};\nstr getPos player;\t\t\t\t\t// \"[3231.05,171.802,0.00143862]\"\ngetPos player call fn_posToString;\t// \"[3231.04882813,171.80192566,0.00143862]\""]},{"text":"Same as **Example 3** only using new alternative syntax:\n\n```sqf\nstr getPos player; // \"[3231.05,171.802,0.00143862]\"\ntoFixed 8;\nstr getPos player; // \"[3231.04882813,171.80192566,0.00143862]\"\n```","code":["str getPos player; // \"[3231.05,171.802,0.00143862]\"\ntoFixed 8;\nstr getPos player; // \"[3231.04882813,171.80192566,0.00143862]\""]},{"text":"```sqf\nsystemChat str position player;        // [11580.3,11797.7,0.00146675]\ncall\n{\n    toFixed 6;\n    systemChat str position player;    // [11580.341797,11797.737305,0.001467]\n};\nsystemChat str position player;        // [11580.341797,11797.737305,0.001467]\ntoFixed -1;\nsystemChat str position player;        // [11580.3,11797.7,0.00146675]\n```\n\nIdeal to be used when saving data to a database when more precise positioning is required.","code":["systemChat str position player;\t\t// [11580.3,11797.7,0.00146675]\ncall\n{\n\ttoFixed 6;\n\tsystemChat str position player;\t// [11580.341797,11797.737305,0.001467]\n};\nsystemChat str position player;\t\t// [11580.341797,11797.737305,0.001467]\ntoFixed -1;\nsystemChat str position player;\t\t// [11580.3,11797.7,0.00146675]"]},{"text":"```sqf\nstr (pi/100000);        // \"3.14159e-005\" - scientific notation\n(pi/100000) toFixed 10;    // \"0.0000314159\" - no scientific notation\nstr pi;                    // \"3.14159\" - 6 significant figures (default)\npi toFixed 6;            // \"3.141593\" - forced to 7 significant figures\npi toFixed 7;            // \"3.1415927\" - forced to 8 significant figures\n```","code":["str (pi/100000);\t\t// \"3.14159e-005\" - scientific notation\n(pi/100000) toFixed 10;\t// \"0.0000314159\" - no scientific notation\nstr pi;\t\t\t\t\t// \"3.14159\" - 6 significant figures (default)\npi toFixed 6;\t\t\t// \"3.141593\" - forced to 7 significant figures\npi toFixed 7;\t\t\t// \"3.1415927\" - forced to 8 significant figures"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toString","toArray","toLower","toUpper","toLowerANSI","toUpperANSI"],"notes":[{"user":"R3vo","date":"2016-09-02T21:56:00Z","text":"```sqf\nparseNumber (3.56346 toFixed 4);        // 0.0026 ms (10000 cycles)\n[3.5634,4] call BIS_fnc_cutDecimals;    // 0.0111 ms (10000 cycles)\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Strings","Introduced with Arma 3 version 1.66","Scripting Commands"]},{"name":"toJSON","operator":null,"title":"toJSON","type":"command","url":"https://community.bistudio.com/wiki/toJSON","revid":370177,"updated":"2024-11-04T16:34:52Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.18"}],"since":{"game":"arma3","name":"Arma 3","version":"2.18"},"arma3_since":"2.18","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts data to [JSON](https://en.wikipedia.org/wiki/JSON).","syntaxes":[{"syntax":"toJSON data","since":null,"effect":null,"exec":null,"params":[{"name":"data","type":null,"optional":false,"default":null,"description":"Only certain Data Types are supported:\n- Boolean - serialized as JSON boolean\n- Number - serialized as JSON number (floating-point)\n- String - serialized as JSON string\n- Array - Serialized as JSON array. Unsupported elements (e.g. Objects) are converted to JSON null.\n- HashMap - Serialized as JSON object. Only String keys are supported, other keys are ignored. Unsupported values (e.g. Objects) are converted to JSON null.\n- nil - serialized as JSON null \n\n> [!IMPORTANT]\n> The nil value can only be passed as a member of an Array or HashMap. It cannot be passed directly as the command would simply not execute.","types":[],"since":null,"text":"data - Only certain Data Types are supported:\n- Boolean - serialized as JSON boolean\n- Number - serialized as JSON number (floating-point)\n- String - serialized as JSON string\n- Array - Serialized as JSON array. Unsupported elements (e.g. Objects) are converted to JSON null.\n- HashMap - Serialized as JSON object. Only String keys are supported, other keys are ignored. Unsupported values (e.g. Objects) are converted to JSON null.\n- nil - serialized as JSON null \n\n> [!IMPORTANT]\n> The nil value can only be passed as a member of an Array or HashMap. It cannot be passed directly as the command would simply not execute."}],"returns":{"type":"String","types":["String"],"description":"JSON string","text":"String - JSON string"},"form":"unary","operator":null,"left":null,"right":{"text":"data","types":[]}}],"examples":[{"text":"```sqf\nprivate _result = toJSON [\"this\", \"is\", \"an\", \"array\"];\n```\n\nResult:\n\n```json\n[\"this\",\"is\",\"an\",\"array\"]\n```","code":["private _result = toJSON [\"this\", \"is\", \"an\", \"array\"];"]},{"text":"```sqf\nprivate _hashMap = createHashMap;\n_hashMap set [\"bKey\", true];\n_hashMap set [\"sKey\", \"Hello there\"];\n_hashMap set [\"oKey\", player];\n_hashMap set [\"nKey\", 42];\n_hashMap set [\"hKey\", [\"key1\", \"key2\", \"yolo\"] createHashMapFromArray [\"General Kenobi\", true, \"Hello it's me\"]];\ntoJSON _hashMap;\n```\n\nResult (formatted for readability):\n\n```json\n{\n    \"bKey\": true,\n    \"sKey\": \"Hello there\",\n    \"oKey\": null,\n    \"nkey\": 42,\n    \"hKey\": {\n        \"key1\": \"General Kenobi\",\n        \"key2\": true,\n        \"yolo\": \"Hello it's me\"\n    }\n}\n```","code":["private _hashMap = createHashMap;\n_hashMap set [\"bKey\", true];\n_hashMap set [\"sKey\", \"Hello there\"];\n_hashMap set [\"oKey\", player];\n_hashMap set [\"nKey\", 42];\n_hashMap set [\"hKey\", [\"key1\", \"key2\", \"yolo\"] createHashMapFromArray [\"General Kenobi\", true, \"Hello it's me\"]];\ntoJSON _hashMap;"]},{"text":"```sqf\nprivate _jsonPlayer = toJSON player; // empty string - [[Object]] is not supported\n```","code":["private _jsonPlayer = toJSON player; // empty string - [[Object]] is not supported"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["fromJSON","toString","str"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 2.18","Scripting Commands"]},{"name":"toLower","operator":null,"title":"toLower","type":"command","url":"https://community.bistudio.com/wiki/toLower","revid":308975,"updated":"2022-04-21T14:51:35Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied Unicode string to all lowercase characters. If the string doesn't have characters with codes > 255, use toLowerANSI.","syntaxes":[{"syntax":"toLower string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\nhint toLower \"AaBb1\"; // returns \"aabb1\"\n```","code":["hint toLower \"AaBb1\"; // returns \"aabb1\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toString","toArray","toUpper","toFixed","toLowerANSI","toUpperANSI"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Armed Assault version 1.09","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"toLowerANSI","operator":null,"title":"toLowerANSI","type":"command","url":"https://community.bistudio.com/wiki/toLowerANSI","revid":339603,"updated":"2023-04-28T14:11:50Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied string to all lower case characters fast (could be 3× faster than toLower).\n[ANSI](https://stackoverflow.com/questions/701882/what-is-ansi-format/701920) in this case refers to [ISO-8859-1](https://en.wikipedia.org/wiki/ISO/IEC_8859-1) code page.\nThe command is primary designed to convert characters with codes 0...127 however it will also convert other characters in 128...255 range as long as they are present in ISO-8859-1 codepage.\nFor Unicode alternative see toLower.","syntaxes":[{"syntax":"toLowerANSI string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to convert","types":["String"],"since":null,"text":"string: String - string to convert"}],"returns":{"type":"String","types":["String"],"description":"all lower case string","text":"String - all lower case string"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\nhint toLowerANSI \"AaBb1\"; // returns \"aabb1\"\n```","code":["hint toLowerANSI \"AaBb1\"; // returns \"aabb1\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toUpperANSI","toLower","toString","toArray","toUpper","toFixed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"toString","operator":null,"title":"toString","type":"command","url":"https://community.bistudio.com/wiki/toString","revid":351525,"updated":"2023-12-06T11:24:40Z","groups":["Strings","Arrays"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied Array of Numbers into a String through <https://en.wikipedia.org/wiki/Unicode> characters representation conversion, or provided Code to compilable String.","syntaxes":[{"syntax":"toString array","since":null,"effect":null,"exec":null,"params":[{"name":"array","type":"Array of Numbers","optional":false,"default":null,"description":"Array of Numbers\n\n> [!IMPORTANT]\n> If *array* contains non-number values, the following error might appear in .rpt file: `Bad conversion: scalar`. See parseSimpleArray for multi-type array.","types":["Array","Number"],"since":null,"text":"array: Array of Numbers\n\n> [!IMPORTANT]\n> If *array* contains non-number values, the following error might appear in .rpt file: `Bad conversion: scalar`. See parseSimpleArray for multi-type array."}],"returns":{"type":"String","types":["String"],"description":"<https://en.wikipedia.org/wiki/Unicode> numbers converted to String of characters","text":"String - <https://en.wikipedia.org/wiki/Unicode> numbers converted to String of characters"},"form":"unary","operator":null,"left":null,"right":{"text":"array","types":["Array","Number"]}},{"syntax":"toString code","since":"arma3 2.02","effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"String","types":["String"],"description":"compilable String from provided code","text":"String - compilable String from provided code"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\nhint toString [65,97,338]; // returns \"AaŒ\"\n```","code":["hint toString [65,97,338]; // returns \"AaŒ\""]},{"text":"```sqf\n[\"test\", \"test\"] joinString toString [12345] splitString toString [12345]; // [\"test\", \"test\"]\n```","code":["[\"test\", \"test\"] joinString toString [12345] splitString toString [12345]; // [\"test\", \"test\"]"]},{"text":"```sqf\nprivate _compilableString = toString { hint \"it works!\" };\nhint _compilableString; // hints ' hint \"it works!\" '\nsleep 2;\ncall compile _compilableString; // hints ' it works! '\n```","code":["private _compilableString = toString { hint \"it works!\" };\nhint _compilableString; // hints ' hint \"it works!\" '\nsleep 2;\ncall compile _compilableString; // hints ' it works! '"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["parseSimpleArray","set","resize","reverse","select","in","find","toArray","forEach","count","deleteAt","deleteRange","append","sort","param","params","arrayIntersect","splitString","joinString","toLower","toUpper","toFixed","endl","format","formatText","toLowerANSI","toUpperANSI"],"notes":[{"user":"DreadedEntity","date":"2015-02-10T21:05:00Z","text":"Tabs and new lines can be created with toString [9] and toString [10], respectively. Alternatively, a new line can also be created with toString [92,110] (\"\\n\"). If you save these strings into a variable, they can be manipulated like any other string. For example, the following code will work just fine and return the expected output:\n\n```sqf\n_tab = toString [9];\nfor \"_i\" from 0 to 3 do\n{\n    _tab = _tab + (toString [9]);\n};\ncopyToClipboard format [\"x%1x\",tab];\n```"},{"user":"Killzone_Kid","date":"2015-08-25T09:58:00Z","text":"While you can convert any String to Array with toArray command, only numbers from 1 to 55295 (not 65535 as expected) can be successfully converted to String with toString and then back to Array with toArray without loss of data."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Arrays","Command Group: Strings","Introduced with Armed Assault version 1.09","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"toUpper","operator":null,"title":"toUpper","type":"command","url":"https://community.bistudio.com/wiki/toUpper","revid":308976,"updated":"2022-04-21T14:52:14Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.09"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.09"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied Unicode string to all uppercase characters. If the string doesn't have characters with codes > 255, use toUpperANSI.","syntaxes":[{"syntax":"toUpper string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"string: String"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\nhint toUpper \"AaBb1\"; // returns \"AABB1\"\n```","code":["hint toUpper \"AaBb1\"; // returns \"AABB1\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toString","toArray","toLower","toFixed","toLowerANSI","toUpperANSI"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Armed Assault version 1.09","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"toUpperANSI","operator":null,"title":"toUpperANSI","type":"command","url":"https://community.bistudio.com/wiki/toUpperANSI","revid":339630,"updated":"2023-04-28T14:11:56Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.96"}],"since":{"game":"arma3","name":"Arma 3","version":"1.96"},"arma3_since":"1.96","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts the supplied string to all upper case characters fast (could be 3x faster than toUpper).\n[ANSI](https://stackoverflow.com/questions/701882/what-is-ansi-format/701920) in this case refers to [ISO-8859-1](https://en.wikipedia.org/wiki/ISO/IEC_8859-1) code page.\nThe command is primary designed to convert characters with codes 0...127 however will also convert other characters in 128...255 range as long as they are present in ISO-8859-1 codepage.\nFor Unicode alternative see toUpper.","syntaxes":[{"syntax":"toUpperANSI string","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to convert","types":["String"],"since":null,"text":"string: String - string to convert"}],"returns":{"type":"String","types":["String"],"description":"all upper case string","text":"String - all upper case string"},"form":"unary","operator":null,"left":null,"right":{"text":"string","types":["String"]}}],"examples":[{"text":"```sqf\nhint toUpperANSI \"AaBb1\"; // returns \"AABB1\"\n```","code":["hint toUpperANSI \"AaBb1\"; // returns \"AABB1\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["toLowerANSI","toLower","toString","toArray","toUpper","toFixed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 1.96","Scripting Commands"]},{"name":"triggerActivated","operator":null,"title":"triggerActivated","type":"command","url":"https://community.bistudio.com/wiki/triggerActivated","revid":352701,"updated":"2024-02-18T16:52:51Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns true if the trigger has been activated.","syntaxes":[{"syntax":"triggerActivated trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\nif (triggerActivated trg1) then { hint \"trigger trg1 activated!\" };\n```","code":["if (triggerActivated trg1) then { hint \"trigger trg1 activated!\" };"]}],"multiplayer":"> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger activated status on the client that executed the command.\n> See createTrigger for more information.","problems":null,"aliases":[],"see_also":["setTriggerActivation","triggerActivation","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled","createTrigger"],"notes":[{"user":"MisterGoodson","date":"2015-06-09T14:50:00Z","text":"If the trigger already activated at least once, triggerActivated will only return false if trigger is set to activate Repeatedly.\n\nIn other words, a trigger set to activate Once will always return true once activated at least once (even if trigger is no longer activated)."},{"user":"Killzone_Kid","date":"2020-08-13T10:50:00Z","text":"The engine does not provide a precise way of detecting which player activated the trigger.\nThe trigger has a default triggerInterval of ~0.5 seconds, so every half a second it checks if there is anyone in the zone.\nThere could be 100 people in the zone on the next scan, which one was the first? There is simply no data for this.\nYou can make an imprecise guess by taking 1st person from thisList or list. Also you should do it on server only trigger.\nThis will still not guarantee that person first on the list is the one who was first to activate trigger, but on balance will probably be the one."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerActivation","operator":null,"title":"triggerActivation","type":"command","url":"https://community.bistudio.com/wiki/triggerActivation","revid":378816,"updated":"2026-06-30T23:55:03Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns trigger activation.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger activation set up locally on the client that executed the command. See createTrigger for more info.","syntaxes":[{"syntax":"triggerActivation trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Array with [by, type, repeating, persistent]","types":["Array"],"description":"by: String - See setTriggerActivation - type: String - See setTriggerActivation - repeating: Boolean - See setTriggerActivation - persistent: Boolean Arma 3 v2.24 - See setTriggerActivation","text":"Array with [by, type, repeating, persistent]\n- by: String - See setTriggerActivation\n- type: String - See setTriggerActivation\n- repeating: Boolean - See setTriggerActivation\n- persistent: Boolean Arma 3 v2.24 - See setTriggerActivation"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_activation = triggerActivation someTrigger;\n```","code":["_activation = triggerActivation someTrigger;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerActivation","triggerActivated","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerAmmo","operator":null,"title":"triggerAmmo","type":"command","url":"https://community.bistudio.com/wiki/triggerAmmo","revid":377211,"updated":"2026-01-01T11:53:01Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Triggers a munition such as shells, bullets, missiles, rockets, mines and bombs (*shotSubmunition/shotShell/shotBullet/shotMissile/shotRocket*) as if it did hit.\nIf ammo uses submunition, then creation of submunition will be triggered. Since Arma 3 v 2.22 it is possible to manipulate mine timer, cook grenades and alter missile trigger distance.","syntaxes":[{"syntax":"triggerAmmo munition","since":null,"effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"munition: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"munition","types":["Object"]}},{"syntax":"triggerAmmo [munition, timeLeft, distanceLeft]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"munition","type":"Object","optional":false,"default":null,"description":"ammo. If 'timeLeft' and 'distanceLeft' are not provided, the action is identical to the main syntax.","types":["Object"],"since":null,"text":"munition: Object - ammo. If 'timeLeft' and 'distanceLeft' are not provided, the action is identical to the main syntax."},{"name":"timeLeft","type":"Number","optional":true,"default":null,"description":"'timeToExplosion' (see getShotInfo). Can only be set to <= relevant config value. Default: -1 - ignore.","types":["Number"],"since":null,"text":"timeLeft: Number - (Optional) 'timeToExplosion' (see getShotInfo). Can only be set to <= relevant config value. Default: -1 - ignore."},{"name":"distanceLeft","type":"Number","optional":true,"default":null,"description":"'fuseDistanceLeft' (see getShotInfo). Can only be set to <= relevant config value. Default: -1 - ignore.","types":["Number"],"since":null,"text":"distanceLeft: Number - (Optional) 'fuseDistanceLeft' (see getShotInfo). Can only be set to <= relevant config value. Default: -1 - ignore."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[munition, timeLeft, distanceLeft]","types":["Array"]}}],"examples":[{"text":"```sqf\ntriggerAmmo bomb1;\n```","code":["triggerAmmo bomb1;"]},{"text":"```sqf\nplayer addEventHandler [\"FiredMan\", {triggerAmmo [_this select 6, 1]}]; // explodes handgrenade or sets smoke on smokegrenade 1 sec after the throw.\n```","code":["player addEventHandler [\"FiredMan\", {triggerAmmo [_this select 6, 1]}]; // explodes handgrenade or sets smoke on smokegrenade 1 sec after the throw."]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getShotParents","Arma 3: Event Handlers"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"triggerArea","operator":null,"title":"triggerArea","type":"command","url":"https://community.bistudio.com/wiki/triggerArea","revid":377709,"updated":"2026-01-02T09:03:48Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns currently monitored trigger area. Since Arma 3 v1.60, the command returns 3rd dimension for the monitored area. If height is not set, the value for it would be -1.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger area set up locally on the client that executed the command. See createTrigger for more info.","syntaxes":[{"syntax":"triggerArea trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Array with [a, b, angle, isRectangle, c]","types":["Array"],"description":"a: Number - trigger area X size / 2 - b: Number - trigger area Y size / 2 - angle: Number in range 0..360 - isRectangle: Boolean - c: Number - trigger area Z size / 2 (since Arma 3 v1.60)","text":"Array with [a, b, angle, isRectangle, c]\n- a: Number - trigger area X size / 2\n- b: Number - trigger area Y size / 2\n- angle: Number in range 0..360\n- isRectangle: Boolean\n- c: Number - trigger area Z size / 2 (since Arma 3 v1.60)"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_area = triggerArea sensor1; // result is [200, 120, 45, false, -1];\n```","code":["_area = triggerArea sensor1; // result is [200, 120, 45, false, -1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerArea","inArea","inAreaArray"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerAttachedVehicle","operator":null,"title":"triggerAttachedVehicle","type":"command","url":"https://community.bistudio.com/wiki/triggerAttachedVehicle","revid":320994,"updated":"2022-05-13T10:28:34Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns vehicle attached to the trigger (for example using triggerAttachVehicle).\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the vehicle attached locally on the client that executed the command. See createTrigger for more info.","syntaxes":[{"syntax":"triggerAttachedVehicle trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_result = triggerAttachedVehicle triggerName;\n```","code":["_result = triggerAttachedVehicle triggerName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle","attachedObject","triggerAttachObject"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerAttachObject","operator":null,"title":"triggerAttachObject","type":"command","url":"https://community.bistudio.com/wiki/triggerAttachObject","revid":336715,"updated":"2023-01-04T15:24:43Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Assigns a static object to the trigger. The activation source is changed to \"STATIC\".","syntaxes":[{"syntax":"triggerName triggerAttachObject objectId","since":null,"effect":null,"exec":null,"params":[{"name":"triggerName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"triggerName: Object"},{"name":"objectId","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"objectId: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"triggerName","types":["Object"]},"right":{"text":"objectId","types":["Number"]}}],"examples":[{"text":"```sqf\n_trigger triggerAttachObject 1234;\n```","code":["_trigger triggerAttachObject 1234;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","triggerAttachVehicle","attachedObject","triggerAttachedVehicle","triggerInterval","setTriggerInterval","enableSimulation","simulationEnabled"],"notes":[{"user":"Killzone_Kid","date":"2013-10-31T21:56:00Z","text":"This command doesn't quite work in Arma 3: see\n\nFurther investigation reveals that objectId param for this command is some kind of map id and not the id you can see in the editor. This map id could be seen in multiplayer when looking at netId of the static objects, for example \"1:-23984219837\", the -23984219837 would be the objectId. Unfortunately it still doesn't work."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerAttachVehicle","operator":null,"title":"triggerAttachVehicle","type":"command","url":"https://community.bistudio.com/wiki/triggerAttachVehicle","revid":377073,"updated":"2026-01-01T09:31:40Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Specifies the entity which will activate the selected trigger.\n\n- If **[]** is given, the trigger is decoupled from the assigned vehicle (example 2).\n- If the activation source is **\"VEHICLE\"**, **\"GROUP\"**, **\"LEADER\"** or **\"MEMBER\"**, it is changed to **\"NONE\"**.\n- If **[vehicle]** is given, the trigger is coupled to the vehicle or its group.\n- When the source is **\"GROUP\"**, **\"LEADER\"** or **\"MEMBER\"**, it is coupled to the group, otherwise it is coupled to the vehicle and the source is changed to **\"VEHICLE\"**.","syntaxes":[{"syntax":"triggerName triggerAttachVehicle objects","since":null,"effect":null,"exec":null,"params":[{"name":"triggerName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"triggerName: Object"},{"name":"objects","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"objects: Array of Objects"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"triggerName","types":["Object"]},"right":{"text":"objects","types":["Array","Object"]}}],"examples":[{"text":"```sqf\ntrigger triggerAttachVehicle [player];\n```","code":["trigger triggerAttachVehicle [player];"]},{"text":"```sqf\ntrigger triggerAttachVehicle [];\n```","code":["trigger triggerAttachVehicle [];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","attachedTo","waypointAttachVehicle","waypointAttachedVehicle","lightAttachObject","attachedObject","triggerAttachedVehicle","triggerAttachObject","triggerInterval","setTriggerInterval"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"triggerDynamicSimulation","operator":null,"title":"triggerDynamicSimulation","type":"command","url":"https://community.bistudio.com/wiki/triggerDynamicSimulation","revid":342181,"updated":"2023-07-09T12:27:00Z","groups":["Dynamic Simulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.68"}],"since":{"game":"arma3","name":"Arma 3","version":"1.68"},"arma3_since":"1.68","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Controls the ability of given unit to activate entities with disabled Arma 3: Dynamic Simulation. If false dynamically disabled entities will not be activated by this unit's presence. This command has the same effect as the Eden Editor attribute *Wake-Up Dynamic Simulation*.","syntaxes":[{"syntax":"unit triggerDynamicSimulation trigger","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"trigger","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"trigger: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"trigger","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer triggerDynamicSimulation false;\n```","code":["player triggerDynamicSimulation false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableDynamicSimulationSystem","dynamicSimulationSystemEnabled","enableDynamicSimulation","dynamicSimulationEnabled","setDynamicSimulationDistance","dynamicSimulationDistance","setDynamicSimulationDistanceCoef","dynamicSimulationDistanceCoef","canTriggerDynamicSimulation","enableSimulation","simulationEnabled","enableSimulationGlobal","Arma 3: Dynamic Simulation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Dynamic Simulation","Introduced with Arma 3 version 1.68","Scripting Commands"]},{"name":"triggerInterval","operator":null,"title":"triggerInterval","type":"command","url":"https://community.bistudio.com/wiki/triggerInterval","revid":349226,"updated":"2023-11-08T14:50:51Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.98"}],"since":{"game":"arma3","name":"Arma 3","version":"1.98"},"arma3_since":"1.98","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns trigger condition check frequency in seconds.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger interval set up locally on the client that executed the command. See createTrigger for more info.","syntaxes":[{"syntax":"triggerInterval trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger object","types":["Object"],"since":null,"text":"trigger: Object - trigger object"}],"returns":{"type":"Number","types":["Number"],"description":"trigger interval in seconds","text":"Number - trigger interval in seconds"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_interval = triggerInterval someTrigger;\n```","code":["_interval = triggerInterval someTrigger;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerInterval","createTrigger","enableSimulation","simulationEnabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 3 version 1.98","Scripting Commands"]},{"name":"triggerStatements","operator":null,"title":"triggerStatements","type":"command","url":"https://community.bistudio.com/wiki/triggerStatements","revid":378402,"updated":"2026-04-04T08:11:49Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns trigger statements.","syntaxes":[{"syntax":"triggerStatements trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Array with [condition, activation, deactivation]","types":["Array"],"description":"condition: String - activation: String - code ran when the trigger is activated - deactivation: String - code ran when the trigger is deactivated","text":"Array with [condition, activation, deactivation]\n- condition: String\n- activation: String - code ran when the trigger is activated\n- deactivation: String - code ran when the trigger is deactivated"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_statements = triggerStatements someTrigger;\n```","code":["_statements = triggerStatements someTrigger;"]}],"multiplayer":"The trigger could be local or remote but the result returned by this command will be for the trigger statements set up locally on the client that executed the command. See createTrigger for more info.","problems":null,"aliases":[],"see_also":["setTriggerStatements"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerText","operator":null,"title":"triggerText","type":"command","url":"https://community.bistudio.com/wiki/triggerText","revid":319934,"updated":"2022-05-13T09:25:45Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns trigger text.","syntaxes":[{"syntax":"triggerText trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_text = triggerText triggerName;\n```","code":["_text = triggerText triggerName;"]}],"multiplayer":"The trigger could be local or remote but the result returned by this command will be for the trigger text set up locally on the client that executed the command. See createTrigger for more info.","problems":null,"aliases":[],"see_also":["setTriggerText"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerTimeout","operator":null,"title":"triggerTimeout","type":"command","url":"https://community.bistudio.com/wiki/triggerTimeout","revid":377686,"updated":"2026-01-02T09:02:55Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns trigger timeout.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger timeout set up locally on the client that executed the command. See createTrigger for more info.","syntaxes":[{"syntax":"triggerTimeout trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"Array with [min, mid, max, interruptible]","types":["Array"],"description":"min: Number - mid: Number - max: Number - interruptible: Boolean","text":"Array with [min, mid, max, interruptible]\n- min: Number\n- mid: Number\n- max: Number\n- interruptible: Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_timeOut = triggerTimeout someTrigger;\n```","code":["_timeOut = triggerTimeout someTrigger;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerTimeout","triggerTimeoutCurrent"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"triggerTimeoutCurrent","operator":null,"title":"triggerTimeoutCurrent","type":"command","url":"https://community.bistudio.com/wiki/triggerTimeoutCurrent","revid":376123,"updated":"2025-09-01T08:15:52Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns current timeout of the given trigger or -1 if countdown is not in progress.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the current trigger timeout local to the client that executed the command.\n> See createTrigger for more info.","syntaxes":[{"syntax":"triggerTimeoutCurrent trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":"trigger object","types":["Object"],"since":null,"text":"trigger: Object - trigger object"}],"returns":{"type":"Number","types":["Number"],"description":"time remaining before trigger activation.","text":"Number - time remaining before trigger activation."},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_remaining = triggerTimeoutCurrent _trigger;\n```","code":["_remaining = triggerTimeoutCurrent _trigger;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["triggerTimeout","setTriggerTimeout","waypointTimeoutCurrent"],"notes":[{"user":"Killzone_Kid","date":"2013-11-26T12:16:00Z","text":"Triggers have their own schedule. If you create a trigger with timeout and try to read triggerTimeoutCurrent immediately it will return -1.\nThis is because the countdown will not start until the next scheduled trigger check is due, and this could take up to 0.5 seconds."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"triggerType","operator":null,"title":"triggerType","type":"command","url":"https://community.bistudio.com/wiki/triggerType","revid":339279,"updated":"2023-04-28T14:02:49Z","groups":["Triggers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the trigger type.\n\n> [!IMPORTANT]\n> The trigger could be local or remote but the result returned by this command will be for the trigger type set up locally on the client that executed the command.\n> See createTrigger for more info.","syntaxes":[{"syntax":"triggerType trigger","since":null,"effect":null,"exec":null,"params":[{"name":"trigger","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"trigger: Object"}],"returns":{"type":"String","types":["String"],"description":"can be one of the following (see setTriggerType for details): - `\"NONE\"` - `\"EAST G\"` - `\"WEST G\"` - `\"GUER G\"` - `\"SWITCH\"` - `\"END1\"` - `\"END2\"` - `\"END3\"` - `\"END4\"` - `\"END5\"` - `\"END6\"` - `\"LOOSE\"` - `\"WIN\"` Can return `\"ERROR\"` in case of an invalid trigger type (due to Mission.sqm manual edit or other type of data corruption)","text":"String - can be one of the following (see setTriggerType for details):\n- `\"NONE\"`\n- `\"EAST G\"`\n- `\"WEST G\"`\n- `\"GUER G\"`\n- `\"SWITCH\"`\n- `\"END1\"`\n- `\"END2\"`\n- `\"END3\"`\n- `\"END4\"`\n- `\"END5\"`\n- `\"END6\"`\n- `\"LOOSE\"`\n- `\"WIN\"`\nCan return `\"ERROR\"` in case of an invalid trigger type (due to Mission.sqm manual edit or other type of data corruption)"},"form":"unary","operator":null,"left":null,"right":{"text":"trigger","types":["Object"]}}],"examples":[{"text":"```sqf\n_type = triggerType tr1;\n```","code":["_type = triggerType tr1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setTriggerType"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Triggers","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"trim","operator":null,"title":"trim","type":"command","url":"https://community.bistudio.com/wiki/trim","revid":377062,"updated":"2026-01-01T09:06:47Z","groups":["Strings"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Trims a string.","syntaxes":[{"syntax":"trim stringValue","since":null,"effect":null,"exec":null,"params":[{"name":"stringValue","type":"String","optional":false,"default":null,"description":"string to be trimmed. spaces, tabs and line returns are removed from both ends of *stringValue*.","types":["String"],"since":null,"text":"stringValue: String - string to be trimmed. spaces, tabs and line returns are removed from both ends of *stringValue*."}],"returns":{"type":"String","types":["String"],"description":"trimmed string","text":"String - trimmed string"},"form":"unary","operator":null,"left":null,"right":{"text":"stringValue","types":["String"]}},{"syntax":"string trim [chars, where]","since":null,"effect":null,"exec":null,"params":[{"name":"string","type":"String","optional":false,"default":null,"description":"string to be trimmed","types":["String"],"since":null,"text":"string: String - string to be trimmed"},{"name":"chars","type":"String","optional":false,"default":null,"description":"list of characters to be trimmed","types":["String"],"since":null,"text":"chars: String - list of characters to be trimmed"},{"name":"where","type":"Number one of:","optional":false,"default":null,"description":"Number one of:\n- 0 - trim at the beginning (left) and the end (right)\n- 1 - trim at the beginning (left)\n- 2 - trim at the end (right)","types":["Number"],"since":null,"text":"where: Number one of:\n- 0 - trim at the beginning (left) and the end (right)\n- 1 - trim at the beginning (left)\n- 2 - trim at the end (right)"}],"returns":{"type":"String","types":["String"],"description":"trimmed string","text":"String - trimmed string"},"form":"binary","operator":null,"left":{"text":"string","types":["String"]},"right":{"text":"[chars, where]","types":["Array"]}}],"examples":[{"text":"```sqf\ntrim \"        hello, how are you?  \"; // returns \"hello, how are you?\"\n```","code":["trim \"\t\thello, how are you?  \"; // returns \"hello, how are you?\""]},{"text":"```sqf\n\"hewosentence!123\" trim [\"3e1o2hw\", 0]; // returns \"sentence!\"\n```","code":["\"hewosentence!123\" trim [\"3e1o2hw\", 0]; // returns \"sentence!\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["select"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Strings","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"true","operator":null,"title":"true","type":"command","url":"https://community.bistudio.com/wiki/true","revid":369382,"updated":"2024-09-03T18:43:15Z","groups":["Math","Variables"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Always true","syntaxes":[{"syntax":"true","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_var = true;\nsystemChat str _var; // true\n\nif (_var) then\n{\n    hint \"_var is true!\";\n};\n```","code":["_var = true;\nsystemChat str _var; // true\n\nif (_var) then\n{\n\thint \"_var is true!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["false"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math","Command Group: Variables","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"try","operator":null,"title":"try","type":"command","url":"https://community.bistudio.com/wiki/try","revid":369368,"updated":"2024-09-03T18:43:09Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Defines a try-catch structure. This sets up an exception handling block. Any thrown exception in a try block is caught in a catch block. The structured exception block has the following form:\n\n```sqf\ntry\n{ /* block that can throw exception */ }\ncatch\n{ /* block that processes the exception. Exception is described in the _exception variable */ };\n```","syntaxes":[{"syntax":"try code","since":null,"effect":null,"exec":null,"params":[{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Exception Type","types":["Exception handling"],"description":null,"text":"Exception Type"},"form":"unary","operator":null,"left":null,"right":{"text":"code","types":["Code"]}},{"syntax":"args try code","since":"arma3 1.54","effect":null,"exec":null,"params":[{"name":"args","type":"Anything","optional":false,"default":null,"description":"passed arguments, will be put in *_this* variable inside the \"code\"","types":["Anything"],"since":null,"text":"args: Anything - passed arguments, will be put in *_this* variable inside the \"code\""},{"name":"code","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"code: Code"}],"returns":{"type":"Exception Type","types":["Exception handling"],"description":null,"text":"Exception Type"},"form":"binary","operator":null,"left":{"text":"args","types":["Anything"]},"right":{"text":"code","types":["Code"]}}],"examples":[{"text":"```sqf\ntry { throw \"invalid argument\" } catch { hint str _exception };\n```","code":["try { throw \"invalid argument\" } catch { hint str _exception };"]},{"text":"```sqf\n123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };\n```","code":["123 try { if (_this != 123) throw \"invalid argument\" } catch { hint str _exception };"]},{"text":"```sqf\ntry {\n    if (a > b) throw \"Error: some error\"; // OK\n    // the command argument is static\n} catch {\n    hint str _exception;\n};\n\ntry {\n    _someFunc = {\n        // ...\n    };\n    if (a > b) throw (call _someFunc); // NOT OK\n    // the command argument is dynamic\n    // _someFunc is called first to get the value regardless of (a > b) outcome\n} catch {\n    hint str _exception;\n};\n\ntry {\n    _someFunc = {\n        // ...\n    };\n    if (a > b) then {throw (call _someFunc)}; // OK\n    // the command argument is dynamic\n    // _someFunc is only called when (a > b) is true\n} catch {\n    hint str _exception;\n};\n```","code":["try {\n\tif (a > b) throw \"Error: some error\"; // OK\n\t// the command argument is static\n} catch {\n\thint str _exception;\n};\n\ntry {\n\t_someFunc = {\n\t\t// ...\n\t};\n\tif (a > b) throw (call _someFunc); // NOT OK\n\t// the command argument is dynamic\n\t// _someFunc is called first to get the value regardless of (a > b) outcome\n} catch {\n\thint str _exception;\n};\n\ntry {\n\t_someFunc = {\n\t\t// ...\n\t};\n\tif (a > b) then {throw (call _someFunc)}; // OK\n\t// the command argument is dynamic\n\t// _someFunc is only called when (a > b) is true\n} catch {\n\thint str _exception;\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Exception handling","throw","catch"],"notes":[{"user":"Killzone_Kid","date":"2015-06-09T20:52:00Z","text":"Do not expect this behave like Javascript try catch and ignore all errors. But it does have one useful behaviour. Normally when a runtime error occurs in SQF (unlike when there is compile error) it continues to execute till the end. But if the script is placed in try {} scope and throw is used upon error, the script immediately terminates, exits the try {} scope and enters catch {} scope. This way it is possible to process possible exceptions in civilised manner."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"turretLocal","operator":null,"title":"turretLocal","type":"command","url":"https://community.bistudio.com/wiki/turretLocal","revid":378399,"updated":"2026-04-04T08:02:12Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if a turret is local.","syntaxes":[{"syntax":"vehicle turretLocal turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"supports [-1] for driver turret","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - supports [-1] for driver turret"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_isLocal = vehicle player turretLocal [0];\n```","code":["_isLocal = vehicle player turretLocal [0];"]},{"text":"```sqf\nif (heli turretLocal [1]) then { heli setVehicleAmmo 1 };\n```","code":["if (heli turretLocal [1]) then { heli setVehicleAmmo 1 };"]},{"text":"```sqf\nif (isNil { heli turretLocal [5] }) then { hint \"Turret 5 is non-existent\" };\n```","code":["if (isNil { heli turretLocal [5] }) then { hint \"Turret 5 is non-existent\" };"]}],"multiplayer":"A vehicle turret will change locality when player gunner gets in it, just like vehicle changes locality when player driver gets in it.\nMany commands for turrets work only where turret is local.\nWhen gunner leaves turret it is supposed to change locality to the locality of the vehicle.","problems":null,"aliases":[],"see_also":["turretOwner","setVehicleAmmo","setVehicleAmmoDef","removeWeaponTurret","addWeaponTurret","addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","currentMagazineDetailTurret","currentMagazineTurret","currentWeaponTurret","selectWeaponTurret","turretUnit","allTurrets"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"turretOwner","operator":null,"title":"turretOwner","type":"command","url":"https://community.bistudio.com/wiki/turretOwner","revid":377490,"updated":"2026-01-02T06:49:12Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.38"}],"since":{"game":"arma3","name":"Arma 3","version":"1.38"},"arma3_since":"1.38","branch":null,"locality":{"argument":"global","effect":null,"server_exec":true},"exec":null,"description":"Returns id of the turret's owner. Returns 0 on non-server and SP.","syntaxes":[{"syntax":"vehicle turretOwner turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"since Arma 3 v2.08 [-1] (driver) is supported","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - since Arma 3 v2.08 [-1] (driver) is supported"}],"returns":{"type":"Number","types":["Number"],"description":"owner id","text":"Number - owner id"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_ownerId = vehicle player turretOwner [0];\n```","code":["_ownerId = vehicle player turretOwner [0];"]}],"multiplayer":"A vehicle turret will change locality when player gunner gets in it, just like vehicle changes locality when player driver gets in it. Many commands for turrets work only where turret is local. When gunner leaves turret it is supposed to change locality to the locality of the vehicle. A vehicle can have one owner while turrets have different owners.","problems":null,"aliases":[],"see_also":["owner","setOwner","turretLocal","setVehicleAmmo","setVehicleAmmoDef","removeWeaponTurret","addWeaponTurret","addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weaponsTurret","currentMagazineDetailTurret","currentMagazineTurret","currentWeaponTurret","selectWeaponTurret"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 1.38","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"turretUnit","operator":null,"title":"turretUnit","type":"command","url":"https://community.bistudio.com/wiki/turretUnit","revid":377501,"updated":"2026-01-02T06:49:29Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the unit in the vehicle turret. To find turret path of known unit, see unitTurret.","syntaxes":[{"syntax":"vehicle turretUnit turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":"since Arma 3 v1.58 [-1] (driver) is supported.","types":["Turret Path"],"since":null,"text":"turretPath: Turret Path - since Arma 3 v1.58 [-1] (driver) is supported."}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_vehicle turretUnit _thisTurret;\n```","code":["_vehicle turretUnit _thisTurret;"]},{"text":"```sqf\nvehicle player turretUnit [0];\n```","code":["vehicle player turretUnit [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitTurret","driver","gunner","commander","effectiveCommander","currentPilot","moveInTurret","assignAsTurret","assignedVehicleRole","lockedTurret","isTurnedOut"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"tvAdd","operator":null,"title":"tvAdd","type":"command","url":"https://community.bistudio.com/wiki/tvAdd","revid":378319,"updated":"2026-04-02T16:17:41Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds an item with given text to Tree View control. The position on Tree View where to add the item and the actual path to this item once added are different. If item is added to existing item, then parent item path is used. If no parent exists, empty array [] is used. See Tree View Path for more information.","syntaxes":[{"syntax":"tvAdd [idc, pathParent, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"pathParent","type":"Tree View Path","optional":false,"default":null,"description":"parent item or [] if no parent exists","types":["Tree View Path"],"since":null,"text":"pathParent: Tree View Path - parent item or [] if no parent exists"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Number","types":["Number"],"description":"index of the added item relative to the branch it was added to","text":"Number - index of the added item relative to the branch it was added to"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, pathParent, text]","types":["Array"]}},{"syntax":"control tvAdd [pathParent, text]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"pathParent","type":"Tree View Path","optional":false,"default":null,"description":"parent item or [] if no parent exists","types":["Tree View Path"],"since":null,"text":"pathParent: Tree View Path - parent item or [] if no parent exists"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Number","types":["Number"],"description":"index of the added item relative to the branch it was added to","text":"Number - index of the added item relative to the branch it was added to"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[pathParent, text]","types":["Array"]}}],"examples":[{"text":"```sqf\n_index = _ctrl tvAdd [[], \"Parent Item\"];\n```","code":["_index = _ctrl tvAdd [[], \"Parent Item\"];"]},{"text":"```sqf\n_index = tvAdd [101, [0], \"First item\"];\n```","code":["_index = tvAdd [101, [0], \"First item\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureRightColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvClear","operator":null,"title":"tvClear","type":"command","url":"https://community.bistudio.com/wiki/tvClear","revid":309901,"updated":"2022-05-05T12:16:47Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Removes all items from Tree View with given idc.","syntaxes":[{"syntax":"tvClear idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"tvClear control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\ntvClear 101;\n```","code":["tvClear 101;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvCollapse","operator":null,"title":"tvCollapse","type":"command","url":"https://community.bistudio.com/wiki/tvCollapse","revid":377801,"updated":"2026-01-03T04:01:37Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Collapses tree item pointed to by the path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvCollapse [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"[] will collapse the whole tree and it will disappear","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - [] will collapse the whole tree and it will disappear"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvCollapse path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"[] will collapse the whole tree and it will disappear","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - [] will collapse the whole tree and it will disappear"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\ntvCollapse [101, [0]];\n```","code":["tvCollapse [101, [0]];"]},{"text":"```sqf\n_ctrl tvCollapse [0];\n```","code":["_ctrl tvCollapse [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvCollapseAll","tvAdd","tvClear","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvCollapseAll","operator":null,"title":"tvCollapseAll","type":"command","url":"https://community.bistudio.com/wiki/tvCollapseAll","revid":309956,"updated":"2022-05-05T12:17:01Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Collapses all tree items for the given Tree View.","syntaxes":[{"syntax":"tvCollapseAll idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"tvCollapseAll control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\ntvCollapseAll 101;\n```","code":["tvCollapseAll 101;"]},{"text":"```sqf\ntvCollapseAll _ctrl;\n```","code":["tvCollapseAll _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvExpandAll","tvCollapse","tvAdd","tvClear","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvCount","operator":null,"title":"tvCount","type":"command","url":"https://community.bistudio.com/wiki/tvCount","revid":319984,"updated":"2022-05-13T09:25:50Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns children count on given path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvCount [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"ctrl tvCount path","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"```sqf\ntvCount [101, [0]];\n```","code":["tvCount [101, [0]];"]},{"text":"```sqf\n_ctrl tvCount [1,0];\n```","code":["_ctrl tvCount [1,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvCurSel","operator":null,"title":"tvCurSel","type":"command","url":"https://community.bistudio.com/wiki/tvCurSel","revid":378354,"updated":"2026-04-02T16:36:18Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns path to currently selected item. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvCurSel idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Tree View Path","types":["Tree View Path"],"description":"selected item","text":"Tree View Path - selected item"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"tvCurSel control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Tree View Path","types":["Tree View Path"],"description":"selected item","text":"Tree View Path - selected item"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\ntvCurSel 101;\n```","code":["tvCurSel 101;"]},{"text":"```sqf\ntvCurSel _ctrl;\n```","code":["tvCurSel _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvData","operator":null,"title":"tvData","type":"command","url":"https://community.bistudio.com/wiki/tvData","revid":378318,"updated":"2026-04-02T16:17:09Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns string data from item on given path. IDC means id of parent CT_TREE.","syntaxes":[{"syntax":"tvData [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvData path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\ntvData [101, [0]];\n```","code":["tvData [101, [0]];"]},{"text":"```sqf\n(_display displayCtrl 101) tvData [0];\n```","code":["(_display displayCtrl 101) tvData [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSetData"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvDelete","operator":null,"title":"tvDelete","type":"command","url":"https://community.bistudio.com/wiki/tvDelete","revid":378380,"updated":"2026-04-04T04:46:06Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Removes an item with given Tree View Path from Tree View.\n\n> [!IMPORTANT]\n> The paths of other items on the same branch after delete operation are updated accordingly; therefore, when deleting multiple entries, start with the one with the highest index and proceed in reverse order.","syntaxes":[{"syntax":"tvDelete [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvDelete path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\ntvDelete [101, [0, 0]];\n```","code":["tvDelete [101, [0, 0]];"]},{"text":"```sqf\n_ctrl tvDelete [0, 0];\n```","code":["_ctrl tvDelete [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvExpand","operator":null,"title":"tvExpand","type":"command","url":"https://community.bistudio.com/wiki/tvExpand","revid":377800,"updated":"2026-01-03T04:01:32Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Expands tree item pointed to by the path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvExpand [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"[] will expand the whole tree if it was collapsed previously with []","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - [] will expand the whole tree if it was collapsed previously with []"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvExpand path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"[] will expand the whole tree if it was collapsed previously with []","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - [] will expand the whole tree if it was collapsed previously with []"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\ntvExpand [101, [0]];\n```","code":["tvExpand [101, [0]];"]},{"text":"```sqf\n_ctrl tvExpand [1];\n```","code":["_ctrl tvExpand [1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvExpandAll","tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvExpandAll","operator":null,"title":"tvExpandAll","type":"command","url":"https://community.bistudio.com/wiki/tvExpandAll","revid":330358,"updated":"2022-09-03T09:09:58Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Expands all tree items for the given Tree View.","syntaxes":[{"syntax":"tvExpandAll idc","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"idc","types":["Number"]}},{"syntax":"tvExpandAll control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\ntvExpandAll 101;\n```","code":["tvExpandAll 101;"]},{"text":"```sqf\ntvExpandAll _ctrl;\n```","code":["tvExpandAll _ctrl;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvExpand","tvCollapse","tvCollapseAll"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvIsSelected","operator":null,"title":"tvIsSelected","type":"command","url":"https://community.bistudio.com/wiki/tvIsSelected","revid":378325,"updated":"2026-04-02T16:30:16Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if given treeview item is selected.","syntaxes":[{"syntax":"control tvIsSelected path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n_control tvIsSelected [0];\n```","code":["_control tvIsSelected [0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSelection","tvSetSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"tvPicture","operator":null,"title":"tvPicture","type":"command","url":"https://community.bistudio.com/wiki/tvPicture","revid":378317,"updated":"2026-04-02T16:16:57Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns name of picture from item pointed to by path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvPicture [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"ctrl tvPicture path","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\ntvPicture [101, [0]];\n```","code":["tvPicture [101, [0]];"]},{"text":"```sqf\n_ctrl tvPicture [0,0,0];\n```","code":["_ctrl tvPicture [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvPictureRight","operator":null,"title":"tvPictureRight","type":"command","url":"https://community.bistudio.com/wiki/tvPictureRight","revid":378316,"updated":"2026-04-02T16:16:44Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the right picture of a CT_TREE on given path.","syntaxes":[{"syntax":"tvPictureRight [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"path to picture","text":"String - path to picture"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"ctrl tvPictureRight path","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"path to picture","text":"String - path to picture"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\nprivate _result = _controlTV tvPictureRight [0, 0];\n```","code":["private _result = _controlTV tvPictureRight [0, 0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSetPictureRight","tvSetPicture","tvPicture"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"tvSelection","operator":null,"title":"tvSelection","type":"command","url":"https://community.bistudio.com/wiki/tvSelection","revid":378378,"updated":"2026-04-04T04:45:23Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of paths to selected items.","syntaxes":[{"syntax":"tvSelection control","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"}],"returns":{"type":"Tree View Path","types":["Tree View Path"],"description":null,"text":"Tree View Path"},"form":"unary","operator":null,"left":null,"right":{"text":"control","types":["Control"]}}],"examples":[{"text":"```sqf\nprivate _selection = tvSelection _ctrlTV;\n```","code":["private _selection = tvSelection _ctrlTV;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSetSelected","tvIsSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"tvSetColor","operator":null,"title":"tvSetColor","type":"command","url":"https://community.bistudio.com/wiki/tvSetColor","revid":378383,"updated":"2026-04-04T04:48:24Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets text color on given Tree View Item","syntaxes":[{"syntax":"tvSetColor [idc, path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, color]","types":["Array"]}},{"syntax":"control tvSetColor [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetColor [101, [0,0], [1,0,0,1]];\n```","code":["tvSetColor [101, [0,0], [1,0,0,1]];"]},{"text":"```sqf\n_ctrl tvSetColor [[0,0], [1,0,0,1]];\n```","code":["_ctrl tvSetColor [[0,0], [1,0,0,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvDelete","tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvSetCurSel","operator":null,"title":"tvSetCurSel","type":"command","url":"https://community.bistudio.com/wiki/tvSetCurSel","revid":369062,"updated":"2024-09-02T20:24:55Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets cursor to given item on given path. IDC means id of parent Tree View. To deselect all items use [-1] for the path param (*available since Arma 3 v1.56*)","syntaxes":[{"syntax":"tvSetCurSel [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvSetCurSel path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"```sqf\ntvSetCurSel [101, [0]];\n```","code":["tvSetCurSel [101, [0]];"]},{"text":"```sqf\n_ctrl tvSetCurSel [0,0,0];\n```","code":["_ctrl tvSetCurSel [0,0,0];"]},{"text":"```sqf\n0 spawn\n{\n    disableSerialization;\n    _CT_TREE = findDisplay 46 ctrlCreate [\"RscTree\", -1];\n    _CT_TREE ctrlSetPosition [0,0,0.3,1];\n    _CT_TREE ctrlCommit 0;\n    _CT_TREE tvAdd [[],\"Parent_A\"];\n    _CT_TREE tvAdd [[0],\"Child_A\"];\n    _CT_TREE tvAdd [[0,0],\"Grandchild_A\"];\n    _CT_TREE tvAdd [[],\"Parent_B\"];\n    _CT_TREE tvAdd [[1],\"Child_B\"];\n    sleep 1;\n    hint \"SELECT [0,0,0]\";\n    _CT_TREE tvSetCurSel [0,0,0];\n    sleep 2;\n    hint \"DESELECT ALL\";\n    _CT_TREE tvSetCurSel [-1];\n};\n```","code":["0 spawn\n{\n\tdisableSerialization;\n\t_CT_TREE = findDisplay 46 ctrlCreate [\"RscTree\", -1];\n\t_CT_TREE ctrlSetPosition [0,0,0.3,1];\n\t_CT_TREE ctrlCommit 0;\n\t_CT_TREE tvAdd [[],\"Parent_A\"];\n\t_CT_TREE tvAdd [[0],\"Child_A\"];\n\t_CT_TREE tvAdd [[0,0],\"Grandchild_A\"];\n\t_CT_TREE tvAdd [[],\"Parent_B\"];\n\t_CT_TREE tvAdd [[1],\"Child_B\"];\n\tsleep 1;\n\thint \"SELECT [0,0,0]\";\n\t_CT_TREE tvSetCurSel [0,0,0];\n\tsleep 2;\n\thint \"DESELECT ALL\";\n\t_CT_TREE tvSetCurSel [-1];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvSetData","operator":null,"title":"tvSetData","type":"command","url":"https://community.bistudio.com/wiki/tvSetData","revid":378314,"updated":"2026-04-02T16:15:57Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets string data to item on given path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvSetData [idc, path, data]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, data]","types":["Array"]}},{"syntax":"ctrl tvSetData [path, data]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"data","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"data: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[path, data]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetData [101, [0], \"Test data\"];\n```","code":["tvSetData [101, [0], \"Test data\"];"]},{"text":"```sqf\n_ctrl tvSetData [[0,0,0], \"Test data\"];\n```","code":["_ctrl tvSetData [[0,0,0], \"Test data\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvSetPicture","operator":null,"title":"tvSetPicture","type":"command","url":"https://community.bistudio.com/wiki/tvSetPicture","revid":378315,"updated":"2026-04-02T16:16:24Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets picture to item selected by path. IDC means id of parent Tree View. Name is picture name. The picture is searched in the mission directory.\n\n> [!NOTE]\n> - Adding pictures to lists is very slow. In order to prevent the filling of the list to be slowed down, add the pictures in a **scheduled** environment - See #Example 3.\n> One drawback of this method is that sorting the entries is not easily possible.\n> - If not all items have a picture but you still want them to be aligned at the front, use a Procedural Texture that is transparent `1. (rgb,32,32,3)color(1,1,1,0)`.","syntaxes":[{"syntax":"tvSetPicture [idc, path, name]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, name]","types":["Array"]}},{"syntax":"control tvSetPicture [path, name]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"name","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"name: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, name]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetPicture [101, [0], \"picture\"];\n```","code":["tvSetPicture [101, [0], \"picture\"];"]},{"text":"```sqf\n_ctrl tvSetPicture [[0,0,0], getText (configFile >> \"CfgWeapons\" >> \"optic_NVS\" >> \"picture\")];\n```","code":["_ctrl tvSetPicture [[0,0,0], getText (configFile >> \"CfgWeapons\" >> \"optic_NVS\" >> \"picture\")];"]},{"text":"Adding images in a scheduled environment:\n\n```sqf\nprivate _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n[_ctrlTV, _path] spawn {\n    (_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n};\n```","code":["private _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n[_ctrlTV, _path] spawn {\n\t(_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureRightColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvSetPictureColor","operator":null,"title":"tvSetPictureColor","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureColor","revid":377815,"updated":"2026-01-03T04:13:41Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the colour of the picture (set via tvSetPicture) under the specified tree view path.","syntaxes":[{"syntax":"tvSetPictureColor [idc, path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"IDC of the tree view control","types":["Number"],"since":null,"text":"idc: Number - IDC of the tree view control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, color]","types":["Array"]}},{"syntax":"ctrl tvSetPictureColor [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetPictureColor [101, [0,2], [1,0,1,1]];\n```","code":["tvSetPictureColor [101, [0,2], [1,0,1,1]];"]},{"text":"```sqf\n_tree tvSetPictureColor [[0,2], [1,0,1,1]];\n```","code":["_tree tvSetPictureColor [[0,2], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvSetPictureColorDisabled","operator":null,"title":"tvSetPictureColorDisabled","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureColorDisabled","revid":377792,"updated":"2026-01-03T01:40:08Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of left picture of a tree item defined by path when that item is disabled.","syntaxes":[{"syntax":"control tvSetPictureColorDisabled [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetPictureColorDisabled [[0], [1,0,1,1]];\n```","code":["_control tvSetPictureColorDisabled [[0], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureColorSelected","tvSetPictureRightColor","tvSetPictureRightColorSelected","tvSetPictureRightColorDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetPictureColorSelected","operator":null,"title":"tvSetPictureColorSelected","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureColorSelected","revid":377366,"updated":"2026-01-02T06:40:38Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of the left picture of a tree item defined by path when item is selected","syntaxes":[{"syntax":"control tvSetPictureColorSelected [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":"path to tree view item","types":["Array","Number"],"since":null,"text":"path: Array of Numbers - path to tree view item"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetPictureColorSelected [[0], [1,0,1,1]];\n```","code":["_control tvSetPictureColorSelected [[0], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureColorDisabled","tvSetPictureRightColor","tvSetPictureRightColorSelected","tvSetPictureRightColorDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetPictureRight","operator":null,"title":"tvSetPictureRight","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureRight","revid":377788,"updated":"2026-01-03T01:40:00Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets right picture on the tree view item defined by path.","syntaxes":[{"syntax":"tvSetPictureRight [idc, path, name]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"name","type":"String","optional":false,"default":null,"description":"picture texture","types":["String"],"since":null,"text":"name: String - picture texture"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, name]","types":["Array"]}},{"syntax":"control tvSetPictureRight [path, name]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"name","type":"String","optional":false,"default":null,"description":"picture texture","types":["String"],"since":null,"text":"name: String - picture texture"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, name]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetPictureRight [101, [0], \"picture\"];\n```","code":["tvSetPictureRight [101, [0], \"picture\"];"]},{"text":"```sqf\n_ctrl tvSetPictureRight [[0], \"picture\"];\n```","code":["_ctrl tvSetPictureRight [[0], \"picture\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvPictureRight","tvSetPicture","tvPicture"],"notes":[{"user":"R3vo","date":"2021-04-05T12:14:00Z","text":"> [!NOTE]\n> Adding pictures to lists is very slow. In order to prevent the filling of the list to be slowed down, add the pictures in the **scheduled** environment.\n> One drawback of that method is, that sorting the entries is not easily possible.\n>\n> ```sqf\n> private _path = _ctrlTV tvAdd [[], \"Some Entry\"];\n> [_ctrlTV, _path] spawn\n> {\n>     (_this select 0) tvSetPictureRight [[_this select 1], \"someImage.paa\"];\n> };\n> ```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetPictureRightColor","operator":null,"title":"tvSetPictureRightColor","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureRightColor","revid":377790,"updated":"2026-01-03T01:40:04Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets color of the right picture on the tree view item defined by path","syntaxes":[{"syntax":"tvSetPictureRightColor [idc, path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, color]","types":["Array"]}},{"syntax":"control tvSetPictureRightColor [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetPictureRightColor [101, [0], [1,0,1,1]];\n```","code":["tvSetPictureRightColor [101, [0], [1,0,1,1]];"]},{"text":"```sqf\n_ctrl tvSetPictureRightColor [[0], [1,0,1,1]];\n```","code":["_ctrl tvSetPictureRightColor [[0], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureColorSelected","tvSetPictureColorDisabled","tvSetPictureRightColorSelected","tvSetPictureRightColorDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetPictureRightColorDisabled","operator":null,"title":"tvSetPictureRightColorDisabled","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureRightColorDisabled","revid":377789,"updated":"2026-01-03T01:40:03Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of the right picture of a tree item defined by path when item is disabled","syntaxes":[{"syntax":"control tvSetPictureRightColorDisabled [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetPictureRightColorDisabled [[0], [1,0,1,1]];\n```","code":["_control tvSetPictureRightColorDisabled [[0], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureColorSelected","tvSetPictureColorDisabled","tvSetPictureRightColor","tvSetPictureRightColorSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetPictureRightColorSelected","operator":null,"title":"tvSetPictureRightColorSelected","type":"command","url":"https://community.bistudio.com/wiki/tvSetPictureRightColorSelected","revid":377791,"updated":"2026-01-03T01:40:06Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the color of the right picture of a tree item defined by path when item is selected","syntaxes":[{"syntax":"control tvSetPictureRightColorSelected [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetPictureRightColorSelected [[0], [1,0,1,1]];\n```","code":["_control tvSetPictureRightColorSelected [[0], [1,0,1,1]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetValue","tvSort","tvSortByValue","tvValue","tvText","tvSetText","tvSetPicture","tvSetPictureColor","tvSetPictureRight","tvSetPictureColorSelected","tvSetPictureColorDisabled","tvSetPictureRightColor","tvSetPictureRightColorDisabled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"tvSetSelectColor","operator":null,"title":"tvSetSelectColor","type":"command","url":"https://community.bistudio.com/wiki/tvSetSelectColor","revid":377360,"updated":"2026-01-02T06:40:27Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the select color of given path.","syntaxes":[{"syntax":"ctrl tvSetSelectColor [path, color]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":"path of the item","types":["Array","Number"],"since":null,"text":"path: Array of Numbers - path of the item"},{"name":"color","type":null,"optional":false,"default":null,"description":"Color (RGBA)","types":["Color"],"since":null,"text":"color: Color (RGBA)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[path, color]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetSelectColor [[0, 0], [1,1,1,0.5]];\n```","code":["_control tvSetSelectColor [[0, 0], [1,1,1,0.5]];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSetColor"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"tvSetSelected","operator":null,"title":"tvSetSelected","type":"command","url":"https://community.bistudio.com/wiki/tvSetSelected","revid":378326,"updated":"2026-04-02T16:30:29Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the selection state of given treeview item in multi-select control.","syntaxes":[{"syntax":"control tvSetSelected [path, selected]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"selected","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"selected: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, selected]","types":["Array"]}}],"examples":[{"text":"```sqf\n_control tvSetSelected [[0], true];\n```","code":["_control tvSetSelected [[0], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSelection","tvIsSelected"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"tvSetText","operator":null,"title":"tvSetText","type":"command","url":"https://community.bistudio.com/wiki/tvSetText","revid":321506,"updated":"2022-05-17T11:22:38Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets string text to item on given path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvSetText [idc, path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, text]","types":["Array"]}},{"syntax":"control tvSetText [path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, text]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetText [101, [0], \"Test data\"];\n```","code":["tvSetText [101, [0], \"Test data\"];"]},{"text":"```sqf\n_ctrl tvSetText [[0,0,0], \"Test data\"];\n```","code":["_ctrl tvSetText [[0,0,0], \"Test data\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 1.56","Scripting Commands"]},{"name":"tvSetTooltip","operator":null,"title":"tvSetTooltip","type":"command","url":"https://community.bistudio.com/wiki/tvSetTooltip","revid":377817,"updated":"2026-01-03T04:13:45Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets the tooltip text associated with the specified tree view path.","syntaxes":[{"syntax":"tvSetTooltip [idc, path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"IDC of the tree view control","types":["Number"],"since":null,"text":"idc: Number - IDC of the tree view control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, text]","types":["Array"]}},{"syntax":"ctrl tvSetTooltip [path, text]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[path, text]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetTooltip [101, [0,2], \"This is a tooltip\"];\n```","code":["tvSetTooltip [101, [0,2], \"This is a tooltip\"];"]},{"text":"```sqf\n_tree tvSetTooltip [[0,2], \"This is a tooltip\"];\n```","code":["_tree tvSetTooltip [[0,2], \"This is a tooltip\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvTooltip","tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvSetValue","operator":null,"title":"tvSetValue","type":"command","url":"https://community.bistudio.com/wiki/tvSetValue","revid":321508,"updated":"2022-05-17T11:23:14Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Sets scalar data to item on given path. IDC means id of parent Tree View. If the given value is not integer, it will be converted to integer","syntaxes":[{"syntax":"tvSetValue [idc, path, val]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"},{"name":"val","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"val: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, val]","types":["Array"]}},{"syntax":"ctrl tvSetValue [path, val]","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"},{"name":"val","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"val: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"[path, val]","types":["Array"]}}],"examples":[{"text":"```sqf\ntvSetValue [101, [0], 555];\n```","code":["tvSetValue [101, [0], 555];"]},{"text":"```sqf\n_ctrl tvSetValue [[0,0,0], 14];\n```","code":["_ctrl tvSetValue [[0,0,0], 14];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvSort","operator":null,"title":"tvSort","type":"command","url":"https://community.bistudio.com/wiki/tvSort","revid":377597,"updated":"2026-01-02T07:01:07Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts all children of given path. Text of Tree View entries is used for sorting.","syntaxes":[{"syntax":"control tvSort [path, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"the parent item to sort","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - the parent item to sort"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"true to reverse sort it","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) true to reverse sort it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, reversed]","types":["Array"]}},{"syntax":"tvSort [idc, path, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control idc","types":["Number"],"since":null,"text":"idc: Number - control idc"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"the parent item to sort","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - the parent item to sort"},{"name":"reversed","type":"Boolean","optional":true,"default":"false","description":"true to reverse sort it","types":["Boolean"],"since":null,"text":"reversed: Boolean - (Optional, default false) true to reverse sort it"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, reversed]","types":["Array"]}}],"examples":[{"text":"```sqf\ncontrol tvSort [[0], true];\n```","code":["control tvSort [[0], true];"]},{"text":"```sqf\ntvSort [102, [0], true];\n```","code":["tvSort [102, [0], true];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","tvSortAll","tvSortByValue","tvSortByValueAll"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvSortAll","operator":null,"title":"tvSortAll","type":"command","url":"https://community.bistudio.com/wiki/tvSortAll","revid":377598,"updated":"2026-01-02T07:01:08Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts all children, including trees deriving from given path. Text of Tree View entries is used for sorting.","syntaxes":[{"syntax":"control tvSortAll [path, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"path to start sorting from","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - path to start sorting from"},{"name":"reversed","type":"Boolean","optional":false,"default":null,"description":"true to reverse sort it.","types":["Boolean"],"since":null,"text":"reversed: Boolean - true to reverse sort it."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, reversed]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl tvSortAll [[], false]; // sorts the complete Tree View\n```","code":["_ctrl tvSortAll [[], false]; // sorts the complete Tree View"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSort","tvSortByValue","tvSortByValueAll"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"tvSortByValue","operator":null,"title":"tvSortByValue","type":"command","url":"https://community.bistudio.com/wiki/tvSortByValue","revid":378381,"updated":"2026-04-04T04:47:06Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts all children of given path. Value of Tree View entries is used for sorting. tvSetValue can be used to set the value for a given path.","syntaxes":[{"syntax":"control tvSortByValue [path, ascending]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"the parent item to sort","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - the parent item to sort"},{"name":"ascending","type":"Boolean","optional":true,"default":"false","description":"true to sort ascending, else descending","types":["Boolean"],"since":null,"text":"ascending: Boolean - (Optional, default false) true to sort ascending, else descending"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, ascending]","types":["Array"]}},{"syntax":"tvSortByValue [idc, path, ascending]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"control idc","types":["Number"],"since":null,"text":"idc: Number - control idc"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"the parent item to sort","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - the parent item to sort"},{"name":"ascending","type":"Boolean","optional":true,"default":null,"description":"true to sort ascending, else descending. Default: false","types":["Boolean"],"since":null,"text":"ascending: Boolean - (Optional) true to sort ascending, else descending. Default: false"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, ascending]","types":["Array"]}}],"examples":[{"text":"```sqf\ncontrol tvSortByValue [[0], false];\n```","code":["control tvSortByValue [[0], false];"]},{"text":"```sqf\ntvSortByValue [102, [0], false];\n```","code":["tvSortByValue [102, [0], false];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["lbSortBy","lnbSortBy","tvSortAll","tvSort","tvSortByValueAll"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvSortByValueAll","operator":null,"title":"tvSortByValueAll","type":"command","url":"https://community.bistudio.com/wiki/tvSortByValueAll","revid":378327,"updated":"2026-04-02T16:30:32Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sorts all children, including trees deriving from given path.  Value of Tree View entries is used for sorting.","syntaxes":[{"syntax":"control tvSortByValueAll [path, reversed]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":"path to start sorting from","types":["Tree View Path"],"since":null,"text":"path: Tree View Path - path to start sorting from"},{"name":"reversed","type":"Boolean","optional":false,"default":null,"description":"true to reverse sort it.","types":["Boolean"],"since":null,"text":"reversed: Boolean - true to reverse sort it."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, reversed]","types":["Array"]}}],"examples":[{"text":"```sqf\n_ctrl tvSortByValueAll [[], false]; // Sorts the complete Tree View\n```","code":["_ctrl tvSortByValueAll [[], false]; // Sorts the complete Tree View"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSort","tvSortByValue","tvSortAll"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"tvText","operator":null,"title":"tvText","type":"command","url":"https://community.bistudio.com/wiki/tvText","revid":330021,"updated":"2022-08-15T14:44:30Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns shown text in the item on given path. IDC means id of parent Tree View.","syntaxes":[{"syntax":"tvText [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"control tvText path","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"```sqf\ntvText [101, [0]];\n```","code":["tvText [101, [0]];"]},{"text":"```sqf\n_ctrl tvText [0,0,0];\n```","code":["_ctrl tvText [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvValue","tvSetText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands"]},{"name":"tvTooltip","operator":null,"title":"tvTooltip","type":"command","url":"https://community.bistudio.com/wiki/tvTooltip","revid":377816,"updated":"2026-01-03T04:13:43Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Gets the tooltip text associated with the specified tree view path.","syntaxes":[{"syntax":"tvTooltip [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":"IDC of the tree view control","types":["Number"],"since":null,"text":"idc: Number - IDC of the tree view control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"tooltip text","text":"String - tooltip text"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"ctrl tvTooltip path","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"}],"returns":{"type":"String","types":["String"],"description":"tooltip text","text":"String - tooltip text"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"path","types":["Tree View Path"]}}],"examples":[{"text":"```sqf\n_text = tvTooltip [101, [0,2]];\n```","code":["_text = tvTooltip [101, [0,2]];"]},{"text":"```sqf\n_text = _treeCtrl tvTooltip [0,2];\n```","code":["_text = _treeCtrl tvTooltip [0,2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvSetTooltip","tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText","tvValue"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"tvValue","operator":null,"title":"tvValue","type":"command","url":"https://community.bistudio.com/wiki/tvValue","revid":347317,"updated":"2023-09-10T15:24:11Z","groups":["GUI Control - Tree View"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.74"}],"since":{"game":"arma3","name":"Arma 3","version":"0.74"},"arma3_since":"0.74","branch":null,"locality":{"argument":"local","effect":"local","server_exec":false},"exec":null,"description":"Returns numeric value set for given tree view path.","syntaxes":[{"syntax":"tvValue [idc, path]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":"set value; if no value was set, 0 is returned","text":"Number - set value; if no value was set, 0 is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path]","types":["Array"]}},{"syntax":"ctrl tvValue path","since":null,"effect":null,"exec":null,"params":[{"name":"ctrl","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"ctrl: Control"},{"name":"path","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"path: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":"set value; if no value was set, 0 is returned","text":"Number - set value; if no value was set, 0 is returned"},"form":"binary","operator":null,"left":{"text":"ctrl","types":["Control"]},"right":{"text":"path","types":["Array","Number"]}}],"examples":[{"text":"```sqf\ntvValue [101, [0]];\n```","code":["tvValue [101, [0]];"]},{"text":"```sqf\n_ctrl tvValue [0,0,0];\n```","code":["_ctrl tvValue [0,0,0];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["tvAdd","tvClear","tvCollapse","tvCount","tvCurSel","tvData","tvDelete","tvExpand","tvPicture","tvSetCurSel","tvSetData","tvSetPicture","tvSetValue","tvSort","tvSortByValue","tvText"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Tree View","Introduced with Arma 3 version 0.74","Scripting Commands","Scripting Commands: Local Effect"]},{"name":"type","operator":null,"title":"type","type":"command","url":"https://community.bistudio.com/wiki/type","revid":319936,"updated":"2022-05-13T09:25:45Z","groups":["Locations","Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.08"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.08"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a string of a Location's class name or Task's name (same as taskName).","syntaxes":[{"syntax":"type location","since":null,"effect":null,"exec":null,"params":[{"name":"location","type":"Location","optional":false,"default":null,"description":null,"types":["Location"],"since":null,"text":"location: Location"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"location","types":["Location"]}},{"syntax":"type task","since":null,"effect":null,"exec":null,"params":[{"name":"task","type":"Task","optional":false,"default":null,"description":null,"types":["Task"],"since":null,"text":"task: Task"}],"returns":{"type":"String","types":["String"],"description":"the type of the task","text":"String - the type of the task"},"form":"unary","operator":null,"left":null,"right":{"text":"task","types":["Task"]}}],"examples":[{"text":"```sqf\n_locationType = type myLocation;\n```","code":["_locationType = type myLocation;"]},{"text":"```sqf\n_taskName = type myTask;\n```","code":["_taskName = type myTask;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setType"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Command Group: Locations","Introduced with Armed Assault version 1.08","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"typeName","operator":null,"title":"typeName","type":"command","url":"https://community.bistudio.com/wiki/typeName","revid":379033,"updated":"2026-09-22T13:56:05Z","groups":["Variables"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the Data Type of an expression.\n\nThe type is returned as on of the following all-uppercase strings:\n- \"ARRAY\"\n- \"BOOL\"\n- \"CODE\"\n- \"CONFIG\"\n- \"CONTROL\"\n- \"DISPLAY\"\n- \"GROUP\"\n- \"OBJECT\"\n- \"SCALAR\" (and \"NaN\")\n- \"SCRIPT\"\n- \"SIDE\"\n- \"STRING\"\n- \"TEXT\"\n- Armed Assault v1.08 \"LOCATION\"\n- Arma 2 v1.00 \"TEAM_MEMBER\"\n- Arma 2 v1.00 \"NAMESPACE\"\n- Arma 2 v1.00 \"DIARY_RECORD\"\n- Arma 2 v1.00 \"TASK\"\n- Arma 3 v2.02 \"HASHMAP\"\n- Arma 3 v2.24 \"NetObject\"\nThey represent the available Data Types in Arma.\n\n> [!NOTE]\n> **Arma 3:** For type comparison, use isEqualType command instead.","syntaxes":[{"syntax":"typeName anything","since":null,"effect":null,"exec":null,"params":[{"name":"anything","type":"Anything","optional":false,"default":null,"description":null,"types":["Anything"],"since":null,"text":"anything: Anything"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"anything","types":["Anything"]}}],"examples":[{"text":"```sqf\n_msg = \"hello\"; _result = typeName _msg;  //_result will be \"STRING\"\n```","code":["_msg = \"hello\"; _result = typeName _msg;  //_result will be \"STRING\""]},{"text":"```sqf\n_unit = player; _result = typeName _unit; //_result becomes \"OBJECT\"\n```","code":["_unit = player; _result = typeName _unit; //_result becomes \"OBJECT\""]},{"text":"Values representing direct Data Types:\n\n```sqf\nhint typeName 0;                    // SCALAR\nhint typeName 1e39;                    // NaN\nhint typeName \"\";                    // STRING\nhint typeName true;                    // BOOL\nhint typeName [];                    // ARRAY\nhint typeName {};                    // CODE\nhint typeName scriptNull;            // SCRIPT (since Arma 3 v1.32)\nhint typeName objNull;                // OBJECT\nhint typeName grpNull;                // GROUP\nhint typeName controlNull;            // CONTROL\nhint typeName teamMemberNull;        // TEAM_MEMBER (since Arma 2 v1.00)\nhint typeName displayNull;            // DISPLAY\nhint typeName taskNull;                // TASK (since Arma 2 v1.00)\nhint typeName locationNull;            // LOCATION\nhint typeName sideUnknown;            // SIDE\nhint typeName text \"\";                // TEXT\nhint typeName configFile;            // CONFIG\nhint typeName configNull;            // CONFIG (since Arma 3 v1.54)\nhint typeName missionNamespace;        // NAMESPACE\nhint typeName diaryRecordNull;        // DIARY_RECORD (since Arma 3 v2.00)\nhint typeName createHashMap;        // HASHMAP (since Arma 3 v2.02)\nhint typeName netObjNull;            // NetObject (works as intended since Arma 3 v2.24)\n```","code":["hint typeName 0;\t\t\t\t\t// SCALAR\nhint typeName 1e39;\t\t\t\t\t// NaN\nhint typeName \"\";\t\t\t\t\t// STRING\nhint typeName true;\t\t\t\t\t// BOOL\nhint typeName [];\t\t\t\t\t// ARRAY\nhint typeName {};\t\t\t\t\t// CODE\nhint typeName scriptNull;\t\t\t// SCRIPT (since Arma 3 v1.32)\nhint typeName objNull;\t\t\t\t// OBJECT\nhint typeName grpNull;\t\t\t\t// GROUP\nhint typeName controlNull;\t\t\t// CONTROL\nhint typeName teamMemberNull;\t\t// TEAM_MEMBER (since Arma 2 v1.00)\nhint typeName displayNull;\t\t\t// DISPLAY\nhint typeName taskNull;\t\t\t\t// TASK (since Arma 2 v1.00)\nhint typeName locationNull;\t\t\t// LOCATION\nhint typeName sideUnknown;\t\t\t// SIDE\nhint typeName text \"\";\t\t\t\t// TEXT\nhint typeName configFile;\t\t\t// CONFIG\nhint typeName configNull;\t\t\t// CONFIG (since Arma 3 v1.54)\nhint typeName missionNamespace;\t\t// NAMESPACE\nhint typeName diaryRecordNull;\t\t// DIARY_RECORD (since Arma 3 v2.00)\nhint typeName createHashMap;\t\t// HASHMAP (since Arma 3 v2.02)\nhint typeName netObjNull;\t\t    // NetObject (works as intended since Arma 3 v2.24)"]},{"text":"```sqf\nif (typeName _this != \"ARRAY\") exitWith { hint \"_this is not an array!\" };\n// is the same as\nif (typeName _this != typeName []) exitWith { hint \"_this is not an array!\" };\n// same result but faster in Arma 3\nif !(_this isEqualType []) exitWith { hint \"_this is not an array!\" };\n```","code":["if (typeName _this != \"ARRAY\") exitWith { hint \"_this is not an array!\" };\n// is the same as\nif (typeName _this != typeName []) exitWith { hint \"_this is not an array!\" };\n// same result but faster in Arma 3\nif !(_this isEqualType []) exitWith { hint \"_this is not an array!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isEqualTypeAll","isEqualType","isEqualTypeParams","isEqualTypeArray","isEqualTypeAny","typeOf","isKindOf","isClass","isArray","isNumber","isText","isNil","isNull"],"notes":[{"user":"Killzone_Kid","date":"2016-09-25T11:14:00Z","text":"typeName of nil is `ANY`, however this is not possible to test as script command is just ignored when any argument is nil."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Variables","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"typeOf","operator":null,"title":"typeOf","type":"command","url":"https://community.bistudio.com/wiki/typeOf","revid":378246,"updated":"2026-03-21T09:42:52Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.90"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the class name of given target.","syntaxes":[{"syntax":"typeOf target","since":null,"effect":null,"exec":null,"params":[{"name":"target","type":"Object, since Arma 3 v2.22 Control, Display","optional":false,"default":null,"description":null,"types":["Object","Control","Display"],"since":null,"text":"target: Object, since Arma 3 v2.22 Control, Display"}],"returns":{"type":"String","types":["String"],"description":"config class name, or empty string if target does not have a class","text":"String - config class name, or empty string if *target* does not have a class"},"form":"unary","operator":null,"left":null,"right":{"text":"target","types":["Object","Control","Display"]}}],"examples":[{"text":"```sqf\nif (typeOf vehicle player == \"B_Heli_Light_01_armed_F\") then { hint \"Player is in a AH-9 Pawnee\"; };\n```","code":["if (typeOf vehicle player == \"B_Heli_Light_01_armed_F\") then { hint \"Player is in a AH-9 Pawnee\"; };"]},{"text":"```sqf\n// Since 2.22\ntypeOf (findDisplay 313); // \"Display3DEN\"\n```","code":["// Since 2.22\ntypeOf (findDisplay 313); // \"Display3DEN\""]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["countType","isKindOf","configOf","ctrlClassName"],"notes":[{"user":"Hardrock","date":"2006-08-04T12:03:00Z","text":"Try using this on an object pre-placed in the mission editor such as a house:\n\n```sqf\nhint typeOf _object; // Shows the class name (XXX)\n```\n\nNow place an object in the editor, save the map, and open up the Mission.sqm. Find the line: vehicle = \"XXX\", and replace XXX with the name of the object that you found above.\nSave it, and load the map. This method is no longer available since Armed Assault."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.90","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"UAVControl","operator":null,"title":"UAVControl","type":"command","url":"https://community.bistudio.com/wiki/UAVControl","revid":378036,"updated":"2026-01-27T09:56:36Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns array with current operator of UAV and his vehicle role in UAV.\nIf nobody is controlling the UAV, the command tries to find if player has terminal connected to this UAV.\nIf nobody is connected, objNull is used as returned operator (see #Example 2).\nThe possible outputs are:\n\n- [objNull, \"\"] - nobody is controlling UAV but there maybe an abandoned terminal connected to the UAV, which will auto-disconnect when a new connection to the UAV is made\n- [somePlayer1, \"DRIVER\"] - some player (could be remote) is a pilot, the gunner seat is empty\n- [somePlayer2, \"GUNNER\"] - some player (could be remote) is a gunner, the pilot seat is empty\n- [somePlayer1, \"DRIVER\", somePlayer2, \"GUNNER\"] - some players (could be remote) control both the pilot and the gunner seats\n- [player, \"\"] - local player has terminal connected to this UAV\n\nThe UAV terminals are local to the players so only local terminal connections are returned.\n\n> [!NOTE]\n> This command works only for vehicles, to get a unit remote-controlling a unit, see remoteControlled and remoteControl#Example 4.\n>\n> While main syntax can only return remote players when they are controlling either pilot or gunner, the alternative syntax can also return all remote players connected with terminals to given UAV.","syntaxes":[{"syntax":"UAVControl uav","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"}],"returns":{"type":"- Array with [unit, vehicleRole]","types":["Array"],"description":"unit: Object - UAV operator - vehicleRole: String - vehicle role of the operator in UAV. Can be \"DRIVER\", \"GUNNER\" or \"\" (not in control) - Arma 3 v1.96 Array with [unit, vehicleRole, unit2, vehicleRole2] (see #Example 2) - unit: Object - UAV operator - vehicleRole: String - vehicle role of the operator in UAV. Can be \"DRIVER\", \"GUNNER\" or \"\" (not in control) - unit2: Object - see #Example 2 - vehicleRole2: Can be \"DRIVER\", \"GUNNER\", or \"\". (see #Example 2)","text":"- Array with [unit, vehicleRole]\n  - unit: Object - UAV operator\n  - vehicleRole: String - vehicle role of the operator in UAV. Can be \"DRIVER\", \"GUNNER\" or \"\" (not in control)\n- Arma 3 v1.96 Array with [unit, vehicleRole, unit2, vehicleRole2] (see #Example 2)\n  - unit: Object - UAV operator\n  - vehicleRole: String - vehicle role of the operator in UAV. Can be \"DRIVER\", \"GUNNER\" or \"\" (not in control)\n  - unit2: Object - see #Example 2\n  - vehicleRole2: Can be \"DRIVER\", \"GUNNER\", or \"\". (see #Example 2)"},"form":"unary","operator":null,"left":null,"right":{"text":"uav","types":["Object"]}},{"syntax":"UAVControl [uav, option]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":"uav vehicle","types":["Object"],"since":null,"text":"uav: Object - uav vehicle"},{"name":"option","type":"String","optional":false,"default":null,"description":"output option, could be one of the following:\n\n- \"driver\" - player controlling UAV pilot\n- \"gunner\" - player controlling UAV gunner\n- \"crew\" - both driver and gunner in that order\n- \"all\" - all the players currently connected to the UAV with their terminals (dead players will show up until they are completely braindead (respawned for example))\n- \"allbutcrew\" - same as \"all\" but excluding driver and pilot\n- \"allbutdead\" - same as \"all\" but excluding dead players","types":["String"],"since":null,"text":"option: String - output option, could be one of the following:\n\n- \"driver\" - player controlling UAV pilot\n- \"gunner\" - player controlling UAV gunner\n- \"crew\" - both driver and gunner in that order\n- \"all\" - all the players currently connected to the UAV with their terminals (dead players will show up until they are completely braindead (respawned for example))\n- \"allbutcrew\" - same as \"all\" but excluding driver and pilot\n- \"allbutdead\" - same as \"all\" but excluding dead players"}],"returns":{"type":"Array","types":["Array"],"description":"[player1], [player1, player2] or [player1, player2,...playerN]","text":"Array - [player1], [player1, player2] or [player1, player2,...playerN]"},"form":"unary","operator":null,"left":null,"right":{"text":"[uav, option]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _result = UAVControl _myUAV;\n```","code":["private _result = UAVControl _myUAV;"]},{"text":"Since Arma 3 v1.96 this command returns both driver and gunner units if the UAV is controlled by 2 players. Here is the list of all expected outputs:\n\n```sqf\n[player1, \"DRIVER\"]; // player1 is controlling the UAV and is the pilot\n[player2, \"GUNNER\"]; // player2 is controlling the UAV and is the gunner\n[player1, \"DRIVER\", player2, \"GUNNER\"]; // player1 is controlling the UAV as the pilot, player2 is controlling the UAV as the gunner\n[player3, \"\"]; // no one is controlling the UAV, player3 is connected to the UAV via terminal, but not controlling it yet\n[objNull, \"\"]; // nobody is controlling but there maybe an abandoned terminal connected to the UAV, \n               // which will auto-disconnect when a new connection to the UAV is made\n```","code":["[player1, \"DRIVER\"]; // player1 is controlling the UAV and is the pilot\n[player2, \"GUNNER\"]; // player2 is controlling the UAV and is the gunner\n[player1, \"DRIVER\", player2, \"GUNNER\"]; // player1 is controlling the UAV as the pilot, player2 is controlling the UAV as the gunner\n[player3, \"\"]; // no one is controlling the UAV, player3 is connected to the UAV via terminal, but not controlling it yet\n[objNull, \"\"]; // nobody is controlling but there maybe an abandoned terminal connected to the UAV, \n               // which will auto-disconnect when a new connection to the UAV is made"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showUAVFeed","shownUAVFeed","allUnitsUAV","getConnectedUAV","connectTerminalToUAV","isUAVConnected","remoteControl","currentPilot","isRemoteControlling","remoteControlled"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"uiNamespace","operator":null,"title":"uiNamespace","type":"command","url":"https://community.bistudio.com/wiki/uiNamespace","revid":353040,"updated":"2024-03-12T11:58:15Z","groups":["Namespaces","Variables","GUI Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the global namespace attached to user interface.","syntaxes":[{"syntax":"uiNamespace","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Namespace","types":["Namespace"],"description":null,"text":"Namespace"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nuiNamespace setVariable [\"LIB_interruptDisplay\", _display];\n```","code":["uiNamespace setVariable [\"LIB_interruptDisplay\", _display];"]},{"text":"```sqf\nuiNamespace setVariable [\"myVar\", 46];\nwith uiNamespace do\n{\n    hint str myVar; // 46\n};\n```","code":["uiNamespace setVariable [\"myVar\", 46];\nwith uiNamespace do\n{\n\thint str myVar; // 46\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionNamespace","currentNamespace","parsingNamespace","profileNamespace","localNamespace","allVariables","with","do","ArmA: Editing"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control","Command Group: Namespaces","Command Group: Variables","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"uiSleep","operator":null,"title":"uiSleep","type":"command","url":"https://community.bistudio.com/wiki/uiSleep","revid":370497,"updated":"2024-12-26T17:41:42Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.05"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Suspend execution of script for given uiTime. uiSleep is a sleep method to delay script execution where script time/simulation time is stopped.\nuiSleep is basically using the system time (uiTime more specifically) and not simulation time.\nSo in the cases where sleep would get stuck indefinitely, uiSleep can still be used to effectively delay script execution for example in pause or in a mission briefing or an editor or when simulation is paused in general.","syntaxes":[{"syntax":"uiSleep delay","since":null,"effect":null,"exec":null,"params":[{"name":"delay","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"delay: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"delay","types":["Number"]}}],"examples":[{"text":"In singleplayer:\n\n```sqf\nsetAccTime 0.25;    // slows down time\nsleep 1;            // waits for 1 second in-game, 4 IRL seconds (1 / 0.25)\n\nsetAccTime 0;        // freezes simulation\n// sleep 1;            // would wait forever\nuiSleep 1;            // waits for 1 IRL second\n```","code":["setAccTime 0.25;\t// slows down time\nsleep 1;\t\t\t// waits for 1 second in-game, 4 IRL seconds (1 / 0.25)\n\nsetAccTime 0;\t\t// freezes simulation\n// sleep 1;\t\t\t// would wait forever\nuiSleep 1;\t\t\t// waits for 1 IRL second"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uiTime","sleep","waitUntil","canSuspend","spawn","execVM","Control Structures","sleep vs uiSleep"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Arma 2 version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"uiTime","operator":null,"title":"uiTime","type":"command","url":"https://community.bistudio.com/wiki/uiTime","revid":370498,"updated":"2024-12-26T17:46:41Z","groups":["Time","Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.20"}],"since":{"game":"arma3","name":"Arma 3","version":"2.20"},"arma3_since":"2.20","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns UI time elapsed since mission started (in seconds). Unlike time the uiTime does not stop when game is paused.","syntaxes":[{"syntax":"uiTime","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _future = uiTime + 30;\nwaitUntil { uiTime >= _future };  // continue after 30 seconds\n```","code":["private _future = uiTime + 30;\nwaitUntil { uiTime >= _future };  // continue after 30 seconds"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uiSleep","time","date","dayTime","serverTime","skipTime","accTime","dateToNumber","timeMultiplier","setTimeMultiplier","missionStart","diag_tickTime","diag_deltaTime","systemTime","systemTimeUTC","BIS_fnc_timeToString"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Command Group: Time","Introduced with Arma 3 version 2.20","Scripting Commands"]},{"name":"unassignCurator","operator":null,"title":"unassignCurator","type":"command","url":"https://community.bistudio.com/wiki/unassignCurator","revid":348367,"updated":"2023-11-08T12:59:54Z","groups":["Curator"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.16"}],"since":{"game":"arma3","name":"Arma 3","version":"1.16"},"arma3_since":"1.16","branch":null,"locality":{"argument":null,"effect":null,"server_exec":true},"exec":null,"description":"Unassign curator (will destroy both sides of connection).","syntaxes":[{"syntax":"unassignCurator curatorObj","since":null,"effect":null,"exec":null,"params":[{"name":"curatorObj","type":"Object","optional":false,"default":null,"description":"curator module.","types":["Object"],"since":null,"text":"curatorObj: Object - curator module."}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"curatorObj","types":["Object"]}}],"examples":[{"text":"```sqf\nunassignCurator myCurator;\n```","code":["unassignCurator myCurator;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Curator","addCuratorAddons","removeAllCuratorAddons","curatorAddons"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Curator","Introduced with Arma 3 version 1.16","Scripting Commands","Scripting Commands: Server Execution"]},{"name":"unassignItem","operator":null,"title":"unassignItem","type":"command","url":"https://community.bistudio.com/wiki/unassignItem","revid":353052,"updated":"2024-03-12T12:31:28Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Unassigns existing item and tries to put it into inventory. If there is no space in inventory the item simply disappears. See also unlinkItem.","syntaxes":[{"syntax":"unit unassignItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\n_bluforUnit unassignItem \"NVGoggles\";\n_bluforUnit removeItem \"NVGoggles\";\n_opforUnit unassignItem \"NVGoggles_OPFOR\";\n_opforUnit removeItem \"NVGoggles_OPFOR\";\n_independentUnit unassignItem \"NVGoggles_INDEP\";\n_independentUnit removeItem \"NVGoggles_INDEP\";\n```","code":["_bluforUnit unassignItem \"NVGoggles\";\n_bluforUnit removeItem \"NVGoggles\";\n_opforUnit unassignItem \"NVGoggles_OPFOR\";\n_opforUnit removeItem \"NVGoggles_OPFOR\";\n_independentUnit unassignItem \"NVGoggles_INDEP\";\n_independentUnit removeItem \"NVGoggles_INDEP\";"]},{"text":"```sqf\n{\n    _x unassignItem hmd _x; // unassign (not remove) NVGs from all units\n} forEach allUnits;\n```","code":["{\n\t_x unassignItem hmd _x; // unassign (not remove) NVGs from all units\n} forEach allUnits;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignItem","addItem","removeItem","linkItem","unlinkItem","assignedItems","removeAllAssignedItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"unassignTeam","operator":null,"title":"unassignTeam","type":"command","url":"https://community.bistudio.com/wiki/unassignTeam","revid":309954,"updated":"2022-05-05T12:17:00Z","groups":["Groups"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":null,"server_exec":false},"exec":null,"description":"Unassigns the unit (in the case of a vehicle its commander unit) from his team. This is equal to unit assignTeam \"MAIN\".","syntaxes":[{"syntax":"unassignTeam vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\nunassignTeam _soldier2;\n```","code":["unassignTeam _soldier2;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignTeam","dissolveTeam"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unassignVehicle","operator":null,"title":"unassignVehicle","type":"command","url":"https://community.bistudio.com/wiki/unassignVehicle","revid":363373,"updated":"2024-03-28T19:52:42Z","groups":["Object Manipulation","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Unassigns individual unit from a vehicle, usually previously assigned with *assignAsXXX* command, i.e removes assignedVehicleRole of the unit.\nIf the unit is currently in that vehicle, the group leader will issue an order to disembark.\n\n> [!NOTE]\n> See AI Group Vehicle Management for more information.","syntaxes":[{"syntax":"unassignVehicle unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nunassignVehicle player;\n```","code":["unassignVehicle player;"]},{"text":"Make all the occupants of a vehicle disembark:\n\n```sqf\n{ unassignVehicle _x } forEach crew _vehicle;\n```","code":["{ unassignVehicle _x } forEach crew _vehicle;"]},{"text":"Make all the occupants of a vehicle disembark and unable to get back in:\n\n```sqf\nprivate _crew = crew _vehicle;\n{ unassignVehicle _x } forEach _crew;\n_crew allowGetIn false;\n```","code":["private _crew = crew _vehicle;\n{ unassignVehicle _x } forEach _crew;\n_crew allowGetIn false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["assignAsCargo","assignAsCommander","assignAsDriver","assignAsGunner","assignAsTurret","assignedVehicle","leaveVehicle","assignedVehicles","assignedGroup","fullCrew"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Global Effect","Take On Helicopters: Scripting Commands"]},{"name":"underwater","operator":null,"title":"underwater","type":"command","url":"https://community.bistudio.com/wiki/underwater","revid":336959,"updated":"2023-01-04T16:44:17Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether the object is fully underwater.\n\n> [!NOTE]\n> This command works well with Arma 3 mini-submarines, which was most likely the primary design goal.","syntaxes":[{"syntax":"underwater object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"mini-submarine","types":["Object"],"since":null,"text":"object: Object - mini-submarine"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if submerged","text":"Boolean - true if submerged"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isUnderwater = underwater vehicle player;\n```","code":["private _isUnderwater = underwater vehicle player;"]},{"text":"```sqf\nprivate _isHeadUnderwater = eyePos player select 2 < 0;\n```","code":["private _isHeadUnderwater = eyePos player select 2 < 0;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isTouchingGround","isAbleToBreathe"],"notes":[{"user":"Killzone_Kid","date":"2017-02-02T18:08:00Z","text":"This command is quite buggy with objects other than mini-subs. Code in #Example 2 is a good alternative."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"uniform","operator":null,"title":"uniform","type":"command","url":"https://community.bistudio.com/wiki/uniform","revid":310875,"updated":"2022-05-07T20:24:10Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns name of uniform.","syntaxes":[{"syntax":"uniform unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_uniform = uniform _unit;\n```","code":["_uniform = uniform _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addUniform","forceAddUniform","isUniformAllowed","removeUniform","uniformContainer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"uniformContainer","operator":null,"title":"uniformContainer","type":"command","url":"https://community.bistudio.com/wiki/uniformContainer","revid":369268,"updated":"2024-09-03T18:42:43Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a cargo container of a unit's uniform.","syntaxes":[{"syntax":"uniformContainer unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":"cargo container, objNull if unit does not wear any uniform/clothing","text":"Object - cargo container, objNull if *unit* does not wear any uniform/clothing"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str uniformContainer player; //2df7dd00# 163941: dummyweapon.p3d\n```","code":["hint str uniformContainer player; //2df7dd00# 163941: dummyweapon.p3d"]},{"text":"```sqf\nhint str getMagazineCargo uniformContainer player;\n/*\n    returns e.g\n    [\n        [\"30Rnd_65x39_caseless_mag\"],\n        [3]\n    ]\n*/\n```","code":["hint str getMagazineCargo uniformContainer player;\n/*\n\treturns e.g\n\t[\n\t\t[\"30Rnd_65x39_caseless_mag\"],\n\t\t[3]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vestContainer","backpackContainer","everyContainer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"uniformItems","operator":null,"title":"uniformItems","type":"command","url":"https://community.bistudio.com/wiki/uniformItems","revid":377118,"updated":"2026-01-01T10:13:43Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all items (of any kind, even weapons) from uniform.","syntaxes":[{"syntax":"uniformItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"Class names of items","text":"Array of Strings - Class names of items"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nuniformItems player;\n// returns e.g\n/*\n[\n    \"FirstAidKit\",\n    \"30Rnd_65x39_caseless_mag\",\n    \"30Rnd_65x39_caseless_mag\",\n    \"30Rnd_65x39_caseless_mag\"\n]\n*/\n```","code":["uniformItems player;\n// returns e.g\n/*\n[\n\t\"FirstAidKit\",\n\t\"30Rnd_65x39_caseless_mag\",\n\t\"30Rnd_65x39_caseless_mag\",\n\t\"30Rnd_65x39_caseless_mag\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vestItems","backpackItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"uniformMagazines","operator":null,"title":"uniformMagazines","type":"command","url":"https://community.bistudio.com/wiki/uniformMagazines","revid":321373,"updated":"2022-05-14T10:55:55Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all magazines from uniform of the given unit.","syntaxes":[{"syntax":"uniformMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of String","types":["Array","String"],"description":null,"text":"Array of String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nuniformMagazines player;\n// returns e.g\n/*\n[\n    \"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:1/0](3x)\"\n]\n*/\n```","code":["uniformMagazines player;\n// returns e.g\n/*\n[\n\t\"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:1/0](3x)\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vestMagazines","backpackMagazines","soldierMagazines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"uniqueUnitItems","operator":null,"title":"uniqueUnitItems","type":"command","url":"https://community.bistudio.com/wiki/uniqueUnitItems","revid":310366,"updated":"2022-05-05T17:43:22Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns hashmap of all items in units inventory as [classname, count] pairs.\n\n> [!NOTE]\n> - *weaponItems*, *uniformItems*, *vestItems*, *backpackItems* arguments use the following Number values:\n>   - 0: do not return value\n>   - 1: returns container only (weapon or container)\n>   - 2: returns container and its content\n> - weapons/containers that are stored inside containers (e.g weapon in backpack) always return all contents if contents for the parent container are enabled.","syntaxes":[{"syntax":"uniqueUnitItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"HashMap in format itemClassname (String) → amount (Number)","types":["HashMap","String","Number"],"description":null,"text":"HashMap in format itemClassname (String) → amount (Number)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"uniqueUnitItems [unit, weaponsItems, uniformItems, vestItems, backpackItems, assignedItems]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weaponsItems","type":"Number","optional":true,"default":"2","description":"weapons (including binoculars) and their accessories (flashlight etc), loaded magazines","types":["Number"],"since":null,"text":"weaponsItems: Number - (Optional, default 2) weapons (including binoculars) and their accessories (flashlight etc), loaded magazines"},{"name":"uniformItems","type":"Number","optional":true,"default":"2","description":null,"types":["Number"],"since":null,"text":"uniformItems: Number - (Optional, default 2)"},{"name":"vestItems","type":"Number","optional":true,"default":"2","description":null,"types":["Number"],"since":null,"text":"vestItems: Number - (Optional, default 2)"},{"name":"backpackItems","type":"Number","optional":true,"default":"2","description":null,"types":["Number"],"since":null,"text":"backpackItems: Number - (Optional, default 2)"},{"name":"assignedItems","type":"Boolean","optional":true,"default":"true","description":"returns assignedItems as well as headgear and goggles","types":["Boolean"],"since":null,"text":"assignedItems: Boolean - (Optional, default true) returns assignedItems as well as headgear and goggles"}],"returns":{"type":"HashMap in format itemClassname (String) → amount (Number)","types":["HashMap","String","Number"],"description":null,"text":"HashMap in format itemClassname (String) → amount (Number)"},"form":"unary","operator":null,"left":null,"right":{"text":"[unit, weaponsItems, uniformItems, vestItems, backpackItems, assignedItems]","types":["Array"]}}],"examples":[{"text":"```sqf\nprivate _unitUniqueItems = uniqueUnitItems [player, 0, 2, 2, 2, true];\nif (_unitUniqueItems getOrDefault [\"FirstAidKit\", 0] > 5) then { hint \"I'm rich of FAK to give!\"; };\n```","code":["private _unitUniqueItems = uniqueUnitItems [player, 0, 2, 2, 2, true];\nif (_unitUniqueItems getOrDefault [\"FirstAidKit\", 0] > 5) then { hint \"I'm rich of FAK to give!\"; };"]},{"text":"```sqf\nprivate _unitUniqueItems = uniqueUnitItems [cursorObject];\n```","code":["private _unitUniqueItems = uniqueUnitItems [cursorObject];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getUnitLoadout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"unitAddons","operator":null,"title":"unitAddons","type":"command","url":"https://community.bistudio.com/wiki/unitAddons","revid":378475,"updated":"2026-04-24T11:31:38Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns list with addons the unit belongs to.","syntaxes":[{"syntax":"unitAddons className","since":null,"effect":null,"exec":null,"params":[{"name":"className","type":"String","optional":false,"default":null,"description":"class name of a unit/vehicle or object","types":["String"],"since":null,"text":"className: String - class name of a unit/vehicle or object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"addon names","text":"Array of Strings - addon names"},"form":"unary","operator":null,"left":null,"right":{"text":"className","types":["String"]}}],"examples":[{"text":"```sqf\nhint str unitAddons typeOf player; // [\"A3_Characters_F_BLUFOR\"]\n```","code":["hint str unitAddons typeOf player; // [\"A3_Characters_F_BLUFOR\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["activateAddons"],"notes":[{"user":"ffur2007slx2_5","date":"2014-03-31T23:38:00Z","text":"1. From Arma 3 1.14 \n\n```sqf\nhint str ([player] call BIS_fnc_unitAddon) // same as unitAddons (typeOf player)\n```\n\n1. To return the addon that a weapon belongs to, use BIS_fnc_weaponAddon instead. E.g. \n\n```sqf\n(primaryWeapon player call BIS_fnc_weaponAddon); // return: \"A3_Weapons_F_Rifles_Khaybar\"\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"unitAimPosition","operator":null,"title":"unitAimPosition","type":"command","url":"https://community.bistudio.com/wiki/unitAimPosition","revid":378159,"updated":"2026-02-26T16:15:33Z","groups":["Object Manipulation","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the position on the unit other units can aim at. Same as aimPos only returns position in PositionAGL format and has render scope alternative unitAimPositionVisual.","syntaxes":[{"syntax":"unitAimPosition unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":null,"text":"PositionAGL"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _aimPosAGL = unitAimPosition player;\n```","code":["private _aimPosAGL = unitAimPosition player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitAimPositionVisual","aimPos","eyePos","getPosASL","weaponDirection"],"notes":[{"user":"Sa-Matra","date":"2023-03-27T12:33:27Z","text":"This command uses \"zamerny\" memory point which is hardcoded name in the engine. If memory point is not present then geometry LOD bounding center is used (according to dedmen)"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Positions","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"unitAimPositionVisual","operator":null,"title":"unitAimPositionVisual","type":"command","url":"https://community.bistudio.com/wiki/unitAimPositionVisual","revid":377836,"updated":"2026-01-03T04:32:14Z","groups":["Object Manipulation","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the position on the unit other units can aim at in render scope. See also aimPos, unitAimPosition.","syntaxes":[{"syntax":"unitAimPositionVisual unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":"position","text":"PositionAGL - position"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nunitAimPositionVisual player;\n```","code":["unitAimPositionVisual player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["unitAimPosition","aimPos","eyePos","getPosASL","weaponDirection"],"notes":[{"user":"Sa-Matra","date":"2023-04-30T11:44:58Z","text":"This command (along with unitAimPosition and aimPos) is unreliable when entity has objectParent, it can return its last position in the world in case of static weapon packed into backpack, or can return very outdated (lagging behind) position or even [0,0,0] on remote units inside vehicles. Be careful when using it!"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Render Time Scope","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"unitBackpack","operator":null,"title":"unitBackpack","type":"command","url":"https://community.bistudio.com/wiki/unitBackpack","revid":341213,"updated":"2023-05-13T22:52:01Z","groups":["Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns unit's backpack","syntaxes":[{"syntax":"unitBackpack unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _myBackpack = unitBackpack player;\n```","code":["private _myBackpack = unitBackpack player;"]},{"text":"```sqf\nclearMagazineCargo unitBackpack player;\n```","code":["clearMagazineCargo unitBackpack player;"]},{"text":"```sqf\nplayer action [\"gear\", unitBackpack player];\n```","code":["player action [\"gear\", unitBackpack player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["backpackContainer","firstBackpack","backpack","backpackCargo","getBackpackCargo","backpackItems","addBackpack","addBackpackCargo","addBackpackCargoGlobal","removeBackpack","clearBackpackCargo","clearBackpackCargoGlobal","clearAllItemsFromBackpack","loadBackpack","backpackSpaceFor","canAddItemToBackpack","addItemToBackpack","removeItemFromBackpack","everyBackpack"],"notes":[{"user":"ffur2007slx2_5","date":"2014-04-29T15:49:00Z","text":"In Arma 3 ver 1.16, we can use either backpackContainer or unitBackpack at present since both of them enjoy same operand type and return value."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Introduced with Arma 2: Operation Arrowhead version 1.50","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unitCombatMode","operator":null,"title":"unitCombatMode","type":"command","url":"https://community.bistudio.com/wiki/unitCombatMode","revid":309924,"updated":"2022-05-05T12:16:58Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.02"}],"since":{"game":"arma3","name":"Arma 3","version":"2.02"},"arma3_since":"2.02","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets individual unit's combat mode. For more information see setUnitCombatMode.","syntaxes":[{"syntax":"unitCombatMode unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nunitCombatMode _unit;\n```","code":["unitCombatMode _unit;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitCombatMode","setCombatMode","combatMode"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 2.02","Scripting Commands"]},{"name":"unitIsUAV","operator":null,"title":"unitIsUAV","type":"command","url":"https://community.bistudio.com/wiki/unitIsUAV","revid":338990,"updated":"2023-04-23T07:34:22Z","groups":["Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether or not the given transport object is a drone (UAV, UGV), regardless of if it has a crew or if it is empty,\ncorresponding to the `isUAV` transport parameter.\n\nArma 3 v2.14 The command can be used to check if the provided unit is a UAV unit.","syntaxes":[{"syntax":"unitIsUAV object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"vehicle or Arma 3 v2.14 unit","types":["Object"],"since":null,"text":"object: Object - vehicle or Arma 3 v2.14 unit"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true when UAV","text":"Boolean - true when UAV"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nunitIsUAV _myUAV;            // true (whether it has driver/gunner or not)\nunitIsUAV driver _myUAV;    // true (provided there is a driver)\nunitIsUAV gunner _myUAV;    // true (provided there is a gunner)\n```","code":["unitIsUAV _myUAV;\t\t\t// true (whether it has driver/gunner or not)\nunitIsUAV driver _myUAV;\t// true (provided there is a driver)\nunitIsUAV gunner _myUAV;\t// true (provided there is a gunner)"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUnitsUAV"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"unitPos","operator":null,"title":"unitPos","type":"command","url":"https://community.bistudio.com/wiki/unitPos","revid":337059,"updated":"2023-01-11T09:38:30Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Return the unit position rules.\n\nThe return value is always \"Auto\" unless the unit has gotten a setUnitPos command. In that case the value is the last stance the unit was ordered to.\n\nAvailable modes are listed at setUnitPos.","syntaxes":[{"syntax":"unitPos unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":"one of `\"Auto\"`, `\"Up\"`, `\"Middle\"`, `\"Down\"` (as of Arma 3)","text":"String - one of `\"Auto\"`, `\"Up\"`, `\"Middle\"`, `\"Down\"` (as of Arma 3)"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str unitPos _unit;\n```","code":["hint str unitPos _unit;"]}],"multiplayer":"Unit pos set by setUnitPosWeak is not returned for remote (non-local) units.","problems":null,"aliases":[],"see_also":["setUnitPos","setUnitPosWeak","stance","pose"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unitReady","operator":null,"title":"unitReady","type":"command","url":"https://community.bistudio.com/wiki/unitReady","revid":378263,"updated":"2026-03-26T16:51:08Z","groups":["Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if the unit is ready. Unit is busy when it is given some command like move, until the command is finished.","syntaxes":[{"syntax":"unitReady unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unitName: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _isReady = unitReady _soldierOne;\n```","code":["private _isReady = unitReady _soldierOne;"]},{"text":"```sqf\nif (not unitReady _soldierOne) then\n{\n    _soldierOne groupChat \"Wait one, sarge!\";\n};\n```","code":["if (not unitReady _soldierOne) then\n{\n\t_soldierOne groupChat \"Wait one, sarge!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["move"],"notes":[{"user":"Rübe","date":"2010-08-26T03:55:00Z","text":"Keep in mind that\n- dead units are unitReady\n- it takes a while until it get's known to group members that a unit is not alive anymore, which leads to\n- the current leader of a group might be actually dead (until another group member takes command).\nWhy this is important? I'll give you an example: if you're using unitReady as a condition inside one of your fsm to advance whatever the fsm/group is doing, you really might wanna check that this unit is actually still alive. Otherwise you might end up with really fast and nasty loops in your FSM, eventually accompanied by a stream of radio commands that will last until finally a living leader is in command again.. and that could take a while... nasty, I tell you :)"},{"user":"Rübe","date":"2011-01-17T20:27:00Z","text":"Regarding vehicles, there is only one single unit (from the vehicle crew) whose unitReady-status is affected by giving that vehicle (or that unit) commands.\nWhile it is the driver unit for a truck, it is the gunner unit for a mg-jeep or the commander for a tank. Generally it is always the unit \"in control\" of the vehicle.\n(because it is only that unit, that is seen as \"full unit\" to the \"outside world\". Only he can be adressed with commands.)\n\nIn consequence you can't just send vehicles around and check if they've arrived with something like:\n\n```sqf\nwaitUntil { unitReady driver _vehicle }; // don't do this!\n```\n\nBecause it is *not guaranteed that the driver is in command of the vehicle* and only that unit will have its unitReady status affected.\n\nSo in conclusion, **if you need to check if a vehicle is ready**, try something like this:\n\n```sqf\n_vehicleReady = {\n    private [\"_veh\", \"_ready\"];\n    _veh = _this;\n    _ready = true;\n    {\n        if (not isNull _x) then\n        {\n            _ready = _ready && (unitReady _x);\n        };\n    } forEach [\n        commander _veh,\n        gunner _veh,\n        driver _veh\n    ];\n    _ready\n};\n```"},{"user":"Kastenbier","date":"2015-11-21T22:40:00Z","text":"To check readiness of a vehicle, don't check its crew, driver, gunner, commander, etc., but the vehicle itself, e.g.:\n\n```sqf\nunitReady _yourVehicle;\n```\n\nOnly tested 11/21/2015 by me with A2 1.63.131129 and A3 1.52.132676 but possibly true since 1964. :P"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unitRecoilCoefficient","operator":null,"title":"unitRecoilCoefficient","type":"command","url":"https://community.bistudio.com/wiki/unitRecoilCoefficient","revid":364133,"updated":"2024-05-04T22:15:43Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns recoil coefficient of a soldier.","syntaxes":[{"syntax":"unitRecoilCoefficient soldier","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"soldier","types":["Object"]}}],"examples":[{"text":"```sqf\n_myRecoil = unitRecoilCoefficient player;\n```","code":["_myRecoil = unitRecoilCoefficient player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setUnitRecoilCoefficient"],"notes":[{"user":"AgentRev01","date":"2013-09-07T20:55:00Z","text":"If the unit doesn't exist / is null, -1 is returned."}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"units","operator":null,"title":"units","type":"command","url":"https://community.bistudio.com/wiki/units","revid":340313,"updated":"2023-04-29T17:06:31Z","groups":["Groups","Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with all the units in the group or unit's group, or all units belonging to a certain side.","syntaxes":[{"syntax":"units type","since":null,"effect":null,"exec":null,"params":[{"name":"type","type":"Group, Object or Arma 3 v2.02 Side","optional":false,"default":null,"description":null,"types":["Group","Object","Side"],"since":null,"text":"type: Group, Object or Arma 3 v2.02 Side"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":"if type is a destroyed object, an empty array is returned","text":"Array of Objects - if *type* is a destroyed object, an empty array is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"type","types":["Group","Object","Side"]}}],"examples":[{"text":"```sqf\n_myUnitCount = count units player;\n```","code":["_myUnitCount = count units player;"]},{"text":"```sqf\n_isInMyGroup = _soldier1 in units player;\n```","code":["_isInMyGroup = _soldier1 in units player;"]},{"text":"```sqf\nprivate _unitsEast = units opfor;\n```","code":["private _unitsEast = units opfor;"]},{"text":"```sqf\n// both methods are the same, the latter is preferred for performance reason\nunits group player;        // [B Alpha 1-1:1 (R3vo), B Alpha 1-1:2, B Alpha 1-1:3, B Alpha 1-1:4, B Alpha 1-1:5, B Alpha 1-1:6, B Alpha 1-1:7, B Alpha 1-1:8]\nunits player;            // [B Alpha 1-1:1 (R3vo), B Alpha 1-1:2, B Alpha 1-1:3, B Alpha 1-1:4, B Alpha 1-1:5, B Alpha 1-1:6, B Alpha 1-1:7, B Alpha 1-1:8]\n```","code":["// both methods are the same, the latter is preferred for performance reason\nunits group player;\t\t// [B Alpha 1-1:1 (R3vo), B Alpha 1-1:2, B Alpha 1-1:3, B Alpha 1-1:4, B Alpha 1-1:5, B Alpha 1-1:6, B Alpha 1-1:7, B Alpha 1-1:8]\nunits player;\t\t\t// [B Alpha 1-1:1 (R3vo), B Alpha 1-1:2, B Alpha 1-1:3, B Alpha 1-1:4, B Alpha 1-1:5, B Alpha 1-1:6, B Alpha 1-1:7, B Alpha 1-1:8]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["group","allGroups","groups","allUnits","playableUnits","switchableUnits","vehicles"],"notes":[{"user":"Kronzky","date":"2009-09-25T01:03:00Z","text":"The returned array on MP clients is not updated when team members die (only when they are deleted). (*Tested on VBS2*)"},{"user":"Ilias38rus","date":"2020-07-03T03:36:00Z","text":"Seems to always return a list with the same order as the leader's squad menu."}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Groups","Command Group: Object Detection","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unitsBelowHeight","operator":null,"title":"unitsBelowHeight","type":"command","url":"https://community.bistudio.com/wiki/unitsBelowHeight","revid":325197,"updated":"2022-07-01T14:53:08Z","groups":["Object Detection","Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.04"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns units in group/array below given Above Terrain Level (ATL) altitude.\n\n> [!NOTE]\n> an object's ATL altitude can be found with `_altitude = (getPosATL _obj) select 2;`.","syntaxes":[{"syntax":"units unitsBelowHeight height","since":null,"effect":null,"exec":null,"params":[{"name":"units","type":"Array of Objects","optional":false,"default":null,"description":null,"types":["Array","Object"],"since":null,"text":"units: Array of Objects"},{"name":"height","type":"Number","optional":false,"default":null,"description":"height above terrain level (PositionATL)","types":["Number"],"since":null,"text":"height: Number - height above terrain level (PositionATL)"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"units","types":["Array","Object"]},"right":{"text":"height","types":["Number"]}},{"syntax":"group unitsBelowHeight height","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":"AI group","types":["Group"],"since":null,"text":"group: Group - AI group"},{"name":"height","type":"Number","optional":false,"default":null,"description":"height above terrain level (PositionATL)","types":["Number"],"since":null,"text":"height: Number - height above terrain level (PositionATL)"}],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"binary","operator":null,"left":{"text":"group","types":["Group"]},"right":{"text":"height","types":["Number"]}}],"examples":[{"text":"```sqf\n_allOnGroudUnits = group player unitsBelowHeight 10;\n```","code":["_allOnGroudUnits = group player unitsBelowHeight 10;"]},{"text":"```sqf\n_units = allUnits unitsBelowHeight 30;\n```","code":["_units = allUnits unitsBelowHeight 30;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allUnits","getPosATL","group"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Command Group: Positions","Introduced with Arma 2 version 1.04","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unitTurret","operator":null,"title":"unitTurret","type":"command","url":"https://community.bistudio.com/wiki/unitTurret","revid":377504,"updated":"2026-01-02T06:49:34Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the turret path the given vehicle's gunner is in.\nTo get the turret's unit see turretUnit.","syntaxes":[{"syntax":"vehicle unitTurret gunner","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"gunner","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"gunner: Object"}],"returns":{"type":"Turret Path","types":["Turret Path"],"description":"`[-1]` is returned if the gunner is also the driver. When no units are in any of vehicle's turret, empty array `[]` is returned.","text":"Turret Path\n- `[-1]` is returned if the gunner is also the driver.\nWhen no units are in any of vehicle's turret, empty array `[]` is returned."},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"gunner","types":["Object"]}}],"examples":[{"text":"```sqf\n_vehicle unitTurret _gunner;\n```","code":["_vehicle unitTurret _gunner;"]},{"text":"```sqf\nvehicle player unitTurret player;\n```","code":["vehicle player unitTurret player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["turretUnit","driver","gunner","commander","effectiveCommander","currentPilot","moveInTurret","assignAsTurret","assignedVehicleRole","lockedTurret","isTurnedOut"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"unlinkItem","operator":null,"title":"unlinkItem","type":"command","url":"https://community.bistudio.com/wiki/unlinkItem","revid":378286,"updated":"2026-03-31T13:01:41Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":"global","effect":"global","server_exec":false},"exec":null,"description":"Unassign and delete existing item from its assigned slot. Nothing happens if the item does not exist or is not assigned. See also unassignItem.","syntaxes":[{"syntax":"unit unlinkItem item","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"item","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"item: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"item","types":["String"]}}],"examples":[{"text":"```sqf\nbluforUnit unlinkItem \"NVGoggles\";\nopforUnit unlinkItem \"NVGoggles_OPFOR\";\nindepUnit unlinkItem \"NVGoggles_INDEP\";\n\n// or\n{ _x unlinkItem hmd _x } forEach [bluforUnit, opforUnit, indepUnit];\n```","code":["bluforUnit unlinkItem \"NVGoggles\";\nopforUnit unlinkItem \"NVGoggles_OPFOR\";\nindepUnit unlinkItem \"NVGoggles_INDEP\";\n\n// or\n{ _x unlinkItem hmd _x } forEach [bluforUnit, opforUnit, indepUnit];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["linkItem","addItem","assignItem","removeItem","unassignItem","assignedItems","removeAllAssignedItems"],"notes":[{"user":"Killzone_Kid","date":"2018-10-15T14:46:00Z","text":"With this command you can also unlink vest, uniform and headgear."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 1.00","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"unlockAchievement","operator":null,"title":"unlockAchievement","type":"command","url":"https://community.bistudio.com/wiki/unlockAchievement","revid":364204,"updated":"2024-05-05T11:07:39Z","groups":["Broken Commands","System"],"status":"broken","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unlocks the given achievement. The achievements are listed in CfgAchievements, however none of the currently listed achievements is used in Arma 3, hence the command always returns false.\n\n> [!IMPORTANT]\n> This command is obsolete and was used in the experimental (unreleased) Arma 2 Xbox 360 version as stated\n> [here](https://forums.bohemia.net/forums/topic/187873-unlockachievment-command/?tab=comments#comment-2978436).\n\n> [!NOTE]\n> **Arma 3:** To unlock a Steam Achievement for Arma 3, see setStatValue.","syntaxes":[{"syntax":"unlockAchievement name","since":null,"effect":null,"exec":null,"params":[{"name":"name","type":"String","optional":false,"default":null,"description":"achievement name","types":["String"],"since":null,"text":"name: String - achievement name"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if achievement was unlocked","text":"Boolean - true if achievement was unlocked"},"form":"unary","operator":null,"left":null,"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\n_isUnlocked = unlockAchievement \"Hunter\";\n```","code":["_isUnlocked = unlockAchievement \"Hunter\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setStatValue"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Broken Commands","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"unregisterTask","operator":null,"title":"unregisterTask","type":"command","url":"https://community.bistudio.com/wiki/unregisterTask","revid":376348,"updated":"2025-10-07T17:06:51Z","groups":["Briefing"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unregisters a task type from given agent. The task type is the name given in `CfgTasks` classes in `name` property. Also available from registeredTasks array.","syntaxes":[{"syntax":"teamMember unregisterTask name","since":null,"effect":null,"exec":null,"params":[{"name":"teamMember","type":"Team Member","optional":false,"default":null,"description":"teamMember agent","types":["Team Member"],"since":null,"text":"teamMember: Team Member - teamMember agent"},{"name":"name","type":"String","optional":false,"default":null,"description":"name of the task","types":["String"],"since":null,"text":"name: String - name of the task"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true on success","text":"Boolean - true on success"},"form":"binary","operator":null,"left":{"text":"teamMember","types":["Team Member"]},"right":{"text":"name","types":["String"]}}],"examples":[{"text":"```sqf\nteamMember _agent unregisterTask ((registeredTasks _agent) select 0);\n```","code":["teamMember _agent unregisterTask ((registeredTasks _agent) select 0);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["registerTask","registeredTasks","sendTask","createTask","currentTasks","taskCompleted"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Briefing","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"updateDrawIcon","operator":null,"title":"updateDrawIcon","type":"command","url":"https://community.bistudio.com/wiki/updateDrawIcon","revid":363252,"updated":"2024-03-26T10:51:27Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Updates the icon to be shown in 2D editor for the specified editor,object. If maintain size is false,icon will not scale depending on the,scale of the map. If maintain size is a number,the icon will maintain,size if map scale is below that number.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map updateDrawIcon [object,string identifier,color,offset,width,height,maintain size?,angle,shadow]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"[object,string identifier,color,offset,width,height,maintain size?,angle,shadow]: Array","type":null,"optional":false,"default":null,"description":null,"types":["Array"],"since":null,"text":"[object,string identifier,color,offset,width,height,maintain size?,angle,shadow]: Array"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[object,string identifier,color,offset,width,height,maintain size?,angle,shadow]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"updateMenuItem","operator":null,"title":"updateMenuItem","type":"command","url":"https://community.bistudio.com/wiki/updateMenuItem","revid":363582,"updated":"2024-04-07T14:51:54Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets the text and command for the menu item. Index is index returned by addMenuItem command. Command is optional.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"map updateMenuItem [menu item index, text, command]","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"},{"name":"menu item index","type":"Number","optional":false,"default":null,"description":"See addMenuItem","types":["Number"],"since":null,"text":"menu item index: Number - See addMenuItem"},{"name":"text","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"text: String"},{"name":"command","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"command: String"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"map","types":["Control"]},"right":{"text":"[menu item index, text, command]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"updateObjectTree","operator":null,"title":"updateObjectTree","type":"command","url":"https://community.bistudio.com/wiki/updateObjectTree","revid":363283,"updated":"2024-03-26T10:51:53Z","groups":["Game 2 Editor"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Update the editor object tree.\n\n> [!NOTE]\n> Some Old Editor Command","syntaxes":[{"syntax":"updateObjectTree map","since":null,"effect":null,"exec":null,"params":[{"name":"map","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"map: Control"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"map","types":["Control"]}}],"examples":[{"text":"```sqf\nupdateObjectTree _ctrlMap;\n```","code":["updateObjectTree _ctrlMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":[],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Game 2 Editor","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"useAIOperMapObstructionTest","operator":null,"title":"useAIOperMapObstructionTest","type":"command","url":"https://community.bistudio.com/wiki/useAIOperMapObstructionTest","revid":310172,"updated":"2022-05-05T13:10:25Z","groups":["System"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":"diag","locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Toggle secondary obstruction test on road paths.","syntaxes":[{"syntax":"useAIOperMapObstructionTest state","since":null,"effect":null,"exec":null,"params":[{"name":"state","type":"Boolean","optional":false,"default":null,"description":"true to enable, false to disable","types":["Boolean"],"since":null,"text":"state: Boolean - true to enable, false to disable"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"state","types":["Boolean"]}}],"examples":[{"text":"```sqf\nuseAIOperMapObstructionTest true;\n```","code":["useAIOperMapObstructionTest true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceFollowRoad","setDriveOnPath","setConvoySeparation"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Arma 3: Scripting Commands: Diagnostic Branch","Command Group: System","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"useAISteeringComponent","operator":null,"title":"useAISteeringComponent","type":"command","url":"https://community.bistudio.com/wiki/useAISteeringComponent","revid":352369,"updated":"2024-02-08T14:10:38Z","groups":["AI Behaviour"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":"local","effect":"global","server_exec":false},"exec":null,"description":"Enable the new , used to test the old and new AI driving.\n\n> [!IMPORTANT]\n> setDriveOnPath does not work if the vehicle doesn't have an AI steering component or if it's disabled.","syntaxes":[{"syntax":"useAISteeringComponent enabled","since":null,"effect":null,"exec":null,"params":[{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"enabled","types":["Boolean"]}},{"syntax":"vehicle useAISteeringComponent enabled","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"the vehicle to enable/disable the feature for","types":["Object"],"since":null,"text":"vehicle: Object - the vehicle to enable/disable the feature for"},{"name":"enabled","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"enabled: Boolean"}],"returns":{"type":"","types":[],"description":null,"text":""},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"enabled","types":["Boolean"]}}],"examples":[{"text":"```sqf\nuseAISteeringComponent true;\n```","code":["useAISteeringComponent true;"]},{"text":"```sqf\nmyTank useAISteeringComponent false;\n```","code":["myTank useAISteeringComponent false;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isUsingAISteeringComponent","isAISteeringComponentEnabled","sendSimpleCommand","enableAI","disableAI","enableAIFeature","vehicleMoveInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: AI Behaviour","Introduced with Arma 3 version 1.60","Scripting Commands","Scripting Commands: Global Effect"]},{"name":"useAudioTimeForMoves","operator":null,"title":"useAudioTimeForMoves","type":"command","url":"https://community.bistudio.com/wiki/useAudioTimeForMoves","revid":340963,"updated":"2023-05-13T22:02:53Z","groups":["Animations"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Switch between elapsed game time and audio time being used as animation timer. Used for audio/animation synchronization.","syntaxes":[{"syntax":"soldier useAudioTimeForMoves toggle","since":null,"effect":null,"exec":null,"params":[{"name":"soldier","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"soldier: Object"},{"name":"toggle","type":"Boolean","optional":false,"default":null,"description":null,"types":["Boolean"],"since":null,"text":"toggle: Boolean"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"soldier","types":["Object"]},"right":{"text":"toggle","types":["Boolean"]}}],"examples":[{"text":"```sqf\nplayer useAudioTimeForMoves true;\n```","code":["player useAudioTimeForMoves true;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setAccTime","accTime"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Animations","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"userInputDisabled","operator":null,"title":"userInputDisabled","type":"command","url":"https://community.bistudio.com/wiki/userInputDisabled","revid":373273,"updated":"2025-04-13T14:32:18Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.60"}],"since":{"game":"arma3","name":"Arma 3","version":"1.60"},"arma3_since":"1.60","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns whether or not user input is disabled.\n\n> [!IMPORTANT]\n> The disabled input system internally *counts* how many times `disableUserInput true` has been called - see #Example 2.","syntaxes":[{"syntax":"userInputDisabled","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"Toggles user input\n\n```sqf\ndisableUserInput !userInputDisabled;\n```","code":["disableUserInput !userInputDisabled;"]},{"text":"```sqf\ndisableUserInput true;\ndisableUserInput true;\ndisableUserInput true;\n\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // false - control is regained only here\n```","code":["disableUserInput true;\ndisableUserInput true;\ndisableUserInput true;\n\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // true\n\ndisableUserInput false;\ndiag_log str userInputDisabled; // false - control is regained only here"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["disableUserInput"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.60","Scripting Commands"]},{"name":"values","operator":null,"title":"values","type":"command","url":"https://community.bistudio.com/wiki/values","revid":376075,"updated":"2025-07-27T22:51:40Z","groups":["HashMap"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.04"}],"since":{"game":"arma3","name":"Arma 3","version":"2.04"},"arma3_since":"2.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns all values stored in the given HashMap. The order of the returned Array corresponds to the order of the Array returned by the keys command.","syntaxes":[{"syntax":"values hashmap","since":null,"effect":null,"exec":null,"params":[{"name":"hashmap","type":"HashMap","optional":false,"default":null,"description":null,"types":["HashMap"],"since":null,"text":"hashmap: HashMap"}],"returns":{"type":"Array","types":["Array"],"description":"all values stored in hashmap","text":"Array - all values stored in *hashmap*"},"form":"unary","operator":null,"left":null,"right":{"text":"hashmap","types":["HashMap"]}}],"examples":[{"text":"```sqf\nprivate _values = values _myHashMap;\n```","code":["private _values = values _myHashMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["keys","toArray"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: HashMap","Introduced with Arma 3 version 2.04","Scripting Commands"]},{"name":"vectorAdd","operator":null,"title":"vectorAdd","type":"command","url":"https://community.bistudio.com/wiki/vectorAdd","revid":378392,"updated":"2026-04-04T07:53:40Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Adds two arrays of numbers. Replaces BIS_fnc_vectorAdd.\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid, if one array is larger than the other, the remaining elements are inserted without change.\n>\n> Before Arma 3 v2.14, the first argument had to be vector 3D, or Arma 3 v2.00 2D (Which still returned 3D result, with z coordinate defaulted to 0)","syntaxes":[{"syntax":"vector1 vectorAdd vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Array of Numbers","optional":false,"default":null,"description":"can be any size","types":["Array","Number"],"since":null,"text":"vector1: Array of Numbers - can be any size"},{"name":"vector2","type":"Array of Numbers","optional":false,"default":null,"description":"can be any size","types":["Array","Number"],"since":null,"text":"vector2: Array of Numbers - can be any size"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Array","Number"]},"right":{"text":"vector2","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nhint str (velocity unit1 vectorAdd velocity unit2);\n```","code":["hint str (velocity unit1 vectorAdd velocity unit2);"]},{"text":"```sqf\n[5, 10, 5] vectorAdd [5, 5, 10];            // returns [10, 15, 15]\n```","code":["[5, 10, 5] vectorAdd [5, 5, 10];\t\t\t// returns [10, 15, 15]"]},{"text":"```sqf\n[0, 0] vectorAdd [1, -2];                    // returns [1, -2]\n```","code":["[0, 0] vectorAdd [1, -2];\t\t\t\t\t// returns [1, -2]"]},{"text":"```sqf\n[1, 2, 3, 4, 5, 6] vectorAdd [10, 10, 10];    // returns [11, 12, 13, 4, 5, 6]\n```","code":["[1, 2, 3, 4, 5, 6] vectorAdd [10, 10, 10];\t// returns [11, 12, 13, 4, 5, 6]"]},{"text":"```sqf\n[1, 2, 3] vectorAdd [1, 2, 3];    // [2, 4, 6]\n[1, 2, 3] vectorAdd [1, 2];        // [2, 4, 3]\n[1, 2] vectorAdd [1, 2, 3];        // [2, 4, 3]\n[1, 2] vectorAdd [1, 2];        // [2, 4]\n```","code":["[1, 2, 3] vectorAdd [1, 2, 3];\t// [2, 4, 6]\n[1, 2, 3] vectorAdd [1, 2];\t\t// [2, 4, 3]\n[1, 2] vectorAdd [1, 2, 3];\t\t// [2, 4, 3]\n[1, 2] vectorAdd [1, 2];\t\t// [2, 4]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","matrixMultiply","matrixTranspose"],"notes":[{"user":"Lou Montana","date":"2023-11-02T17:40:30Z","text":"```sqf\n// between Arma 3 v2.00 and Arma 3 v2.14:\n[1, 2] vectorAdd [1, 2]; // [2, 4, 0]\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorCos","operator":null,"title":"vectorCos","type":"command","url":"https://community.bistudio.com/wiki/vectorCos","revid":378449,"updated":"2026-04-16T17:04:09Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Cosine of angle between two 3D or 2D vectors.","syntaxes":[{"syntax":"vector1 vectorCos vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Vector3D, Vector2D since Arma 3 v2.00","optional":false,"default":null,"description":"When Vector2D is provided the z coordinate is defaulted to 0","types":["Vector3D","Vector2D"],"since":null,"text":"vector1: Vector3D, Vector2D since Arma 3 v2.00  - When Vector2D is provided the z coordinate is defaulted to 0"},{"name":"vector2","type":"Vector3D, Vector2D since Arma 3 v2.00","optional":false,"default":null,"description":"When Vector2D is provided the z coordinate is defaulted to 0","types":["Vector3D","Vector2D"],"since":null,"text":"vector2: Vector3D, Vector2D since Arma 3 v2.00  - When Vector2D is provided the z coordinate is defaulted to 0"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Vector3D","Vector2D"]},"right":{"text":"vector2","types":["Vector3D","Vector2D"]}}],"examples":[{"text":"```sqf\n_cos = getPos player vectorCos [0,0,2];\n```","code":["_cos = getPos player vectorCos [0,0,2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorCrossProduct","operator":null,"title":"vectorCrossProduct","type":"command","url":"https://community.bistudio.com/wiki/vectorCrossProduct","revid":378395,"updated":"2026-04-04T07:56:27Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Cross product of two 3D vectors.\n\nIn layman's terms, if you have a polygon (surface) defined by 3 points, you can find a normal to it (just like terrain surfaceNormal). To invert direction of the normal, swap arguments around.","syntaxes":[{"syntax":"vector1 vectorCrossProduct vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"since Arma 3 v2.00, z coordinate is defaulted to 0 if not provided","types":["Vector3D","Vector2D"],"since":null,"text":"vector1:  Vector3D or Vector2D - since Arma 3 v2.00, z coordinate is defaulted to 0 if not provided"},{"name":"vector2","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"since Arma 3 v2.00, z coordinate is defaulted to 0 if not provided","types":["Vector3D","Vector2D"],"since":null,"text":"vector2:  Vector3D or Vector2D - since Arma 3 v2.00, z coordinate is defaulted to 0 if not provided"}],"returns":{"type":"Array","types":["Array"],"description":"vector [x, y, z]","text":"Array -  vector [x, y, z]"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Vector3D","Vector2D"]},"right":{"text":"vector2","types":["Vector3D","Vector2D"]}}],"examples":[{"text":"```sqf\n_vector = [1,1,1] vectorCrossProduct [2,2,2];\n```","code":["_vector = [1,1,1] vectorCrossProduct [2,2,2];"]},{"text":"```sqf\n_vectorUp = [0,1,0] vectorCrossProduct [-1,0,0]; //[0,-0,1]\n```","code":["_vectorUp = [0,1,0] vectorCrossProduct [-1,0,0]; //[0,-0,1]"]},{"text":"```sqf\n_vectorSide = (vectorDir player) vectorCrossProduct (vectorUp player);\n```","code":["_vectorSide = (vectorDir player) vectorCrossProduct (vectorUp player);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo","matrixMultiply","matrixTranspose"],"notes":[{"user":"ffur2007slx2_5","date":"2014-06-28T09:12:00Z","text":"Arma 3 v1.22Algorithm:\n\n```sqf\nVector1 = [x1,y1,z1]; Vector2 = [x2,y2,z2];\nResult = [(y1 * z2) - (z1 * y2),(z1 * x2) - (x1 * z2),(x1 * y2) - (y1 * x2)];\n```\n\nIt is recommended to use vectorCrossProduct instead of BIS_fnc_crossProduct."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorDiff","operator":null,"title":"vectorDiff","type":"command","url":"https://community.bistudio.com/wiki/vectorDiff","revid":377116,"updated":"2026-01-01T10:12:56Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Subtracts one 3D vector from another. (vector1 - vector2)\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid, if one array is larger than the other, the remaining elements are inserted without change.\n>\n> Before Arma 3 v2.14, the first argument had to be vector 3D, or Arma 3 v2.00 2D (Which still returned 3D result, with z coordinate defaulted to 0)","syntaxes":[{"syntax":"vector1 vectorDiff vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector1: Array of Numbers"},{"name":"vector2","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector2: Array of Numbers"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Array","Number"]},"right":{"text":"vector2","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nhint str (velocity car vectorDiff velocity bike);\n```","code":["hint str (velocity car vectorDiff velocity bike);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo"],"notes":[{"user":"ffur2007slx2_5","date":"2014-06-28T09:09:00Z","text":"Arma 3 v1.22 Algorithm:\n\n```sqf\nVector1 = [x1,y1,z1]; Vector2 = [x2,y2,z2];\nResult = [x1 - x2, y1 - y2, z1 - z2];\n```\n\nIt is recommended to use vectorDiff instead of BIS_fnc_vectorDiff."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorDir","operator":null,"title":"vectorDir","type":"command","url":"https://community.bistudio.com/wiki/vectorDir","revid":377247,"updated":"2026-01-02T05:27:32Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's direction vector in world space.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.\n\nFor an object facing one of the cardinal directions on perfectly flat ground (parallel to the XY-plane of the world space), vectorDir returns simple values:\n- `[0, 1, 0]` if the object is facing directly north\n- `[1, 0, 0]` if the object is facing directly east\n- `[0, -1, 0]` if the object is facing directly south\n- `[-1, 0, 0]` if the object is facing directly west","syntaxes":[{"syntax":"vectorDir object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecDir = vectorDir MyObject;\n```","code":["_vecDir = vectorDir MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorModelToWorld","vectorDirVisual","vectorSide","vectorSideVisual","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo","BIS_fnc_transformVectorDirAndUp"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"vectorDirVisual","operator":null,"title":"vectorDirVisual","type":"command","url":"https://community.bistudio.com/wiki/vectorDirVisual","revid":377258,"updated":"2026-01-02T06:32:55Z","groups":["Math - Vectors","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's direction vector in world space and render time scope.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.\n\nFor an object facing one of the cardinal directions on perfectly flat ground (parallel to the XY-plane of the world space), vectorDirVisual returns simple values:\n- `[0, 1, 0]` if the object is facing directly north\n- `[1, 0, 0]` if the object is facing directly east\n- `[0, -1, 0]` if the object is facing directly south\n- `[-1, 0, 0]` if the object is facing directly west","syntaxes":[{"syntax":"vectorDirVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecDirVis = vectorDirVisual MyObject;\n```","code":["_vecDirVis = vectorDirVisual MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorModelToWorldVisual","vectorDir","vectorSide","vectorSideVisual","vectorUpVisual","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"vectorDistance","operator":null,"title":"vectorDistance","type":"command","url":"https://community.bistudio.com/wiki/vectorDistance","revid":369374,"updated":"2024-09-03T18:43:13Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns [Euclidean distance](https://en.wikipedia.org/wiki/Euclidean_distance) between two points.","syntaxes":[{"syntax":"point1 vectorDistance point2","since":null,"effect":null,"exec":null,"params":[{"name":"point1","type":"Position3D or Position2D","optional":false,"default":null,"description":"(since Arma 3 v2.00, z coordinate is defaulted to 0)","types":["Position3D","Position2D"],"since":null,"text":"point1: Position3D or Position2D - (since Arma 3 v2.00, z coordinate is defaulted to 0)"},{"name":"point2","type":"Position3D or Position2D","optional":false,"default":null,"description":"(since Arma 3 v2.00, z coordinate is defaulted to 0)","types":["Position3D","Position2D"],"since":null,"text":"point2: Position3D or Position2D - (since Arma 3 v2.00, z coordinate is defaulted to 0)"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"point1","types":["Position3D","Position2D"]},"right":{"text":"point2","types":["Position3D","Position2D"]}}],"examples":[{"text":"```sqf\n_euclideanDist = getPosASL player vectorDistance [0,0,0];\n```","code":["_euclideanDist = getPosASL player vectorDistance [0,0,0];"]},{"text":"```sqf\n(getPosASL _a) vectorDistance (getPosASL _b);\n// same as\n(getPosATL _a) distance (getPosATL _b);\n```","code":["(getPosASL _a) vectorDistance (getPosASL _b);\n// same as\n(getPosATL _a) distance (getPosATL _b);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","distance","vectorNormalized","vectorFromTo","distance2D","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorDistanceSqr","operator":null,"title":"vectorDistanceSqr","type":"command","url":"https://community.bistudio.com/wiki/vectorDistanceSqr","revid":378368,"updated":"2026-04-03T16:47:13Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Squared distance between two 3D vectors.","syntaxes":[{"syntax":"vector1 vectorDistanceSqr vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)","types":["Vector3D","Vector2D"],"since":null,"text":"vector1: Vector3D or Vector2D - 3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)"},{"name":"vector2","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)","types":["Vector3D","Vector2D"],"since":null,"text":"vector2: Vector3D or Vector2D - 3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Vector3D","Vector2D"]},"right":{"text":"vector2","types":["Vector3D","Vector2D"]}}],"examples":[{"text":"```sqf\n_distSqr = getPos player vectorDistanceSqr [0,0,2];\n```","code":["_distSqr = getPos player vectorDistanceSqr [0,0,2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","distanceSqr","vectorNormalized","vectorFromTo"],"notes":[{"user":"ffur2007slx2_5","date":"2014-06-28T08:50:00Z","text":"Algorithm:\n\n```sqf\n_vector1 = [x1,y1,z1];\n_vector2 = [x2,y2,z2];\n_result = (x2 - x1) ^ 2 + (y2 - y1) ^ 2 + (z2 - z1) ^ 2;\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorDotProduct","operator":null,"title":"vectorDotProduct","type":"command","url":"https://community.bistudio.com/wiki/vectorDotProduct","revid":373021,"updated":"2025-03-18T15:32:41Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Dot product of two 3D vectors.\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid, but both arrays must be same length.\n>\n> 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)","syntaxes":[{"syntax":"vector1 vectorDotProduct vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector1: Array of Numbers"},{"name":"vector2","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector2: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Array","Number"]},"right":{"text":"vector2","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_dot = [1,0,1] vectorDotProduct [0,0,2];\n```","code":["_dot = [1,0,1] vectorDotProduct [0,0,2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorFromTo","operator":null,"title":"vectorFromTo","type":"command","url":"https://community.bistudio.com/wiki/vectorFromTo","revid":378369,"updated":"2026-04-03T16:47:19Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Unit vector, equal to direction from vector1 to vector2. In other words this command produces normalised vector between given 2 points.\n\nTo get a non-normalised vector, use vectorDiff.","syntaxes":[{"syntax":"vector1 vectorFromTo vector2","since":null,"effect":null,"exec":null,"params":[{"name":"vector1","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)","types":["Vector3D","Vector2D"],"since":null,"text":"vector1: Vector3D or Vector2D - 3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)"},{"name":"vector2","type":"Vector3D or Vector2D","optional":false,"default":null,"description":"3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)","types":["Vector3D","Vector2D"],"since":null,"text":"vector2: Vector3D or Vector2D - 3D or Arma 3 v2.00 2D vector (z coordinate is defaulted to 0)"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"binary","operator":null,"left":{"text":"vector1","types":["Vector3D","Vector2D"]},"right":{"text":"vector2","types":["Vector3D","Vector2D"]}}],"examples":[{"text":"```sqf\n[1,2,3] vectorFromTo [4,5,6];\n// is the same as\nvectorNormalized ([4,5,6] vectorDiff [1,2,3]);\n```","code":["[1,2,3] vectorFromTo [4,5,6];\n// is the same as\nvectorNormalized ([4,5,6] vectorDiff [1,2,3]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","matrixMultiply","matrixTranspose"],"notes":[{"user":"ffur2007slx2_5","date":"2014-07-19T16:01:00Z","text":"Arma 3 v1.26 Algorithm:\n\n```sqf\n_vector1 = [x1,y1,z1];\n_vector2 = [x2,y2,z2];\n_result = [\n    (x1 - x2) / (sqrt ((x1 - x2) ^ 2 + (y1 - y2) ^ 2 + (z1 - z2) ^ 2)),\n    (y1 - y2) / (sqrt ((x1 - x2) ^ 2 + (y1 - y2) ^ 2 + (z1 - z2) ^ 2)),\n    (z1 - z2) / (sqrt ((x1 - x2) ^ 2 + (y1 - y2) ^ 2 + (z1 - z2) ^ 2))\n];\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"vectorLinearConversion","operator":null,"title":"vectorLinearConversion","type":"command","url":"https://community.bistudio.com/wiki/vectorLinearConversion","revid":377894,"updated":"2026-01-05T17:41:49Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.92"}],"since":{"game":"arma3","name":"Arma 3","version":"1.92"},"arma3_since":"1.92","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Interpolates vector between the given *vectorFrom* and *vectorTo* value according to the given range value.","syntaxes":[{"syntax":"vectorLinearConversion [rangeFrom, rangeTo, rangeValue, vectorFrom, vectorTo, clip]","since":null,"effect":null,"exec":null,"params":[{"name":"rangeFrom","type":"Number","optional":false,"default":null,"description":"start \"from\" range","types":["Number"],"since":null,"text":"rangeFrom: Number - start \"from\" range"},{"name":"rangeTo","type":"Number","optional":false,"default":null,"description":"end \"to\" range","types":["Number"],"since":null,"text":"rangeTo: Number - end \"to\" range"},{"name":"rangeValue","type":"Number","optional":false,"default":null,"description":"variable range value","types":["Number"],"since":null,"text":"rangeValue: Number - variable range value"},{"name":"vectorFrom","type":"Vector3D","optional":false,"default":null,"description":"start \"from\" vector","types":["Vector3D"],"since":null,"text":"vectorFrom: Vector3D - start \"from\" vector"},{"name":"vectorTo","type":"Vector3D","optional":false,"default":null,"description":"end \"to\" vector","types":["Vector3D"],"since":null,"text":"vectorTo: Vector3D - end \"to\" vector"},{"name":"clip","type":"Boolean","optional":true,"default":"false","description":"if true, range value will be clipped to stay within \"from\" - \"to\" range","types":["Boolean"],"since":null,"text":"clip: Boolean - (Optional, default false) if true, range value will be clipped to stay within \"from\" - \"to\" range"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"interpolated vector","text":"Vector3D - interpolated vector"},"form":"unary","operator":null,"left":null,"right":{"text":"[rangeFrom, rangeTo, rangeValue, vectorFrom, vectorTo, clip]","types":["Array"]}}],"examples":[{"text":"```sqf\nvectorLinearConversion [0, 1, 0.5, [0,0,0], [25,50,100], false];    // [12.5,25,50]\n```","code":["vectorLinearConversion [0, 1, 0.5, [0,0,0], [25,50,100], false];\t// [12.5,25,50]"]},{"text":"```sqf\nvectorLinearConversion [0, 1, 100, [0,0,0], [25,50,100], true];    // [25,50,100]\n```","code":["vectorLinearConversion [0, 1, 100, [0,0,0], [25,50,100], true];\t// [25,50,100]"]},{"text":"```sqf\nvectorLinearConversion [0, 1, 100, [0,0,0], [25,50,100], false];    // [2500,5000,10000]\n```","code":["vectorLinearConversion [0, 1, 100, [0,0,0], [25,50,100], false];\t// [2500,5000,10000]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["linearConversion","bezierInterpolation","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.92","Scripting Commands"]},{"name":"vectorMagnitude","operator":null,"title":"vectorMagnitude","type":"command","url":"https://community.bistudio.com/wiki/vectorMagnitude","revid":373022,"updated":"2025-03-18T15:33:55Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Magnitude of a 3D vector.\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid.\n>\n> Before Arma 3 v2.14, the argument had to be vector 3D, or Arma 3 v2.00 2D (With z coordinate defaulted to 0)","syntaxes":[{"syntax":"vectorMagnitude vector","since":null,"effect":null,"exec":null,"params":[{"name":"vector","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"vector","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_size = vectorMagnitude [0,3,4]; // returns 5\n```","code":["_size = vectorMagnitude [0,3,4]; // returns 5"]},{"text":"```sqf\n_speed = vectorMagnitude velocity player;                // return velocity of player in m/s\n_speed = (vectorMagnitude velocity player) * 3.6;        // return velocity of player in km/h\n_speed = (vectorMagnitude velocity player) * 2.23694;    // return velocity of player in mph\n```","code":["_speed = vectorMagnitude velocity player;\t\t\t\t// return velocity of player in m/s\n_speed = (vectorMagnitude velocity player) * 3.6;\t\t// return velocity of player in km/h\n_speed = (vectorMagnitude velocity player) * 2.23694;\t// return velocity of player in mph"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorMagnitudeSqr","operator":null,"title":"vectorMagnitudeSqr","type":"command","url":"https://community.bistudio.com/wiki/vectorMagnitudeSqr","revid":373023,"updated":"2025-03-18T15:34:37Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Squared magnitude of a 3D vector.\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid.\n>\n> Before Arma 3 v2.14, the argument had to be vector 3D, or Arma 3 v2.00 2D (With z coordinate defaulted to 0)","syntaxes":[{"syntax":"vectorMagnitudeSqr vector","since":null,"effect":null,"exec":null,"params":[{"name":"vector","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector: Array of Numbers"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"vector","types":["Array","Number"]}}],"examples":[{"text":"```sqf\n_sizeSqr = vectorMagnitudeSqr [0,3,4]; // returns 25\n```","code":["_sizeSqr = vectorMagnitudeSqr [0,3,4]; // returns 25"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorNormalized","vectorFromTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorModelToWorld","operator":null,"title":"vectorModelToWorld","type":"command","url":"https://community.bistudio.com/wiki/vectorModelToWorld","revid":378448,"updated":"2026-04-16T17:00:30Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts vector direction from model to world space.\n\n> [!IMPORTANT]\n> For scaled objects, the resulting vector's magnitude will also be multiplied by the object scale.","syntaxes":[{"syntax":"object vectorModelToWorld modelDir","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"modelDir","type":"Vector3D","optional":false,"default":null,"description":"vector direction in model space in format [x,y,z]","types":["Vector3D"],"since":null,"text":"modelDir: Vector3D - vector direction in model space in format [x,y,z]"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"vector direction in world space","text":"Vector3D - vector direction in world space"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"modelDir","types":["Vector3D"]}}],"examples":[{"text":"Convert model space vector [0,-10,4] to world space; vector gets rotated according to _airplane:\n\n```sqf\n_airplane vectorModelToWorld [0,-10,4];\n```","code":["_airplane vectorModelToWorld [0,-10,4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDir","modelToWorld","addForce","addTorque","vectorModelToWorldVisual","vectorWorldToModel","vectorWorldToModelVisual","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"vectorModelToWorldVisual","operator":null,"title":"vectorModelToWorldVisual","type":"command","url":"https://community.bistudio.com/wiki/vectorModelToWorldVisual","revid":378406,"updated":"2026-04-04T08:14:52Z","groups":["Math - Vectors","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts vector from model to world space in render time scope.\n\n> [!IMPORTANT]\n> For scaled objects, the resulting vector's magnitude will also be multiplied by the object scale.","syntaxes":[{"syntax":"object vectorModelToWorldVisual modelDir","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"modelDir","type":"Vector3D","optional":false,"default":null,"description":"vector direction in model space in format [x,y,z]","types":["Vector3D"],"since":null,"text":"modelDir: Vector3D - vector direction in model space in format [x,y,z]"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"vector direction in world space in format [x,y,z]","text":"Vector3D - vector direction in world space in format [x,y,z]"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"modelDir","types":["Vector3D"]}}],"examples":[{"text":"Convert model space vector [0,-10,4] to world space; vector gets rotated according to _airplane:\n\n```sqf\n_airplane vectorModelToWorldVisual [0,-10,4];\n```","code":["_airplane vectorModelToWorldVisual [0,-10,4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDirVisual","modelToWorldVisual","addForce","addTorque","vectorModelToWorld","vectorWorldToModel","vectorWorldToModelVisual"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Command Group: Render Time Scope","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"vectorMultiply","operator":null,"title":"vectorMultiply","type":"command","url":"https://community.bistudio.com/wiki/vectorMultiply","revid":373016,"updated":"2025-03-18T15:24:19Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Multiplies an array of numbers by a scalar or another array of numbers.\n\n> [!NOTE]\n> **Since Arma 3 v2.14:** Since Arma 3 v2.14 any count of numbers is valid, if one array is larger than the other, the remaining elements are inserted without change.\n>\n> Before Arma 3 v2.14, the first argument had to be vector 3D, or Arma 3 v2.00 2D (Which still returned 3D result, with z coordinate defaulted to 0)","syntaxes":[{"syntax":"numArray vectorMultiply multiplier","since":null,"effect":null,"exec":null,"params":[{"name":"numArray","type":"Array of Numbers","optional":false,"default":null,"description":"an array of any size to be multiplied with the multiplier","types":["Array","Number"],"since":null,"text":"numArray: Array of Numbers - an array of any size to be multiplied with the multiplier"},{"name":"multiplier","type":"Number or Arma 3 v2.14 Array of Numbers","optional":false,"default":null,"description":null,"types":["Number","Array"],"since":null,"text":"multiplier: Number or Arma 3 v2.14 Array of Numbers"}],"returns":{"type":"Array of Numbers","types":["Array","Number"],"description":null,"text":"Array of Numbers"},"form":"binary","operator":null,"left":{"text":"numArray","types":["Array","Number"]},"right":{"text":"multiplier","types":["Number","Array"]}}],"examples":[{"text":"```sqf\n_newVector = [1,2,3] vectorMultiply 3; // returns [3,6,9]\n```","code":["_newVector = [1,2,3] vectorMultiply 3; // returns [3,6,9]"]},{"text":"```sqf\n[1,2,3,4] vectorMultiply [1,2,3,4];    // [1,4,9,16]\n[1,2,3,4] vectorMultiply 2;            // [2,4,6,8]\n[1,2,3,4] vectorMultiply [2];        // [2,2,3,4]\n[2] vectorMultiply [1,2,3,4];        // [2,2,3,4]\n[1,2,3] vectorMultiply [1,2,3,4,5];    // [1,4,9,4,5]\n```","code":["[1,2,3,4] vectorMultiply [1,2,3,4];\t// [1,4,9,16]\n[1,2,3,4] vectorMultiply 2;\t\t\t// [2,4,6,8]\n[1,2,3,4] vectorMultiply [2];\t\t// [2,2,3,4]\n[2] vectorMultiply [1,2,3,4];\t\t// [2,2,3,4]\n[1,2,3] vectorMultiply [1,2,3,4,5];\t// [1,4,9,4,5]"]},{"text":"```sqf\nprivate _eyePos = eyePos player;\nprivate _eyeDir = getCameraViewDirection player;    // this is a normalized vector, i.e. its magnitude is 1\nprivate _100mFurther = _eyeDir vectorMultiply 100;    // since _eyeDir is normalised (length = 1m), multiplying it by 100 means 100m in that direction\nprivate _lookPos = _eyePos vectorAdd _100mFurther;    // the position where player is looking 100m ahead\n```","code":["private _eyePos = eyePos player;\nprivate _eyeDir = getCameraViewDirection player;\t// this is a normalized vector, i.e. its magnitude is 1\nprivate _100mFurther = _eyeDir vectorMultiply 100;\t// since _eyeDir is normalised (length = 1m), multiplying it by 100 means 100m in that direction\nprivate _lookPos = _eyePos vectorAdd _100mFurther;\t// the position where player is looking 100m ahead"]},{"text":"```sqf\n// Override firing to throw the player towards where he's aiming\nplayer allowDamage false;\nplayer addAction [\"\", {\n    player setVelocity ((player weaponDirection \"\") vectorMultiply 20);\n}, \"\", 0, false, true, \"DefaultAction\"];\n```","code":["// Override firing to throw the player towards where he's aiming\nplayer allowDamage false;\nplayer addAction [\"\", {\n\tplayer setVelocity ((player weaponDirection \"\") vectorMultiply 20);\n}, \"\", 0, false, true, \"DefaultAction\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorAdd","vectorDiff","vectorCrossProduct","vectorDotProduct","vectorMagnitude","matrixMultiply"],"notes":[{"user":"ffur2007slx2_5","date":"2014-06-28T08:21:00Z","text":"Arma 3 v1.22 Algorithm:\n\n```sqf\nVector = [x, y, z]; scalar = a;\nResult = [(x * a), (y * a), (z * a)];\n```\n\nIt is recommended to use vectorMultiply instead of BIS_fnc_vectorMultiply.\nThis is a very useful function, as it can be used with the velocity command to move an object from one position to another. (ie <vector1> to <vector2>) - ensure both positions are found using getPosASL.\n\n```sqf\n_obj setVelocity (((getPosASL _target) vectorDiff (getPosASL _obj)) vectorMultiply 2);\n```"}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"vectorNormalized","operator":null,"title":"vectorNormalized","type":"command","url":"https://community.bistudio.com/wiki/vectorNormalized","revid":378403,"updated":"2026-04-04T08:14:40Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.26"}],"since":{"game":"arma3","name":"Arma 3","version":"1.26"},"arma3_since":"1.26","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns normalised vector (unit vector, vectorMagnitude == 1) of given vector. If given vector is 0 result is a 0 vector as well.\n\n> [!NOTE]\n> - Arma 3 v2.14 any count of numbers is valid\n> - Arma 3 v2.00 now supports Vector2D (z defaulted to 0)\n> - Arma 3 v1.26 command introduction, only works with Vector3D","syntaxes":[{"syntax":"vectorNormalized vector","since":null,"effect":null,"exec":null,"params":[{"name":"vector","type":"Array of Numbers","optional":false,"default":null,"description":null,"types":["Array","Number"],"since":null,"text":"vector: Array of Numbers"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"vector","types":["Array","Number"]}}],"examples":[{"text":"```sqf\nvectorNormalized [12345,7890,38383]; // [0.300481,0.192045,0.934254]\nvectorMagnitude [0.300481,0.192045,0.934254]; // 1\n```","code":["vectorNormalized [12345,7890,38383]; // [0.300481,0.192045,0.934254]\nvectorMagnitude [0.300481,0.192045,0.934254]; // 1"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorDiff","vectorCrossProduct","vectorDotProduct","vectorCos","vectorMagnitude","vectorMagnitudeSqr","vectorMultiply","vectorDistance","vectorDistanceSqr","vectorDir","vectorUp","setVectorDir","setVectorUp","setVectorDirAndUp","vectorFromTo","matrixMultiply","matrixTranspose"],"notes":[{"user":"ffur2007slx2_5","date":"2014-07-19T15:13:00Z","text":"Arma 3 v1.26 Algorithm:\n\n```sqf\n_vector = [x,y,z];\n_result = [x / (sqrt (x ^ 2 + y ^ 2 + z ^ 2)), y / (sqrt (x ^ 2 + y ^ 2 + z ^ 2)), z / (sqrt (x ^ 2 + y ^ 2 + z ^ 2))];\n```\n\nIn mathematics, a unit vector in a normed vector space is a vector whose length is 1."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.26","Scripting Commands"]},{"name":"vectorSide","operator":null,"title":"vectorSide","type":"command","url":"https://community.bistudio.com/wiki/vectorSide","revid":378405,"updated":"2026-04-04T08:14:48Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's side vector in world space.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.","syntaxes":[{"syntax":"vectorSide object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecSide = vectorSide MyObject;\n```","code":["_vecSide = vectorSide MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorSideVisual","vectorUpVisual","vectorDir","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo","BIS_fnc_getPitchBank","BIS_fnc_transformVectorDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"vectorSideVisual","operator":null,"title":"vectorSideVisual","type":"command","url":"https://community.bistudio.com/wiki/vectorSideVisual","revid":377261,"updated":"2026-01-02T06:33:05Z","groups":["Math - Vectors","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's side vector in world space and render time scope.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.","syntaxes":[{"syntax":"vectorSideVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecSideVis = vectorSideVisual MyObject;\n```","code":["_vecSideVis = vectorSideVisual MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorSide","vectorUpVisual","vectorDir","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo","BIS_fnc_getPitchBank","BIS_fnc_transformVectorDirAndUp"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Command Group: Render Time Scope","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"vectorUp","operator":null,"title":"vectorUp","type":"command","url":"https://community.bistudio.com/wiki/vectorUp","revid":377264,"updated":"2026-01-02T06:33:14Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's up vector in world space.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.","syntaxes":[{"syntax":"vectorUp object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecUp = vectorUp MyObject;\n```","code":["_vecUp = vectorUp MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorUpVisual","vectorDir","vectorSide","vectorSideVisual","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo","BIS_fnc_getPitchBank","BIS_fnc_transformVectorDirAndUp"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"vectorUpVisual","operator":null,"title":"vectorUpVisual","type":"command","url":"https://community.bistudio.com/wiki/vectorUpVisual","revid":377255,"updated":"2026-01-02T06:32:45Z","groups":["Math - Vectors","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an object's up vector in world space and render time scope.\n\n> [!IMPORTANT]\n> The vector is **not necessarily normalized**. The magnitude of the vector depends on the object's scale.","syntaxes":[{"syntax":"vectorUpVisual object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vecUpVis = vectorUpVisual MyObject;\n```","code":["_vecUpVis = vectorUpVisual MyObject;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["vectorUp","vectorDirVisual","vectorSide","vectorSideVisual","vectorDir","setVectorDir","setVectorUp","setVectorDirAndUp","vectorDiff","vectorAdd","vectorMultiply","vectorCrossProduct","vectorDistance","vectorMagnitudeSqr","vectorDistanceSqr","vectorCos","vectorMagnitude","vectorDotProduct","vectorNormalized","vectorFromTo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"vectorWorldToModel","operator":null,"title":"vectorWorldToModel","type":"command","url":"https://community.bistudio.com/wiki/vectorWorldToModel","revid":377866,"updated":"2026-01-04T11:33:08Z","groups":["Math - Vectors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts vector direction from world to model space.\n\n> [!IMPORTANT]\n> For scaled objects, the resulting vector's magnitude will be divided by the object scale.","syntaxes":[{"syntax":"object vectorWorldToModel worldDir","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"worldDir","type":"Vector3D","optional":false,"default":null,"description":"vector direction in world space in format [x,y,z]","types":["Vector3D"],"since":null,"text":"worldDir: Vector3D - vector direction in world space in format [x,y,z]"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"vector direction in model space in format [x,y,z]","text":"Vector3D - vector direction in model space in format [x,y,z]"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"worldDir","types":["Vector3D"]}}],"examples":[{"text":"Convert world space vector [0,-10,4] to model space of object _airplane:\n\n```sqf\n_airplane vectorWorldToModel [0,-10,4];\n```","code":["_airplane vectorWorldToModel [0,-10,4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addForce","worldToModel","addTorque","vectorModelToWorld","vectorModelToWorldVisual","vectorWorldToModelVisual","matrixMultiply","matrixTranspose"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"vectorWorldToModelVisual","operator":null,"title":"vectorWorldToModelVisual","type":"command","url":"https://community.bistudio.com/wiki/vectorWorldToModelVisual","revid":377893,"updated":"2026-01-05T17:39:06Z","groups":["Math - Vectors","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.72"}],"since":{"game":"arma3","name":"Arma 3","version":"1.72"},"arma3_since":"1.72","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts vector direction from world to model space in render time scope.\n\n> [!IMPORTANT]\n> For scaled objects, the resulting vector's magnitude will be divided by the object scale.","syntaxes":[{"syntax":"object vectorWorldToModelVisual worldDir","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"worldDir","type":"Vector3D","optional":false,"default":null,"description":"vector direction in world space in format [x,y,z]","types":["Vector3D"],"since":null,"text":"worldDir: Vector3D - vector direction in world space in format [x,y,z]"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"vector direction in model space in format [x,y,z]","text":"Vector3D - vector direction in model space in format [x,y,z]"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"worldDir","types":["Vector3D"]}}],"examples":[{"text":"Convert world space vector [0,-10,4] to model space of object _airplane:\n\n```sqf\nprivate _vector = _airplane vectorWorldToModelVisual [0,-10,4];\n```","code":["private _vector = _airplane vectorWorldToModelVisual [0,-10,4];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addForce","worldToModelVisual","addTorque","vectorModelToWorld","vectorModelToWorldVisual","vectorWorldToModel"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Math - Vectors","Command Group: Render Time Scope","Introduced with Arma 3 version 1.72","Scripting Commands"]},{"name":"vehicle","operator":null,"title":"vehicle","type":"command","url":"https://community.bistudio.com/wiki/vehicle","revid":376160,"updated":"2025-09-08T19:48:37Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Vehicle in which given unit is mounted. If none, unit is returned. Alternatively, use objectParent\n\n> [!IMPORTANT]\n> While vehicle may return the vehicle the unit is in for **alive** units, for dead units which are groupless, this command returns the unit itself - use objectParent instead.","syntaxes":[{"syntax":"vehicle unitName","since":null,"effect":null,"exec":null,"params":[{"name":"unitName","type":"Object","optional":false,"default":null,"description":"alive unit","types":["Object"],"since":null,"text":"unitName: Object - alive unit"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"unitName","types":["Object"]}}],"examples":[{"text":"SQS\n\n```sqs\n? vehicle player != player : hint \"Player is in a vehicle\"\n```","code":["? vehicle player != player : hint \"Player is in a vehicle\""]},{"text":"SQF\n\n```sqf\nif (vehicle player != player) then { hint \"Player is in a vehicle\" };\n```","code":["if (vehicle player != player) then { hint \"Player is in a vehicle\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["objectParent"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"vehicleCargoEnabled","operator":null,"title":"vehicleCargoEnabled","type":"command","url":"https://community.bistudio.com/wiki/vehicleCargoEnabled","revid":349518,"updated":"2023-11-08T17:15:53Z","groups":["Vehicle in Vehicle Transport"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.62"}],"since":{"game":"arma3","name":"Arma 3","version":"1.62"},"arma3_since":"1.62","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if the vehicle has enabled transporting other vehicles or not.","syntaxes":[{"syntax":"vehicleCargoEnabled vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"returns true if the vehicle has enabled transporting other vehicles, and false if the vehicle has not enabled transporting other vehicles","text":"Boolean - returns true if the vehicle has enabled transporting other vehicles, and false if the vehicle has not enabled transporting other vehicles"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"Blackfish (Vehicle Transport) with given variable name blackfish\n\n```sqf\n_canTransportVehicles = vehicleCargoEnabled blackfish; //returns true\n```","code":["_canTransportVehicles = vehicleCargoEnabled blackfish; //returns true"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Arma 3: Vehicle in Vehicle Transport","canVehicleCargo","setVehicleCargo","enableVehicleCargo","getVehicleCargo","isVehicleCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Vehicle in Vehicle Transport","Introduced with Arma 3 version 1.62","Scripting Commands"]},{"name":"vehicleChat","operator":null,"title":"vehicleChat","type":"command","url":"https://community.bistudio.com/wiki/vehicleChat","revid":376772,"updated":"2025-11-17T00:04:46Z","groups":["Radio and Chat"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.34"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Types text to the vehicle radio channel. The text will be visible only on the PC where command was executed. If you need the message to show on all computers, you have to execute it globally, see remoteExec. Use clearRadio to clear chat history\n\n> [!NOTE]\n> - Object parameter must be a vehicle, not a player\n> - If you are in a crew seat (i.e. driver, gunner or commander), then it will include that role in the chat name output (Eg: Driver (you_name): \"Message\")","syntaxes":[{"syntax":"vehicle vehicleChat chatText","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle unit is in","types":["Object"],"since":null,"text":"vehicle: Object - vehicle unit is in"},{"name":"chatText","type":"String","optional":false,"default":null,"description":"message to transmit","types":["String"],"since":null,"text":"chatText: String - message to transmit"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"chatText","types":["String"]}}],"examples":[{"text":"```sqf\nvehicle player vehicleChat \"Show this text\";\n```","code":["vehicle player vehicleChat \"Show this text\";"]},{"text":"```sqf\ndriver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";\n```","code":["driver vehicle player sideChat \"sideChat\";\ndriver vehicle player globalChat \"globalChat\";\ndriver vehicle player groupChat \"groupChat\";\nvehicle player vehicleChat \"vehicleChat\";\ndriver vehicle player commandChat \"commandChat\";\ndriver vehicle player customChat [1, \"customChat\"];\nsystemChat \"systemChat\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["globalChat","groupChat","sideChat","commandChat","customChat","systemChat","vehicleRadio"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Introduced with Operation Flashpoint version 1.34","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"vehicleMoveInfo","operator":null,"title":"vehicleMoveInfo","type":"command","url":"https://community.bistudio.com/wiki/vehicleMoveInfo","revid":377693,"updated":"2026-01-02T09:03:15Z","groups":["Object Manipulation","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.98"}],"since":{"game":"arma3","name":"Arma 3","version":"1.98"},"arma3_since":"1.98","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current vehicle move/turn info (a getter for sendSimpleCommand) in format [moveInfo, turnInfo]. Possible values:\n\n| moveInfo | turnInfo |\n|---|---|\n| - `\"FORMATION\"` - vehicle is stationary<br>- `\"FORWARD\"`  - vehicle is moving forward<br>- `\"FAST\"` - vehicle is fast moving forward<br>- `\"SLOW\"` - vehicle is slow moving forward<br>- `\"STOP\"` - vehicle is stationary<br>- `\"BACK\"` - vehicle is reversing<br>- `\"DirectByComander\"` [sic] - keyboard pilot is used, i.e. player is in the vehicle and is the effectiveCommander pressing any driving key (WASD or arrows).<br>- `\"MOVE\"`<br>- `\"CONVOY\"`<br>- `\"SIMPLE\"` | - `\"LEFT\"` - vehicle is turning left (use \"STOPTURNING\" to cancel)<br>- `\"RIGHT\"` - vehicle is turning right (use \"STOPTURNING\" to cancel)<br>- `\"NONE\"` - vehicle is not turning (when script command is used)<br>- `\"ABS\"` - vehicle is not turning (when keyboard pilot is used) |","syntaxes":[{"syntax":"vehicleMoveInfo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Array with [moveInfo, turnInfo]","types":["Array"],"description":"moveInfo: String - state of vehicle forward/backward movement (see description) - turnInfo: String - state of vehicle left/right turning (see description)","text":"Array with [moveInfo, turnInfo]\n- moveInfo: String - state of vehicle forward/backward movement (see description)\n- turnInfo: String - state of vehicle left/right turning (see description)"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nonEachFrame { hintSilent str vehicleMoveInfo vehicle player };\n```","code":["onEachFrame { hintSilent str vehicleMoveInfo vehicle player };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sendSimpleCommand","useAISteeringComponent","effectiveCommander","setEffectiveCommander","enableAI","disableAI","getUnitState","enableAIFeature"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Unit Control","Introduced with Arma 3 version 1.98","Scripting Commands"]},{"name":"vehicleRadio","operator":null,"title":"vehicleRadio","type":"command","url":"https://community.bistudio.com/wiki/vehicleRadio","revid":353385,"updated":"2024-03-15T17:12:00Z","groups":["Radio and Chat","Sounds"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":"local","server_exec":false},"exec":null,"description":"Sends the audio message to the vehicle radio channel. The message is defined in CfgRadio in the description.ext file or config radio protocol. The transmission will play only on the PC where command was executed. If you need the transmission to play on all computers, you have to execute it globally (see remoteExec).\n\n> [!NOTE]\n> When transmitting unit gets killed, transmission will be interrupted. However when receiving unit gets killed, the transmission continues to play.","syntaxes":[{"syntax":"unit vehicleRadio radioName","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"unit to transmit","types":["Object"],"since":null,"text":"unit: Object - unit to transmit"},{"name":"radioName","type":"String","optional":false,"default":null,"description":"class name from CfgRadio","types":["String"],"since":null,"text":"radioName: String - class name from CfgRadio"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"radioName","types":["String"]}}],"examples":[{"text":"```sqf\n_soldierOne vehicleRadio \"messageOne\";\n```","code":["_soldierOne vehicleRadio \"messageOne\";"]},{"text":"```sqf\nplayer vehicleRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));\n```","code":["player vehicleRadio configName selectRandom (\"true\" configClasses (configFile >> \"CfgRadio\"));"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["sideRadio","groupRadio","customRadio","vehicleChat","globalRadio","directSay","commandRadio"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Radio and Chat","Command Group: Sounds","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"vehicleReceiveRemoteTargets","operator":null,"title":"vehicleReceiveRemoteTargets","type":"command","url":"https://community.bistudio.com/wiki/vehicleReceiveRemoteTargets","revid":311075,"updated":"2022-05-07T20:59:23Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets whether the vehicle can acquire targets via datalink from the Side center.","syntaxes":[{"syntax":"vehicleReceiveRemoteTargets vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvehicleReceiveRemoteTargets vehicle player;\n```","code":["vehicleReceiveRemoteTargets vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"vehicleReportOwnPosition","operator":null,"title":"vehicleReportOwnPosition","type":"command","url":"https://community.bistudio.com/wiki/vehicleReportOwnPosition","revid":311076,"updated":"2022-05-07T20:59:46Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets whether the vehicle shares its own position via datalink with the Side center.","syntaxes":[{"syntax":"vehicleReportOwnPosition vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvehicleReportOwnPosition vehicle player;\n```","code":["vehicleReportOwnPosition vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","vehicleReportRemoteTargets","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","setVehicleReportOwnPosition","reportRemoteTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"vehicleReportRemoteTargets","operator":null,"title":"vehicleReportRemoteTargets","type":"command","url":"https://community.bistudio.com/wiki/vehicleReportRemoteTargets","revid":311077,"updated":"2022-05-07T21:00:14Z","groups":["Sensors"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.70"}],"since":{"game":"arma3","name":"Arma 3","version":"1.70"},"arma3_since":"1.70","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets whether the vehicle shares acquired targets via datalink with the Side center.","syntaxes":[{"syntax":"vehicleReportRemoteTargets vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvehicleReportRemoteTargets vehicle player;\n```","code":["vehicleReportRemoteTargets vehicle player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleRadar","setVehicleReportRemoteTargets","vehicleReceiveRemoteTargets","setVehicleReceiveRemoteTargets","vehicleReportOwnPosition","setVehicleReportOwnPosition","reportRemoteTarget","confirmSensorTarget"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Sensors","Introduced with Arma 3 version 1.70","Scripting Commands"]},{"name":"vehicles","operator":null,"title":"vehicles","type":"command","url":"https://community.bistudio.com/wiki/vehicles","revid":377110,"updated":"2026-01-01T10:06:56Z","groups":["Object Detection"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":"local","server_exec":false},"exec":null,"description":"Returns an array of all vehicles available to current client. This command returns both empty and crewed vehicles but not soldiers. It will also return \"WeaponHolderSimulated\" of dead bodies (weapon on the ground). Vehicles created with createVehicleLocal will only be returned on the client that created them.","syntaxes":[{"syntax":"vehicles","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array of Objects","types":["Array","Object"],"description":null,"text":"Array of Objects"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_vehicles = vehicles;\n```","code":["_vehicles = vehicles;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allGroups","allUnits","units","entities","agents","playableUnits","switchableUnits","allPlayers","allDead","allDeadMen","allUnitsUAV","allCurators","allObjects","allMissionObjects","allSimpleObjects","allMines"],"notes":[{"user":"Sa-Matra","date":"2024-06-18T06:18:00Z","text":"This command returns a lot of crap that is not really a vehicle in a common sense - simulated weapon holders, clutter cutters, etc. It also skips \"out\" vehicles (disassembled drones and statics). Be careful iterating through it as it may be expensive.\n\nHere is a list of most vehicle simulations that are returned by this command:\n\n```sqf\nairplanex\nartillerymarker\ncar\ncarx\nfire\nhelicopterrtd\nlasertarget\nmotorcycle\nnvmarker\nparachute\nparaglide\nrope\nshipx\nsubmarinex\nsuppresstarget\ntankx\nthing\nthingx\n```\n\nGenerated using this code bit:\n\n```sqf\nprivate _sims = createHashMap;\n{\n    private _sim = toLowerANSI getText(_x >> \"simulation\");\n    if!(_sim in _sims) then {\n        _sims set [_sim, configName _x];\n    };\n} forEachReversed (\"getNumber(_x >> 'scope') > 0\" configClasses (configFile >> \"CfgVehicles\"));\n\nprivate _used_sims = [];\n{\n    if(createVehicle [_y, [random 1e5,random 1e5,random 1e5], [], 0, \"CAN_COLLIDE\"] in vehicles) then {\n        _used_sims pushBack _x;\n    };\n} forEach _sims;\n\n_used_sims sort true;\ncopyToClipboard (_used_sims joinString toString [10]);\n```\n\nThere is probably more simulations not listed like non-x versions of vehicle simulations but these are ones actually used in A3."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Detection","Introduced with Armed Assault version 1.00","Scripting Commands","Scripting Commands: Local Effect","Take On Helicopters: Scripting Commands"]},{"name":"vehicleVarName","operator":null,"title":"vehicleVarName","type":"command","url":"https://community.bistudio.com/wiki/vehicleVarName","revid":352868,"updated":"2024-02-28T19:33:35Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the variable name that contains a primary editor reference to this object. This is the variable given in the *Insert Unit dialog / name field* in the editor. It can be changed using setVehicleVarName.\n\n> [!NOTE]\n> Respawned unit will have the same vehicleVarName as the corpse left behind, however actual missionNamespace variable of the same name will only contain respawned unit.","syntaxes":[{"syntax":"vehicleVarName object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"String","types":["String"],"description":"variable name, if none was set, an empty string is returned","text":"String - variable name, if none was set, an empty string is returned"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nhint vehicleVarName player;\n```","code":["hint vehicleVarName player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVehicleVarName","BIS_fnc_objectVar"],"notes":[{"user":"Killzone_Kid","date":"2015-04-19T08:45:00Z","text":"To get variable names referencing an object in mission namespace:\n\n```sqf\nKK_fnc_objectVarNames = {\n    private \"_names\";\n    _names = [];\n    {\n        if (missionNamespace getVariable _x isEqualTo _this) then {\n            _names pushBack _x;\n        };\n    } forEach allVariables missionNamespace;\n    _names\n};\n\n// Example\nmyGroup = group player;\naGroup = group player;\nhint str (group player call KK_fnc_objectVarNames); // [\"agroup\", \"mygroup\"]\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"velocity","operator":null,"title":"velocity","type":"command","url":"https://community.bistudio.com/wiki/velocity","revid":377249,"updated":"2026-01-02T06:14:11Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.80"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the velocity of the object as vector in m/s.","syntaxes":[{"syntax":"velocity object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_vector = velocity jeep;\n```","code":["_vector = velocity jeep;"]},{"text":"```sqf\nif ((velocity _plane1 select 2) > 50) then { hint \"Aircraft is climbing up too fast!\"; };\n```","code":["if ((velocity _plane1 select 2) > 50) then { hint \"Aircraft is climbing up too fast!\"; };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVelocity","velocityModelSpace","setVelocityModelSpace","setVelocityTransformation","speed"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Operation Flashpoint version 1.80","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"velocityModelSpace","operator":null,"title":"velocityModelSpace","type":"command","url":"https://community.bistudio.com/wiki/velocityModelSpace","revid":377109,"updated":"2026-01-01T10:06:22Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the velocity (speed vector) of the vehicle as an array with format [x, y, z] in metre per second. Vector is in model space.","syntaxes":[{"syntax":"velocityModelSpace vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nvelocityModelSpace _chopper; // returns [X (left(-) right(+)), Y (backward(-) forward(+)), Z (down(-) up(+))]\n```","code":["velocityModelSpace _chopper; // returns [X (left(-) right(+)), Y (backward(-) forward(+)), Z (down(-) up(+))]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setVelocityModelSpace","velocity","speed","setVelocity","setVelocityTransformation"],"notes":[{"user":"Pierre MGI","date":"2014-12-11T02:55:00Z","text":"This function is useful for helicopters as it returns Z vector like an indicator of thrust/load ratio. More or less climb (+) or descent (-) tendency but:\nAs X,Y,Z vectors are relative to vehicle attitude, this function doesn't return a climb or descend rate (as the attitude of the vehicle can be far from horizontal).\nYou can get negative Z vector, in jets, while climbing fast, peeling off in the sky!\nMore or less, you can use as a Z accelerometer factor but invert the sign: +G acceleration (negative vector below the jet) is -Z here.\nIf not \"physically\" correct, the behavior is sufficient enough for Arma flight model."},{"user":"K.J.","date":"2015-06-21T02:36:00Z","text":"Previous note is physically incorrect. Velocity can not be used to give information about Thrust/Load ratio or G-Forces/acceleration.\nTo get acceleration you have to create the derivative of velocity after time dv/dt -> the difference of velocity between 2 timesteps divided by the time that passed between the 2 steps."}],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"verifySignature","operator":null,"title":"verifySignature","type":"command","url":"https://community.bistudio.com/wiki/verifySignature","revid":319877,"updated":"2022-05-13T09:25:38Z","groups":["Mods and Addons"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Check if file is signed by any key present in game keys folders. On clients, it does not check against the keys accepted by server.","syntaxes":[{"syntax":"verifySignature filename","since":null,"effect":null,"exec":null,"params":[{"name":"filename","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"filename: String"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"filename","types":["String"]}}],"examples":[{"text":"```sqf\nverifySignature \"@MyAddon\\Addons\\SomeAddon.pbo\";\n```","code":["verifySignature \"@MyAddon\\Addons\\SomeAddon.pbo\";"]},{"text":"```sqf\nverifySignature \"@MyAddon\\Somefnc.dll\";\n```","code":["verifySignature \"@MyAddon\\Somefnc.dll\";"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["ArmA: Addon Signatures"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mods and Addons","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"vest","operator":null,"title":"vest","type":"command","url":"https://community.bistudio.com/wiki/vest","revid":319955,"updated":"2022-05-13T09:25:47Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"nameof vest.","syntaxes":[{"syntax":"vest unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_myVest = vest player;\n```","code":["_myVest = vest player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["removeVest","addVest"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"vestContainer","operator":null,"title":"vestContainer","type":"command","url":"https://community.bistudio.com/wiki/vestContainer","revid":369325,"updated":"2024-09-03T18:42:58Z","groups":["Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.04"}],"since":{"game":"arma3","name":"Arma 3","version":"1.04"},"arma3_since":"1.04","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns a cargo container of a unit's vest.","syntaxes":[{"syntax":"vestContainer unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Object","types":["Object"],"description":"cargo container or objNull if unit does not wear a vest","text":"Object - cargo container or objNull if *unit* does not wear a vest"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str vestContainer player; // 2df7d600# 163942: dummyweapon.p3d\n```","code":["hint str vestContainer player; // 2df7d600# 163942: dummyweapon.p3d"]},{"text":"```sqf\nhint str getMagazineCargo vestContainer player;\n/*\n    returns e.g\n    [\n        [\n            \"30Rnd_65x39_caseless_mag\",\n            \"16Rnd_9x21_Mag\",\n            \"HandGrenade\",\n            \"APERSMine_Range_Mag\",\n            \"SmokeShell\",\n            \"SmokeShellGreen\",\n            \"Chemlight_green\"\n        ],[\n            2,\n            2,\n            2,\n            3,\n            1,\n            1,\n            2\n        ]\n    ]\n*/\n```","code":["hint str getMagazineCargo vestContainer player;\n/*\n\treturns e.g\n\t[\n\t\t[\n\t\t\t\"30Rnd_65x39_caseless_mag\",\n\t\t\t\"16Rnd_9x21_Mag\",\n\t\t\t\"HandGrenade\",\n\t\t\t\"APERSMine_Range_Mag\",\n\t\t\t\"SmokeShell\",\n\t\t\t\"SmokeShellGreen\",\n\t\t\t\"Chemlight_green\"\n\t\t],[\n\t\t\t2,\n\t\t\t2,\n\t\t\t2,\n\t\t\t3,\n\t\t\t1,\n\t\t\t1,\n\t\t\t2\n\t\t]\n\t]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformContainer","backpackContainer","everyContainer"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Introduced with Arma 3 version 1.04","Scripting Commands"]},{"name":"vestItems","operator":null,"title":"vestItems","type":"command","url":"https://community.bistudio.com/wiki/vestItems","revid":377108,"updated":"2026-01-01T10:05:52Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all items (of any kind, even weapons) from vest.","syntaxes":[{"syntax":"vestItems unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"Class names of items","text":"Array of Strings - Class names of items"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nvestItems player;\n// returns e.g\n/*\n[\n    \"30Rnd_65x39_caseless_mag\",\n    \"30Rnd_65x39_caseless_mag\",\n    \"16Rnd_9x21_Mag\",\n    \"16Rnd_9x21_Mag\",\n    \"HandGrenade\",\n    \"HandGrenade\",\n    \"SmokeShell\",\n    \"SmokeShellGreen\",\n    \"Chemlight_green\",\n    \"Chemlight_green\"\n]\n*/\n```","code":["vestItems player;\n// returns e.g\n/*\n[\n\t\"30Rnd_65x39_caseless_mag\",\n\t\"30Rnd_65x39_caseless_mag\",\n\t\"16Rnd_9x21_Mag\",\n\t\"16Rnd_9x21_Mag\",\n\t\"HandGrenade\",\n\t\"HandGrenade\",\n\t\"SmokeShell\",\n\t\"SmokeShellGreen\",\n\t\"Chemlight_green\",\n\t\"Chemlight_green\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformItems","backpackItems"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"vestMagazines","operator":null,"title":"vestMagazines","type":"command","url":"https://community.bistudio.com/wiki/vestMagazines","revid":321370,"updated":"2022-05-14T10:53:55Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all magazines from vest of the given unit.","syntaxes":[{"syntax":"vestMagazines unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of String","types":["Array","String"],"description":null,"text":"Array of String"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nvestMagazines player;\n// returns e.g\n/*\n[\n    \"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:4/0](2x)\",\n    \"9mm 16Rnd Mag(16/16)[id/cr:7/0](2x)\",\n    \"RGO Frag Grenade(1/1)[id/cr:10/0](2x)\",\n    \"Smoke Grenade (White)(1/1)[id/cr:12/0](1x)\",\n    \"Smoke Grenade (Green)(1/1)[id/cr:13/0](1x)\",\n    \"Chemlight (Green)(1/1)[id/cr:14/0](2x)\"\n]\n*/\n```","code":["vestMagazines player;\n// returns e.g\n/*\n[\n\t\"6.5mm 30Rnd STANAG Mag(30/30)[id/cr:4/0](2x)\",\n\t\"9mm 16Rnd Mag(16/16)[id/cr:7/0](2x)\",\n\t\"RGO Frag Grenade(1/1)[id/cr:10/0](2x)\",\n\t\"Smoke Grenade (White)(1/1)[id/cr:12/0](1x)\",\n\t\"Smoke Grenade (Green)(1/1)[id/cr:13/0](1x)\",\n\t\"Chemlight (Green)(1/1)[id/cr:14/0](2x)\"\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["uniformMagazines","backpackMagazines","soldierMagazines"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"viewDistance","operator":null,"title":"viewDistance","type":"command","url":"https://community.bistudio.com/wiki/viewDistance","revid":319951,"updated":"2022-05-13T09:25:46Z","groups":["System","Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the rendering distance.","syntaxes":[{"syntax":"viewDistance","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nhint (\"my view distance is \" + str viewDistance + \" meters\");\n```","code":["hint (\"my view distance is \" + str viewDistance + \" meters\");"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setViewDistance","setDetailMapBlendPars","setTerrainGrid","getObjectViewDistance","setObjectViewDistance"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Command Group: System","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"visibleCompass","operator":null,"title":"visibleCompass","type":"command","url":"https://community.bistudio.com/wiki/visibleCompass","revid":319850,"updated":"2022-05-13T09:25:35Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the player has compass opened and visible. Keep in mind that the GPS minimap in Arma 3 also shows the direction.","syntaxes":[{"syntax":"visibleCompass","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (visibleCompass) then {hint \"Compass is visible\"};\n```","code":["if (visibleCompass) then {hint \"Compass is visible\"};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showCompass","shownCompass","visibleGPS","visibleWatch"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"visibleGPS","operator":null,"title":"visibleGPS","type":"command","url":"https://community.bistudio.com/wiki/visibleGPS","revid":378434,"updated":"2026-04-07T19:38:22Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the player has GPS receiver (minimap) opened and visible.","syntaxes":[{"syntax":"visibleGPS","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (visibleGPS) then\n{\n    hint \"GPS is visible\";\n};\n```","code":["if (visibleGPS) then\n{\n\thint \"GPS is visible\";\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["openGPS","showGPS","shownGPS","visibleWatch","visibleCompass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"visibleMap","operator":null,"title":"visibleMap","type":"command","url":"https://community.bistudio.com/wiki/visibleMap","revid":376117,"updated":"2025-08-30T17:58:07Z","groups":["Map","Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return true if the main map is shown (active). In Arma 3 it also returns true if the respawn screen map is visible.","syntaxes":[{"syntax":"visibleMap","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (visibleMap) then { hint \"You're showing the map !\" };\n```","code":["if (visibleMap) then { hint \"You're showing the map !\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["forceMap","openMap"],"notes":[{"user":"3.JgKp James","date":"2017-11-13T15:14:00Z","text":"visibleMap does not work in all cases where a map might be part of a dialog like in a uav terminal or in a artillery computer dialog.\nSome of these cases can be covered with an addMissionEventHandler of type \"Map\".\nJust use the two magic variables 'mapIsOpened' and 'mapIsForced'. Skeleton might look something like:\n\n```sqf\n// update marker as long as map is open (works for UAV stations as well)\nJ_myGPSEH = addMissionEventHandler [\"Map\", {\n\n    params [\"_mapIsOpened\", \"_mapIsForced\"];\n\n    if (_mapIsOpened) then\n    {\n        systemChat \"GPS active\";\n        J_var_GPSOn = true;\n\n        // no sheduled environment -> create one\n        /* Triggered when map is opened or closed either by user action or script command openMap. */\n        0 spawn {\n            waitUntil { \n                // ... // do something as long as map is open\n                not J_var_GPSOn;\n            };\n        };\n    }\n    else\n    {\n        J_var_GPSOn = false;\n        systemChat \"GPS inactive\";\n    };\n}];\n```"}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Command Group: Map","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"visiblePosition","operator":null,"title":"visiblePosition","type":"command","url":"https://community.bistudio.com/wiki/visiblePosition","revid":363616,"updated":"2024-04-08T11:45:05Z","groups":["Positions","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an object's rendered position (z value above surface underneath) in render time scope. Same as getPosVisual.\n\n> [!IMPORTANT]\n> This command must **not** be used for actual 3D calculations. See getPos for an explanation.","syntaxes":[{"syntax":"visiblePosition object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"name of the object","types":["Object"],"since":null,"text":"object: Object - name of the object"}],"returns":{"type":"PositionAGLS","types":["PositionAGLS"],"description":null,"text":"PositionAGLS"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerRenderedPos = visiblePosition player;\n```","code":["_playerRenderedPos = visiblePosition player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosVisual","getPosATLVisual","getPosASLVisual","getPosWorldVisual","visiblePositionASL","position","getPos","getPosATL","getPosASL","getPosASLW"],"notes":[{"user":"Leopard20","date":"2022-01-26T15:15:06Z","text":"Note that this command returns the position in AGLS format (Z is measured from the nearest surface below). For example the value of Z is 0 even if the object is resting on top of a building.\n\nFor use with draw commands, such as drawIcon3D, an AGL position is needed. The following alternatives can be used, depending on where the icon is intended to be shown:\n\n```sqf\nASLToAGL getPosWorldVisual _object        // object center in model coordinates, i.e [0,0,0]\nASLToAGL getPosASLVisual _object        // object land contact (e.g. floor of a building)\nunitAimPositionVisual _object            // object's aiming position, i.e where the AI aim at, such as a soldier's chest\n_object modelToWorldVisual _relativePos    // custom position in model coordinates. if _relativePos is [0,0,0], it'll be the same as ASLToAGL getPosWorldVisual _object\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Command Group: Render Time Scope","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"visiblePositionASL","operator":null,"title":"visiblePositionASL","type":"command","url":"https://community.bistudio.com/wiki/visiblePositionASL","revid":377444,"updated":"2026-01-02T06:46:56Z","groups":["Positions","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.62"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an object's rendered ASL position (z value above sea level) in render time scope.","syntaxes":[{"syntax":"visiblePositionASL object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":"name of the object","types":["Object"],"since":null,"text":"object: Object - name of the object"}],"returns":{"type":"PositionASL","types":["PositionASL"],"description":null,"text":"PositionASL"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n_playerRenderedPosASL = visiblePositionASL player;\n```","code":["_playerRenderedPosASL = visiblePositionASL player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getPosVisual","getPosASLVisual","getPosATLVisual","getPosWorldVisual","visiblePosition","position","getPos","getPosATL","getPosASL","getPosASLW"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Command Group: Render Time Scope","Introduced with Arma 2: Operation Arrowhead version 1.62","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"visibleScoretable","operator":null,"title":"visibleScoretable","type":"command","url":"https://community.bistudio.com/wiki/visibleScoretable","revid":310767,"updated":"2022-05-07T20:21:40Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.64"}],"since":{"game":"arma3","name":"Arma 3","version":"1.64"},"arma3_since":"1.64","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks whether the score table is visible.","syntaxes":[{"syntax":"visibleScoretable","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_visible = visibleScoretable;\n```","code":["_visible = visibleScoretable;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showScoretable","shownScoretable"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.64","Scripting Commands"]},{"name":"visibleWatch","operator":null,"title":"visibleWatch","type":"command","url":"https://community.bistudio.com/wiki/visibleWatch","revid":364092,"updated":"2024-05-03T19:50:40Z","groups":["Interaction"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the player has watch opened and visible. Keep in mind that the GPS minimap in Arma 3 also shows the time.","syntaxes":[{"syntax":"visibleWatch","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (visibleWatch) then { hint \"Watch is visible\" };\n```","code":["if (visibleWatch) then { hint \"Watch is visible\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showWatch","shownWatch","visibleGPS","visibleCompass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Interaction","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"waitUntil","operator":null,"title":"waitUntil","type":"command","url":"https://community.bistudio.com/wiki/waitUntil","revid":378959,"updated":"2026-09-03T14:52:35Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Suspends execution of scheduled script until the given condition satisfied.\n- This command will loop and call the code inside `{}` **mostly every frame**, depends on complexity of the condition and the overall engine load, until the code returns true\n- If the very first execution of the code returns true the command will exit immediately, therefore it will not produce any \"Suspending not allowed in this context\" error when used inside non-scheduled script. For all other uses it must be executed in environment that allows suspension (canSuspend), such as spawned or execVMed code\n- Avoid doing `waitUntil { time > 20 };` and use `sleep 20;` instead!\n- If you can, add a sleep to the condition to save some cpu cycles `waitUntil { sleep 1; !alive player };`\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.94, a *condition* returning anything other than true or false **will** result in an appropriate type error.","syntaxes":[{"syntax":"waitUntil condition","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"Code","optional":false,"default":null,"description":"the expression that **must** return a Boolean, true to finish waiting or false to continue waiting","types":["Code"],"since":null,"text":"condition: Code - the expression that **must** return a Boolean, true to finish waiting or false to continue waiting"}],"returns":{"type":"Anything","types":["Anything"],"description":"the value the condition evaluates to when the wait is over (normally true)","text":"Anything - the value the condition evaluates to when the wait is over (normally true)"},"form":"unary","operator":null,"left":null,"right":{"text":"condition","types":["Code"]}},{"syntax":"waitUntil [condition, timeout, interval]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"condition","type":"Code","optional":false,"default":null,"description":"the expression that **must** return a Boolean, true to finish waiting or false to continue waiting","types":["Code"],"since":null,"text":"condition: Code - the expression that **must** return a Boolean, true to finish waiting or false to continue waiting"},{"name":"timeout","type":"Number","optional":false,"default":null,"description":"a timeout in seconds of game time (sleep vs uiSleep). The timeout is only checked after the condition was checked. **Any negative value disables the timeout**","types":["Number"],"since":null,"text":"timeout: Number - a timeout in seconds of game time (sleep vs uiSleep). The timeout is only checked after the condition was checked. **Any negative value disables the timeout**"},{"name":"interval","type":"Number","optional":true,"default":"0","description":"the time interval in seconds of game time between condition checks, this is equivalent to using a \"sleep\" after the condition.","types":["Number"],"since":null,"text":"interval: Number - (Optional, default 0) the time interval in seconds of game time between condition checks, this is equivalent to using a \"sleep\" after the condition."}],"returns":{"type":"Anything","types":["Anything"],"description":"the value the condition evaluates to when the wait is over (normally true), or Nothing if the timeout ended the wait","text":"Anything - the value the condition evaluates to when the wait is over (normally true), or Nothing if the timeout ended the wait"},"form":"unary","operator":null,"left":null,"right":{"text":"[condition, timeout, interval]","types":["Array"]}},{"syntax":"waitUntil scriptHandle","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":"a script handle or promise to wait on","types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle - a script handle or promise to wait on"}],"returns":{"type":"Anything","types":["Anything"],"description":"The result of the script or Promise","text":"Anything - The result of the script or Promise"},"form":"unary","operator":null,"left":null,"right":{"text":"scriptHandle","types":["Script Handle"]}},{"syntax":"waitUntil [scriptHandle, timeout]","since":"arma3 2.22","effect":null,"exec":null,"params":[{"name":"scriptHandle","type":"Script Handle","optional":false,"default":null,"description":"a script handle or promise to wait on","types":["Script Handle"],"since":null,"text":"scriptHandle: Script Handle - a script handle or promise to wait on"},{"name":"timeout","type":"Number","optional":false,"default":null,"description":"a timeout in seconds of game time (sleep vs uiSleep)","types":["Number"],"since":null,"text":"timeout: Number - a timeout in seconds of game time (sleep vs uiSleep)"}],"returns":{"type":"Anything","types":["Anything"],"description":"the result of the script or Promise. Or Nothing if timed out.","text":"Anything - the result of the script or Promise. Or Nothing if timed out."},"form":"unary","operator":null,"left":null,"right":{"text":"[scriptHandle, timeout]","types":["Array"]}}],"examples":[{"text":"```sqf\nwaitUntil { not alive player };\n```","code":["waitUntil { not alive player };"]},{"text":"```sqf\n_i = 0; waitUntil { _i = _i + 1; _i >= 100 };\n```","code":["_i = 0; waitUntil { _i = _i + 1; _i >= 100 };"]},{"text":"waitUntil can lead to performance loss if used improperly:\n\n```sqf\nwaitUntil { not alive player };            // bad\nwaitUntil { sleep 1; not alive player };    // good - checks every 1 second\nplayer addEventHandler [\"Killed\", {  }];    // best - don't forget about Event Handlers\n```","code":["waitUntil { not alive player };\t\t\t// bad\nwaitUntil { sleep 1; not alive player };\t// good - checks every 1 second\nplayer addEventHandler [\"Killed\", {  }];\t// best - don't forget about Event Handlers"]},{"text":"An on-the-fly custom event handler:\n\n```sqf\n_myEH = [\"ZoomIn\"] spawn {\n    while { true } do\n    {\n        waitUntil { inputAction (_this select 0) == 1 };\n        diag_log format [\"%1 @ %2\", _this select 0, diag_tickTime];\n    };\n};\n```\n\nAlthough it may be better to use onEachFrame (stacked) mission Event Handler, depending on the application.","code":["_myEH = [\"ZoomIn\"] spawn {\n\twhile { true } do\n\t{\n\t\twaitUntil { inputAction (_this select 0) == 1 };\n\t\tdiag_log format [\"%1 @ %2\", _this select 0, diag_tickTime];\n\t};\n};"]},{"text":"Use getVariable with default value to prevent unexcepted script errors:\n\n```sqf\nwaitUntil { bank getVariable [\"money\", 0] > 0 };\nwaitUntil { missionNamespace getVariable [\"isready\", false] };\n```","code":["waitUntil { bank getVariable [\"money\", 0] > 0 };\nwaitUntil { missionNamespace getVariable [\"isready\", false] };"]},{"text":"Always return Boolean:\n\n```sqf\nwaitUntil { sleep 1; if (not alive player) exitWith {}; _time = _time + 1 };                // bad\nwaitUntil { sleep 1; if (not alive player) exitWith { true }; _time = _time + 1; false };    // good\nwaitUntil { sleep 1; not alive player };                                                    // perfect\n```","code":["waitUntil { sleep 1; if (not alive player) exitWith {}; _time = _time + 1 };\t\t\t\t// bad\nwaitUntil { sleep 1; if (not alive player) exitWith { true }; _time = _time + 1; false };\t// good\nwaitUntil { sleep 1; not alive player };\t\t\t\t\t\t\t\t\t\t\t\t\t// perfect"]}],"multiplayer":null,"problems":"For some unknown reason if you have waitUntil loop active and game is **saved/loaded**, some variables in the expression may appear undefined for a short time. As a workaround, assign expression to a variable and make sure it is defined before waitUntil checks it:\n\n```sqf\nwaitUntil { private _expression = someBooleanVar && (someNumberVar > 10); !isNil \"_expression\" && { _expression } };\n```","aliases":[],"see_also":["sleep","uiSleep","canSuspend","spawn","execVM","while","Control Structures"],"notes":[{"user":"CrashDome","date":"2006-12-20T19:55:00Z","text":"waitUntil suspends both SQF functions and SQF scripts. In functions, the calling script is still in suspension due to waiting for a return from the call command. The game engine will continue, however. See Function for more detail."},{"user":"RoehrenRadio","date":"2010-04-02T17:10:00Z","text":"Prior to Arma 3 v1.94 if waitUntil uses an undefined call code, waitUntil won't release, even when this code is separated from other conditions through or. Be warned that this won't cause an error message."},{"user":"Commy2","date":"2014-12-13T23:25:00Z","text":"If you want to use waitUntil together with exitWith, remember that the loop only exits if the code block returns true.\n\nIt should look like this:\n\n```sqf\nwaitUntil {\n    // exit loop if the unit gets deleted\n    if (isNull _unit) exitWith { true }; // has to return true to continue\n\n    !alive _unit;\n};\n```"},{"user":"AgentRev","date":"2022-04-19T06:05:01Z","text":"It's a good idea to include a timeout with the condition if there's any possibility that it never becomes true:\n\n```sqf\ndisableUserInput true;\nplayer moveInDriver _vehicle; // this command is asynchronous and can fail sometimes\n_time = time;\nwaitUntil {vehicle player == _vehicle || time - _time > 3};\ndisableUserInput false;\n```"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waterDamaged","operator":null,"title":"waterDamaged","type":"command","url":"https://community.bistudio.com/wiki/waterDamaged","revid":347219,"updated":"2023-09-05T16:49:02Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Checks if the engine was water damaged. When a vehicle is Drowned, the engine gets water damaged and might need full repair either with setDamage or setHitPointDamage to be able to start.","syntaxes":[{"syntax":"waterDamaged object","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if the engine was water damaged","text":"Boolean - true if the engine was water damaged"},"form":"unary","operator":null,"left":null,"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\nwaterDamaged tank1;\n```","code":["waterDamaged tank1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setDamage","damage","alive"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"waves","operator":null,"title":"waves","type":"command","url":"https://community.bistudio.com/wiki/waves","revid":319915,"updated":"2022-05-13T09:25:43Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return waves value.","syntaxes":[{"syntax":"waves","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nwaveIntensity = waves;\n```","code":["waveIntensity = waves;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaves"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"waypointAttachedObject","operator":null,"title":"waypointAttachedObject","type":"command","url":"https://community.bistudio.com/wiki/waypointAttachedObject","revid":377741,"updated":"2026-01-03T00:57:50Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the object attached to the waypoint.","syntaxes":[{"syntax":"waypointAttachedObject waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint:  Waypoint"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointAttachedObject [groupOne,1];\n```","code":["waypointAttachedObject [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointAttachObject"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointAttachedVehicle","operator":null,"title":"waypointAttachedVehicle","type":"command","url":"https://community.bistudio.com/wiki/waypointAttachedVehicle","revid":377749,"updated":"2026-01-03T00:58:03Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the vehicle attached to the waypoint.\n\nA vehicle can be attached to a waypoint by\n- creating the waypoint on top of the vehicle in the 2D Editor\n- using waypointAttachVehicle","syntaxes":[{"syntax":"waypointAttachedVehicle waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Object","types":["Object"],"description":null,"text":"Object"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointAttachedVehicle [groupOne, 1];\n```","code":["waypointAttachedVehicle [groupOne, 1];"]},{"text":"```sqf\nwaypointAttachedVehicle [group player, currentWaypoint group player];\n```","code":["waypointAttachedVehicle [group player, currentWaypoint group player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["attachObject","attachTo","attachedObjects","attachedTo","lightAttachObject","triggerAttachVehicle","attachedObject"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointAttachObject","operator":null,"title":"waypointAttachObject","type":"command","url":"https://community.bistudio.com/wiki/waypointAttachObject","revid":377746,"updated":"2026-01-03T00:57:58Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attaches a static object via its numeric ID to the given waypoint. Not to be confused with synchronizeWaypoint!\n\n> [!IMPORTANT]\n> - The main syntax doesn't work in Arma 3 anymore.\n> - The alternative syntax is (at least) available since Arma 2.","syntaxes":[{"syntax":"waypoint waypointAttachObject objectID","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"objectID","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"objectID: Number"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"objectID","types":["Number"]}},{"syntax":"waypoint waypointAttachObject object","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"object","type":"Object","optional":false,"default":null,"description":"static object","types":["Object"],"since":null,"text":"object: Object - static object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"object","types":["Object"]}}],"examples":[{"text":"```sqf\n[_grp, 2] waypointAttachObject 1234;\n```","code":["[_grp, 2] waypointAttachObject 1234;"]},{"text":"```sqf\nprivate _wp = group player addWaypoint [[1907.5, 5746.5, 0.00144196], 0];\n_wp waypointAttachObject ((waypointPosition _wp) nearestObject 66220);\n```","code":["private _wp = group player addWaypoint [[1907.5, 5746.5, 0.00144196], 0];\n_wp waypointAttachObject ((waypointPosition _wp) nearestObject 66220);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypointAttachedObject","synchronizeWaypoint"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointAttachVehicle","operator":null,"title":"waypointAttachVehicle","type":"command","url":"https://community.bistudio.com/wiki/waypointAttachVehicle","revid":319971,"updated":"2022-05-13T09:25:48Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Attaches the Waypoint to the provided vehicle Object.\n\n> [!IMPORTANT]\n> Use this command to associate a transport with `\"GETIN\"` waypoint, other types of waypoints might or might not work.\n> See also setWaypointType to set the waypoint type to \"GETIN\".","syntaxes":[{"syntax":"waypoint waypointAttachVehicle vehicleName","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"},{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"waypoint","types":["Waypoint"]},"right":{"text":"vehicleName","types":["Object"]}}],"examples":[{"text":"```sqf\n[_grp, 2] waypointAttachVehicle vehicle player;\n```","code":["[_grp, 2] waypointAttachVehicle vehicle player;"]},{"text":"```sqf\n((waypoints player) select 0) waypointAttachVehicle _soldier1;\n```","code":["((waypoints player) select 0) waypointAttachVehicle _soldier1;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","currentWaypoint","attachObject","attachTo","attachedObjects","attachedTo","lightAttachObject","triggerAttachVehicle","attachedObject"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointBehaviour","operator":null,"title":"waypointBehaviour","type":"command","url":"https://community.bistudio.com/wiki/waypointBehaviour","revid":377739,"updated":"2026-01-03T00:57:47Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint behavior.","syntaxes":[{"syntax":"waypointBehaviour waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint:  Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointBehaviour [groupOne,1];\n```","code":["waypointBehaviour [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","AIBehaviour","waypoints","setWaypointBehaviour"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointCombatMode","operator":null,"title":"waypointCombatMode","type":"command","url":"https://community.bistudio.com/wiki/waypointCombatMode","revid":377742,"updated":"2026-01-03T00:57:51Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint's combat mode setting.","syntaxes":[{"syntax":"waypointCombatMode waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":"one of \"BLUE\", \"GREEN\", \"WHITE\", \"YELLOW\" and \"RED\" or \"ERROR\"","text":"String - one of \"BLUE\", \"GREEN\", \"WHITE\", \"YELLOW\" and \"RED\" or \"ERROR\""},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointCombatMode [groupOne, 1];\n```","code":["waypointCombatMode [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Combat Modes","waypoints","setWaypointCombatMode"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointCompletionRadius","operator":null,"title":"waypointCompletionRadius","type":"command","url":"https://community.bistudio.com/wiki/waypointCompletionRadius","revid":377743,"updated":"2026-01-03T00:57:53Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the radius around the waypoint where the waypoint is completed.","syntaxes":[{"syntax":"waypointCompletionRadius waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_radius = waypointCompletionRadius [groupOne, 1];\n```","code":["_radius = waypointCompletionRadius [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointCompletionRadius"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointDescription","operator":null,"title":"waypointDescription","type":"command","url":"https://community.bistudio.com/wiki/waypointDescription","revid":377753,"updated":"2026-01-03T00:58:09Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint description.","syntaxes":[{"syntax":"waypointDescription waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointDescription [groupOne,1];\n```","code":["waypointDescription [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointDescription"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointForceBehaviour","operator":null,"title":"waypointForceBehaviour","type":"command","url":"https://community.bistudio.com/wiki/waypointForceBehaviour","revid":377583,"updated":"2026-01-02T06:56:41Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.58"}],"since":{"game":"arma3","name":"Arma 3","version":"1.58"},"arma3_since":"1.58","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if the waypoint behavior is forced.","syntaxes":[{"syntax":"waypointForceBehaviour waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"is forced","text":"Boolean - is forced"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_isForced = waypointForceBehaviour [groupOne, 1];\n```","code":["_isForced = waypointForceBehaviour [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaypointForceBehaviour","setWaypointBehaviour","waypointBehaviour","Mission Editor: Waypoints"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.58","Scripting Commands"]},{"name":"waypointFormation","operator":null,"title":"waypointFormation","type":"command","url":"https://community.bistudio.com/wiki/waypointFormation","revid":377745,"updated":"2026-01-03T00:57:56Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint formation.\n\nPossible values are:\n- \"NO CHANGE\"\n- \"COLUMN\"\n- \"STAG COLUMN\"\n- \"WEDGE\"\n- \"ECH LEFT\"\n- \"ECH RIGHT\"\n- \"VEE\"\n- \"LINE\"\n- \"FILE\"\n- \"DIAMOND\"","syntaxes":[{"syntax":"waypointFormation waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointFormation [groupOne,1];\n```","code":["waypointFormation [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","waypoints","setWaypointFormation"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointHousePosition","operator":null,"title":"waypointHousePosition","type":"command","url":"https://community.bistudio.com/wiki/waypointHousePosition","revid":377756,"updated":"2026-01-03T00:58:13Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns buildingPos index assigned to the waypoint.","syntaxes":[{"syntax":"waypointHousePosition waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Number","types":["Number"],"description":"buildingPos index","text":"Number - buildingPos index"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointHousePosition [groupOne,1];\n```","code":["waypointHousePosition [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","waypointPosition","setWaypointHousePosition","buildingPos"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointLoiterAltitude","operator":null,"title":"waypointLoiterAltitude","type":"command","url":"https://community.bistudio.com/wiki/waypointLoiterAltitude","revid":377578,"updated":"2026-01-02T06:56:34Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.00"}],"since":{"game":"arma3","name":"Arma 3","version":"2.00"},"arma3_since":"2.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint loiter altitude.","syntaxes":[{"syntax":"waypointLoiterAltitude waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nprivate _loiterAlt = waypointLoiterAltitude [groupOne, 1];\n```","code":["private _loiterAlt = waypointLoiterAltitude [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaypointLoiterAltitude"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 2.00","Scripting Commands"]},{"name":"waypointLoiterRadius","operator":null,"title":"waypointLoiterRadius","type":"command","url":"https://community.bistudio.com/wiki/waypointLoiterRadius","revid":377587,"updated":"2026-01-02T06:56:47Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint's loiter radius.","syntaxes":[{"syntax":"waypointLoiterRadius waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_radius = waypointLoiterRadius [groupOne, 1];\n```","code":["_radius = waypointLoiterRadius [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","setWaypointCompletionRadius","setWaypointPosition","setWaypointTimeout","setWaypointLoiterRadius","addWaypoint","setWaypointLoiterType","currentWaypoint"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"waypointLoiterType","operator":null,"title":"waypointLoiterType","type":"command","url":"https://community.bistudio.com/wiki/waypointLoiterType","revid":323061,"updated":"2022-06-28T21:43:11Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint loiter type. Waypoint uses format Waypoint.","syntaxes":[{"syntax":"waypointLoiterType waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_type = waypointLoiterType [groupOne, 1];\n```","code":["_type = waypointLoiterType [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.00","Scripting Commands"]},{"name":"waypointName","operator":null,"title":"waypointName","type":"command","url":"https://community.bistudio.com/wiki/waypointName","revid":377579,"updated":"2026-01-02T06:56:35Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint name.","syntaxes":[{"syntax":"waypointName waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_wpName = waypointName [_grp, 2];\n```","code":["_wpName = waypointName [_grp, 2];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWaypointName","waypointPosition","waypointSpeed"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"waypointPosition","operator":null,"title":"waypointPosition","type":"command","url":"https://community.bistudio.com/wiki/waypointPosition","revid":377419,"updated":"2026-01-02T06:45:28Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":null},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":null},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get provided waypoint's position.","syntaxes":[{"syntax":"waypointPosition [groupOrUnit, index]","since":null,"effect":null,"exec":null,"params":[{"name":"groupOrUnit","type":"Group or Object","optional":false,"default":null,"description":null,"types":["Group","Object"],"since":null,"text":"groupOrUnit: Group or Object"},{"name":"index","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"index: Number"}],"returns":{"type":"PositionAGL","types":["PositionAGL"],"description":null,"text":"PositionAGL"},"form":"unary","operator":null,"left":null,"right":{"text":"[groupOrUnit, index]","types":["Array"]}}],"examples":[{"text":"```sqf\n_wPos = waypointPosition [_groupOne, 1];\n```","code":["_wPos = waypointPosition [_groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":["getWPPos"],"see_also":["waypoints","setWaypointPosition","waypointHousePosition","setWPPos"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Operation Flashpoint version","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypoints","operator":null,"title":"waypoints","type":"command","url":"https://community.bistudio.com/wiki/waypoints","revid":347556,"updated":"2023-09-28T09:43:23Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.05"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.05"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns an array of waypoints for the specified unit/group.","syntaxes":[{"syntax":"waypoints groupName","since":null,"effect":null,"exec":null,"params":[{"name":"groupName","type":"Group or Object","optional":false,"default":null,"description":null,"types":["Group","Object"],"since":null,"text":"groupName: Group or Object"}],"returns":{"type":"Array of Waypoints","types":["Array","Waypoint"],"description":null,"text":"Array of Waypoints"},"form":"unary","operator":null,"left":null,"right":{"text":"groupName","types":["Group","Object"]}}],"examples":[{"text":"```sqf\nwaypoints player;\n```","code":["waypoints player;"]},{"text":"```sqf\n_wPosArray = waypoints group10; // returns e.g [[EAST 1-1-A,0],[EAST 1-1-A,1],[EAST 1-1-A,2]]\n```","code":["_wPosArray = waypoints group10; // returns e.g [[EAST 1-1-A,0],[EAST 1-1-A,1],[EAST 1-1-A,2]]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypointSpeed","setWPPos","waypointName"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Armed Assault version 1.05","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointScript","operator":null,"title":"waypointScript","type":"command","url":"https://community.bistudio.com/wiki/waypointScript","revid":377751,"updated":"2026-01-03T00:58:05Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint script.","syntaxes":[{"syntax":"waypointScript waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointScript [groupOne,1];\n```","code":["waypointScript [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointScript"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointsEnabledUAV","operator":null,"title":"waypointsEnabledUAV","type":"command","url":"https://community.bistudio.com/wiki/waypointsEnabledUAV","revid":369353,"updated":"2024-09-03T18:43:04Z","groups":["Waypoints","Remote Control"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.40"}],"since":{"game":"arma3","name":"Arma 3","version":"1.40"},"arma3_since":"1.40","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Checks if the UAV has waypoints enabled.","syntaxes":[{"syntax":"waypointsEnabledUAV uav","since":null,"effect":null,"exec":null,"params":[{"name":"uav","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"uav: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"uav","types":["Object"]}}],"examples":[{"text":"```sqf\n_uav enableUAVWaypoints false;\nhint str waypointsEnabledUAV _uav; // returns false\n```","code":["_uav enableUAVWaypoints false;\nhint str waypointsEnabledUAV _uav; // returns false"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableUAVWaypoints","enableUAVConnectability","disableUAVConnectability","isUAVConnected","isUAVConnectable","allUnitsUAV","getConnectedUAV","connectTerminalToUAV"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Remote Control","Command Group: Waypoints","Introduced with Arma 3 version 1.40","Scripting Commands"]},{"name":"waypointShow","operator":null,"title":"waypointShow","type":"command","url":"https://community.bistudio.com/wiki/waypointShow","revid":378529,"updated":"2026-05-04T02:16:33Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for showWaypoint command.","syntaxes":[{"syntax":"waypointShow waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":"can return: - \"NEVER\" - Never show - \"EASY\" - Show only in cadet mode - \"ALWAYS\" - Always show - \"ERROR\" - When set to any different string","text":"String - can return:\n- \"NEVER\" - Never show\n- \"EASY\" - Show only in cadet mode\n- \"ALWAYS\" - Always show\n- \"ERROR\" - When set to any different string"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_wpShow = waypointShow [groupOne, 1];\n```","code":["_wpShow = waypointShow [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showWaypoint","waypoints","waypointVisible","setWaypointVisible"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointSpeed","operator":null,"title":"waypointSpeed","type":"command","url":"https://community.bistudio.com/wiki/waypointSpeed","revid":377740,"updated":"2026-01-03T00:57:48Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint speed.\n\nPossible values are:\n- \"UNCHANGED\"\n- \"LIMITED\"\n- \"NORMAL\"\n- \"FULL\"","syntaxes":[{"syntax":"waypointSpeed waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"String","types":["String"],"description":"see description","text":"String - see description"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_speed = waypointSpeed [groupOne,1];\n```","code":["_speed = waypointSpeed [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointTimeout","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","waypoints","setWPPos","waypointName"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointStatements","operator":null,"title":"waypointStatements","type":"command","url":"https://community.bistudio.com/wiki/waypointStatements","revid":377581,"updated":"2026-01-02T06:56:38Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint statements.","syntaxes":[{"syntax":"waypointStatements waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Array with [condition, statement]","types":["Array"],"description":"condition: String - statement: String","text":"Array with [condition, statement]\n- condition: String\n- statement: String"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointStatements [groupOne,1];\n```","code":["waypointStatements [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointStatements"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointTimeout","operator":null,"title":"waypointTimeout","type":"command","url":"https://community.bistudio.com/wiki/waypointTimeout","revid":377668,"updated":"2026-01-02T09:02:25Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint timeout values.","syntaxes":[{"syntax":"waypointTimeout waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Array with [min, mid, max]","types":["Array"],"description":"min: Number - mid: Number - max: Number","text":"Array with [min, mid, max]\n- min: Number\n- mid: Number\n- max: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nwaypointTimeout [groupOne,1];\n```","code":["waypointTimeout [groupOne,1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointTimeout"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointTimeoutCurrent","operator":null,"title":"waypointTimeoutCurrent","type":"command","url":"https://community.bistudio.com/wiki/waypointTimeoutCurrent","revid":319799,"updated":"2022-05-13T09:25:29Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.08"}],"since":{"game":"arma3","name":"Arma 3","version":"1.08"},"arma3_since":"1.08","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the current timeout for currentWaypoint of a group or -1 if countdown is not in progress.","syntaxes":[{"syntax":"waypointTimeoutCurrent group","since":null,"effect":null,"exec":null,"params":[{"name":"group","type":"Group","optional":false,"default":null,"description":null,"types":["Group"],"since":null,"text":"group: Group"}],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"unary","operator":null,"left":null,"right":{"text":"group","types":["Group"]}}],"examples":[{"text":"```sqf\n_timeout = waypointTimeoutCurrent group player;\n```","code":["_timeout = waypointTimeoutCurrent group player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","deleteWaypoint","copyWaypoints","setCurrentWaypoint","setWaypointBehaviour","setWaypointCombatMode","setWaypointCompletionRadius","setWaypointDescription","setWaypointFormation","setWaypointHousePosition","setWaypointPosition","setWaypointScript","setWaypointSpeed","setWaypointStatements","setWaypointType","setWaypointVisible","waypointAttachVehicle","waypointAttachedVehicle","setWaypointLoiterRadius","waypointLoiterRadius","addWaypoint","setWaypointLoiterType","setWaypointTimeout"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 3 version 1.08","Scripting Commands"]},{"name":"waypointType","operator":null,"title":"waypointType","type":"command","url":"https://community.bistudio.com/wiki/waypointType","revid":377748,"updated":"2026-01-03T00:58:01Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Gets the waypoint type.\n\n> [!NOTE]\n> See Waypoints#Waypoint Types for more information.","syntaxes":[{"syntax":"waypointType waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint:  Waypoint"}],"returns":{"type":"String","types":["String"],"description":"returns `\"\"` if the waypoint doesn't exist.","text":"String - returns `\"\"` if the waypoint doesn't exist."},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\nprivate _type = waypointType [groupOne, 1];\n```","code":["private _type = waypointType [groupOne, 1];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Mission Editor: Waypoints","Waypoints","waypoints","setWaypointType"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"waypointVisible","operator":null,"title":"waypointVisible","type":"command","url":"https://community.bistudio.com/wiki/waypointVisible","revid":377744,"updated":"2026-01-03T00:57:55Z","groups":["Waypoints"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.55"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"A getter for setWaypointVisible command.\n\n> [!WARNING]\n> Returns **0** (Number) instead of Booleanfor an invalid waypoint.","syntaxes":[{"syntax":"waypointVisible waypoint","since":null,"effect":null,"exec":null,"params":[{"name":"waypoint","type":"Waypoint","optional":false,"default":null,"description":null,"types":["Waypoint"],"since":null,"text":"waypoint: Waypoint"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"waypoint","types":["Waypoint"]}}],"examples":[{"text":"```sqf\n_visible = waypointVisible [groupOne, 1];\n```","code":["_visible = waypointVisible [groupOne, 1];"]},{"text":"```sqf\n_visible = waypointVisible [group player, currentWaypoint group player];\n```","code":["_visible = waypointVisible [group player, currentWaypoint group player];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["waypoints","setWaypointVisible"],"notes":[],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Waypoints","Introduced with Arma 2: Operation Arrowhead version 1.55","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"weaponAccessories","operator":null,"title":"weaponAccessories","type":"command","url":"https://community.bistudio.com/wiki/weaponAccessories","revid":353156,"updated":"2024-03-12T12:48:33Z","groups":["Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with all items linked to a given weapon.\n\n> [!IMPORTANT]\n> This command does not return loaded magazines, see weaponsItems","syntaxes":[{"syntax":"unit weaponAccessories weapon","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weapon","type":"String","optional":false,"default":null,"description":"primary, secondary or handgun","types":["String"],"since":null,"text":"weapon: String - primary, secondary or handgun"}],"returns":{"type":"Array","types":["Array"],"description":"[silencer, laserpointer/flashlight, optics, bipod]","text":"Array - [silencer, laserpointer/flashlight, optics, bipod]"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weapon","types":["String"]}}],"examples":[{"text":"```sqf\nplayer weaponAccessories primaryWeapon player; //[\"\",\"acc_pointer_IR\",\"optic_Aco\",\"\"]\n```","code":["player weaponAccessories primaryWeapon player; //[\"\",\"acc_pointer_IR\",\"optic_Aco\",\"\"]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponAccessoriesCargo","handgunItems","primaryWeaponItems","secondaryWeaponItems","weaponsItems","weaponsItemsCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"weaponAccessoriesCargo","operator":null,"title":"weaponAccessoriesCargo","type":"command","url":"https://community.bistudio.com/wiki/weaponAccessoriesCargo","revid":352198,"updated":"2024-02-01T23:26:01Z","groups":["Vehicle Inventory","Containers","Unit Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array with all items assigned to the given weapon in given cargo container.\n\n> [!WARNING]\n> This is unofficial documentation. All Information here is as it exists in the Engine. It might not reflect the reality.","syntaxes":[{"syntax":"container weaponAccessoriesCargo [weaponId, creatorId]","since":null,"effect":null,"exec":null,"params":[{"name":"container","type":"Object","optional":false,"default":null,"description":"cargo container","types":["Object"],"since":null,"text":"container: Object - cargo container"},{"name":"weaponId","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"weaponId: Number"},{"name":"creatorId","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"creatorId: Number"}],"returns":{"type":"Array","types":["Array"],"description":"[silencer, laserpointer/flashlight, optics, bipod]","text":"Array - [silencer, laserpointer/flashlight, optics, bipod]"},"form":"binary","operator":null,"left":{"text":"container","types":["Object"]},"right":{"text":"[weaponId, creatorId]","types":["Array"]}}],"examples":[{"text":"-","code":[]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponAccessories","primaryWeaponItems","handgunItems","secondaryWeaponItems","weaponsItems","weaponsItemsCargo","removeWeaponAttachmentCargo","removeWeaponCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"weaponCargo","operator":null,"title":"weaponCargo","type":"command","url":"https://community.bistudio.com/wiki/weaponCargo","revid":310284,"updated":"2022-05-05T13:11:26Z","groups":["Vehicle Inventory","Unit Inventory","Containers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Get array with weapons from ammo box (or any general weapon holder container).","syntaxes":[{"syntax":"weaponCargo box","since":null,"effect":null,"exec":null,"params":[{"name":"box","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"box: Object"}],"returns":{"type":"Array of String","types":["Array","String"],"description":"list of present classes","text":"Array of String - list of present classes"},"form":"unary","operator":null,"left":null,"right":{"text":"box","types":["Object"]}}],"examples":[{"text":"```sqf\nhint str weaponCargo backpackContainer player;\n```","code":["hint str weaponCargo backpackContainer player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getWeaponCargo","addWeaponCargo","addWeaponCargoGlobal","clearWeaponCargo","clearWeaponCargoGlobal","magazineCargo","itemCargo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"weaponDirection","operator":null,"title":"weaponDirection","type":"command","url":"https://community.bistudio.com/wiki/weaponDirection","revid":377763,"updated":"2026-01-03T00:59:33Z","groups":["Weapons","Unit Control"],"status":"ok","replaced_by":[],"games":[{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns the direction that the vehicle weapon is aiming in. For addons the weapon name must be an entry in CfgWeapons.\n\n> [!NOTE]\n> Turret and gun angle in degrees can also be obtained using animationSourcePhase or animationPhase commands.","syntaxes":[{"syntax":"vehicleName weaponDirection weaponName","since":null,"effect":null,"exec":null,"params":[{"name":"vehicleName","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicleName: Object"},{"name":"weaponName","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponName: String"}],"returns":{"type":"Vector3D","types":["Vector3D"],"description":null,"text":"Vector3D"},"form":"binary","operator":null,"left":{"text":"vehicleName","types":["Object"]},"right":{"text":"weaponName","types":["String"]}}],"examples":[{"text":"```sqf\n_weaponVectorDir = player weaponDirection currentWeapon player;\n```","code":["_weaponVectorDir = player weaponDirection currentWeapon player;"]},{"text":"Draw AI eye direction (green) and weapon direction (red) in 3D:\n\n```sqf\nbob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nbob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame\n{\n    _beg = ASLToAGL eyePos bob;\n    _endE = _beg vectorAdd (eyeDirection bob vectorMultiply 100);\n    drawLine3D [_beg, _endE, [0,1,0,1]];\n    _endW = _beg vectorAdd (bob weaponDirection currentWeapon bob vectorMultiply 100);\n    drawLine3D [_beg, _endW, [1,0,0,1]];\n};\n```","code":["bob = createGroup east createUnit [\"O_Soldier_F\", [0,0,0], [], 0, \"NONE\"];\nbob setVehiclePosition [player modelToWorld [0,100,0], [], 0, \"NONE\"];\nonEachFrame\n{\n\t_beg = ASLToAGL eyePos bob;\n\t_endE = _beg vectorAdd (eyeDirection bob vectorMultiply 100);\n\tdrawLine3D [_beg, _endE, [0,1,0,1]];\n\t_endW = _beg vectorAdd (bob weaponDirection currentWeapon bob vectorMultiply 100);\n\tdrawLine3D [_beg, _endW, [1,0,0,1]];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["positionCameraToWorld","getCameraViewDirection","eyeDirection","vectorDir","vectorDirVisual"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Control","Command Group: Weapons","Introduced with Operation Flashpoint: Elite version 1.00","Operation Flashpoint: Elite: New Scripting Commands","Operation Flashpoint: Elite: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"weaponDisassemblyEnabled","operator":null,"title":"weaponDisassemblyEnabled","type":"command","url":"https://community.bistudio.com/wiki/weaponDisassemblyEnabled","revid":347215,"updated":"2023-09-05T16:49:02Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.14"}],"since":{"game":"arma3","name":"Arma 3","version":"2.14"},"arma3_since":"2.14","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns if weapon disassembly is enabled. As disassembly can be enabled/disabled on both player and weapon, it might be necessary to check both.\n\n> [!IMPORTANT]\n> Beware that when the weapon disassembly is disabled on the player, it is tracking the unit itself.\n> If the player leaves the server and another player joins into the same playable unit, they will not have the option to disassemble either.","syntaxes":[{"syntax":"weaponDisassemblyEnabled entity","since":null,"effect":null,"exec":null,"params":[{"name":"entity","type":"Object","optional":false,"default":null,"description":"player or weapon","types":["Object"],"since":null,"text":"entity: Object - player or weapon"}],"returns":{"type":"Boolean","types":["Boolean"],"description":"true if enabled","text":"Boolean - true if enabled"},"form":"unary","operator":null,"left":null,"right":{"text":"entity","types":["Object"]}}],"examples":[{"text":"```sqf\nprivate _enabled = weaponDisassemblyEnabled player && weaponDisassemblyEnabled _weapon;\n```","code":["private _enabled = weaponDisassemblyEnabled player && weaponDisassemblyEnabled _weapon;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["enableWeaponDisassembly","weapons","action","inGameUISetEventHandler"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.14","Scripting Commands"]},{"name":"weaponInertia","operator":null,"title":"weaponInertia","type":"command","url":"https://community.bistudio.com/wiki/weaponInertia","revid":378476,"updated":"2026-04-24T11:32:50Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current rate of how much the weapon view is distorted because of quick aiming.","syntaxes":[{"syntax":"weaponInertia unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [x, y]","types":["Array"],"description":"x: Number - Amount of x-axis sway - y: Number - Amount of y-axis sway","text":"Array with [x, y]\n- x: Number - Amount of x-axis sway\n- y: Number - Amount of y-axis sway"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_inertia = weaponInertia player; //[-0.0126307,0.038023]\n```","code":["_inertia = weaponInertia player; //[-0.0126307,0.038023]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getWeaponSway"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"weaponLowered","operator":null,"title":"weaponLowered","type":"command","url":"https://community.bistudio.com/wiki/weaponLowered","revid":341169,"updated":"2023-05-13T22:13:14Z","groups":["Object Manipulation","Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns true if given soldier's weapon is lowered. \n\n> [!IMPORTANT]\n> This command will **always** return false if player is sprinting, even without a weapon. Alternatively, the weapon raised state could be obtained via animationState command `...slow...` vs `...sras...`","syntaxes":[{"syntax":"weaponLowered unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\nisWeaponLowered = weaponLowered player;\n```","code":["isWeaponLowered = weaponLowered player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["stance","unitPos","animationState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Command Group: Weapons","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"weaponReloadingTime","operator":null,"title":"weaponReloadingTime","type":"command","url":"https://community.bistudio.com/wiki/weaponReloadingTime","revid":349603,"updated":"2023-11-14T14:16:56Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.06"}],"since":{"game":"arma3","name":"Arma 3","version":"2.06"},"arma3_since":"2.06","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns current ammo round reloading phase. For a magazine reloading phase see weaponState command.","syntaxes":[{"syntax":"vehicle weaponReloadingTime [gunner, muzzleName]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"gunner","type":"Object","optional":false,"default":null,"description":"gunner of desired turret","types":["Object"],"since":null,"text":"gunner: Object - gunner of desired turret"},{"name":"muzzleName","type":"String","optional":false,"default":null,"description":"muzzle on desired turret","types":["String"],"since":null,"text":"muzzleName: String - muzzle on desired turret"}],"returns":{"type":"Number","types":["Number"],"description":"ammo round reload phase in range 0..1; -1 when N/A","text":"Number - ammo round reload phase in range 0..1; -1 when N/A"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"[gunner, muzzleName]","types":["Array"]}}],"examples":[],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWeaponReloadingTime","weaponState","weaponsInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.06","Scripting Commands"]},{"name":"weapons","operator":null,"title":"weapons","type":"command","url":"https://community.bistudio.com/wiki/weapons","revid":369614,"updated":"2024-09-26T21:03:08Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.75"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns array of names of all unit's weapons.","syntaxes":[{"syntax":"weapons unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":"weapon class names","text":"Array of Strings - weapon class names"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}}],"examples":[{"text":"```sqf\n_wArray = weapons player;\n```","code":["_wArray = weapons player;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["magazines","weaponsTurret","assignedVehicleRole","weaponState"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Operation Flashpoint version 1.75","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"weaponsInfo","operator":null,"title":"weaponsInfo","type":"command","url":"https://community.bistudio.com/wiki/weaponsInfo","revid":377065,"updated":"2026-01-01T09:09:48Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.10"}],"since":{"game":"arma3","name":"Arma 3","version":"2.10"},"arma3_since":"2.10","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns entity's weapons information including weapon index and firemode.","syntaxes":[{"syntax":"unit weaponsInfo [weaponOrMuzzle, onlyLoaded]","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":"person","types":["Object"],"since":null,"text":"unit: Object - person"},{"name":"weaponOrMuzzle","type":"String","optional":false,"default":null,"description":"name of the weapon or muzzle (returns whichever matches first) or \"\" to return all weapons","types":["String"],"since":null,"text":"weaponOrMuzzle: String - name of the weapon or muzzle (returns whichever matches first) or \"\" to return all weapons"},{"name":"onlyLoaded","type":"Boolean","optional":true,"default":"false","description":"true to return loaded weapons only","types":["Boolean"],"since":null,"text":"onlyLoaded: Boolean - (Optional, default false) true to return loaded weapons only"}],"returns":{"type":"Array of Arrays with [weaponIndex, isSelected, weaponName, muzzleName, firemode, magazineName, ammoCount, isPrimary] (or an empty []):","types":["Array"],"description":"weaponIndex: Number - internal weapon index (changes frequently) used with \"SwitchWeapon\" and \"UseWeapon\" actions - isSelected: Boolean - true if this weapon is currently selected - weaponName: String - weapon name - muzzleName: String - muzzle name - firemode: String - firemode that is set for this 'weaponIndex' - magazineName: String - name of the loaded magazine or \"\" - ammoCount: Number - magazine ammo count or -1 - isPrimary: Boolean - true if this muzzle is considered primary by the engine (Since Arma 3 2.14)","text":"Array of Arrays with [weaponIndex, isSelected, weaponName, muzzleName, firemode, magazineName, ammoCount, isPrimary] (or an empty []):\n- weaponIndex: Number - internal weapon index (changes frequently) used with \"SwitchWeapon\" and \"UseWeapon\" actions\n- isSelected: Boolean - true if this weapon is currently selected\n- weaponName: String - weapon name\n- muzzleName: String - muzzle name\n- firemode: String - firemode that is set for this 'weaponIndex'\n- magazineName: String - name of the loaded magazine or \"\"\n- ammoCount: Number - magazine ammo count or -1\n- isPrimary: Boolean - true if this muzzle is considered primary by the engine (Since Arma 3 2.14)"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"[weaponOrMuzzle, onlyLoaded]","types":["Array"]}}],"examples":[{"text":"Find weapon with FullAuto firemode and switch to it: \n\n```sqf\nprivate _weapons = player weaponsInfo [currentMuzzle player, true];\nprivate _found = _weapons findIf { _x select 4 == \"FullAuto\" };\nif (_found > -1) then { action [\"SwitchWeapon\", player, player, _weapons select _found select 0] };\n```","code":["private _weapons = player weaponsInfo [currentMuzzle player, true];\nprivate _found = _weapons findIf { _x select 4 == \"FullAuto\" };\nif (_found > -1) then { action [\"SwitchWeapon\", player, player, _weapons select _found select 0] };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponState","weaponReloadingTime","action"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 2.10","Scripting Commands"]},{"name":"weaponsItems","operator":null,"title":"weaponsItems","type":"command","url":"https://community.bistudio.com/wiki/weaponsItems","revid":369242,"updated":"2024-09-03T10:35:40Z","groups":["Unit Inventory","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.76"}],"since":{"game":"arma3","name":"Arma 3","version":"0.76"},"arma3_since":"0.76","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with subarrays contains class names and also names of connected items of all the vehicle's weapons.\n\n> [!NOTE]\n> This command can return weapon magazine(s) if any are present. Or an empty array if weapon is stored without a magazine in it.\n\n- Arma 3 v1.22 it is possible to query weapon holders and ammo crates with this command.\nIf the argument is a vehicle, the command will return vehicle's weapons.\nIf the argument is a container, the command will act identical to weaponsItemsCargo.\n- Arma 3 v1.96 the returned array always contains secondary muzzle magazine info and consistent with getUnitLoadout format for weapon items.\n- Arma 3 v2.02 the returned array can contains binocular weapon items.","syntaxes":[{"syntax":"weaponsItems vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"}],"returns":{"type":"Array of Arrays of weapon items, format [weapon, muzzle, flashlight, optics, [magazine, ammo], [magazine, ammo], bipod]:","types":["Array"],"description":"weapon: String - muzzle: String - flashlight: String - optics: String - [primaryMagazine, primaryAmmo]: Array - could be empty - [secondaryMagazine, secondaryAmmo]: Array - could be empty - bipod: String > [!IMPORTANT] > The weapons are listed in the order they were taken by the unit, with the most recent at the bottom of the array, e.g do not assume the first item is always the primary weapon.","text":"Array of Arrays of weapon items, format [weapon, muzzle, flashlight, optics, [magazine, ammo], [magazine, ammo], bipod]:\n- weapon: String\n- muzzle: String\n- flashlight: String\n- optics: String\n- [primaryMagazine, primaryAmmo]: Array - could be empty\n- [secondaryMagazine, secondaryAmmo]: Array - could be empty\n- bipod: String\n\n> [!IMPORTANT]\n> The weapons are listed in the order they were taken by the unit, with the most recent at the bottom of the array, e.g do **not** assume the first item is always the primary weapon."},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"weaponsItems [vehicle, extended]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"unit or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - unit or vehicle"},{"name":"extended","type":"Boolean","optional":false,"default":null,"description":"true to include muzzle information","types":["Boolean"],"since":null,"text":"extended: Boolean - true to include muzzle information"}],"returns":{"type":null,"types":["Array"],"description":null,"text":"Array of Arrays (see above) in format [weapon, muzzle, flashlight, optics, [magazine, ammo, muzzle, maxammo], [magazine, ammo, muzzle, maxammo], bipod]"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, extended]","types":["Array"]}}],"examples":[{"text":"```sqf\nhint str weaponsItems player;\n// returns e.g\n/*\n[\n    [\"arifle_MX_ACO_pointer_F\", \"muzzle_snds_H\", \"acc_pointer_IR\", \"optic_Aco\", [\"30Rnd_65x39_caseless_mag\", 30], [], \"bipod_01_F_blk\"],\n    [\"launch_NLAW_F\", \"\", \"\", \"\", [\"NLAW_F\", 1], [], \"\"],\n    [\"hgun_P07_F\", \"muzzle_snds_L\", \"\", \"\", [\"16Rnd_9x21_Mag\", 11], [], \"\"]\n]\n// a loaded underbarrel grenade launcher can look like this:\n[\n    [\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"acc_pointer_IR\", \"optic_Aco\", [\"30Rnd_65x39_caseless_mag\", 30], [\"1Rnd_HE_Grenade_shell\", 1], \"\"]\n]\n*/\n```","code":["hint str weaponsItems player;\n// returns e.g\n/*\n[\n\t[\"arifle_MX_ACO_pointer_F\", \"muzzle_snds_H\", \"acc_pointer_IR\", \"optic_Aco\", [\"30Rnd_65x39_caseless_mag\", 30], [], \"bipod_01_F_blk\"],\n\t[\"launch_NLAW_F\", \"\", \"\", \"\", [\"NLAW_F\", 1], [], \"\"],\n\t[\"hgun_P07_F\", \"muzzle_snds_L\", \"\", \"\", [\"16Rnd_9x21_Mag\", 11], [], \"\"]\n]\n// a loaded underbarrel grenade launcher can look like this:\n[\n\t[\"arifle_MX_GL_F\", \"muzzle_snds_H\", \"acc_pointer_IR\", \"optic_Aco\", [\"30Rnd_65x39_caseless_mag\", 30], [\"1Rnd_HE_Grenade_shell\", 1], \"\"]\n]\n*/"]},{"text":"```sqf\nhint str weaponsItems vehicle player;\n// returns e.g\n/*\n[\n    [\"gatling_30mm\", \"\", \"\", \"\", [\"250Rnd_30mm_HE_shells\", 250], [], \"\"],\n    [\"missiles_SCALPEL\", \"\", \"\", \"\", [\"8Rnd_LG_scalpel\", 8], [], \"\"],\n    [\"rockets_Skyfire\", \"\", \"\", \"\", [\"38Rnd_80mm_rockets\", 38], [], \"\"]\n]\n*/\n```","code":["hint str weaponsItems vehicle player;\n// returns e.g\n/*\n[\n\t[\"gatling_30mm\", \"\", \"\", \"\", [\"250Rnd_30mm_HE_shells\", 250], [], \"\"],\n\t[\"missiles_SCALPEL\", \"\", \"\", \"\", [\"8Rnd_LG_scalpel\", 8], [], \"\"],\n\t[\"rockets_Skyfire\", \"\", \"\", \"\", [\"38Rnd_80mm_rockets\", 38], [], \"\"]\n]\n*/"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponsItemsCargo","primaryWeaponItems","secondaryWeaponItems","handgunItems","addPrimaryWeaponItem","addSecondaryWeaponItem","addHandgunItem","primaryWeapon","secondaryWeapon","handgunWeapon","binocular","weaponAccessories","addWeaponWithAttachmentsCargoGlobal","BIS_fnc_weaponComponents","weaponState"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Unit Inventory","Command Group: Vehicle Inventory","Introduced with Arma 3 version 0.76","Scripting Commands"]},{"name":"weaponsItemsCargo","operator":null,"title":"weaponsItemsCargo","type":"command","url":"https://community.bistudio.com/wiki/weaponsItemsCargo","revid":378085,"updated":"2026-02-12T12:40:27Z","groups":["Containers","Vehicle Inventory"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.22"}],"since":{"game":"arma3","name":"Arma 3","version":"1.22"},"arma3_since":"1.22","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns an array with subarrays contains class names and also names of connected items of all the vehicle's cargo weapons in weaponsItems format. If weapon has no magazine, an empty array [] is returned instead of magazine info. If the argument is a vehicle with weapons, vehicles cargo is searched, unlike with weaponsItems command, which will return vehicle's weapons instead.\n\n> [!NOTE]\n> Since Arma 3 v1.96 the returned array always contains secondary muzzle magazine info and is consistent with getUnitLoadout format for weapon items.","syntaxes":[{"syntax":"weaponsItemsCargo vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object ammobox or vehicle","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object ammobox or vehicle"}],"returns":{"type":"Array","types":["Array"],"description":"see weaponsItems","text":"Array - see weaponsItems"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}},{"syntax":"weaponsItemsCargo [vehicle, extended]","since":"arma3 2.14","effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"ammobox or vehicle","types":["Object"],"since":null,"text":"vehicle: Object - ammobox or vehicle"},{"name":"extended","type":"Boolean","optional":false,"default":null,"description":"true to include muzzle information","types":["Boolean"],"since":null,"text":"extended: Boolean - true to include muzzle information"}],"returns":{"type":"Array","types":["Array"],"description":"see weaponsItems","text":"Array - see weaponsItems"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, extended]","types":["Array"]}}],"examples":[{"text":"```sqf\nweaponsItemsCargo vehicle player;\n```","code":["weaponsItemsCargo vehicle player;"]},{"text":"```sqf\nweaponsItemsCargo _weaponholder;\n```","code":["weaponsItemsCargo _weaponholder;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weaponsItems","primaryWeaponItems","secondaryWeaponItems","handgunItems","addPrimaryWeaponItem","addSecondaryWeaponItem","addHandgunItem","primaryWeapon","secondaryWeapon","handgunWeapon","weaponAccessories","weaponAccessoriesCargo","addWeaponWithAttachmentsCargoGlobal"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Containers","Command Group: Vehicle Inventory","Introduced with Arma 3 version 1.22","Scripting Commands"]},{"name":"weaponState","operator":null,"title":"weaponState","type":"command","url":"https://community.bistudio.com/wiki/weaponState","revid":378932,"updated":"2026-08-19T22:08:00Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.60"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the given or currently selected weapon state for unit or vehicle.\nWith #Syntax 2, if no optional arguments are present, currently selected weapon is queried.\n\n> [!NOTE]\n> **Arma 3:** Since Arma 3 v1.70 this command has been improved and extended:\n> - A vehicle's weapon query doesn't need a weapon operator provided the weapon or muzzle is specified in optional param.\n> (keep in mind that by default a vehicle has no weapons selected)\n> - Driver turret can now be accessed as well with turret path [-1].\n> - Muzzle name is supported as well as weapon name. The command searches for weapon first, then if not found, muzzle is searched for.","syntaxes":[{"syntax":"weaponState unit","since":null,"effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"}],"returns":{"type":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]","types":["Array"],"description":"weapon: String - muzzle: String - firemode: String - magazine: String - ammoCount: Number - Arma 3 v2.06 roundReloadPhase: Number in range -1 or 0..1 - current ammo round reload phase (see weaponReloadingTime). -1 when weapon has magazine removed - Arma 3 v2.06 magazineReloadPhase: Number in range 1..0 - current magazine reload phase, 0 - reload complete. > 0 - reload in progress","text":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]\n- weapon: String\n- muzzle: String\n- firemode: String\n- magazine: String\n- ammoCount: Number\n- Arma 3 v2.06 roundReloadPhase: Number in range -1 or 0..1 - current ammo round reload phase (see weaponReloadingTime). -1 when weapon has magazine removed\n- Arma 3 v2.06 magazineReloadPhase: Number in range 1..0 - current magazine reload phase, 0 - reload complete. > 0 - reload in progress"},"form":"unary","operator":null,"left":null,"right":{"text":"unit","types":["Object"]}},{"syntax":"weaponState [vehicle, turretPath, weapon, muzzle, firemode]","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"},{"name":"weapon","type":"String","optional":true,"default":"`\"\"`","description":"weapon or muzzle name","types":["String"],"since":"arma3 1.70","text":"weapon: String - (Optional, default `\"\"`) weapon or muzzle name"},{"name":"muzzle","type":"String","optional":true,"default":"`\"\"`","description":"muzzle name","types":["String"],"since":"arma3 2.08","text":"muzzle: String - (Optional, default `\"\"`) muzzle name"},{"name":"firemode","type":"String","optional":true,"default":"`\"\"`","description":"firemode name","types":["String"],"since":"arma3 2.08","text":"firemode: String - (Optional, default `\"\"`) firemode name"}],"returns":{"type":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]","types":["Array"],"description":"weapon: String - muzzle: String - firemode: String - magazine: String - ammoCount: Number - Arma 3 v2.06 roundReloadPhase: Number - current ammo round reload phase (see weaponReloadingTime) - Arma 3 v2.06 magazineReloadPhase: Number - current magazine reload phase from 1 to 0, 0 - reload complete. > 0 - reload in progress","text":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]\n- weapon: String\n- muzzle: String\n- firemode: String\n- magazine: String\n- ammoCount: Number\n- Arma 3 v2.06 roundReloadPhase: Number - current ammo round reload phase (see weaponReloadingTime)\n- Arma 3 v2.06 magazineReloadPhase: Number - current magazine reload phase from 1 to 0, 0 - reload complete. > 0 - reload in progress"},"form":"unary","operator":null,"left":null,"right":{"text":"[vehicle, turretPath, weapon, muzzle, firemode]","types":["Array"]}},{"syntax":"unit weaponState weaponOrMuzzle","since":"arma3 2.06","effect":null,"exec":null,"params":[{"name":"unit","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"unit: Object"},{"name":"weaponOrMuzzle","type":"String","optional":false,"default":null,"description":null,"types":["String"],"since":null,"text":"weaponOrMuzzle: String"}],"returns":{"type":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]","types":["Array"],"description":"weapon: String - muzzle: String - firemode: String - magazine: String - ammoCount: Number - Arma 3 v2.06 roundReloadPhase: Number - current ammo round reload phase (see weaponReloadingTime) - Arma 3 v2.06 magazineReloadPhase: Number - current magazine reload phase from 1 to 0, 0 - reload complete. > 0 - reload in progress","text":"Array with [weapon, muzzle, firemode, magazine, ammoCount, roundReloadPhase, magazineReloadPhase]\n- weapon: String\n- muzzle: String\n- firemode: String\n- magazine: String\n- ammoCount: Number\n- Arma 3 v2.06 roundReloadPhase: Number - current ammo round reload phase (see weaponReloadingTime)\n- Arma 3 v2.06 magazineReloadPhase: Number - current magazine reload phase from 1 to 0, 0 - reload complete. > 0 - reload in progress"},"form":"binary","operator":null,"left":{"text":"unit","types":["Object"]},"right":{"text":"weaponOrMuzzle","types":["String"]}}],"examples":[{"text":"```sqf\n_wsPlayer = weaponState player;                    // [\"arifle_MXC_ACO_F\",\"arifle_MXC_ACO_F\",\"Single\",\"30Rnd_65x39_caseless_mag\",30,0,0]\n```","code":["_wsPlayer = weaponState player;\t\t\t\t\t// [\"arifle_MXC_ACO_F\",\"arifle_MXC_ACO_F\",\"Single\",\"30Rnd_65x39_caseless_mag\",30,0,0]"]},{"text":"Query currently selected gunner weapon:\n\n```sqf\n_wsVehicle = weaponState [_apc, [0]];            // [\"autocannon_40mm_CTWS\",\"HE\",\"player\",\"60Rnd_40mm_GPR_Tracer_Red_shells\",60,0,0]\n```","code":["_wsVehicle = weaponState [_apc, [0]];\t\t\t// [\"autocannon_40mm_CTWS\",\"HE\",\"player\",\"60Rnd_40mm_GPR_Tracer_Red_shells\",60,0,0]"]},{"text":"```sqf\n_wsVehicle = weaponState [_apc, [0], \"AP\"];        // [\"autocannon_40mm_CTWS\",\"AP\",\"player\",\"40Rnd_40mm_APFSDS_Tracer_Red_shells\",40,0,0]\n```","code":["_wsVehicle = weaponState [_apc, [0], \"AP\"];\t\t// [\"autocannon_40mm_CTWS\",\"AP\",\"player\",\"40Rnd_40mm_APFSDS_Tracer_Red_shells\",40,0,0]"]},{"text":"```sqf\n_wsPlayer = player weaponState \"GL_3GL_F\";        // [\"arifle_MX_GL_ACO_F\",\"GL_3GL_F\",\"Single\",\"1Rnd_HE_Grenade_shell\",1,0,0]\n```","code":["_wsPlayer = player weaponState \"GL_3GL_F\";\t\t// [\"arifle_MX_GL_ACO_F\",\"GL_3GL_F\",\"Single\",\"1Rnd_HE_Grenade_shell\",1,0,0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["weapons","selectWeaponTurret","loadMagazine","magazinesTurret","weaponsTurret","weaponReloadingTime"],"notes":[{"user":"AgentRev","date":"2022-03-31T04:08:09Z","text":"In the case of a GL rifle, if the rifle is currently in GL mode, syntax 3 will return the same result for either muzzle:\n\n```sqf\nplayer selectWeapon \"GL_3GL_F\";\n_state = player weaponState \"arifle_MX_GL_ACO_F\";    // [\"arifle_MX_GL_ACO_F\",\"GL_3GL_F\",\"Single\",\"1Rnd_HE_Grenade_shell\",1,0,0]\n_state = player weaponState \"GL_3GL_F\";                // [\"arifle_MX_GL_ACO_F\",\"GL_3GL_F\",\"Single\",\"1Rnd_HE_Grenade_shell\",1,0,0]\n```\n\nIn rifle mode, the result is different:\n\n```sqf\nplayer selectWeapon \"arifle_MX_GL_ACO_F\";\n_state = player weaponState \"arifle_MX_GL_ACO_F\";    // [\"arifle_MX_GL_ACO_F\",\"arifle_MX_GL_ACO_F\",\"Single\",\"30Rnd_65x39_caseless_mag\",30,0,0]\n_state = player weaponState \"GL_3GL_F\";                // [\"arifle_MX_GL_ACO_F\",\"GL_3GL_F\",\"Single\",\"1Rnd_HE_Grenade_shell\",1,0,0]\n```\n\nTherefore, in order to gather all states of one multi-muzzle weapon, we have to do some masochistic stuff:\n\n```sqf\nfn_getWeaponStates =\n{\n    params [\"_unit\", \"_weapon\"];\n    private _origState = weaponState _unit select [0,3];\n    private _muzzles = [_weapon] + (getArray (configFile >> \"CfgWeapons\" >> _weapon >> \"muzzles\") select { _x != \"this\" });\n    private _states = [];\n\n    {\n        _unit selectWeapon _x;\n        _states pushBack weaponState _unit;\n    } forEach _muzzles;\n\n    _unit selectWeapon _origState;\n    _states;\n};\n\nprivate _result = [player, primaryWeapon player] call fn_getWeaponStates;\n/*\n    [\n        [\"arifle_MX_GL_ACO_F\", \"arifle_MX_GL_ACO_F\", \"Single\", \"30Rnd_65x39_caseless_mag\", 30, 0, 0],\n        [\"arifle_MX_GL_ACO_F\", \"GL_3GL_F\", \"Single\", \"1Rnd_HE_Grenade_shell\", 1, 0, 0]\n    ]\n*/\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 2: Operation Arrowhead version 1.60","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"weaponsTurret","operator":null,"title":"weaponsTurret","type":"command","url":"https://community.bistudio.com/wiki/weaponsTurret","revid":377486,"updated":"2026-01-02T06:49:06Z","groups":["Turrets"],"status":"ok","replaced_by":[],"games":[{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.52"},"arma3_since":"0.50","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"description":"Returns all weapons of a given turret. Use turret path [-1] for driver's turret.","syntaxes":[{"syntax":"vehicle weaponsTurret turretPath","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"vehicle: Object"},{"name":"turretPath","type":"Turret Path","optional":false,"default":null,"description":null,"types":["Turret Path"],"since":null,"text":"turretPath: Turret Path"}],"returns":{"type":"Array of Strings","types":["Array","String"],"description":null,"text":"Array of Strings"},"form":"binary","operator":null,"left":{"text":"vehicle","types":["Object"]},"right":{"text":"turretPath","types":["Turret Path"]}}],"examples":[{"text":"```sqf\n_weapons = vehicle player weaponsTurret [0,0];\n```","code":["_weapons = vehicle player weaponsTurret [0,0];"]},{"text":"```sqf\n_weapons = _tank weaponsTurret [0];\n```","code":["_weapons = _tank weaponsTurret [0];"]},{"text":"```sqf\n_driverWeapon = _ka50pilot weaponsTurret [-1];\n```","code":["_driverWeapon = _ka50pilot weaponsTurret [-1];"]},{"text":"```sqf\n_weaponsForAnyTurrentPosition = (vehicle player) weaponsTurret ((assignedVehicleRole player) select 1);\n```","code":["_weaponsForAnyTurrentPosition = (vehicle player) weaponsTurret ((assignedVehicleRole player) select 1);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["addMagazineTurret","magazinesTurret","removeMagazinesTurret","removeMagazineTurret","weapons","assignedVehicleRole","addWeaponTurret","removeWeaponTurret","turretLocal"],"notes":[{"user":".kju","date":"2011-03-11T07:49:00Z","text":"Use assignedVehicleRole in combination to easily determine the weapons for any vehicle position. You need to check for -1 if the unit is in the driver/pilot position. See example 3 and 4."},{"user":"DenV","date":"2012-05-30T16:26:00Z","text":"Returns information (including the turrets paths) about all weapons on turrets\n\n```sqf\nfuncGetTurretsWeapons = {\n    private [\"_result\", \"_getAnyMagazines\", \"_findRecurse\", \"_class\"];\n    _result = [];\n    _getAnyMagazines = {\n        private [\"_weapon\", \"_mags\"];\n        _weapon = configFile >> \"CfgWeapons\" >> _this;\n        _mags = [];\n        {\n            _mags = _mags + getArray (\n                (if (_x == \"this\") then { _weapon } else { _weapon >> _x }) >> \"magazines\"\n            )\n        } forEach getArray (_weapon >> \"muzzles\");\n        _mags\n    };\n    _findRecurse = {\n        private [\"_root\", \"_class\", \"_path\", \"_currentPath\"];\n        _root = (_this select 0);\n        _path = +(_this select 1);\n        for \"_i\" from 0 to count _root -1 do {\n            _class = _root select _i;\n            if (isClass _class) then {\n                _currentPath = _path + [_i];\n                {\n                    _result set [count _result, [_x, _x call _getAnyMagazines, _currentPath, str _class]];\n                } forEach getArray (_class >> \"weapons\");\n                _class = _class >> \"turrets\";\n                if (isClass _class) then {\n                    [_class, _currentPath] call _findRecurse;\n                };\n            };\n        };\n    };\n    _class = (\n        configFile >> \"CfgVehicles\" >> (\n            switch (typeName _this) do {\n                case \"STRING\" : {_this};\n                case \"OBJECT\" : {typeOf _this};\n                default {nil}\n            }\n        ) >> \"turrets\"\n    );\n    [_class, []] call _findRecurse;\n    _result;\n};\n```\n\nThis call:\n\n```sqf\n\"M1A2_US_TUSK_MG_EP1\" call funcGetTurretsWeapons;\n```\n\nwill return all turrets weapons, their magazines and their paths:\n\n```\n[\n    [\"M256\", [\"20Rnd_120mmSABOT_M1A2\", \"20Rnd_120mmHE_M1A2\"], [0], \"bin\\config.bin/CfgVehicles/M1A2_US_TUSK_MG_EP1/Turrets/MainTurret\"],\n    [\"M240_veh\", [\"100Rnd_762x51_M240\", \"1200Rnd_762x51_M240\"], [0], \"bin\\config.bin/CfgVehicles/M1A2_US_TUSK_MG_EP1/Turrets/MainTurret\"],\n    [\"M2BC\", [\"100Rnd_127x99_M2\"], [0, 0], \"bin\\config.bin/CfgVehicles/M1A2_US_TUSK_MG_EP1/Turrets/MainTurret/Turrets/CommanderOptics\"],\n    [\"SmokeLauncher\", [\"SmokeLauncherMag\"], [0, 0], \"bin\\config.bin/CfgVehicles/M1A2_US_TUSK_MG_EP1/Turrets/MainTurret/Turrets/CommanderOptics\"],\n    [\"M240_veh_2\", [\"100Rnd_762x51_M240\", \"1200Rnd_762x51_M240\"], [0, 1], \"bin\\config.bin/CfgVehicles/M1A2_US_TUSK_MG_EP1/Turrets/MainTurret/Turrets/LoaderTurret\"]\n]\n```"}],"categories":["Arma 2: Operation Arrowhead: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 3: Scripting Commands","Command Group: Turrets","Introduced with Arma 2: Operation Arrowhead version 1.52","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"weightRTD","operator":null,"title":"weightRTD","type":"command","url":"https://community.bistudio.com/wiki/weightRTD","revid":378400,"updated":"2026-04-04T08:04:41Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"arma3","name":"Arma 3","version":"1.34"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.\n\nReturns weight of RTD helicopter.","syntaxes":[{"syntax":"weightRTD helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"helicopter: Object"}],"returns":{"type":"Array with [fuselage, crew, fuel, custom, weapons]","types":["Array"],"description":"weights in kilograms - fuselage: Number - weight of the fuselage - crew: Number - weight of the crew - fuel: Number - weight of the fuel - custom: Number - weight set with setCustomWeightRTD - weapons: Number - weight of the weapons","text":"Array with [fuselage, crew, fuel, custom, weapons] - weights in kilograms\n- fuselage: Number - weight of the fuselage\n- crew: Number - weight of the crew\n- fuel: Number - weight of the fuel\n- custom: Number - weight set with setCustomWeightRTD\n- weapons: Number - weight of the weapons"},"form":"unary","operator":null,"left":null,"right":{"text":"helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_taruWeight = weightRTD taru// Returns [7000,300,1990.56,0,0]\n```","code":["_taruWeight = weightRTD taru// Returns [7000,300,1990.56,0,0]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setCustomWeightRTD","isObjectRTD","load","getMass"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: RTD","Introduced with Arma 3 version 1.34","Scripting Commands"]},{"name":"west","operator":null,"title":"west","type":"command","url":"https://community.bistudio.com/wiki/west","revid":325308,"updated":"2022-07-10T23:00:31Z","groups":["Sides"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"West (BLUFOR) side.","syntaxes":[{"syntax":"west","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Side","types":["Side"],"description":null,"text":"Side"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"SQS Syntax:\n\n```sqs\n? side _unit == west : hint \"This is a western unit!\"\n```","code":["? side _unit == west : hint \"This is a western unit!\""]},{"text":"SQF Syntax:\n\n```sqf\nif (side _unit == west) then\n{\n    hint \"This is a western unit!\";\n};\n```","code":["if (side _unit == west) then\n{\n\thint \"This is a western unit!\";\n};"]}],"multiplayer":null,"problems":null,"aliases":["blufor"],"see_also":["side","east","resistance","civilian","sideEmpty","sideAmbientLife"],"notes":[],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Sides","Introduced with Operation Flashpoint version 1.00","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"WFSideText","operator":null,"title":"WFSideText","type":"command","url":"https://community.bistudio.com/wiki/WFSideText","revid":352213,"updated":"2024-02-01T23:26:05Z","groups":["Sides","Localization"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.04"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.04"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the unlocalized text value of a side or an object's/group's side.\n\n|  |  |  |  |  |  |  |  |  |  |  |\n|---|---|---|---|---|---|---|---|---|---|---|\n| Side | east / opfor | west / blufor | resistance / independent | civilian | sideUnknown | sideEnemy | sideFriendly | sideLogic | sideEmpty | sideAmbientLife |\n| Result | \"East\" | \"West\" | \"Resistance\" | \"Civilian\" | \"Unknown\" |  |  |  |  |  |\n\n> [!NOTE]\n> *WF* stands for **Warfare**, an Armed Assault/Arma 2 official game mode.","syntaxes":[{"syntax":"WFSideText value","since":null,"effect":null,"exec":null,"params":[{"name":"value","type":"Object, Group or Side","optional":false,"default":null,"description":null,"types":["Object","Group","Side"],"since":null,"text":"value: Object, Group or Side"}],"returns":{"type":"String","types":["String"],"description":"unlocalized side text value","text":"String - unlocalized side text value"},"form":"unary","operator":null,"left":null,"right":{"text":"value","types":["Object","Group","Side"]}}],"examples":[{"text":"```sqf\nWFSideText player;\n```","code":["WFSideText player;"]},{"text":"```sqf\nWFSideText group player;\n```","code":["WFSideText group player;"]},{"text":"```sqf\nWFSideText west;\n```","code":["WFSideText west;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["side","localize","isLocalized"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Localization","Command Group: Sides","Introduced with Arma 2 version 1.04","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"while","operator":null,"title":"while","type":"command","url":"https://community.bistudio.com/wiki/while","revid":369060,"updated":"2024-09-02T20:24:55Z","groups":["Program Flow"],"status":"ok","replaced_by":[],"games":[{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},{"game":"ofpe","name":"Operation Flashpoint: Elite","version":"1.00"},{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"ofp","name":"Operation Flashpoint","version":"1.85"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Repeats Code while the given condition is true. A part of while-do construct.\n\n> [!IMPORTANT]\n> - A while loop does not have any suspension, meaning that if used in scheduled environment without any suspension (sleep or uiSleep) the code will run multiple times per frame and consumes the 3 ms per frame scheduler execution limit. This should be avoided if not intended (see #Example 3).\n> - In non-scheduled environment, while do loop is limited to 10,000 iterations, after which it exits even if condition is still true.","syntaxes":[{"syntax":"while condition","since":null,"effect":null,"exec":null,"params":[{"name":"condition","type":"Code","optional":false,"default":null,"description":null,"types":["Code"],"since":null,"text":"condition: Code"}],"returns":{"type":"While Type","types":["While Type"],"description":null,"text":"While Type"},"form":"unary","operator":null,"left":null,"right":{"text":"condition","types":["Code"]}}],"examples":[{"text":"```sqf\nwhile { a < b } do { a = a + 1 };\n```","code":["while { a < b } do { a = a + 1 };"]},{"text":"A practical example: Repair all members of a group to such a level that they are able to stand up:\n\n```sqf\n{\n    if (alive _x) then\n    {\n        while { not canStand _x } do\n        {\n            _x setDamage (damage _x - 0.01);\n        };\n    };\n} forEach units group unitname;\n```","code":["{\n\tif (alive _x) then\n\t{\n\t\twhile { not canStand _x } do\n\t\t{\n\t\t\t_x setDamage (damage _x - 0.01);\n\t\t};\n\t};\n} forEach units group unitname;"]},{"text":"```sqf\n0 spawn {\n    // warning: while loop without suspension executes multiple times per frame\n    private _counter = 0;\n    private _endTime = diag_tickTime + 5;\n    private _frameNo = diag_frameNo;\n    while { diag_tickTime < _endTime } do\n    {\n        _counter = _counter + 1;\n    };\n    // in an empty mission, the _counter may go well over 2000 times per frame!\n    hint format [\"Average Execution: %1 times per frame\", _counter / (diag_frameNo - _frameNo)];\n\n    // with suspension\n    private _counter = 0;\n    private _endTime = diag_tickTime + 5;\n    private _frameNo = diag_frameNo;\n    while { diag_tickTime < _endTime } do\n    {\n        _counter = _counter + 1;\n        uiSleep 0.001; // waits at least 1 frame\n    };\n    // _counter says one per frame, as expected\n    hint format [\"Average Execution: %1 times per frame\", _counter / (diag_frameNo - _frameNo)];\n};\n```","code":["0 spawn {\n\t// warning: while loop without suspension executes multiple times per frame\n\tprivate _counter = 0;\n\tprivate _endTime = diag_tickTime + 5;\n\tprivate _frameNo = diag_frameNo;\n\twhile { diag_tickTime < _endTime } do\n\t{\n\t\t_counter = _counter + 1;\n\t};\n\t// in an empty mission, the _counter may go well over 2000 times per frame!\n\thint format [\"Average Execution: %1 times per frame\", _counter / (diag_frameNo - _frameNo)];\n\n\t// with suspension\n\tprivate _counter = 0;\n\tprivate _endTime = diag_tickTime + 5;\n\tprivate _frameNo = diag_frameNo;\n\twhile { diag_tickTime < _endTime } do\n\t{\n\t\t_counter = _counter + 1;\n\t\tuiSleep 0.001; // waits at least 1 frame\n\t};\n\t// _counter says one per frame, as expected\n\thint format [\"Average Execution: %1 times per frame\", _counter / (diag_frameNo - _frameNo)];\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["Control Structures","waitUntil","for","do"],"notes":[{"user":"Kronzky","date":"2008-05-14T08:40:00Z","text":"The boolean code that is used to evaluate the while condition can be preceded by code that executes a regular command.\n\n```sqf\nwhile { _a =_a + 1; _a < 10 } do { /* ... */ };\n```"}],"categories":["ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Program Flow","Introduced with Operation Flashpoint version 1.85","Operation Flashpoint: Elite: Scripting Commands","Operation Flashpoint: New Scripting Commands","Operation Flashpoint: Scripting Commands","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"wind","operator":null,"title":"wind","type":"command","url":"https://community.bistudio.com/wiki/wind","revid":378404,"updated":"2026-04-04T08:14:45Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current wind vector (in m/s).","syntaxes":[{"syntax":"wind","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Vector3D","types":["Vector3D"],"description":"[x, y, 0]. with wind being only horizontal","text":"Vector3D - [x, y, 0]. with wind being only horizontal"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_windArray = wind;\n```","code":["_windArray = wind;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWind","windDir"],"notes":[{"user":"Ceeeb","date":"2008-08-10T04:38:00Z","text":"In **OFP 1.96**, wind speed and direction are directly related to overcast."}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"windDir","operator":null,"title":"windDir","type":"command","url":"https://community.bistudio.com/wiki/windDir","revid":321137,"updated":"2022-05-13T14:31:42Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current wind azimuth.","syntaxes":[{"syntax":"windDir","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":"azimuth","text":"Number - azimuth"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nif (windDir < 45 || windDir > 315) then {\n    hint \"I feel a southern wind\"; // wind going from South to North\n};\n```","code":["if (windDir < 45 || windDir > 315) then {\n\thint \"I feel a southern wind\"; // wind going from South to North\n};"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["wind","setWindDir","setWindStr","setWindForce"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"windRTD","operator":null,"title":"windRTD","type":"command","url":"https://community.bistudio.com/wiki/windRTD","revid":377885,"updated":"2026-01-04T16:30:27Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns wind strength and direction.\n\n> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.","syntaxes":[{"syntax":"windRTD","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Array with [windStrength, windDirection]","types":["Array"],"description":"windStrength: Number - windDirection: Number","text":"Array with [windStrength, windDirection]\n- windStrength: Number\n- windDirection: Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n_wind = windRTD;\n```","code":["_wind = windRTD;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["wind","setWind"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"windStr","operator":null,"title":"windStr","type":"command","url":"https://community.bistudio.com/wiki/windStr","revid":319970,"updated":"2022-05-13T09:25:48Z","groups":["Environment"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma3","name":"Arma 3","version":"0.50"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the current wind strength.","syntaxes":[{"syntax":"windStr","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\n10 setWindStr (0.5 * windStr);\n```","code":["10 setWindStr (0.5 * windStr);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["setWindStr","gusts","setGusts","setWind","setWindDir","setWindForce","wind","windDir"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Environment","Introduced with Arma 3 version 0.50","Scripting Commands"]},{"name":"wingsForcesRTD","operator":null,"title":"wingsForcesRTD","type":"command","url":"https://community.bistudio.com/wiki/wingsForcesRTD","revid":341020,"updated":"2023-05-13T22:06:26Z","groups":["RTD"],"status":"ok","replaced_by":[],"games":[{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"1.34"}],"since":{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},"arma3_since":"1.34","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"> [!NOTE]\n> **afm:** For this command to have any effect, the Advanced Flight Model (AFM) has to be enabled. AFM status can be checked with difficultyEnabledRTD.\n\n Returns force produced by wings.","syntaxes":[{"syntax":"wingsForcesRTD RTD_helicopter","since":null,"effect":null,"exec":null,"params":[{"name":"RTD_helicopter","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"RTD_helicopter: Object"}],"returns":{"type":"Array","types":["Array"],"description":null,"text":"Array"},"form":"unary","operator":null,"left":null,"right":{"text":"RTD_helicopter","types":["Object"]}}],"examples":[{"text":"```sqf\n_wingForce = wingsForcesRTD _rtdHelo;\n```","code":["_wingForce = wingsForcesRTD _rtdHelo;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["isObjectRTD","enginesRpmRTD","enginesTorqueRTD","airDensityRTD","wind","windDir","windStr"],"notes":[],"categories":["Arma 3: Scripting Commands","Command Group: RTD","Introduced with Take On Helicopters version 1.00","Scripting Commands","Take On Helicopters: New Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"with","operator":null,"title":"with","type":"command","url":"https://community.bistudio.com/wiki/with","revid":369023,"updated":"2024-08-26T13:58:14Z","groups":["Program Flow","Namespaces"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Creates a With Type that is used inside a do construct in order to execute code inside a given namespace.\n\n> [!IMPORTANT]\n> To avoid the below-mentioned issue error (whether in scheduled or unscheduled environment) use setVariable/getVariable with the desired Namespace.","syntaxes":[{"syntax":"with namespace","since":null,"effect":null,"exec":null,"params":[{"name":"namespace","type":"Namespace","optional":false,"default":null,"description":null,"types":["Namespace"],"since":null,"text":"namespace: Namespace"}],"returns":{"type":"With Type","types":["With Type"],"description":null,"text":"With Type"},"form":"unary","operator":null,"left":null,"right":{"text":"namespace","types":["Namespace"]}}],"examples":[{"text":"```sqf\n_myWithType = with uiNamespace;\n```","code":["_myWithType = with uiNamespace;"]},{"text":"```sqf\nwith missionNamespace do { global = global + 1 };\n```","code":["with missionNamespace do { global = global + 1 };"]}],"multiplayer":null,"problems":"When used in a do-construct in scripts with allowed suspension, a namespace switching might unexpectedly occur inside some scopes (for, if, try, call) started in a scheduled environment after small suspension if with was not the main scope; however, the issue does not arise if with is used in the parent scope:\n\n| namespace switch risk | namespace switch safe |\n|---|---|\n| ```sqf<br>0 spawn<br>{<br>    with uiNamespace do<br>    {<br>        for \"_i\" from 1 to 1 do <br>        {<br>            systemChat str [<br>                currentNamespace isEqualTo uiNamespace, <br>                currentNamespace isEqualTo missionNamespace<br>            ];<br>            // result [true, false]<br>            sleep 0.05; // <-- small suspension<br>            systemChat str [<br>                currentNamespace isEqualTo uiNamespace, <br>                currentNamespace isEqualTo missionNamespace<br>            ];<br>            // result [false, true] <-- switching<br>        };<br>    };<br>};<br>``` | ```sqf<br>with uiNamespace do<br>{<br>    0 spawn<br>    {<br>        for \"_i\" from 1 to 1 do <br>        {<br>            systemChat str [<br>                currentNamespace isEqualTo uiNamespace, <br>                currentNamespace isEqualTo missionNamespace<br>            ];<br>            // result [true, false]<br>            sleep 0.05; // <-- small suspension<br>            systemChat str [<br>                currentNamespace isEqualTo uiNamespace, <br>                currentNamespace isEqualTo missionNamespace<br>            ];<br>            // result [true, false] <-- NO switching<br>        };<br>    };<br>};<br>``` |","aliases":[],"see_also":["missionNamespace","uiNamespace","parsingNamespace","currentNamespace"],"notes":[{"user":"Hypoxic125","date":"2023-02-23T07:05:05Z","text":"**Using with:**\n\n```sqf\nwith profileNamespace do {\n    myVariable = \"Hello!\";\n};\n```\n\n**is the same as:**\n\n```sqf\nprofileNamespace setVariable [\"myVariable\", \"Hello!\"];\n```\n\nThis allows you to quickly modify/use variables within a namespace without using **get/setvariable** every time."}],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Namespaces","Command Group: Program Flow","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"worldName","operator":null,"title":"worldName","type":"command","url":"https://community.bistudio.com/wiki/worldName","revid":364784,"updated":"2024-06-12T09:38:47Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Return the name of the currently loaded world.","syntaxes":[{"syntax":"worldName","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"String","types":["String"],"description":null,"text":"String"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _name = worldName;\n```","code":["private _name = worldName;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["missionName","briefingName","serverName","worldSize"],"notes":[{"user":"Sa-Matra","date":"2024-06-12T09:38:47Z","text":"World name casing is unreliable and checks must be case insensitive!"}],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"worldSize","operator":null,"title":"worldSize","type":"command","url":"https://community.bistudio.com/wiki/worldSize","revid":373463,"updated":"2025-05-09T16:51:14Z","groups":["Mission Information"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.48"}],"since":{"game":"arma3","name":"Arma 3","version":"1.48"},"arma3_since":"1.48","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Returns the engine calculated size (terrain side length) of the current world in meters. In Arma, terrains are always square. (BIS_fnc_mapSize may return the same value, but is just a simple look up in config).","syntaxes":[{"syntax":"worldSize","since":null,"effect":null,"exec":null,"params":[],"returns":{"type":"Number","types":["Number"],"description":null,"text":"Number"},"form":"nullary","operator":null,"left":null,"right":null}],"examples":[{"text":"```sqf\nprivate _size = worldSize; // VR and Stratis: 8192; Altis: 30720\n```","code":["private _size = worldSize; // VR and Stratis: 8192; Altis: 30720"]},{"text":"```sqf\n// A round marker that should cover the whole map, placed in the center of the map, should have the following radius (a, b)\nprivate _radius = sqrt 2 / 2 * worldSize;\n```","code":["// A round marker that should cover the whole map, placed in the center of the map, should have the following radius (a, b)\nprivate _radius = sqrt 2 / 2 * worldSize;"]},{"text":"```sqf\nprivate _axis = worldSize / 2;\nprivate _center = [_axis, _axis , 0];\nprivate _radius = sqrt 2 * _axis;\n```","code":["private _axis = worldSize / 2;\nprivate _center = [_axis, _axis , 0];\nprivate _radius = sqrt 2 * _axis;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_mapSize","getTerrainInfo"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Mission Information","Introduced with Arma 3 version 1.48","Scripting Commands"]},{"name":"worldToModel","operator":null,"title":"worldToModel","type":"command","url":"https://community.bistudio.com/wiki/worldToModel","revid":377406,"updated":"2026-01-02T06:45:05Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma1","name":"Armed Assault","version":"1.00"},{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma1","name":"Armed Assault","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position from world space to object model space.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will be divided by the object scale.","syntaxes":[{"syntax":"model worldToModel position","since":null,"effect":null,"exec":null,"params":[{"name":"model","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"model: Object"},{"name":"position","type":"PositionAGL or Position2D","optional":false,"default":null,"description":"world position","types":["PositionAGL","Position2D"],"since":null,"text":"position: PositionAGL or Position2D - world position"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":"position relative to model","text":"PositionRelative - position relative to model"},"form":"binary","operator":null,"left":{"text":"model","types":["Object"]},"right":{"text":"position","types":["PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_relPos = myObject worldToModel [0,0,0];\n```","code":["_relPos = myObject worldToModel [0,0,0];"]},{"text":"```sqf\n_relPos = player worldToModel ASLToAGL getPosASL car;\n```","code":["_relPos = player worldToModel ASLToAGL getPosASL car;"]},{"text":"```sqf\n_relPos = car worldToModel [12000,5000];\n```","code":["_relPos = car worldToModel [12000,5000];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["worldToModelVisual","vectorWorldToModel","modelToWorld"],"notes":[],"categories":["ArmA: Armed Assault: New Scripting Commands","ArmA: Armed Assault: Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Armed Assault version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]},{"name":"worldToModelVisual","operator":null,"title":"worldToModelVisual","type":"command","url":"https://community.bistudio.com/wiki/worldToModelVisual","revid":377846,"updated":"2026-01-03T04:37:17Z","groups":["Positions","Render Time Scope"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.32"}],"since":{"game":"arma3","name":"Arma 3","version":"1.32"},"arma3_since":"1.32","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position from world space to object model space in render time scope.\n\n> [!IMPORTANT]\n> For scaled objects, the relative position will be divided by the object scale.","syntaxes":[{"syntax":"object worldToModelVisual worldPosition","since":null,"effect":null,"exec":null,"params":[{"name":"object","type":"Object","optional":false,"default":null,"description":null,"types":["Object"],"since":null,"text":"object: Object"},{"name":"worldPosition","type":"PositionAGL or Position2D","optional":false,"default":null,"description":null,"types":["PositionAGL","Position2D"],"since":null,"text":"worldPosition: PositionAGL or Position2D"}],"returns":{"type":"PositionRelative","types":["PositionRelative"],"description":null,"text":"PositionRelative"},"form":"binary","operator":null,"left":{"text":"object","types":["Object"]},"right":{"text":"worldPosition","types":["PositionAGL","Position2D"]}}],"examples":[{"text":"```sqf\n_relPos = myObject worldToModelVisual [0,0,0];\n```","code":["_relPos = myObject worldToModelVisual [0,0,0];"]},{"text":"```sqf\n_relPos = player worldToModelVisual position car;\n```","code":["_relPos = player worldToModelVisual position car;"]},{"text":"```sqf\n_relPos = car worldToModelVisual [12000, 5000];\n```","code":["_relPos = car worldToModelVisual [12000, 5000];"]},{"text":"```sqf\n_relPos = unit worldToModelVisual position tank;\n```","code":["_relPos = unit worldToModelVisual position tank;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["worldToModel","vectorWorldToModelVisual","modelToWorldVisual","modelToWorld"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Command Group: Render Time Scope","Introduced with Arma 3 version 1.32","Scripting Commands"]},{"name":"worldToScreen","operator":null,"title":"worldToScreen","type":"command","url":"https://community.bistudio.com/wiki/worldToScreen","revid":377903,"updated":"2026-01-05T18:00:13Z","groups":["Positions"],"status":"ok","replaced_by":[],"games":[{"game":"arma2","name":"Arma 2","version":"1.00"},{"game":"arma2oa","name":"Arma 2: Operation Arrowhead","version":"1.50"},{"game":"tkoh","name":"Take On Helicopters","version":"1.00"},{"game":"arma3","name":"Arma 3","version":"0.50"}],"since":{"game":"arma2","name":"Arma 2","version":"1.00"},"arma3_since":"0.50","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Converts position in world space into screen (UI) space. If a specified position is not within the current screen view, an empty array is returned.\n\n> [!NOTE]\n> SafeZones should be considered:\n> - the result can be out of the [0,0]..[1,1] range\n> - the result can be a filled array even if the position is not displayed on screen if it would appear on a triplescreen setup","syntaxes":[{"syntax":"worldToScreen position","since":null,"effect":null,"exec":null,"params":[{"name":"position","type":"Position2D, PositionAGL","optional":false,"default":null,"description":null,"types":["Position2D","PositionAGL"],"since":null,"text":"position: Position2D, PositionAGL"}],"returns":{"type":"Array with [x, y]","types":["Array"],"description":"screen position in SafeZone. Returns an empty array `[]` if not on-screen. - x: Number - y: Number","text":"Array with [x, y] - screen position in SafeZone. Returns an empty array `[]` if not on-screen.\n- x: Number\n- y: Number"},"form":"unary","operator":null,"left":null,"right":{"text":"position","types":["Position2D","PositionAGL"]}},{"syntax":"camera worldToScreen position","since":"arma3 2.18","effect":null,"exec":null,"params":[{"name":"camera","type":"Object","optional":false,"default":null,"description":"camera object","types":["Object"],"since":null,"text":"camera: Object - camera object"},{"name":"position","type":"Position2D, PositionAGL","optional":false,"default":null,"description":null,"types":["Position2D","PositionAGL"],"since":null,"text":"position: Position2D, PositionAGL"}],"returns":{"type":"Array with [x, y]","types":["Array"],"description":"screen position in SafeZone. Returns an empty array `[]` if not on-screen. - x: Number - y: Number","text":"Array with [x, y] - screen position in SafeZone. Returns an empty array `[]` if not on-screen.\n- x: Number\n- y: Number"},"form":"binary","operator":null,"left":{"text":"camera","types":["Object"]},"right":{"text":"position","types":["Position2D","PositionAGL"]}}],"examples":[{"text":"```sqf\n_screenPos = worldToScreen ASLToAGL getPosASL soldier1;\n```","code":["_screenPos = worldToScreen ASLToAGL getPosASL soldier1;"]},{"text":"```sqf\n_screenPos = worldToScreen (player modelToWorld [0,10,0]);\n```","code":["_screenPos = worldToScreen (player modelToWorld [0,10,0]);"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["screenToWorld","SafeZone"],"notes":[],"categories":["Arma 2: New Scripting Commands","Arma 2: Operation Arrowhead: Scripting Commands","Arma 2: Scripting Commands","Arma 3: Scripting Commands","Command Group: Positions","Introduced with Arma 2 version 1.00","Scripting Commands","Take On Helicopters: Scripting Commands"]}]}