The problem was that the bones were incorrectly exported from blender, I needed to reset their roll.
transform.rotation = newValue; does not work on bone of rigged mesh
I have a rigged mesh, that has main bone and multiple child bones. I have a script for more complex animation. I'm trying to set absolute rotation of a bone in level2. transform.rotation = rot; or transform.eulerAngles = rot.eulerAngles; or transform.SetPositionAndRotation(pos, rot);
When debugging: The initial value is (270.019775, 89.9999924, 0), I'm setting (270, 90, 0) but the result is (-1.09115881E-05, 6.08191203E-06, 90), which different angle. All the lines above do the same.
How is this possible? I cannot find any way to set the correct value.
Follow this Question
Related Questions
Rotating sprite rotates the controls 1 Answer
[UNET] Problems with syncing Weapon rotation 0 Answers
Rotate gameObject to a specific angle on one axis 0 Answers
Set bone transform in code after removing skinnned mesh renderer and adding mesh renderer. 0 Answers
Rotating transform more than 180 degrees 2 Answers