{"name":"BIN_fnc_isExtensionError","title":"BIN fnc isExtensionError","type":"function","url":"https://community.bistudio.com/wiki/BIN_fnc_isExtensionError","revid":379541,"updated":"2026-10-31T13:36:56Z","groups":["Diagnostic"],"status":"ok","games":{"arma3":"1.94"},"since":"arma3 1.94","arma3_since":"1.94","description":"Checks the output of the array syntax of callExtension for an error. If an error is found, it is reported with BIS_fnc_error and the function returns true.\n\n- If the error code (third element) is above 0, the engine reported an error; the reported message depends on the code:\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  - any other code - \"UNKNOWN_ERROR\"\n- Otherwise, if the return code (second element) is negative, the extension itself reported an error and its output string is used as the error message (\"Generic Error\" if the string is empty).\n\nIf the input is not an array of format [String, Number, Number], the function returns false without reporting anything.\n\nContact functions use it after every call to their extensions, e.g. BIN_fnc_addObjectsToArea and BIN_fnc_getObjectBoundingBarrel (extension \"biext_collisions\") or BIN_fnc_preInitEM and BIN_fnc_deleteAntenna (extension \"biext_txscan\"). It works with the output of any extension and can be used in scripts as well.\n\n> [!NOTE]\n> This content is exclusive to the Arma 3 Contact Expansion.","syntaxes":[{"syntax":"extensionOutput call BIN_fnc_isExtensionError","params":[{"name":"extensionOutput","type":"Array","description":"output of `extensionName callExtension [function, arguments]`, format [result, returnCode, errorCode]:\n\n- result: String - output of the extension; on error it should contain the error description\n- returnCode: Number - return code set by the extension; a negative value means an error\n- errorCode: Number - error code set by the engine; a value above 0 means an error","type_expr":"Array"}],"returns":{"type":"Boolean","type_expr":"Boolean","description":"true if an error was detected (and reported), otherwise false"}}],"examples":[{"code":["private _result = \"biext_collisions\" callExtension [\"addObjectsToArea\", _args];\nif (_result call BIN_fnc_isExtensionError) exitWith { [0] }; // the error has already been reported\nparseSimpleArray (_result select 0);"]}],"see_also":["callExtension","BIS_fnc_error"]}