From 8218efcc8f3b41ae9b9dd3f1ec954176c1a269b0 Mon Sep 17 00:00:00 2001 From: Mario Date: Mon, 27 Jul 2020 17:59:59 +1000 Subject: [PATCH] Don't perform trueaim tracing on the client side when drawing muzzle flashes, accurate shot position is not necessary --- qcsrc/common/weapons/all.qc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/qcsrc/common/weapons/all.qc b/qcsrc/common/weapons/all.qc index 9feb5ffe4..6e5539d9a 100644 --- a/qcsrc/common/weapons/all.qc +++ b/qcsrc/common/weapons/all.qc @@ -803,10 +803,8 @@ NET_HANDLE(w_muzzleflash, bool isNew) vector md = wepent.movedir_aligned; vector vecs = ((md.x > 0) ? md : '0 0 0'); - vector dv = right * -vecs.y + up * vecs.z; + vector dv = forward * vecs.x + right * -vecs.y + up * vecs.z; vector org = rlplayer.origin + rlplayer.view_ofs + dv; - tracebox(org, '0 0 0', '0 0 0', org + forward * (vecs.x + 1), MOVE_NORMAL, rlplayer); - org = trace_endpos - forward * 1; pointparticles(thiswep.m_muzzleeffect, org, forward * 1000, 1); -- 2.39.2