I need multiple toggles to cancel each other out, please help
OK I'm new to Max/Msp and so far I have been able to build what I need. Now I'm stuck and I've tried to search before posting this but couldn't find an answer. Here's where I am stuck. Maybe there is even a better way of doing this.
First Half: I have three toggles that trigger different functions, but when 1 toggle is on, the other 2 toggles need to be off. At no time can 2 toggles be on simultaneously.
Second Half: This needs to be cycled by a single "bang". So that as the bang is pressed, toggle 1 is on and toggle 2 and 3 are off. Bang again and toggle 2 is on and 1 and 3 are off, Bang again and toggle 3 is on and 1 and 2 are off. Bang a forth time and you are back to toggle 1 on and 2 and 3 are off... repeat.
Any help would be appreciated. Especially on the first half question.
radio group do it for ya?
Here's another way using actual toggles...
`
THANK YOU! That was exactly what I was looking for!
and I'll be checking out the radio function as well.
Here is a version with [coll]
for the 2nd question look up [decode]
I'm looking to do the same thing, but I want to randomly choose which toggle is on.
The problem with using random number generation, however, is that if it picks the same number twice, the toggle is untoggled. I need one toggle always to be on.
Any suggestions?
Hi, the easy version is to use [urn] instead or random- I would use the [%] modulo object (see patch).
hth o
o s -
Thanks for the quick reply! Not sure if I understand though. Your patch still allows for the possiblity of not having any boxes checked. That's my core problem, is that one and only one of the boxes needs always to be checked.
this patch checks for and discards repeated values
or:
Wow, thank you both. A lot! That's perfect.
What's the difference between [t b b] and a button with two outs?
I should read that. thanks much. I'm just getting into this stuff, but it's really fun!
And zl.scramble?
or not ;-)