Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Flash movie drags & preloader

Status
Not open for further replies.

jennjenn

Programmer
May 23, 2003
1
US
Hi,

Dave sent me and said everyone is most helpful here.

I have a main movie
on View Presentation and register and then the movie starts automatically)
that loads 11 movies and plays them sequentially. The individual movies also have mp3 voiceovers which stream. The problem is that the tweens can't keep up with the mp3 voiceovers. They sync properly on my local machine, but when you watch the movie on the web, the movie lags behind the voice and makes the movie very long.

I need help to make the play back of these movies seamless without waiting for the flash tween to catchup to the voiceover and the first movie needs to start playing within 20 seconds for 56K.

I also need to know how to create a basic percentage bar preloader built on the front of the movie. Since the main movie loads instantly and calls the otehr 11 movies I don't know how to create a preloader for this type of circumstance. The actionscript on the first frame of the container/main movie is:

stop();

numberOfMovies=11;
loadCount=0;


for(i=0;i<numberOfMovies;i++){
createEmptyMovieClip(&quot;mcHolder&quot; + i,i+1);
}

function playMovies(){
_root.mcHolder0.gotoAndPlay(2);
}

loadStage=0;

loaderInterval=setInterval(loadChecker,100);
function loadChecker(){
if(loadCount<numberOfMovies){

if(loadStage==0){
loadMovie(&quot;movie&quot; + loadCount+&quot;.swf&quot;,_root[&quot;mcHolder&quot; + loadCount]);
loadStage=1;
}
else if(loadStage==1){
dataLoaded=_root[&quot;mcHolder&quot; + loadCount].getBytesLoaded();
dataTotal=_root[&quot;mcHolder&quot; + loadCount].getBytesTotal();
if(dataLoaded>=dataTotal && dataLoaded>0){
if(loadCount==9){playMovies();}
loadCount++;loadStage=0;
}
}

}
else if(loadCount>=numberOfMovies){
clearInterval(loaderInterval);
}
}

Thank You for your help!
Jennifer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top