dcsimg
A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Animate the down frame of a button?

  1. #1
    Junior Member
    Join Date
    Apr 2000
    Posts
    1

    Question

    I am trying to put a movie animation in the 'down' frame of a button. When a user clicks on a button, I would like it to play a little animation of the button then go to another scene. If I put a movie / graphic animation in the down frame, it will only play the animation if I click and hold down the button. Is there anyway to get an entire animation to play in the down portion of a button? I would like it to play all frames of an animation then on the last frame I could apply an action to go to another scene or page.

    You might see an example of this at www.collective studios. I think the animation when clicked is actually in the down part of the button and not jumping to another scene that starts with the button animation.

  2. #2
    Junior Member
    Join Date
    Mar 2000
    Posts
    29

    Cool

    Help out a fellow houstonian i always say..

    Have you tought about making a movie of the animation first, and on the button itself give it a tell target comand to begin playing that movie.
    I'm sure theres other ways of doing this, this is just the one that sticks out in my mind.
    My ICQ number is 48984561
    contact me if you need any further help
    later

  3. #3
    Senior Member
    Join Date
    Apr 2000
    Location
    Northern Ireland
    Posts
    2,146

    Post

    You can't actually put an MC in the button down state the way you would in an over state, simply beacuse the down state is only in effect for a split second. That means you might get the first frame of the animation and that's it. What you should be looking at is putting an action on the button instance, telling it to play the MC when clicked. Then, in the MC (which is just plonked on the stage) in the last frame you put your go to command.

    It's a bit of a long winded leapfrog tactic, but as far as I can see it's just about the only way to accomplish this effect.

  4. #4
    Junior Member
    Join Date
    Mar 2000
    Posts
    29

    Thumbs up

    Ok maybe i did'nt explain this clearly enough,
    Make your MC animation, make the first frame a blank keyframe with a stop action.

    on the main scene Drag an instance of your button on to the stage in layer2.

    Place an instance of the MC animation in layer one of the main scene above the Button instance, "or were ever you prefer"

    Make sure you name the MC Instance, Lets use "Garbage" as the instance name.
    to name the MC just right click it to bring up the properties box.

    Now on your button instance give it this action

    On (Press)
    Begin Tell Target ("/Garbage")
    Go to and Play (2)
    End Tell Target
    End On

    That will just play your animation once cause it will go back to the first frame were theres a stop action.
    If you want it to go to another scene,
    Just add a "go to action" on the last frame of the movie clip.
    Hope I was a little clearer on that,

    later

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center