Stops vending machines from runtiming when broken (#63888)

* fix

* review
This commit is contained in:
Seth Scherer
2022-01-11 16:25:14 -05:00
committed by GitHub
parent 00f6996a87
commit ad55a08493
+2
View File
@@ -518,6 +518,8 @@ GLOBAL_LIST_EMPTY(vending_products)
///Tilts ontop of the atom supplied, if crit is true some extra shit can happen. Returns TRUE if it dealt damage to something.
/obj/machinery/vending/proc/tilt(atom/fatty, crit=FALSE)
if(QDELETED(src))
return
visible_message(span_danger("[src] tips over!"))
tilted = TRUE
layer = ABOVE_MOB_LAYER