A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: How to load a ekstern swf, but it shall not start at frame 1

  1. #1
    Member
    Join Date
    Jan 2004
    Location
    Denmark
    Posts
    38

    How to load a ekstern swf, but it shall not start at frame 1

    I have a big project, with a lot of moviess. Now I have to jump to another movie, where I have made som frame labels with a stop action.

    My problem is that I can make it jump to the new movie, if I use this code below, but then it starts at frame 1. How do I make it start fx in frame 10 ?

    Code:
    on (release) {
        loadMovieNum("mbi3_vestjylland.swf", 1);
    }
    I dont know how to make it jump to a scene fx. at frame 10

    I have tried to use this code, but it dos´nt work (I have placed a label called lemvig2 and I want the movie to start there and not in frame 1

    Code:
    gotoAndPlay("vestjylland", "lemvig2");
    So my problem is, how to jump to a new movie and start fx in frame 10 ??

  2. #2
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Try this on the button

    on (release) {
    whatFrame = 10;
    loadMovieNum("mbi3_vestjylland.swf", 1);
    }

    Then in frame 1 of the mbi3_vestjylland.swf movie add this code:

    if(_root.whatFrame == 10){
    this.gotoAndPlay("lemvig2");
    }

  3. #3
    Member
    Join Date
    Jan 2004
    Location
    Denmark
    Posts
    38
    I have done exactly what you wrote, but it only plays frame 1 in the loaded movie.....hmmm

  4. #4
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Sometimes framelabels don't work right, especially in loaded movies. Try changing the frame code:

    if(_root.whatFrame == 10){
    this.gotoAndPlay("lemvig2");
    }

    To this:

    if(_root.whatFrame == 10){
    gotoAndPlay(10);
    }

    maybe change the button code too:

    on (release) {
    _root.whatFrame = 10;
    loadMovieNum("mbi3_vestjylland.swf", 1);
    }

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center