]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge branch 'master' into mirceakitsune/universal_reload_system
authorMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Thu, 10 Mar 2011 14:09:50 +0000 (16:09 +0200)
committerMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Thu, 10 Mar 2011 14:09:50 +0000 (16:09 +0200)
1  2 
qcsrc/server/miscfunctions.qc

index 463137ed4e5c9b129f2a0f193e347fbfdfb38816,4f6d9868faa4901296c86868f9740d186ad1873d..4cf479fa9fdaf34896db02d29aa555d8ade6a77d
@@@ -921,7 -921,11 +921,11 @@@ void readplayerstartcvars(
                        s = "most";
        }
  
-       if (s == "off")
+       if (s == "0" || s == "")
+       {
+               // no arena
+       }
+       else if (s == "off")
        {
                // forcibly turn off weaponarena
        }
        }
        else if(start_items & IT_UNLIMITED_WEAPON_AMMO)
        {
-               for (j = WEP_FIRST; j <= WEP_LAST; ++j)
-               {
-                       e = get_weaponinfo(j);
-                       if(start_weapons & e.weapons)
-                       {
-                               if(e.items & IT_ROCKETS)
-                                       start_ammo_rockets = 999;
-                               if(e.items & IT_SHELLS)
-                                       start_ammo_shells = 999;
-                               if(e.items & IT_CELLS)
-                                       start_ammo_cells = 999;
-                               if(e.items & IT_NAILS)
-                                       start_ammo_nails = 999;
-                               if(e.items & IT_FUEL)
-                                       start_ammo_fuel = 999;
-                       }
-               }
+               start_ammo_rockets = 999;
+               start_ammo_shells = 999;
+               start_ammo_cells = 999;
+               start_ammo_nails = 999;
+               start_ammo_fuel = 999;
        }
        else
        {
@@@ -1664,7 -1656,6 +1656,7 @@@ void precache(
      precache_model ("models/sprites/10.spr32");
  
      // common weapon precaches
 +      precache_sound ("weapons/reload.wav"); // until weapons have individual reload sounds, precache the reload sound here
      precache_sound ("weapons/weapon_switch.wav");
      precache_sound ("weapons/weaponpickup.wav");
      precache_sound ("weapons/unavailable.wav");