]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/g_world.qc
Merge remote-tracking branch 'origin/mirceakitsune/weapon_hagar_secondary_load'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / g_world.qc
index 51c98ec46274982be1335595a14fdcf58718d0ee..0b178c8c13e9823b78ac5c3465404e2050052e70 100644 (file)
@@ -823,7 +823,8 @@ void spawnfunc_worldspawn (void)
        addstat(STAT_FUEL, AS_INT, ammo_fuel);
        addstat(STAT_SHOTORG, AS_INT, stat_shotorg);
        addstat(STAT_LEADLIMIT, AS_FLOAT, stat_leadlimit);
-       addstat(STAT_BULLETS_LOADED, AS_INT, sniperrifle_bulletcounter);
+       addstat(STAT_WEAPON_CLIPLOAD, AS_INT, clip_load);
+       addstat(STAT_WEAPON_CLIPSIZE, AS_INT, clip_size);
        addstat(STAT_LAST_PICKUP, AS_FLOAT, last_pickup);
        addstat(STAT_HIT_TIME, AS_FLOAT, hit_time);
        addstat(STAT_TYPEHIT_TIME, AS_FLOAT, typehit_time);
@@ -832,6 +833,8 @@ void spawnfunc_worldspawn (void)
        addstat(STAT_NEX_CHARGE, AS_FLOAT, nex_charge);
        addstat(STAT_NEX_CHARGEPOOL, AS_FLOAT, nex_chargepool_ammo);
 
+       addstat(STAT_HAGAR_LOAD, AS_INT, hagar_load);
+
        if(g_ca || g_freezetag)
        {
                addstat(STAT_REDALIVE, AS_INT, redalive_stat);
@@ -916,8 +919,12 @@ void spawnfunc_worldspawn (void)
        // fill sv_curl_serverpackages from .serverpackage files
        if(autocvar_sv_curl_serverpackages_auto)
        {
-               fd = search_begin("*.serverpackage", TRUE, FALSE);
                s = "";
+               n = tokenize_console(cvar_string("sv_curl_serverpackages"));
+               for(i = 0; i < n; ++i)
+                       if(substring(argv(i), -14, -1) != ".serverpackage")
+                               s = strcat(s, " ", argv(i));
+               fd = search_begin("*.serverpackage", TRUE, FALSE);
                if(fd >= 0)
                {
                        j = search_getsize(fd);
@@ -1436,7 +1443,6 @@ void DumpStats(float final)
        float to_eventlog;
        float to_file;
        float i;
-       entity e;
 
        to_console = autocvar_sv_logscores_console;
        to_eventlog = autocvar_sv_eventlog;
@@ -2844,14 +2850,14 @@ void EndFrame()
                {
                        if(self.enemy.typehitsound)
                                self.typehit_time = time;
-                       else if(self.enemy.hitsound && self.cvar_cl_hitsound)
+                       else if(self.enemy.hitsound)
                                self.hit_time = time;
                }
                else
                {
                        if(self.typehitsound)
                                self.typehit_time = time;
-                       else if(self.hitsound && self.cvar_cl_hitsound)
+                       else if(self.hitsound)
                                self.hit_time = time;
                }
        }