Hi! I am having problems with the stubborn negative values of euler that doesn´t work. Is there any other way I can write negative angles in a quaternion? This is my line of code, and as you know the negative value 15 is acting like angle 345…

transform.localRotation = Quaternion.Euler(0f,0f,Mathf.Lerp(transform.rotation.eulerAngles.z,-15,Time.deltaTime*5f));

I want to rotate my camera 15 degrees “negative” while my character is wallrunning.

Thank you in advance

I solved it.

Instead of using Quaternion.Euler I used a Quaternion.Lerp from my cameras transform.localrotation to a Quaternion(0,0f,-0.1f,1.0f) (which is the quaternion that rotates aproximately 15 degrees “negatively” around the z-axis). This is the code:

RotateCamera.transform.localRotation = Quaternion.Lerp( RotateCamera.transform.localRotation,new Quaternion(0,0f,-0.1f,1.0f),1f*Time.deltaTime*5f);

I used the same line, but with my cameras original transform.rotation as the target, to rotate the camera back (when I jump off the wall).