thx for clicking my newbie question…
My swf file includes a mute button for a sound and a looping sound file.
There are several methods I tried which dont work…
for example,
//frame 1
var loaded = Math.round(this.getBytesLoaded()/this.getBytesTotal()*100)
load_txt.text=loaded;
//frame 2
if (this._framesloaded < this._totalframes) {
this.gotoAndPlay(1);
}
else {
this.gotoAndPlay(3);
}
type of preloaders start from %60 or some unnecessary high value,probably because the sound files are processed before the preloader.
I can’t find out how to make a preloader for a movie having sounds.
Because I need to control the volume of the sound I add the sound using :var song:Sound = new Sound();
song.attachSound(“music”);
song.setVolume(100);
song.start(0,5000);
Another way I know to add the sound is to drag drop the sound file to stage.
But then I can’t find a way to mute the sound with a button.
Is there a way to control the volume of the stage-drag dropped sound?
(because with drag dropped sound I can make another swf which loads my main swf with loadMovieNum—this shows progress correctly,however I can’t control the volume of the sound in main swf because there is no sound object)
I don’t want to use stopAllSounds() method,because by using it the sound starts from beginning when it is played again.
What is the method of making a preloader with a complete swf having sounds and having a sound mute button inside?
thx again…