mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-11 23:23:55 +01:00
Merge branch 'bleeding-edge-freeze' of https://github.com/Baystation12/Baystation12 into bs12_with_tgport
Conflicts: icons/turf/areas.dmi maps/RandomZLevels/stationCollision.dmm Signed-off-by: Cael_Aislinn <cael_aislinn@yahoo.com.au>
This commit is contained in:
@@ -39,6 +39,16 @@
|
||||
// evil infection stuff that will make everyone hate me
|
||||
var/can_infect = 0
|
||||
|
||||
proc/isright(obj/item/tool) //is it is a required surgical tool for this step
|
||||
return (istype(tool,required_tool))
|
||||
|
||||
proc/isacceptable(obj/item/tool) //is it is an accepted replacement tool for this step
|
||||
if (allowed_tools)
|
||||
for (var/T in allowed_tools)
|
||||
if (istype(tool,T))
|
||||
return 1
|
||||
return 0
|
||||
|
||||
// Build this list by iterating over all typesof(/datum/surgery_step) and sorting the results by priority
|
||||
|
||||
|
||||
@@ -1226,3 +1236,68 @@ proc/spread_germs_to_organ(datum/organ/external/E, mob/living/carbon/human/user)
|
||||
user:bloody_hands(target, 0)
|
||||
user:bloody_body(target)
|
||||
|
||||
//////////////////////////////////////////////////////////////////
|
||||
// IMPLANT REMOVAL SURGERY //
|
||||
//////////////////////////////////////////////////////////////////
|
||||
|
||||
/datum/surgery_step/implant_removal
|
||||
required_tool = /obj/item/weapon/hemostat
|
||||
allowed_tools = list(/obj/item/weapon/wirecutters, /obj/item/weapon/kitchen/utensil/fork)
|
||||
|
||||
min_duration = 80
|
||||
max_duration = 100
|
||||
|
||||
can_use(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
return affected.open == 2 && !(affected.status & ORGAN_BLEEDING)
|
||||
|
||||
begin_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("[user] starts poking around inside the incision on [target]'s [affected.display_name] with \the [tool].", \
|
||||
"You start poking around inside the incision on [target]'s [affected.display_name] with \the [tool]" )
|
||||
target.custom_pain("The pain in your chest is living hell!",1)
|
||||
|
||||
end_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/chest/affected = target.get_organ("chest")
|
||||
|
||||
var/find_prob = 0
|
||||
if (affected.implants.len)
|
||||
var/obj/item/weapon/implant/imp = affected.implants[1]
|
||||
if (imp.islegal())
|
||||
find_prob +=60
|
||||
else
|
||||
find_prob +=40
|
||||
if (isright(tool))
|
||||
find_prob +=20
|
||||
|
||||
if (prob(find_prob))
|
||||
user.visible_message("\blue [user] takes something out of incision on [target]'s [affected.display_name] with \the [tool].", \
|
||||
"\blue You take something out of incision on [target]'s [affected.display_name]s with \the [tool]." )
|
||||
var/obj/item/weapon/implant/imp = affected.implants[1]
|
||||
affected.implants -= imp
|
||||
imp.loc = get_turf(target)
|
||||
imp.imp_in = null
|
||||
imp.implanted = 0
|
||||
else
|
||||
user.visible_message("\blue [user] could not find anything inside [target]'s [affected.display_name], and pulls \the [tool] out.", \
|
||||
"\blue You could not find anything inside [target]'s [affected.display_name]." )
|
||||
if (ishuman(user) && prob(80)) user:bloody_hands(target, 0)
|
||||
|
||||
fail_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/chest/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\red [user]'s hand slips, scraping tissue inside [target]'s [affected.display_name] with \the [tool]!", \
|
||||
"\red Your hand slips, scraping tissue inside [target]'s [affected.display_name] with \the [tool]!")
|
||||
affected.createwound(CUT, 20)
|
||||
if (affected.implants.len)
|
||||
var/fail_prob = 10
|
||||
if (!isright(tool))
|
||||
fail_prob += 30
|
||||
if (prob(fail_prob))
|
||||
var/obj/item/weapon/implant/imp = affected.implants[1]
|
||||
user.visible_message("\red Something beeps inside [target]'s [affected.display_name]!")
|
||||
playsound(imp.loc, 'sound/weapons/armbomb.ogg', 75, 1, -3)
|
||||
spawn(15)
|
||||
imp.activate()
|
||||
if (ishuman(user))
|
||||
user:bloody_hands(target, 0)
|
||||
user:bloody_body(target)
|
||||
Reference in New Issue
Block a user