mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-03 21:42:06 +00:00
* This tail refactor turned into an organ refactor. Funny how that works. * Firstly, fixing all the conflicts. * Fixes all our maps (hopefully) * Actually, this should fix pod people hair :) * Almost everything is working, just two major things to fix * Fixed a certain kind of external organ * Cleaning up some more stuff * Turned tail_cat into tail because why the fuck are they separate? * Moved all the tails into tails.dmi because that was just dumb to have like 3 in a different file * Adds relevant_layers to organs to help with rendering * Makes stored_feature_id also check mutant_bodyparts * Fixes the icon_state names of ALL the tails (pain) * Fixes wagging, gotta refactor most mutant bodyparts later on * I Love Added Failures * Fixed some organs that slipped through my searches * This could possibly fix the CI for this? * It doesn't look like it did fix it * This will make it pass, even if it's ugly as sin. * Fixed Felinids having a weird ghost tail * Fixes instances of snouts and tails not being properly colored Co-authored-by: Kapu1178 <75460809+Kapu1178@users.noreply.github.com> Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
63 lines
3.1 KiB
Plaintext
63 lines
3.1 KiB
Plaintext
/datum/surgery/brain_surgery
|
|
name = "Brain surgery"
|
|
steps = list(
|
|
/datum/surgery_step/incise,
|
|
/datum/surgery_step/retract_skin,
|
|
/datum/surgery_step/saw,
|
|
/datum/surgery_step/clamp_bleeders,
|
|
/datum/surgery_step/fix_brain,
|
|
/datum/surgery_step/close)
|
|
|
|
target_mobtypes = list(/mob/living/carbon/human)
|
|
possible_locs = list(BODY_ZONE_HEAD)
|
|
requires_bodypart_type = 0
|
|
|
|
/datum/surgery_step/fix_brain
|
|
name = "fix brain"
|
|
implements = list(
|
|
TOOL_HEMOSTAT = 85,
|
|
TOOL_SCREWDRIVER = 35,
|
|
/obj/item/pen = 15) //don't worry, pouring some alcohol on their open brain will get that chance to 100
|
|
repeatable = TRUE
|
|
time = 100 //long and complicated
|
|
preop_sound = 'sound/surgery/hemostat1.ogg'
|
|
success_sound = 'sound/surgery/hemostat1.ogg'
|
|
failure_sound = 'sound/surgery/organ2.ogg'
|
|
|
|
/datum/surgery/brain_surgery/can_start(mob/user, mob/living/carbon/target)
|
|
var/obj/item/organ/internal/brain/target_brain = target.getorganslot(ORGAN_SLOT_BRAIN)
|
|
if(!target_brain)
|
|
return FALSE
|
|
return TRUE
|
|
|
|
/datum/surgery_step/fix_brain/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
|
|
display_results(user, target, span_notice("You begin to fix [target]'s brain..."),
|
|
span_notice("[user] begins to fix [target]'s brain."),
|
|
span_notice("[user] begins to perform surgery on [target]'s brain."))
|
|
display_pain(target, "Your head pounds with unimaginable pain!")
|
|
|
|
/datum/surgery_step/fix_brain/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery, default_display_results = FALSE)
|
|
display_results(user, target, span_notice("You succeed in fixing [target]'s brain."),
|
|
span_notice("[user] successfully fixes [target]'s brain!"),
|
|
span_notice("[user] completes the surgery on [target]'s brain."))
|
|
display_pain(target, "The pain in your head receeds, thinking becomes a bit easier!")
|
|
if(target.mind?.has_antag_datum(/datum/antagonist/brainwashed))
|
|
target.mind.remove_antag_datum(/datum/antagonist/brainwashed)
|
|
target.setOrganLoss(ORGAN_SLOT_BRAIN, target.getOrganLoss(ORGAN_SLOT_BRAIN) - 50) //we set damage in this case in order to clear the "failing" flag
|
|
target.cure_all_traumas(TRAUMA_RESILIENCE_SURGERY)
|
|
if(target.getOrganLoss(ORGAN_SLOT_BRAIN) > 0)
|
|
to_chat(user, "[target]'s brain looks like it could be fixed further.")
|
|
return ..()
|
|
|
|
/datum/surgery_step/fix_brain/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
|
|
if(target.getorganslot(ORGAN_SLOT_BRAIN))
|
|
display_results(user, target, span_warning("You screw up, causing more damage!"),
|
|
span_warning("[user] screws up, causing brain damage!"),
|
|
span_notice("[user] completes the surgery on [target]'s brain."))
|
|
display_pain(target, "Your head throbs with horrible pain; thinking hurts!")
|
|
target.adjustOrganLoss(ORGAN_SLOT_BRAIN, 60)
|
|
target.gain_trauma_type(BRAIN_TRAUMA_SEVERE, TRAUMA_RESILIENCE_LOBOTOMY)
|
|
else
|
|
user.visible_message(span_warning("[user] suddenly notices that the brain [user.p_they()] [user.p_were()] working on is not there anymore."), span_warning("You suddenly notice that the brain you were working on is not there anymore."))
|
|
return FALSE
|