mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 12:37:26 +01:00
Moved surgery from WIP to modules, since it's not really that WIP anymore.
Split one huge file into several smaller ones for readability.
This commit is contained in:
@@ -0,0 +1,81 @@
|
||||
//Procedures in this file: Appendectomy
|
||||
//////////////////////////////////////////////////////////////////
|
||||
// APPENDECTOMY //
|
||||
//////////////////////////////////////////////////////////////////
|
||||
|
||||
/datum/surgery_step/appendectomy/
|
||||
var/datum/organ/external/groin
|
||||
can_use(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
if (target_zone != "groin")
|
||||
return 0
|
||||
groin = target.get_organ("groin")
|
||||
if (!groin)
|
||||
return 0
|
||||
if (groin.open < 2)
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/datum/surgery_step/appendectomy/cut_appendix
|
||||
required_tool = /obj/item/weapon/scalpel
|
||||
allowed_tools = list(/obj/item/weapon/shard, /obj/item/weapon/kitchenknife)
|
||||
|
||||
min_duration = 70
|
||||
max_duration = 90
|
||||
|
||||
can_use(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
return ..() && target.op_stage.appendix == 0
|
||||
|
||||
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
user.visible_message("[user] starts to separating [target]'s appendix from the abdominal wall with \the [tool].", \
|
||||
"You start to separating [target]'s appendix from the abdominal wall with \the [tool]." )
|
||||
target.custom_pain("The pain in your abdomen is living hell!",1)
|
||||
|
||||
end_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
user.visible_message("\blue [user] has separated [target]'s appendix with \the [tool]." , \
|
||||
"\blue You have separated [target]'s appendix with \the [tool].")
|
||||
target.op_stage.appendix = 1
|
||||
if (ishuman(user) && prob(40)) user:bloody_hands(target, 0)
|
||||
|
||||
fail_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/groin = target.get_organ("groin")
|
||||
user.visible_message("\red [user]'s hand slips, slicing an artery inside [target]'s abdomen with \the [tool]!", \
|
||||
"\red Your hand slips, slicing an artery inside [target]'s abdomen with \the [tool]!")
|
||||
groin.createwound(CUT, 50, 1)
|
||||
if (ishuman(user))
|
||||
user:bloody_body(target)
|
||||
|
||||
/datum/surgery_step/appendectomy/remove_appendix
|
||||
required_tool = /obj/item/weapon/hemostat
|
||||
allowed_tools = list(/obj/item/weapon/wirecutters)
|
||||
|
||||
min_duration = 60
|
||||
max_duration = 80
|
||||
|
||||
can_use(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
return ..() && target.op_stage.appendix == 1
|
||||
|
||||
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
user.visible_message("[user] starts removing [target]'s appendix with \the [tool].", \
|
||||
"You start removing [target]'s appendix with \the [tool].")
|
||||
target.custom_pain("Someone's ripping out your bowels!",1)
|
||||
|
||||
end_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
user.visible_message("\blue [user] has removed [target]'s appendix with \the [tool].", \
|
||||
"\blue You have removed [target]'s appendix with \the [tool].")
|
||||
var/app = 0
|
||||
for(var/datum/disease/appendicitis/appendicitis in target.viruses)
|
||||
app = 1
|
||||
appendicitis.cure()
|
||||
target.resistances += appendicitis
|
||||
if (app)
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/appendix/inflamed(get_turf(target))
|
||||
else
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/appendix(get_turf(target))
|
||||
target.op_stage.appendix = 2
|
||||
if (ishuman(user) && prob(40)) user:bloody_hands(target, 0)
|
||||
|
||||
fail_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\red [user]'s hand slips, nicking internal organs in [target]'s abdomen with \the [tool]!", \
|
||||
"\red Your hand slips, nicking internal organs in [target]'s abdomen with \the [tool]!")
|
||||
affected.createwound(BRUISE, 20)
|
||||
Reference in New Issue
Block a user