MZ Stuck on a variable counter issue

I am using Main Menu Core VisuStella MZ for my main Menu and I need to add a few things like step counters. Well the counters are showing up they're not functional their remaining at zero. I can't figure out what I'm doing wrong.


Screen Shot 2025-02-12 at 5.40.18 PM.png
First of all, love the name Houtenburg. (I might take that for my book :LZSevil:)

Anyway, what exactly are you using for the counter?
You're free to use it 😛 I'm trying to set up a variable to count steps so that I can tie it in with the plug-in and have it appear in the menu system and while I can get the variable to show up in the menu I can't get it to actually count. I'm obviously doing something wrong and probably need to start it from scratch. The end I have three variables I need to create one for gold one for playtime and one for steps
You're free to use it 😛 I'm trying to set up a variable to count steps so that I can tie it in with the plug-in and have it appear in the menu system and while I can get the variable to show up in the menu I can't get it to actually count. I'm obviously doing something wrong and probably need to start it from scratch. The end I have three variables I need to create one for gold one for playtime and one for steps
What have you actually done so far to attempt implementing this?
I'm trying to set up a variable to count steps so that I can tie it in with the plug-in and have it appear in the menu system and while I can get the variable to show up in the menu I can't get it to actually count
when are you setting that variable?

also if wherever youre putting this accepts JS, you can bypass the variable and use
Code:
$gameParty.steps()
This is pretty much where I'm at because nothing I've tried is working
Screen Shot 2025-02-12 at 6.38.26 PM.png
This is pretty much where I'm at because nothing I've tried is working
View attachment 331371
*where* are you doing that, though? (also "steps" is one of the built-in things you can set with "game data" but it uses the same function so not really vastly different)
This is pretty much where I'm at because nothing I've tried is working
variables dont update automatically. your event that sets the variable to the number of steps needs to be used in order for it to update the value.

also i mentioned the $gameParty.steps() thing under the assumption that the plugin you were using allowed you to directly put in JS. it doesnt seem to be the case, so you can disregard that... or not. it doesnt make much of a difference

does the plugin allow you to call a common event as the menu is opened?
So I'm trying to set the variable up through an event and then put the variable into the plug-in under the variable window and it does seem to be reading the variable but not the counter
Screen Shot 2025-02-12 at 7.21.30 PM.png
So I'm trying to set the variable up through an event and then put the variable into the plug-in under the variable window and it does seem to be reading the variable but not the counterView attachment 331378
What exactly do you mean by "put the variable into the plugin under the variable window"? You're showing us small parts of the whole individually but you need to show everything you're doing in order to determine which part you didn't do correctly.
Screen Shot 2025-02-12 at 7.26.20 PM.png
So, you set your variable to steps once but it doesn't update itself, you have to tell it to update. You have to either call a common event before the menu to update the steps variable or have a parallel common event constantly updating the variable with a wait of 6 or so.
So it looks like your event from a post prior to that is a map event, which would only count steps on that particular map, even if it's parallel process. What you want is a parallel process *common event* that sets variable 3 to steps.
Worked for a second but the play timer didn't take the money constantly went up in the steps were ridiculous
Fixed the money issue I forget I had another event that was clashing with it
the steps were ridiculous
screenshots of what youve done would help. are you sure you made the common event to "set" the variables and not "add" to them?
OK so the steps are working and the gold looks like it works but the timer is a different issue. Instead of being 00:00:00 constantly counts up and once I get to 60 keeps going
OK so the steps are working and the gold looks like it works but the timer is a different issue. Instead of being 00:00:00 constantly counts up and once I get to 60 keeps going
"Play time" in the variable settings is in seconds, so you'd have to do some calculations with it to split it into hours, minutes and seconds.
the engine can do it for them. theres a function that does the divisions and formats the text
Code:
$gameSystem.playtimeText()
theyll just have to set the variable's value to it
So close! The script worked! Timer doesn't count while the menu is open but I can deal with that later last question and I do appreciate all the help and set up as a common event and the variable is said through the plug-in but I did notice that when I moved to a new area it stops counting.

Original thread: https://forums.rpgmakerweb.com/threads/stuck-on-a-variable-counter-issue.175407/