From be412804dfe447a9a56fd5e43e2991cc4c46d2f4 Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Mon, 5 May 2025 12:52:11 +0100 Subject: [PATCH] fix y_func --- mods.lua | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/mods.lua b/mods.lua index 6725130..bdf69e9 100644 --- a/mods.lua +++ b/mods.lua @@ -264,16 +264,18 @@ if core.get_modpath("caverealms") then }) end +-- helper + +local function y_func(grow_func) + return function(pos) + grow_func({x = pos.x, y = pos.y - 1, z = pos.z}) + end +end + -- ferns if core.get_modpath("ferns") then - local function y_func(grow_func) - return function(pos) - grow_func({x = pos.x, y = pos.y - 1, z = pos.z}) - end - end - bonemeal:add_sapling({ {"ferns:sapling_giant_tree_fern", y_func(abstract_ferns.grow_giant_tree_fern), "soil"},