This commit is contained in:
kevinz000
2020-02-21 15:03:22 -07:00
parent e85699df50
commit 665e95d827
2 changed files with 8 additions and 4 deletions
+4 -2
View File
@@ -109,9 +109,11 @@
to_chat(user, "<span class='warning'>The interface on [src] is already too damaged to short it again.</span>")
return
/obj/machinery/pool/controller/AltClick(mob/user)
/obj/machinery/pool/controller/AltClick(mob/living/user)
. = ..()
if(!isliving(user) || !user.Adjacent(src) || !user.CanReach(src) || !CHECK_MOBILITY(user, MOBILITY_USE))
if(!istype(user))
return FALSE
if(!user.Adjacent(src) || !user.CanReach(src) || !CHECK_MOBILITY(user, MOBILITY_USE))
return FALSE
visible_message("<span class='boldwarning'>[user] starts to drain [src]!</span>")
draining = TRUE
+4 -2
View File
@@ -50,9 +50,11 @@
layer = BELOW_MOB_LAYER
// Mousedrop hook to normal turfs to get out of pools.
/turf/open/MouseDrop_T(atom/from, mob/user)
/turf/open/MouseDrop_T(atom/from, mob/living/user)
if(!istype(user))
return ..()
// I could make this /open/floor and not have the !istype but ehh - kev
if(isliving(from) && HAS_TRAIT(from, TRAIT_SWIMMING) && isliving(user) && ((user == from) || user.CanReach(from)) && !CHECK_MOBILITY(user, MOBILITY_USE) && !istype(src, /turf/open/pool))
if(HAS_TRAIT(from, TRAIT_SWIMMING) && isliving(user) && ((user == from) || user.CanReach(from)) && !CHECK_MOBILITY(user, MOBILITY_USE) && !istype(src, /turf/open/pool))
var/mob/living/L = from
//The element only exists if you're on water and a living mob, so let's skip those checks.
var/pre_msg