Click to See Complete Forum and Search --> : Movement restriction


Sang Hee
02-05-2010, 02:53 AM
Hi,
I've made a sort of sliding menu in Flash (CS4) which is basically a movie clip that has a function assigned to it that if the cursor goes over a button it starts moving in a direction.


_root.right.onRollOver = function() {
goRight = true;
};
if (goRight) {
_root.content._x -= 10;
}

Now, I don't want that "content" object to slide all the way out of the screen. How can I make it stop at certain position, say x=770? Or is there any way?