Buffer.toFile() - Mtax-Development/GML-OOP GitHub Wiki
Name |
Type |
Optional |
path |
{string:path} |
No |
offset? |
{int} |
Yes |
size? |
{int} |
Yes |
async? |
{bool} |
Yes |
{int|undefined}
Save the data of this Buffer
to the specified file. A byte offset can be specified for where the operation will start and then continue until either the specified size in bytes was affected or the end of this Buffer
is reached. This operation can be done asynchronously, which will prevent the game from stopping while in process. If performed asynchronously, the file path will have "Default" added at the beginning of it automatically, also the ID
will be returned that will equal the value of the ID
key in SaveLoad asynchronous event. Otherwise {undefined}
will be returned.