PDA

View Full Version : Play control and loading control of animation


dwof
05-29-2001, 11:43 PM
I have a site with some flash animations and rolovers on the startingpage. One of the flash animations is an animated menu. The problem is I still have a normal dail-up internet account. Soon i'll get cable. The problem is on a dail-up account the loading time of the page takes a little time. Not too much but the problem is that the flash animation is already starting before ther rest of the page and the animation are completely loaded. This makes the animation quite shaky the first time you see it. What i wanna do is first load all the images and all other files including the flash animation and when everything is loaded i want the animation to start. Then it'll go smooth the first time you load it. Is there a way to do this.

Marx
06-02-2001, 09:18 AM
Hi..
I'm sure you could do this with an fscommand and javascript but I don't know the code required.
Another option would be to test how long it takes for your page to load up then place a 'pause' action at the begining of your swf file which matches the load time:

For instance, if your page takes 10 seconds to load then you could place the following script on an MC in the first frame of your movie:

onClipEvent (load) {
_root.stop();
wait = 10;
start = getTimer()/1000;
}
onClipEvent (enterFrame) {
current = getTimer()/1000;
timer = current-start;
if (timer>=wait) {
_root.gotoAndPlay(_root._currentframe+1);
}
}

Hope this helps.