]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/cl_weaponsystem.qc
sign the HTTP requests
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / cl_weaponsystem.qc
index f5fc4a33aab3f42c8ba22d5c9702d1bf95da2813..3d7a33278d15201ce89b789f1a03f9441e0d0be8 100644 (file)
@@ -255,7 +255,7 @@ void W_SetupShot_Dir_ProjectileSize_Range(entity ent, vector s_forward, vector m
                (time > ent.prevstrengthsoundattempt + autocvar_sv_strengthsound_antispam_refire_threshold)
        ) // prevent insane sound spam
        {
-               sound(ent, CHAN_AUTO, "weapons/strength_fire.wav", VOL_BASE, ATTN_NORM);
+               sound(ent, CH_TRIGGER, "weapons/strength_fire.wav", VOL_BASE, ATTN_NORM);
                ent.prevstrengthsound = time;
        }
        ent.prevstrengthsoundattempt = time;
@@ -986,7 +986,8 @@ float client_hasweapon(entity cl, float wpn, float andammo, float complain)
                                                world, e.origin,
                                                self, 0,
                                                world, enemy,
-                                               0
+                                               0,
+                                               RADARICON_NONE, '0 0 0'
                                        );
                                }
                        }
@@ -1062,7 +1063,7 @@ float weapon_prepareattack_checkammo(float secondary)
 
                if(self.weapon == self.switchweapon && time - self.prevdryfire > 1) // only play once BEFORE starting to switch weapons
                {
-                       sound (self, CHAN_AUTO, "weapons/dryfire.wav", VOL_BASE, ATTN_NORM);
+                       sound (self, CH_WEAPON_A, "weapons/dryfire.wav", VOL_BASE, ATTN_NORM);
                        self.prevdryfire = time;
                }
 
@@ -1260,18 +1261,19 @@ void weapon_thinkf(float fr, float t, void() func)
        self.weapon_think = func;
        //dprint("next ", ftos(self.weapon_nextthink), "\n");
 
-    // The shoot animation looks TERRIBLE without animation blending! Yay for moonwalking while shooting!
+       // The shoot animation looks TERRIBLE without animation blending! Yay for moonwalking while shooting!
+       //anim = self.anim_shoot;
        if (restartanim)
        if (t)
        if (!self.crouch) // shoot anim stands up, this looks bad
        {
-               local vector anim;
+               vector anim;
                if(self.weapon == WEP_SHOTGUN && self.BUTTON_ATCK2)
+               {
                        anim = self.anim_melee;
-               /*else
-                       anim = self.anim_shoot;*/
-               anim_z = anim_y / (t + sys_frametime);
-               setanim(self, anim, FALSE, TRUE, TRUE);
+                       anim_z = anim_y / (t + sys_frametime);
+                       setanim(self, anim, FALSE, TRUE, TRUE);
+               }
        }
 };
 
@@ -1731,7 +1733,7 @@ void W_Reload(float sent_ammo_min, float sent_ammo_amount, float sent_time, stri
 
        // now begin the reloading process
 
-       sound (self, CHAN_WEAPON2, self.reload_sound, VOL_BASE, ATTN_NORM);
+       sound (self, CH_WEAPON_B, self.reload_sound, VOL_BASE, ATTN_NORM);
 
        // do not set ATTACK_FINISHED in reload code any more. This causes annoying delays if eg: You start reloading a weapon,
        // then quickly switch to another weapon and back. Reloading is canceled, but the reload delay is still there,