From Bohemia Interactive Community
Click on the images for descriptions
- Operation Flashpoint: Resistance
- Return content of given filename as string. If you plan to compile said string, be aware that the file shouldn't contain comments or compile will throw an error. If there are comments, use preprocessFile/preprocessFileLineNumbers instead.
- Example 1:
_contents = loadFile "wantedString.txt";
- Example 2:
_contents = compile loadFile "myFunction.sqf"; // will compile string into code
- Posted on 25 January 2016 - 12:13
- Notice that you will have to activate file patching via -filePatching. Otherwise, execVM and loadFile will *not* load any files outside your mission folder (like the global scripts).