Another Game questions, might be useful for gamers.
I've been reading the forum threads and came across some saving questions for games, no comes my question.
Forexample, if i was making a platform game with levels once u reach a certain point, i want to make the level change once u get to the other side of the stage, (that is easy enough to do), then, once u reach the next level the text "level2" is displayed in a dynamic text box somewhere on the screen, now, the question.
Is there a way so that when u get the level 2 flash will automatically save a text file to the same directory the swf is located and the .txt file has in it;
myLevel=(level reached eg."level2")
myPoints=(points gained eg."34000")
myUser=(whatever user logged in?)
--- those 3 variables will have allocated dynamic text boxes,
now to my 2nd question, (yes or no) can u make a load button at the beginning of your .swf movie, when clicked loads the information from the external .txt file and takes you to that level with the level score.. eg;
.swf opens with a input text box,
if u put in your name and press load
flash gets the variable from the text file and takes you tothat level
like,...
if (myUser="john") {
open text file. and get otehr variables..
if (myLevel="level2"){
gotoAndStop("level2")
}
}
(excuse the poor action script it is just an eg)
is that possable?
and the last question..
if that file is not local (stored on the internet n not hard drive)
is tehre a way that the name an level n all can be saved ?
so taht the user can play with his level when wanted ?
(just like a score listing but difernt..)
thank you.
|