multiply by 1000 to wait 30s before stopping game.

This commit is contained in:
Evan
2024-12-15 12:55:06 -08:00
parent 2fc81c7d17
commit 5cf6a35fee
2 changed files with 2 additions and 3 deletions
+1 -1
View File
@@ -28,7 +28,7 @@
</svg>
</a>
<h1 class="text-7xl sm:text-5xl md:text-6xl lg:text-7xl mb-2">OpenFront.io</h1>
<h2 class="text-3xl sm:text-4xl md:text-5xl lg:text-6xl mb-4">(v0.12.0)</h2>
<h2 class="text-3xl sm:text-4xl md:text-5xl lg:text-6xl mb-4">(v0.12.1)</h2>
<div class="flex justify-center items-start">
<div class="w-full max-w-3xl p-4 space-y-4">
<br />
+1 -2
View File
@@ -208,7 +208,7 @@ export class GameServer {
return GamePhase.Lobby
}
if (this.activeClients.length == 0 && now > this.createdAt + this.config.lobbyLifetime() + 30 * 60) { // wait at least 30s before ending game
if (this.activeClients.length == 0 && now > this.createdAt + this.config.lobbyLifetime() + 30 * 60 * 1000) { // wait at least 30s before ending game
return GamePhase.Finished
}
@@ -218,5 +218,4 @@ export class GameServer {
hasStarted(): boolean {
return this._hasStarted
}
}