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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I wait for a movie to finish loading

Status
Not open for further replies.

ueberbill

Programmer
Aug 22, 2000
21
US
I have this controller movie at level0 and an opening movie at level1.
Depending on where the user clicks, level1 sets a variable (just a number) within level0. Level0 then unloads level1 and then loads another movie into level1. This new movie should be played at the frame specified by the number that the previous level1 set but I can't do a gotoAndPlay until the new level1 has finished loading. How do I, in the frame of level0 that just loaded the new level1, wait for level1 to finish loading so that I can tell it to goto it's correct frame?
I hope that wasn't too hard to decipher :)
Thanks,
Bill
 
Instead of sending the variable from your _level0 when you wait for level1 to load, you should read the variable from the level0 at anytime.

-You could create an action in your first frame of the new level1 movie like this:

Set Variable ("readvar",_level0:var);

This way you assign the value of the variable from level0 to a local variable in level1 and you can use it as soon as the movie finishes laoding. You could even write the actionscript to react to this variable and only load the frames you need. As soon as the frame you need loads, you use the variable. (If frame is loaded in a 2 frame loop)

I hope that helps.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top