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




Movie Clip Control



I'm using flash mx
I have a scene with movie clips every other frame
the frames are labled 0040, 0045, 0050, 0055 etc.
I need to get my movie clips when they are finished playing to navigate back to the main timeline and go to the next frame label

I have tried to use, in movieclip 0040
onClipEvent (enterFrame) {
_root.gotoAndPlay ("0045");
}

and
_root.gotoAndPlay ("0045");

my movie clips are 0040 0045 0050 0055 etc.
when movie clip 0040 gets to the end, I want it to go to frame label 0045 in the main scene which is "main" and so on.

my problem is that I cant get the last frame action "right in the head".
does anyone have any ideas?

NineSpine...



FlashKit > Flash Help > Flash ActionScript
Posted on: 12-10-2002, 09:05 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Making A Draggable Movie Clip Control The Location Of Another Movie Clip
http://www.kineticz.net/jba/residental.jpg that is a picture of what i am trying to do. the white bar at the bottom is the draggable movie clip and the group of 3 pictures right above that is the movie clip that i am trying to control w/ the draggable clip. I am having trouble writing a script that will do this. any help you can give will be much appreciated.

How Can I Control A Movie Clip Which Was Loaded In To A Empty Movie Clip On Level 0
how can i control a movie clip which was loaded in to a empty movie clip on level 0 the name of the movie is 'imagemc.swf' and 'imagemc' for the empty movie clip on level 0. the movie doesn't have a movieclip name, how am i going to tell target the movie?

Control Movie Clip In Container From Button Inside Other Movie Clip
There are three movie clips involved in this question.

1. A main movie clip that has a target empty movie clip where an external swf loads.

2. A menu movie clip that is built from button symbols and has its own timeline.

3. The external movie.

When a user clicks on the menu, the external swf loads into the empty movie clip target.  This part works fine. Here's the code:
on (release) {    
    loadMovie ("Lesson1.swf", "_root.container");
}

I want to use one external swf for all lesson, versus 20 external swfs. The problem I'm having is controling at what frame the external swf loads.  I've tried adding --gotoAndStop (15) -- for example. I've also tried adding, gotoAndStop "_root.container" (15), but that doesn't work either. The gotoAndStop action ends up controlling the menu movie clip timeline instead of the movie loaded into the container. I figure this is because the menu mc has "embedded" buttons and it's own timeline.

Any  help you can offer will be much appreciated.

Thanks
Sheila



Using A Button In A Movie Clip To Control The Movie(and Not Movie Clip) Timeline
Ok i have a button placed in a movie clip. I want this button, when released, to go in another scene, frame one, on the movie(scene) timeline and not on the movie clip timeline.

So i tried: gotoAndPlay("mission", 1); (mission is the name of my scene)

But it goes to the frame 1 of my movie clip, It would be great if someone could tell me how i can control the movie timeline while my button is in a movie clip

thaks
Vakarm

Control A Movie Clip From A Drag N Drop Movie Clip
I need a script that allows the user to control the timeline of a MC from a drag-able MC.

Basically I want a MC that drags is constrained to the x position with a limited movement of say 100 Pixels, as the drag MC is moved along it controls the play position of a tween in a different MC.
So when you push the Drag MC back and forth it moves the second MC play position back and forth.

a great example of this is at http://fable.lionhead.com/fable.html
on the pop up book parts

Movie Clip Inside Movie Clip - Control From Timeline
hello all.

i have a movieclip (instance name: mov1) with a movieclip (instance name: mov2) inside of it.

mov1 is on my main timeline. I want to control mov2 from the main timeline. how can i do it?

i am trying what i thought would work which is
_root.mov1.mov2.stop();

How Do I Control A Movie Clip Thats On Stage From A Nested Movie Clip
I have been lookin for a solution for this for a while now. How do I access a movie clip thats on the stage from a nested movie clip? root doesnt work like it used to with AS2.0, is there a way? Any help would be highly appreciated

