Scoring
Author |
Message |
bigr
|
Posted: Mon Apr 19, 2004 9:50 am Post subject: Scoring |
|
|
I have a worm game and Im wondering how you can have a scoring system which saves high scores to a file. Allowing the high scores to be shown every time you start the game |
|
|
|
|
|
Sponsor Sponsor
|
|
|
EDEN-E
|
Posted: Mon Apr 19, 2004 11:12 am Post subject: Re: Scoring |
|
|
code: | var f : int
var top : int
% to get topscore from data.txt file
open : f, "data.txt", get
get : f, top
close : f
% to write
open : f, "data.txt", put
put : f, top
end for |
of course there are much more function for file io...
if you need more about file io, i suggest you to look up Turing Reference (F10) |
|
|
|
|
|
Tony
|
Posted: Mon Apr 19, 2004 12:34 pm Post subject: (No subject) |
|
|
turing reference is useless for most parts... they give bad examples that sometimes don't even work
I know we've got a good tutorial on file i/o... it was like one of the first ones posted |
Tony's programming blog. DWITE - a programming contest. |
|
|
|
|
|
|