mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 19:13:30 +01:00
Fixes #3081
This commit is contained in:
@@ -190,7 +190,16 @@
|
||||
max_duration = 160
|
||||
|
||||
can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
return ..() && target_zone != "chest" && target_zone != "groin" && target_zone != "head"
|
||||
if (target_zone == "eyes") //there are specific steps for eye surgery
|
||||
return 0
|
||||
if (!hasorgans(target))
|
||||
return 0
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
if (affected == null)
|
||||
return 0
|
||||
if (affected.status & ORGAN_DESTROYED)
|
||||
return 0
|
||||
return target_zone != "chest" && target_zone != "groin" && target_zone != "head"
|
||||
|
||||
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
@@ -203,11 +212,11 @@
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\blue [user] cuts off [target]'s [affected.display_name] with \the [tool].", \
|
||||
"\blue You cut off [target]'s [affected.display_name] with \the [tool].")
|
||||
affected.droplimb(1,1)
|
||||
affected.droplimb(1,0)
|
||||
|
||||
fail_step(mob/living/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, sawwing through the bone in [target]'s [affected.display_name] with \the [tool]!", \
|
||||
"\red Your hand slips, sawwing through the bone in [target]'s [affected.display_name] with \the [tool]!")
|
||||
affected.createwound(CUT, 30)
|
||||
affected.fracture()
|
||||
affected.fracture()
|
||||
@@ -144,10 +144,15 @@
|
||||
"You start attaching [tool] where [target]'s [affected.display_name] used to be.")
|
||||
|
||||
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/obj/item/robot_parts/L = tool
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\blue [user] has attached [tool] where [target]'s [affected.display_name] used to be.", \
|
||||
"\blue You have attached [tool] where [target]'s [affected.display_name] used to be.")
|
||||
affected.robotize()
|
||||
if(L.sabotaged)
|
||||
affected.sabotaged = 1
|
||||
else
|
||||
affected.sabotaged = 0
|
||||
target.update_body()
|
||||
target.updatehealth()
|
||||
target.UpdateDamageIcon()
|
||||
|
||||
Reference in New Issue
Block a user