Hello,
I have a nested MC that functions as a continuous slider; when you mouse right of center it slides one way and when you mouse left of center it slides the opposite direction. Right at center it stops. The problem I have is that I’m using this as a menu at the bottom of a .swf and there are other places to mouse on the page, which means that this menu is constantly in motion even when it’s not being used. I want it to stop when it isn’t being used, only because it’s an MC I can’t use the onMouseOut command to stop the clip. I tried making a button that targets the clip and stops it when you roll over the button but it doesn’t work. Not sure what I need to do but sure would appreciate any and all help.
Here’s the script I’m currently using:
onClipEvent (mouseMove) {
xcenter = 467.5;
speed = 1/25;
}
onClipEvent (enterFrame) {
var distance = _root._xmouse-xcenter;
_x -= (distance*speed);
}
onClipEvent (enterFrame) {
var distance = _root._xmouse-xcenter;
_x -= (distance*speed);
if (_x>0) {
_x = -935;
}
if (_x<-935) {
_x = 0;
}
}
-Thanks,
Llyfre