Merge pull request #10917 from Arturlang/Hyposprays_QOL

Removes the hypospray verb for toggling spray/inject mode and makes it into an Alt click proc.
This commit is contained in:
Ghom
2020-02-06 20:31:46 +01:00
committed by GitHub

View File

@@ -423,18 +423,21 @@
else
unload_hypo(vial,user)
/obj/item/hypospray/mkii/verb/modes()
set name = "Toggle Application Mode"
set category = "Object"
set src in usr
var/mob/M = usr
switch(mode)
if(HYPO_SPRAY)
mode = HYPO_INJECT
to_chat(M, "[src] is now set to inject contents on application.")
if(HYPO_INJECT)
mode = HYPO_SPRAY
to_chat(M, "[src] is now set to spray contents on application.")
/obj/item/hypospray/mkii/AltClick(mob/living/user)
. = ..()
if(user.canUseTopic(src, FALSE))
switch(mode)
if(HYPO_SPRAY)
mode = HYPO_INJECT
to_chat(user, "[src] is now set to inject contents on application.")
if(HYPO_INJECT)
mode = HYPO_SPRAY
to_chat(user, "[src] is now set to spray contents on application.")
return TRUE
/obj/item/hypospray/mkii/examine(mob/user)
. = ..()
. += "<span class='notice'><b>Alt-Click</b> it to toggle its mode from spraying to injecting and vice versa.</span>"
#undef HYPO_SPRAY
#undef HYPO_INJECT