3 Replies Latest reply on Jun 8, 2010 6:58 AM by Ned Murphy

    mouse-over action?


      Hi again, i have another totally newbie question here, sorry everyone, i am so useless!


      In one of my frames i would like to have a button that opens up a movie clip, but i would like it to do this on a mouse-over action instead of a click, i have tried using the onRollover action, but i can't get it to work, it's got to be a daft mistake i am making but i have spent ages trying to figure it out, and once again i am stumped.


      Any help from you wise people would make my day!

        • 1. Re: mouse-over action?



          Is this what you're looking for?




          function onOVER(e:Event)




          • 2. Re: mouse-over action?

            This is code that I use. The button and movie clip is placed on the stage in the desired location.


            // This imports the transitions to make resizing and viewing more pleasing to the user.

            import Scripts.caurina.transitions.*;


            // This makes the button and movie clip invisible.




            // This sets the movie clip size to 0 px high and wide so it does not interfere with the button.

            mc_01.scaleX=0, mc_01.scaleY=0;



            btn_01.addEventListener(MouseEvent.ROLL_OVER, rOver1);

            btn_01.addEventListener(MouseEvent.ROLL_OUT, rOut1);



            function rOver1(event:MouseEvent):void {

                            Tweener.addTween(mc_01,{scaleX:1, scaleY:1, x:450, y:285, alpha:1, time:.5, transition:"easeInOutQuad"});


            function rOut1(event:MouseEvent):void {

                            Tweener.addTween(mc_01,{scaleX:0, scaleY:0, x:450, y:285, alpha:0, time:.25, transition:"easeInOutQuad"});




            • 3. Re: mouse-over action?
              Ned Murphy Adobe Community Professional & MVP

              It is best if you show the code you are using and exlain how the objects it addresses support it.  The suggestions you are getting are AS3 while I believe you are working with AS2.  Also explain what you mean by "opens up a movie clip".

              1 person found this helpful