Tuesday, December 29, 2009

Help with Flash music repeating?!?

i am making an animation with flash mx 2004 and i have music playing throughout the animation. I have a simple preloader at the beginning of the animation. At the end of the clip, i have the music continuing until the person closes the window. I placed a button at the end of the the clip so that it replays the movie when you clip on it (skipping the preloader of course).



I want the music to stop playing when the replay button at the end is clicked so i put the following action script on the button:



on (release) {gotoAndPlay(4);



}



on (release) {stopAllSounds();



}



After i put that in, the animation still repeats but the music stops and doesn't start again. The music starts on frame 5, the preloader ends on frame 3. If I make the replay action script to lok like this:



on (release) {gotoAndPlay(4);



}



then the music from the first time it was played continues and overlaps with the music from the second time around.



Help with Flash music repeating?!?

-(Myspace music www.myspace.com)



I'm not a Flash expert, but here is a suggestion.



Move your preloader to a separate scene. Access the scene menu from Window %26gt; Other Panals %26gt; Scenes. Use the + to add another scene, name it "Preloader" and make sure it's on top of the rest of your movie. This way, you can tell the music to stop when the preloader stops playing and there should be no overlap.

No comments:

Post a Comment