]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/dpdefs/dpextensions.qh
Replace more `vector_[xyz]` with `vector.[xyz]`
[xonotic/xonotic-data.pk3dir.git] / qcsrc / dpdefs / dpextensions.qh
index 7a7c3cb0f6e998e34ffa238fda2dd78d2a1be48d..6be1efcb38286a11fc6a8465e214e276a2f5d314 100644 (file)
@@ -2036,10 +2036,10 @@ void(entity own, vector start, vector end) te_beam = #431;
 //idea: LordHavoc
 //darkplaces implementation: LordHavoc
 //globals:
-.float dphitcontentsmask; // if non-zero on the entity passed to traceline/tracebox/tracetoss this will override the normal collidable contents rules and instead hit these contents values (for example AI can use tracelines that hit DONOTENTER if it wants to, by simply changing this field on the entity passed to traceline), this affects normal movement as well as trace calls
-float trace_dpstartcontents; // DPCONTENTS_ value at start position of trace
-float trace_dphitcontents; // DPCONTENTS_ value of impacted surface (not contents at impact point, just contents of the surface that was hit)
-float trace_dphitq3surfaceflags; // Q3SURFACEFLAG_ value of impacted surface
+.int dphitcontentsmask; // if non-zero on the entity passed to traceline/tracebox/tracetoss this will override the normal collidable contents rules and instead hit these contents values (for example AI can use tracelines that hit DONOTENTER if it wants to, by simply changing this field on the entity passed to traceline), this affects normal movement as well as trace calls
+int trace_dpstartcontents; // DPCONTENTS_ value at start position of trace
+int trace_dphitcontents; // DPCONTENTS_ value of impacted surface (not contents at impact point, just contents of the surface that was hit)
+int trace_dphitq3surfaceflags; // Q3SURFACEFLAG_ value of impacted surface
 string trace_dphittexturename; // texture name of impacted surface
 //constants:
 const int DPCONTENTS_SOLID = 1; // hit a bmodel, not a bounding box
@@ -2260,9 +2260,9 @@ void(vector eyetarget, string bonename) example_skel_player_update_eyetarget =
        vector oldup = v_up;
        vector v = eyetarget - self.origin;
        vector modeleyetarget;
-       modeleyetarget_x =   v * v_forward;
-       modeleyetarget_y = 0-v * v_right;
-       modeleyetarget_z =   v * v_up;
+       modeleyetarget.x =   v * v_forward;
+       modeleyetarget.y = 0-v * v_right;
+       modeleyetarget.z =   v * v_up;
        // this is an eyeball, make it point at the target location
        // first get all the data we can...
        vector relorg = skel_get_bonerel(self.skeletonindex, bonenum);
@@ -2280,11 +2280,11 @@ void(vector eyetarget, string bonename) example_skel_player_update_eyetarget =
        // get the vector from the eyeball to the target
        vector u = modeleyetarget - boneorg;
        // now transform it inversely by the parent matrix to produce new rel vectors
-       v_x = u * parentforward;
-       v_y = u * parentright;
-       v_z = u * parentup;
+       v.x = u * parentforward;
+       v.y = u * parentright;
+       v.z = u * parentup;
        vector ang = vectoangles2(v, relup);
-       ang_x = 0 - ang.x;
+       ang.x = 0 - ang.x;
        makevectors(ang);
        // set the relative bone matrix
        skel_set_bone(self.skeletonindex, bonenum, relorg);