fixed out of range error when dragging mouse outside game window