HELP - Converting A Clip To Control A Movie Clip Raher Than Getting A Url - HELP
I've downloaded a movie from the FLASHKIT open source which scrolls to a link when the user types what they are looking for which is great!- see details below

+ + + + + + the clip im trying to convert + + + + + +

Search Window

http://www.flashkit.com/movies/Utili...27/index.shtml

2000-05-03 8.91

Search window with complete funcionality; resizable window with resizable scrollbar , arrow and enter keys functionality implemented, word find. Open source modified from Active Search by Degrees. By Nenad Markovic

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
NOTE- IM USING flash 5 so its automatically updating the scripting when i open the fla file
+ + + + + + + + + + + + + + + + + + + + + + + + + + +




But i want the clip to give a Teltarget and goto comand in order to allow the user to navigate a flash movie rather than linking to external URLs

but i cant get the bastard thing to play ball- ive tried email the original author if the script but their eamil address in no longer valid

please help im on deadline
ross

ross@sevencreative.co.uk



NOTES



HERE IS THE SCIPT I THINK I SHOULD BE CHANGING


on (press) {
n = substring(getProperty("", _name), 7, length(getProperty("", _name))-6);
pressTime = getTimer();
trace (pressTime);
if (Number(n)<>Number(/:selectedButton)) {
setProperty ("over", _visible, true);
setProperty ("../button" add /:selectedButton add "/over", _visible, false);
/:selectedButton = n;
/:selectButtonNew = n;
} else if (Number(pressTime-pressTimeOld)<200) {
// extract button number
n = substring(getProperty("", _name), 7, length(getProperty("", _name))-6);
location = eval("/:link" add n);
getURL ("http:/ /" add location, "_blank");
}
pressTimeOld = pressTime;
}
on (release, keyPress "`") {
setProperty ("../button" add n, _visible, true);
}
on (keyPress "`") {
k = 0;
while (Number(k)<Number((1300-CPUlag))) {
k = Number(k)+1;
}
setProperty ("../button" add n, _visible, true);
setProperty ("over", _visible, false);
}




AND THIS IS WHAT IM TRYING AND IT DOESN'T WORK



on (press) {
n = substring(getProperty("", _name), 7, length(getProperty("", _name))-6);
pressTime = getTimer();
trace (pressTime);
if (Number(n)<>Number(/:selectedButton)) {
setProperty ("over", _visible, true);
setProperty ("../button" add /:selectedButton add "/over", _visible, false);
/:selectedButton = n;
/:selectButtonNew = n;
} else if (Number(pressTime-pressTimeOld)<200) {
// extract button number
n = substring(getProperty("", _name), 7, length(getProperty("", _name))-6);
location = eval("/:link" add n);
tellTarget ("nav") {
gotoAndPlay ("http://" add location);
}
}
pressTimeOld = pressTime;
}
on (release, keyPress "`") {
setProperty ("../button" add n, _visible, true);
}
on (keyPress "`") {
k = 0;
while (Number(k)<Number((1300-CPUlag))) {
k = Number(k)+1;
}
setProperty ("../button" add n, _visible, true);
setProperty ("over", _visible, false);
}

Movie Clip Control Other Clip, Actionscript Help
How do I make a movie clip control another movie clip? In this case, when I click on the green box(Movie1), the blue box(Anim1) will move. I added "Stop()" to the first frame of Anim1. I think I got the actionscript right, any idea what's wrong?

Can A Button In A Movie Clip Control A Different Movie Clip?
I'm working on a web page with a draggable menu which is in its own movie clip. Can the buttons in this menu affect different movie clips or the main page?

Control The Play On The Main Timeline From Within A Loaded Movie (not A Movie Clip)?
Question... I have a movie (main movie) that loads another movie (movie 2) automatically. Movie 2 contains a button that loads yet another movie (movie3). Now I’m having trouble with this next part... When movie3 loads I want "main movie" to stop where it’s at in the timeline and stop all other loaded movies until the user clicks another button where upon movie 3 will go away and "main movie" will resume. Movie 2 is like the paper clip guy in Word and movie 3 is my help movie. Therefore, it can be accessed at any point during the main movie and I don’t want to use a goTo command to jump to a frame label or scene. Does anyone have any idea how to control the play on the main timeline from within a loaded movie (not a movie clip)?

