Create 4 button switch logic using pictCtrl toggles

Blair's icon

I need to create a 4 button switch with pictlCtrl toggles. live.switch and mgraphics don't suit my needs right now

This is my current setup which is working well but I want one mode to always be selected but right now you can just click off the selected one, but I don't know how to make the logic do that.

when you select A, it sends a 0 to B C D

Max Patch
Copy patch and select New From Clipboard in Max.

Source Audio's icon

Why don't you use tab or live.tab ?
they both do exctly what you want.

if you insist on using textbutton or pictctrl for whatever reason,

Max Patch
Copy patch and select New From Clipboard in Max.

Blair's icon

Thank you! i like this, quite a clever setup! I needed to use specific border radiuses for each corner + angled gradients. Cheers!

Roman Thilenius's icon

mgraphics would work fine, but will require you to get the required mouse logic and geometry absorbed.

i play the [t 1] game, too.

whenever a new one should be made active, first turn all off, then send set 1 to the recently pressed one. outlet number 17 gives you the button instance number.

and do not forget about the matrixcontrol object, which can also be used for this type of element.

Blair's icon

interesting idea 🤔