Afternoon all!
I’m having a look at the stats page and I want to have a variable that increases every time you go on the stats page.
At the beginning of my choicescript_stats page I have a simple line that says
*set count +1
This variable is defined at the beginning of the startup file.
The value increases fine but then if I leave the stats page and then go back to it the value won’t have increased any further.
I’m using CSIDE and the track variable option (i’ve also used some conditional if statements to check the values are being reported correctly).
So I enter the stats page and this values goes from 0 to 1.
I leave the page (via the return to game button) and CSIDE reports the value hasn’t changed.
I then go to the stats page and it reports the value goes from 0 to 1 again.
I did wonder if I was being stupid with my *set command syntax so I tried *set count count+1 just in case. Same difference. I’ve reloaded all my files and rerun the game and it’s the same. I must be missing something obvious but
I’ve got family visiting unexpectedly so I am a bit rushed.
Hopefully this all makes sense. Finally I DID get this to work once, when I had two consecutive line with the *set count +1 in place. But then when I reloaded it stopped working and I cannot replicate it.
Sorry for the chaotic post!
edit: the only possible scenarios I can see are that I’m either setting the variable incorrectly and it’s just assigning the value rather than adding to it. I have checked my code and I have other lines that work absolutely find outside of the stats screen. Or the values reset when you leave the stats page - but I’m not seeing the value change when I track it…