Control The Main Movie From Withen A Movie Clip
I have this movie, it has a movie clip in it, in side the movie clip is a button. How could I use the button in side this movie clip to control the main sceme timeline?

please help.

Movie Clip Control
In my main scene i have a button and on rollover effect i want to to go to a certain frame in a movie clip.

I know this can be done as i did it a long time ago i just wish i can remember how

Thankz Rob

Movie Clip Control
I have this code for a Mc follow mouse and its working ok!

mouse_x = _xmouse;
setProperty (_root.follow, _x, mouse_x+((getProperty(_root.follow, _x)-mouse_x)/1.2));
mouse_y = _ymouse;
setProperty (_root.follow, _y, mouse_y+((getProperty(_root.follow, _y)-mouse_y)/1.2));

but i want that the movie clip "follow" do not follow the mouse, but do exactly the opposite movement of it!
Ex: If i move the mouse to left, it moves to rigth...
I will appreciate your help guys!
thank you...

Control Movie Clip
plz tell me how i can control head or frames of movie clip
from main movie through draging mouse.

Movie Clip Control Within Swf....
I have a movie clip within a movie clip.

Links.movie clip within mainmenu.movieclip

How do i call movie animation in mainmenu.movie clip with button within links.movieclip

i've labeled clips...

mainmenu - "mainmenu"
and animation-"animation"

and tried on(press){animation.gotoAndPlay(2)}

but it didn't work.

how do i start animation?

animation is beeing placed inside the mainmenu,together with the links from which i'm trying to control it.

Thanx!

Movie Clip Control
I'm having a problem with a movie clip inside a movie. The problem is that when you click on the movie button it animates but underneath of the next movie clip layered on top of it. Is there a way to make this move clip "come to the front" over top of any other movie clips when it is active.

If I am not explaining it well...you can go to http://www.havensplace.com
and click on the "links" button to see what I'm talking about. after the links.swf file comes up click on the "Travel" folder and you will see the animation and the "Friends" folder is on top of it.

I know that you can use levels when loading other swf files but can you use them inside a swf to control multiple movie clips???

Thanks in advance for any help you might offer.
Bob

Control Movie Clip?
How can I start and stop a Flash movie clip that has attached code that starts with onClipEvent (load), etc. I want to start and stop it externally - from a frame action. The usuual stuff (movieClip.stop ()), etc, doesn't seem to work.

Thanks.

Pete Giotta

Movie Clip Control
Hi there
I have a preloader scene (dont sigh yet!) the preloader is fine however i am trying to link the percentage loaded 'txtPercent' to the movie clip 'loadedboxbar' 1 - 100 frames. I.E 1% = frame 1, 5% = frame5. Im hoping someone here could shed a litle light on the problem for me.

Many thanks
Dave

Movie Clip Control
How can I make a button play the next frame of a movieclip on the main mc? What I mean is that I have a menu of buttons and each button on the main mc is going to play a certain frame for the clip when clicked. Thanks for the help.

Using One Movie Clip To Control Another
I've got an instance of one movie clip (instance name: cockpitpanel) that I've grouped (several groups "deep") with another clip instance and button.

I've put this code into the event handler for the button:
on (press) {
_parent.gotoAndPlay("audio");
}

"audio" is a label in the cockpitpanel instance. Sound is supposed to start playing then.

It does not. Any ideas?

Movie Clip Control
i have a left to right scrolling menu.
how do i stop it on mouse over & then animate it again on mouse out

hope someone can help--
ps got flash mx

Movie Clip Control
I have several movie clips that I want to play randomly during the main movie. Using tell target or with on the main timeline does not make the movie clips play. I can set them up to play when a button is pressed not from a frame action. Any help would be appreciated.

Thanks

Movie Clip Control
Hey, was just wondering if this was possible...

