section 2

This commit is contained in:
timothyteakettle
2020-07-24 23:44:57 +01:00
parent 7fb55a02a5
commit 8360bb1a7f
44 changed files with 760 additions and 99 deletions
@@ -1016,4 +1016,23 @@
if(M.getToxLoss() && prob(30))
M.adjustToxLoss(-1, 0)
..()
. = TRUE
. = TRUE
// i googled "natural coagulant" and a couple of results came up for banana peels, so after precisely 30 more seconds of research, i now dub grinding banana peels good for your blood
/datum/reagent/consumable/banana_peel
name = "Pulped Banana Peel"
description = "Okay, so you put a banana peel in a grinder... Why, exactly?"
color = "#863333" // rgb: 175, 175, 0
reagent_state = SOLID
taste_description = "stringy, bitter pulp"
glass_name = "glass of banana peel pulp"
glass_desc = "Okay, so you put a banana peel in a grinder... Why, exactly?"
/datum/reagent/consumable/baked_banana_peel
name = "Baked Banana Peel Powder"
description = "You took a banana peel... pulped it... baked it... Where are you going with this?"
color = "#863333" // rgb: 175, 175, 0
reagent_state = SOLID
taste_description = "bitter powder"
glass_name = "glass of banana peel powder"
description = "You took a banana peel... pulped it... baked it... Where are you going with this?"
@@ -145,8 +145,8 @@
M.adjustToxLoss(-power, 0, TRUE) //heals TOXINLOVERs
M.adjustCloneLoss(-power, 0)
for(var/i in M.all_wounds)
var/datum/wound/W = i
W.on_xadone(power)
var/datum/wound/iter_wound = i
iter_wound.on_xadone(power)
REMOVE_TRAIT(M, TRAIT_DISFIGURED, TRAIT_GENERIC) //fixes common causes for disfiguration
. = 1
metabolization_rate = REAGENTS_METABOLISM * (0.00001 * (M.bodytemperature ** 2) + 0.5)
@@ -196,8 +196,8 @@
M.adjustToxLoss(-power, 0, TRUE)
M.adjustCloneLoss(-power, 0)
for(var/i in M.all_wounds)
var/datum/wound/W = i
W.on_xadone(power)
var/datum/wound/iter_wound = i
iter_wound.on_xadone(power)
REMOVE_TRAIT(M, TRAIT_DISFIGURED, TRAIT_GENERIC)
. = 1
..()
@@ -365,7 +365,7 @@
/datum/reagent/medicine/salglu_solution
name = "Saline-Glucose Solution"
description = "Has a 33% chance per metabolism cycle to heal brute and burn damage. Can be used as a temporary blood substitute."
description = "Has a 33% chance per metabolism cycle to heal brute and burn damage. Can be used as a temporary blood substitute, as well as slowly speeding blood regeneration."
reagent_state = LIQUID
color = "#DCDCDC"
metabolization_rate = 0.5 * REAGENTS_METABOLISM
@@ -373,6 +373,7 @@
taste_description = "sweetness and salt"
var/last_added = 0
var/maximum_reachable = BLOOD_VOLUME_NORMAL - 10 //So that normal blood regeneration can continue with salglu active
var/extra_regen = 0.25 // in addition to acting as temporary blood, also add this much to their actual blood per tick
pH = 5.5
/datum/reagent/medicine/salglu_solution/on_mob_life(mob/living/carbon/M)
@@ -385,7 +386,7 @@
var/amount_to_add = min(M.blood_volume, volume*5)
var/new_blood_level = min(M.blood_volume + amount_to_add, maximum_reachable)
last_added = new_blood_level - M.blood_volume
M.blood_volume = new_blood_level
M.blood_volume = new_blood_level + extra_regen
if(prob(33))
M.adjustBruteLoss(-0.5*REM, 0)
M.adjustFireLoss(-0.5*REM, 0)
@@ -471,8 +472,9 @@
else if(method in list(PATCH, TOUCH))
M.adjustBruteLoss(-1 * reac_volume)
M.adjustFireLoss(-1 * reac_volume)
for(var/datum/wound/burn/burn_wound in C.all_wounds)
burn_wound.regenerate_flesh(reac_volume)
for(var/i in carbies.all_wounds)
var/datum/wound/iter_wound = i
iter_wound.on_synthflesh(reac_volume)
if(show_message)
to_chat(M, "<span class='danger'>You feel your burns and bruises healing! It stings like hell!</span>")
SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "painful_medicine", /datum/mood_event/painful_medicine)
@@ -1592,10 +1594,57 @@
to_chat(C, "[pick(GLOB.wisdoms)]") //give them a random wisdom
..()
// handled in cut wounds process
// helps bleeding wounds clot faster
/datum/reagent/medicine/coagulant
name = "Sanguirite"
description = "A coagulant used to help open cuts clot faster."
description = "A proprietary coagulant used to help bleeding wounds clot faster."
reagent_state = LIQUID
color = "#bb2424"
metabolization_rate = 0.25 * REAGENTS_METABOLISM
overdose_threshold = 20
/// How much base clotting we do per bleeding wound, multiplied by the below number for each bleeding wound
var/clot_rate = 0.25
/// If we have multiple bleeding wounds, we count the number of bleeding wounds, then multiply the clot rate by this^(n) before applying it to each cut, so more cuts = less clotting per cut (though still more total clotting)
var/clot_coeff_per_wound = 0.9
/datum/reagent/medicine/coagulant/on_mob_life(mob/living/carbon/M)
. = ..()
if(!M.blood_volume || !M.all_wounds)
return
var/effective_clot_rate = clot_rate
for(var/i in M.all_wounds)
var/datum/wound/iter_wound = i
if(iter_wound.blood_flow)
effective_clot_rate *= clot_coeff_per_wound
for(var/i in M.all_wounds)
var/datum/wound/iter_wound = i
iter_wound.blood_flow = max(0, iter_wound.blood_flow - effective_clot_rate)
/datum/reagent/medicine/coagulant/overdose_process(mob/living/M)
. = ..()
if(!M.blood_volume)
return
if(prob(15))
M.losebreath += rand(2,4)
M.adjustOxyLoss(rand(1,3))
if(prob(30))
to_chat(M, "<span class='danger'>You can feel your blood clotting up in your veins!</span>")
else if(prob(10))
to_chat(M, "<span class='userdanger'>You feel like your blood has stopped moving!</span>")
if(prob(50))
var/obj/item/organ/lungs/our_lungs = M.getorganslot(ORGAN_SLOT_LUNGS)
our_lungs.applyOrganDamage(1)
else
var/obj/item/organ/heart/our_heart = M.getorganslot(ORGAN_SLOT_HEART)
our_heart.applyOrganDamage(1)
// can be synthesized on station rather than bought. made by grinding a banana peel, heating it up, then mixing the banana peel powder with salglu
/datum/reagent/medicine/coagulant/weak
name = "Synthi-Sanguirite"
description = "A synthetic coagulant used to help bleeding wounds clot faster. Not quite as effective as name brand Sanguirite, especially on patients with lots of cuts."
clot_coeff_per_wound = 0.8
@@ -244,6 +244,11 @@
glass_desc = "The father of all refreshments."
shot_glass_icon_state = "shotglassclear"
/datum/reagent/water/on_mob_life(mob/living/carbon/M)
. = ..()
if(M.blood_volume)
M.blood_volume += 0.1 // water is good for you!
/*
* Water reaction to turf
*/
@@ -334,6 +339,8 @@
return ..()
/datum/reagent/water/holywater/on_mob_life(mob/living/carbon/M)
if(M.blood_volume)
M.blood_volume += 0.1 // water is good for you!
if(!data)
data = list("misc" = 1)
data["misc"]++
@@ -2304,6 +2311,7 @@
metabolization_rate = 0.75 * REAGENTS_METABOLISM // 5u (WOUND_DETERMINATION_CRITICAL) will last for ~17 ticks
/// Whether we've had at least WOUND_DETERMINATION_SEVERE (2.5u) of determination at any given time. No damage slowdown immunity or indication we're having a second wind if it's just a single moderate wound
var/significant = FALSE
self_consuming = TRUE
/datum/reagent/determination/on_mob_end_metabolize(mob/living/carbon/M)
if(significant)
@@ -50,6 +50,18 @@
results = list(/datum/reagent/medicine/salglu_solution = 3)
required_reagents = list(/datum/reagent/consumable/sodiumchloride = 1, /datum/reagent/water = 1, /datum/reagent/consumable/sugar = 1)
/datum/chemical_reaction/baked_banana_peel
results = list(/datum/reagent/consumable/baked_banana_peel = 1)
required_temp = 413.15 // if it's good enough for caramel it's good enough for this
required_reagents = list(/datum/reagent/consumable/banana_peel = 1)
mix_message = "The pulp dries up and takes on a powdery state!"
mob_react = FALSE
/datum/chemical_reaction/coagulant_weak
results = list(/datum/reagent/medicine/coagulant/weak = 3)
required_reagents = list(/datum/reagent/medicine/salglu_solution = 2, /datum/reagent/consumable/baked_banana_peel = 1)
mob_react = FALSE
/datum/chemical_reaction/mine_salve
name = "Miner's Salve"
id = /datum/reagent/medicine/mine_salve
@@ -135,7 +135,7 @@
/obj/item/reagent_containers/hypospray/medipen/ekit
name = "emergency first-aid autoinjector"
desc = "An epinephrine medipen with trace amounts of coagulants and antibiotics to help stabilize bad cuts and burns."
desc = "An epinephrine medipen with extra coagulant and antibiotics to help stabilize bad cuts and burns."
volume = 15
amount_per_transfer_from_this = 15
list_reagents = list(/datum/reagent/medicine/epinephrine = 12, /datum/reagent/medicine/coagulant = 2.5, /datum/reagent/medicine/spaceacillin = 0.5)
@@ -16,6 +16,7 @@
custom_materials = list(/datum/material/iron=10, /datum/material/glass=20)
reagent_flags = TRANSPARENT
custom_price = PRICE_CHEAP_AS_FREE
sharpness = SHARP_POINTY
/obj/item/reagent_containers/syringe/Initialize()
. = ..()