Jump to content
GreenSock

learner_7n

Image button change to another image when mouse over..

Moderator Tag

Recommended Posts

Hi,

 

I want to make an image as button which should show on mouse over another image? How it is possible? What is the greensock code to achieve it?

 

Please help.

 

Regards.

Link to comment
Share on other sites

That's not really a GreenSock-related question:

 

mc1.addEventListener(MouseEvent.ROLL_OVER, overHandler);
mc1.addEventListener(MouseEvent.ROLL_OUT, outHandler);
function overHandler(event:MouseEvent):void {
   mc2.visible = true;
}
function outHandler(event:MouseEvent):void {
   mc2.visible = false;
}

 

Of course you could tween the alpha or whatever if you want.

 

I'd recommend getting a good AS3 book or going through some basic tutorials at lynda.com or kirupa.com or actionscript.org or gotoandlearn.com

 

Good luck!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×