From e878c57099a1215e3452c81c59ab475e4b5bb35e Mon Sep 17 00:00:00 2001 From: Mario Date: Wed, 12 Oct 2016 03:00:41 +1000 Subject: [PATCH] Reset viewloc when respawning, and link it with spectatee (should fix spectating sidescrollers) --- qcsrc/server/client.qc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index ad7b4e8fb..1735a78be 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -625,6 +625,8 @@ void PutClientInServer(entity this) FixPlayermodel(this); this.drawonlytoclient = NULL; + this.viewloc = NULL; + this.crouch = false; this.view_ofs = STAT(PL_VIEW_OFS, this); setsize(this, STAT(PL_MIN, this), STAT(PL_MAX, this)); @@ -1672,6 +1674,7 @@ void SpectateCopy(entity this, entity spectatee) this.angles = spectatee.v_angle; STAT(FROZEN, this) = STAT(FROZEN, spectatee); this.revive_progress = spectatee.revive_progress; + this.viewloc = spectatee.viewloc; if(!PHYS_INPUT_BUTTON_USE(this) && STAT(CAMERA_SPECTATOR, this) != 2) this.fixangle = true; setorigin(this, spectatee.origin); -- 2.39.2