Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








Playing One Movie After Another


I know this question has been answered in several forms on this forum, but I haven't been able to find an answer that works in my case.

I have 6 movies that I want to load in to a swf and I want movie #2 to start playing when movie #1 is done, and so forth. I have tried this code, but it just replays the first movie again and again.


Code:
var tut01:tutorial01 = new tutorial01();
var target:DisplayObject;
var startTime:Number;
var duration:Number;

addChild(tut01);
tut01.play();

function clipDuration (duration:Number):void {
tut01.duration = duration;
target.addEventListener(Event.ENTER_FRAME, enterFrameListener);
}

function enterFrameListener (e:Event):void {
var elapsed:Number = getTimer()-startTime;
var percentDone:Number = elapsed/duration;
if (percentDone == 1) {
gotoAndPlay("tutorial02");
target.removeEventListener(Event.ENTER_FRAME, enterFrameListener);
}
}

I have created six frames in the swf that is loading these movies (one for each movie), that's what the 'tutorial02' is referring to.

Thanks for any help!




FlashKit > Flash Help > Actionscript 3.0
Posted on: 10-21-2008, 10:50 AM


View Complete Forum Thread with Replies

Sponsored Links:

Check If Movie Clip Finish Playing Before Playing Next
I'm trying to figure out how to create a conditional variable script to check to see if one of the 4 movies are finished before starting the next selected one.

I have 4 menus with 4 movie clips that have an opening and closing animation in them.
When clicking the one of the buttons I would like it to check and see if any of the movie clips are in the open position. Then have the movie that is in the open position play it's closing animation. Then play the selected category movie that the person clicked on.

I know it's all done with variables but just cant figure out how to put it together.

here is what i have so far.

menuStatus = 0;
trace(menuStatus);
but1.onPress = function() {
if (menuStatus == 0) {
menuwork.gotoAndPlay("start");
menuStatus = 1;
} else if (menuStatus == 2) {
resetMenus();

}
};
but2.onRelease = function() {
if (menuStatus == 0) {
menuwhoweare.gotoAndPlay("start");
menuStatus = 2;
}else if (menuStatus == 1){
resetMenus();
}
};
function resetMenus() {
if (menuStatus == 1) {
menuwork.gotoAndPlay("close");
menuStatus = 0;
} else if (menuStatus == 2) {
menuwhoweare.gotoAndPlay("close");
menuStatus = 0;
}
}

thanks for any help in advance

View Replies !    View Related
Playing A Specific Frame Of A Level1 Movie From Level 0 Movie
I want to play a level 1 movie from a level 0 movie, only I want to play a specific frame of the level 1 movie, not the whole movie. I don't know how to do this with the LoadMovie command. Can anyone help? Thanks

View Replies !    View Related
Playing External Quicktime Movie Files From With In A Flash Movie
I'm currently working on a Multimedia Showreel using Flash MX 2004 and I need to be able to play an external movie file from with in the flash movie. I don't want to embed the movie as it is 60MB+. Is there anyway to do it?

Cheers

View Replies !    View Related
Swapping Movie Clips With Variables And Just Playing A Friggin' Movie..
Ok i am trying to do 2 very simple things..

i just want to jump to frame 2 of this movie called solotab just when the movie first runs..

Then i want the clickable tabs to enlarge - move to the edge and replace each other and for this there are the variables current and currenttab to store the respective instances to be targetted.

I don't know why it doesn't work as the target path is correct and the variable is correct - the trace action shows this..

with your help i could become cleverer..the file is on this thread - http://www.kirupa.com/forum/showthread.php?t=217591

Si

View Replies !    View Related
Playing Movie With A Button Inside A Movie Clip
OK LETS START FROM THE VERY BEGINING HERE...

I HAVE A BUTTON THAT IS IN A MOVIE CLIP, WHEN I TELL IT TO GOTO AND PLAY THE FIRST SCENE FRAME 2, IT PLAYS THE ANIMATION IN THE MOVIE CLIP AND NOT THE SCENE. WHAT SCRIPT DO I USE TO TELL THE BUTTON TO PLAY THE MOTION TWEEN IN THE FIRST SCENE ON THE SECOND FRAME.

