summaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index 94e9832..4ea0b06 100644
--- a/init.lua
+++ b/init.lua
@@ -334,11 +334,12 @@ function farming.plant_growth_timer(pos, elapsed, node_name)
local growth
- local light_pos = { x = pos.x, y = pos.y + 1, z = pos.z }
+ local light_pos = { x = pos.x, y = pos.y, z = pos.z }
local lambda = elapsed / STAGE_LENGTH_AVG
if lambda < 0.1 then return true end
if max_growth == 1 or lambda < 2.0 then
local light = (minetest.get_node_light(light_pos) or 0) -- CHANGED
+ print ("light level:", light)
if not in_range(light, MIN_LIGHT, MAX_LIGHT) then return true end
growth = 1
else