I am trying to get a movieclip to follow the mouse on which direction it plays, the movieclip plays from right to left normally and loops twice it plays the last half over and over
code:
onClipEvent (mouseMove) {
myMouseX1 = _xmouse;
myMouseY1 = _ymouse;
if (myMouseX1 > myMouseX2 and myMouseY1> 100 and myMouseY2 <0) {
onClipEvent (mouseMove) {
myMouseX1 = _xmouse;
myMouseY1 = _ymouse;
if (myMouseX1 > myMouseX2 and myMouseY1> 100 and myMouseY2 <0) {
_root.globescroll.nextFrame();
}
if (myMouseX1 < myMouseX2 and myMouseY1>100 and myMouseY2 <0) {
_root.globescroll.prevFrame();
}
if ( myMouseY1<100 or myMouseY1>0) {
play();
}
myMouseX2 = _xmouse;
myMouseY2 = _ymouse;
}_root.globescroll.nextFrame();
}
if (myMouseX1 < myMouseX2 and myMouseY1>100 and myMouseY2 <0) {
_root.globescroll.prevFrame();
}
if ( myMouseY1<100 or myMouseY1>0) {
play();
}
myMouseX2 = _xmouse;
myMouseY2 = _ymouse;
}
i cant see any problems with the code
myMouseY figures reference the _ymouse from _root which is the top left hand corner which is normal for flash although, the movieclip with the instance globescroll is 100pixels high, so it should play while the _ymouse is between 0 and 100