Movement

Hi, I followed an older tut on this site about moving an MC using AS.

I can get it to do what I want with the code below when moving from left to right, and I assumed that by using negative values I could get it to go from left to right. But it won’t work. Can anyone help, as I’d like to set the movement r to l.

This code works left to right

onClipEvent(enterFrame) {
speed = 2;
if(this._x< 160){
this._x += speed;
}
}