Question: Can the game create an external text file?

Started by FERdeBOER, Wed 12/11/2008 20:11:36

Previous topic - Next topic

FERdeBOER

First, thank You all for this game and forum.

I'm not English and I don't know anything about programming, that's probably because I didn't find what I was looking for...maybe I don't know the concrete name of I what I want... or maybe is really a rare question...  ;)
I also doubt if I have to ask this here or in the other tech forum, but as I'm a newbie...

The question is if I can make a game that creates an external .txt file (or similar).

I will try to explain my "problem": I use to play a simulator that has a great mission editor but a very poor campaign. The mission files can be read by notepad and what I'm looking for is to simulate with AGS a more dynamic and bigger campaign (I already know how to do that) and then, when the "important things" happen in AGS, create a .txt file with that info and use it to make the mission in the simulator.
I would tell to AGS what it has to write in that file depending on the situation (i.e. this part of the map, this planes, this ships...).

Thank You very much for your attention.

OneDollar

Quote from: FERdeBOER on Wed 12/11/2008 20:11:36
The question is if I can make a game that creates an external .txt file (or similar).

I'm not fully following what you're trying to do, but yes AGS can read and write text files. Look up 'File functions and properties' in the manual (or click here for the online version). You can either read and write strings, integers etc previously written by AGS or (and I guess this is what you'd want) you can read and write raw data, i.e. stuff written by other programs or in notepad.

The main limitation is that you can only read and write to and from the game's folder and the save directory, so you'd have to move any files manually to either of those locations

FERdeBOER

Thanks for the answer.

Seems what I was looking for, but seems also too complicated to do for me...  ::)

But thank you very much!

SMF spam blocked by CleanTalk