looks like you're using ActionScript 2.0, but just for the record, in ActionScript 3.0 you can use the Event.MOUSE_LEAVE event to detect when the mouse leaves Flash Player's display area.

colin

Hans Wichman wrote:
Hi,

that is only detectable when the mouse is down (try tracing xmouse and
ymouse while mouse is down, versus when its not).
Another thing you can do is look at how long the mouse hasnt moved.

greetz
JC

On Feb 8, 2008 1:40 PM, Allandt Bik-Elliott (Receptacle) <
[EMAIL PROTECTED]> wrote:

hi guys

just a quickie

i've got an expandable flash banner that has a transparent movie clip
(called roll_mc) over the top of it to detect whether to expand or
not but because i can't seem to get an accurate false from my hittest
if the mouse goes out of the banner, i was wondering if there was a
way to detect if the mouse was in the movie at all

here is what i have

function gotoExpand():Void {
       trace ("x mouse is "+_root._xmouse);
       trace ("y mouse is "+_root._ymouse);
       if (roll_mc.hitTest(_root._xmouse, _root._ymouse) &&
_root._xmouse<345 && _root._ymouse<345) nextFrame();
}

the movie is 350x350 but if you move the mouse out of the movie
pretty quickly, it registers that the mouse is still within the movie

example traces:
//mouse is moved fairly slowly
x mouse is 349
y mouse is 208
x mouse is 349
y mouse is 208
x mouse is 185
y mouse is 349
x mouse is 348
y mouse is 95
//mouse moved fairly quickly
x mouse is 336
y mouse is 225

anyone have any ideas?

_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to