-
Notifications
You must be signed in to change notification settings - Fork 294
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sync quaternion instead of euler #368
Conversation
Yes! I compared it with master, and this branch does indeed fix it. |
src/components/networked.js
Outdated
@@ -411,6 +408,21 @@ AFRAME.registerComponent('networked', { | |||
// Call networkUpdatePredicate first so that it can update any cached values in the event of a fullSync. | |||
if (this.networkUpdatePredicates[i](syncedComponentData) || fullSync) { | |||
componentsData = componentsData || {}; | |||
if (componentName === 'rotation') { | |||
// We compared the rotation, but we are sending actually the quaternion. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"but we are sending actually" -> "but we actually send" or, "but we are actuallying sending"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I changed to "but we actually send".
Out of curiosity, did you try before adding rotation component on the entities of left-hand-default-template and right-hand-default-template templates, as well on my-tracked-left-hand and my-tracked-right-hand entities so this set the YXZ order? Didn't this fix the issue too? |
I just hadn't gotten around to trying. |
Just adding |
I pushed 0d46822 on master to immediately fix the issue. |
I'm not sure if this is relevant to work on this change. We're adding an additional float to every rotation sync in the naf messages. |
That would be a non issue in aframe 1.6.0. |
Sync quaternion instead of the rotation euler to fix some rotation issues with the YXZ or XYZ euler order.
I didn't fix the tests yet.
@kylebakerio with that does it fix your rotation issues?