AutoSave

SwaggedSwagged Member Posts: 50
edited November -1 in Working with GS (Mac)
I want my app to save gameplay when it is exited. like whatever level you were on you start there.

Comments

  • DrGlickertDrGlickert Member Posts: 1,135
    You mean through the viewer/creator? What do you mean by exited?
  • SwaggedSwagged Member Posts: 50
    like lets say i start playing and then i turn the app off, now i want to start on the level i left off on
  • DrGlickertDrGlickert Member Posts: 1,135
    Ahh, got ya.

    "Continue Mode"

    I'd use "Save Attributes" and "Load Attributes" mostly on the main menu scene.

    So when the player gets to each level, at the end of the level, have an actor to a "Save Attribute" (a game.attribute that's an integer will suffice). Level 1 would be "Save Attribute game.LevelOn to 2". Then level 2 completed would be "Save Attribute: game.LevelOn to 3."

    When the game is started have in the opening/menu scene a "Load Attribute." Load the last game.LevelOn (of say 5; so they've finished level 4 and they'll begin on level 5).

    When the player clicks on a button that says "Continue" the loaded attribute (LevelOn = 5) will take them to the scene that they played up until (Have a rule; If LevelOn = 5, load scene/level 5) on it.

    Good luck!
Sign In or Register to comment.