fixed: choose map for simple game is working now
authordisplacer
Sun, 19 Nov 2006 14:11:02 +0000
changeset 253 e7b3687fcb2c
parent 252 455f29b31ed9
child 254 6bdb58eff749
fixed: choose map for simple game is working now
QTfrontend/game.cpp
QTfrontend/game.h
--- a/QTfrontend/game.cpp	Sun Nov 19 12:29:58 2006 +0000
+++ b/QTfrontend/game.cpp	Sun Nov 19 14:11:02 2006 +0000
@@ -51,7 +51,7 @@
 	LocalCFG(teams[index]);
 }
 
-void HWGame::SendConfig()
+void HWGame::commonConfig()
 {
 	SendIPC(QString("eseed %1").arg(seed).toAscii());
 	try {
@@ -64,6 +64,11 @@
 	}
 	SendIPC("TL");
 	SendIPC(QString("e$gmflags %1").arg(gamecfg->getGameFlags()).toAscii());
+}
+
+void HWGame::SendConfig()
+{
+	commonConfig();
 
 	for (int i = 0; i < TeamCount; i++)
 	{
@@ -80,10 +85,7 @@
 
 void HWGame::SendQuickConfig()
 {
-	SendIPC(QString("eseed %1").arg(seed).toAscii());
-	SendIPC(QString("etheme %1").arg(config->GetRandomTheme()).toAscii());
-	SendIPC("TL");
-	SendIPC(QString("e$gmflags %1").arg(gamecfg->getGameFlags()).toAscii());
+	commonConfig();
 
 	QByteArray teamscfg;
 	HWTeam team1(0);
--- a/QTfrontend/game.h	Sun Nov 19 12:29:58 2006 +0000
+++ b/QTfrontend/game.h	Sun Nov 19 14:11:02 2006 +0000
@@ -70,6 +70,7 @@
 	GameCFGWidget * gamecfg;
 	GameType gameType;
 
+	void commonConfig();
 	void SendConfig();
 	void SendQuickConfig();
 	void SendTeamConfig(int index);