I'm trying to do this:
Spawn.ar({ arg spawn, events;
n = events;
BUT when events gets to a specified max number it wraps back to 0.
i fallaciously tried n = maxNum.wrapAt(events). nada. anyone? thanks as
always.
wrapAt() works similar to at(), it is wrapped indexing. [1,2,3].wrapAt(124) wrap does what you want, but in an inverse argument order: n = events.wrap(0, maxNum); or also you can do: n = events % maxNum; //modulo