Forum Moderators: open

Message Too Old, No Replies

Flash MX Actionscript held needed

mouse position doesn't make sense

         

lorax

3:15 pm on May 5, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I'm working with a downloaded tutorial and I know just enough ActionScript to be dangerous.

The details:

The script is a movie scroll (20 images repeated once so the total is 40 images all together).

The movie uses a tween to move the image group (all of the images as one group) left to right.

The code in question is:

onClipEvent (mouseMove) {
xmousepos1 = _xmouse;
ymousepos1 = _ymouse;
_quality = "LOW";

if (ymousepost1>ymousepos2 && xmousepos1>-390 && xmousepos1<-280) {
_root.scrollclip.nextFrame();
}
...
}

ymouse2 gets set later. What I don't understand is the reason a negative xmousepos1 works. I've tried to use positive numbers instead but then the mouse position is ignored. I'm a bit stuck and am in deadline mode...

FYI - The original of this clip was vertical. I turned te movie on it's side and edited it from there. Shouldn't matter right? I added two text boxes to display the mouse coordinates just for grins and they seem to track just as I would expect.

lorax

4:17 pm on May 5, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Found my answer - even though I edited the MC in the main Scene - it was still rotated so my mouse positions were screwed up. The MC displayed properly when I edited it and because I rotated it when I inserted it into the Scene I thought everything was ok. To test if this issue was a rotation problem I copied the MC off the Scene and inserted it into a blank fla. It came in rotated. Now I just have to rebuild my movie and all should be well.