mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 12:07:27 +01:00
burn wounds, for real this time (#20542)
* burn wounds * user feedback * ready for review * sean review * Apply suggestions from code review Co-authored-by: Farie82 <farie82@users.noreply.github.com> * surgery fix * other repair methods * GDN review * health scanner feedback * Update code/game/objects/items/devices/scanners.dm Co-authored-by: Nathan Winters <100448493+CinnamonSnowball@users.noreply.github.com> * bodyscanner print out * Update code/game/machinery/adv_med.dm --------- Co-authored-by: Farie82 <farie82@users.noreply.github.com> Co-authored-by: Nathan Winters <100448493+CinnamonSnowball@users.noreply.github.com>
This commit is contained in:
co-authored by
Farie82
Nathan Winters
parent
7293b7ecbd
commit
e6085895c1
@@ -8,10 +8,13 @@
|
||||
#define ORGAN_MUTATED (1 << 4)
|
||||
#define ORGAN_INT_BLEEDING (1 << 5)
|
||||
#define ORGAN_DISFIGURED (1 << 6)
|
||||
#define ORGAN_BURNT (1 << 7)
|
||||
#define ORGAN_SALVED (1 << 8)
|
||||
|
||||
// For limb resistance flags
|
||||
#define CANNOT_BREAK (1 << 0)
|
||||
#define CANNOT_DISMEMBER (1 << 1)
|
||||
#define CANNOT_BURN (1 << 2)
|
||||
|
||||
#define PROCESS_ACCURACY 10
|
||||
|
||||
|
||||
@@ -179,6 +179,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
|
||||
|
||||
#define TRAIT_NO_BONES "no_bones"
|
||||
#define TRAIT_STURDY_LIMBS "sturdy_limbs"
|
||||
#define TRAIT_BURN_WOUND_IMMUNE "burn_immune"
|
||||
|
||||
#define TRAIT_COMIC_SANS "comic_sans"
|
||||
#define TRAIT_NOFINGERPRINTS "no_fingerprints"
|
||||
|
||||
@@ -315,6 +315,7 @@
|
||||
if(prob(10))
|
||||
E.mend_fracture()
|
||||
E.fix_internal_bleeding()
|
||||
E.fix_burn_wound(update_health = FALSE)
|
||||
heal_points--
|
||||
else if(issilicon(L))
|
||||
L.adjustBruteLoss(-3.5)
|
||||
@@ -349,6 +350,7 @@
|
||||
if(is_mining_level(H.z))
|
||||
for(var/obj/item/organ/external/E in H.bodyparts)
|
||||
E.fix_internal_bleeding()
|
||||
E.fix_burn_wound()
|
||||
E.mend_fracture()
|
||||
else
|
||||
to_chat(owner, "<span class='warning'>...But the core was weakened, it is not close enough to the rest of the legions of the necropolis.</span>")
|
||||
|
||||
@@ -362,6 +362,7 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
for(var/obj/item/organ/external/E in H.bodyparts)
|
||||
E.mend_fracture()
|
||||
E.fix_internal_bleeding()
|
||||
E.fix_burn_wound()
|
||||
for(var/datum/disease/critical/crit in H.viruses) // cure all crit conditions
|
||||
crit.cure()
|
||||
|
||||
|
||||
@@ -311,6 +311,9 @@
|
||||
if(E.status & ORGAN_INT_BLEEDING)
|
||||
organData["internalBleeding"] = TRUE
|
||||
|
||||
if(E.status & ORGAN_BURNT)
|
||||
organData["burnWound"] = TRUE
|
||||
|
||||
extOrganData.Add(list(organData))
|
||||
|
||||
occupantData["extOrgan"] = extOrganData
|
||||
@@ -452,6 +455,8 @@
|
||||
var/bled = ""
|
||||
var/splint = ""
|
||||
var/internal_bleeding = ""
|
||||
var/burn_wound = ""
|
||||
var/ointment = ""
|
||||
var/lung_ruptured = ""
|
||||
if(e.status & ORGAN_INT_BLEEDING)
|
||||
internal_bleeding = "<br>Internal bleeding"
|
||||
@@ -461,6 +466,10 @@
|
||||
splint = "Splinted:"
|
||||
if(e.status & ORGAN_BROKEN)
|
||||
AN = "[e.broken_description]:"
|
||||
if(e.status & ORGAN_SALVED)
|
||||
ointment = "Salved:"
|
||||
if(e.status & ORGAN_BURNT)
|
||||
burn_wound = "Critical Burn:"
|
||||
if(e.status & ORGAN_DEAD)
|
||||
dead = "DEAD:"
|
||||
if(e.is_robotic())
|
||||
@@ -491,7 +500,7 @@
|
||||
imp += "Unknown body present:"
|
||||
if(!AN && !open && !infected && !imp)
|
||||
AN = "None:"
|
||||
dat += "<td>[e.name]</td><td>[e.burn_dam]</td><td>[e.brute_dam]</td><td>[robot][bled][AN][splint][open][infected][imp][internal_bleeding][lung_ruptured][dead]</td>"
|
||||
dat += "<td>[e.name]</td><td>[e.burn_dam]</td><td>[e.brute_dam]</td><td>[robot][bled][AN][splint][burn_wound][ointment][open][infected][imp][internal_bleeding][lung_ruptured][dead]</td>"
|
||||
dat += "</tr>"
|
||||
for(var/obj/item/organ/internal/i in occupant.internal_organs)
|
||||
var/mech = i.desc
|
||||
|
||||
@@ -207,7 +207,9 @@ REAGENT SCANNER
|
||||
to_chat(user, "<span class='warning'>Significant brain damage detected. Subject may have had a concussion.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='warning'>Subject has no brain.</span>")
|
||||
|
||||
var/broken_bone = FALSE
|
||||
var/internal_bleed = FALSE
|
||||
var/burn_wound = FALSE
|
||||
for(var/name in H.bodyparts_by_name)
|
||||
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
|
||||
if(!e)
|
||||
@@ -216,20 +218,18 @@ REAGENT SCANNER
|
||||
if(e.status & ORGAN_BROKEN)
|
||||
if((e.limb_name in list("l_arm", "r_arm", "l_hand", "r_hand", "l_leg", "r_leg", "l_foot", "r_foot")) && !(e.status & ORGAN_SPLINTED))
|
||||
to_chat(user, "<span class='warning'>Unsecured fracture in subject [limb]. Splinting recommended for transport.</span>")
|
||||
broken_bone = TRUE
|
||||
if(e.has_infected_wound())
|
||||
to_chat(user, "<span class='warning'>Infected wound detected in subject [limb]. Disinfection recommended.</span>")
|
||||
burn_wound = burn_wound || (e.status & ORGAN_BURNT)
|
||||
internal_bleed = internal_bleed || (e.status & ORGAN_INT_BLEEDING)
|
||||
if(broken_bone)
|
||||
to_chat(user, "<span class='warning'>Bone fractures detected. Advanced scanner required for location.</span>")
|
||||
if(internal_bleed)
|
||||
to_chat(user, "<span class='warning'>Internal bleeding detected. Advanced scanner required for location.</span>")
|
||||
if(burn_wound)
|
||||
to_chat(user, "<span class='warning'>Critical burn detected. Examine patient's body for location.</span>")
|
||||
|
||||
for(var/name in H.bodyparts_by_name)
|
||||
var/obj/item/organ/external/e = H.bodyparts_by_name[name]
|
||||
if(!e)
|
||||
continue
|
||||
if(e.status & ORGAN_BROKEN)
|
||||
to_chat(user, "<span class='warning'>Bone fractures detected. Advanced scanner required for location.</span>")
|
||||
break
|
||||
for(var/obj/item/organ/external/e in H.bodyparts)
|
||||
if(e.status & ORGAN_INT_BLEEDING)
|
||||
to_chat(user, "<span class='warning'>Internal bleeding detected. Advanced scanner required for location.</span>")
|
||||
break
|
||||
var/blood_id = H.get_blood_id()
|
||||
if(blood_id)
|
||||
if(H.bleed_rate)
|
||||
|
||||
@@ -111,6 +111,7 @@
|
||||
remburn = nremburn
|
||||
user.visible_message("<span class='green'>[user] [healverb]s the wounds on [H]'s [E.name] with the remaining medication.</span>", \
|
||||
"<span class='green'>You [healverb] the wounds on [H]'s [E.name] with the remaining medication.</span>" )
|
||||
return affecting
|
||||
|
||||
//Bruise Packs//
|
||||
|
||||
@@ -220,6 +221,19 @@
|
||||
else
|
||||
to_chat(user, "<span class='warning'>[affecting] is cut open, you'll need more than some ointment!</span>")
|
||||
|
||||
/obj/item/stack/medical/ointment/heal(mob/living/M, mob/user)
|
||||
var/obj/item/organ/external/affecting = ..()
|
||||
if((affecting.status & ORGAN_BURNT) && !(affecting.status & ORGAN_SALVED))
|
||||
affecting.status |= ORGAN_SALVED
|
||||
addtimer(CALLBACK(affecting, TYPE_PROC_REF(/obj/item/organ/external, remove_ointment), heal_burn), 3 MINUTES)
|
||||
|
||||
/obj/item/organ/external/proc/remove_ointment(heal_amount) //de-ointmenterized D:
|
||||
status &= ~ORGAN_SALVED
|
||||
perma_injury = max(perma_injury - heal_amount, 0)
|
||||
if(owner)
|
||||
owner.updatehealth("permanent injury removal")
|
||||
if(!perma_injury)
|
||||
fix_burn_wound(update_health = FALSE)
|
||||
|
||||
/obj/item/stack/medical/ointment/advanced
|
||||
name = "advanced burn kit"
|
||||
|
||||
@@ -304,6 +304,7 @@
|
||||
if(prob(25))
|
||||
E.mend_fracture()
|
||||
E.fix_internal_bleeding()
|
||||
E.fix_burn_wound()
|
||||
|
||||
return
|
||||
if(H.stat != DEAD)
|
||||
|
||||
@@ -318,16 +318,19 @@
|
||||
status = "battered"
|
||||
if(40 to INFINITY)
|
||||
status = "mangled"
|
||||
if(brutedamage > 0 && burndamage > 0)
|
||||
if(brutedamage > 0 && (burndamage > 0 || LB.status & ORGAN_BURNT))
|
||||
status += " and "
|
||||
|
||||
switch(burndamage)
|
||||
if(0.1 to 10)
|
||||
status += "numb"
|
||||
if(10 to 40)
|
||||
status += "blistered"
|
||||
if(40 to INFINITY)
|
||||
status += "peeling away"
|
||||
if(LB.status & ORGAN_BURNT)
|
||||
status += "critically burnt"
|
||||
else
|
||||
switch(burndamage)
|
||||
if(0.1 to 10)
|
||||
status += "numb"
|
||||
if(10 to 40)
|
||||
status += "blistered"
|
||||
if(40 to INFINITY)
|
||||
status += "peeling away"
|
||||
|
||||
if(LB.status & ORGAN_MUTATED)
|
||||
status = "weirdly shapen"
|
||||
|
||||
@@ -5,17 +5,13 @@
|
||||
set_stat(CONSCIOUS)
|
||||
return
|
||||
|
||||
var/total_burn = 0
|
||||
var/total_brute = 0
|
||||
var/total_limb_damage = 0
|
||||
|
||||
for(var/obj/item/organ/external/O in bodyparts) //hardcoded to streamline things a bit
|
||||
total_brute += O.brute_dam //calculates health based on organ brute and burn
|
||||
total_burn += O.burn_dam
|
||||
for(var/obj/item/organ/external/O in bodyparts) /// sums up all the damage of all the limbs
|
||||
total_limb_damage += O.get_damage()
|
||||
|
||||
health = maxHealth - getOxyLoss() - getToxLoss() - getCloneLoss() - total_burn - total_brute
|
||||
health = maxHealth - getOxyLoss() - getToxLoss() - getCloneLoss() - total_limb_damage
|
||||
|
||||
if(((maxHealth - total_burn) < HEALTH_THRESHOLD_DEAD * 2) && stat == DEAD)
|
||||
become_husk(BURN)
|
||||
update_stat("updatehealth([reason])")
|
||||
med_hud_set_health()
|
||||
|
||||
@@ -102,6 +98,9 @@
|
||||
take_overall_damage(0, amount, updating_health, used_weapon = damage_source)
|
||||
else
|
||||
heal_overall_damage(0, -amount, updating_health, FALSE, robotic)
|
||||
|
||||
if(((maxHealth - getFireLoss()) < HEALTH_THRESHOLD_DEAD * 2) && stat == DEAD)
|
||||
become_husk(BURN)
|
||||
// brainless default for now
|
||||
return STATUS_UPDATE_HEALTH
|
||||
|
||||
|
||||
@@ -187,6 +187,9 @@
|
||||
else if(!E.properly_attached)
|
||||
wound_flavor_text["[E.limb_name]"] = "[p_their(TRUE)] [E.name] is barely attached!\n"
|
||||
|
||||
else if(E.status & ORGAN_BURNT)
|
||||
wound_flavor_text["[E.limb_name]"] = "[p_their(TRUE)] [E.name] is badly burnt!\n"
|
||||
|
||||
if(E.open)
|
||||
if(E.is_robotic())
|
||||
msg += "<b>The maintenance hatch on [p_their()] [ignore_limb_branding(E.limb_name)] is open!</b>\n"
|
||||
|
||||
@@ -686,7 +686,7 @@
|
||||
// Use the dead health doll as the base, since we have proper "healthy" overlays now
|
||||
healthdoll.icon_state = "healthdoll_DEAD"
|
||||
for(var/obj/item/organ/external/O in bodyparts)
|
||||
var/damage = O.burn_dam + O.brute_dam
|
||||
var/damage = O.get_damage()
|
||||
var/comparison = (O.max_damage/5)
|
||||
var/icon_num = 0
|
||||
if(damage)
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
var/obj/item/organ/internal/I = pick(E.internal_organs)
|
||||
custom_pain("You feel broken bones moving in your [E.name]!")
|
||||
I.receive_damage(rand(3,5))
|
||||
if((E.status & ORGAN_BURNT) && !(E.status & ORGAN_SALVED))
|
||||
custom_pain("You feel the skin sloughing off the burn on your [E.name]!")
|
||||
E.germ_level++
|
||||
|
||||
|
||||
//handle_stance()
|
||||
handle_grasp()
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
icobase = 'icons/mob/human_races/r_golem.dmi'
|
||||
|
||||
species_traits = list(NO_BLOOD, NO_HAIR, NOT_SELECTABLE)
|
||||
inherent_traits = list(TRAIT_RESISTHEAT, TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_NOFIRE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS, TRAIT_XENO_IMMUNE)
|
||||
inherent_traits = list(TRAIT_RESISTHEAT, TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_NOFIRE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS, TRAIT_XENO_IMMUNE, TRAIT_BURN_WOUND_IMMUNE)
|
||||
inherent_biotypes = MOB_HUMANOID | MOB_MINERAL
|
||||
dies_at_threshold = TRUE
|
||||
speed_mod = 2
|
||||
@@ -111,7 +111,7 @@
|
||||
name = "Plasma Golem"
|
||||
skinned_type = /obj/item/stack/ore/plasma
|
||||
//Can burn and takes damage from heat
|
||||
inherent_traits = list(TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS) //no RESISTHEAT, NOFIRE
|
||||
inherent_traits = list(TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS, TRAIT_BURN_WOUND_IMMUNE) //no RESISTHEAT, NOFIRE
|
||||
golem_colour = rgb(170, 51, 221)
|
||||
info_text = "As a <span class='danger'>Plasma Golem</span>, you burn easily. Be careful, if you get hot enough while burning, you'll blow up!"
|
||||
heatmod = 0 //fine until they blow up
|
||||
@@ -288,7 +288,7 @@
|
||||
golem_colour = rgb(158, 112, 75)
|
||||
skinned_type = /obj/item/stack/sheet/wood
|
||||
//Can burn and take damage from heat
|
||||
inherent_traits = list(TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS)
|
||||
inherent_traits = list(TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_CHUNKYFINGERS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS, TRAIT_BURN_WOUND_IMMUNE)
|
||||
inherent_biotypes = MOB_ORGANIC | MOB_HUMANOID | MOB_PLANT
|
||||
armor = 30
|
||||
burn_mod = 1.25
|
||||
@@ -559,7 +559,7 @@
|
||||
prefix = "Bananium"
|
||||
special_names = null
|
||||
unarmed_type = /datum/unarmed_attack/golem/bananium
|
||||
inherent_traits = list(TRAIT_RESISTHEAT, TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_NOFIRE, TRAIT_CHUNKYFINGERS, TRAIT_CLUMSY, TRAIT_COMIC_SANS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS)
|
||||
inherent_traits = list(TRAIT_RESISTHEAT, TRAIT_NOBREATH, TRAIT_RESISTCOLD, TRAIT_RESISTHIGHPRESSURE, TRAIT_RESISTLOWPRESSURE, TRAIT_NOFIRE, TRAIT_CHUNKYFINGERS, TRAIT_CLUMSY, TRAIT_COMIC_SANS, TRAIT_RADIMMUNE, TRAIT_PIERCEIMMUNE, TRAIT_NOPAIN, TRAIT_NO_BONES, TRAIT_STURDY_LIMBS, TRAIT_BURN_WOUND_IMMUNE)
|
||||
var/last_honk = 0
|
||||
var/honkooldown = 0
|
||||
var/last_banana = 0
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
//language = "Clatter"
|
||||
|
||||
species_traits = list(NO_BLOOD, NO_HAIR)
|
||||
inherent_traits = list(TRAIT_RADIMMUNE, TRAIT_NOHUNGER)
|
||||
inherent_traits = list(TRAIT_RADIMMUNE, TRAIT_NOHUNGER, TRAIT_BURN_WOUND_IMMUNE)
|
||||
inherent_biotypes = MOB_HUMANOID | MOB_MINERAL
|
||||
forced_heartattack = TRUE // Plasmamen have no blood, but they should still get heart-attacks
|
||||
skinned_type = /obj/item/stack/sheet/mineral/plasma // We're low on plasma, R&D! *eyes plasmaman co-worker intently*
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
for(var/obj/item/organ/external/E in H.bodyparts)
|
||||
E.mend_fracture()
|
||||
E.fix_internal_bleeding()
|
||||
E.fix_burn_wound(update_health = FALSE)
|
||||
M.SetEyeBlind(0)
|
||||
M.cure_nearsighted(null, FALSE)
|
||||
M.cure_blind(null, FALSE)
|
||||
|
||||
@@ -1310,7 +1310,7 @@
|
||||
else
|
||||
for(var/obj/item/organ/external/E in M.bodyparts)
|
||||
if(prob(25)) // Each tick has a 25% chance of repearing a bone.
|
||||
if(E.status & (ORGAN_INT_BLEEDING | ORGAN_BROKEN | ORGAN_SPLINTED)) //I can't just check for !E.status
|
||||
if(E.status & (ORGAN_INT_BLEEDING | ORGAN_BROKEN | ORGAN_SPLINTED | ORGAN_BURNT)) //I can't just check for !E.status
|
||||
to_chat(M, "<span class='notice'>You feel a burning sensation in your [E.name] as it straightens involuntarily!</span>")
|
||||
E.rejuvenate() //Repair it completely.
|
||||
if(ishuman(M))
|
||||
|
||||
@@ -104,7 +104,7 @@
|
||||
germ_level = 0
|
||||
return
|
||||
|
||||
if(!owner)
|
||||
if(!owner || ((status & ORGAN_BURNT) && !(status & ORGAN_SALVED)))
|
||||
if(is_preserved())
|
||||
return
|
||||
// Maybe scale it down a bit, have it REALLY kick in once past the basic infection threshold
|
||||
|
||||
@@ -146,6 +146,8 @@
|
||||
if(HAS_TRAIT(owner, TRAIT_STURDY_LIMBS))
|
||||
limb_flags |= CANNOT_DISMEMBER
|
||||
|
||||
if(HAS_TRAIT(owner, TRAIT_BURN_WOUND_IMMUNE))
|
||||
limb_flags |= CANNOT_BURN
|
||||
|
||||
/obj/item/organ/external/replaced(mob/living/carbon/human/target)
|
||||
owner = target
|
||||
@@ -191,6 +193,8 @@
|
||||
|
||||
// See if bones need to break
|
||||
check_fracture(brute)
|
||||
// see if we need to inflict severe burns
|
||||
check_for_burn_wound(burn)
|
||||
// Threshold needed to have a chance of hurting internal bits with something sharp
|
||||
#define LIMB_SHARP_THRESH_INT_DMG 5
|
||||
// Threshold needed to have a chance of hurting internal bits
|
||||
@@ -364,9 +368,6 @@ This function completely restores a damaged organ to perfect condition.
|
||||
if(trace_chemicals[chemID] <= 0)
|
||||
trace_chemicals.Remove(chemID)
|
||||
|
||||
if(!(status & ORGAN_BROKEN))
|
||||
perma_injury = 0
|
||||
|
||||
if(..())
|
||||
if(owner.germ_level > germ_level && infection_check())
|
||||
//Open wounds can become infected
|
||||
@@ -447,6 +448,12 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
if(damage > 15 && local_damage > 30 && prob(damage))
|
||||
cause_internal_bleeding()
|
||||
|
||||
/obj/item/organ/external/proc/check_for_burn_wound(damage)
|
||||
if(is_robotic())
|
||||
return
|
||||
if(burn_dam >= min_broken_damage && prob(damage * max(owner.bodytemperature / BODYTEMP_HEAT_DAMAGE_LIMIT, 1)))
|
||||
cause_burn_wound()
|
||||
|
||||
// new damage icon system
|
||||
// returns just the brute/burn damage code
|
||||
/obj/item/organ/external/proc/damage_state_text()
|
||||
@@ -657,7 +664,6 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
|
||||
status |= ORGAN_BROKEN
|
||||
broken_description = pick("broken", "fracture", "hairline fracture")
|
||||
perma_injury = brute_dam
|
||||
|
||||
// Fractures have a chance of getting you out of restraints
|
||||
if(prob(25))
|
||||
@@ -672,7 +678,6 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
|
||||
status &= ~ORGAN_BROKEN
|
||||
status &= ~ORGAN_SPLINTED
|
||||
perma_injury = 0
|
||||
if(owner)
|
||||
owner.handle_splints()
|
||||
return TRUE
|
||||
@@ -689,7 +694,18 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
if(is_robotic())
|
||||
return
|
||||
status &= ~ORGAN_INT_BLEEDING
|
||||
perma_injury = 0
|
||||
|
||||
/obj/item/organ/external/proc/cause_burn_wound()
|
||||
if(is_robotic() || (limb_flags & CANNOT_BURN) || (status & ORGAN_BURNT))
|
||||
return
|
||||
status |= ORGAN_BURNT
|
||||
perma_injury = min_broken_damage
|
||||
|
||||
/obj/item/organ/external/proc/fix_burn_wound(update_health = TRUE)
|
||||
status &= ~ORGAN_BURNT
|
||||
perma_injury = max(perma_injury - min_broken_damage, 0)
|
||||
if(update_health)
|
||||
owner.updatehealth("burn wound")
|
||||
|
||||
/obj/item/organ/external/robotize(company, make_tough = FALSE, convert_all = TRUE)
|
||||
..()
|
||||
@@ -733,7 +749,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
status &= ~ORGAN_MUTATED
|
||||
|
||||
/obj/item/organ/external/proc/get_damage() //returns total damage
|
||||
return max(brute_dam + burn_dam - perma_injury, perma_injury) //could use health?
|
||||
return max(brute_dam + burn_dam, perma_injury)
|
||||
|
||||
/obj/item/organ/external/proc/has_infected_wound()
|
||||
if(germ_level > INFECTION_LEVEL_ONE)
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
if(!.)
|
||||
return FALSE
|
||||
var/obj/item/organ/external/affected = target.get_organ(user.zone_selected)
|
||||
if(!(affected.status & ORGAN_DEAD))
|
||||
if(!(affected.status & ORGAN_DEAD) && !(affected.status & ORGAN_BURNT))
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
@@ -174,7 +174,7 @@
|
||||
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
|
||||
if(!(affected.status & ORGAN_DEAD))
|
||||
if(!(affected.status & ORGAN_DEAD) && !(affected.status & ORGAN_BURNT))
|
||||
to_chat(user, "<span class='warning'>The [affected] seems to already be in fine condition!")
|
||||
return SURGERY_BEGINSTEP_SKIP
|
||||
|
||||
@@ -200,6 +200,7 @@
|
||||
|
||||
if(mitocholide)
|
||||
affected.status &= ~ORGAN_DEAD
|
||||
affected.fix_burn_wound()
|
||||
affected.germ_level = 0
|
||||
target.update_body()
|
||||
|
||||
|
||||
@@ -276,6 +276,7 @@ const BodyScannerMainOrgansExternal = (props) => {
|
||||
color={
|
||||
(!!o.status.dead && 'bad') ||
|
||||
((!!o.internalBleeding ||
|
||||
!!o.burnWound ||
|
||||
!!o.lungRuptured ||
|
||||
!!o.status.broken ||
|
||||
!!o.open ||
|
||||
@@ -323,6 +324,7 @@ const BodyScannerMainOrgansExternal = (props) => {
|
||||
<Box color="average" display="inline">
|
||||
{reduceOrganStatus([
|
||||
!!o.internalBleeding && 'Internal bleeding',
|
||||
!!o.burnWound && 'Critical tissue burns',
|
||||
!!o.lungRuptured && 'Ruptured lung',
|
||||
!!o.status.broken && o.status.broken,
|
||||
germStatus(o.germ_level),
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user