-
Notifications
You must be signed in to change notification settings - Fork 3
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
Re-implemented NAF player position syncing #17
Conversation
@@ -33,7 +33,6 @@ export const useRoomConnection = (roomName: string) => { | |||
// The `onConnect` setting tells it to call the global function under that name when ready. | |||
sceneElement.setAttribute("networked-scene", { | |||
adapter: "webrtc", | |||
audio: "true", |
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.
#18: you should try this out locally. When this line is added back in, player positions don't sync (on localhost
)...
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.
what the.... and why's that?
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.
Haha I would very much like to know. It might be an issue with using WebRTC over localhost, which would explain why it didn't happen on Glitch.
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.
In src/pages/room/RoomBody/template.html you got rid of dynamic-room
attribute in a-scene
because...? I'm assuming it has to do with the way you are refactoring NAF? Other than that, LGTM!
@fedGL great question! Adding it back in didn't change any of the behavior in this PR for me, including the audio bug. |
Interesting... I found this dynamic room component that was doing |
Oh yes that's right! And now that we attach the logic via JavaScript, the |
Fixes #5.
This was the real deal to get it working again:
I was hoping
audio: true;
and the nametag syncing would also work. No such luck 😒