v_up = vu;
// un-adjust trueaim if shotend is too close
- if(vlen(w_shotend - (ent.origin + ent.view_ofs)) < autocvar_g_trueaim_minrange)
+ if(vdist(w_shotend - (ent.origin + ent.view_ofs), <, autocvar_g_trueaim_minrange))
w_shotend = ent.origin + ent.view_ofs + s_forward * autocvar_g_trueaim_minrange;
// track max damage
void fireBullet_trace_callback(vector start, vector hit, vector end)
{
- if(vlen(hit - start) > 16)
+ if(vdist(hit - start, >, 16))
trailparticles(world, fireBullet_trace_callback_eff, start, hit);
WarpZone_trace_forent = world;
fireBullet_last_hit = world;
// Only show effect when going through a player (invisible otherwise)
if (hit && (hit.solid != SOLID_BSP))
- if(vlen(trace_endpos - start) > 4)
+ if(vdist(trace_endpos - start, >, 4))
trailparticles(self, fireBullet_trace_callback_eff, start, trace_endpos);
start = trace_endpos;