收到结束游戏的消息后, 将房间设置为lock
This commit is contained in:
parent
ba570be9ff
commit
08a01f8b8e
@ -9,5 +9,7 @@ export class EndGameCommand extends Command<PuzzleGameState, {}> {
|
|||||||
async execute() {
|
async execute() {
|
||||||
this.state.updateGameState(GameStateConst.STATE_GAME_OVER)
|
this.state.updateGameState(GameStateConst.STATE_GAME_OVER)
|
||||||
this.room.broadcast('endgame', {})
|
this.room.broadcast('endgame', {})
|
||||||
|
await this.room.setPrivate(true)
|
||||||
|
await this.room.lock()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user