From 4b04b867ac7ff48ac5de56758331db83ae13ca16 Mon Sep 17 00:00:00 2001 From: Zuhayr Date: Wed, 10 Jun 2015 12:32:50 +0930 Subject: [PATCH] Fxes #9625 --- code/modules/hydroponics/spreading/spreading.dm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/code/modules/hydroponics/spreading/spreading.dm b/code/modules/hydroponics/spreading/spreading.dm index e62a96c2ce..87894c6d73 100644 --- a/code/modules/hydroponics/spreading/spreading.dm +++ b/code/modules/hydroponics/spreading/spreading.dm @@ -196,16 +196,19 @@ layer = 3 density = 0 -/obj/effect/plant/proc/calc_dir(turf/location = loc) +/obj/effect/plant/proc/calc_dir() set background = 1 + var/turf/T = get_turf(src) + if(!istype(T)) return + var/direction = 16 for(var/wallDir in cardinal) - var/turf/newTurf = get_step(location,wallDir) + var/turf/newTurf = get_step(T,wallDir) if(newTurf.density) direction |= wallDir - for(var/obj/effect/plant/shroom in location) + for(var/obj/effect/plant/shroom in T.contents) if(shroom == src) continue if(shroom.floor) //special