It is in no way actionscript but you get the idea...


Code:
on(release){
if
_root.MC_MOVIE is @ frame 5
then
_root.MC_MOVIE.gotoandplay("fade out")
else
do nothing
}
What is the syntax if this is possible, maybe I have to use 'current frame'?

Robb

Movie Clip Control
on (press) {
control.nextFrameAndStop();
}


control is a movie clip, does that make sense? im such a newb

Movie Clip Control
I have a portfolio site with several buttons. when clicked they will tell a corresponding movie clip to play revealing that area of my portfolio. all the clips are on the stage and instance names are entered, frame one of each clip is blank and the clips are all stopped at frame 1. when clicking on a button, is there a way I can tell ALL OTHER clips that contain portfolio area to go to frame 1 and stop in one line of script rather than individually?

Thanks, Jeff

Movie Clip Control
hey

i would like to have an animation on loading of a movie clip, when a menu button is clicked. then once the user press's another menu button, play an exit animation before loading the next movie.

so how can i script a button to tell a movieclip to finish playing before loading the next movie the user wants? bearing in mind it could be any one of 5 movies currently on screen or being loaded.

cheers..

Control One Movie Clip By Another?
Hi,

I have a website with a a table divided into 3 parts,
a header cell with the "Topnav" movie,
a leftnav cell with the "Leftnav" movie,
and a main content cell.

view here :

http://www.innovents.org/oss

The header cell contains a flash movie with buttons for sections of the website.

The leftnav cell contains subsections for each of the main section of the website,
Ie: In the "Topenav" movie there is a "Media" button, when that is clicked, I need the leftnav movie to advance to a frame which will display 3 more buttons, Photos, Audio and Video.

I have found a tutorial that mentions something about how to do this, but the code doesnt work,

http://www.flashkit.com/tutorials/Ac...-966/index.php

Does anyone have any ideas how i can use the Topnav movie to control the Leftnav movie?

Thanks

Ollie Griffiths

Movie Clip Control (take Two)
My appologies for the confusion on my last post. Rather than force feeding anyone a layered & nested mess, I took my culprit movie clip out of the FLA and dropped it into it's own fresh one - much easier to understand.

The problem is:
in order to have an 'over-state' animation play fully (instead of dying once 'mouseOut' occurs) I placed the following code on a movie clip (rather than a button):
on (press) {
this.gotoAndPlay("d10");
}
on (rollOver) {
this.play();
}
the problem lies in that 'on press' (or 'on relese') the playhead isn't advancing (I have a series of named frames d1 thru d12)

here's the stripped down FLA...

Movie Clip Control
I am building a site where my main window is a sphere in the center of the screen. My buttons rotate to a certain point (the bottom of the sphere) when you click on them. Obviously the button closest to the bottom would not have to travel as far as the button that is farthest from the bottom. So what I need is a script to apply to the button that will tell the timeline that has the rotation animation to play at a certain point and then stop at a certain point without putting stop actions on the timeline of the rotation animation. Essentially a gotoandplay(1)andstop(20) script. Also I am aware that this my be the stupidest question in the world. While working on this problem it seemed that it would be the simplest thing to do. What can I say? Im stupid

Movie Clip Control. Please Help.
Hello, I was am having trouble making a movie clip controll the root time line. I have created a movie clip that acts as a transition between scenes of my movie. At the end of the MC (transition) I need an action that will progress my movie to the next scene. If any one can help I would really appreciate it.

Thanks!

Movie Clip Control HELP
Hey everyone. I am brand spankin new to actionscript. Im working with 2.0 in flash mx 2004. I have a movie clip I have made that I want to play forwards and backwards depending on which one of 5 buttons you hit on the screen. the clip is 150 frames long and its broken into 5 stops. button 1 would be assigned to frame one, button 2 to frame 30, button 3 to frame 60 etc. I want the movie to play from whatever point on the timeline it is on, to whatever point on the timeline it is called to, forwards or backwards depending on which section of the timeline it is called to next. for example: if it is on frame one, and you hit button 5 i want it to play forwards to frame 150. then if you hit button 3, i want it to play backwards from frame 150 to frame 60. how do I do this? any help would be greatly appreciated thanks!

