Mobile and PC: how do I manage saved games?

0 favourites
  • 3 posts
From the Asset Store
A space themed game with high quality 2D graphics and addictive music that provide hours of fun
  • Hi again, everyone.

    As I move through the development of my first game, I'm faced with challenges at every turn. Good challenges, and I can usually work through them, but one thing has been bothering me: saving the player's progress.

    My thinking is that I'll create an array that saves the player's current level, total money, unlocked vehicles, upgrades and so on. That's easy enough, but when they quit the game, that info is lost. I've had a look at webstorage and that seems to be a good way to record information, but I'm worried about the cookie clearing issue.

    I'm developing for iOS and Android (CocoonJS), and PC exe (node-webkit)

    So, my questions: What's the best way to permanently save information on both of these platforms? Is there an internal function that can do this on all platforms?

    Thanks!

  • The Dropbox Plugin by Septeven gives u exactly the permanent saving u seek.

    Only downside is the player needs to be "online".

    But even when going ofline for a day would mean the player could save his/her progress as local webstorage.

    Then when internet pops up again, upload the complete webstorage "as json" to a dropbox .txt file.

    Then when the cookies are erased: have the player download his savegame from dropbox.

    Bam!

    In my "Universe App" i have a login & upload/download via webstorage combined with dropbox.

    Its awesome, realy easy!

    And now my app users can erase all the cookies they want, and never really loose the data.

    Unless ofcourse i erase the dropbox entirely.

    But also that is to be backupped.

    Kind regards.

    Savvy001

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thanks Savvy001, that's very interesting. I'm not too keen on forcing the player to be online, to be honest, but if it comes down to it then I may have to.

    On a related note, I've done some basic testing with apps made in node-webkit and CocoonJS, and they seem to have some permanence when it comes to storing data. I'm not sure exactly how these wrappers deal with webstorage but they seem to store the data locally, outside of the scope of the system's web browser.

    How long that data will stick around for is still an uncertainty, however.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)