r5682 - trunk/data/qcsrc/client

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Tue Jan 27 16:56:11 EST 2009


Author: div0
Date: 2009-01-27 16:56:10 -0500 (Tue, 27 Jan 2009)
New Revision: 5682

Modified:
   trunk/data/qcsrc/client/Main.qc
Log:
moved some long taking entity update code into global init


Modified: trunk/data/qcsrc/client/Main.qc
===================================================================
--- trunk/data/qcsrc/client/Main.qc	2009-01-27 20:34:55 UTC (rev 5681)
+++ trunk/data/qcsrc/client/Main.qc	2009-01-27 21:56:10 UTC (rev 5682)
@@ -138,6 +138,24 @@
 	GibSplash_Precache();
 	Casings_Precache();
 	DamageInfo_Precache();
+
+	get_mi_min_max_texcoords(1); // try the CLEVER way first
+	minimapname = strcat("gfx/", mi_shortname, "_radar.tga");
+	shortmapname = mi_shortname;
+
+	if(precache_pic(minimapname) == "")
+	{
+		// but maybe we have a non-clever minimap
+		minimapname = strcat("gfx/", mi_shortname, "_mini.tga");
+		if(precache_pic(minimapname) == "")
+			minimapname = ""; // FAIL
+		else
+			get_mi_min_max_texcoords(0); // load new texcoords
+	}
+
+	mi_center = (mi_min + mi_max) * 0.5;
+	mi_scale = mi_max - mi_min;
+	minimapname = strzone(minimapname);
 }
 
 // CSQC_Shutdown : Called every time the CSQC code is shutdown (changing maps, quitting, etc)
@@ -591,24 +609,6 @@
 
 void Gamemode_Init()
 {
-	get_mi_min_max_texcoords(1); // try the CLEVER way first
-	minimapname = strcat("gfx/", mi_shortname, "_radar.tga");
-	shortmapname = mi_shortname;
-
-	if(precache_pic(minimapname) == "")
-	{
-		// but maybe we have a non-clever minimap
-		minimapname = strcat("gfx/", mi_shortname, "_mini.tga");
-		if(precache_pic(minimapname) == "")
-			minimapname = ""; // FAIL
-		else
-			get_mi_min_max_texcoords(0); // load new texcoords
-	}
-
-	mi_center = (mi_min + mi_max) * 0.5;
-	mi_scale = mi_max - mi_min;
-	minimapname = strzone(minimapname);
-
 	if(gametype == GAME_ONSLAUGHT) {
 		print(strcat("Using ", minimapname, " as minimap.\n"));
 		precache_pic("gfx/ons-cp-neutral.tga");




More information about the nexuiz-commits mailing list