Forums > MaxMSP

button bangs on push/release ?

April 1, 2008 | 11:00 pm

Hello people..

I can’t find a way to trigger an event when i release the button object..I mean the simple bang button…

I need to trigger 2 events..one for press and one for release.
Is there a button type that works like mouse or key presses (1 on press, 0 on release)?


April 1, 2008 | 11:18 pm

Hi Tom,

Check out ubutton. The left-middle outlet sends a bang when the mouse
is clicked on the button, and left outlet sends a bang when the mouse
button is released.

-ben

tom wrote:
> Hello people..
>
> I can’t find a way to trigger an event when i release the button object..I mean the simple bang button…
>
> I need to trigger 2 events..one for press and one for release.
> Is there a button type that works like mouse or key presses (1 on press, 0 on release)?
>


April 1, 2008 | 11:21 pm

Probably many approaches, but you could try lcd object – the 3rd
outlet sends data you can use.

On Apr 1, 2008, at 7:00 PM, tom wrote:

>
> Hello people..
>
> I can’t find a way to trigger an event when i release the button
> object..I mean the simple bang button…
>
> I need to trigger 2 events..one for press and one for release.
> Is there a button type that works like mouse or key presses (1 on
> press, 0 on release)?


April 2, 2008 | 4:45 am

[mousestate]


April 2, 2008 | 7:40 am

See also rs.textbutton, which outputs the mousedown/up
state out of it’s right outlet – see maxobjects.com
for url,
cheers
Roger

— tom wrote:

>
> Hello people..
>
> I can’t find a way to trigger an event when i
> release the button object..I mean the simple bang
> button…
>
> I need to trigger 2 events..one for press and one
> for release.
> Is there a button type that works like mouse or key
> presses (1 on press, 0 on release)?
>


April 2, 2008 | 11:34 am

thank you people, it was so obvious with the u button!!
I will try the other objects too!


Viewing 6 posts - 1 through 6 (of 6 total)