The dll also has some extra functions, for examle opening or saving entire files at once. These functions are a lot faster than the standard GM functions, because the only way to do this in GM is reading one line at a time and concatenating all these lines. For example, opening a 1MB text file in GM could take several minutes, but with this function it only takes 0.2 seconds.
The dll can open up to 16 files at the same time (+ 1 with the functions that read the entire file at once).
Download: File Dll - ZIP (47.9kb)
The zip file contains the dll, the scripts, a gex file, an example (gmk), and a help file.
New: If you combine this dll with Blijbol's INI data structure extension, you can use this to read and edit INI files, even with files outside the program directory, without getting errors! Here you can find a list of instructions. Or if you don't understand Dutch:
- Import the INI data structure scripts OR extension into your game.
- Import the File Dll scripts OR extension into your game.
- Add the two alternative scripts for loading and saving INI data structures to your game.
- Use the alternative scripts for loading/saving instead of the normal ones.
Edited by Maarten Baert, 27 August 2011 - 08:44 PM.