forked from mtcontrib/bonemeal
Compare commits
7 Commits
7c106254d2
...
1a9c67b1e3
Author | SHA1 | Date | |
---|---|---|---|
1a9c67b1e3 | |||
05e211a037 | |||
fdc62f06b0 | |||
807388d632 | |||
2658577776 | |||
634d1496aa | |||
8fc57f7746 |
37
init.lua
37
init.lua
@ -37,6 +37,17 @@ local function pine_grow(pos)
|
||||
end
|
||||
|
||||
|
||||
-- special function for cactus growth
|
||||
local function cactus_grow(pos)
|
||||
default.grow_cactus(pos, minetest.get_node(pos))
|
||||
end
|
||||
|
||||
-- special function for papyrus growth
|
||||
local function papyrus_grow(pos)
|
||||
default.grow_papyrus(pos, minetest.get_node(pos))
|
||||
end
|
||||
|
||||
|
||||
-- default saplings
|
||||
local saplings = {
|
||||
{"default:sapling", default.grow_new_apple_tree, "soil"},
|
||||
@ -49,7 +60,9 @@ local saplings = {
|
||||
{"default:acacia_bush_sapling", default.grow_acacia_bush, "soil"},
|
||||
{"default:large_cactus_seedling", default.grow_large_cactus, "sand"},
|
||||
{"default:blueberry_bush_sapling", default.grow_blueberry_bush, "soil"},
|
||||
{"default:pine_bush_sapling", default.grow_pine_bush, "soil"}
|
||||
{"default:pine_bush_sapling", default.grow_pine_bush, "soil"},
|
||||
{"default:cactus", cactus_grow, "sand"},
|
||||
{"default:papyrus", papyrus_grow, "soil"},
|
||||
}
|
||||
|
||||
-- helper tables ( "" denotes a blank item )
|
||||
@ -63,24 +76,22 @@ local dry_grass = {
|
||||
"default:dry_grass_5", "", ""
|
||||
}
|
||||
|
||||
-- add all in-game flowers except waterlily
|
||||
-- loads mods then add all in-game flowers except waterlily
|
||||
local flowers = {}
|
||||
|
||||
for node, def in pairs(minetest.registered_nodes) do
|
||||
minetest.after(0.1, function()
|
||||
|
||||
if def.groups.flower and not node:find("waterlily") then
|
||||
for node, def in pairs(minetest.registered_nodes) do
|
||||
|
||||
if def.groups
|
||||
and def.groups.flower
|
||||
and not node:find("waterlily")
|
||||
and not node:find("xdecor:potted_") then
|
||||
flowers[#flowers + 1] = node
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
-- add additional bakedclay flowers if enabled
|
||||
if minetest.get_modpath("bakedclay") then
|
||||
flowers[#flowers + 1] = "bakedclay:delphinium"
|
||||
flowers[#flowers + 1] = "bakedclay:thistle"
|
||||
flowers[#flowers + 1] = "bakedclay:lazarus"
|
||||
flowers[#flowers + 1] = "bakedclay:mannagrass"
|
||||
flowers[#flowers + 1] = ""
|
||||
end
|
||||
|
||||
-- default biomes deco
|
||||
local deco = {
|
||||
|
Reference in New Issue
Block a user