From 0e757286460146dff292fc22330f505e28426df2 Mon Sep 17 00:00:00 2001 From: stephen001 Date: Sat, 21 Jun 2008 02:01:39 +0000 Subject: [PATCH] Added canReach to Cryocells, as per #1939088. --- Code/Machinery/cryocell.dm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Code/Machinery/cryocell.dm b/Code/Machinery/cryocell.dm index e6dfe8f..bc1aa64 100644 --- a/Code/Machinery/cryocell.dm +++ b/Code/Machinery/cryocell.dm @@ -202,8 +202,11 @@ obj/machinery/cryo_cell attackby(obj/item/weapon/grab/G, mob/user) if (stat & NOPOWER) return - if ((!( istype(G, /obj/item/weapon/grab) ) || !( ismob(G.affecting) ))) + return + var/result = src.canReach(user, null, 1) + if (result==0) + user.client_mob() << "You can't reach [src]." return if (src.occupant) user.client_mob() << "\blue The cell is already occupied!" @@ -470,4 +473,4 @@ obj/machinery/cryo_cell allow_drop() return 0 - */ \ No newline at end of file + */