4 Replies Latest reply on Mar 26, 2010 3:02 PM by Jubahlingus

    Animations sticking on mouse over and mouse out




      im in the process of making an interactive map. I have set up some code for the mouse over and mouse out for each of my movieclips of the 50 states. but if you notice if you move the mouse rather fast over the map the mouse over state seems to be sticking.



      here is what i have for the code for each of the states. california will be the example.


      california_mc.buttonMode = true;
      california_mc.addEventListener(MouseEvent.CLICK, ca_info);
      california_mc.addEventListener(MouseEvent.ROLL_OVER, colorIn);
      california_mc.addEventListener(MouseEvent.ROLL_OUT, colorOut);


      function colorIn(event:MouseEvent):void
      function colorOut(event:MouseEvent):void


      in each instance of the state there are 3 frames, the latter 2 labeled in and out. the in frame is just a shape of the state colored red. on the out frame label there is this code:


      import com.greensock.TweenLite;
      import com.greensock.easing.*;
      import com.greensock.plugins.*;
      import flash.geom.ColorTransform;


      function colorChange():void
          var color_transform:ColorTransform = cali_mc.transform.colorTransform;
          cali_mc.transform.colorTransform = color_transform;



      TweenLite.to(cali_mc, .3, {tint:0x999999});




      is there something about this design that is letting it hang like that on the mouse over state? and how to get rid of it?