if (x != targetx) x += ((targetx - x) / ratio) if (y != targety) y += ((targety - y) / ratio) with (oCharacter) xVel = 0