]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Remove useless returns on attack and attack2. There are several other checks that...
authorMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Fri, 21 Jan 2011 21:40:52 +0000 (23:40 +0200)
committerMircea Kitsune <sonichedgehog_hyperblast00@yahoo.com>
Fri, 21 Jan 2011 21:40:52 +0000 (23:40 +0200)
qcsrc/server/w_grenadelauncher.qc
qcsrc/server/w_minelayer.qc
qcsrc/server/w_shotgun.qc
qcsrc/server/w_sniperrifle.qc
qcsrc/server/w_uzi.qc

index 055376543ed220dc8762fefbc126f3de816d3bd4..d252c1f1ca2421f566e11d65292ad41cdd469862 100644 (file)
@@ -213,9 +213,6 @@ void W_Grenade_Touch2 (void)
 
 void W_Grenade_Attack (void)
 {
 
 void W_Grenade_Attack (void)
 {
-       if(autocvar_g_balance_grenadelauncher_reload_ammo && self.clip_load <= 0)
-               return; // reloading, so we are done
-
        local entity gren;
 
        W_SetupShot_ProjectileSize (self, '-3 -3 -3', '3 3 3', FALSE, 4, "weapons/grenade_fire.wav", CHAN_WEAPON, autocvar_g_balance_grenadelauncher_primary_damage);
        local entity gren;
 
        W_SetupShot_ProjectileSize (self, '-3 -3 -3', '3 3 3', FALSE, 4, "weapons/grenade_fire.wav", CHAN_WEAPON, autocvar_g_balance_grenadelauncher_primary_damage);
index 76b47c6bd7e9fa7ee48be4d2d7b93f76c5a19500..691eccfe1cef2cf78f4d1d450ae19935e8f2c1fd 100644 (file)
@@ -249,9 +249,6 @@ void W_Mine_Damage (entity inflictor, entity attacker, float damage, float death
 
 void W_Mine_Attack (void)
 {
 
 void W_Mine_Attack (void)
 {
-       if(autocvar_g_balance_minelayer_reload_ammo && self.clip_load <= 0)
-               return; // reloading, so we are done
-
        entity mine;
        entity flash;
 
        entity mine;
        entity flash;
 
index 2d26b183d2441f465d3ee2e500b9349052645b75..2bee7080d19caa7666d60bdf553af7a1d68cd8c0 100644 (file)
@@ -69,9 +69,6 @@ void W_Shotgun_Attack (void)
        float   bulletconstant;
        local entity flash;
 
        float   bulletconstant;
        local entity flash;
 
-       if(autocvar_g_balance_shotgun_reload_ammo && self.clip_load <= 0)
-               return; // reloading, so we are done
-
        ammoamount = autocvar_g_balance_shotgun_primary_ammo;
        bullets = autocvar_g_balance_shotgun_primary_bullets;
        d = autocvar_g_balance_shotgun_primary_damage;
        ammoamount = autocvar_g_balance_shotgun_primary_ammo;
        bullets = autocvar_g_balance_shotgun_primary_bullets;
        d = autocvar_g_balance_shotgun_primary_damage;
index 9df76a95170afd723586bfa5897b7d146ea6b528..469b2db0b140505c4ce684fd588ec16852622778 100644 (file)
@@ -127,9 +127,6 @@ void W_SniperRifle_BulletHail_Continue()
 {
        float r, sw, af;
 
 {
        float r, sw, af;
 
-       if(autocvar_g_balance_sniperrifle_reload_ammo && self.clip_load <= 0)
-               return; // reloading, so we are done
-
        sw = self.switchweapon; // make it not detect weapon changes as reason to abort firing
        af = ATTACK_FINISHED(self);
        self.switchweapon = self.weapon;
        sw = self.switchweapon; // make it not detect weapon changes as reason to abort firing
        af = ATTACK_FINISHED(self);
        self.switchweapon = self.weapon;
index 8681c204cdd5009f9bff4ed89c96d177de7d4e1b..4693b584227136fb484441e5b6d205c817fd18fc 100644 (file)
@@ -95,9 +95,6 @@ void UziFlash()
 
 void W_Uzi_Attack (float deathtype)
 {
 
 void W_Uzi_Attack (float deathtype)
 {
-       if(autocvar_g_balance_uzi_reload_ammo && self.clip_load <= 0)
-               return; // reloading, so we are done
-
        W_SetupShot (self, autocvar_g_antilag_bullets && autocvar_g_balance_uzi_speed >= autocvar_g_antilag_bullets, 0, "weapons/uzi_fire.wav", CHAN_WEAPON, ((self.misc_bulletcounter == 1) ? autocvar_g_balance_uzi_first_damage : autocvar_g_balance_uzi_sustained_damage));
        if (!g_norecoil)
        {
        W_SetupShot (self, autocvar_g_antilag_bullets && autocvar_g_balance_uzi_speed >= autocvar_g_antilag_bullets, 0, "weapons/uzi_fire.wav", CHAN_WEAPON, ((self.misc_bulletcounter == 1) ? autocvar_g_balance_uzi_first_damage : autocvar_g_balance_uzi_sustained_damage));
        if (!g_norecoil)
        {