From cb44f5d724c51b54e06db9fbc60eedf82922300f Mon Sep 17 00:00:00 2001 From: "kortgstation@gmail.com" Date: Thu, 29 Dec 2011 00:24:34 +0000 Subject: [PATCH] Simple animals (Ian, Shades, etc) no longer suffer stuns/stuttering from projectiles (because it would never wear off) On the other hand, simple animals now take damage from harmful projectiles (bullets, lasers). Because of their low amount of health and lack of armour, this means lasers kill most animals in a single shot (I might need to give them some sort of damage reduction so that poor Ian doesn't get killed in one shot every round). git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2848 316c924e-a436-60f5-8080-3fe189b3f50e --- code/defines/mob/simple_animal/life.dm | 5 +++++ code/modules/projectiles/projectile.dm | 1 + 2 files changed, 6 insertions(+) diff --git a/code/defines/mob/simple_animal/life.dm b/code/defines/mob/simple_animal/life.dm index 25cfb962e70..28479e790a6 100644 --- a/code/defines/mob/simple_animal/life.dm +++ b/code/defines/mob/simple_animal/life.dm @@ -212,6 +212,11 @@ var/damage = rand(M.melee_damage_lower, M.melee_damage_upper) health -= damage +/mob/living/simple_animal/bullet_act(var/obj/item/projectile/Proj) + if(!Proj) return + src.health -= Proj.damage + return 0 + /mob/living/simple_animal/attack_hand(mob/living/carbon/human/M as mob) ..() diff --git a/code/modules/projectiles/projectile.dm b/code/modules/projectiles/projectile.dm index 4b6bef3f3b1..673bd499821 100644 --- a/code/modules/projectiles/projectile.dm +++ b/code/modules/projectiles/projectile.dm @@ -51,6 +51,7 @@ if(blocked >= 2) return 0//Full block if(!isliving(target)) return 0 var/mob/living/L = target + if(istype(L, /mob/living/simple_animal)) return 0 L.apply_effects(stun, weaken, paralyze, irradiate, stutter, eyeblur, drowsy, blocked) return 1