Stage 249

This commit is contained in:
Abdussamed ULUTAŞ 2022-12-22 23:34:56 +03:00
parent 3e5e77ab64
commit d7900f827f
4 changed files with 5 additions and 3 deletions

View File

@ -73,6 +73,7 @@ export default class Room extends EventTarget
...result.room ...result.room
}; };
this.roomId = result.room.id; this.roomId = result.room.id;
this.mwse.rooms.set(this.roomId as string, this);
} }
} }
async join(){ async join(){
@ -90,6 +91,7 @@ export default class Room extends EventTarget
...result.room ...result.room
}; };
this.roomId = result.room.id; this.roomId = result.room.id;
this.mwse.rooms.set(this.roomId as string, this);
} }
} }
async send(pack: any, wom:boolean = false){ async send(pack: any, wom:boolean = false){

View File

@ -71,7 +71,7 @@ export default class MWSE extends EventTarget {
} }
let room = new Room(this); let room = new Room(this);
room.setRoomOptions(options); room.setRoomOptions(options);
this.rooms.set(room.roomId as string, room); // this.rooms.set(room.roomId as string, room);
this.emit('room'); this.emit('room');
return room; return room;
} }

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long