]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc
Add Read/WriteAngleVector macros to simplify the networking of angles
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / gamemodes / gamemode / onslaught / sv_onslaught.qc
index 1f3e43378c71919fce84baf73f2d26e2e59d4587..170845298ff1eb1e4a8891c5073d9c7a97d092bf 100644 (file)
@@ -39,9 +39,7 @@ bool clientcamera_send(entity this, entity to, int sf)
 
        WriteVector(MSG_ENTITY, this.origin);
 
-       WriteAngle(MSG_ENTITY, this.angles_x);
-       WriteAngle(MSG_ENTITY, this.angles_y);
-       WriteAngle(MSG_ENTITY, this.angles_z);
+       WriteAngleVector(MSG_ENTITY, this.angles);
 
        return true;
 }
@@ -876,6 +874,7 @@ void ons_camSetup(entity this)
 
        FOREACH_CLIENT(true, it.clientcamera = cam;);
 
+       // NOTE: engine networked
        WriteByte(MSG_ALL, SVC_SETVIEWANGLES);
        WriteAngle(MSG_ALL, cam.angles_x);
        WriteAngle(MSG_ALL, cam.angles_y);