High Score for a game?

Hey guys, i finished the game i was making (see at www.se-miserious.com ) but I want to add a top score system to it…i read a tutorial on flashkit which uses a simple PHP script…that’s really easy, but I’m confused as to how to submit the details to write to it…here’s the flashkit tutorial:


Please post back with help :rambo:

PHP script? … i thought you had to use a database to keep track of anything … i.e. scores

Nah, the php script puts the info into a txt file…do you know how to make a list?

i don’t know PHP … but that sounds useful … i’m gonna have to look into that

what kind of list?

A high score list

yeah i have it here in book … but it’s quite lengthy

Do you have AIM or MSN?

AIM = vader4379
MSN = [email protected]

but it’s a few pages … and i’m reading through it to see what’s important so maybe i can type that here

Do u want a PHP script that saves the information into the Txt file, i made one some time ago, just send me a reply and i’ll send it to you back! =)

i’d like to have one =)

Here u go, its really very simple, but does the job! :slight_smile:

$file = fopen("scores.txt", "a");
fputs($file, $username." - ".$scores."


Hehe, i’d love one thanks, wouldn’t mind talking to you either… AIM: HecticDesigns
MSN: [email protected]
email: [email protected]

nah, i really like discussing it in the forums :slight_smile:

Well, how do I implement that into my game? i’d really like to send u the fla…

hmm, ok ill post a flash actionscript right now, just hang on a sec!

Ok lemme explain :smiley:

I have a dynamic txt box where the score goes and when the time runs out it goes “Time over, you’ve got…” then underneath it has the score box…so i wanna have another txt box where u enter ur name and press submit and it send ur name and score off…

hmmm, this is quite not as i thought, You then will need an output something like:


well, this will output in textfile:

username - score!! so, u cant easily retrieve it back into flash

Ill try doing a PHP code for this later, probably today!

cya until time!


The thing is, i don’t want the scores in flash…i wanna put em on my webpage…

Why? the thing is the PHP Code, though its easier when its done with Flash!

btw, do u want the code to only record the Top 10!

Top 10 would be easier!

Yeh top 10 is fine, thanks a lot…thing is like candystand.com i wanna have it so they play the game, click submit and it (for example) saves it to a txt file which i can include on my website…