From: paramat Date: Fri, 16 Oct 2015 10:51:27 +0000 (+0100) Subject: Default/trees: Add requirement of light level 13 for sapling growth X-Git-Tag: 0.4.14~201 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=ef8b7e230d17b424749e0ce428720afa7ac4fe6d;p=oweals%2Fminetest_game.git Default/trees: Add requirement of light level 13 for sapling growth --- diff --git a/mods/default/trees.lua b/mods/default/trees.lua index 07cc4d73..5f50b040 100644 --- a/mods/default/trees.lua +++ b/mods/default/trees.lua @@ -16,6 +16,10 @@ local function can_grow(pos) if is_soil == 0 then return false end + local ll = minetest.get_node_light(pos) + if not ll or ll < 13 then -- Minimum light level for growth + return false -- matches grass, wheat and cotton + end return true end