changed using network protocol by starting with protocol version check
[rocksndiamonds.git] / src / init.c
index 1d3085c5c4b9bb47c0fe5f191ea3664b29fd8f7c..ad660e355bcbd3de0c063866c75838e40af502e7 100644 (file)
@@ -5051,6 +5051,9 @@ void Execute_Command(char *command)
   {
     Error(ERR_EXIT_HELP, "unrecognized command '%s'", command);
   }
+
+  /* disable networking if any valid command was recognized */
+  options.network = setup.network_mode = FALSE;
 }
 
 static void InitSetup()
@@ -5628,8 +5631,8 @@ void InitNetworkServer()
   }
   else
   {
-    SendToServer_PlayerName(setup.player_name);
     SendToServer_ProtocolVersion();
+    SendToServer_PlayerName(setup.player_name);
     SendToServer_NrWanted(setup.network_player_nr + 1);
 
     network.connected = TRUE;