{"name":"BIS_fnc_bitflagsToArray","operator":null,"title":"BIS fnc bitflagsToArray","type":"function","url":"https://community.bistudio.com/wiki/BIS_fnc_bitflagsToArray","revid":328601,"updated":"2022-07-13T17:02:31Z","groups":["Bitwise"],"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 array with all bit flags which are set in the given flagset\n\n**Limitations**:\n\nDue to various limitations of the Real Virtuality engine this function is\nintended to work with unsigned 24 bit integers only. This means that the\nsupported range is 2^0...2^24 (1...16777216)","syntaxes":[{"syntax":"flagset call BIS_fnc_bitflagsToArray","since":null,"effect":null,"exec":null,"params":[{"name":"flagset","type":"Number","optional":false,"default":null,"description":"decimal or hexadecimal unsigned 24 bit integer","types":["Number"],"since":null,"text":"flagset: Number - decimal or hexadecimal unsigned 24 bit integer"}],"returns":{"type":"Array","types":["Array"],"description":"array of set bit flags","text":"Array - array of set bit flags"}}],"examples":[{"text":"```sqf\n15 call BIS_fnc_bitflagsToArray; // [1,2,4,8]\n2342 call BIS_fnc_bitflagsToArray; // [2,4,32,256,2048]\n[2 + 4 + 8] call BIS_fnc_bitflagsToArray; // [2,4,8]\n[2 + 2 + 2 + 4 + 8 + 8 + 8] call BIS_fnc_bitflagsToArray; // [2,32]\n```","code":["15 call BIS_fnc_bitflagsToArray; // [1,2,4,8]\n2342 call BIS_fnc_bitflagsToArray; // [2,4,32,256,2048]\n[2 + 4 + 8] call BIS_fnc_bitflagsToArray; // [2,4,8]\n[2 + 2 + 2 + 4 + 8 + 8 + 8] call BIS_fnc_bitflagsToArray; // [2,32]"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["BIS_fnc_bitflagsFlip","BIS_fnc_bitflagsSet","BIS_fnc_bitflagsCheck","BIS_fnc_bitflagsUnset"],"notes":[],"categories":["Arma 3: Functions","Arma 3: New Functions","Function Group: Bitwise","Functions","Introduced with Arma 3 version 1.66"],"docblock":null,"filled_from_docblock":[]}