how to Trigger object when the bang is off vs on
Hello this I feel Is somewhat a simple question. but haven't been able to solve it. I don't understand very well
how the if statements work in max msp.
I have a gate object that outputs a number that is going from 0 to 320 in various sequences, if I attach a bang to the same outlet the bang stays On if the number is moving , as soon as the number stops moving the bang turns off. This is great.. my question is what object do I need to detect the bang when it turns off and detect it when it turns on
so I can trigger different events when the number stops moving(bang off) from when the number is moving(bang on).
thanks for the time.
oh je. ^^
a bang in max is nothing but the message "bang", just like the
message "hello" .. it does not turn on and off ... unfortunately
many newbies are mislead from the [button] object´s behaviour.
what you want to use to find out about the densitiy of incoming
events is the [timer] object (in conjunction with [if] or [==] when
you want a true false output for activity.)
[timer] is not easy to use at first but it is worth the hassle.
-110
thank you
here's a solution which doesn't use an expression or a timer, just some conditioning using [maximum], [-1], [select] and the inevitable [onebang]; selecting peaks and troughs is a common head-scratcher and has eluded me for some time so i'm glad you posted this question; some may find this one a little convoluted, but it's as minimal as i can make it:
Brendan
ps
for better functionality on startup, the [onebang] object on the lower right should NOT have the argument '1'
ooops
thanks very helpful
Great solution Noob_Meister !