unity3d - Need Unity character controller to make sharp 90 degree turns and not slide when turning -
I am using the first person controller for my letter movement. On the left arrow keymap, I will rotate the character immediately 90 degrees and would like to move forward. Currently, when I hit the arrow key, the character turns 90 degrees high, but it takes a second to wear the forward speed first, so that the character has to slide in the direction that it is the first was going on. / P>
The closest example I can imagine is what I am trying to do is to see how much the character gets accelerated in the temple run. What my game is currently doing, if I have a character on a hole, then it turns a sharp left, it maintains the original speed and closes the edge immediately after going behind it.
Since my character is running on the X / Z axis, I am thinking that what would be the method of swapping directional velocity / speed? The motion of the character on the X axis will be switched immediately and the second will be set to zero. I am obviously open to any solution which is what I see.
I dug the character meter in the first person's controller, but so far to figure out which part I can be responsible for fulfilling.
Thanks
Thank you.
You can try to stop fanatics before turning it on.
this.rigidbody.velocity = Vector3.zero; This.rigidbody.angularVelocity = Vector3.zero; If you want to continue the object, you can save the current speed in one variable and set it to 0, then rotate it and then the old speed (still Next)
If it works with a global vector (hence the object of the world, not the object), then you can try to defame velocity, in fact it 'backwards 'Can motivate to go. I can not test it till now, but I think that you have to set zero to zero first before changing the character.
Comments
Post a Comment