Syncing optimizations (#1554)

* Syncing optimizations

* Add comment
This commit is contained in:
Pete Hunt
2020-05-07 14:13:18 -07:00
committed by GitHub
parent e27f3f9ad2
commit 4696c9ee0e
4 changed files with 71 additions and 15 deletions

View File

@@ -29,7 +29,7 @@ class Portal {
}
});
this.socket.on("new-user", async (_socketID: string) => {
this.app.broadcastScene(SCENE.INIT);
this.app.broadcastScene(SCENE.INIT, /* syncAll */ true);
});
this.socket.on("room-user-change", (clients: string[]) => {
this.app.setCollaborators(clients);