[MIRROR] Makes self surgery not work when var is set to 0 (#10818)

Co-authored-by: tacoguy7765093 <karokaromaro@gmail.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-05-01 00:57:57 -07:00
committed by GitHub
parent 3e4c75d2c5
commit bcf5dad75d

View File

@@ -1158,9 +1158,9 @@ var/global/list/common_tools = list(
// check if mob is lying down on something we can operate him on.
// The RNG with table/rollerbeds comes into play in do_surgery() so that fail_step() can be used instead.
/proc/can_operate(mob/living/carbon/M, mob/living/user)
. = M.lying
if(user && M == user && user.allow_self_surgery && user.a_intent == I_HELP) // You can, technically, always operate on yourself after standing still. Inadvised, but you can.
if(M != user)
. = M.lying
else if(user && user.allow_self_surgery && user.a_intent == I_HELP) // You can, technically, always operate on yourself after standing still. Inadvised, but you can.
. = TRUE
return .