This function will return a byte of data from current position within the file with the given file ID. You supply the file ID value, as returned by the function file_bin_open().
NOTE: These functions do not work when the target module is HTML5.
file_bin_read_byte(binfile);
Argument | Type | Description |
---|---|---|
binfile | Binary File ID | The ID of the file to get the data from. |
file = file_bin_open("myfile.bin", 2);
data = file_bin_read_byte(file);
file_bin_close(file);
This would open a file from the same directory as the game, and get a byte of data from it before closing it again.