archive full game on crash (#251)

This commit is contained in:
evanpelle
2025-03-14 14:08:16 -07:00
committed by GitHub
parent d82191308e
commit 4a6ce12988
3 changed files with 10 additions and 8 deletions
+3 -3
View File
@@ -193,7 +193,7 @@ export class ClientGameRunner {
this.lobby.gameID,
this.lobby.clientID,
);
this.stop();
this.stop(true);
return;
}
gu.updates[GameUpdateType.Hash].forEach((hu: HashUpdate) => {
@@ -265,10 +265,10 @@ export class ClientGameRunner {
this.transport.connect(onconnect, onmessage);
}
public stop() {
public stop(saveFullGame: boolean = false) {
this.worker.cleanup();
this.isActive = false;
this.transport.leaveGame();
this.transport.leaveGame(saveFullGame);
}
private inputEvent(event: MouseUpEvent) {