View Replies !    View Related
Playing A Movie Clip In A Different Frame Rate That The Movie Has HELP
Hello all, im trying to play a mc in a different frame rate than the movie (im using flash 5) is it possible?? any help appreciated !!!
Thanx in advanced.

View Replies !    View Related
Load The Main Movie While The Intro Movie Is Playing
HI
Can some one pls. help me.
I have a main movie that is 600kb in size and it take very long to load it, can i start loading the movie when the intro is being played., Also can we load the movie partially, (what i mean by that is if i can load a few frames first then some other frames)

I am usinf flash mx, and have alot of symbols, and other movies that are loaded into the scroll pane component,

thanks a lot

j

View Replies !    View Related
I Want To Have A Movie That Starts Playing When I Click On Another Movie/button..
I want to have a movie that starts playing when I click on another movie/button and pauses or stops when I hit it again.. very simple, but I need help

Thanks

View Replies !    View Related
Playing Ext. Movie Syncronized With Internal Movie Clip
HI there,

I want to loadMovie and I want to stop it till it loads all together; so I need preloader. Then there is another movie clip for 20 frames lets say, which is in loop, and I want this small one start with the external one (it will loop about ten times while other plays) and finish when it finishes. My preloader is not working. I made an interval and made an evaluation of getbytesloaded/...total, but movie starts anyway and it is very slow because it is also loading at the same time. I will be glad if you have any suggestions.

Thx.

View Replies !    View Related
Attachsound Sounds Not Playing When Movie Is Loaded Into Another Movie
Hi,

I have made a movie that contains actionscript-controlled sounds using attachsound aswell as regular event sounds attached to frames. I am loading this movie in another movie but there the attachsound sounds dont play, only the ones that are put on frames. Is there any way to fix this?

View Replies !    View Related
Music On Movie Fading Out When The Movie Finishes Playing...
I have an animation, I need to put some music in it, but I´d like the music to fade out (the volume turning down) when the movie finishes playing. How can I do this?

Also, if you can let me know how can make an mp3 file´s size more suitable for a quick load.

Thanks!!!

View Replies !    View Related
Scrollable Movie And How To Load Swfs While Another Movie Is Playing
Well im trying to make this and have no succes i suck when it comes to scripting i just know a a few scritps from flash 5 but mx is diffrent, anyways, can i achive this effect with the scroll pane component? what the hell is the scroll pane used for anyways? Well i saw a tut on flashkit but all it did was confuse me even more, now on to my other problem how can i have lest say my animation running and while that animation is running its loading my next animation and when its loadedit will just wait for a button to be clicked and then it will play?? i know how to load swfs on a button click, but i want it to load lets say from the first frame of my movie while the movie is playing, any help is apreciated thanks for all your help

Grim

View Replies !    View Related
Load Another Movie When Loaded Movie Stops Playing
Hello flashers

I have been given a bunch of swfs which I have no control over, nor can view the flas (dont ask its a long story!). I just have the swfs.

I am loading these swfs into my flash movie using loadMovie(...,...).

---

How can I access the children of the loaded swf?

i.e. the swf loaded also loads another swf (lets call this "x") itself. I need to find out how to access "x". I guess what I need help with is finding out the name of the variable in which movies are loaded in the movie I have loaded..

(hope that makes sense!)

I have been smashing my head on my desk all day so any help would be cool.

Cheers.

View Replies !    View Related
Preloading A Movie But Not Playing It While Another Movie Is Running
I need a few tips on how I make sure some flash movies are preloadet while the first movie is played, so they can be ready to be played when chosen without having to wait for them to load then.

Got any ideas to get me started in the right direction please?

View Replies !    View Related
Playing Movie From A Button Inside Of Movie
I appreciate any help! I made a movie it has four buttons. I am try to Link those button to play four other movies. I am not sure of the Actions I need to apply inside of the movies.Or the actions needed in the main movie. My main objctive is to make a flash site with four clickable pages. Please Help Thanx

