if(spectatee_status >= 0 && (autocvar_cl_eventchase_death && getstati(STAT_HEALTH) <= 0 && !intermission) || intermission)
{
// make special vector since we can't use view_origin (It is one frame old as of this code, it gets set later with the results this code makes.)
- vector current_view_origin = (getpropertyvec(VF_ORIGIN) + autocvar_sv_player_spectate_viewoffset);
+ vector current_view_origin = (getpropertyvec(VF_ORIGIN) + autocvar_sv_spectator_viewoffset);
// We must enable chase_active to get a third person view (weapon viewmodel hidden and own player model showing).
// Ideally, there should be another way to enable third person cameras, such as through setproperty()
makevectors(view_angles);
vector eventchase_target_origin = (current_view_origin - (v_forward * eventchase_current_distance));
- WarpZone_TraceBox(current_view_origin, autocvar_sv_player_spectate_mins, autocvar_sv_player_spectate_maxs, eventchase_target_origin, MOVE_WORLDONLY, self);
+ WarpZone_TraceBox(current_view_origin, autocvar_sv_spectator_mins, autocvar_sv_spectator_maxs, eventchase_target_origin, MOVE_WORLDONLY, self);
setproperty(VF_ORIGIN, ((trace_startsolid) ? current_view_origin : trace_endpos));
setproperty(VF_ANGLES, WarpZone_TransformVAngles(WarpZone_trace_transform, view_angles));
noref var vector autocvar_sv_player_crouch_maxs = '16 16 25';
noref var vector autocvar_sv_player_crouch_mins = '-16 -16 -24';
noref var vector autocvar_sv_player_crouch_viewoffset = '0 0 20';
-noref var vector autocvar_sv_player_spectate_maxs = '12 12 8';
-noref var vector autocvar_sv_player_spectate_mins = '-12 -12 -8';
-noref var vector autocvar_sv_player_spectate_viewoffset = '0 0 20';
noref var vector autocvar_sv_player_headsize = '24 24 12';
+noref var vector autocvar_sv_spectator_maxs = '12 12 8';
+noref var vector autocvar_sv_spectator_mins = '-12 -12 -8';
+noref var vector autocvar_sv_spectator_viewoffset = '0 0 20';
+
#define PL_VIEW_OFS autocvar_sv_player_viewoffset
#define PL_MIN autocvar_sv_player_mins
#define PL_MAX autocvar_sv_player_maxs
self.fixangle = TRUE;
self.crouch = FALSE;
- setorigin (self, (spot.origin + PL_VIEW_OFS)); // offset it so that the spectator spawns higher off the ground, looks better this way
+ setorigin (self, (spot.origin + autocvar_sv_spectator_viewoffset)); // offset it so that the spectator spawns higher off the ground, looks better this way
self.prevorigin = self.origin;
self.items = 0;
WEPSET_CLEAR_E(self);
setmodel(self, "null");
self.drawonlytoclient = self;
- setsize (self, PL_CROUCH_MIN, PL_CROUCH_MAX); // give the spectator some space between walls for MOVETYPE_FLY_WORLDONLY
+ setsize (self, autocvar_sv_spectator_mins, autocvar_sv_spectator_maxs); // give the spectator some space between walls for MOVETYPE_FLY_WORLDONLY
self.view_ofs = '0 0 0'; // so that your view doesn't go into the ceiling with MOVETYPE_FLY_WORLDONLY, previously "PL_VIEW_OFS"
self.weapon = 0;