Top Down Character - Face direction of movement?
I have a topdown character moving like this:
moveDirection = new Vector3(Input.GetAxis("Horizontal"), 0, Input.GetAxis("Vertical"));
gameObject.transform.LookAt(gameObject.transform.position + moveDirection, Vector3.up);
But when I release the moving keys he snaps back to 0,0,0 rotation (in fact its often 90,0,0). How can I make him remain facing the right direction when I release keys?
Comment