First of all...sorry if this is in the wrong forum.
I have just finished a game in Macromedia Director using Lingo and I really want to add a high score to the end.
How do I do this? Do I have to use FileI/O??
Any help or links to tutorials would be much appreciated as I cannot find how to do this anywhere...and i have spent ages looking!!
However, if Lingo supports file I/O, i e reading and writing files, then you need a few functions:
1) a function which takes a list of five (name,score) pairs, and writes them to a file of a given name (say, "hiscores.dat") 2) a function which reads a file of a given name (say, "hiscores.dat") and returns a list of five (name,score) pairs. 3) a function which, when given a (name,score) pair, reads the existing file if it exists, adds the sixth name,score pair, sorts the list, drops the last item, and then writes the file again.
As for how file I/O actually works (how to read/write "hiscores.dat") I'd suggest looking in the Lingo help files. I know that file I/O is probably curtailed, as Shockwave is possible to be executed from the web...