saving and loading attribute not working?

RawanAlodehRawanAlodeh Member Posts: 51

hey guys
so i have published my game, but i have a big error that i need to fix asap

the thing is, after a level is finished, it unlocks the next level but if the player exits the game. only the finished level is unlocked

how do i fix this?

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    edited May 2015

    You use the Load and Save Attribute behaviors. Can you post screenshots of these?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • RawanAlodehRawanAlodeh Member Posts: 51

    what is weird that it saves the level that is finished. 1st screenshot is the actor that my chaacter collides with at the end of the level. the second one is the lock on the level. the 3rd one is the load attribute



  • RawanAlodehRawanAlodeh Member Posts: 51

    correction, 1st picture is the load attribute which is at the begining the "click to play" scene. 2nd one is the lock and 3rd one is the actor collides w/ to unlock next level

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    It's hard to tell from your screenshots but are you using a single Key for all of your unlock attributes? Also, in general I always make the Destroy behavior the last in the list since it's possible to destroy an actor and then not run any more behaviors (as you might expect).

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • RawanAlodehRawanAlodeh Member Posts: 51

    Yes i am using a single key for all unlocks. should i make a unique one for each level? okay ill try putting the destroy after and tell u

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    If you use a single Key then each time you save, you're overwriting the value of that Key. :/

    You'll need a separate Key for each unlock. If you have more than about three values to store, I'd highly recommend using tables instead of Load/Save Attribute behaviors.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • RawanAlodehRawanAlodeh Member Posts: 51

    how do i use tables?
    i create a table with the number of levels. boolean and make level 1 true, then have ID for each level. but thats when i get stuck, how do i make the lock actor dispear when the level is unlocked?

  • UtopianGamesUtopianGames Member Posts: 5,692
    edited May 2015

    You can try our free template below, it should have everything you need.

    http://www.deepblueapps.com/level-select-system/

  • RawanAlodehRawanAlodeh Member Posts: 51

    @DeepBlueApps said:
    You can try our free template below, it should have everything you need.

    http://www.deepblueapps.com/level-select-system/

    thank u, ive downloaded it. tried opening it but it says that gamesalad cant open gamesalad documents?

  • UtopianGamesUtopianGames Member Posts: 5,692

    It was made with an RC build so try renaming the extension to .gameproj

  • RawanAlodehRawanAlodeh Member Posts: 51
    edited May 2015

    @DeepBlueApps said:
    It was made with an RC build so try renaming the extension to .gameproj

  • RawanAlodehRawanAlodeh Member Posts: 51

    :'(

  • UtopianGamesUtopianGames Member Posts: 5,692

    No probs I will send you the normal version via email.

Sign In or Register to comment.