]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Client code already knows g_trueaim_minrange, use that global
authorSamual Lenks <samual@xonotic.org>
Tue, 18 Feb 2014 23:37:44 +0000 (18:37 -0500)
committerSamual Lenks <samual@xonotic.org>
Tue, 18 Feb 2014 23:37:44 +0000 (18:37 -0500)
qcsrc/client/particles.qc

index 5558d8b94090f96948d54066ceef7e352d89f53c..35304e6467cd52b3e7f06b1d35994a5822b0be4e 100644 (file)
@@ -413,8 +413,8 @@ void Draw_ArcBeam()
                view_up = vu;
 
                // un-adjust trueaim if shotend is too close
-               if(vlen(shothitpos - view_origin) < cvar("g_trueaim_minrange"))
-                       shothitpos = view_origin + (view_forward * cvar("g_trueaim_minrange"));
+               if(vlen(shothitpos - view_origin) < g_trueaim_minrange)
+                       shothitpos = view_origin + (view_forward * g_trueaim_minrange);
 
                // move shot origin to the actual gun muzzle origin
                vector origin_offset = view_forward * self.beam_shotorigin_x + view_right * -self.beam_shotorigin_y + view_up * self.beam_shotorigin_z;