Makes you unable to pull a surgical tray you are standing on (#20229)

* No longer pull trays you are on.

* Update code/game/objects/structures/tables_racks.dm

Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>

* Update code/game/objects/structures/tables_racks.dm

Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>

* Remove unnecessary loop from can_be_pulled

Co-authored-by: adrermail@gmail.com <adrermail@gmail.com>
Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>
This commit is contained in:
Adrer
2023-01-21 14:13:06 -05:00
committed by GitHub
co-authored by Ryan adrermail@gmail.com <adrermail@gmail.com>
parent 526c92e1db
commit 524a8dc0b4
+15 -1
View File
@@ -797,11 +797,25 @@
continue
held.forceMove(NewLoc)
/obj/structure/table/tray/can_be_pulled(user, grab_state, force, show_message)
var/atom/movable/puller = user
if(loc != puller.loc)
held_items -= puller.UID()
if(isliving(user))
var/mob/living/M = user
if(M.UID() in held_items)
return FALSE
return ..()
/obj/structure/table/tray/item_placed(atom/movable/item)
. = ..()
if(is_type_in_typecache(item, typecache_can_hold))
held_items += item.UID()
if(isliving(item))
var/mob/living/M = item
if(M.pulling == src)
M.stop_pulling()
/obj/structure/table/tray/deconstruct(disassembled = TRUE, wrench_disassembly = 0)
if(!(flags & NODECONSTRUCT))
var/turf/T = get_turf(src)