How do we create a HighScore variable to be stored in Android, even if the game is closed, and then have it retrieved when re-opened?
Does someone know how to do this?
Read the manual and the turorials, there are plenty that cover saving information. You can use the save game option, web storage, etc... all of these save it locally and work on every platform not just android.
Develop games in your browser. Powerful, performant & highly capable.
Use the WebStorage object: that's the simplest solution for storing only a few variables: it will save them locally and then you can retrieve the data any time.
BluePhaze and Roberto,
Thanks for helping. I read the page about WebStorage in the manual, and already did what I wanted.
The name is confusing so I wouldn't figure it out by myself.