Well it compiles; just synthtissue and TongueLoss now.

This commit is contained in:
Fermi
2019-09-19 01:14:12 +01:00
parent dfa40a4b22
commit 107dd67cbe
29 changed files with 107 additions and 106 deletions
+9 -12
View File
@@ -4,7 +4,7 @@
/datum/surgery/graft_synthtissue
name = "Graft_synthtissue"
target_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
species = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
possible_locs = list(BODY_ZONE_CHEST)
steps = list(
/datum/surgery_step/incise,
@@ -16,8 +16,8 @@
/datum/surgery_step/close
)
//repair lungs step
/datum/surgery_step/repair_synthtissue
//repair organs
/datum/surgery_step/graft_synthtissue
name = "graft synthtissue"
implements = list(/obj/item/hemostat = 100, TOOL_SCREWDRIVER = 35, /obj/item/pen = 15)
repeatable = TRUE
@@ -25,10 +25,8 @@
chems_needed = list("synthtissue")
var/obj/item/organ/chosen_organ
//Repair lungs
/datum/surgery_step/repair_synthtissue/preop(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool, datum/surgery/surgery)
if(implement_type in implements_extract)
current_type = "insert"
/datum/surgery_step/graft_synthtissue/preop(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool, datum/surgery/surgery)
if(implement_type in implements)
var/list/organs = target.getorganszone(target_zone)
if(!organs.len)
to_chat(user, "<span class='notice'>There are no targetable organs in [target]'s [parse_zone(target_zone)]!</span>")
@@ -39,24 +37,23 @@
organs -= O
organs[O.name] = O
chosen_organ = input("Remove which organ?", "Surgery", null, null) as null|anything in organs
if(chosen_organ.organ_flags & ORGAN_FAILING))
if(chosen_organ.organ_flags & ORGAN_FAILING)
to_chat(user, "<span class='notice'>[target]'s [chosen_organ] is too damaged to repair graft onto!</span>")
return -1
user.visible_message("[user] begins to repair damaged portions of [target]'s [chosen_organ].</span>")
/datum/surgery_step/repair_synthtissue/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
/datum/surgery_step/graft_synthtissue/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
if((!chosen_organ)||(chosen_organ.organ_flags & ORGAN_FAILING))
to_chat(user, "[target] has no [chosen_organ] capable of repair!")
else
user.visible_message("[user] successfully repairs part of [target]'s [chosen_organ].", "<span class='notice'>You succeed in repairing parts of [target]'s [chosen_organ].</span>")
chosen_organ.applyOrganDamage(-10)
/datum/surgery_step/repair_synthtissue/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
/datum/surgery_step/graft_synthtissue/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
if((!chosen_organ)||(chosen_organ.organ_flags & ORGAN_FAILING))
to_chat(user, "[target] has no [chosen_organ] capable of repair!")
else
user.visible_message("<span class='warning'>[user] accidentally damages part of [target]'s [chosen_organ]!</span>", "<span class='warning'>You damage [target]'s [chosen_organ]! Apply more synthtissue if it's run out.</span>")
chosen_organ.applyOrganDamage(10)
return FALSE