]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/miscfunctions.qc
Merge branch 'master' of git://de.git.xonotic.org/xonotic/xonotic-data.pk3dir
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / miscfunctions.qc
index 632a4a5ce1bedb30f9994d22c21481e44b1c961d..a40982ce7e2f733f72ac43aedef9564af457c120 100644 (file)
@@ -880,8 +880,6 @@ float want_weapon(string cvarprefix, entity weaponinfo, float allguns)
                        t = (weaponinfo.spawnflags & WEP_FLAG_NORMAL);
                else if(t < -1)
                        t = 0;
-               else if (g_race)
-                       t = (i == WEP_LASER || i == WEP_SHOTGUN);
                else if (g_cts)
                        t = (i == WEP_SHOTGUN);
                else if (g_nexball)
@@ -917,8 +915,15 @@ void readplayerstartcvars()
 
        g_weaponarena = 0;
        s = cvar_string("g_weaponarena");
-       if (s == "0")
+       if (s == "0" || s == "")
+       {
+               if(g_lms || g_ca)
+                       s = "most";
+       }
+
+       if (s == "off")
        {
+               // forcibly turn off weaponarena
        }
        else if (s == "all")
        {
@@ -1530,8 +1535,12 @@ void precache_playermodel(string m)
        precache_model(m);
        if(sv_loddistance1)
        {
-               precache_model(strcat(substring(m, 0, -5), "_lod1", substring(m, -4, -1)));
-               precache_model(strcat(substring(m, 0, -5), "_lod2", substring(m, -4, -1)));
+               f = strcat(substring(m, 0, -5), "_lod1", substring(m, -4, -1));
+               if(fexists(f))
+                       precache_model(f);
+               f = strcat(substring(m, 0, -5), "_lod2", substring(m, -4, -1));
+               if(fexists(f))
+                       precache_model(f);
        }
 
        globhandle = search_begin(strcat(m, "_*.sounds"), TRUE, FALSE);