how do you test the load game attribute?

johnydeejohnydee Member, PRO Posts: 196
edited November -1 in Working with GS (Mac)
I have tried to test Load\Save Attribute in GS Viewer and it seems it dosen't work. It should properly only in ad hoc?

Comments

  • imGuaimGua Member Posts: 1,089
    I have made a simple project to test it, and it dosen't work, what am I doing wrong?

    (go to youtube to watch in HD)


    Project: http://creashock-studios.com/xlam/vis_test.gameproj.zip
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    You can test load and save in the creator as well as the viewer by clicking the refresh icon in the preview window of the creator. That refresh is the same as exiting and reopening the app.

    image
  • imGuaimGua Member Posts: 1,089
    Can you tell why my example dosen't work?
  • SkyMapleSkyMaple Member Posts: 817
    Make sure you are saving the attribute AFTER it changes, also check to make sure that the keyword is the same in both the load and save.

    _______________________________
    Follow me on Twitter!
    https://twitter.com/SkyMapleGames
  • imGuaimGua Member Posts: 1,089
    Look at first shots of video in HD, you can see all game logic. I also tried to make a version where I load attribute on separate scene, same result.
  • JohnPapiomitisJohnPapiomitis Member Posts: 6,256
    hmm try putting the save attribute behavior in a timer every 0 seconds inside the mouse is down rule. I remember having a problem like that a while ago and that fixed it, but since then the issue has been resolved and it works without the timer. Wont hurt to try though
  • johnydeejohnydee Member, PRO Posts: 196
    So iam trying to see if the level unlock system save attribute saves the game state when you exit the game.I tried it on the viewer but it dosent seem to work.How can i see if its saving the last highest level completed so when the user comes back they can start where they left off?
  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    Hey John,

    Build your game on your device, also known as an adhoc.

    Tshirtbooth has a great tutorials series for it, search it up on his website: www.gshelper.com
  • johnydeejohnydee Member, PRO Posts: 196
    oh ok...
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    Hey John,

    Check Above I just merged in the thread on how to test save an load attributes that discussed yesterday.

    It can actually be done from the creators preview if you are not ready for testing on device yet.
  • johnydeejohnydee Member, PRO Posts: 196
    yeah i tried the viewer this way but dosent work so i guess i dont have it down properly
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    johnydee187 said:
    yeah i tried the viewer this way but dosent work so i guess i dont have it down properly

    you would probably be correct. you need to make sure you are saving an attribute to begin wit and make sure the key you save it to matches exactly how your are loading it. Also Make sure you run the viewer or preview from the menu screen or where ever the attributes load from. otherwise the rules will never run.

    Hope that helps
Sign In or Register to comment.