]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/weapons/accuracy.qc
Remove the null weapon check from W_SetupShot and make sure accuracy_add doesn't...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / weapons / accuracy.qc
index c0441ca162a375e20daa917385a118539f12e18b..1eda4e25b1066c86831ef2cb679bccd7993a6ce8 100644 (file)
@@ -67,6 +67,7 @@ void accuracy_add(entity this, int w, int fired, int hit)
        entity a = CS(this).accuracy;
        if (!a) return;
        if (!hit && !fired) return;
+       if (w == WEP_Null.m_id) return;
        w -= WEP_FIRST;
        int b = accuracy_byte(a.accuracy_hit[w], a.accuracy_fired[w]);
        if (hit)    a.accuracy_hit  [w] += hit;