Counter

A whole number that goes up, down or back to a start value on triggers.

Parameters

NameTypeDescription
ValueoutputIntThe current count.
StepIntHow much the count changes on each increment or decrement.
IncrementTriggerAdds the step to the count.
DecrementTriggerTakes the step off the count.
ResetTriggerSets the count to the reset value.
Reset ToIntThe count after a reset.
Limit RangeBoolWhether the count is kept between a minimum and a maximum.
MinIntThe lowest count allowed. Only present when Limit Range is on.
MaxIntThe highest count allowed, included in the range. Only present when Limit Range is on.
At EdgeEnumWhat happens when the count would leave the range. Only present when Limit Range is on.Choices: Wrap, Stop

Counter keeps a whole number that triggers move up and down. Every increment adds the step, every decrement takes it off, and a reset puts the count back to the reset value. A negative step turns the two around.

With Limit Range on the count stays between the minimum and the maximum, and both ends are part of the range. Wrap continues from the other end, so counting up past the maximum lands on the minimum again. Stop holds the count at the edge. A reset value outside the range is brought inside in the same way. Turning the limit off hides the minimum, the maximum and the edge choice, and turning it on again brings them back with the values they had.

A common use is stepping through a list of things. A Beat on the increment and a wrapped range from 0 to the last index gives an index that walks through the list in time and starts over at the end.

Keywords: count, increment, decrement, step, index, tally