Build Your Own Arcade Controls Forum

Main => Main Forum => Topic started by: michelevit on January 31, 2007, 10:53:18 am

Title: would like to play a sound when a button is pressed? how can i do this?
Post by: michelevit on January 31, 2007, 10:53:18 am
i am building up a full size cab from scratch and have installed a
coin door and a credit button.

my joystick and buttons are wired to a joywiz.
what i would like to do is have a sound trigger
when the credit button is pressed. is there a simple program
that will play a .wav or .mp3 in the background when
a button is pressed?
i am inspired by the sk jukebox program which has
a coin drop sound when the credit button is pressed.
 
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: roadrunnr on January 31, 2007, 11:20:54 am
I know that many MAME games do this automatically in their original software.  For example, Ms. Pac Man plays a 'gwoink' kind of sound when you put a quarter in.  Pretty cool for a newbie like me!
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: ahofle on January 31, 2007, 11:22:43 am
I can't think of many arcade games that DON'T play a sound when you insert a credit.    ???
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: (+_+) on January 31, 2007, 12:28:29 pm
I just ran a quick test in my app and it appears that because mame's dos window now has focus, the application does not capture the keypress (ie credit button). The only thing I could think of would be an app running as a service that is listening for certain keystrokes and play a sound based on this. From what I've seen most games do this in Mame already when the coinup is pressed.
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: shardian on January 31, 2007, 12:30:41 pm
You could always get one of those simple voice recorder thingies, hack a simple mono amplifier and a new speaker to it, hack the play button to be pressed when you press the coin button and voila, independent coin op sound from inside the cabinet. ;D
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: headkaze on January 31, 2007, 01:10:28 pm
Check out this thread

http://forum.arcadecontrols.com/index.php?topic=60166.0
Title: Re: would like to play a sound when a button is pressed? how can i do this?
Post by: ahofle on January 31, 2007, 01:31:19 pm
Check out this thread

http://forum.arcadecontrols.com/index.php?topic=60166.0

Wow, that's a neat idea.  Did anyone try Silver's suggestion from that thread?  Anyone get it to work?