Other Software > Developer's Corner
[ActionScript 3/Adobe Flash] Play a sound when user clicks button?
RedPillow:
Oh ... I also have background-music playing from the start ... I'd like it to stop when I say so.
Tried this one:
--- Code: ActionScript ---var bgMusic:bgMsc= new bgMsc();bgMusic.stop();
Also this:
--- Code: ActionScript ---var bgMusic:bgMsc= new bgMsc();bgMsc.stop();
Error is this:
TypeError: Error #1006: stop is not a function.
at Untitled_fla::MainTimeline/frame96()
Isn't this similar (this is playsound-function when someone click the twitter-button)?:
--- Code: ActionScript ---function sound_play (e:MouseEvent):void {snd.play();}
Navigation
[0] Message Index
[*] Previous page
Go to full version