Webstorage Bug - Need Help

0 favourites
  • 1 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • EDIT: -------------

    Problem Fixed


    My first mobile game I'm developing with C2 is based with worlds and levels.

    Currently it has 2 worlds and 30 levels done and its playable, I used 2 webstorage local keys, one for each world to save levels.

    I got 3 Global variables:

       Level set to 1

       CurrentLevel set to 1

       Win set to 0

    Then got levels 1 - 15 ''unique sprite'' each with animations,

    unlocked = frame 0

    locked = frame 1

    Now at level 1 there's a finishline and when the mainactor collides with finish line, set global variable Win to 1


    ---IF Global Variable Win is 1 ---- set CurrentLevel to 2

                                   ---- go to level2


    ---IF Global Variable Win is 1                  ---- Set Level to 2

    ---IF Level is GreaterOrEqual with CurrentLevel ---- Set Loaclkey save to Level


    and so on for each level

    Now at World select I got a event:

    Every Tick --- Set Global Var Level to WebStorage.LocalValue"save"

    Now my problem is that when I test it on Browsers, this save system works perfectly, but when I tested it on 2 different Galaxy S3 and one Galaxy S2, I got a wierd bug, On the first S3 I tested, this save method didn't work, then I tried it on another S3 and Saves did work! yay!, then I tried on a S2, boom again saves didn't work.

    I don't understand this, why saves are working on browser and on this S3, while they didn't work on another S3 and on a S2.

    I can provide with a Capx if needed as this was difficult to explain here.


    EDIT: -------------

    Problem Fixed


  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)