Thursday, December 24, 2009

What Actionscript 3.0 would I use for a frame action that controls play and stop buttons?

What frame actionscript would I use to control play and stop buttons for an animation? I do not need to know the object actions, just the frame actions that I would put into the actions layer. For the life of my I can't get it to work. My buttons are called: MC_play and MC_stop, and the animation that it is controlling is called ball. Thanks in advance for any help!What Actionscript 3.0 would I use for a frame action that controls play and stop buttons?
Try this code or contact me if you want a source file








Ragards





Anil


anilkumarnd@gmail.com


http://flash-workshop.blogspot.com/





********************************





MC_play. addEventListener (MouseEvent. CLICK, playHandler);





MC_stop. addEventListener (MouseEvent. CLICK, stopHandler);





function playHandler (IN_Event: MouseEvent): void {





ball. play();





}





function stopHandler (IN_Event: MouseEvent): void {





ball. stop();





}





********************************What Actionscript 3.0 would I use for a frame action that controls play and stop buttons?
OK, the script is...


on(release){ play(';framename';);} or on(release){ stop(';framename';);}

No comments:

Post a Comment