View Replies !    View Related
Playing A Flash Movie Inside Another Movie
Hi All. I've created a small site out of flash, and the content I have made using Swish. I exported the Swish to an SWF file, then imported the SWF into a new symbol --> Movie, named "Content". This consisted of 20 individual frames. I then accepted it, and dragged the "Content" from the Library into the main piece of movie itself, but when I try to view the movie the imported SWF does not play. Does anybody know how to play a flash movie, inside another flash movie. Cheers,

Kind Regards,

Adam Prettyjohns

View Replies !    View Related
Slow Playing Movie When Using Load Movie
Hi....i'm using flash mx

I have a movie which loads on level 1. I noticed it plays slower than it does when i just open it directly. (just straight from the computer). It is designed to open on level 1. any ideas why it is lagging?

Cheers

Miffy

View Replies !    View Related
Unload Movie After Movie Stop Playing
Is there a way to unload a loaded swf in level 15 immediatly after the timeline ends playing in specific loaded swf ?? Also is there a way to trigger an action from _level 0 after the loaded movie has reached a certain frame with _currentFrame._level15 ??

Thanks.

View Replies !    View Related
Movie Clip, In Movie; Not Playing Sounds?
Does anyone know why when I have a movie that has a movie clip inside it or multiple levels of movies in movies? The sounds that are in the sub moves don't play? If I test just the scene the sounds play perfect, but on the main movie, no sound. My movies don't normally have so many levels but this one does and it's bugging the fuk outta me.

Any help would be appreciated :-) Won't help much but the movie is located at www.mHungry.com

Thanks, Dave Schlaegel

View Replies !    View Related
Pause Movie (open Movie After Done Playing)
Ok here is my deal. I want a button to

on(release) {
loadMovie("blah", "emptyclip")
}

that movie will be paused half way.....

then when another button is hit

on(release) {
unpause("blah");

then(after blah is completed )
loadmovie("secondblah")

Fill in the blanks to help..........dont know what to d or if this is even possible.

I have figured out a REALLY long way to o this but i think this will be quicker.

Thanks yall !!

View Replies !    View Related
Playing Mc's Within Movie
here another extreme newby question

i have my movie with 3 mc's in it,on the mainstage there is one layer with one mc in each frame from 1-3. when i view the movie why does it not play mc 1-3 one after eachother???

do i need to add an action to each mc on the main stage saying play mc 1 then mc 2 then mc 3?? (if so please let me know the exact script.) or how does this work??

thanks!!!

View Replies !    View Related
Playing Movie
I need to play a movie inside my main flash score and not sure how to do it.

- i have a symbol turned into a movie with numerous layers and what not.
- i just want to place that within the top movie and play as is. Right not when I create a keyframe, it passes right thru it without playing the movie. I've played w/ actions but nothing works. thanks

View Replies !    View Related
Help Playing A Swf In A Movie
I am trying to get a swf file to play in a frame of my movie instead of using a huge movie clip. I have no idea how to do this! please someone help me!

View Replies !    View Related
Movie Not Playing
Hi
I have made a movie based on one of the educational movies in the Flash Movies. The movie is playing in the Main Timeline, when Enter key is pressed or the Playhead is scrubbed. However, when I Control > Test Movie, it does not play. I am uploading the .fla file, could somebody please have a look at it. I would be grateful for any help. I would appreciate if the fault could be detected so that I can rectify it.
thanks.

View Replies !    View Related
Movie Playing
I have problems with playing my swf file on my site. It dont seem to play. It says its not loaded, and never does load. Anyhelp?

View Replies !    View Related
Playing Mp3 From Outside Movie
Hi all,
Here's my first newbie question. I want to play some mp3 files from a link in the movie, but I want to link with a button to the file outside the movie to keep the file size smaller. I would like it to load in a player. (Media player, winamp etc.) If I use the action "go to url" and insert the url of the mp3 I get page can't be displayed. I'm thinking I need a java script? I've done this before by going to a html page with the "go to url" action and then linking to the mp3 from that page, but this time I'd like to link from the movie straight to the mp3. Can anyone help?
Thanks in advance,
Desertshark

View Replies !    View Related
Playing Mp3 From Outside Movie
Hi all,
Here's my first newbie question. I want to play some mp3 files from a link in the movie, but I want to link with a button to the file outside the movie to keep the file size smaller. I would like it to load in a player. (Media player, winamp etc.) If I use the action "go to url" and insert the url of the mp3 I get page can't be displayed. I'm thinking I need a java script? I've done this before by going to a html page with the "go to url" action and then linking to the mp3 from that page, but this time I'd like to link from the movie straight to the mp3. Can anyone help?
Thanks in advance,
Desertshark

View Replies !    View Related
Movie Not Playing?
Hi,
I am new tyo Flash. My problem is this. I have created a simple animation that plays fine in the program, but when I 'Test Movie" it doesn't play. The animation is simply text that fades in and out. I can scrub through it and see it fade in and out and use the controller to play it, so why doesn't it play when I "test move" or export it to a movie?

View Replies !    View Related
Keep Movie Playing
Hi, I need to correct way to say this in actionscript!

If playback head is not on frame 1,
don't do "onRollOver = function() {
gotoAndPlay(2);
}

