Rotate gameObject to a specific angle on one axis
I want to rotate a gameObject (cube) smoothly around 90degrees. Key up rotate 90 upwards/on the x-axis, Key left rotate 90 to the left/on the y-axis ... My problem is that after for example I rotated the object 90 degrees on the x-axis and now click the left Key I have to rotate the object 90 degrees on the z axis or when I firstly rotate the object to the right/on the y-axis and now want to rotate it upwards I have to rotate it on the z-axis.
Is there a simpler way than always remembering which axis is facing upwards to the left ... to rotate the Cube around the correct axis?
Thank you in advance for your response.
Your answer
Follow this Question
Related Questions
transform rotations overwriting eachother 1 Answer
What is the difference between setting transform.eulerAngles and transform.rotation? 1 Answer
slowly turn an object 90 degrees by key press 0 Answers
Any simple ways of keeping track of simple rotation? 2 Answers
Rotate clockwise/counterclockwise using Quaternion.Slerp() 0 Answers