mirror of
https://github.com/JezuzLizard/BO2-Reimagined.git
synced 2025-06-09 23:02:53 -05:00
Zombies: increase damage taken to make a crawler
This commit is contained in:
@ -79,6 +79,7 @@
|
||||
* Health capped at 100,000
|
||||
* Decreased damage from 60 to 50
|
||||
* Changed height to 60 (normally either 48 or 72)
|
||||
* Increased damage taken to make a crawler from 10% of current health to 25% of current health
|
||||
* Amount of zombies scales linearly with the amount of players
|
||||
* Zombies that are deleted due to being too far away always respawn
|
||||
* Attracted towards points of interest immediately
|
||||
|
@ -308,6 +308,72 @@ zombie_gib_on_damage()
|
||||
}
|
||||
}
|
||||
|
||||
zombie_should_gib( amount, attacker, type )
|
||||
{
|
||||
if ( !is_mature() )
|
||||
return false;
|
||||
|
||||
if ( !isdefined( type ) )
|
||||
return false;
|
||||
|
||||
if ( isdefined( self.is_on_fire ) && self.is_on_fire )
|
||||
return false;
|
||||
|
||||
if ( isdefined( self.no_gib ) && self.no_gib == 1 )
|
||||
return false;
|
||||
|
||||
switch ( type )
|
||||
{
|
||||
case "MOD_UNKNOWN":
|
||||
case "MOD_TRIGGER_HURT":
|
||||
case "MOD_TELEFRAG":
|
||||
case "MOD_SUICIDE":
|
||||
case "MOD_FALLING":
|
||||
case "MOD_CRUSH":
|
||||
case "MOD_BURNED":
|
||||
return false;
|
||||
|
||||
case "MOD_MELEE":
|
||||
return false;
|
||||
}
|
||||
|
||||
if ( type == "MOD_PISTOL_BULLET" || type == "MOD_RIFLE_BULLET" )
|
||||
{
|
||||
if ( !isdefined( attacker ) || !isplayer( attacker ) )
|
||||
return false;
|
||||
|
||||
weapon = attacker getcurrentweapon();
|
||||
|
||||
if ( weapon == "none" || weapon == level.start_weapon )
|
||||
return false;
|
||||
|
||||
if ( weaponisgasweapon( self.weapon ) )
|
||||
return false;
|
||||
}
|
||||
else if ( type == "MOD_PROJECTILE" )
|
||||
{
|
||||
if ( isdefined( attacker ) && isplayer( attacker ) )
|
||||
{
|
||||
weapon = attacker getcurrentweapon();
|
||||
|
||||
if ( weapon == "slipgun_zm" || weapon == "slipgun_upgraded_zm" )
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
prev_health = amount + self.health;
|
||||
|
||||
if ( prev_health <= 0 )
|
||||
prev_health = 1;
|
||||
|
||||
damage_percent = amount / prev_health * 100;
|
||||
|
||||
if ( damage_percent < 25 )
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bleedout_watcher()
|
||||
{
|
||||
self endon("death");
|
||||
|
Reference in New Issue
Block a user