...remember a savestate after closing the app

0 favourites
  • 5 posts
From the Asset Store
Create your own casino app and import it to Google Play and the App Store.
  • In my Android app I have created something which uses a saved variable to determine the output. The variable is determined by the user in the "settings" part of the app, and when created a savestate is made. Upon loading the homepage the app loads itself from that specific savestate. Then when they load a specific page it should display some text dependant on the variable. If I return to the main menu I can carry out this procedure as many times as I want without re-determining the variable, however if I close the app from the running apps list, then re-open it, the user will have to re-input the variable through the settings menu!

    Kinda confusing I know but if you have any questions about it ask. Would really like to get to the bottom of this! It just doesn't seem to keep the savestate upon rebooting the app

  • Posting your project file may help.

    Possible problems.

    1. Make sure you are using local storage and not session.

    2. Make sure you are not resaving or setting the value to default on any of your layouts.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • i'm definitely not resaving the session on any other layouts but how do I know if i'm using local or session? thanks

  • Ok so I was creating savestates by going system -> save then "save01"

    and loading from system -> load "save01" but this wasn't working. I watched a guide on youtube about using JSON and he hadds a JSON object by double clicking the layout but my one has JSON missing from the list. I have tried saving the score variable by doing Set Local key "S1" to HighScore and loading by doing Load Game from JSON String "S1" but this just freezes my app!

  • Ok so I finally got it working using JSON saves. Not sure what the whole "System -> Save" and "System -> Load" is for but it seems temporary and I won't be using that again.

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