Movie Clip Control
With a button I want to



play a movieclip called BOX in the same scene

(box have X frames, in frame 1 = stop)

and...



change the color of b1 to X, b2 to Y,and b3 to Z

(BOX contains b1, b2, b3 movieclips)


I can make works 1° but not 2° and viceversa...

any ideas?

Movie Clip Control
I have a voice over (.wav) file in a movieclip that plays half way into scene one . That part works, it loads the clip and plays no problem but what script do I use to get back to the parent and pick up where it left off?

Movie Clip Control
i have created a movie clip animation and its a looping one, i then placed the mc into a frame on the main timeline now i want to control the playing interval of the mc randomly after few seconds or minutes, this could be done from the frame where ive place the mc

Movie Clip Control
Can someone please help me with a small issue.

I have a movie clip placed on frame 20 on my timeline. I would like the movie clip when finished playing to go back to frame 3. Do i need to double click the movie on the timeline and go to its last keyframe and insert a "go to" command there? I have tried many things but none are working and i am really frustrated.

The movie on frame 20 is a fade out of frame 2 and when the fade out movie is finished, i want it to automatically go to frame 3...

Your help would be most appreciated


Many Thanks




Simon

Movie Clip Control
Hello...

I have what I believe is a very simple question.

I have a main timeline containing a movie clip called "buttons". The "buttons" clip has several labeled frames for navigation purposes. Inside this movie clip, is another movie clip called "print". I have buttons inside the "print" clip that need to tell the "buttons" clip which frame to goto and play. What script would these buttons need in order to do this.

All the files are located here

Thanks a ton in advance!!!

Movie Clip Control
Okay I am trying to make my first game in flash. I have got a movie clip (Symbol 15) with an animation inside: A crocodile swims down to a clam with a pearl inside. The clam is another movie and the pearl is a button inside the clam movie clip. If the crocodile is at the pearl Symbol 15 stops. Now I want the movie clip Symbol 15 to keep on playing if the user clicks the pearl but I don’t know what to code if I want it to play a certain frame or go to a certain frame inside a movie clip if I click a button that’s inside another movie clip.

How To Control A Movie Clip
Hello everybody.

Ok...
I have this movie clip pasted on the first frame of the stage called "Internal_mc", and an external movie clip on a separate SWF file called "External_mc"

I want to tell the "Internal_mc" to star playing at frame 2 when the "External_mc" is completly loaded into the main stage.

How can I do that?

Anybody can help?

Thanks.
Hanso

Movie Clip Control Help
Ok I'm not really a newbie but I've gone a little while without using actionscript and my minds blank.

I've got a movieclip called "anim" on the second frame inside another movie clip called "ship". I need it so that on the last frame of "anim" it tells "ship" (the movie clip that it is inside) to go to and stop at the first frame. But I can't think how to do it >_<

I know it's simple but can't think how to do it, any help is really appreciated thanks
-Olly

[F8] Movie Clip Control
im trying to use a tell target that will control a movie clip. i want it to do one thing when a keyboard key is pressed and another when the key is released. this is the code im using but is not working. can anyone see what im doinf wrong?

on (keyDown "a") {
tellTarget ("movieclip") {
gotoAndPlay(2);
}
}
on (keyUp "a") {
tellTarget ("movieclip") {
gotoAndPlay(1);
}
}

[F8] Movie Clip Control Help Please
//I have a movie clip (about_mc) at frame ten on my _root timeline

//I dont want this to play until I navigate to frame 10 ("about") from my about_btn.

//I have an actions layer within about_mc with a stop() action on frame 1.

//and this is the code in frame 1 on the actions layer on the _root timeline to go to it.

about_btn.onRelease = function (){
_root.gotoAndStop("about");
};

What code do i need to add for about_mc to start playing only when i navigate to frame ten on the _root timeline?

