Unity DOTS - Changing LocalTransforms Rotation also changes Local-To-World scalings

Hey guys its me again :open_mouth:
im finally using dots for my game, i got the balls pawning, now im working with obstacles, i need to rotate them on the Z axys only, I’ve tried almost every type of code i found online, being in the onupdate, changing the transform via quaternion, changing the z value directly, working with aspects, etc…

the problem i am getting is:
that whenever i change the Z axis on the entity (be it via code or in the inspector) it changes the local-to-world scalings aswell…
is this a known bug, or am i doing something wrong?
image

The rotation in the LocalTransform is a quaternion, not Euler angles. Valid quaternion rotations are a 4-component vector with magnitude 1. You’ll need to write the Rotation from code with quaternion.EulerZXY. Note that Euler angles in Unity Mathematics are in radians. You can convert to radians with math.radians.

1 Like

That’s working, Thanks! very big help there. Now I have to figure out why the child components are not setup correctly.

Thanks again!

1 Like