Closed lnjX closed 8 years ago
Now you can give default.register_tree a schematic and it creates a function for it.
Here are some examples:
default.register_tree("default:apple_tree", { schematic = core.get_modpath("default") .. "/schematics/apple_tree_from_sapling.mts", schematic_size = {x = 2, y = 1, z = 2}, sapling = { growing_type = "schematic_and_function", mgv6_grow = function(pos) if not default.can_grow() then return false end return default.grow_apple_tree(pos, math.random(1, 4) == 1) end, } }) default.register_tree("default:acacia", { schematic = core.get_modpath("default") .. "/schematics/acacia_tree_from_sapling.mts", schematic_size = {x = 2, y = 1, z = 2}, sapling = { growing_type = "schematic", } })
@JBBgameich If you don't have any improvements, you can merge it.
Now you can give default.register_tree a schematic and it creates a function for it.
Here are some examples: