How to get the angle to animate the player when running?
Hello,
I'm now doing the animations, and want to set a "float" value to blend between "move left/right/straight". Using the A and D keys for switching the animation is done. BUT when I only press W key, and player moves forward, then moves the camera, it keeps running straight and I want it's current "momentum VS input direction (camera facing)" to modify the "float" value to animate it right.
So far I got this: float Angle = Vector3.Angle(PlayerRigidbodyVelocity, CameraForwardWithoutY); Which gives me the nice angle I need to make it happen, but the angle is always positive (aka, when moving either left or right gives 90º on both, instead of one 90º and one either -90º or 270º on the other). How can I figure out when to multiply that value for -1 to make it work? Thanks