I want to add music to a button and make it so it plays when the button is moused over, but stops when the mouse leaves the button. I've added the music to the Over state of the button but when I mouse off the music keeps playing, and if I mouse on again it starts over, overlapping the first play.
Is there any way to have the music play just on the over state of the button?
Try to do it with help of actionscript. In AS you can control the sound when to play and stop.
Don't put the music within the button.
Instead make a new movie clip.
Give the MC an instance name, such as "myMusic".
Drag the music onto a layer within that MC. Extend the time line so as to fit the music completely.
Now for the button, add this code
Hope that helps