Closed BertrandOustriere closed 4 years ago
Side note: I updated the PR description text and replaced hostTransform.localEulerAngles with hostTransform.eulerAngles, because I'm assuming that the text was intended to show the code as-is (with the issue that exists today), not the fix that was proposed.
@thalbern it seems like this is actually just a bug due to the non-mirrored nature of the set/get (i.e. non local in one, local in the other) - it seems like making them be mirrored would be the right thing to do, but I guess it might also be a question of which one is the more 'correct' one. Do you have any background/thoughts on this one?
Otherwise there might be some compat concerns (i.e. people now taking a dependency on the weird state that exists today - which would also be fixable with another property/bit without too much difficulty)
Describe the bug
InteractableRotationTheme is using a world rotation for the interpolation's start value :
Since the interpolation is setting the local rotation in the SetValue function, this induces weird behaviour in some cases, for exemple when the parent transform of the rotated object has a rotation different from Vector3.zero
By using
hostTransform.localEulerAngles
in the GetProperty function, the issue seems to be fixed.To reproduce
Steps to reproduce the behavior:
Your setup (please complete the following information)
Target platform (please complete the following information)