]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix view snapping as a vehicle spectator
authorMario <mario@smbclan.net>
Tue, 5 Jul 2016 09:01:41 +0000 (19:01 +1000)
committerMario <mario@smbclan.net>
Tue, 5 Jul 2016 09:01:41 +0000 (19:01 +1000)
qcsrc/server/cl_client.qc

index 1cc143d748cd603d32e6365a3e43fe590152a866..146209528db92a1b08f8079249c4df41c58b6c69 100644 (file)
@@ -1623,7 +1623,9 @@ void SpectateCopy(entity this, entity spectatee)
        this.hud = spectatee.hud;
        if(spectatee.vehicle)
     {
-        this.fixangle = false;
+       this.angles = spectatee.v_angle;
+
+        //this.fixangle = false;
         //this.velocity = spectatee.vehicle.velocity;
         this.vehicle_health = spectatee.vehicle_health;
         this.vehicle_shield = spectatee.vehicle_shield;
@@ -1633,12 +1635,12 @@ void SpectateCopy(entity this, entity spectatee)
         this.vehicle_reload1 = spectatee.vehicle_reload1;
         this.vehicle_reload2 = spectatee.vehicle_reload2;
 
-        msg_entity = this;
+        //msg_entity = this;
 
-        WriteByte (MSG_ONE, SVC_SETVIEWANGLES);
-            WriteAngle(MSG_ONE,  spectatee.v_angle.x);
-            WriteAngle(MSG_ONE,  spectatee.v_angle.y);
-            WriteAngle(MSG_ONE,  spectatee.v_angle.z);
+       // WriteByte (MSG_ONE, SVC_SETVIEWANGLES);
+            //WriteAngle(MSG_ONE,  spectatee.v_angle.x);
+           // WriteAngle(MSG_ONE,  spectatee.v_angle.y);
+           // WriteAngle(MSG_ONE,  spectatee.v_angle.z);
 
         //WriteByte (MSG_ONE, SVC_SETVIEW);
         //    WriteEntity(MSG_ONE, this);