Is This Right(Part II.)

Ok I need sombody to check this code,on my game im try to make my character(“Sonic”) face in different directions(Left And Right), and also control whether or not there walking,running or dashing. I used absolute value to measure the distance from zero(the speed), and whether or not my character was facing right to show which way im facing.

if (_root.Sonic.Xspeed == 0) {
if (_root.Sonic.Right == true) {
_root.Sonic.gotoAndStop(“Stand Right”);
} else if (_root.Sonic.Right=false) {
_root.Sonic.gotoAndStop(“Stand Left”);
}
} else if (not (_root.Sonic.Xspeed == 0)) {
if (_root.Sonic.Right == true) {
} else if (Math.abs(_root.Sonic.Xspeed)<=10) {
_root.Sonic.gotoAndStop(“Walk Right”);
} else if (Math.abs(_root.Sonic.Xspeed)<=20) {
_root.Sonic.gotoAndStop(“Run Right”);
} else if (Math.abs(_root.Sonic.Xspeed)<=30) {
_root.Sonic.gotoAndStop(“Dash Right”);
}
} else if (_root.Sonic.Right == false) {
if (Math.abs(_root.Sonic.Xspeed)<=10) {
_root.Sonic.gotoAndStop(“Walk Left”);
} else if (Math.abs(_root.Sonic.Xspeed)<=20) {
_root.Sonic.gotoAndStop(“Run Left”);
} else if (Math.abs(_root.Sonic.Xspeed)<=30) {
_root.Sonic.gotoAndStop(“Dash Left”);
}
}