Skip to main content
Question

Using Variables to manage global counter

  • February 3, 2025
  • 0 replies
  • 26 views

Pietro_Franchini

Hello everyone,

I need to manage the counter 16 at the top using variables.
Each time I press plus on a counter, I add one point to that counter while subtracting it from 16. Conversely, when I press minus on a counter that has at least one point, I subtract the point from the counter and add it back to the global counter.

I want the global counter (16) to be influenced by all these counters without exceeding 16 when pressing plus more than 5 times on a single counter or going below 0 when pressing minus too many times.

Additionally, each counter is limited between 0 and 5. The global counter (16) should not be affected by more or less than 5 points per individual counter.

How can I manage this variable?
 

 

0 replies

Be the first to reply!

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings