From: Martin Taibr Date: Thu, 8 Jun 2017 13:42:27 +0000 (+0200) Subject: remove multiple declarations of v_angle, document usage of v_angle and angles X-Git-Tag: xonotic-v0.8.5~2526^2~5 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=f028b7258d7a7312b83f4c2b3894cfbc849cfe4f;p=xonotic%2Fxonotic-data.pk3dir.git remove multiple declarations of v_angle, document usage of v_angle and angles --- diff --git a/qcsrc/client/player_skeleton.qc b/qcsrc/client/player_skeleton.qc index 66827c8f3..d01f3feff 100644 --- a/qcsrc/client/player_skeleton.qc +++ b/qcsrc/client/player_skeleton.qc @@ -5,7 +5,6 @@ #include "../lib/csqcmodel/cl_player.qh" #include "../lib/warpzone/anglestransform.qh" -.vector v_angle; .float v_angle_save_x; class(Skeleton) .float skeleton_info_modelindex; diff --git a/qcsrc/common/csqcmodel_settings.qh b/qcsrc/common/csqcmodel_settings.qh index 9c4909671..9cbcb8696 100644 --- a/qcsrc/common/csqcmodel_settings.qh +++ b/qcsrc/common/csqcmodel_settings.qh @@ -26,9 +26,6 @@ # define TAG_VIEWLOC_TYPE entity #endif -// new fields -.vector v_angle; - // add properties you want networked to CSQC here #define CSQCMODEL_EXTRAPROPERTIES \ CSQCMODEL_PROPERTY(BIT(0), int, ReadShort, WriteShort, colormap) \ diff --git a/qcsrc/common/physics/player.qh b/qcsrc/common/physics/player.qh index 39cc573ee..b5b016c7e 100644 --- a/qcsrc/common/physics/player.qh +++ b/qcsrc/common/physics/player.qh @@ -190,6 +190,9 @@ STATIC_INIT(PHYS_INPUT_BUTTON_DODGE) .int items; .vector movement; + + // angles of the player's view (as opposed to his model which uses `.vector angles;`) + // x is pitch, y is yaw, z is roll .vector v_angle; .entity hook; diff --git a/qcsrc/lib/angle.qc b/qcsrc/lib/angle.qc index f921d74b0..09e267fe4 100644 --- a/qcsrc/lib/angle.qc +++ b/qcsrc/lib/angle.qc @@ -1,4 +1,7 @@ .vector origin; + +// angles of the player's model (as opposed to his view which uses `.vector v_angle;`) +// x is pitch, y is yaw, z is roll .vector angles; /* diff --git a/qcsrc/lib/csqcmodel/interpolate.qh b/qcsrc/lib/csqcmodel/interpolate.qh index 3ea385cbc..94af86340 100644 --- a/qcsrc/lib/csqcmodel/interpolate.qh +++ b/qcsrc/lib/csqcmodel/interpolate.qh @@ -45,6 +45,3 @@ void InterpolateOrigin_Reset(entity this); // call this BEFORE drawing void InterpolateOrigin_Do(entity this); - -// in case we interpolate that: -.vector v_angle;