file_text_open_write(fname)

fname = the name of the file you want to open including the directory.

 

This will open a file so you can write into it from Game Maker.  It returns the id of the file you opened so whenever you try to write to it, you use this id. You have to include the directory of the file you want to open but you can use the variables working_directory for the folder where the game is being run from or temp_directory for the temp folder(if you included files and extracted them to there).if the file doesn't exist, Game Maker will create it. This will erase everything that is in the file before.

 

Example

file1 = file_text_open_write(working_directory+'\test.txt');

 

Ari - Revision #'1