Easy Button
- Create an ActionScript 3.0 project
- Right-click the first frame of the only layer and select "Actions"
- In the pop-up window, type "stop()," and close the window
- On the stage, type the word "Play," and convert to symbol
- Choose "Button"
- In the properties window, change the instance name to Play_Button
- Select Window > Actions to reopen the action window
- Add to your code:
Play_Button.addEventListener(MouseEvent.CLICK, play_animation);
function play_animation(event:MouseEvent):void
{
gotoAndPlay(2);
} - Create a new layer
- Create a simple motion tween animation
- Select Control > Test Movie > In Animate to test your interactive animation