]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/g_world.qc
Merge branch 'master' into mirceakitsune/universal_reload_system
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / g_world.qc
index ffbc58e32004f50933075a02aa9a2ea0cf9247ba..57d0071d2f063d78c0a5a9031f7b087ca795ac8f 100644 (file)
@@ -826,6 +826,8 @@ void spawnfunc_worldspawn (void)
        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_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);
 
        addstat(STAT_NEX_CHARGE, AS_FLOAT, nex_charge);
        addstat(STAT_NEX_CHARGEPOOL, AS_FLOAT, nex_chargepool_ammo);
 
        addstat(STAT_NEX_CHARGE, AS_FLOAT, nex_charge);
        addstat(STAT_NEX_CHARGEPOOL, AS_FLOAT, nex_chargepool_ammo);
@@ -2841,16 +2843,16 @@ void EndFrame()
                if(self.classname == "spectator")
                {
                        if(self.enemy.typehitsound)
                if(self.classname == "spectator")
                {
                        if(self.enemy.typehitsound)
-                               play2(self, "misc/typehit.wav");
+                               self.typehit_time = time;
                        else if(self.enemy.hitsound && self.cvar_cl_hitsound)
                        else if(self.enemy.hitsound && self.cvar_cl_hitsound)
-                               play2(self, "misc/hit.wav");
+                               self.hit_time = time;
                }
                else
                {
                        if(self.typehitsound)
                }
                else
                {
                        if(self.typehitsound)
-                               play2(self, "misc/typehit.wav");
+                               self.typehit_time = time;
                        else if(self.hitsound && self.cvar_cl_hitsound)
                        else if(self.hitsound && self.cvar_cl_hitsound)
-                               play2(self, "misc/hit.wav");
+                               self.hit_time = time;
                }
        }
        altime = time + frametime * (1 + autocvar_g_antilag_nudge);
                }
        }
        altime = time + frametime * (1 + autocvar_g_antilag_nudge);