ActionScript 2.0 :: Animation And Function, Controlling _x And _y?

May 27, 2007

Have been struggeling for days now , I have in the _root a function called elastic and then on the stage a movieclip containing 9 smaller clips called t1 --> t9, these movieclips are each at a different y-axis and when this function is called they appear (slide) in, but now I want to slide in t1-->t4 at _x = 200 and t6-->t9 at _x=400, how can i do this within this function/code?

Code:
mc = ["t1", "t2", "t3", "t4", "t5", "t6", "t7", "t8", "t9"];
var i = 0;
while (i < mc.length)

[code]....

View 2 Replies


Similar Posts:


ActionScript 2.0 :: [CS4] Controlling And Reversing Animation On The BG

Jul 2, 2011

I'm trying to do the following:

1. Have a permanent animation on the background, running over and over again.

2. My buttons should control that animation. What I want to do is to reverse the animation (going backwards on the timelime) when the user press the button, no matter in which frame the animation is.

3. Finally, when the animation is "gone", the buttons must point to an specific label.

I'm not sure how to to the reverse motion thing and if that's possible usings AS2. BTW, I'm attaching the file (just 8Kb) to show the idea, the real animation in the background is gonna be a movie clip but it's heavy to upload and I don't believe anyone will download it.

View 0 Replies

ActionScript 3.0 :: Controlling The MyMovie Animation With The Icons?

May 6, 2011

I have this project with a movie clip I'll call MyMovie. The movie is a simple tween. I also have a set of button controllers that will start, pause and rewind the movie when clicking on the icons. These icons are movie clips with instance names of goButton, pauseButton, etc. I have no problem controlling the MyMovie animation with the icons until I convert the normal tween to action script. I follow the normal procedure of coping the Motion to Actionscript 3, removing the tween, and making the animation play with the actionscript. But I can't figure out how to make the buttons control MyMovie. It looks like the instance of MyMovie isn't behaving like a tweened movie.
 
[code]...

Works fine with the action is tweened but when the motion is converted to actionscript it has no effect. Making MyMovie a child seems to have no effect. It seems like once the AnimatorFactory scripts start running the array's you can't stop them. I must be missing something simple.

View 8 Replies

ActionScript 2.0 :: Controlling Carousel Animation Movement?

May 26, 2007

[URL]i'm working with some carousel movement and am trying to figure out how to add a level of interactivity beyond simply reacting to the _xmouse position.when pressing prev or next i want to go into a mode where the objects cycle through positions on the ellipse.i was thinking the fuse kit would be a good solution which is what i tried here:[URL]

View 9 Replies

ActionScript 2.0 :: XML Controlling And Displaying Animation Properly

Jun 26, 2004

I'm having some problems getting the nodes to display the animation properly, each textField should be doing the animation effect. I'm not to savvy with xml, so I'm not sure If I have my xml structured properly or not. [URL].

View 14 Replies

ActionScript 2.0 :: Controlling Character Animation In MovieClip

Jul 7, 2002

I am trying to make a movie in flash, and each character is its own movie clip symbol. I also have a variable for each character, to control the current animation running. I have one character in the movie, for now, and that movie clip symbol is called mann. It is just a simple draw, I am just testing this method out. Now, the first frame of the movie, has this action:
--
mann1_anim = 1;
--

That is the first time I use that variable, so then it will be created, right? anyway, then, the first frame of the main movie clip symbol has this action:
--
mann.stop();
while (mann1_anim == 1) { }
mann.gotoAndPlay(mann1_anim);
--

On that first frame, my man character only stands, so this action should do so that while the mann1_anim variable is 1, the man should just stand there, right?
Then, the 9th frame of the MOVIE, has this action:
--
mann1_anim = 2;
--

Then something should happened in the action of the first frame of the main movie clip symbol, because mann1_anim is no longer 1. Then the mann movie clip should start and play at frame 2, right? From frame 9 of the MOVIE to frame 22, I have created a motion tween for the main symbol. from right of the screen to the left. Then, in the 2nd frame of the main MovieClip to the 3th frame, is the "walk to the left" animation.

