Please!!!!
Could someone tell me an easy way or write out the script. I'm trying to load 30 external SWF files in order from 1.swf -30.swf ???
Thank you,
Liz
Printable View
Please!!!!
Could someone tell me an easy way or write out the script. I'm trying to load 30 external SWF files in order from 1.swf -30.swf ???
Thank you,
Liz
With a preloader or without? simple bar preloader?
Without a preloader. These will be loading in the background of another movie.
Liz
This will load movies 1.swf to 30.swf in levels 1 to 30 respectively, one by one in order:
P.S ive defined the array and startQueue function as global, so no matter where you are you can easily start and run a queue..Code:
var count:Number = 0;
var my_mcl:MovieClipLoader = new MovieClipLoader();
var loadListener:Object = new Object();
my_mcl.addListener(loadListener);
_global.aQueue = new Array();
_global.startQueue = function():Void {
my_mcl.loadClip(aQueue[0].source, aQueue[0].level);
}
loadListener.onLoadInit = function() {
count++;
if (count<aQueue.length) {
my_mcl.loadClip(aQueue[count].source, aQueue[count].level);
}
if (count == aQueue.length) {
count = 0;
aQueue.length = 0; //everything has loaded so now empty array so its ready for another queue push
}
};
//load movies 1.swf - 30.swf in levels 1 to 30
for(var i:Number = 1 ; i <=30 i++){
aQueue.push({source: i+".swf", level: i});
}
startQueue();
Thank you... Thank you.... Thank you....
Liz
yw yw yw :)
I am trying to do this exact same thing but when I try to use your code I am getting errors. I am really bad with action scripts - I really need some help, please! I have spent the last three days trying to figure this out. The problem is with this section:
_global.startQueue = function():Void {
my_mcl.loadClip(aQueue[0].source, aQueue[0].level);
}
These are the error messages I am getting:
**Error** Scene=Scene 1, layer=Layer 18, frame=1:Line 8: '{' expected
_global.startQueue = function():Void {
**Error** Scene=Scene 1, layer=Layer 18, frame=1:Line 10: Unexpected '}' encountered
}
Please help me!
Make sure your publish settings are set for flash player 7 and actionscript 2
ok. I have got it to work - to load all the movies. Now how do I controll how they play back - right now they just all show up at the same time. I know should have posted these questions in the newbie section - I am in way over my head. Please help!
locally they will show up at the same time as there is no speed issue..online they will show one by one as they load..
So it will play all of 1 and then when that is finished it will start 2 and when that is finished it will start 3, etc? I want all of the movies to load and then play in order.
Hi
No the above script only loads them in order it does not play them in order.. to do that what u need to do is put a stop action at the beginning of each of the movies(except the first movie) and on the end frame of each movie you tell the next movie to start playing
Is there a way to control the movies from the main movie? If I wanted to have a stop, play, and rewind button. And also, there is a little pause between each movie, is there any way to get rid of that? Thanks for answering all my questions!