can someone teach me to load a saved state?
QbAnYtO
Member Posts: 523
say i'm in level 2, game ask me "u wanna save?" i press YES
i exit the game....
go back to the game. it asks me "continue" and "new game" but i hit conitnue, then it loads level 2....
how can i make this happen?! lol
i exit the game....
go back to the game. it asks me "continue" and "new game" but i hit conitnue, then it loads level 2....
how can i make this happen?! lol
Comments
Then have a rule on your level that says;
Change attribute game.level to 2 (or whatever level you're on)
Save attribute game.level and give it a name of your choice.
Now you will want to put a load attribute on your splash/menu screen.
Load game.level with the name you gave it above.
Then have a rule on your continue button that says;
If touch is pressed and game.level = 1
Change scene to level 1
Otherwise
If game.level = 2
Change scene to level 2
Etc etc
Its best to just implement an auto-save like above without asking the user to save.
This will only work if played once through, if you have say 50 levels, get to 30 and then decide to play level 2 again, it would set the current level at 2 and not 30.
So you need to implement a current level and unlocked level. You'd need to tell it that if current level < than unlocked.level then just change scene.
That should give you the guts of what you need to do
i'm still a little confused tho...
ok i tried it. worked REALLY WELL! thanks man u have NO idea how much this has helped me.... i still got another issue...time to post a new thread
i'm trying to figure out how i can apply it to other levels