]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Apply the accurate impact effect logic to all hitscan weapons
authorMario <mario@smbclan.net>
Sat, 27 Jul 2019 02:33:45 +0000 (12:33 +1000)
committerMario <mario@smbclan.net>
Sat, 27 Jul 2019 02:33:45 +0000 (12:33 +1000)
qcsrc/common/effects/qc/damageeffects.qc

index 5dd3e4c8271555ca0993333c7682d5ae3f6054aa..17f48136a6c0a4126f1ae96bf172c89fc63b9d4d 100644 (file)
@@ -392,7 +392,7 @@ NET_HANDLE(ENT_CLIENT_DAMAGEINFO, bool isNew)
                w_random = prandom();
 
                traceline(w_org - normalize(force) * 16, w_org + normalize(force) * 16, MOVE_NOMONSTERS, NULL);
-               if(trace_fraction < 1 && hitwep != WEP_VORTEX && hitwep != WEP_VAPORIZER)
+               if(trace_fraction < 1 && !(hitwep.spawnflags & WEP_TYPE_HITSCAN))
                        w_backoff = trace_plane_normal;
                else
                        w_backoff = -1 * normalize(force);