mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
@@ -320,7 +320,8 @@
|
||||
|
||||
// Internal wounds get worse over time. Low temperatures (cryo) stop them.
|
||||
if(W.internal && !W.is_treated() && owner.bodytemperature >= 170)
|
||||
W.open_wound(0.1 * wound_update_accuracy)
|
||||
if(!owner.reagents.has_reagent("bicaridine")) //bicard stops internal wounds from growing bigger with time
|
||||
W.open_wound(0.1 * wound_update_accuracy)
|
||||
owner.vessel.remove_reagent("blood",0.07 * W.damage * wound_update_accuracy)
|
||||
if(prob(1 * wound_update_accuracy))
|
||||
owner.custom_pain("You feel a stabbing pain in your [display_name]!",1)
|
||||
|
||||
@@ -27,11 +27,12 @@
|
||||
H.internal_organs[src.name] = src
|
||||
src.owner = H
|
||||
|
||||
/datum/organ/internal/proc/take_damage(amount)
|
||||
/datum/organ/internal/proc/take_damage(amount, var/silent=0)
|
||||
src.damage += amount
|
||||
|
||||
var/datum/organ/external/parent = owner.get_organ(parent_organ)
|
||||
owner.custom_pain("Something inside your [parent.display_name] hurts a lot.", 1)
|
||||
if (!silent)
|
||||
owner.custom_pain("Something inside your [parent.display_name] hurts a lot.", 1)
|
||||
|
||||
/****************************************************
|
||||
INTERNAL ORGANS DEFINES
|
||||
@@ -62,6 +63,21 @@
|
||||
|
||||
process()
|
||||
if(owner.life_tick % process_accuracy == 0)
|
||||
//High toxins levels are dangerous
|
||||
if(owner.getToxLoss() >= 60 && !owner.reagents.has_reagent("anti_toxin"))
|
||||
//Healthy liver suffers on its own
|
||||
if (src.damage < min_broken_damage)
|
||||
src.damage += 0.2 * process_accuracy
|
||||
//Damaged one shares the fun
|
||||
else
|
||||
var/victim = pick(owner.internal_organs)
|
||||
var/datum/organ/internal/O = owner.internal_organs[victim]
|
||||
O.damage += 0.2 * process_accuracy
|
||||
|
||||
//Detox can heal small amounts of damage
|
||||
if (owner.reagents.has_reagent("anti_toxin") && src.damage < src.min_bruised_damage)
|
||||
src.damage -= 0.2 * process_accuracy
|
||||
|
||||
// Damaged liver means some chemicals are very dangerous
|
||||
if(src.damage >= src.min_bruised_damage)
|
||||
for(var/datum/reagent/R in owner.reagents.reagent_list)
|
||||
|
||||
@@ -9,6 +9,12 @@ mob/var/next_pain_time = 0
|
||||
// amount is a num from 1 to 100
|
||||
mob/proc/pain(var/partname, var/amount, var/force, var/burning = 0)
|
||||
if(stat >= 2) return
|
||||
if(reagents.has_reagent("tramadol"))
|
||||
return
|
||||
if(reagents.has_reagent("oxycodone"))
|
||||
return
|
||||
if(analgesic)
|
||||
return
|
||||
if(world.time < next_pain_time && !force)
|
||||
return
|
||||
if(amount > 10 && istype(src,/mob/living/carbon/human))
|
||||
|
||||
Reference in New Issue
Block a user