-
Movie Clip Button hit area
I am working on my first Flash Project since a few years ago when I was using Flash MX. So far I have created a working movie clip button that incorporates an After Effects animation upon a mouse rollover.
The hit area for my button is way too large now since the movie clip has taken on the properties of a button.I tried to create another movie clip in the same layer that was the correct size to act as the hit area that I wanted. I also made it transparent but I know my action scripting must be wrong.
Is there a way to do this or should I try a different way to customize my hit area?? Any help is appreciated.
-
Senior Member
Which actionscript version are you using?
- The right of the People to create Flash movies shall not be infringed. -
-
I am using Flash CS3, AS 3.0
-
Senior Member
- The right of the People to create Flash movies shall not be infringed. -
-
So how would I go about simply creating a child button that would play the movie clip in my movie clip button on a rollover? I think that would work to create the right sized hit area that I want, Im just not sure how to script that.
-
I have 2 movie clip buttons. "hit_btn" is the one I want as the hit area. "animation" is my animated movie clip button that contains a hit area that is way to large to use with multiple buttons that would eventually be side by side.
Here is what I have Scripted thus far. I don't get any errors but nothing is happening now when I rollover.
function overButton(event:MouseEvent):void {
event.currentTarget.gotoAndPlay("over");
}
hit_btn.addEventListener(MouseEvent.ROLL_OVER,over Button);
hit_btn.buttonMode = true;
hit_btn.visible = false;
hit_btn.hitArea = animation;
animation.mouseEnabled = false;
-
NEVERMIND. I GOT IT!! just had my buttons flipped around wrong
(animation.hitArea = hit_btn)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|