Multiple movie clips within a button

I'm having trouble with working a movie clip played one after another within a button. Can anybody help? or is there a simpler way of getting multiple movie clips to play?
for my project, when you hover over the button and vines grow out. currently, i have one working in a button but i can't seem to get other vines to work.

use a movieclip (or sprite) button.  you can then control the child movieclips with actionscript.

Similar Messages

  • Playing a Movie Clip within a Movie Clip on load

    Hi,
    I'm trying to play a Movie Clip animation that is within a Movie Clip after a button has been pressed in a different Movie Clip.
    The issue is that all Movie Clip animations are playing as soon as the SWF is loaded.
    I have a separate Main.as file that contains all of the coding except for the animation stops:
    package
              import flash.display.MovieClip;
              import flash.events.MouseEvent;
              public class Main extends MovieClip
              var title1:Title1;
              var scene1:Scene1;
              var scene2:Scene2;
              var scene3:Scene3;
              var scene4:Scene4;
              var scene5:Scene5;
              var scene6:Scene6;
              var scene7:Scene7;
              var scene8:Scene8;
              var scene9:Scene9;
              var scene10:Scene10;
              public function Main()
                        title1 = new Title1();
                        scene1 = new Scene1();
                        scene2 = new Scene2();
                        scene3 = new Scene3();
                        scene4 = new Scene4();
                        scene5 = new Scene5();
                        scene6 = new Scene6();
                        scene7 = new Scene7();
                        scene8 = new Scene8();
                        scene9 = new Scene9();
                        scene10 = new Scene10();
                        addChild(title1);
                        title1.buttonStart.addEventListener(MouseEvent.CLICK,onButtonStartClick);
                        scene1.buttonWalkOutside.addEventListener(MouseEvent.CLICK,onButtonWalkOutsideC lick);
              //title
              function onButtonStartClick(event:MouseEvent):void
                        addChild(scene1);
                        removeChild(title1);
                        Scene1(parent).gotoAndPlay("frame1")
              //scene1
              function onButtonWalkOutsideClick(event:MouseEvent):void
                        addChild(scene2);
                        removeChild(scene1);
    So right now, I'm getting this error:
    TypeError: Error #1034: Type Coercion failed: cannot convert flash.display::Stage@46534041 to Scene1.
              at Main/onButtonStartClick()
    Any help is greatly appreciated... I've been grinding at this all night.

    I had been trying a bunch of different methods after searching for clues on Google, so it probably doesn't make sense with the parent.
    I replaced the code with what you wrote, and I am given this error now:
    Main.as, Line 44
    1120: Access of undefined property scene1Text1.
    Is there somewhere I have to declare scene1Text1 in Main.as?

  • HitTest for multiple Movie Clip at the same time

    I have a movie it is a triangle.I duplicate it and I want to hitTest on the first triangle movie clip and I added 3 different line movie clips on the 3 side of triangle.I tried to write a code something like that.
    if(firstTriangle_mc.hitTestObject(line1_mc,line2_mc,line_3mc){
    trace("Ok");
    but I've got error.I think it is not allowed hitTestObject for multiple Movie Clips.So is there anyone have an opinion about it?What should I do?

    Here is another test for multiple movie clips for hitTestPoint but only the first work the others don't
    uc_mc.addEventListener(Event.ENTER_FRAME,hitle);
    function hitle(e:Event) {
    if (uc_mc.hitTestPoint(cub1,cub1Y,true)&&(cub2,cub2Y,true)&&(cub3,cub3Y,true)) {
      uc_mc.alpha=0.5;
    }else{
      uc_mc.alpha=1;
    The code above doesn't work.What should I do?

  • Multiple movie clips in variable

    Is it possible to have multiple movie clips inside one variable? I want to be able to just use var._totalframes instead of mc1._totalframes, mc2._totalframes, etc... Or is there another way I can avoid copying and pasting dozens of movie clips over and over? Thanks.

    You can use the bracket notation in a loop to process multiple similarly named objects such as you described...
    for(i=1; i<someNum; i++){
         something += this["mc"+ i]._totalframes // not clear on your intent
    I can't be sure I am answerng your question when you mention copying and pasting movieclips.

  • Loading Movie Clip from a button

    Hi,
    How do I load a movie clip from a button? So far on my button
    (b1), I have this AS: and I want the button to load the movie clip
    "char1." My button already has some AS:
    b2.onRollOver = function() {
    _root.captionFN(true, "Hi!", this);
    this.onRollOut = function() {
    captionFN(false);
    How would I go about adding more script to load a movie clip
    to my button b2?
    Thanks

    Hey - Unfortunately I'm going to be in meetings for most of
    the day, so
    it'll take me a while before I can go through this in any
    detail. One thing
    that struck me though is that your two functions (captionFN
    and
    hoverCaption) are in the main1_mc not on the main timeline.
    Then the
    buttons are calling _root.captionFN(); which refers to the
    main timeline.
    I would expect that they should be calling
    _root.main1_mc.captionFN(),
    because that is the path to where the function is. Does that
    make any
    sense?
    One thing that I do when I'm writing code is to always keep
    all functions on
    the main timeline. That way you are sure that they are being
    registered
    (i.e. if you call a function before the playhead reaches
    where that function
    is written, the function won't work. If the function is in
    the first frame
    of the main timeline, you know that the playhead has reached
    it). What you
    might want to do is to move all your functions to the very
    first frame of
    your movie. Then you can call them with the path:
    _root.myFunction() and
    you are sure that they will be found.
    Maybe give that a try and let me know if it helps. In the
    meantime, I'll
    try to go through your code, but like I said, today's a bit
    of a gong show
    for me.
    Sorry - I don't mean to just sluff you off or anything.
    Cheers,
    Brock
    "respondplease" <[email protected]> wrote in
    message
    news:[email protected]...
    > Hi Brock,
    >
    > Thanks again, your sample file really helps but I'm
    still having problems.
    > What it boils down to is that my buttons don't fully
    function properly. It
    > works correctly sometimes, but not consistently enough.
    So if I fast
    > forward
    > too much or rewind and then FF, the buttons aren't
    either isn't clickable
    > or
    > the hover text and caption box doesn't show up, etc.
    This usually happens
    > when
    > I press FF too many times or too fast. But regardless of
    how many times I
    > press
    > FF I would like my buttons to work
    >
    > Your sample file is very useful but unlike mine I have
    perhaps too many
    > MC's
    > w/in MC's, etc. I will try to clarify my setup in hopes
    of finding a
    > (better)
    > solution to my problems. My main timeline has my "prev",
    "next", and
    > "pause"
    > buttons which also has the actionscript for my NEXT
    BUTTON, PREV BUTTONS.
    > And
    > now I've added your SHOW BUTTONs function as well. I've
    minorly modified
    > your
    > showButtons function adding a couple of more lines and
    actually deleting
    > the
    > _root because I found that it doesn't work sometimes.
    Anyhoo, here it my
    > entire
    > code in one frame on my main timeline:
    >
    > // ===== NEXT BUTTON ===== \\
    > next.onPress = function() {
    > _root.screen.showButtons();
    > _root.createEmptyMovieClip("controller_mc", 1);
    > controller_mc.onEnterFrame = function() {
    > _root.screen.gotoAndPlay(_root.screen._currentframe+10);
    > if
    (_root.screen._currentframe+10>_root.screen._totalframes) {
    > _root.screen.gotoAndStop(_root.screen._totalframes);
    > }
    > };
    > };
    > next.onRelease = function() {
    > controller_mc.removeMovieClip();
    > _root.screen.showButtons();
    > };
    > next.onReleaseOutside = function() {
    > controller_mc.removeMovieClip();
    > _root.screen.showButtons();
    > };
    >
    > // ===== REWIND BUTTON ===== \\
    > prev.onPress = function() {
    > _root.createEmptyMovieClip("controller_mc", 1);
    > controller_mc.onEnterFrame = function() {
    > _root.screen.gotoAndStop(_root.screen._currentframe-10);
    > if (_root.screen._currentframe-10<1) {
    > _root.gotoAndStop("screen");
    > }
    > };
    > };
    > prev.onRelease = function() {
    > controller_mc.removeMovieClip();
    > };
    > prev.onReleaseOutside = function() {
    > controller_mc.removeMovieClip();
    > };
    > // ===== SHOW BUTTONS ===== \\
    > function showButtons() {
    > for (i=1; i<=6; i++) {
    > _root["b"+i]._visible = true;
    > _root["char"+i].removeMovieClip();
    > chars._visible = true;
    > cap.desc._visible = true;
    > cap._visible = true;
    > }
    > }
    > Still from my main timeline, my main1_mc is called from
    the frame labeled
    > "screen." My main1_mc has the b1 - b6 buttons which has
    the HOVER CAPTIONS
    > and
    > HIDE BUTTONS FUNCTION coding. And each button calls each
    movie clip ie.
    > char1_mc, char2_mc, etc. Here's all my code on one frame
    (in my main1_mc):
    > // ===== HOVER CAPTIONS =====
    > b1.onRollOver = function() {
    > _root.captionFN(true, "pick me!", this);
    > //display the function (true) or to hide the function
    (false)
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char1_mc", "char1",
    _root.getNextHighestDepth(),
    > {_x:595,
    > _y:345}); //this attaches movie to the _root timeline,
    and renames it to
    > "char1".
    >
    > _root.char1.swapDepths(_root.cursor_mc);
    > //swaps the depth that the cursor is on and the new
    movieClip is on. So
    > the
    > cursor will stay on top.
    > };
    > };
    > b2.onRollOver = function() {
    > _root.captionFN(true, "Hi!", this);
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char2_mc", "char2",
    _root.getNextHighestDepth(),
    > {_x:605,
    > _y:345});
    > };
    > };
    > b3.onRollOver = function() {
    > _root.captionFN(true, "Get Jac'd Up!", this);
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char3_mc", "char3",
    _root.getNextHighestDepth(),
    > {_x:605,
    > _y:345});
    > };
    > };
    > b4.onRollOver = function() {
    > _root.captionFN(true, "Boo!", this);
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char4_mc", "char4",
    _root.getNextHighestDepth(),
    > {_x:605,
    > _y:345});
    > };
    > };
    > b5.onRollOver = function() {
    > _root.captionFN(true, "I'll be your guide", this);
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char5_mc", "char5",
    _root.getNextHighestDepth(),
    > {_x:605,
    > _y:345});
    > };
    > };
    > b6.onRollOver = function() {
    > _root.captionFN(true, "Welcome!", this);
    > this.onRollOut = function() {
    > captionFN(false);
    > };
    > this.onRelease = function() {
    > hideButtons();
    > _root.attachMovie("char6_mc", "char6",
    _root.getNextHighestDepth(),
    > {_x:605,
    > _y:345});
    > };
    > };
    > _root.captionFN = function(showCaption, captionText,
    bName) {
    > if (showCaption) {
    > createEmptyMovieClip("hoverCaption",
    this.getNextHighestDepth());
    > cap.desc.text = captionText;
    > // cap._width = 7*cap.desc.text.length;
    > cap._alpha = 75;
    > if ((bName._width+bName._x+cap._width)>Stage.width) {
    > xo = -2-cap._width;
    > yo = -17;
    > } else {
    > xo = 2;
    > yo = -17;
    > }
    > hoverCaption.onEnterFrame = function() {
    > cap._x = _xmouse+xo;
    > cap._y = _ymouse+yo;
    > cap._visible = true;
    > };
    > } else {
    > delete hoverCaption.onEnterFrame;
    > cap._visible = false;
    > }
    > };
    > // ===== END OF HOVER CAPTION ===== \\
    >
    > // ===== HIDE BUTTONS FUNCTION ===== \\
    > function hideButtons() {
    > for (i=1; i<=6; i++) {
    > this["b"+i]._visible = false;
    > }
    > chars._visible = false;
    > cap.desc._visible = false;
    > }
    > Sorry for copying and pasting all my code - I know it
    must be annoying,
    > but I
    > can't seem to find what's wrong. Again, ANY help would
    be greatly
    > appreciated.
    > Thanks for your patience. Your talent is very much
    appreciated and I'm
    > very
    > grateful for all your help.
    >
    > Kindest regards
    >

  • Playing multiple movies without clicking home button

    I want to create a piece of art containing multiple buttons. For example, an illustration of a field, where, if the user were to click on a bush, a rabbit's head would pop out briefly, then disappear behind the bush. If a lilly pad were clicked, a frog would pop his head out of water and again disappear. How can I allow the user to randomly click on the various buttons, triggering the associated movies to play, without necessitating that a "home" button be hit after each sequence?

    I can get each button to play the corresponding movie. After the movie plays, however, I would like the movie to automaticaly revert to the home state.
    In this way, the user could randomly click around on the image, triggering various movies when the appropriate buttons are hit. I have seen this done many times- I remember an an image of a hanunted house, for example. When the user clicked on a window, it would open and a ghost would look out. Without having to then click a home button, a further click on the door of the house would cause the door to open, and a mummy to lean out. I'm trying to avodi having to repeatedly hit a "home" button before additional button hits could trigger additional movie clips.
    I should probably mention that I've had to insert a stop command at the end of each movie clip, otherwise all the animations play sequentially, rather than one at a time, when a button is clicked. How do I tell Flash to procede from this stop command, at the end of each movie, back to home, so that further buttons can be pushed?
    Sorry if I've misunderstood your posting- I've been animating for several years on Flash, but have only started several days ago to use Actionscript 3 for interactivity, and am a complete novice, in that regard.

  • TellTarget to play a movie clip within a movie clip

    I currently have two movie clips in my scene with a button
    that lies inside one of the movie clips. We will call this movie
    clip for the sake of this post "ph." The button inside of ph has a
    rollOver/rollOut movie clip called "Buick_rollOut" attached to it
    as a parked movie clip through tellTarget. Currently Buick_rollOut
    only works if I put the parked movie clip on the same level as ph.
    I want Buick_rollOut to be within the movie clip, ph, that contains
    the button. I want that button be able to tellTarget the location
    of Buick_rollOut within ph. I hope this makes sense. Here is my
    code for the button that lies within ph. (this code only works when
    Buick_rollOut is located outside of ph on the same level).

    Is this code running on the button? What's the name of the
    button?
    Things would be a little clearer if you replaced tellTarget
    with dot notation:
    Buick_rollOut.gotoAndPlay("rollOver");

  • Attempt to move main timeline from inside a movie clip breaks menu buttons.

    I am attempting to have the main timeline move from a stopped position over a movie clip to frame 1, where my start menu is.
    The code I'm using does move the timeline but in doing so it somehow breaks the 4 buttons I have in frame 1.
    My code in the movie clip:
    stop()
    function replayMovie(event:MouseEvent):void
    MovieClip(parent).gotoAndStop(1);
    Menu.addEventListener(MouseEvent.CLICK, replayMovie);
    My code in frame 1 of the main timeline:
    stop();
    function bo(event:MouseEvent):void
    gotoAndPlay(21)
    SoundMixer.stopAll()
    espesp.addEventListener(MouseEvent.CLICK, bo);
    function ho(event:MouseEvent):void
    gotoAndPlay(31)
    SoundMixer.stopAll()
    espeng.addEventListener(MouseEvent.CLICK, ho);
    function yo(event:MouseEvent):void
    gotoAndPlay(41)
    SoundMixer.stopAll()
    engesp.addEventListener(MouseEvent.CLICK, yo);
    function go(event:MouseEvent):void
    gotoAndPlay(51)
    SoundMixer.stopAll()
    engeng.addEventListener(MouseEvent.CLICK, go);
    The error output when I use my Menu button at the end of the movie clip.
    TypeError: Error #1009: Cannot access a property or method of a null object reference.
    at SSubjunctiveProjNewgrounds_fla::MainTimeline/frame1()
    at flash.display::MovieClip/gotoAndStop()
    at SSubjunctiveProjNewgrounds_fla::Esp_5/replayMovie()
    Any help would be greatly appreciated.

    For the sake of space, I'll leave out all the package declarations and class declarations and just talk about the functions.
    First, the Game class, it has two functions.  The first one is the constructor function and it launches at the beginning of the game:  First the Game function:
    public function Game():void
    //Game code goes here
    }//Game
    We want to listen for someone to click the mouse on the MenuPage, so lets create a new MenuPage and add a listener to the button contiained within it.
    public function Game():void
    menuPage = new MenuPage;
    menuPage.startButton.addEventListener(MouseEvent.CLICK, startGame);
    addChild(menuPage);
    }//Game
    You will notice that before I declared a variable var menuPage:MenuPage, but that's all I did was declare it.  I didn't really make a new instance of it, I just set aside space for it.  In the first line within the Game function, I'm actually turning that variable into a new instance of a MenuPage.
    We don't have a picture of this imaginary menuPage instance, but lets' assume that in our MenuPage MovieClip in the library, we created a SimpleButton called startButton.  Here, I'm adding an EventListener that patiently waits for someone to click that button.  Once we receive that event, Flash is told to call the startGame function.
    As you get better at this, you'll get into custom events, and the eventListener for the button will exist in the MenuPage class file, or even in another class file that you create just for the button.  Something like StartButton.as  But for now, we can do it as above.
    Now the startGame function:
              public function startGame(evt:MouseEvent):void
    //Remove the start Page
    //Add the zombie
    //Add the gun
    }//startGame
    And we'll replace those comments with real code.  It follows along with what we just did above.
    public function startGame(evt:MouseEvent):void
    zombie = new Zombie;
    addChild(zombie);
    gun = new Gun;
    addChild(gun);
    And we also want to clean up some by removing the menuPage, and throwing out the eventListener.
    public function startGame(evt:MouseEvent):void
    zombie = new Zombie;
    addChild(zombie);
    gun = new Gun;
    addChild(gun);
    menuPage.startButton.removeEventListener(MouseEvent.Click,startGame);
    removeChild(menuPage);
    }//startGame
    Now our Game class is complete.
    The Zombie Class
    public function zombieWalk(evt:Event):void
    this.addEventListener(Event.ENTER_FRAME,zombieWalk);
    this.x = this.x + 10;
    }//zombieWalk
    Notice we've added a function to the Zombie Class.
    The first function adds an EventListener to the zombie.  We can use the word this and actionScript knows we're talking about the zombie that the class is written for.  This listener fires off every frame.  If our FLA file is set to 12fps, then 12 times every second it will call on the zombieWalk function.
    The zombie walk function moves the zombie 10 pixels to the right every time the function is called.
    On a more advanced level, you'll want to add animation in the MovieClip to move the zombie legs.  You'll also want to use Timer events to space out how often the funtion fires and not ENTER_FRAME events.  And you'll want to use a static constant to establish how far the zombie moves.  We have it now set to 10 pixels, but that can get irritating if we want to change that value later.  But again, baby steps.
    And finally, the Gun class
    public function Gun():void
    this.addEventListener(MouseEvent.CLICK, fireGun);
    }//function
    public function fireGun(evt:MouseEvent):void
    this.gotoAndPlay(2);
    }//fireGun
    First we add an EventListener for when someone clicks on the gun.  Once this happens, the listener calls on the fireGun function.
    The fireGun function takes advantage of the frames within the Gun MovieClip.  Say we have three frames in the Gun MovieClip.  The first is just a picture of the gun.  The second is the gun with a flash coming out of the nozzle.  And the third is the gun at rest again.  The line this.gotoAndPlay(2) sends the gun to the second frame with the flash graphic.
    For this to work, each frame in the Gun MovieClip has to have some stop and play commands.
    But.. you said no code on our timeline!! Liar!
    I know.  This is the exception.  You will need basic stop() commands and gotoAndPlay commands to loop animations.  Any MovieClip that has more than one frame will need something to control it.
    So our Gun MovieCLip has the following:
    Frame 1: stop();
    Frame 2: no actionScript... and I mean nothing, not even the words, "no actionScript"
    Frame 3: gotoAndStop(1);
    This will loop the gun to the beginning and wait for the next time the user clicks the gun.
    Advanced features of the Gun class might include a Bullet.as sub-class that creates a bullet MovieClip to fly across the screen.  Sound to play when the shooting takes place.  Object collision detection to see if the bullet hits the target.  And a means by which a custom event will tell the Game.as class that a zombie has been hit and it should be removed from the stage.
    As you go down the rabbit hole of ActionScript 3, you will find yourself at a point where it's just a matter of getting the syntax right for all the built in functions and classes.  Arrays, Loaders, casting variable types.. all that stuff will come.
    I hope this has been helfpul.  It's been on my to-do list for a long time.  When I first started out, no one could provide me with basic answers for how all these classes and whatnot worked.  After teaching myself AS3 for 2 years and reading a gabillion books, I think I've gotten to a point where I'm pretty comfortable with it all.

  • How to unload a movie clip within a movie clip.

    Hi all,
    I am trying to unload a movie clip that is on a layer in a
    movie clip. After clicking on a button, I would like the movie to
    go back to the previous menu without playing a couple of movie
    clips that's in the main movie clip.
    So at the end of my movie clip I have:
    _parent.gotoAndPlay("resources"); // resources is the frame
    name in the main movie clip where I would like the movie to restart
    from
    _parent.vhost_mc.unloadMovie("vhost_mc"); //vhost_mc is a
    movie clip in the main movie clip that I want to unload
    _parent.videoScreen_mc.unloadMovie();
    But the videoScreen_mc doesn't unload. The main movie clip
    starts with the videoScreen and I've actually deleted the frames of
    videoScreen_mc where the "resources" frame starts, but still it
    appears.
    I've even tried _parent.videoScreen_mc._visible = false; but
    nothing works! I've tried createEmptyMovieClip, but since the
    videoScreen_mc is on the main timeline, I don't think it works.
    I've even tried putting this function on the "resources" frame:
    onEnterFrame = function() {
    play();
    vhost_mc.unloadMovie("vhost_mc");
    vhost_mc.removeMovieClip();
    this.videoScreen_mc.unloadMovie();
    this.videoScreen_mc.removeMovieClip();
    this.mask._visible = false;
    But when I do this, the play button loops starting at the
    "resources" frame.
    Essentially I would like the main movie clip to play without
    certain movie clips that's included within the main movie clip.
    I hope I'm making sense. Please help, I've been at this for
    days!

    Olá Felipe, tudo bem com você?
    In order to unload content loaded into a Loader object you can use either the unload() method or the unloadAndStop() method. The difference between them is that unloadAndStop() will unload the loaded SWF and try to stop executing any code that it was running including animations, sound and event listeners.
    If you wanto to call the unload() or unloadAndStop() methods from the loaded SWF you can use its loaderInfo.loader property to reference the Loader object that loaded it.
    It could be someting like this:
    this.closeButton.addEventListener(MouseEvent.CLICK, this.handleClose);
    protected function handleClose(event:MoueEvent):void {
         this.loaderInfo.loader.unloadAndStop();
    You can pass a Boolean parameter to unloadAndStop() to indicate if Flash's garbage collector should be run ont the unloaded SWF in order to free up memory. Considering the size of your SWFs, this could be a good option. The downside is that there is a performance penalty and in my professional experience, CPU is still a resource that is more scarce than memory, so use with care.
    Hope this helps.
    Abraço,
    Rui

  • Linking other movie clips within one flash file

    hey,
    i'm making a flash tutorial for my company. I'm making each
    section into a movie clip. so i'm wondering how to link from one
    movie clip to another.
    ok thanks

    It's not confusing, there's just not enough information about
    what you have designed already to be able to tell you what you can
    do.
    How will the movies be arranged in the Flash timeline?
    If the movies are all going to be within the same Flash file,
    then you will need to have buttons as the links you mention. You
    can create your own so that they appear as text if that's what you
    want.

  • Play multiple movie clips - with sound

    Hello Forum members,
    I am a total new comer in terms of flash and action script,
    self-educated and Adobe forum and internet educated. I can now
    click a button and stop and start a movie clip, use attachMovie,
    and even mute sound in a movie clip (not video). I am currently
    using Flash 8, and waiting for CS3 (downloaded a trial, and like it
    better than Flash 8).
    Enough history - now to my question - I have an application
    that had 3 scenes. I read in some Adobe article
    "Flash Best Practices" that it was not a good idea to use
    scenes in an application. I converted my Scene 2 and Scene 3 into
    movie clips.
    I figured I could either put each movie clip on a separate
    layer in my timeline (mc_scene2, mc_scene3)
    and play them, one after the other (did not quite work, more
    later). Or...
    copy the timelines from the scenes, and add those frames to
    my Scene 1, making a application with both scenes staggered one
    after the other in the main timeline. Or...
    Keep Scene 1 and at the end of scene 1,
    attacheMovie("mc_scene2", etc) and when scene 2 was done play and
    or attach the final movie clip (mc_scene3).
    I could not figure out how to tell when mc_scene2 was done
    using the attacheMovie method, so I could then attach mc_scene3,
    etc.
    How would I be able to tell when one attached or loaded movie
    clip is finished, and then start the next one?
    Or what is the suggested way to use actionscript to load a
    movie, play it, and when the clip is done, load and play the next,
    etc.
    Thanks for a good forum,
    eholz1

    Hello Again - I guess there is much that I do not understand.
    I followed the tip above - or so I thought.
    I have "buttons" on my movie clips that play the clip when
    clicked.
    I have placed stop actions in frame 1 of each movie clip.
    I tried placing mc_scene2 and mc_scene3 on their own layer
    in the timeline,
    and put the code above in my actions layer (Scene 1).
    it seems that nothing really works - the _visible property
    seems not to work,
    etc - I must be doing something wrong. What layer should the
    two mc's be
    placed?
    Thanks for the info
    Eholz1

  • Playing Movie clip backward using buttons?

    Im trying to create a series of images that scroll acoss the page left and right using arrows at either side of the stage. The arrows use mouse over events to play a movie clip of the images foward and backward.
    There are a few issues I am having. I have a mouse over and mouse out events in place to start and stop the clip on to different buttons. However when playing the clip backward with my current script the mouse out doesnt do anything so the clip just keeps playing backward to the beggining. Once this has happened neither button then does anything.
    Another issue is once the clip has played foward once in total and I mouse over the same arrow button again it flicks back to the begginging of the clip.
    Here is my current scrpit:
    panel.stop();
    leftarrow_btn.addEventListener(MouseEvent.MOUSE_OVER, fl_MouseOverHandler_7);
    leftarrow_btn.addEventListener(MouseEvent.MOUSE_OUT, fl_MouseOutHandler_4);
    function fl_MouseOverHandler_7(event:MouseEvent):void
              panel.play();
    function fl_MouseOutHandler_4(event:MouseEvent):void
              panel.stop();
    rightarrow_btn.addEventListener(MouseEvent.MOUSE_OVER, fl_MouseOverHandler_9);
    rightarrow_btn.addEventListener(MouseEvent.MOUSE_OUT, fl_MouseOutHandler_7);
    function fl_MouseOverHandler_9(event:MouseEvent):void
       panel.addEventListener(Event.ENTER_FRAME, everyFrame);
    function everyFrame(event:Event):void
              panel.prevFrame();
    function fl_MouseOutHandler_7(event:MouseEvent):void
              panel.stop();
    Please Help!!
    Patrick

    use:
    panel.stop();
    leftarrow_btn.addEventListener(MouseEvent.MOUSE_OVER, fl_MouseOverHandler_7);
    leftarrow_btn.addEventListener(MouseEvent.MOUSE_OUT, fl_MouseOutHandler_4);
    function fl_MouseOverHandler_7(event:MouseEvent):void
              panel.play();
    function fl_MouseOutHandler_4(event:MouseEvent):void
              panel.stop();
    rightarrow_btn.addEventListener(MouseEvent.MOUSE_OVER, fl_MouseOverHandler_9);
    rightarrow_btn.addEventListener(MouseEvent.MOUSE_OUT, fl_MouseOutHandler_7);
    function fl_MouseOverHandler_9(event:MouseEvent):void
       panel.addEventListener(Event.ENTER_FRAME, everyFrame);
    function everyFrame(event:Event):void
              panel.prevFrame();
    function fl_MouseOutHandler_7(event:MouseEvent):void
    panel.removeEventListener(Event.ENTER_FRAME,everyFrame);

  • Multiple Preloaders for Multiple Movie Clips

    Designed in Flash 8, the site's timeline is all in Scene 1
    and is comprised of an introduction, which contains a short video,
    and 6 movie clip categories that the user selects to view. Since I
    want the intro to play as soon as possible, I'd like to limit the
    first preloader to just the video in the intro and not
    _root.getBytesTotal. Then, as the viewer watches this short video,
    the rest of Scene 1 movie clips will keep on loading. After the
    intro, the viewer will choose which of the 6 categories to view.
    These categories are identified with buttons which play the
    particular movie clip. Since I don't know the order of the
    categories they will select, I thought there should be a separate
    preloader for each category. Hopefully, after they view a category,
    the rest of the categories will have loaded and the loading time
    will be nil. The design for the preloader is comprised of a status
    bar and a percent loaded. Is there a way to limit the
    _root.GetBytesTotal to specific frames? I know I could break these
    categories up into separate SWF files but then I loose the
    advantage of one loading while another is being viewed.

    MovieClipLoader is a built in class of functions that will
    allows you to easily load Media (swfs/jpgs) from external sources.
    This will create a MCL object
    var mcl:MovieClipLoader = new MovieClipLoader
    We want the MCL object to receive events for any movie that
    is loaded into the main timeline
    mcl.addListener(this);
    Ok. now we have a movie clip loader that is able to recieve
    events. Since we want to show the progressive download and want to
    do something with that content after it loads, we need to declare
    two event handlers onLoadProgress and onLoadInit. onLoadProgress is
    pretty straight forward. onLoadInit executes it's action as soon
    all of the AS on frame 1 of its time has finished loading. In this
    case, we want two different things to happen. 1st, load the first
    clip and show it.... 2nd, load all remaining clips into the buffer.
    But first, lets declare those next...
    function onLoadProgress( target:MovieClip,
    bytesLoaded:Number, bytesTotal:Number):Void {
    // standard preloader code goes here
    function onLoadInit( target:MovieClip ):Void {
    // display the clip - this will be as easy as just calling
    our loadClip function for the mcl...more on that in a minute
    // If you want something special to happen, i.e. movie fades
    in or a mask is applied to it, you'd do that here.
    Now all we need to do is call the loadClip member function
    for the MovieClipLoader. Just replace the two parameters with the
    location of the swf and then the name of the instance you want it
    to load into
    mcl.loadClip( "myswf.swf", targetMovieClip );
    The other movie clips are now a breeze as well. For each
    button, just add an on(release) or onRelease = function (depending
    on your situation) to just call that mcl.loadClip() line from up
    above. Just change the movie you want loaded.
    Let me know if you need more help...

  • Multiple Movie clips and rollovers

    Hi, I need some help. I am putting together a flash file with
    3 movieclips. I have three movie clips I made - one for each of the
    3 big circles. When they roll over the other circles are supposed
    to disappear under the circle that they have their mouse on. I
    placed all 3 movie clips on the first scene, but when they roll
    over one of the circles the other circle movie clips stay there
    while the other one runs on the mouse over. I need the other ones
    to disappear. You can view what I have so far:
    http://www.feeco.com/Portals/0/encap.swf.
    If you need to see my fla file I can email it to you. Thanks!
    Stephanie

    use:
    stop();
    yourplaybutton.addEventListener(MouseEvent.CLICK,playF);   // replace yourplaybutton with the name of your play button.
    function playF(e:MouseEvent):void{
    play();
    /* Click to Go to Frame and Play
    Clicking on the specified symbol instance moves the playhead to the specified frame in the timeline and continues playback from that frame.
    Can be used on the main timeline or on movie clip timelines.
    Instructions:
    1. Replace the number 5 in the code below with the frame number you would like the playhead to move to when the symbol instance is clicked.
    button_19.addEventListener(MouseEvent.CLICK, fl_ClickToGoToAndPlayFromFrame_15);
    function fl_ClickToGoToAndPlayFromFrame_15(event:MouseEvent):void
        gotoAndPlay(2);
    /* Click to Go to Next Frame and Stop
    Clicking on the specified symbol instance moves the playhead to the next frame and stops the movie.
    button_20.addEventListener(MouseEvent.CLICK, fl_ClickToGoToNextFrame_6);
    function fl_ClickToGoToNextFrame_6(event:MouseEvent):void
        nextFrame();
    I also have added a keyframe to the end of my actions to stop(); this does not appear here with this code but on a separte screen but under the same actions folder the stop works just as I want to the last movie clip stops at the end
    Just can not figure out how to get the play to not start over from begining but to continue.

  • Playing multiple movie clips one after other on main timeline

    Excuse the probably simple question but I'm just starting off with Flash.
    I have imported a few video trailers directly into flash and saved them as movie clips.
    I want to be able to insert these movie clips onto the main timeline and play them one after the other, repeating once they have all played.
    On the main timeline I have set a layer for each clip and a keyframe where the clip is inserted for each layer.
    When I go to play the flash file, it is showing the first frame from each movie file and then moving to the first frame of the next movie file.
    What do I need to do to make flash play the entire movie file in that specific frame before moving to the next frame where the next movie file is and playing all that movie?
    Sorry for what is probably a simple thing to ask.
    thanks

    Create an actions layer on the main timeline and place stop(); commands on that layer in each frame where a movieclip resides.
    Within in each movieclip, at the end (last frame) you want to tell the main timeline to play(); so that it moves to the next frame (where it will stop because of the stop() commands you add).
    So at the end of each movieclip you will put either:
    for AS2:  _parent.nextFrame();
    for AS3: MovieClip(parent).nextFrame();
    For the last movieclip in the lineup you will replace nextFrame() with gotoAndStop(1);

Maybe you are looking for

  • How can i change the default Portal page

    When i access Portal (3.0.9) with my browser it leads me to the well known 'Welcome to Oracle Portal' page (which was installed during Portal configuration). From there i can continue to the login screen, log in and start working. Now, i would like t

  • Best way to go about having two people use the same form?

    Hi guys, Relativly new to livecycle and I need some help. I've been asked to make a form that 2 different people will have access too, what I need to do is as followed: Person 1 Only has access to the first 5 pages and is able to fill out the form Pe

  • As opening an xml file in excel?

    I can not open a xml file in excel, and I get a message that is not a valid spreadsheet, and if the same file can be opened from a normal machine, anyone know how?

  • Change step parameters in teststand edit mode

    Hello, I would like to know if it's possible to change the parameters in a step in edit mode of teststand. I have attached a sequence with one step, in this step I want to select DMMx. After the selection I want to teststand to fill in the parameters

  • IMessage and groups

    How do you create groups in iMessage? I understand the multi-chat thing, by choosing to send the message to multiple people it starts a private group chat. But, as iMessage seems to be the answer to BBM, in that application you can create large group