Merge pull request #9371 from variableundefined/DefibPaddleDetach

Defib paddles snap away if you walk away from the defib
This commit is contained in:
Crazy Lemon
2018-08-22 22:27:03 -07:00
committed by GitHub
+4
View File
@@ -293,6 +293,10 @@
update_icon()
return unwield(user)
/obj/item/twohanded/shockpaddles/on_mob_move(dir, mob/user)
if(defib && !(defib.Adjacent(user)))
defib.remove_paddles(user)
/obj/item/twohanded/shockpaddles/proc/check_defib_exists(mainunit, var/mob/living/carbon/human/M, var/obj/O)
if(!mainunit || !istype(mainunit, /obj/item/defibrillator)) //To avoid weird issues from admin spawns
M.unEquip(O)