Send ROUND_FINISHED only once (only from in game mode)
authorunc0rr
Sun, 26 Feb 2012 12:15:32 +0400
changeset 6739 97dab041f995
parent 6738 dd98869d74b4
child 6740 4167ebd563d9
Send ROUND_FINISHED only once (only from in game mode)
QTfrontend/net/newnetclient.cpp
--- a/QTfrontend/net/newnetclient.cpp	Sat Feb 25 22:18:08 2012 +0400
+++ b/QTfrontend/net/newnetclient.cpp	Sun Feb 26 12:15:32 2012 +0400
@@ -761,8 +761,11 @@
 
 void HWNewNet::gameFinished(bool correctly)
 {
-    if (netClientState == InGame) netClientState = InRoom;
-    RawSendNet(QString("ROUNDFINISHED%1%2").arg(delimeter).arg(correctly ? "1" : "0"));
+    if (netClientState == InGame)
+    {
+        netClientState = InRoom;
+        RawSendNet(QString("ROUNDFINISHED%1%2").arg(delimeter).arg(correctly ? "1" : "0"));
+    }
 }
 
 void HWNewNet::banPlayer(const QString & nick)