frontlib: Moved mapname sending to the end of flib_netconn_send_map
authorMedo <smaxein@googlemail.com>
Sat, 18 Aug 2012 00:22:33 +0200
changeset 7504 ed1d52c5aa94
parent 7500 6253cae96f21
child 7508 763d3961400b
frontlib: Moved mapname sending to the end of flib_netconn_send_map
project_files/frontlib/net/netconn_send.c
--- a/project_files/frontlib/net/netconn_send.c	Sat Aug 18 00:18:43 2012 +0200
+++ b/project_files/frontlib/net/netconn_send.c	Sat Aug 18 00:22:33 2012 +0200
@@ -267,12 +267,14 @@
 	}
 	error |= flib_netconn_send_mapGen(conn, map->mapgen);
 	error |= flib_netconn_send_mapMazeSize(conn, map->mazeSize);
+	if(map->drawData && map->drawDataSize>0) {
+		error |= flib_netconn_send_mapDrawdata(conn, map->drawData, map->drawDataSize);
+	}
+	// Name is sent last, because the QtFrontend uses this to update its preview, and to show/hide
+	// certain fields
 	if(map->name) {
 		error |= flib_netconn_send_mapName(conn, map->name);
 	}
-	if(map->drawData && map->drawDataSize>0) {
-		error |= flib_netconn_send_mapDrawdata(conn, map->drawData, map->drawDataSize);
-	}
 	return error;
 }