my actionscript is not very good so I hope I'm making myself clear. I just don't want the movieclip to start over again every time the mouse moves near the clip.
thanks!

View Replies !    View Related
[F8] Movie Not Playing From The Off
hiya all - just made a simple little intro page in flash with a pre-loader. once the preloader has finished the movie is paused and the user has to right click and play. any ideas why it does not play right away as i would like it to?

here's the link:
http://www.mmgraphixstudio.co.uk/dcn/intro.htm

i'm worried people will be confused and turned off by the site.

all help will be appriciated.

thanks

View Replies !    View Related
Get The Url Of The Currently Playing Movie
Hi,

I'm trying to get the URL of the currently playing movie.

This was really easy in AS2 (trace(_url)) but I can't find the AS3 equivalent.

Any ideas?

View Replies !    View Related
Help (movie Not Playing)
Could I email my movie to one of you and could you tell me what in the world I am doing wrong because it is NOT playing!.....With my very limited expertise in Flash, I have totally run out of ideas of what I could be doing wrong........ any candidates?

View Replies !    View Related
Movie Not Playing....
Hi,

If anybody can help me figure this out, i would really appreciated. It's probably something stupid but I can't get it to work.

This is what I have..

- Main Movie
- Secondary Movie (in the library panel)

I have my main movie on frame 1 and a button as a control. The button when pressed will go to frame 2. But once I press the button it goes to frame 2 and does not play the movie. I want it to go to frame 2 play the movie and then stop. Then i want it to go to frame 3 and play the rest of the movie...

how do i this ???

Thank you and I appreciate the help...

View Replies !    View Related
Movie Not Playing Twice
Does anyone know why my movie will not play forward the second time? If I play it forward then reverse it, it will not play forward again.

Here is the code for the button that plays the movie.

on(release){
if(_root._currentframe ==1)
_root.play()
else{
_root.stop();
_root.onEnterFrame = function(){
if(this._currentframe!=1){
this.gotoAndStop(this._currentframe-1);
this._currentframe--;
}
else
delete this.onEnterFrame;
}
}
}

and here is the code for the button that plays it backwards.

on(press){
_root.stop();
_root.onEnterFrame = function(){
if(this._currentframe!=0){
this.gotoAndStop(this._currentframe-1);
this._currentframe--;
}
else
delete this.onEnterFrame;
}
}

View Replies !    View Related
Playing A Movie
This navigation menu, when the cursor rolls over the button, a cross fades and when it rolls out (at frame 40) the cross' alpha value returns to 100%. This works!! Did it by when collection_btn.rollout it plays frame 40. This action is placed in frame 30 where its the end of the cross fade motion tween

