From 1e0dccd137eaf928e6242899de552fdb6f1d96cf Mon Sep 17 00:00:00 2001 From: Anewbe Date: Sat, 6 Aug 2016 19:06:00 -0500 Subject: [PATCH] Severe burns cause bloodloss --- code/modules/organs/blood.dm | 12 +++++---- code/modules/organs/organ_external.dm | 5 ++++ html/changelogs/HarpyEagle-burns.yml | 36 +++++++++++++++++++++++++++ 3 files changed, 48 insertions(+), 5 deletions(-) create mode 100644 html/changelogs/HarpyEagle-burns.yml diff --git a/code/modules/organs/blood.dm b/code/modules/organs/blood.dm index 2c5f24984a..105a547e08 100644 --- a/code/modules/organs/blood.dm +++ b/code/modules/organs/blood.dm @@ -135,16 +135,18 @@ var/const/BLOOD_VOLUME_SURVIVE = 40 drip(blood_max) //Makes a blood drop, leaking amt units of blood from the mob -/mob/living/carbon/human/proc/drip(var/amt as num) +/mob/living/carbon/human/proc/drip(var/amt) + if(remove_blood(amt)) + blood_splatter(src,src) +/mob/living/carbon/human/proc/remove_blood(var/amt) if(!should_have_organ(O_HEART)) //TODO: Make drips come from the reagents instead. - return + return 0 if(!amt) - return + return 0 - vessel.remove_reagent("blood",amt) - blood_splatter(src,src) + return vessel.remove_reagent("blood",amt * (src.mob_size/MOB_MEDIUM)) /**************************************************** BLOOD TRANSFERS diff --git a/code/modules/organs/organ_external.dm b/code/modules/organs/organ_external.dm index 1ff2c29778..612cda4a98 100644 --- a/code/modules/organs/organ_external.dm +++ b/code/modules/organs/organ_external.dm @@ -474,6 +474,11 @@ This function completely restores a damaged organ to perfect condition. wounds += I owner.custom_pain("You feel something rip in your [name]!", 1) +//Burn damage can cause fluid loss due to blistering and cook-off + if((damage > 5 || damage + burn_dam >= 15) && type == BURN && (robotic < ORGAN_ROBOT)) + var/fluid_loss = (damage/(owner.maxHealth - config.health_threshold_dead)) * owner.species.blood_volume*(1 - BLOOD_VOLUME_SURVIVE/100) + owner.remove_blood(fluid_loss) + // first check whether we can widen an existing wound if(wounds.len > 0 && prob(max(50+(number_wounds-1)*10,90))) if((type == CUT || type == BRUISE) && damage >= 5) diff --git a/html/changelogs/HarpyEagle-burns.yml b/html/changelogs/HarpyEagle-burns.yml new file mode 100644 index 0000000000..f7fce8e5fe --- /dev/null +++ b/html/changelogs/HarpyEagle-burns.yml @@ -0,0 +1,36 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +################################# + +# Your name. +author: HarpyEagle + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - rscadd: "Severe enough burn damage now causes one-time blood loss due to blistering and body fluid cook-off." \ No newline at end of file