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 continue until either the specified amount of bytes was affected or the end of this Buffer was reached. This operation can be performed asynchronously to prevent the application from stopping while it is in process. If done so, the file path will have "Default" added at the beginning of it and an ID will be returned for use as the in SaveLoad asynchronous event. Otherwise, {undefined} will be returned.