]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mapobjects/trigger/viewloc.qc
Add Read/WriteAngleVector macros to simplify the networking of angles
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mapobjects / trigger / viewloc.qc
index ba5dcbe443ea4c26e955adfa68b9f997eb0f8d69..354d36cb765ccfe72cc780949de7ab7e44bd3629 100644 (file)
@@ -125,9 +125,7 @@ bool viewloc_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;
 }
@@ -200,9 +198,7 @@ NET_HANDLE(ENT_CLIENT_VIEWLOC, bool isnew)
        this.origin = ReadVector();
        setorigin(this, this.origin);
 
-       this.movedir_x = ReadAngle();
-       this.movedir_y = ReadAngle();
-       this.movedir_z = ReadAngle();
+       this.movedir = ReadAngleVector();
 
        return = true;