]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix the exception for hagar W_CheckProjectileDamage function (previously was overridi...
authorSamual <samual@xonotic.org>
Wed, 5 Oct 2011 04:28:47 +0000 (00:28 -0400)
committerSamual <samual@xonotic.org>
Wed, 5 Oct 2011 04:28:47 +0000 (00:28 -0400)
qcsrc/server/w_hagar.qc

index 76d2f9414aef874b2a883460bd22c64d3d0867d9..7d9db5c39fb67f9aeb00031712997cbd1fa0a85a 100644 (file)
@@ -26,8 +26,13 @@ void W_Hagar_Damage (entity inflictor, entity attacker, float damage, float deat
                return;
                
        float is_linkexplode = ((inflictor.realowner == self.realowner) 
-               && ((inflictor.projectiledeathtype & HITTYPE_SECONDARY) && (self.projectiledeathtype & HITTYPE_SECONDARY))
-               && autocvar_g_balance_hagar_secondary_load_linkexplode);
+               && (inflictor.projectiledeathtype & HITTYPE_SECONDARY) 
+               && (self.projectiledeathtype & HITTYPE_SECONDARY));
+       
+       if(is_linkexplode)
+               is_linkexplode = (is_linkexplode && autocvar_g_balance_hagar_secondary_load_linkexplode);
+       else
+               is_linkexplode = -1; // not secondary load, so continue as normal without exception.
                
        if (!W_CheckProjectileDamage(inflictor.realowner, self.realowner, deathtype, is_linkexplode))
                return; // g_projectiles_damage says to halt