Control Movie Clip From Within Another One?
Hi, everyone!

I have this movieclip that plays when he site loads, then stops at frame 5.
I want to start playing another movieclip (stopped at the beginning) after the first one stops.

Can anyone help me with this?

Movie Clip Control
I have my main timeline with a layer labelled "movies" which will have 12 keyframes, each of which has a separate movie clip in it (named billboard1, billboard2, and quote1, quote2, etc). I can't get the clips to play back to back - I simply wanted to loop these without putting them all in the main timeline back to back (with all the frames, about 100 each). I'm sure this is easy... PLEASE HELP ME!

Movie Clip Control
Ok, from the main timeline i can control the movie clip, but if i tell the movie clip to play, but inside the movie clip to stop at a certain point...it dosent do it.
how do i make it stop?

Movie Clip Control
I have a a movie clip that contains buttons. When i click any of these buttons i want a seperate movie clip located inside located inside other movieclips to go to a certain frame.

My code is

on (release) {
_root.initial.secondary.progressbar.gotoAndPlay (2634);
}


This code works for a button that is located directly on my root time line but it doesn't work for a button that located inside a movieclip on my main time line.

What's Wrong with my code?

Movie Clip Control
im trying to control multiple functions within a single movieclip (my_mc) that has several other movieclips (mySubmovie_mc) inside it - which i also need to control - all of which from the main timeline. this is what i currently have in place:


Code:
my_mc.onEnterFrame = function() {
_alpha = 50;
gotoAndPlay("turnLeft");
mySubmovie_mc._alpha = 50;
mySubmovie_mc._rotation = 90;
};
i wish to place this type of script within a keyframe on an actions layer. setting global properties is also an option i am wanting to learn more about - to possibly simplify this operation even more.

thanks!

Control Movie Clip
I need a sugestion for this problem.

i have a function that controls a movieCLip. But the movieClip is not present until later in the time line.

example:


ActionScript Code:
function controlMovieClip():void{
   myMovie_MC.x = 100;
}

Its there a better to do it?

Movie Clip Control Help?
Movie Clip Control
Hi there, got a quick question that I know there's a really simple fix for.

On my stage, I have three buttons that each add a movie clip child to the stage.
On the frame, on that stage, I have the following code to show each child.


ActionScript Code:
stop();


/* Position of clips */
var clipX:Number = 0;
var clipY:Number = 0;

/* New instance of register clip */
var mcRegister:Register = new Register();
mcRegister.x = clipX;
mcRegister.y = clipY;

/* New instance of Auction Clip */
var mcAuction:Auction = new Auction();
mcAuction.x = clipX;
mcAuction.y = clipY;

/* New instance of Bids Clip */
var mcBids:Bids = new Bids();
mcBids.x = clipX;
mcBids.y = clipY;

/*button for registering*/
btn_register.addEventListener(
MouseEvent.MOUSE_UP,
function(evt:MouseEvent):void {
addChild(mcRegister);

/*button for close button*/
mcRegister.btn_register_close.addEventListener(
MouseEvent.MOUSE_UP,
function(evt:MouseEvent):void
{
removeChild(mcRegister);
}
);

/*|||||||||||||||| */
MovieClip(root).btn_play_auc.addEventListener(
MouseEvent.MOUSE_UP,
function(evt:MouseEvent):void
{
this.play();
//MovieClip(root).mc_auction_embed.gotoAndPlay(2);
//MovieClip(root).mc_auction.mc_auction_embed.play() ;
//gotoAndPlay(MovieClip(root).mc_auction.mc_auction_ embed.play);
}
);
/*|||||||||||||||| */

}
);

The child it adds is a movie clip called mc_auction, that has another movie clip in it called mc_auction_embed, which has a tutorial animation in it. mc_auction_embed has a button to "play" the video, namely stop it from being in a stop() state and make it play. I've been wrestling with this for about three days now.

How can I attach a play event to this button to make the movie clip play???

Please help!

Copyright © 2005-08 www.BigResource.com, All rights reserved