Global variables are not working![SOLVED]

0 favourites
  • 3 posts
From the Asset Store
Globals 2.0
$3.99 USD
Globals 2.0 stores and group variables. You can also load and save data (variables) from/to JSON files.
  • Hi!

    I have really weird bug occurring in my project. For some reason the global variables change on default value every time ANY layout loads. I am confused and frustrated, it could be that I am missing something obvious but I would like you to check it yourself. I thought at first that a problems is with the local storage but now when I have disabled all local storage functions I can see that the global variables are not working properly. Watch for behavior of "score" or "GlobalTestVariable" to see this phenomenon occurring. I have tried testing global variables in other projects and there they work fine.

    https://www.mediafire.com/file/mchwnr6qxrm1q5q/GlobalVariableBug.c3p/file

    Thank you,

    Martin Starešinčić

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You have a reset global variables action that runs when you exit the level...

  • You have a reset global variables action that runs when you exit the level...

    Oh god, thank you so much, didn't even know that action exist. Decided to ignore everything that didn't contain name of variables. Mix of this not being my code and unfamiliarity with this kind of action made me do such silly mistake.

    Thank you everyone for helping me and saving my time! Sorry and thank you for wasting yours.

    I really do feel bad and ashamed for bothering community with this, but it is what it is.

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