diff --git a/code/game/objects/items/stacks/medical.dm b/code/game/objects/items/stacks/medical.dm index 2be87802f4a..8b35787d4df 100644 --- a/code/game/objects/items/stacks/medical.dm +++ b/code/game/objects/items/stacks/medical.dm @@ -14,7 +14,7 @@ var/stop_bleeding = 0 var/self_delay = 50 -/obj/item/stack/medical/attack(mob/living/carbon/M, mob/user) +/obj/item/stack/medical/attack(mob/living/M, mob/user) if(M.stat == 2) var/t_him = "it" @@ -25,8 +25,8 @@ user << "\The [M] is dead, you cannot help [t_him]!" return - if(!istype(M) || isdrone(M)) - user << "You cannot apply \the [src] to [M]!" + if(!istype(M, /mob/living/carbon) && !istype(M, /mob/living/simple_animal)) + user << "You don't know how to apply \the [src] to [M]..." return 1 if(!user.IsAdvancedToolUser()) @@ -48,7 +48,18 @@ return if(user) - if(M != user) + if (M != user) + if (istype(M, /mob/living/simple_animal)) + var/mob/living/simple_animal/critter = M + if (!(critter.healable)) + user << " You cannot use [src] on [M]!" + return + else if (critter.health == critter.maxHealth) + user << " [M] is at full health." + return + else if(src.heal_brute < 1) + user << " [src] won't help [M] at all." + return user.visible_message("[user] applies [src] on [M].", "You apply [src] on [M].") else var/t_himself = "itself" diff --git a/code/modules/mob/living/simple_animal/constructs.dm b/code/modules/mob/living/simple_animal/constructs.dm index 261dad9eaa9..fff18ea4494 100644 --- a/code/modules/mob/living/simple_animal/constructs.dm +++ b/code/modules/mob/living/simple_animal/constructs.dm @@ -16,6 +16,7 @@ attack_sound = 'sound/weapons/punch1.ogg' atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0) minbodytemp = 0 + healable = 0 faction = list("cult") flying = 1 var/list/construct_spells = list() diff --git a/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm b/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm index 4b349ee1ddb..ac0bab34649 100644 --- a/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm +++ b/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm @@ -24,6 +24,7 @@ wander = 0 speed = 0 ventcrawler = 2 + healable = 0 density = 0 pass_flags = PASSTABLE | PASSMOB sight = (SEE_TURFS | SEE_OBJS) diff --git a/code/modules/mob/living/simple_animal/hostile/hivebot.dm b/code/modules/mob/living/simple_animal/hostile/hivebot.dm index ce67552c952..07fb4abc1ab 100644 --- a/code/modules/mob/living/simple_animal/hostile/hivebot.dm +++ b/code/modules/mob/living/simple_animal/hostile/hivebot.dm @@ -11,6 +11,7 @@ icon_dead = "basic" health = 15 maxHealth = 15 + healable = 0 melee_damage_lower = 2 melee_damage_upper = 3 attacktext = "claws" diff --git a/code/modules/mob/living/simple_animal/hostile/statue.dm b/code/modules/mob/living/simple_animal/hostile/statue.dm index 8ff2d451a10..3da4da1e5ad 100644 --- a/code/modules/mob/living/simple_animal/hostile/statue.dm +++ b/code/modules/mob/living/simple_animal/hostile/statue.dm @@ -16,6 +16,7 @@ speed = -1 maxHealth = 50000 health = 50000 + healable = 0 harm_intent_damage = 70 melee_damage_lower = 68 diff --git a/code/modules/mob/living/simple_animal/morph/morph.dm b/code/modules/mob/living/simple_animal/morph/morph.dm index 15d69564839..031a9b759b3 100644 --- a/code/modules/mob/living/simple_animal/morph/morph.dm +++ b/code/modules/mob/living/simple_animal/morph/morph.dm @@ -20,6 +20,7 @@ minbodytemp = 0 maxHealth = 150 health = 150 + healable = 0 environment_smash = 1 melee_damage_lower = 20 melee_damage_upper = 20 @@ -35,7 +36,7 @@ /mob/living/simple_animal/hostile/morph/examine(mob/user) if(morphed) form.examine(user) // Refactor examine to return desc so it's static? Not sure if worth it - if(get_dist(user,src)<=3) + if(get_dist(user,src)<=3) user << "Looks odd!" else ..() @@ -61,7 +62,7 @@ /mob/living/simple_animal/hostile/morph/proc/assume(atom/movable/target) morphed = 1 form = target - + //anim(loc,src,'icons/mob/mob.dmi',,"morph",,src.dir) No effect better than shit effect //Todo : update to .appearance once 508 hits @@ -89,9 +90,9 @@ return morphed = 0 form = null - - //anim(loc,src,'icons/mob/mob.dmi',,"morph",,src.dir) - + + //anim(loc,src,'icons/mob/mob.dmi',,"morph",,src.dir) + name = initial(name) icon = initial(icon) icon_state = initial(icon_state) diff --git a/code/modules/mob/living/simple_animal/revenant/revenant.dm b/code/modules/mob/living/simple_animal/revenant/revenant.dm index cb99c234248..8a558dd64c1 100644 --- a/code/modules/mob/living/simple_animal/revenant/revenant.dm +++ b/code/modules/mob/living/simple_animal/revenant/revenant.dm @@ -13,6 +13,7 @@ health = 25 maxHealth = 25 see_in_dark = 255 + healable = 0 see_invisible = SEE_INVISIBLE_OBSERVER languages = ALL response_help = "passes through" diff --git a/code/modules/mob/living/simple_animal/shade.dm b/code/modules/mob/living/simple_animal/shade.dm index cb43847c32c..a7fabaed8d2 100644 --- a/code/modules/mob/living/simple_animal/shade.dm +++ b/code/modules/mob/living/simple_animal/shade.dm @@ -7,6 +7,7 @@ icon_living = "shade" maxHealth = 50 health = 50 + healable = 0 speak_emote = list("hisses") emote_hear = list("wails.","screeches.") response_help = "puts their hand through" diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm index 938ee7cf586..33ee249b8d2 100644 --- a/code/modules/mob/living/simple_animal/simple_animal.dm +++ b/code/modules/mob/living/simple_animal/simple_animal.dm @@ -34,6 +34,9 @@ var/minbodytemp = 250 var/maxbodytemp = 350 + //Healable by medical stacks? Defaults to yes. + var/healable = 1 + //Atmos effect - Yes, you can make creatures that require plasma or co2 to survive. N2O is a trace gas and handled separately, hence why it isn't here. It'd be hard to add it. Hard and me don't mix (Yes, yes make all the dick jokes you want with that.) - Errorage var/list/atmos_requirements = list("min_oxy" = 5, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 1, "min_co2" = 0, "max_co2" = 5, "min_n2" = 0, "max_n2" = 0) //Leaving something at 0 means it's off - has no maximum var/unsuitable_atmos_damage = 2 //This damage is taken when atmos doesn't fit all the requirements above @@ -340,29 +343,6 @@ if(O.flags & NOBLUDGEON) return - if(istype(O, /obj/item/stack/medical)) - user.changeNext_move(CLICK_CD_MELEE) - if(stat != DEAD) - var/obj/item/stack/medical/MED = O - if(health < maxHealth) - if(MED.amount >= 1) - if(MED.heal_brute >= 1) - adjustBruteLoss(-MED.heal_brute) - MED.amount -= 1 - if(MED.amount <= 0) - qdel(MED) - visible_message("[user] applies [MED] on [src].") - return - else - user << "[MED] won't help at all." - return - else - user << "[src] is at full health." - return - else - user << "[src] is dead, medical items won't bring it back to life." - return - if((butcher_results) && (stat == DEAD)) user.changeNext_move(CLICK_CD_MELEE) var/sharpness = is_sharp(O) diff --git a/code/modules/mob/living/simple_animal/slaughter/slaughter.dm b/code/modules/mob/living/simple_animal/slaughter/slaughter.dm index 58fe29515b3..880ed436404 100644 --- a/code/modules/mob/living/simple_animal/slaughter/slaughter.dm +++ b/code/modules/mob/living/simple_animal/slaughter/slaughter.dm @@ -23,6 +23,7 @@ attacktext = "wildly tears into" maxHealth = 250 health = 250 + healable = 0 environment_smash = 1 melee_damage_lower = 30 melee_damage_upper = 30 diff --git a/code/modules/mob/living/simple_animal/slime/slime.dm b/code/modules/mob/living/simple_animal/slime/slime.dm index 75da09b542c..4744100ecb9 100644 --- a/code/modules/mob/living/simple_animal/slime/slime.dm +++ b/code/modules/mob/living/simple_animal/slime/slime.dm @@ -24,6 +24,7 @@ maxHealth = 150 health = 150 + healable = 0 gender = NEUTER nutrition = 700