I’m playing around with the built-in character controller.
Unity - Scripting API: CharacterController.Move (unity3d.com)
in the jump code we have this,
playerVelocity.y += Mathf.Sqrt(jumpHeight * -3.0f * gravityValue);
Which got me to thinking, what if we made some changes to control jump distance
playerVelocity.z += Mathf.Sqrt(jumpHeight * -3.0f * gravityValue);
Works, except, it only moves forward in the world space no matter which direction the player object is facing.
So, what I’m trying to figure out is how do I get this Vector3 to match up with the direction the player is facing?
It’s late. I’ve hit a dead end here.