At the 3rd frame of the MovieClip, I have this action:
--
while (mann1_anim == 2) {
mann.gotoAndPlay(2);
}
mann.gotoandplay(mann1_anim);
--

This should loop the walk to the left animation to frame 22 of the movie, cause in frame 22 of the movie, when the tween animation stops, is this action:
--
mann1_anim = 1;
--

So then, when the tween animation stops, the mann symbol should return to the stand animation (frame 1). Well, that was a lot of explenation, and here is the problem. When I test the movie, the main runs its complete animation all the time! I have uploaded my work file(fla) here [URL].

View 3 Replies

ActionScript 3.0 :: Controlling Flash Presentation With Voice Over And Animation

Mar 5, 2009

my final project has a prev, next,stop, play, pause buttons and all of these affect the animations and voice overs. I suggested to make this on video and bring it into flash using a video player, but they want it to be into a single SWF to put on their website.

View 4 Replies

ActionScript 3.0 :: Controlling Animation Timing - Services Text Fade In

Oct 27, 2009

I'm new to OOP and AS3. I'm doing my company website. When a mouse event sends you to my services page I have 4 separate blocks of text that fade in. So far I have the first 2 texts blocks fading in at the same time. I want to stagger the timing so the second block of text starts its fade in a fraction of a second later, and so on with the remaining text blocks. Below is the code I've used to fade them in at the same time.

//services text fade in
var servicesText1Tween:Tween = new Tween(servicesText1, "y", Regular.easeOut, 148.9, 140.9, 1, true);
var servicesText1Fade:Tween = new Tween(servicesText1,"alpha",Regular.easeIn,0,1,2,t rue);
var servicesText2Tween:Tween = new Tween(servicesText2, "y", Regular.easeOut, 244.7, 236.7, 1, true);
var servicesText2Fade:Tween = new Tween(servicesText2,"alpha",Regular.easeIn,0,1,2,t rue);

View 6 Replies

ActionScript 2.0 :: [Flash8] Button - Show An Animation (created By A DuplicateMovieClip Function) With OnRollOver And Stops The Animation With OnRollOut

Jun 16, 2006

im trying to do is have a button that shows an animation (created by a duplicateMovieClip function) with onRollOver and stops the animation with onRollOut. It works when i roll over and it stops when i roll out, but then it continues in a loop up to the point where i rolled out (instead of cutting off completely as i would like). Id be extremely grateful if you could tell me where im going wrong.

View 2 Replies

ActionScript 3.0 :: Controlling Sound In Animation With Button Click - Error 2068

Apr 13, 2010

I seem to be getting this error message when I click on any of my button which are controlling the sound in my animations.
ArgumentError: Error #2068: Invalid sound. at flash.media::Sound/play() at Conventional1_fla::MainTimeline/pSound()

My sound is working and all the buttons are working as wel but this error message keeps popping up in the out frame.
stop()
import flash.events.MouseEvent;
import flash.display.Sprite;
import flash.media.SoundChannel;
var loadSnd: URLRequest = new URLRequest("");
var Snd:Sound = new Sound();
[Code] .....

View 2 Replies

ActionScript 3.0 :: Controlling A MC From Within A Function?

Oct 20, 2008

I dont really know if I can put this into words correcly so I'm including enough code(AS3) to show what I mean. I can see the results from my trace statement so I know my function is ok, but I'm seeing an error once I try to make my MC disappear. Need something inplace of "this.lowerThird_mc.visible = false;". Also, I should note that this code is in a MC that is on the stage where the other MC is.

