Hi-Score save w/ local storage plus full mobile game capx.

1
  • 20 favourites

Attached Files

The following files have been attached to this tutorial:

.capx

Stats

6,125 visits, 9,175 views

Translations

This tutorial hasn't been translated.

Tools

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

1st) Make global variable Highscore=0 = your in game highscore variable

       Make Global variable Score=0  = your in game score variable

2nd) System - start of layout -localstorage- check for item "highscore" exist.

(highscore is the key I made up for this example but you can use anything)

3rd) Local storage-on item exist - Localstorage-set Highscore(global variable) to LocalStorage.ItemValue

4th) System - Score> Highscore - System-set Highscore to Score

                                                          -localstorage-set item "highscore" to Highscore

5th) System-every tick- set text to "Score:"&Score&"/Highscore:"&Highscore

Any questions feel free to ask just look at the capx file I included its a full game that actually is in the googleplay store now .

.CAPX
  • 1 Comments

  • Order by
Want to leave a comment? Login or Register an account!
  • if I have a text file that counts time in the game(making a endless runner game), can I get the time to score and to highscore