However when i want to click on the button (onRelease) it doesn't go to frame 60 where the button will move.

At frame 1:

stop();

collection_btn.onRollOver = function () {
gotoAndPlay (15);
};

collection_btn.onRelease = function () {
gotoAndPlay (60);
};

THX

View Replies !    View Related
Movie Not Playing
A client sent me a link to a page on the web where he has a video -

http://www.reservationkey.com/projects/buzza/default_new.asp

He wrote me - "We would like to have a flash video automatically play on the home page. We had a local guy set it up and when I uploaded the files to the server it did not work. Here is the site on the local web developers site. Any ideas of why it doesn't work? Do you have any alternatives?"

I took the source code from his page and created a page on my server -

http://www.santarosadentist.com/flash.html

I believe I have all the necessary files on the server and I modified the object code, but I only get a "buffering" message. Can someone shed some light?


Code:


<object type="application/x-shockwave-flash" width="299" height="225" wmode="transparent" data="flvplayer.swf?file=Buzza_Testimonial_short.flv&autoStart=true">
<param name="movie" value="flvplayer.swf?file=Buzza_Testimonial_short.flv&autoStart=true" />
<param name="wmode" value="transparent" />
</object>

View Replies !    View Related
Playing A Movie After Another Movie Has Played.
In my movie I have a horazontally scrolling background that moves spefic distance (such as x = -648) when you click a button. Also upon click that button another movie clip rolls in over top of that back ground clip and back out if that button or another button is clicked using variables.

My problem is the animations play at the exact same time. What I would like to happen upon open opening the sequence is have the back ground animation scroll to it's desired posistion and stop... (or even better almost stop but not quite) and then the movie clip above should come in.
Upon exist I'd like the top movie clip to slide back out and then the background scroll to it's next posistion stop and pop up the next menu over that and so forth.
I'm new to action scripting and very lost. If some one could help I'd much appreactiate it.

The Code for the scrolling background movie is:

onClipEvent (enterFrame) {
_x += (endX-_x)/spd;
_y += (endY-_y)/spd;
_root.home.onRelease = function() {
endX = 0;
endY = 0;
};
_root.tour.onRelease = function() {
endX = -684;
endY = 0;
};
_root.gallery.onRelease = function() {
endX = -1368;
endY = 0;
};
_root.mission.onRelease = function() {
endX = -2052;
endY = 0;
};
}

The code for the first frame of the movie that slides in over it:

if (Number(_root.test) == 1) {
gotoAndPlay("goclip1");
}

View Replies !    View Related
[F8] Playing A Movie...inside A Movie
hey guys, so basically i am trying to play a "movie clip symbol" in my time line, but it wont let me. Because i made a symbol of my character, and inside of it are the eyes, eyebrows, mouth, etc. and thats where i made all my animation, inside the character. so when i go to Scene one, there will only be one layer. but the problem is that the only way to view it is if i go into preview mode, and that isn't good for me because to edit each frame i have to scrub back and forth, to see whether or not it works. How can i play the video in the time line, or is there an alternative?

View Replies !    View Related
Creating And Playing Movie In Movie
Hi,

I'm trying to make a sort of slide show player, but with pop up images and animations (tweens). What I have so far is an xml file that has image file names and information tags for the image. Images get loaded and the play/rewind etc buttons control the playback.

I have been able to pause the timing queues (ei when the pause button is pressed) for animations but my last challenge is to have a slider so that that player acts just like any standard flash movie player. This would become very complicated since scrolling forward in the movie would require numerous calculations and lots of overhead so as to calculate where you are in the playback of the slide show/movie.

I was wondering if it would be possible to program a slide show and export it within the same movie and use the control buttons to have it run just like any flash player that loads an swf.

..I hope this made sense and thanks for reading.

View Replies !    View Related
Random Movie Playing
I have 4 movies the will be at the beganning of a flash app. I want them to play at random when play is clicked. Is there any way to do that?

