]> git.xonotic.org Git - voretournament/voretournament.git/blobdiff - data/qcsrc/server/cl_weaponsystem.qc
Randomize all recoils and punch angles in several directions
[voretournament/voretournament.git] / data / qcsrc / server / cl_weaponsystem.qc
index e90c78e08ac99eeeeb45b23dc647eee4a90a5171..dedc00ba75aa1fe5cb1ec6eaefaf3d2c4e3ca8b3 100644 (file)
@@ -223,7 +223,10 @@ void W_SetupShot_Dir_ProjectileSize(entity ent, vector s_forward, vector mi, vec
        ent.dphitcontentsmask = oldsolid; // restore solid type (generally SOLID_SLIDEBOX)\r
 \r
        if (!g_norecoil)\r
-               ent.punchangle_x -= recoil;\r
+       {\r
+               ent.punchangle_x += crandom() * recoil;\r
+               ent.punchangle_y += crandom() * recoil;\r
+       }\r
 \r
        if (snd != "")\r
        {\r