{"name":"BIS_fnc_recompile","operator":null,"title":"BIS fnc recompile","type":"function","url":"https://community.bistudio.com/wiki/BIS_fnc_recompile","revid":327400,"updated":"2022-07-12T22:11:58Z","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":"Can be used to recompile functions.\n\n> [!NOTE]\n> As a security measure, functions are by default protected against rewriting during the mission. This restriction does **not** apply to:\n> - missions previewed from the editor\n> - missions with the following attribute in Description.ext: \n>\n> ```cpp\n> allowFunctionsRecompile = 1;\n> ```","syntaxes":[{"syntax":"[mode] call BIS_fnc_recompile","since":null,"effect":null,"exec":null,"params":[{"name":"mode (Optional, default 0)","type":null,"optional":false,"default":null,"description":"- String - name of the function to be recompiled\n- Number - can be:\n  - 0 - Autodetect what compile type should be used\n  - 1 - Forced recompile of all the things\n  - 2 - Create only uiNamespace variables (used in UI)\n  - 3 - Create missionNamespace variables and initialize mission\n  - 4 - Create only missionNamespace variables\n  - 5 - Recompile all functions, and initialize mission (used for editor preview with function recompile)","types":[],"since":null,"text":"mode (Optional, default 0):\n- String - name of the function to be recompiled\n- Number - can be:\n  - 0 - Autodetect what compile type should be used\n  - 1 - Forced recompile of all the things\n  - 2 - Create only uiNamespace variables (used in UI)\n  - 3 - Create missionNamespace variables and initialize mission\n  - 4 - Create only missionNamespace variables\n  - 5 - Recompile all functions, and initialize mission (used for editor preview with function recompile)"}],"returns":{"type":"Boolean","types":["Boolean"],"description":null,"text":"Boolean"}}],"examples":[{"text":"```sqf\n[] call BIS_fnc_recompile;\n```","code":["[] call BIS_fnc_recompile;"]},{"text":"```sqf\n[3] call BIS_fnc_recompile;\n```","code":["[3] call BIS_fnc_recompile;"]},{"text":"```sqf\n[\"BIS_fnc_spawnVehicle\"] call BIS_fnc_recompile;\n```","code":["[\"BIS_fnc_spawnVehicle\"] call BIS_fnc_recompile;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["compile","compileFinal"],"notes":[],"categories":["Arma 2: Functions","Arma 2: New Functions","Arma 2: Operation Arrowhead: Functions","Arma 3: Functions","Function Group: Diagnostic","Functions","Introduced with Arma 2 version 1.00","Take On Helicopters: Functions"],"docblock":null,"filled_from_docblock":[]}