They don't do a rotation check, they make the arm fully rotatable. Then limit it between 2 rotations. So make it say follow mouse if rotation less then 270 but greater then 230 if hes facing right, then do the same on the other side.
Then just do a check of which side the mouse is on.
if (_root._xmouse > _root.char._x) {
_root.sam._xscale = -100;
} else {
_root.sam._xscale = 100;
}
you may have to reverse it, but you get the general idea