From a645a0c2365d7c2528abc78a4cb742121a4eaa3e Mon Sep 17 00:00:00 2001 From: Doubleumc Date: Sun, 7 Jul 2024 17:28:44 -0400 Subject: [PATCH] initial --- code/__DEFINES/mobs.dm | 1 - code/_globalvars/bitfields.dm | 1 - code/game/machinery/medical_pod/autodoc.dm | 34 ---- code/modules/cm_preds/yaut_weapons.dm | 1 - code/modules/mob/living/carbon/human/human.dm | 24 +-- code/modules/organs/limbs.dm | 20 -- .../chemistry_properties/prop_negative.dm | 4 +- .../chemistry_properties/prop_positive.dm | 1 - code/modules/surgery/face.dm | 174 ------------------ colonialmarines.dme | 1 - 10 files changed, 8 insertions(+), 253 deletions(-) delete mode 100644 code/modules/surgery/face.dm diff --git a/code/__DEFINES/mobs.dm b/code/__DEFINES/mobs.dm index 77f2393e6542..3639ef1ccd13 100644 --- a/code/__DEFINES/mobs.dm +++ b/code/__DEFINES/mobs.dm @@ -113,7 +113,6 @@ #define CANROOT (1<<6) #define GODMODE (1<<12) #define FAKEDEATH (1<<13) //Replaces stuff like changeling.changeling_fakedeath -#define DISFIGURED (1<<14) //I'll probably move this elsewhere if I ever get wround to writing a bitflag mob-damage system #define XENO_HOST (1<<15) //Tracks whether we're gonna be a baby alien's mummy. #define IMMOBILE_ACTION (1<<16) // If you are performing an action that prevents you from being pushed by your own people. #define PERMANENTLY_DEAD (1<<17) diff --git a/code/_globalvars/bitfields.dm b/code/_globalvars/bitfields.dm index facc2b951ad3..d3fc9994414a 100644 --- a/code/_globalvars/bitfields.dm +++ b/code/_globalvars/bitfields.dm @@ -356,7 +356,6 @@ DEFINE_BITFIELD(status_flags, list( "PASSEMOTES" = PASSEMOTES, "GODMODE" = GODMODE, "FAKEDEATH" = FAKEDEATH, - "DISFIGURED" = DISFIGURED, "XENO_HOST" = XENO_HOST, "IMMOBILE_ACTION" = IMMOBILE_ACTION, "PERMANENTLY_DEAD" = PERMANENTLY_DEAD, diff --git a/code/game/machinery/medical_pod/autodoc.dm b/code/game/machinery/medical_pod/autodoc.dm index ef335c6841e6..b5fd43b35651 100644 --- a/code/game/machinery/medical_pod/autodoc.dm +++ b/code/game/machinery/medical_pod/autodoc.dm @@ -238,11 +238,6 @@ surgery_list += create_autodoc_surgery(L,ORGAN_SURGERY,"damage",0,I) organdamagesurgery++ - if(istype(L,/obj/limb/head)) - var/obj/limb/head/H = L - if(H.disfigured) - surgery_list += create_autodoc_surgery(L,LIMB_SURGERY,"facial") - if(L.status & LIMB_BROKEN) surgery_list += create_autodoc_surgery(L,LIMB_SURGERY,"broken") if(L.status & LIMB_DESTROYED) @@ -521,20 +516,6 @@ if(!surgery) break close_incision(H,S.limb_ref) - if("facial") - if(prob(30)) visible_message("[icon2html(src, viewers(src))] \The [src] speaks: Beginning Facial Reconstruction Surgery."); - if(S.unneeded) - sleep(UNNEEDED_DELAY) - visible_message("[icon2html(src, viewers(src))] \The [src] speaks: Procedure has been deemed unnecessary."); - surgery_todo_list -= S - continue - if(istype(S.limb_ref, /obj/limb/head)) - var/obj/limb/head/F = S.limb_ref - sleep(SCALPEL_MAX_DURATION + HEMOSTAT_MAX_DURATION + RETRACTOR_MAX_DURATION + CAUTERY_MAX_DURATION) - F.remove_all_bleeding(TRUE) - F.disfigured = 0 - F.owner.name = F.owner.get_visible_name() - if("open") if(prob(30)) visible_message("[icon2html(src, viewers(src))] \The [src]croaks: Closing surgical incision."); close_encased(H,S.limb_ref) @@ -753,9 +734,6 @@ if("shrapnel") surgeryqueue["shrapnel"] = 1 dat += "Shrapnel Removal Surgery" - if("facial") - surgeryqueue["facial"] = 1 - dat += "Facial Reconstruction Surgery" if("open") surgeryqueue["open"] = 1 dat += "Close Open Incisions" @@ -902,18 +880,6 @@ N.fields["autodoc_manual"] += create_autodoc_surgery(null,LIMB_SURGERY,"shrapnel",1) updateUsrDialog() - if(href_list["facial"]) - for(var/obj/limb/L in connected.occupant.limbs) - if(L) - if(istype(L,/obj/limb/head)) - var/obj/limb/head/J = L - if(J.disfigured) - N.fields["autodoc_manual"] += create_autodoc_surgery(L,LIMB_SURGERY,"facial") - else - N.fields["autodoc_manual"] += create_autodoc_surgery(L,LIMB_SURGERY,"facial",1) - updateUsrDialog() - break - if(href_list["open"]) for(var/obj/limb/L in connected.occupant.limbs) if(L) diff --git a/code/modules/cm_preds/yaut_weapons.dm b/code/modules/cm_preds/yaut_weapons.dm index 2db3c2ca4b68..b6d595c37b96 100644 --- a/code/modules/cm_preds/yaut_weapons.dm +++ b/code/modules/cm_preds/yaut_weapons.dm @@ -584,7 +584,6 @@ SPAN_DANGER("[victim] is missing \his head. Pelts like this just aren't the same... You peel the skin around the stump loose with your [tool.name].")) else victim.apply_damage(10, BRUTE, v_head, sharp = TRUE) - v_head.disfigured = TRUE create_leftovers(victim, has_meat = FALSE, skin_amount = 1) if(victim.h_style == "Bald") //you can't scalp someone with no hair. user.visible_message(SPAN_DANGER("[user] makes some rough cuts on [victim]'s head and face with \a [tool]."), diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 213d037afe6e..61738e236360 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -338,23 +338,15 @@ return species.handle_paygrades(id.paygrade, size, gender) -//repurposed proc. Now it combines get_id_name() and get_face_name() to determine a mob's name variable. Made into a separate proc as it'll be useful elsewhere +//repurposed proc. Now it combines get_id_name() and real_name to determine a mob's name variable. Made into a separate proc as it'll be useful elsewhere /mob/living/carbon/human/proc/get_visible_name() if(wear_mask && (wear_mask.flags_inv_hide & HIDEFACE) ) //Wearing a mask which hides our face, use id-name if possible return get_id_name("Unknown") if(head && (head.flags_inv_hide & HIDEFACE) ) return get_id_name("Unknown") //Likewise for hats - var/face_name = get_face_name() var/id_name = get_id_name("") - if(id_name && (id_name != face_name)) - return "[face_name] (as [id_name])" - return face_name - -//Returns "Unknown" if facially disfigured and real_name if not. Useful for setting name when polyacided or when updating a human's name variable -/mob/living/carbon/human/proc/get_face_name() - var/obj/limb/head/head = get_limb("head") - if(!head || head.disfigured || (head.status & LIMB_DESTROYED) || !real_name) //disfigured. use id-name if possible - return "Unknown" + if(id_name && (id_name != real_name)) + return "[real_name] (as [id_name])" return real_name //gets name from ID or PDA itself, ID inside PDA doesn't matter @@ -907,8 +899,6 @@ var/obj/limb/head/h = get_limb("head") if(QDELETED(h)) h = get_limb("synthetic head") - else - h.disfigured = 0 name = get_visible_name() if(species && !(species.flags & NO_BLOOD)) @@ -1712,15 +1702,15 @@ /mob/living/carbon/human/on_knockedout_trait_gain(datum/source) . = ..() - + update_execute_hud() - + return . /mob/living/carbon/human/on_knockedout_trait_loss(datum/source) . = ..() update_execute_hud() - + return . - + diff --git a/code/modules/organs/limbs.dm b/code/modules/organs/limbs.dm index 37ebac207c28..ea2006c924c4 100644 --- a/code/modules/organs/limbs.dm +++ b/code/modules/organs/limbs.dm @@ -1424,7 +1424,6 @@ treat_grafted var tells it to apply to grafted but unsalved wounds, for burn kit has_stump_icon = TRUE splint_icon_amount = 4 bandage_icon_amount = 4 - var/disfigured = 0 //whether the head is disfigured. var/eyes_r var/eyes_g @@ -1462,25 +1461,6 @@ treat_grafted var tells it to apply to grafted but unsalved wounds, for burn kit mob/attack_source = null,\ brute_reduced_by = -1, burn_reduced_by = -1) . = ..() - if (!disfigured) - if (brute_dam > 50 || brute_dam > 40 && prob(50)) - disfigure("brute") - if (burn_dam > 40) - disfigure("burn") - -/obj/limb/head/proc/disfigure(type = "brute") - if (disfigured) - return - if(type == "brute") - owner.visible_message(SPAN_DANGER("You hear a sickening cracking sound coming from \the [owner]'s face."), \ - SPAN_DANGER("Your face becomes an unrecognizible mangled mess!"), \ - SPAN_DANGER("You hear a sickening crack.")) - else - owner.visible_message(SPAN_DANGER("[owner]'s face melts away, turning into a mangled mess!"), \ - SPAN_DANGER("Your face melts off!"), \ - SPAN_DANGER("You hear a sickening sizzle.")) - disfigured = 1 - owner.name = owner.get_visible_name() /obj/limb/head/reset_limb_surgeries() for(var/zone in list("head", "eyes", "mouth")) diff --git a/code/modules/reagents/chemistry_properties/prop_negative.dm b/code/modules/reagents/chemistry_properties/prop_negative.dm index 783584102182..e7d40c3da31f 100644 --- a/code/modules/reagents/chemistry_properties/prop_negative.dm +++ b/code/modules/reagents/chemistry_properties/prop_negative.dm @@ -137,11 +137,9 @@ if(affecting) if(affecting.take_damage(4, 2)) H.UpdateDamageIcon() - if(prob(meltprob)) //Applies disfigurement + if(prob(meltprob)) if(H.pain.feels_pain) H.emote("scream") - H.status_flags |= DISFIGURED - H.name = H.get_visible_name() else M.take_limb_damage(min(6, volume)) return diff --git a/code/modules/reagents/chemistry_properties/prop_positive.dm b/code/modules/reagents/chemistry_properties/prop_positive.dm index 40867892afbd..76f881e5f977 100644 --- a/code/modules/reagents/chemistry_properties/prop_positive.dm +++ b/code/modules/reagents/chemistry_properties/prop_positive.dm @@ -949,7 +949,6 @@ /datum/chem_property/positive/aiding/process(mob/living/M, potency = 1, delta_time) M.disabilities = 0 M.sdisabilities = 0 - M.status_flags &= ~DISFIGURED if(ishuman(M)) var/mob/living/carbon/human/H = M H.name = H.get_visible_name() diff --git a/code/modules/surgery/face.dm b/code/modules/surgery/face.dm deleted file mode 100644 index 7d13c0ed5675..000000000000 --- a/code/modules/surgery/face.dm +++ /dev/null @@ -1,174 +0,0 @@ -//Procedures in this file: Facial reconstruction surgery -////////////////////////////////////////////////////////////////// -// FACE SURGERY // -////////////////////////////////////////////////////////////////// - -/datum/surgery/face_fix - name = "Facial Reconstruction" - possible_locs = list("mouth") - invasiveness = list(SURGERY_DEPTH_SURFACE) - pain_reduction_required = PAIN_REDUCTION_HEAVY - required_surgery_skill = SKILL_SURGERY_TRAINED - steps = list( - /datum/surgery_step/facial_incision, - /datum/surgery_step/mend_vocals, - /datum/surgery_step/pull_skin, - /datum/surgery_step/cauterize/close_facial_incision, - ) - -/datum/surgery/face_fix/can_start(mob/user, mob/living/carbon/patient, obj/limb/L, obj/item/tool) - var/obj/limb/head/H = L - return H && H.disfigured - -//------------------------------------ - -/datum/surgery_step/facial_incision - name = "Make Facial Incision" - desc = "make facial incisions" - tools = SURGERY_TOOLS_INCISION - time = 4 SECONDS - -/datum/surgery_step/facial_incision/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You start to cut open [target]'s face and neck with \the [tool]."), - SPAN_NOTICE("[user] starts to cut open your face and neck with \the [tool]."), - SPAN_NOTICE("[user] starts to cut open [target]'s face and neck with \the [tool].")) - - log_interact(user, target, "[key_name(user)] began to cut open [key_name(target)]'s face and neck with \the [tool].") - target.custom_pain("Your face is being cut apart!", 1) - -/datum/surgery_step/facial_incision/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You finish opening incisions on [target]'s face and neck."), - SPAN_NOTICE("[user] finishes opening incisions on your face and neck."), - SPAN_NOTICE("[user] finishes opening incisions on [target]'s face and neck.")) - - target.incision_depths[target_zone] = SURGERY_DEPTH_SHALLOW - log_interact(user, target, "[key_name(user)] cut open [key_name(target)]'s face and neck with \the [tool].") - -/datum/surgery_step/facial_incision/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_DANGER("Your hand slips, slicing [target]'s throat wth \the [tool]!"), - SPAN_DANGER("[user]'s hand slips, slicing [target]'s throat wth \the [tool]!"), - SPAN_DANGER("[user]'s hand slips, slicing [target]'s throat wth \the [tool]!")) - - log_interact(user, target, "[key_name(user)] failed to cut open [key_name(target)]'s face and neck with \the [tool].") - - target.apply_damage(40, BRUTE, target_zone) - target.losebreath += 20 - user.add_blood(target.get_blood_color(), BLOOD_BODY|BLOOD_HANDS) - return FALSE - -//------------------------------------ - -/datum/surgery_step/mend_vocals - name = "Mend Vocal Cords" - desc = "mend the vocal cords" - tools = SURGERY_TOOLS_PINCH - time = 3 SECONDS - -/datum/surgery_step/mend_vocals/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You start mending [target]'s vocal cords with \the [tool]."), - SPAN_NOTICE("[user] starts to mend your vocal cords with \the [tool]."), - SPAN_NOTICE("[user] starts to mend [target]'s vocal cords with \the [tool].")) - - log_interact(user, target, "[key_name(user)] began to mend [key_name(target)]'s vocal cords with \the [tool].") - target.custom_pain("The insides of your throat are being pinched and pulled at!", 1) - -/datum/surgery_step/mend_vocals/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You mend [target]'s vocal cords."), - SPAN_NOTICE("[user] mends your vocal cords."), - SPAN_NOTICE("[user] mends [target]'s vocal cords.")) - - log_interact(user, target, "[key_name(user)] mended [key_name(target)]'s vocal cords with \the [tool].") - -/datum/surgery_step/mend_vocals/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_WARNING("Your hand slips, clamping [user]'s trachea shut for a moment with \the [tool]!"), - SPAN_DANGER("[user]'s hand slips, clamping your trachea shut for a moment with \the [tool]!"), - SPAN_WARNING("[user]'s hand slips, clamping [target]'s trachea shut for a moment with \the [tool]!")) - - log_interact(user, target, "[key_name(user)] failed to mend [key_name(target)]'s vocal cords with \the [tool].") - - target.losebreath += 10 - return FALSE - -//------------------------------------ - -/datum/surgery_step/pull_skin - name = "Reconstruct Facial Features" - desc = "reconstruct the face" - tools = SURGERY_TOOLS_PRY_DELICATE - time = 3 SECONDS - -/datum/surgery_step/pull_skin/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You start pulling the skin on [target]'s face back into shape with \the [tool]."), - SPAN_NOTICE("[user] starts to pull the skin on your face back into shape with \the [tool]."), - SPAN_NOTICE("[user] starts to pull the skin on [target]'s face back into shape with \the [tool].")) - - log_interact(user, target, "[key_name(user)] began to pull the skin on [key_name(target)]'s face back in place with \the [tool].") - target.custom_pain("Your face hurts!", 1) - -/datum/surgery_step/pull_skin/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You reconstruct [target]'s facial features."), - SPAN_NOTICE("[user] reconstructs your facial features."), - SPAN_NOTICE("[user] reconstructs [target]'s facial features.")) - - log_interact(user, target, "[key_name(user)] pulled the skin on [key_name(target)]'s face back in place with \the [tool].") - -/datum/surgery_step/pull_skin/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_WARNING("Your hand slips, tearing skin on [target]'s face with \the [tool]!"), - SPAN_WARNING("[user]'s hand slips, tearing skin on your face with \the [tool]!"), - SPAN_WARNING("[user]'s hand slips, tearing skin on [target]'s face with \the [tool]!")) - - log_interact(user, target, "[key_name(user)] failed to pull the skin on [key_name(target)]'s face back in place with \the [tool].") - - target.apply_damage(10, BRUTE, target_zone) - return FALSE - -//------------------------------------ - -/datum/surgery_step/cauterize/close_facial_incision - name = "Close Facial Incisions" - desc = "close the facial incisions" - time = 5 SECONDS - -/datum/surgery_step/cauterize/close_facial_incision/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You begin to cauterize the incisions on [target]'s face and neck with \the [tool]."), - SPAN_NOTICE("[user] begins to cauterize the incisions on your face and neck with \the [tool]."), - SPAN_NOTICE("[user] begins to cauterize the incisions on [target]'s face and neck with \the [tool].")) - - target.custom_pain("Your face is being burned!", 1) - - log_interact(user, target, "[key_name(user)] began to cauterize [key_name(target)]'s face and neck with \the [tool].") - -/datum/surgery_step/cauterize/close_facial_incision/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_NOTICE("You cauterize the incisions on [target]'s face and neck."), - SPAN_NOTICE("[user] cauterizes the incisions on your face and neck."), - SPAN_NOTICE("[user] cauterizes the incision on [target]'s face and neck.")) - - log_interact(user, target, "[key_name(user)] cauterized [key_name(target)]'s face and neck with \the [tool], ending [surgery].") - - target.incision_depths[target_zone] = SURGERY_DEPTH_SURFACE - surgery.affected_limb.remove_all_bleeding(TRUE) - var/obj/limb/head/H = surgery.affected_limb - H.disfigured = FALSE - H.owner.name = H.owner.get_visible_name() - -/datum/surgery_step/cauterize/close_facial_incision/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, tool_type, datum/surgery/surgery) - user.affected_message(target, - SPAN_WARNING("Your hand slips, leaving a small burn on [target]'s face!"), - SPAN_WARNING("[user]'s hand slips, leaving a small burn on your face!"), - SPAN_WARNING("[user]'s hand slips, leaving a small burn on [target]'s face!")) - - log_interact(user, target, "[key_name(user)] failed to cauterize [key_name(target)]'s face and neck with \the [tool].") - - target.apply_damage(5, BURN, target_zone) - return FALSE diff --git a/colonialmarines.dme b/colonialmarines.dme index 5193cd3571cb..45d6f007d37f 100644 --- a/colonialmarines.dme +++ b/colonialmarines.dme @@ -2332,7 +2332,6 @@ #include "code\modules\surgery\brainrepair.dm" #include "code\modules\surgery\chestburster.dm" #include "code\modules\surgery\eye.dm" -#include "code\modules\surgery\face.dm" #include "code\modules\surgery\generic.dm" #include "code\modules\surgery\headreattach.dm" #include "code\modules\surgery\implant.dm"