What is wrong with my array saving events? Capx inside

  • Hi guys, in my capx, you can see that the array is not properly saved as it won't show the new value once you restart the layout. Press the Up sprite to change value, and press the restart sprite to restart the layout.

    If you play it in the debugger, you can see that once it restarts layout, the values all return to 0. I guess it must be that I am not properly saving my array cause the loading seems to work. But I am using the same style of code from an earlier game of mine that worked. I am sure I must be missing something simple.....I hope.

  • You have a number variable instead of text. Also you can store the array as a single JSON string instead of specifying each individual element.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Haha thanks so much ramones! It indeed was something so simple. Also, thank you so much for the showing me how to save as a Json string. I'm just starting to learn about it and I thought the only way to save it was to use the download action, but that was not appropriate for mobile games. Again, thanks! I can continue on with my game now.

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