In CharacterControllerInput, is this just determining the direction of movement?
Code: Select all
#if XBOX360
Vector3 forward = Camera.WorldMatrix.Forward;
forward.Y = 0;
forward.Normalize();
Vector3 right = Camera.WorldMatrix.Right;
totalMovement += gamePadInput.ThumbSticks.Left.Y * new Vector2(forward.X, forward.Z);
totalMovement += gamePadInput.ThumbSticks.Left.X * new Vector2(right.X, right.Z);
CharacterController.HorizontalMotionConstraint.MovementDirection = Vector2.Normalize(totalMovement);
Code: Select all
#if XBOX360
Vector3 forward = Camera.WorldMatrix.Forward;
forward.Y = 0;
forward.Normalize();
Vector3 right = Camera.WorldMatrix.Right;
totalMovement += gamePadInput.ThumbSticks.Left.Y * gamePadInput.ThumbSticks.Left.Y * new Vector2(forward.X, forward.Z);
totalMovement += gamePadInput.ThumbSticks.Left.X * gamePadInput.ThumbSticks.Left.X * new Vector2(right.X, right.Z);
CharacterController.HorizontalMotionConstraint.MovementDirection = Vector2.Normalize(totalMovement);
Should I be passing the thumbstick values to HorizontalMotionConstraint and use them to modify MaxSpeed?
I have played with increasing the characters mass. A mass of 30 gives an acceptable smooth stop rather than an abrupt halt. A mass of 300 is more akin to a hovercraft.
Ideally I would like some dampening so that i can accurately move the character small amounts. Also I would like left, right and back speeds to be a lot less than forward speeds.
Any help would be great!
Thank you.