working woka picture if no camera view is provided

This commit is contained in:
Hanusiak Piotr 2021-11-26 23:30:21 +01:00
parent f4ce82481e
commit 7b94ac644d
2 changed files with 41 additions and 15 deletions

View file

@ -5,12 +5,13 @@ import type { RoomConnection } from "../Connexion/RoomConnection";
* A store that contains the players avatars pictures
*/
function createUserWokaPictureStore() {
let players = new Map<number, string>();
const players = new Map<number, string>();
const { subscribe, update } = writable(players);
return {
subscribe,
// P.H. NOTE: Not clearing the store after reconnecting to the room - is this a problem?
connectToRoomConnection: (roomConnection: RoomConnection) => {
roomConnection.onUserLeft((userId) => {
update((users) => {