Wanting to do a level editor of sorts I was converting quaternions from a rotation ‘handle’ to euler angles to display and store, but you find some oddities not seen in the Unity inspector which tracks a euler ‘hint’ value alongside a quaternion for rotations! Quaternion to three hinge joints - Unity Engine - Unity Discussions
Anyway this is most obvious if you rotate on the x-axis so:
transform.rotation = Quaternion.Euler( new Vector3( 110, 0, 0 ) );
Debug.Log( transform.eulerAngles.ToString() );
will give you 70,180,180
I wonder if there is a simple way to avoid this ‘flip’ effect where 2 axis change and the rotation reverses on the original, i.e. if you rotate on x axis beyond 90,0,0 Perhaps only by tracking the previous value and the new one could you then detect it. But it gets much more complicated as you rotate on many axis.
Ultimately it is not unacceptable to have the above but can make it confusing if you show the end user euler angles, which is presumably why Unity track a hinted value