bug fixes

fixed a bug with how direction is determined when using the mouse and
support a 8 way movement.