View Replies !    View Related
Playing 2 Movie Clips Before Going To Swf
I have 4 swf's and I want 2 transitional movie clips (8 altogether) between each swf. How do I script my button so that it will play 2 movie clips before going to another swf? Thanks!

View Replies !    View Related
Playing A Movie From One Frame To Another...
This should be easy? I am using the telltarget command to controll a movie, but I want to tell it to play from frame 20 to frame 21, without using a Stop command inside the movie timeline. Is there a way I can use Gotoandplay (20 -30) or GotoandPlay (20+5frames)??

View Replies !    View Related
My Movie Clips Are Not Playing
Hi everyone!

Im trying to get my actionscript to work here. I have all my instances named properly (and not using the names from the library) and such but still they dont play when needed.

//Instance MC Functions:

mov1 = plays on [rollOver]
mc1 = plays the menu on [onRelease]
cube1 = plays the button mc with an invisible button behind it.

//Here is the script:

on (rollOver, dragOver) {
_root.mov1.play();
_root.cube1._alpha = 100;
}
on (rollOut, dragOut) {
_root.cube1._alpha = 30;
}
on (release) {
_root.mc1.play();
}

//End of Script

View Replies !    View Related
Can I Preload A Movie That's Not Playing?
I have an intro on my website and would like to preload another movie while the intro is still playing, so that the main movie is done when the user clicks on the 'Continue' button.

Is this possible somehow?

Joepy

View Replies !    View Related
Playing The End Of A Movie Before Loading Another
Hopefully someone can help...I have a feeling this is easier than i think, but i have a site im building that has 5 or 6 different sections, with each section having an 'ending' anim fadeout which i would like to have play before i go to the button choice that was selected. If you have ANY hints, PLEASE RESPOND. Im getting a headache trying to figure it out!

View Replies !    View Related
Playing A Movie In Reverse?
I want my movie to play in reverse for exactly 5 frames every time someone clicks on a button. How would I do this? thanks.

View Replies !    View Related
Playing A Movie Clip...
how do i make my movie clip play? i'm doing my personal flash site. what i wanna happen is: "whenever a menu button is pressed, an item(movie clip) should play". to get my idea, pls open this site...http://arsendomain.tripod.com
get it!? pls help meeehhh!!!

thank you!

View Replies !    View Related
Playing A Movie Clip...
how do i make my movie clip play? i'm doing my personal flash site. what i wanna happen is: "whenever a menu button is pressed, an item(movie clip) should play". to get my idea, pls open this site...http://arsendomain.tripod.com
get it!? pls help meeehhh!!!

thank you!

View Replies !    View Related
Playing A Movie Backwards
I have a movie that I need to play forward or backward, depending on what button is pushed. The movie (rough draft) can be seen at http://www.bluewtech.com/KBT/home.htm . You will see why I have to go in 2 directios. Thanks for any help!

View Replies !    View Related
Playing A Flash Movie From A CD Rom
i have built a flash movie and want to use it on a CDrom. It runs fine from my machine but when I try it from others it doesn't work. I have supplied flashplayer 6 for the mac and pc, but it still doesnt work when those have been installed...any suggestions

thanks

View Replies !    View Related
Movie Clip Not Playing
Ok, here goes:

In my scene, all located in ONE frame. This frame has a STOP action, so this all takes place in one frame.

I have 3 movie clips.

One is in top right corner, is a news ticker that just loops constantly.

One is in left, and is just a scroller of images when down/up arrow is moused over.

Both those two are working fine.

Third is a ladder type list of 4 text images. Now, right click on that one to edit it, and each text image is a button. The object action of the first one is to this.gotoAndPlay(2). Frame 1 and Frame 15(of this movie clip) have STOP actions. 2-14 play the first text image moving in a straight line up, and stopping there.

Now, when I publish, and test it out, when I click on the first text image, the image jumps up to it's ending spot then right back to it's original, all in about half a second so you can barely see it. Almost as if it's playing superfast than stopping back at frame 1 of the movie clip.

Any help would be appreciated, or if you need more info please let me know. Thanks.

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved