]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Cvar the two chase cam types
authorMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Sat, 26 Mar 2011 16:18:47 +0000 (18:18 +0200)
committerMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Sat, 26 Mar 2011 16:18:47 +0000 (18:18 +0200)
defaultXonotic.cfg
qcsrc/client/View.qc
qcsrc/client/autocvars.qh

index a500cec9e1de073eb1ee156411b092c5ff1e0b69..472d9e90f53dd875ccf2a09bce70b938361c1823 100644 (file)
@@ -316,6 +316,9 @@ set sv_ready_restart_repeatable 0   "allows the players to restart the game as oft
 seta cl_hitsound 1 "play a hit notifier sound when you have hit an enemy"
 set cl_hitsound_antispam_time 0.05 "don't play the hitsound more often than this"
 
+seta cl_chase_death 1 "camera goes into 3rd person mode when dead"
+seta cl_chase_intermission 1 "camera goes into 3rd person mode at match end"
+
 //nifreks lockonrestart feature, used in team-based game modes, if set to 1 and all players readied up no other player can then join the game anymore, useful to block spectators from joining
 set teamplay_lockonrestart 0 "it set to 1 in a team-based game, the teams are locked once all players readied up and the game restarted (no new players can join after restart unless using the server-command unlockteams)"
 
index c2097524ea1dc202e8aff6345fa8e921e4a0321b..3b44a42391d035bacb64072f434e69ea0acaa69d 100644 (file)
@@ -794,9 +794,9 @@ void CSQC_UpdateView(float w, float h)
                        drawpic(splash_pos, "gfx/blood", splash_size, stov(autocvar_hud_damage_color), bound(0, myhealth_flash_temp, 1) * autocvar_hud_damage, DRAWFLAG_NORMAL);
        }
 
-       if(spectatee_status >= 0)
+       if(spectatee_status >= 0 && (autocvar_cl_chase_death || autocvar_cl_chase_intermission))
        {
-               if((getstati(STAT_HEALTH) <= 0 && !intermission) || (intermission))
+               if((autocvar_cl_chase_death && getstati(STAT_HEALTH) <= 0 && !intermission) || (autocvar_cl_chase_intermission && intermission))
                {
                        if(!cvar("chase_active"))
                                cvar_set("chase_active", "1");
index d380c7fc30902052883a2bc6449cb87cc2fb49b0..8989762ecf39f5d923fa548a7be8951c091d5416 100644 (file)
@@ -305,3 +305,5 @@ float autocvar_viewsize;
 float autocvar_crosshair_color_by_health;
 float autocvar_cl_hitsound;
 float autocvar_cl_hitsound_antispam_time;
+float autocvar_cl_chase_death;
+float autocvar_cl_chase_intermission;