Brainmed Code Quality + Organ Scarring (#7645)

Organ scarring has been made into a better system.

New healthdoll.

Other misc code cleanup attempts.

Fixes #7647
This commit is contained in:
Matt Atlas
2019-12-14 00:10:53 +02:00
committed by Erki
parent 480f537afb
commit 37abd8f771
24 changed files with 356 additions and 332 deletions
+1 -1
View File
@@ -70,7 +70,7 @@
if(I && I.damage > 0 && !BP_IS_ROBOTIC(I))
user.visible_message("<span class='notice'>[user] treats damage to [target]'s [I.name] with [tool_name].</span>", \
"<span class='notice'>You treat damage to [target]'s [I.name] with [tool_name].</span>" )
I.surgical_fix()
I.surgical_fix(user)
var/obj/item/organ/internal/brain/sponge = target.internal_organs_by_name[BP_BRAIN]
if(sponge && istype(I, sponge))
target.cure_all_traumas(cure_type = CURE_SURGERY)
+2 -4
View File
@@ -21,7 +21,7 @@
return 0
var/obj/item/organ/external/affected = target.get_organ(target_zone)
if(!affected)
if(!affected)
return
return affected.open >= 2 && (affected.status & ORGAN_ARTERY_CUT)
@@ -40,7 +40,7 @@
affected.status &= ~ORGAN_ARTERY_CUT
affected.update_damages()
if(ishuman(user) && prob(40))
if(ishuman(user) && prob(40))
user:bloody_hands(target, 0)
/datum/surgery_step/fix_vein/fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -103,8 +103,6 @@
user.visible_message("<span class='notice'>[user] has cut away necrotic tissue from [target]'s [organ_to_fix.name] with \the [tool].</span>", \
"<span class='notice'>You have cut away necrotic tissue in [target]'s [organ_to_fix.name] with \the [tool].</span>")
organ_to_fix.status &= ~ORGAN_DEAD
if(organ_to_fix.max_damage > 15)
organ_to_fix.max_damage -= rand(1, 10) //remove some max damage, since we cut away the organ
/datum/surgery_step/fix_dead_tissue/fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/obj/item/organ/external/affected = target.get_organ(target_zone)