Good timeline usage?

  • uknightuss
  • Graduate
  • Graduate
  • uknightuss
  • Posts: 196
  • Loc: Los Angeles

Post 3+ Months Ago

I admit I am not overly experienced in flash, and even less experienced with actual actionscript.. Help is definitely appreciated if any is available!

I am loading external swf's into a main movie/timeline one at a time. Each individual swf is anywhere between 150 to 300kb.

In different frames of the main timeline I am using this code to load each external movie.. (swap all names for each different swf of course)

Code: [ Select ]

//actions for frame 315 main timeline
loadMovieNum("s01x3.swf", 1);

//actions for frame 630 main timeline
loadMovieNum("s02x5.swf", 2);
  1. //actions for frame 315 main timeline
  2. stop();
  3. loadMovieNum("s01x3.swf", 1);
  4. gotoAndPlay("s1");
  5. //actions for frame 630 main timeline
  6. stop();
  7. unloadMovieNum(1);
  8. loadMovieNum("s02x5.swf", 2);
  9. gotoAndPlay("s2");

"s01x3.swf" stands for "scene 1 x 3 photos". I have 5 scenes and 26 photos total to display. If I add all the keyframes up for all of the different swf's it amounts to approximately a couple, to three thousand keyframes. Each swf has its own %preloader on frame 1, with content starting on frame 2, and a stop command on the last frame of each sequence so they don't loop more than once.
The "stop" and "play" commands in the external swf's do not affect the main timeline that I can tell, at least I don't know how to make them..

So my real question revolves around how to use the "main timeline" of the "main movie" with each loaded swf.

I currently have it set up like this:
frame 1 - 315 = opening sequence
frame 315 - 630 = load and play s01x3.swf
frame 630 - 1030 = load and play s02x5.swf
frame 1030 - 1200 = load and play s03x2.swf
frame 1200 - etc.. = load and play s04x6.swf
frame etc... - to approximately 2500-3000 keyframes total

I am seeing a potential problem with the example1 scenario above, mixed with super slow computer connections.

------ Lets say that if the main timeline is loading one of the external swf's but is also playing along at the same time, what happens if the persons connection is so slow that the main timeline reaches the next loadmovie command before the first movie has finished loading/playing? I'll tell you what happens, bad design/ overlapping frames/ unpredictable behavior..

I need a way to ensure that each swf gets loaded and fully played before continuing on in the main timeline.

I saw the command "ifFramesLoaded()", and it almost seems like the kind of thing that could be implemented here, but I also saw that it is a deprecated function.. I'm not really sure what that means, but from the sound of it I think I'm not supposed to use that function anymore or something.. I never used it to begin with though, don't even know how to yet :roll:..

I am using blank keyframes in my main timeline for the amount of time it takes for each swf to play its keyframes out and then loading the next swf in line. I don't seem to get how you could control the main timeline of the main movie with commands that are on keyframes of the external loaded swf's, or even from commands on the main timeline itself..

It seems like it would be easier if you could set it up this way:
frame 1 - 315 = opening sequence
frame 316 = stop, load and play s01x3.swf, goto next frame
frame 317 = stop, load and play s02x5.swf, goto next frame
frame 318 = stop, load and play s03x2.swf, goto next frame
frame 319 = stop, load and play s04 " " "
frame 320 = stop, load and play s05 " " "
frame 321 - 650 = closing sequence, end.

Please forgive what you see above, it is not meant to resemble REAL actionscript in very many ways!

In case the meat of my question is unclear now I will clarify it again. How can I shorten the length of the main timeline while also being able to fully stop, load, play, unload, and play each external swf in line without any frame overlaps?

It is a matter of commands and lines of actionscript, and I don't really know the first thing about this end of things.. I see certain lines of script sometimes and it makes sense, but I don't know how to string different lines together to make a proper sequence of actions for my needs..

I admit I am not overly experienced in flash, and even less experienced with actual actionscript.. Help is definitely appreciated if any is available!

My thanks and best wishes to any with the patience and good heart to help. (not that my best wishes don't go out to everyone already!)

Sorry for writing a book here by the way, I felt the need to be detailed in my predicament!

Learn by doing research of course, but it never hurts to ask as well.
  • Abelius
  • Proficient
  • Proficient
  • User avatar
  • Posts: 260
  • Loc: Miami Beach, FL, USA

Post 3+ Months Ago


I will definitely go through this tomorrow Saturday when I have more time, but I can tell you one thing right now:

You can't have a MAIN TIMELINE with 3000 frames...!!! Not even 100 is healthy!

Talk to you soon, same place, same time! :)
  • uknightuss
  • Graduate
  • Graduate
  • uknightuss
  • Posts: 196
  • Loc: Los Angeles

Post 3+ Months Ago

Abelius, I am looking forward to any helpful info that you can give me.

I'm bummed out to see that nobody else has commented on this though, I figured I would at least get a couple responses by now.. I was hoping that my question would not go the way of the lost threads so quickly..

Well I am still hoping someone can show me the way to the light, the flashlight?!

No, really

Post Information

  • Total Posts in this topic: 3 posts
  • Users browsing this forum: No registered users and 7 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum

© 1998-2017. Ozzu® is a registered trademark of Unmelted, LLC.