diff --git a/code/modules/mob/living/simple_animal/animal_defense.dm b/code/modules/mob/living/simple_animal/animal_defense.dm index d7dbb558106f..3a7c398386cf 100644 --- a/code/modules/mob/living/simple_animal/animal_defense.dm +++ b/code/modules/mob/living/simple_animal/animal_defense.dm @@ -128,7 +128,11 @@ /mob/living/simple_animal/proc/attack_threshold_check(damage, damagetype = BRUTE, actuallydamage = TRUE) var/temp_damage = damage - temp_damage *= damage_coeff.getCoeff(damagetype) + if(islist(damage_coeff)) + temp_damage *= damage_coeff[damagetype] + stack_trace("[src] has a damage_coeff list and was hurt!") + else + temp_damage *= damage_coeff.getCoeff(damagetype) if(temp_damage >= 0 && temp_damage <= force_threshold) visible_message("[src] looks unharmed!") diff --git a/code/modules/mob/living/simple_animal/hostile/hostile.dm b/code/modules/mob/living/simple_animal/hostile/hostile.dm index 16b613fa78ec..af8ed5d1d487 100644 --- a/code/modules/mob/living/simple_animal/hostile/hostile.dm +++ b/code/modules/mob/living/simple_animal/hostile/hostile.dm @@ -193,10 +193,10 @@ /mob/living/simple_animal/hostile/proc/DamageEffect(amount, damtype) //Code stolen from attack_threshold_check() in animal_defense.dm var/temp_damage = amount - if(!damage_coeff[damtype]) - temp_damage = 0 - else + if(islist(damage_coeff)) temp_damage *= damage_coeff[damtype] + else + temp_damage *= damage_coeff.getCoeff(damtype) if(temp_damage > 0) return FALSE