rainforest biome
|
@ -1,4 +1,4 @@
|
|||
name = baldcypress
|
||||
description = Blad Cypress for Swamps
|
||||
description = Bald Cypress for Swamps
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
||||
optional_depends = stairs, bonemeal, swampz
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
--
|
||||
-- Birch Tree
|
||||
--
|
||||
|
@ -90,21 +89,22 @@ end
|
|||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.008,
|
||||
offset = 0.01,
|
||||
scale = 0.001,
|
||||
spread = {x = 255, y = 255, z = 255},
|
||||
seed = 89,
|
||||
seed = 32,
|
||||
octaves = 3,
|
||||
persist = 0.67
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
y_min = 10,
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = birch.birchtree,
|
||||
flags = "place_center_x, place_center_z",
|
||||
place_offset_y = 1,
|
||||
})
|
||||
|
||||
--
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name = birch
|
||||
description = Birch Tree for Grassland
|
||||
depends = default
|
||||
depends = rainf, default
|
||||
optional_depends = stairs, bonemeal
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
local modname = "cherrytree"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
local fruit_grow_time = 1200
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
@ -31,8 +32,25 @@ minetest.register_node("cherrytree:cherries", {
|
|||
after_place_node = function(pos, placer, itemstack)
|
||||
minetest.set_node(pos, {name = "cherrytree:cherries", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
on_dig = function(pos, node, digger)
|
||||
if digger:is_player() then
|
||||
local inv = digger:get_inventory()
|
||||
if inv:room_for_item("main", "cherrytree:cherries") then
|
||||
inv:add_item("main", "cherrytree:cherries")
|
||||
end
|
||||
end
|
||||
minetest.remove_node(pos)
|
||||
pos.y = pos.y + 1
|
||||
local node_above = minetest.get_node_or_nil(pos)
|
||||
if node_above and node_above.param2 == 0 and node_above.name == "cherrytree:blossom_leaves" then
|
||||
--20% of variation on time
|
||||
local twenty_percent = fruit_grow_time * 0.2
|
||||
local grow_time = math.random(fruit_grow_time - twenty_percent, fruit_grow_time + twenty_percent)
|
||||
minetest.get_node_timer(pos):start(grow_time)
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
-- Cherrytree
|
||||
|
||||
|
@ -157,6 +175,17 @@ minetest.register_node("cherrytree:blossom_leaves", {
|
|||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
|
||||
on_timer = function(pos)
|
||||
pos.y = pos.y - 1
|
||||
local node = minetest.get_node_or_nil(pos)
|
||||
if node and node.name == "air" then
|
||||
minetest.set_node(pos, {name = "cherrytree:cherries"})
|
||||
return false
|
||||
else
|
||||
return true
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
-- cherrytree tree leaves
|
||||
|
@ -236,26 +265,6 @@ if minetest.get_modpath("stairs") ~= nil then
|
|||
)
|
||||
end
|
||||
|
||||
-- Chance to convert to normal leaves and cherry fruits
|
||||
minetest.register_abm({
|
||||
nodenames = {"cherrytree:blossom_leaves"},
|
||||
neighbors = {},
|
||||
interval = 600.0, -- Run every 10 minuts
|
||||
chance = 50, -- Select every 1 in 50 nodes
|
||||
action = function(pos, node, active_object_count, active_object_count_wider)
|
||||
if node.param2 == 1 then -- ignore manually placed leaves
|
||||
return
|
||||
end
|
||||
math.randomseed(os.time())
|
||||
local is_fruit = math.random(10)
|
||||
if is_fruit == 10 then
|
||||
minetest.set_node(pos, {name = "cherrytree:cherries"})
|
||||
else
|
||||
minetest.set_node(pos, {name = "cherrytree:leaves"})
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
--Support for bonemeal
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
|
|
|
@ -30,14 +30,14 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:cherries", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -70,28 +70,28 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:cherries", prob=126, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -112,28 +112,28 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -154,27 +154,27 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -196,9 +196,9 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
|
|
@ -69,17 +69,17 @@ end
|
|||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.00005,
|
||||
offset = 0.0008,
|
||||
scale = 0.00004,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 278,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = modpath.."/schematics/chestnuttree.mts",
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name = chestnuttree
|
||||
description = Chesnut Tree for Grassland
|
||||
depends = default
|
||||
depends = rainf, default
|
||||
optional_depends = stairs, bonemeal
|
||||
|
|
|
@ -45,6 +45,7 @@ if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
|||
schematic = modpath.."/schematics/ebony.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
place_offset_y = -1,
|
||||
})
|
||||
end
|
||||
|
||||
|
|
|
@ -0,0 +1,198 @@
|
|||
--
|
||||
-- Hollytree
|
||||
--
|
||||
local modname = "hollytree"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
-- Hollytree
|
||||
|
||||
local function grow_new_hollytree_tree(pos)
|
||||
if not default.can_grow(pos) then
|
||||
-- try a bit later again
|
||||
minetest.get_node_timer(pos):start(math.random(240, 600))
|
||||
return
|
||||
end
|
||||
minetest.remove_node(pos)
|
||||
minetest.place_schematic({x = pos.x-4, y = pos.y, z = pos.z-4}, modpath.."/schematics/hollytree.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0008,
|
||||
scale = 0.00005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 789,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 32,
|
||||
schematic = modpath.."/schematics/hollytree.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("hollytree:sapling", {
|
||||
description = S("Holly Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"hollytree_sapling.png"},
|
||||
inventory_image = "hollytree_sapling.png",
|
||||
wield_image = "hollytree_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_hollytree_tree,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, 7 / 16, 4 / 16}
|
||||
},
|
||||
groups = {snappy = 2, dig_immediate = 3, flammable = 2,
|
||||
attached_node = 1, sapling = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
on_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(2400,4800))
|
||||
end,
|
||||
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
itemstack = default.sapling_on_place(itemstack, placer, pointed_thing,
|
||||
"hollytree:sapling",
|
||||
-- minp, maxp to be checked, relative to sapling pos
|
||||
-- minp_relative.y = 1 because sapling pos has been checked
|
||||
{x = -2, y = 1, z = -2},
|
||||
{x = 2, y = 6, z = 2},
|
||||
-- maximum interval of interior volume check
|
||||
4)
|
||||
|
||||
return itemstack
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("hollytree:trunk", {
|
||||
description = S("Holly Tree Trunk"),
|
||||
tiles = {
|
||||
"hollytree_trunk_top.png",
|
||||
"hollytree_trunk_top.png",
|
||||
"hollytree_trunk.png"
|
||||
},
|
||||
groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
paramtype2 = "facedir",
|
||||
is_ground_content = false,
|
||||
on_place = minetest.rotate_node,
|
||||
})
|
||||
|
||||
-- hollytree wood
|
||||
minetest.register_node("hollytree:wood", {
|
||||
description = S("Holly Tree Wood"),
|
||||
tiles = {"hollytree_wood.png"},
|
||||
paramtype2 = "facedir",
|
||||
place_param2 = 0,
|
||||
is_ground_content = false,
|
||||
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
-- hollytree tree leaves
|
||||
minetest.register_node("hollytree:leaves", {
|
||||
description = S("Holly Tree Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
tiles = {"hollytree_leaves.png"},
|
||||
inventory_image = "hollytree_leaves.png",
|
||||
wield_image = "hollytree_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"hollytree:sapling"}, rarity = 20},
|
||||
{items = {"hollytree:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "hollytree:wood 4",
|
||||
recipe = {{"hollytree:trunk"}}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "hollytree:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "hollytree:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "hollytree:convert_hollytree_saplings_to_node_timer",
|
||||
nodenames = {"hollytree:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"hollytree:trunk"},
|
||||
leaves = {"hollytree:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"hollytree_trunk",
|
||||
"hollytree:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"hollytree_wood.png"},
|
||||
S("Cherry Tree Stair"),
|
||||
S("Cherry Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
--Support for bonemeal
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"hollytree:sapling", grow_new_hollytree_tree, "soil"},
|
||||
})
|
||||
end
|
|
@ -0,0 +1,11 @@
|
|||
# textdomain: hollytree
|
||||
Holly Tree Trunk=Madera de acebo
|
||||
Holly Tree Wood=Tablas de acebo
|
||||
Holly Tree Leaves=Hojas de acebo
|
||||
Holly Tree Wood=Tablas de acebo
|
||||
Holly Tree Sapling=Retoño de acebo
|
||||
Holly TreeTree Stair=Escaleras de acebo
|
||||
Holly TreeTree Slab=Losa de acebo
|
||||
Inner Holly Tree Tree Stair=Escaleras de acebo interior
|
||||
Outer Holly Tree Tree Stair=Escaleras de acebo exterior
|
||||
Holly Tree Slab=Losa de acebo
|
|
@ -0,0 +1,4 @@
|
|||
name = hollytree
|
||||
description = Hollytree
|
||||
depends = rainf, default
|
||||
optional_depends = stairs, bonemeal
|
After Width: | Height: | Size: 12 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 9.5 KiB |
After Width: | Height: | Size: 9.1 KiB |
After Width: | Height: | Size: 2.2 KiB |
|
@ -5,6 +5,7 @@
|
|||
local modname = "lemontree"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
local fruit_grow_time = 1200
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
@ -32,6 +33,22 @@ minetest.register_node("lemontree:lemon", {
|
|||
after_place_node = function(pos, placer, itemstack)
|
||||
minetest.set_node(pos, {name = "lemontree:lemon", param2 = 1})
|
||||
end,
|
||||
|
||||
on_dig = function(pos, node, digger)
|
||||
if digger:is_player() then
|
||||
local inv = digger:get_inventory()
|
||||
if inv:room_for_item("main", "lemontree:lemon") then
|
||||
inv:add_item("main", "lemontree:lemon")
|
||||
end
|
||||
end
|
||||
minetest.remove_node(pos)
|
||||
pos.y = pos.y + 1
|
||||
local node_above = minetest.get_node_or_nil(pos)
|
||||
if node_above and node_above.param2 == 0 and node_above.name == "lemontree:leaves" then
|
||||
local timer = minetest.get_node_timer(pos)
|
||||
timer:start(fruit_grow_time)
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
-- lemontree
|
||||
|
@ -156,6 +173,17 @@ minetest.register_node("lemontree:leaves", {
|
|||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
|
||||
on_timer = function(pos)
|
||||
pos.y = pos.y - 1
|
||||
local node = minetest.get_node_or_nil(pos)
|
||||
if node and node.name == "air" then
|
||||
minetest.set_node(pos, {name = "lemontree:lemon"})
|
||||
return false
|
||||
else
|
||||
return true
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
--
|
||||
|
|
|
@ -25,20 +25,20 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:lemon", prob=64, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:lemon", prob=64, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -60,24 +60,24 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:trunk", prob=126, param2=20},
|
||||
{name="lemontree:lemon", prob=126, param2=1},
|
||||
{name="lemontree:lemon", prob=126, param2=0},
|
||||
{name="lemontree:trunk", prob=254, param2=9},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -95,25 +95,25 @@ schematic = {
|
|||
{name="lemontree:trunk", prob=254, param2=22, force_place=true},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:lemon", prob=126, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:lemon", prob=126, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:lemon", prob=126, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:lemon", prob=126, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -130,24 +130,24 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:trunk", prob=254, param2=9},
|
||||
{name="lemontree:lemon", prob=126, param2=1},
|
||||
{name="lemontree:lemon", prob=126, param2=0},
|
||||
{name="lemontree:trunk", prob=126, param2=23},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
@ -165,19 +165,19 @@ schematic = {
|
|||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=1},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="lemontree:leaves", prob=254, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
|
|
|
@ -28,17 +28,17 @@ end
|
|||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0002,
|
||||
offset = 0.0005,
|
||||
scale = 0.0002,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 3462,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 62,
|
||||
schematic = modpath.."/schematics/maple.mts",
|
||||
|
@ -117,7 +117,6 @@ minetest.register_node("maple:leaves", {
|
|||
description = S("Maple Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
tiles = {"maple_leaves.png"},
|
||||
--inventory_image = "maple_leaves.png",
|
||||
wield_image = "maple_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name = maple
|
||||
description = Maple Tree
|
||||
depends = default
|
||||
depends = rainf, default
|
||||
optional_depends = stairs, bonemeal
|
||||
|
|
|
@ -0,0 +1,218 @@
|
|||
--
|
||||
-- Oak
|
||||
--
|
||||
|
||||
local modname = "oak"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
--Acorn
|
||||
|
||||
minetest.register_node("oak:acorn", {
|
||||
description = S("Acorn"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"oak_acorn.png"},
|
||||
inventory_image = "oak_acorn.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
is_ground_content = false,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -7 / 16, -3 / 16, 3 / 16, 4 / 16, 3 / 16}
|
||||
},
|
||||
groups = {fleshy = 3, dig_immediate = 3, flammable = 2,
|
||||
leafdecay = 3, leafdecay_drop = 1},
|
||||
on_use = minetest.item_eat(2),
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
after_place_node = function(pos, placer, itemstack)
|
||||
minetest.set_node(pos, {name = "oak:acorn", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
-- oak
|
||||
|
||||
local function grow_new_oak_tree(pos)
|
||||
if not default.can_grow(pos) then
|
||||
-- try a bit later again
|
||||
minetest.get_node_timer(pos):start(math.random(1, 1))
|
||||
return
|
||||
end
|
||||
minetest.remove_node(pos)
|
||||
minetest.place_schematic({x = pos.x-5, y = pos.y, z = pos.z-5}, modpath.."/schematics/oak.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0008,
|
||||
scale = 0.00004,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 6431,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = modpath.."/schematics/oak.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
place_offset_y = 0,
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("oak:sapling", {
|
||||
description = S("Oak Sapling"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"oak_sapling.png"},
|
||||
inventory_image = "oak_sapling.png",
|
||||
wield_image = "oak_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_oak_tree,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, 7 / 16, 4 / 16}
|
||||
},
|
||||
groups = {snappy = 2, dig_immediate = 3, flammable = 2,
|
||||
attached_node = 1, sapling = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
on_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1,1))
|
||||
end,
|
||||
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
itemstack = default.sapling_on_place(itemstack, placer, pointed_thing,
|
||||
"oak:sapling",
|
||||
-- minp, maxp to be checked, relative to sapling pos
|
||||
-- minp_relative.y = 1 because sapling pos has been checked
|
||||
{x = -2, y = 1, z = -2},
|
||||
{x = 2, y = 6, z = 2},
|
||||
-- maximum interval of interior volume check
|
||||
4)
|
||||
|
||||
return itemstack
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("oak:trunk", {
|
||||
description = S("Oak Trunk"),
|
||||
tiles = {
|
||||
"oak_trunk_top.png",
|
||||
"oak_trunk_top.png",
|
||||
"oak_trunk.png"
|
||||
},
|
||||
groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
paramtype2 = "facedir",
|
||||
on_place = minetest.rotate_node,
|
||||
})
|
||||
|
||||
-- oak wood
|
||||
minetest.register_node("oak:wood", {
|
||||
description = S("Oak Wood"),
|
||||
tiles = {"oak_wood.png"},
|
||||
is_ground_content = false,
|
||||
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
-- oak tree leaves
|
||||
minetest.register_node("oak:leaves", {
|
||||
description = S("Oak Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
tiles = {"oak_leaves.png"},
|
||||
inventory_image = "oak_leaves.png",
|
||||
wield_image = "oak_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"oak:sapling"}, rarity = 20},
|
||||
{items = {"oak:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "oak:wood 4",
|
||||
recipe = {{"oak:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "oak:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "oak:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "oak:convert_oak_saplings_to_node_timer",
|
||||
nodenames = {"oak:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1, 1))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"oak:trunk"},
|
||||
leaves = {"oak:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"oak_trunk",
|
||||
"oak:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"oak_wood.png"},
|
||||
S("Oak Stair"),
|
||||
S("Oak Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"oak:sapling", grow_new_oak_tree, "soil"},
|
||||
})
|
||||
end
|
|
@ -0,0 +1,10 @@
|
|||
# textdomain: oak
|
||||
Acorn=Bellota
|
||||
Oak Sapling=Retoño de roble
|
||||
Oak Trunk=Madera de roble
|
||||
Oak Wood=Tablas de roble
|
||||
Oak Inner Stair=Escalera interior de roble
|
||||
Oak Leaves=Hojas de roble
|
||||
Oak Outer Stair=Escalera exterior de roble
|
||||
Oak Slab=Losa de roble
|
||||
Oak Stair=Escalera de roble
|
|
@ -0,0 +1,4 @@
|
|||
name = oak
|
||||
description = Oak Tree
|
||||
depends = rainf, default
|
||||
optional_depends = stairs, bonemeal
|
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 3.0 KiB |
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 2.7 KiB |
|
@ -227,7 +227,6 @@ minetest.register_node("palm:wood", {
|
|||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
|
||||
-- palm tree leaves
|
||||
minetest.register_node("palm:leaves", {
|
||||
description = S("Palm Leaves"),
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name = willow
|
||||
description = Willow Tree for Swampy Biomes
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
||||
optional_depends = stairs, bonemeal, swampz
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
unused_args = false
|
||||
allow_defined_top = true
|
||||
|
||||
read_globals = {
|
||||
"minetest",
|
||||
"default",
|
||||
"flowers"
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
# rainf
|
||||
|
||||
A Temperate Rain Forest Biome for Minetest.
|
|
@ -0,0 +1,829 @@
|
|||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
|
||||
|
||||
--Variables
|
||||
|
||||
local grapes_grow_time = 2250
|
||||
|
||||
local water_type
|
||||
if mg_name == "valleys" then
|
||||
water_type= "default:river_water_source"
|
||||
else
|
||||
water_type= "default:water_source"
|
||||
end
|
||||
|
||||
-- Register Biomes
|
||||
|
||||
minetest.register_biome({
|
||||
name = "temperate_rainforest",
|
||||
node_top = "rainf:meadow",
|
||||
depth_top = 1,
|
||||
node_filler = "swaz:silt",
|
||||
depth_filler = 3,
|
||||
node_riverbed = "default:sand",
|
||||
depth_riverbed = 2,
|
||||
node_water_top = water_type,
|
||||
depth_water_top = 1,
|
||||
node_stone = "rainf:granite",
|
||||
y_max = 31000,
|
||||
y_min = 1,
|
||||
heat_point = 52,
|
||||
humidity_point = 75,
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:meadow", {
|
||||
description = S("Meadow"),
|
||||
tiles = {"rainf_meadow.png", "rainf_dirt.png",
|
||||
{name = "rainf_dirt.png^rainf_dirt_with_grass_side.png",
|
||||
tileable_vertical = false}},
|
||||
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
|
||||
drop = "swaz:mud",
|
||||
sounds = default.node_sound_dirt_defaults({
|
||||
footstep = {name = "default_grass_footstep", gain = 0.25},
|
||||
}),
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:blossom_meadow", {
|
||||
description = S("Blossom Meadow"),
|
||||
tiles = {"rainf_blossom_meadow.png", "rainf_dirt.png",
|
||||
{name = "rainf_dirt.png^rainf_dirt_with_grass_side.png",
|
||||
tileable_vertical = false}},
|
||||
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
|
||||
drop = "swaz:mud",
|
||||
sounds = default.node_sound_dirt_defaults({
|
||||
footstep = {name = "default_grass_footstep", gain = 0.25},
|
||||
}),
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:meadow_with_mud", {
|
||||
description = S("Meadow with Mud"),
|
||||
tiles = {"rainf_meadow_with_mud.png", "rainf_dirt.png",
|
||||
"rainf_dirt.png"},
|
||||
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
|
||||
drop = "swaz:mud",
|
||||
sounds = default.node_sound_dirt_defaults({
|
||||
footstep = {name = "default_grass_footstep", gain = 0.25},
|
||||
}),
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:granite", {
|
||||
description = S("Granite"),
|
||||
tiles = {"rainf_granite.png"},
|
||||
groups = {cracky = 3, stone = 1},
|
||||
drop = "rainf:granite",
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:pink_granite", {
|
||||
description = S("Pink Granite"),
|
||||
tiles = {"rainf_pink_granite.png"},
|
||||
groups = {cracky = 3, stone = 1},
|
||||
drop = "rainf:pink_granite",
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:pink_granite_with_moss", {
|
||||
description = S("Pink Granite with Moss"),
|
||||
tiles = {"rainf_pink_granite.png^rainf_moss.png"},
|
||||
groups = {cracky = 3, stone = 1},
|
||||
drop = "rainf:pink_granite",
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
--Grasses
|
||||
|
||||
minetest.register_node("rainf:aloe_vera", {
|
||||
description = S("Aloe Vera"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"rainf_aloe_vera.png"},
|
||||
inventory_image = "rainf_aloe_vera.png",
|
||||
wield_image = "rainf_aloe_vera.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -0.5, -3 / 16, 3 / 16, -2 / 16, 3 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:weed", {
|
||||
description = S("Weed"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_weed.png"},
|
||||
inventory_image = "rainf_weed.png",
|
||||
wield_image = "rainf_weed.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -0.5, -3 / 16, 3 / 16, -2 / 16, 3 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
--Short Grass
|
||||
|
||||
minetest.register_node("rainf:grass", {
|
||||
description = S("Short Grass"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_grass.png"},
|
||||
inventory_image = "rainf_grass.png",
|
||||
wield_image = "rainf_grass.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, -5 / 16, 4 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
--Flowers
|
||||
|
||||
minetest.register_node("rainf:pansy", {
|
||||
description = S("Pansy"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_pansy.png"},
|
||||
inventory_image = "rainf_pansy.png",
|
||||
wield_image = "rainf_pansy.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_blue = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, 0, 2 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:dahlia", {
|
||||
description = S("Dahlia"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_dahlia.png"},
|
||||
inventory_image = "rainf_dahlia.png",
|
||||
wield_image = "rainf_dahlia.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_orange = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, 0, 2 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:camomille", {
|
||||
description = S("Camomille"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_camomille.png"},
|
||||
inventory_image = "rainf_camomille.png",
|
||||
wield_image = "rainf_camomille.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_white = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -0.5, -3 / 16, 3 / 16, -6 / 16, 3 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:red_daisy", {
|
||||
description = S("Red Daisy"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"rainf_red_daisy.png"},
|
||||
inventory_image = "rainf_red_daisy.png",
|
||||
wield_image = "rainf_red_daisy.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_red = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, -5 / 16, 4 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:hyacinth", {
|
||||
description = S("Hyacinth"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"rainf_hyacinth.png"},
|
||||
inventory_image = "rainf_hyacinth.png",
|
||||
wield_image = "rainf_hyacinth.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_yellow = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, 0, 2 / 16},
|
||||
},
|
||||
})
|
||||
|
||||
-- Vines and Grapes
|
||||
|
||||
minetest.register_node("rainf:grapes", {
|
||||
description = S("Grapes"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"rainf_grapes.png"},
|
||||
inventory_image = "rainf_grapes.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
is_ground_content = false,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -7 / 16, -3 / 16, 3 / 16, 4 / 16, 3 / 16}
|
||||
},
|
||||
groups = {fleshy = 3, dig_immediate = 3, flammable = 2, leafdecay = 3, leafdecay_drop = 1},
|
||||
on_use = minetest.item_eat(2),
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
after_place_node = function(pos, placer, itemstack)
|
||||
minetest.set_node(pos, {name = "rainf:grapes", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:vine", {
|
||||
description = S("Vine"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"rainf_vine.png"},
|
||||
inventory_image = "rainf_vine.png",
|
||||
wield_image = "rainf_vine.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1,},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, 0, 2 / 16},
|
||||
},
|
||||
|
||||
on_construct = function(pos)
|
||||
--20% of variation on time
|
||||
local twenty_percent = grapes_grow_time * 0.2
|
||||
local grow_time = math.random(grapes_grow_time - twenty_percent, grapes_grow_time + twenty_percent)
|
||||
minetest.get_node_timer(pos):start(grow_time)
|
||||
end,
|
||||
|
||||
on_timer = function(pos)
|
||||
local node = minetest.get_node_or_nil(pos)
|
||||
if node and node.name == "rainf:vine" then
|
||||
minetest.set_node(pos, {name = "rainf:grapevine"})
|
||||
return false
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("rainf:grapevine", {
|
||||
description = S("Grapevine"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"rainf_grapevine.png"},
|
||||
inventory_image = "rainf_grapevine.png",
|
||||
wield_image = "rainf_grapevine.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1,},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, 0, 2 / 16},
|
||||
},
|
||||
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
local inv = player:get_inventory()
|
||||
if inv:room_for_item("main", "rainf:grapes") then
|
||||
inv:add_item("main", "rainf:grapes")
|
||||
minetest.set_node(pos, {name="rainf:vine"})
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
-- Mushroom
|
||||
|
||||
minetest.register_node("rainf:champignon", {
|
||||
description = S("Champignon"),
|
||||
visual_scale = 0.8,
|
||||
tiles = {"rainf_champignon.png"},
|
||||
inventory_image = "rainf_champignon.png",
|
||||
wield_image = "rainf_champignon.png",
|
||||
drawtype = "plantlike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
stack_max = 99,
|
||||
groups = {snappy = 3, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
on_use = minetest.item_eat(3),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-2 / 16, -0.5, -2 / 16, 2 / 16, -3 / 16, 2 / 16},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_abm({
|
||||
label = "Rainf Mushroom Spread",
|
||||
nodenames = {"rainf:champignon"},
|
||||
interval = 11,
|
||||
chance = 150,
|
||||
action = function(...)
|
||||
flowers.mushroom_spread(...)
|
||||
end,
|
||||
})
|
||||
|
||||
--Pavements
|
||||
|
||||
local pavements= {
|
||||
{name= "rainf:granite_wall", description= "Granite Wall", texture= "rainf_granite_wall.png",
|
||||
amount = 8,
|
||||
recipe = {
|
||||
{'rainf:granite', 'rainf:granite', 'rainf:granite'},
|
||||
{'rainf:granite', 'rainf:granite', 'rainf:granite'},
|
||||
{'rainf:granite', 'rainf:granite', 'rainf:granite'},
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
for i = 1, #pavements do
|
||||
minetest.register_node(pavements[i].name, {
|
||||
description = S(pavements[i].description),
|
||||
tiles = {pavements[i].texture},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
local amount
|
||||
if pavements[i].amount then
|
||||
amount = " ".. tostring(pavements[i].amount)
|
||||
else
|
||||
amount = "1"
|
||||
end
|
||||
minetest.register_craft({
|
||||
output = pavements[i].name .. amount,
|
||||
type = 'shaped',
|
||||
recipe = pavements[i].recipe,
|
||||
})
|
||||
end
|
||||
|
||||
-- Register Decoration
|
||||
-- IMPORTANT!
|
||||
-- THE ORDER OF THE DECORATION MATTERS!
|
||||
-- DO NOT SORT
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
|
||||
--Water Source (4x4)
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0009,
|
||||
scale = 0.005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainf"},
|
||||
height = 2,
|
||||
y_min = 2,
|
||||
y_max = 1000,
|
||||
place_offset_y = 0,
|
||||
schematic = {
|
||||
size = {x = 4, y = 1, z = 4},
|
||||
data = {
|
||||
{name = "rainf:meadow"}, {name = "rainf:meadow"}, {name = "rainf:meadow"},{name = "rainf:meadow"},
|
||||
{name = "rainf:meadow"}, {name = water_type}, {name = water_type},{name = "rainf:meadow"},
|
||||
{name = "rainf:meadow"}, {name = water_type}, {name = water_type},{name = "rainf:meadow"},
|
||||
{name = "rainf:meadow"}, {name = "rainf:meadow"}, {name = "rainf:meadow"},{name = "rainf:meadow"},
|
||||
}
|
||||
},
|
||||
spawn_by = "rainf:meadow",
|
||||
num_spawn_by = 5,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:blossom_meadow",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.1,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.0002,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 221,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
place_offset_y = -1,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:meadow_with_mud",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 2.0,
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
spawn_by = water_type,
|
||||
num_spawn_by = 1,
|
||||
place_offset_y = -1,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:meadow_with_mud",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.05,
|
||||
noise_params = {
|
||||
offset = 0.2,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 451,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
spawn_by = "rainf:meadow_with_mud",
|
||||
num_spawn_by = 1,
|
||||
place_offset_y = -1,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "simple",
|
||||
decoration = water_type,
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.8,
|
||||
scale = 0.8,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainf"},
|
||||
height = 2,
|
||||
y_min = 2,
|
||||
y_max = 1000,
|
||||
place_offset_y = -2,
|
||||
spawn_by = "rainf:meadow_with_mud",
|
||||
num_spawn_by = 5,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
schematic = {
|
||||
size = {x = 1, y = 2, z = 1},
|
||||
data = {
|
||||
{name = "rainf:pink_granite"}, {name = "rainf:pink_granite_with_moss"},
|
||||
}
|
||||
},
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.00001,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.0002,
|
||||
scale = 0.0008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 4341,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
place_offset_y = -1,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
schematic = {
|
||||
size = {x = 1, y = 2, z = 1},
|
||||
data = {
|
||||
{name = "rainf:pink_granite"}, {name = "rainf:pink_granite_with_moss"},
|
||||
}
|
||||
},
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.6,
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
place_offset_y = -1,
|
||||
spawn_by = "rainf:pink_granite_with_moss",
|
||||
num_spawn_by = 1,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
--Another Pink granite over same block
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:pink_granite_with_moss",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:pink_granite_with_moss",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.6,
|
||||
biomes = {"rainf"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
place_offset_y = 0,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:blossom_meadow",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.1,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.9,
|
||||
scale = 0.08,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2231,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
spawn_by = "rainf:blossom_meadow",
|
||||
num_spawn_by = 1,
|
||||
place_offset_y = -1,
|
||||
y_max = 80,
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
})
|
||||
|
||||
--Aloe Vera
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:aloe_vera",
|
||||
deco_type = "simple",
|
||||
place_on = {"rainf:meadow"},
|
||||
sidelen = 16,
|
||||
biomes = {"rainf"},
|
||||
fill_ratio = 0.001,
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
--Weed
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:weed",
|
||||
deco_type = "simple",
|
||||
place_on = {"rainf:meadow", "rainf:meadow_with_mud", "rainf:pink_granite_with_moss"},
|
||||
sidelen = 16,
|
||||
biomes = {"rainf"},
|
||||
fill_ratio = 0.01,
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:grass",
|
||||
deco_type = "simple",
|
||||
place_on = {"rainf:meadow", "rainf:pink_granite_with_moss"},
|
||||
sidelen = 16,
|
||||
biomes = {"rainf"},
|
||||
fill_ratio = 0.05,
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
--Pansy
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:pansy",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.008,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 289,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
--Dahlia
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:dahlia",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.008,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 34,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
-- Camomille
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:camomille",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:blossom_meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.5,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.8,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 452,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
-- Red Daisy
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:red_daisy",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.05,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 452,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
-- Hyacinth
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:hyacinth",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.05,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 452,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
-- Champignon
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:champignon",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.0005,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.0008,
|
||||
scale = 0.0008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 452,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
-- Vine
|
||||
|
||||
minetest.register_decoration({
|
||||
decoration = "rainf:grapevine",
|
||||
deco_type = "simple",
|
||||
place_on = "rainf:meadow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.0005,
|
||||
biomes = {"rainf"},
|
||||
noise_params = {
|
||||
offset = 0.0008,
|
||||
scale = 0.0008,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 452,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
})
|
||||
|
||||
end
|
||||
|
||||
if minetest.get_modpath("stairs")~=nil then
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
"granite",
|
||||
"rainf:granite",
|
||||
{cracky = 2, stone = 1},
|
||||
{"rainf_granite.png"},
|
||||
S("Granite Stair"),
|
||||
S("Granite Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
"pink_granite",
|
||||
"rainf:pink_granite",
|
||||
{cracky = 2, stone = 1},
|
||||
{"rainf_pink_granite.png"},
|
||||
S("Pink Granite Stair"),
|
||||
S("Pink Granite Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
end
|
|
@ -0,0 +1,24 @@
|
|||
# textdomain: rainf
|
||||
Meadow=Pradera
|
||||
Blossom Meadow=Pradera florida
|
||||
Meadow with Mud=Pradera con barro
|
||||
Granite=Granito
|
||||
Pink Granite=Granito rosa
|
||||
Pink Granite with Moss=Granito rosa con musgo
|
||||
Aloe vera=Aloe vera
|
||||
Weed=Mala hierba
|
||||
Short Grass=Hierba corta
|
||||
Pansy=Pensamiento
|
||||
Dahlia=Dalia
|
||||
Camomille=Manzanilla
|
||||
Red Daisy=Margarita roja
|
||||
Hyacinth=Jacinto
|
||||
Grapes=Uvas
|
||||
Vine=Vid
|
||||
Grapevine=Viñedo
|
||||
Champignon=Campiñón común
|
||||
Granite Wall=Muro de granito
|
||||
Granite Stair=Escaleras de granito
|
||||
Granite Slab=Losa de granito
|
||||
Pink Granite Stair=Escaleras de granito rosa
|
||||
Pink Granite Slab=Losa de granito rosa
|
|
@ -0,0 +1,3 @@
|
|||
name = rainf
|
||||
depends = default
|
||||
optional_depends = stairs
|
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 2.5 KiB |
After Width: | Height: | Size: 4.7 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 6.1 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 3.5 KiB |
After Width: | Height: | Size: 2.9 KiB |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 8.8 KiB |
After Width: | Height: | Size: 919 B |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 9.5 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 5.5 KiB |
After Width: | Height: | Size: 3.5 KiB |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 2.3 KiB |
|
@ -3,7 +3,8 @@ allow_defined_top = true
|
|||
|
||||
globals = {
|
||||
"minetest",
|
||||
"mobkit"
|
||||
"mobkit",
|
||||
"stairs"
|
||||
}
|
||||
|
||||
read_globals = {
|
||||
|
|
|
@ -14,7 +14,7 @@ minetest.register_biome({
|
|||
node_water_top = "swaz:water_source",
|
||||
depth_water_top = 1,
|
||||
node_stone = "swaz:limestone",
|
||||
y_max = 5,
|
||||
y_max = 25,
|
||||
y_min = 1,
|
||||
heat_point = 80,
|
||||
humidity_point = 89,
|
||||
|
@ -56,7 +56,6 @@ minetest.register_node("swaz:limestone", {
|
|||
tiles = {"swaz_limestone.png"},
|
||||
groups = {cracky = 3, stone = 1},
|
||||
drop = "swaz:limestone",
|
||||
legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
|
@ -222,7 +221,7 @@ minetest.register_node("swaz:pampas_grass", {
|
|||
description = S("Pampas Grass"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
visual_scale = 0.9,
|
||||
tiles = {"swaz_pampas_grass.png"},
|
||||
inventory_image = "swaz_pampas_grass.png",
|
||||
wield_image = "swaz_pampas_grass.png",
|
||||
|
@ -242,7 +241,7 @@ minetest.register_node("swaz:lavender", {
|
|||
description = S("Lavender"),
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
visual_scale = 0.8,
|
||||
visual_scale = 1.0,
|
||||
tiles = {"swaz_lavender.png"},
|
||||
inventory_image = "swaz_lavender.png",
|
||||
wield_image = "swaz_lavender.png",
|
||||
|
@ -250,7 +249,7 @@ minetest.register_node("swaz:lavender", {
|
|||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {snappy = 3, flora = 1, attached_node = 1, flammable = 1},
|
||||
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, color_violet = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
|
@ -574,6 +573,111 @@ minetest.register_craft({
|
|||
recipe = {"swaz:adobe", "swaz:adobe", "swaz:adobe", "swaz:adobe"},
|
||||
})
|
||||
|
||||
minetest.register_node("swaz:brick_wall", {
|
||||
description = S("Brick Wall"),
|
||||
tiles = {"swaz_brick_wall.png"},
|
||||
is_ground_content = false,
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "swaz:brick_wall",
|
||||
type = "cooking",
|
||||
cooktime = 3.0,
|
||||
recipe = "swaz:mudbrick",
|
||||
})
|
||||
|
||||
minetest.register_node("swaz:mixed_brick_wall", {
|
||||
description = S("Mixed Brick Wall"),
|
||||
tiles = {"swaz_mixed_brick_wall.png"},
|
||||
is_ground_content = false,
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "swaz:mixed_brick_wall",
|
||||
type = "shapeless",
|
||||
recipe = {"swaz:brick_wall", "dye:red", "dye:blue"},
|
||||
})
|
||||
|
||||
minetest.register_node("swaz:sandy_brick_wall", {
|
||||
description = S("Sandy Brick Wall"),
|
||||
tiles = {"swaz_sandy_brick_wall.png"},
|
||||
is_ground_content = false,
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "swaz:sandy_brick_wall",
|
||||
type = "shapeless",
|
||||
recipe = {"swaz:brick_wall", "default:sand"},
|
||||
})
|
||||
|
||||
local cement_base
|
||||
|
||||
if minetest.get_modpath("basic_materials")~=nil then
|
||||
cement_base = "basic_materials:wet_cement"
|
||||
else
|
||||
cement_base = "dye:grey"
|
||||
end
|
||||
|
||||
minetest.register_node("swaz:cemented_brick_wall", {
|
||||
description = S("Cemented Brick Wall"),
|
||||
tiles = {"swaz_cemented_brick_wall.png"},
|
||||
is_ground_content = false,
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "swaz:cemented_brick_wall",
|
||||
type = "shapeless",
|
||||
recipe = {"swaz:brick_wall", cement_base},
|
||||
})
|
||||
|
||||
--Roof/Gables
|
||||
|
||||
minetest.register_node("swaz:roof_slope_red", {
|
||||
description = S("Red Roof Slope"),
|
||||
drawtype= "mesh",
|
||||
mesh = "swaz_roof_slope.b3d",
|
||||
tiles = {"swaz_red_roof.png"},
|
||||
is_ground_content = false,
|
||||
paramtype2 = "facedir",
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {
|
||||
{-0.5, -0.5, -0.5, 0.5, 0, 0.5},
|
||||
{-0.5, 0, 0, 0.5, 0.5, 0.5},
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_node("swaz:red_roof_corner", {
|
||||
description = S("Red Roof Corner"),
|
||||
drawtype= "mesh",
|
||||
mesh = "swaz_roof_corner.b3d",
|
||||
tiles = {"swaz_red_roof.png"},
|
||||
paramtype2 = "facedir",
|
||||
is_ground_content = false,
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("swaz:roof_flat_red", {
|
||||
description = S("Red Flat Roof"),
|
||||
tiles = {"swaz_red_gables.png", "swaz_adobe.png"},
|
||||
is_ground_content = false,
|
||||
paramtype2 = "facedir",
|
||||
groups = {cracky = 3, stone = 1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
if minetest.get_modpath("stairs")~=nil then
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
|
@ -595,4 +699,14 @@ if minetest.get_modpath("stairs")~=nil then
|
|||
S("Mudbrick Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
"adobe_brick",
|
||||
"swaz_brick_wall",
|
||||
{cracky = 2, stone = 1},
|
||||
{"swaz_brick_wall.png"},
|
||||
S("Bricked Stair"),
|
||||
S("Bricked Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
end
|
||||
|
|
|
@ -16,3 +16,12 @@ Adobe Slab=Losa de adobe
|
|||
Mudbrick=Ladrillos de adobe
|
||||
Mudbrick Stair=Escaleras de ladrillos adobe
|
||||
Mudbrick Slab=Losa de ladrillos adobe
|
||||
Brick Wall=Muro de ladrillos
|
||||
Mixed Brick Wall=Muro de ladrillos mixto
|
||||
Sandy Brick Wall=Muro de ladrillos arenoso
|
||||
Cemented Brick Wall=Muro de ladrillos cementado
|
||||
Red Roof Slope=Cuña de tejado rojo
|
||||
Red Roof Corner=Esquina de tejado rojo
|
||||
Red Flat Roof=Plano de tejado rojo
|
||||
Bricked Stair=Escaleras de ladrillos tejar
|
||||
Bricked Slab=Losa de ladrillos tejar
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
name = swaz
|
||||
depends = default, flowers, baldcypress, willow, farming
|
||||
optional_depends = stairs
|
||||
depends = default, flowers, baldcypress, willow, farming, dye
|
||||
optional_depends = stairs, basic_materials
|
||||
|
|
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 5.5 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 5.8 KiB |
After Width: | Height: | Size: 10 KiB |