Functions
file.inc
| Function | Type | Description |
|---|---|---|
| FileReadInt16 | native | Reads a single int16 (short) from a file. The value is sign-extended to an int32. |
| FileReadInt32 | native | Reads a single int32 (int/cell) from a file. |
| FileReadInt8 | native | Reads a single int8 (byte) from a file. The returned value is sign- extended to an int32. |
| FileReadUint16 | native | Reads a single unt16 (unsigned short) from a file. The value is zero- extended to an int32. |
| FileReadUint8 | native | Reads a single uint8 (unsigned byte) from a file. The returned value is zero-extended to an int32. |
| FileWriteInt16 | native | Writes a single int16 (short) to a file. |
| FileWriteInt32 | native | Writes a single int32 (int/cell) to a file. |
| FileWriteInt8 | native | Writes a single int8 (byte) to a file. |
| GetFileTime | native | Returns a file timestamp as a unix timestamp. |
| LoadFileForMe | native | Loads a file using the LoadFileForMe engine function. The data is truncated if there is not enough space. No null-terminator is applied; the data is the raw contents of the file. |
| SetFilePermissions | native | Changes a file or directories permissions. |
| close_dir | native | Closes the directory. |
| delete_file | native | Deletes a file. |
| dir_exists | native | Checks if a directory exists. |
| fclose | native | Closes a file handle. |
| feof | native | Tests if the end of file has been reached. |
| fflush | native | Flushes a buffered output stream. |
| fgetc | native | Gets character from file. |
| fgets | native | Reads a line from a text file. |
| file_exists | native | Checks if a file exists. |
| file_size | native | Get the file size in bytes. |
| filesize | native | Gets the formatted file size in bytes. |
| fopen | native | Opens or creates a file, returning a file handle on success. File handles should be closed with fclose(). |
| fprintf | native | Writes a line of formatted text to a text file. |
| fputc | native | Writes character to file |
| fputs | native | Writes a line of text to a text file. |
| fread | native | Reads a single binary data from a file. |
| fread_blocks | native | Reads binary data from a file. |
| fread_raw | native | Reads raw binary data from a file. |
| fseek | native | Sets the file position indicator. |
| ftell | native | Gets current position in the file. |
| fungetc | native | Ungets character from file. |
| fwrite | native | Writes a single binary data to a file. |
| fwrite_blocks | native | Writes binary data to a file. |
| fwrite_raw | native | Writes raw binary data to a file. |
| mkdir | native | Creates a directory. |
| next_file | native | Reads the next directory entry as a local filename. |
| open_dir | native | Opens a directory/folder for contents enumeration. |
| read_dir | native | Reads content from directory |
| read_file | native | Reads line from file. |
| rename_file | native | Renames a file. |
| rmdir | native | Removes a directory. |
| unlink | native | Deletes a file (delete_file macro) |
| write_file | native | Writes text to file. |