From d5d71c95bea1d5e3a4dc9c1c9a201f70b51bb91b Mon Sep 17 00:00:00 2001 From: Mikhail Dzianishchyts Date: Sun, 25 Aug 2024 21:34:05 +0300 Subject: [PATCH] Do not use spray after putting it into a modsuit (#26570) --- code/modules/reagents/reagent_containers/spray.dm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/modules/reagents/reagent_containers/spray.dm b/code/modules/reagents/reagent_containers/spray.dm index 8945b2e73c6..ffe7d3036b1 100644 --- a/code/modules/reagents/reagent_containers/spray.dm +++ b/code/modules/reagents/reagent_containers/spray.dm @@ -24,10 +24,13 @@ ADD_TRAIT(src, TRAIT_CAN_POINT_WITH, ROUNDSTART_TRAIT) /obj/item/reagent_containers/spray/afterattack(atom/A, mob/user) - if(isstorage(A) || istype(A, /obj/structure/table) || istype(A, /obj/structure/rack) || istype(A, /obj/structure/closet) \ + if(isstorage(A) || ismodcontrol(A) || istype(A, /obj/structure/table) || istype(A, /obj/structure/rack) || istype(A, /obj/structure/closet) \ || istype(A, /obj/item/reagent_containers) || istype(A, /obj/structure/sink) || istype(A, /obj/structure/janitorialcart) || istype(A, /obj/machinery/hydroponics)) return + if(loc != user) + return + if(istype(A, /obj/structure/reagent_dispensers) && get_dist(src,A) <= 1) //this block copypasted from reagent_containers/glass, for lack of a better solution if(!A.reagents.total_volume && A.reagents) to_chat(user, "[A] is empty.")