What do I type under frame actions if I want to stop music from playing once I reach a certain frame?
What do I type under frame actions if I want to stop music from playing once I reach a certain frame?
Hi,
Are you using frame sound or loading sound into an object?......
stopAllSounds();
or
mySound.stop(["idName"])
Which is which?
And I'm using frame sound but if you could tell how button sound works that would work much better.
Hi,
stopAllSounds();
will stop all sounds in the movie.
button sound is just putting the sound on the appropriate keyframe in the button.
Object sound takes a bit of actionscript. You need to create a new sound object and then depending on how you want to load it..... either attaching it from the library or using the loadSound method...
This would require the sound to be in your library and exported for actionscript in the first frame with an export name of "soundtrack"Code:mySound = newSound(); mySound.attachSound("soundtrack"); mySound.start(); trace("Soundtrack is " + mySound.duration/1000 + " seconds in length");
Here is a very nice sound tutorial.......
http://kennybellew.com/tutorial/
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks