QTfrontend/game.cpp
changeset 541 bc7be7f6d3e8
parent 533 eebb7684ac22
child 555 0376fdcc6322
--- a/QTfrontend/game.cpp	Mon Jun 11 15:52:32 2007 +0000
+++ b/QTfrontend/game.cpp	Mon Jun 11 15:53:29 2007 +0000
@@ -48,8 +48,16 @@
 
 void HWGame::onClientDisconnect()
 {
-	if (gameState == gsInterrupted) emit HaveRecord(false, demo);
-	else if (gameState == gsFinished) emit HaveRecord(true, demo);
+	switch (gameType) {
+		case gtDemo:
+			break;
+		case gtNet:
+			emit HaveRecord(true, demo);
+			break;
+		default:
+			if (gameState == gsInterrupted) emit HaveRecord(false, demo);
+			else if (gameState == gsFinished) emit HaveRecord(true, demo);
+	}
 	SetGameState(gsStopped);
 }