Files
SmArtKar a4f0dcb76f Adds flaying, human butchering and limb surgeries (#94612)
## About The Pull Request

Merry Christmas!

This PR expands on the more gruesome areas of chef content, such as
cannibalism.
Human limbs can now be individually butchered for their meat and skin
with a knife or another butchering implement once the skin has been cut
and retracted (forks now can be used as bootleg retractors). If the limb
contains organs, those will need to be removed first, which also can be
quickly performed with a butchering tool at the cost of damaging the
inhards (head and chest will require the bone to be cut first, which can
be done with a butcher's cleaver if you don't have a saw)
You can also butcher humans whole by right clicking them with a
butchering implement on combat mode, which will attempt to gut/cut apart
the selected limb. Obviously this requires the limb to be prepped first,
so meat hooks/kitchenspikes now allow mobs strung on them to be operated
on without needing drapes. Its a pretty bad spot to be performing
surgeries at though, so beware! Torsos can only be butchered after all
other limbs have been. The gutting/butchering delay is based off the
owner's stat, halving if the limb is detached and doubling if the owner
is still alive and kicking.

<img width="392" height="265" alt="dreamseeker_D7QWbWKStd"
src="https://github.com/user-attachments/assets/050d7c25-3572-4b02-ae93-d8efefe54885"
/>

(The video is too large for github)
https://streamable.com/459a0y

After being butchered, most limbs will leave behind a nonfunctional
skeletal limb (with exceptions like jelly limbs with no skeleton inside)
which is always disabled. Skeleton chests husk their owner, so you'll
need to replace it first.
Gibbers now source their meat from the victim's limbs (and not their
species) at an RNG-based percentage based on the matter bin's tier.

As to allow individual limbs to be butchered, you can now perform (some)
surgeries on individual limbs. There are some obvious restrictions like
zombification or bioware surgeries, but most of the ones that make sense
can be performed on someone's chopped off head as long as you've got the
tools.
Wounds also contribute to surgeries now, major slash wounds count as
cut/open skin (and sealing the vessels would reduce their bleed rate),
and critical blunt wounds count as sawed bones.

I've refactored gibbers, butchering and meat spike code as well as fixed
some backend bugs while I was at it.

## Why It's Good For The Game

While rather gruesome, I feel like the freedom which these mechanics
provide fits us pretty well. We already have plenty of nasty stuff and
this doesn't really go that much further, and a chef serving their own
leg in their dish is pretty funny. (Also you can scrape plasma off
plasmamen bones)
2025-12-31 12:55:39 -06:00

76 lines
3.2 KiB
Plaintext

/datum/surgery_operation/limb/bionecrosis
name = "induce bionecrosis"
rnd_name = "Bionecroplasty (Necrotic Revival)"
desc = "Inject reagents that stimulate the growth of a Romerol tumor inside the patient's brain."
rnd_desc = "An experimental procedure which induces the growth of a Romerol tumor inside the patient's brain."
implements = list(
/obj/item/reagent_containers/syringe = 1,
/obj/item/pen = 3.33,
)
time = 5 SECONDS
operation_flags = OPERATION_MORBID | OPERATION_LOCKED | OPERATION_NOTABLE
all_surgery_states_required = SURGERY_SKIN_OPEN|SURGERY_BONE_SAWED
any_surgery_states_blocked = SURGERY_VESSELS_UNCLAMPED
var/list/zombie_chems = list(
/datum/reagent/medicine/rezadone,
/datum/reagent/toxin/zombiepowder,
)
/datum/surgery_operation/limb/bionecrosis/get_default_radial_image()
return image(get_dynamic_human_appearance(species_path = /datum/species/zombie))
/datum/surgery_operation/limb/bionecrosis/all_required_strings()
. = ..()
. += "the limb must have a brain present"
/datum/surgery_operation/limb/bionecrosis/any_required_strings()
. = ..()
for(var/datum/reagent/chem as anything in zombie_chems)
. += "the patient or tool must contain >1u [chem::name]"
/datum/surgery_operation/limb/bionecrosis/all_blocked_strings()
. = ..()
. += "the limb must not already have a Romerol tumor"
/datum/surgery_operation/limb/bionecrosis/state_check(obj/item/bodypart/limb)
if(locate(/obj/item/organ/zombie_infection) in limb)
return FALSE
if(!(locate(/obj/item/organ/brain) in limb))
return FALSE
return TRUE
/datum/surgery_operation/limb/bionecrosis/snowflake_check_availability(obj/item/bodypart/limb, mob/living/surgeon, obj/item/tool, operated_zone)
for(var/chem in zombie_chems)
if(tool.reagents?.get_reagent_amount(chem) > 1)
return TRUE
if(limb.owner.reagents?.get_reagent_amount(chem) > 1)
return TRUE
return FALSE
/datum/surgery_operation/limb/bionecrosis/on_preop(obj/item/bodypart/limb, mob/living/surgeon, obj/item/tool, list/operation_args)
display_results(
surgeon,
limb.owner,
span_notice("You begin to grow a romerol tumor in [limb.owner]'s brain..."),
span_notice("[surgeon] begins to tinker with [limb.owner]'s brain..."),
span_notice("[surgeon] begins to perform surgery on [limb.owner]'s brain."),
)
display_pain(limb.owner, "Your head pounds with unimaginable pain!") // Same message as other brain surgeries
/datum/surgery_operation/limb/bionecrosis/on_success(obj/item/bodypart/limb, mob/living/surgeon, obj/item/tool, list/operation_args)
display_results(
surgeon,
limb.owner,
span_notice("You succeed in growing a romerol tumor in [limb.owner]'s brain."),
span_notice("[surgeon] successfully grows a romerol tumor in [limb.owner]'s brain!"),
span_notice("[surgeon] completes the surgery on [limb.owner]'s brain."),
)
display_pain(limb.owner, "Your head goes totally numb for a moment, the pain is overwhelming!")
if(locate(/obj/item/organ/zombie_infection) in limb) // they got another one mid surgery? whatever
return
var/obj/item/organ/zombie_infection/z_infection = new()
z_infection.Insert(limb.owner)
for(var/chem in zombie_chems)
tool.reagents?.remove_reagent(chem, 1)
limb.owner.reagents?.remove_reagent(chem, 1)