01.07.2011, 11:06
Hello there,
I was wondering how to use File Functions to save inputtext into a text file. What I am trying to do is OnDialogResponse, when the player puts his text into an Input type dialog, the information will get submitted into a text file, creating a new line for each new input. I did some research and I found it's possible, but I'm not sure how to code it, I looked upon file functions and tried something like this:
There's no errors, so I figured out it can't be a brackets issue or anything, it must be that useless format I made. Please could I have some sort of example or correction on how to do that?
Regards,
HighFlyer
I was wondering how to use File Functions to save inputtext into a text file. What I am trying to do is OnDialogResponse, when the player puts his text into an Input type dialog, the information will get submitted into a text file, creating a new line for each new input. I did some research and I found it's possible, but I'm not sure how to code it, I looked upon file functions and tried something like this:
Код:
if(dialogid == REQUEST && response) { new File:pos=fopen("/RadioRequests.txt", io_write); fwrite(pos, inputtext); fclose(pos); }
Regards,
HighFlyer