function onCuePoint(infoObject:Object):void
{
if (infoObject.name == 'CuePoint5')
{

[Code]....

View 3 Replies

AS2 :: Flash - Controlling A Tween From Outside A Function

Oct 8, 2010

i've defined a Tween object within a function, and i want to control that tween from another function.

This is the basic way i have the code set up currently:

// Define the function with my tween:
function updateSlide()
{

[Code].....

Now i'm sure it's not working because it's not within the same function, but what would you do to make this work? Some sort of global variable or global function? I'm not used to working in AS2, or with programming in general

View 2 Replies

ActionScript 2.0 :: Controlling Movieclips With An IF Function?

Dec 6, 2003

I have created 3 movieclip buttons which have a total of 3 states eachUP, OVER and Pressed.What i am wanting to do is create a fuction that will change the state of an already pressed button back to its UP state. For exampleButton one is press and will stay in its state untill button 2 or 3 are presses then it will revert back to its up state.My way of tackling the problem was to target a frame in the movie clip that I wanted to change such as this:

on (rollOut) {
gotoAndPlay("ee");
}

[code].....

View 5 Replies

ActionScript 3.0 :: Controlling Movie Clips In A Function?

Sep 4, 2011

In the FLA file i have two animations of a turbine and a fan turning one is controlled via a button the other is a loop action that is not controlled.The button control is simple telling the movie clips to got frame 2 and play,and on the fan and turbine movie clips I have a goto and play frame 2 action the end of their time line. By doing this I get a rotation effect .

The problem is that when I call play function from the start button the movie clip does not play properly and just shudders between frames,rather than way it should run as a looped animation.

View 2 Replies

ActionScript 1/2 :: Controlling Button Function In A MovieClip Within A Movie?

Jan 14, 2011

I have a main timeline and on frame 6 I have  a game1_mc to be controlled from the main timeline, that has start drag on it.  The cursor changes to a hand but the movieClip won't drag. Could someone tell me how to get this to work? After trying many things, I currently have  on a frame on the main timeline:
 
game1_mc.purpleTri.onPress=function() {
this.startDrag();
}

[Code].....

View 3 Replies

ActionScript 2.0 :: Controlling Multiple Movie Clip Location Using Single Function?

Sep 20, 2007

I need to write a function which should fix the location of the movie clip on the stage.

public function setCoOrdinates(xpos:Number,ypos:Number,movieName:S tring):Void
{
eval(movieName)._x=xpos;
eval(movieName)._y=ypos;
}

My function is as above. While I use this function in flash I only see the last movieclip on the stage which was passed. Movieclips passed earlier seem to have disappeared from the screen.

setCoOrdinates(20,200,"bButton_mc");
setCoOrdinates(530,100,"fButton_mc");

I see only "fButton_mc" on the stage. Even though I set different xpos and yposs for the movie clip.

View 1 Replies

ActionScript 3.0 :: Call Function After The 'animation'?

Jul 12, 2010

basically i want this function to only be called after the 'animation'. when the hero dies hero.play() is called and this plays the death animation for the hero, i then called gameOver() which brings up a menu, but i only want the gameOver function to be called if the hero.play() animation is completed.

View 9 Replies

ActionScript 2.0 :: Reversing Animation Using A Function?

Mar 11, 2007

I have an mc which when rollOver plays an animation (works like a button), on rollOut I want the animation to play in reverse... I have seen it done before using a fucntion, but can't seem to get it to work... If I just reverse all the frames and get it to play that on rollOut it doesn't work properly...

View 14 Replies

Applying Loop Function On Last Frame Of Animation

Feb 23, 2010

I just got stuck with something while making an animation. I am making an animation where I want the last frames to keep repeating I want everything else to stop playing but to have specific animations repeat from a certain key-frame. Something like the animation on this site.

View 2 Replies

Flex :: Animation - Detect End Of Move Function

Feb 10, 2011

I need to create an animation and provide some results of the move function at the END of the animation. However, i am not able to control the output till the move function is completed

I tried the isPlaying- that doesn't seem to detect that the animation is completed... so continues to output resukts before the animation is complete

sample code I tried

private function mvbut():void{
var mv:Move= new Move;
mv.xFrom=Math.random()*300;

[Code]....

View 1 Replies

ActionScript 2.0 :: Preload Images Before Animation Function?

Apr 29, 2010

I have a .fla which loads in images and then animates them. My preloader works but the animation starts before the images are loaded. Can anyone figure out how to load images before the animation function starts?

View 3 Replies

ActionScript 2.0 :: Function To Stop And Start Animation?

May 18, 2010

I'm a little new to the AS thing so I need a little help. I need a simple function that will stop an animation on the main timeline for about 10 seconds then restart again.

View 2 Replies

ActionScript 2.0 :: Make A Button That Has An Animation As Well As A Function?

Jun 4, 2007

I'm trying to make a button that has an animation as well as a function. Currently i have an MC with an animation in it and on roll over/out it plays forward or in reverse. Now I've tried adding a function that when clicked, the animation goes straight to the end of the animation until clicked again.

Code:
onClipEvent (enterFrame) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {

[Code]....

Tried with variables, setting whether or not it was clicked, yes or no. But the enterFrame kept resetting it.

View 4 Replies

ActionScript 2.0 :: Mc.onRollOut - Shows An Animation OnRollOver And An Animation On RollOut But OnRelease The Animation Enlarge Itselfs

Jun 19, 2004

I have a movieclip that shows an animation onRollOver and an animation on RollOut but onRelease the animation enlarge itselfs but now when I'll roll out when the animation isn't open (so i didn't release) the animation plays the animation for the minimizing of the animation. Here's my code (I know its a bit amateuristic but I'm not a programmer )

[Code]....

View 4 Replies

Actionscript 3.0 :: Function Call When MovieClip Animation Finishes?

May 2, 2010

What I'd like to know is that if I could set up a eventlistener to wait until the MovieClip has reached the final frame, then fire a function.

Solution:
In the last frame of the MovieClip timeline:Code: Select all dispatchEvent(new Event("EventName"));
In the main timeline/class:Code: Select allMovieClip.addEventListener("EventName", FunctionName);

View 4 Replies

ActionScript 3.0 :: Controlling Animation Of Movie Clip Within Another Movie Clip

Apr 16, 2010

I press a button and have an object (a movie clip) move onto the stage - that works ok.When that movie clip gets to a certain spot, I want it to stop - that works ok.I want to be able to press the button again and have it leave the stage - that works ok.Then if I press the button again, it will come back on the stage again - that works ok.when it stops on the stage, I want a part of it to animate just once. I've been trying to do this by putting a second movie clip inside of the first, but it won't work.

View 4 Replies

ActionScript 1/2 :: Global Counter - Put An Animation In A Page And Call Or Use The Function?

Mar 17, 2009

I downloaded a free fla file open source for pageflip. It uses a global function which is this:

_global.mcnt = 0; //counter (used on a page where is an animation).

So now I want to put an animation in a page and i assume that i have to call or use this function. the problem is that i don't know how.

View 4 Replies

ActionScript 3.0 :: Use The Timer / Setinterval Function To Pause The Animation Between Tweens

May 11, 2009

I have been having trouble with the timer, knowing how to plug into the scripts/Functions the correct way. Below is the script (probably not written as efficently as it could be, but I'm trying) Anyway, the script is uses simple tweens for a movieclip. I would like to use the timer/setinterval function to pause the animation between tweens (Using the event listener after the tween stops to start the interval/pause) Is this the right concept or am I barking up the wrong tree.

[Code]...

View 3 Replies

ActionScript 3.0 :: Function Or Eventlistener To Check If An Animation Got To Its Final Layer?

Feb 22, 2011

Is there a funcion or eventlistener to check if an animation got to its final layer? Like, I have 3 movieclips: stance, precharge and charge. When I press a key, stance changes to precharge, but I need precharge to change to charge when its animation changes. I don't want precharge to loop and return to the beginning.

View 4 Replies

ActionScript 3.0 :: Make A Function That's Only Executable If The Right Frame Is Active In The Animation?

May 20, 2011

I want to make a function that's only executable if the right frame is active in the animation.In this case, the frame 1 (and make all the rest frames have it's cursor normal):

ActionScript Code:
Mouse.hide();
stage.addEventListener(MouseEvent.MOUSE_MOVE,follow);
function follow(evt:MouseEvent){

[code]....

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved