Highlighted

absolute confusion

Community Beginner ,
Mar 22, 2019

Copy link to clipboard

Copied

I have the following AS:

this.addEventListener(MouseEvent.MOUSE_OVER, FolderHover);

function FolderHover(event:MouseEvent):void

{ if (FolderState=="idle")

{

Mouse.cursor=MouseCursor.BUTTON;

gotoAndStop("hover");

}

}

Now...

the MouseCursor.BUTTON bit works as expected, as soon as I hover over the target MC the cursor changes but the gotoAndStop("hover"); only works when I hover over a bit of dynamic text that lives inside the target movie clip. If I turn the dynamic text to static, gotoAndStop("hover") stops working altogether. If I remove the text field completely, gotoAndStop("hover") stops working altogether but Mouse.cursor=MouseCursor.BUTTON; always works.

I'm not sure if I'm completely stupid or there's something very strange going on

Views

136

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

absolute confusion

Community Beginner ,
Mar 22, 2019

Copy link to clipboard

Copied

I have the following AS:

this.addEventListener(MouseEvent.MOUSE_OVER, FolderHover);

function FolderHover(event:MouseEvent):void

{ if (FolderState=="idle")

{

Mouse.cursor=MouseCursor.BUTTON;

gotoAndStop("hover");

}

}

Now...

the MouseCursor.BUTTON bit works as expected, as soon as I hover over the target MC the cursor changes but the gotoAndStop("hover"); only works when I hover over a bit of dynamic text that lives inside the target movie clip. If I turn the dynamic text to static, gotoAndStop("hover") stops working altogether. If I remove the text field completely, gotoAndStop("hover") stops working altogether but Mouse.cursor=MouseCursor.BUTTON; always works.

I'm not sure if I'm completely stupid or there's something very strange going on

Views

137

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Mar 22, 2019 0
Adobe Community Professional ,
Mar 22, 2019

Copy link to clipboard

Copied

Hi.

It seems to me this a hit area problem.

Try including a invisible rectangle in your Movie Clip instance and set the mouseChildren property to false.

Please let us know if this helps.

Regards,

JC

__________________________________________
HTML5, JSFL, and AS3 samples: http://bit.ly/2mJgDoG

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 22, 2019 0
Community Beginner ,
Mar 22, 2019

Copy link to clipboard

Copied

the movie clip already has a background which is actually visible

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 22, 2019 0
Adobe Community Professional ,
Mar 22, 2019

Copy link to clipboard

Copied

And what happens if you set the mouseChildren property to false?

__________________________________________
HTML5, JSFL, and AS3 samples: http://bit.ly/2mJgDoG

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 22, 2019 0
Community Beginner ,
Mar 22, 2019

Copy link to clipboard

Copied

didn't work

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 22, 2019 0
Adobe Community Professional ,
Mar 22, 2019

Copy link to clipboard

Copied

Can I see your FLA?

__________________________________________
HTML5, JSFL, and AS3 samples: http://bit.ly/2mJgDoG

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 22, 2019 0