1 Commits

Author SHA1 Message Date
767d3e5ef7 use enable_unique_ids on all tree nodes (but not saplings)
remove long-dead paramtype2="waving" entries
(it's just node def entry, waving=1 now)

misc whitespace fixes
2015-07-19 15:37:42 -04:00
95 changed files with 450 additions and 314 deletions

0
.gitignore vendored Executable file → Normal file
View File

0
LICENSE Executable file → Normal file
View File

2
README.md Executable file → Normal file
View File

@ -8,4 +8,4 @@ jungle trees mod, and big contributions by RealBadAngel.
Brought together into one mod and made L-systems compatible by Vanessa
Ezekowitz.
Dependencies: <a href="https://forum.minetest.net/viewtopic.php?f=11&t=12999">biome_lib</a> and default
Dependencies: <a href="https://github.com/VanessaE/plantlife">plants_lib</a> and default

33
biome_defs.lua Executable file → Normal file
View File

@ -91,7 +91,7 @@ moretrees.willow_biome = {
}
moretrees.acacia_biome = {
surface = { "default:dirt_with_grass", "default:dirt_with_dry_grass", "default:desert_sand" },
surface = { "default:dirt_with_grass", "default:desert_sand" },
avoid_nodes = moretrees.avoidnodes,
avoid_radius = 15,
seed_diff = 1,
@ -118,24 +118,18 @@ moretrees.rubber_tree_biome = {
}
moretrees.jungletree_biome = {
surface = {
"default:dirt",
"default:dirt_with_grass",
"woodsoils:dirt_with_leaves_1",
"woodsoils:grass_with_leaves_1",
"woodsoils:grass_with_leaves_2"
},
avoid_nodes = {"moretrees:jungletree_trunk"},
max_count = 12,
avoid_radius = 3,
rarity = 85,
surface = "default:dirt_with_grass",
avoid_nodes = moretrees.avoidnodes,
avoid_radius = 5,
seed_diff = 329,
min_elevation = 1,
near_nodes = {"default:jungletree"},
near_nodes_size = 6,
near_nodes_vertical = 2,
near_nodes_count = 1,
plantlife_limit = -0.9,
min_elevation = -5,
max_elevation = 10,
temp_min = 0.25,
near_nodes = {"default:water_source"},
near_nodes_size = 20,
near_nodes_count = 7,
rarity = 10,
max_count = 10,
}
moretrees.spruce_biome = {
@ -150,7 +144,7 @@ moretrees.spruce_biome = {
max_count = 5,
}
moretrees.cedar_biome = {
moretrees.pine_biome = {
surface = "default:dirt_with_grass",
avoid_nodes = moretrees.avoidnodes,
avoid_radius = 10,
@ -186,3 +180,4 @@ moretrees.fir_biome_snow = {
delete_above = true,
spawn_replace_node = true
}

43
crafts.lua Executable file → Normal file
View File

@ -3,24 +3,13 @@ local S = moretrees.intllib
for i in ipairs(moretrees.treelist) do
local treename = moretrees.treelist[i][1]
-- MODIFICATION MADE FOR MFF //MFF(Mg|08/12/15)
if minetest.registered_items["moretrees:" .. treename .. "_trunk_sideways"] then
minetest.register_craft({
output = "moretrees:"..treename.."_trunk 2",
recipe = {
{"moretrees:"..treename.."_trunk_sideways"},
{"moretrees:"..treename.."_trunk_sideways"}
}
})
minetest.register_craft({
type = "shapeless",
output = "moretrees:"..treename.."_planks 4",
recipe = {
"moretrees:"..treename.."_trunk_sideways"
}
})
end
minetest.register_craft({
output = "moretrees:"..treename.."_trunk 2",
recipe = {
{"moretrees:"..treename.."_trunk_sideways"},
{"moretrees:"..treename.."_trunk_sideways"}
}
})
minetest.register_craft({
type = "shapeless",
@ -30,6 +19,14 @@ for i in ipairs(moretrees.treelist) do
}
})
minetest.register_craft({
type = "shapeless",
output = "moretrees:"..treename.."_planks 4",
recipe = {
"moretrees:"..treename.."_trunk_sideways"
}
})
minetest.register_craft({
type = "fuel",
recipe = "moretrees:"..treename.."_sapling",
@ -83,9 +80,9 @@ minetest.register_craftitem("moretrees:spruce_nuts", {
on_use = minetest.item_eat(1),
})
minetest.register_craftitem("moretrees:cedar_nuts", {
description = S("Roasted Cedar Cone Nuts"),
inventory_image = "moretrees_cedar_nuts.png",
minetest.register_craftitem("moretrees:pine_nuts", {
description = S("Roasted Pine Cone Nuts"),
inventory_image = "moretrees_pine_nuts.png",
on_use = minetest.item_eat(1),
})
@ -141,8 +138,8 @@ minetest.register_craft({
minetest.register_craft({
type = "cooking",
output = "moretrees:cedar_nuts 4",
recipe = "moretrees:cedar_cone",
output = "moretrees:pine_nuts 4",
recipe = "moretrees:pine_cone",
})
minetest.register_craft({

47
default_settings.txt Executable file → Normal file
View File

@ -6,7 +6,7 @@ moretrees.enable_apple_tree = true
moretrees.enable_oak = true
moretrees.enable_sequoia = true
moretrees.enable_palm = true
moretrees.enable_cedar = true
moretrees.enable_pine = true
moretrees.enable_rubber_tree = true
moretrees.enable_willow = true
moretrees.enable_acacia = true
@ -17,16 +17,14 @@ moretrees.enable_fir = true
moretrees.enable_beech = false
-- set this to true to make moretrees spawn saplings at mapgen time instead
-- of fully-grown trees, which will grow into full trees after a very short
-- delay. This reduces mapgen lag in some situations.
-- of fully-grown trees, which will grow into full trees very quickly. With
-- older versions of plants_lib, doing this will reduce mapgen lag.
moretrees.spawn_saplings = false
-- Set this to true to allow defining stairs/slabs/etc. If Moreblocks is
-- installed, this will use that mod's Stairs Plus component. Otherwise, it
-- will use the default stairs mod in minetest_game, if present
-- Set this to true to allow usage of the stairsplus mod in moreblocks
moretrees.enable_stairs = true
moretrees.enable_stairsplus = true
-- Set this to true if you want the plantlike drawtype for leaves, which
-- improves some peoples' framerates without resorting to making leaf nodes opaque.
@ -34,21 +32,42 @@ moretrees.enable_stairs = true
moretrees.plantlike_leaves = false
-- Set this to true to enable leaf decay of all trees except the default ones.
moretrees.enable_leafdecay = true
-- Enable this one if you want this mod's leafdecay code to affect the old
-- default trees too; this setting is independent of the one above. You'll
-- want to manually disable the default leafdecay code in minetest_game if
-- you enable this, otherwise you'll have two sets of leaf decay code running
-- at the same time, which will just waste CPU for no benefit.
moretrees.enable_default_leafdecay = true
-- Enable this one for default *jungle* leaves
moretrees.enable_default_jungle_leafdecay = true
-- Enable this if you want moretrees to redefine default apples so that they
-- fall when leaves decay/are dug.
moretrees.enable_redefine_apple = true
-- Set this to true to enable leaf decay of all trees except the default ones.
moretrees.enable_leafdecay = true
-- various related settings to configure leaf decay.
-- various settings to configure default and default-jungle leaf decay.
moretrees.leafdecay_delay = 2
moretrees.leafdecay_chance = 5
moretrees.leafdecay_chance = 100
moretrees.leafdecay_radius = 5
moretrees.palm_leafdecay_radius = 10
moretrees.default_jungle_leafdecay_delay = 2
moretrees.default_jungle_leafdecay_chance = 100
moretrees.default_jungle_leafdecay_radius = 5
moretrees.palm_leafdecay_radius = 15
moretrees.default_leafdecay_delay = 3
moretrees.default_leafdecay_chance = 50
moretrees.default_leafdecay_radius = 4
-- Change these settings if you want default trees to be gradually cut down
-- above the elevation where firs normally generate.

3
depends.txt Executable file → Normal file
View File

@ -1,6 +1,5 @@
default
biome_lib
stairs?
plants_lib
moreblocks?
intllib?

View File

@ -1 +0,0 @@
This mod adds a whole bunch of new types of trees to the game

108
init.lua Executable file → Normal file
View File

@ -13,7 +13,8 @@
-- by RealBadAngel.
--
-- License: WTFPL for all parts (code and textures, including those copied
-- from the the old jungletree and conifers mods).
-- from the jungletree and conifers mods) except the default jungle tree trunk
-- texture, which is CC-By-SA.
moretrees = {}
@ -24,8 +25,21 @@ local modpath=minetest.get_modpath("moretrees")
dofile(modpath.."/default_settings.txt")
if io.open(worldpath.."/moretrees_settings.txt","r") then
io.close()
if io.open(worldpath.."/moretrees_settings.txt","r") == nil then
io.input(modpath.."/default_settings.txt")
io.output(worldpath.."/moretrees_settings.txt")
local size = 2^13 -- good buffer size (8K)
while true do
local block = io.read(size)
if not block then
io.close()
break
end
io.write(block)
end
else
dofile(worldpath.."/moretrees_settings.txt")
end
@ -38,17 +52,6 @@ else
end
moretrees.intllib = S
-- clone node
function moretrees.clone_node(name)
local node2 = {}
local node = minetest.registered_nodes[name]
for k,v in pairs(node) do
node2[k]=v
end
return node2
end
-- infinite stacks checking
if minetest.get_modpath("unified_inventory") or not minetest.setting_getbool("creative_mode") then
@ -64,19 +67,19 @@ moretrees.cutting_tools = {
"default:axe_diamond",
"default:axe_mese",
"default:axe_steel",
-- "glooptest:axe_alatro",
-- "glooptest:axe_arol",
"default:axe_mithril",
"default:axe_silver",
-- "titanium:axe",
"glooptest:axe_alatro",
"glooptest:axe_arol",
"moreores:axe_mithril",
"moreores:axe_silver",
"titanium:axe",
}
-- Cutting tools disabled. They are unknown //MFF(Mg|08/09/15)
dofile(modpath.."/tree_models.lua")
dofile(modpath.."/node_defs.lua")
dofile(modpath.."/biome_defs.lua")
dofile(modpath.."/saplings.lua")
dofile(modpath.."/crafts.lua")
dofile(modpath.."/leafdecay.lua")
-- tree spawning setup
@ -86,7 +89,7 @@ if moretrees.spawn_saplings then
moretrees.spawn_oak_object = "moretrees:oak_sapling_ongen"
moretrees.spawn_sequoia_object = "moretrees:sequoia_sapling_ongen"
moretrees.spawn_palm_object = "moretrees:palm_sapling_ongen"
moretrees.spawn_cedar_object = "moretrees:cedar_sapling_ongen"
moretrees.spawn_pine_object = "moretrees:pine_sapling_ongen"
moretrees.spawn_rubber_tree_object = "moretrees:rubber_tree_sapling_ongen"
moretrees.spawn_willow_object = "moretrees:willow_sapling_ongen"
moretrees.spawn_acacia_object = "moretrees:acacia_sapling_ongen"
@ -101,75 +104,76 @@ else
moretrees.spawn_oak_object = moretrees.oak_model
moretrees.spawn_sequoia_object = moretrees.sequoia_model
moretrees.spawn_palm_object = moretrees.palm_model
moretrees.spawn_cedar_object = moretrees.cedar_model
moretrees.spawn_pine_object = moretrees.pine_model
moretrees.spawn_rubber_tree_object = moretrees.rubber_tree_model
moretrees.spawn_willow_object = moretrees.willow_model
moretrees.spawn_acacia_object = moretrees.acacia_model
moretrees.spawn_birch_object = "moretrees.grow_birch"
moretrees.spawn_spruce_object = "moretrees.grow_spruce"
moretrees.spawn_jungletree_object = "moretrees.grow_jungletree"
moretrees.spawn_fir_object = "moretrees.grow_fir"
moretrees.spawn_fir_snow_object = "moretrees.grow_fir_snow"
moretrees.spawn_birch_object = "moretrees:grow_birch"
moretrees.spawn_spruce_object = "moretrees:grow_spruce"
moretrees.spawn_jungletree_object = "moretrees:grow_jungletree"
moretrees.spawn_fir_object = "moretrees:grow_fir"
moretrees.spawn_fir_snow_object = "moretrees:grow_fir_snow"
end
if moretrees.enable_beech then
biome_lib:register_generate_plant(moretrees.beech_biome, moretrees.spawn_beech_object)
plantslib:register_generate_plant(moretrees.beech_biome, moretrees.spawn_beech_object)
end
if moretrees.enable_apple_tree then
biome_lib:register_generate_plant(moretrees.apple_tree_biome, moretrees.spawn_apple_tree_object)
plantslib:register_generate_plant(moretrees.apple_tree_biome, moretrees.spawn_apple_tree_object)
end
if moretrees.enable_oak then
biome_lib:register_generate_plant(moretrees.oak_biome, moretrees.spawn_oak_object)
plantslib:register_generate_plant(moretrees.oak_biome, moretrees.spawn_oak_object)
end
if moretrees.enable_sequoia then
biome_lib:register_generate_plant(moretrees.sequoia_biome, moretrees.spawn_sequoia_object)
plantslib:register_generate_plant(moretrees.sequoia_biome, moretrees.spawn_sequoia_object)
end
if moretrees.enable_palm then
biome_lib:register_generate_plant(moretrees.palm_biome, moretrees.spawn_palm_object)
plantslib:register_generate_plant(moretrees.palm_biome, moretrees.spawn_palm_object)
end
if moretrees.enable_cedar then
biome_lib:register_generate_plant(moretrees.cedar_biome, moretrees.spawn_cedar_object)
if moretrees.enable_pine then
plantslib:register_generate_plant(moretrees.pine_biome, moretrees.spawn_pine_object)
end
if moretrees.enable_rubber_tree then
biome_lib:register_generate_plant(moretrees.rubber_tree_biome, moretrees.spawn_rubber_tree_object)
plantslib:register_generate_plant(moretrees.rubber_tree_biome, moretrees.spawn_rubber_tree_object)
end
if moretrees.enable_willow then
biome_lib:register_generate_plant(moretrees.willow_biome, moretrees.spawn_willow_object)
plantslib:register_generate_plant(moretrees.willow_biome, moretrees.spawn_willow_object)
end
if moretrees.enable_acacia then
biome_lib:register_generate_plant(moretrees.acacia_biome, moretrees.spawn_acacia_object)
plantslib:register_generate_plant(moretrees.acacia_biome, moretrees.spawn_acacia_object)
end
if moretrees.enable_birch then
biome_lib:register_generate_plant(moretrees.birch_biome, moretrees.spawn_birch_object)
plantslib:register_generate_plant(moretrees.birch_biome, moretrees.spawn_birch_object)
end
if moretrees.enable_spruce then
biome_lib:register_generate_plant(moretrees.spruce_biome, moretrees.spawn_spruce_object)
plantslib:register_generate_plant(moretrees.spruce_biome, moretrees.spawn_spruce_object)
end
if moretrees.enable_jungle_tree then
biome_lib:register_generate_plant(moretrees.jungletree_biome, moretrees.spawn_jungletree_object)
plantslib:register_generate_plant(moretrees.jungletree_biome, moretrees.spawn_jungletree_object)
end
if moretrees.enable_fir then
biome_lib:register_generate_plant(moretrees.fir_biome, moretrees.spawn_fir_object)
plantslib:register_generate_plant(moretrees.fir_biome, moretrees.spawn_fir_object)
if minetest.get_modpath("snow") then
biome_lib:register_generate_plant(moretrees.fir_biome_snow, moretrees.spawn_fir_snow_object)
plantslib:register_generate_plant(moretrees.fir_biome_snow, moretrees.spawn_fir_snow_object)
end
end
-- Code to spawn a birch tree
function moretrees.grow_birch(pos)
function moretrees:grow_birch(pos)
minetest.remove_node(pos)
if math.random(1,2) == 1 then
minetest.spawn_tree(pos, moretrees.birch_model1)
@ -180,7 +184,7 @@ end
-- Code to spawn a spruce tree
function moretrees.grow_spruce(pos)
function moretrees:grow_spruce(pos)
minetest.remove_node(pos)
if math.random(1,2) == 1 then
minetest.spawn_tree(pos, moretrees.spruce_model1)
@ -205,7 +209,7 @@ moretrees.ct_rules_b1 = "[-FBf][+FBf]"
moretrees.ct_rules_a2 = "FF[FF][&&-FBF][&&+FBF][&&---FBF][&&+++FBF]F/A"
moretrees.ct_rules_b2 = "[-fB][+fB]"
function moretrees.grow_jungletree(pos)
function moretrees:grow_jungletree(pos)
local r1 = math.random(2)
local r2 = math.random(3)
if r1 == 1 then
@ -235,6 +239,8 @@ function moretrees.grow_jungletree(pos)
moretrees.jungletree_model.rules_b = moretrees.jt_rules_b2
end
moretrees.jungletree_model.enable_unique_ids = true
minetest.remove_node(pos)
local leaves = minetest.find_nodes_in_area({x = pos.x-1, y = pos.y, z = pos.z-1}, {x = pos.x+1, y = pos.y+10, z = pos.z+1}, "default:leaves")
for leaf in ipairs(leaves) do
@ -245,7 +251,7 @@ end
-- code to spawn fir trees
function moretrees.grow_fir(pos)
function moretrees:grow_fir(pos)
if math.random(2) == 1 then
moretrees.fir_model.leaves="moretrees:fir_leaves"
else
@ -259,6 +265,7 @@ function moretrees.grow_fir(pos)
moretrees.fir_model.rules_b = moretrees.ct_rules_b2
end
moretrees.fir_model.enable_unique_ids = true
moretrees.fir_model.iterations = 7
moretrees.fir_model.random_level = 5
@ -272,7 +279,7 @@ end
-- same thing, but a smaller version that grows only in snow biomes
function moretrees.grow_fir_snow(pos)
function moretrees:grow_fir_snow(pos)
if math.random(2) == 1 then
moretrees.fir_model.leaves="moretrees:fir_leaves"
else
@ -286,6 +293,7 @@ function moretrees.grow_fir_snow(pos)
moretrees.fir_model.rules_b = moretrees.ct_rules_b2
end
moretrees.fir_model.enable_unique_ids = true
moretrees.fir_model.iterations = 2
moretrees.fir_model.random_level = 2
@ -297,4 +305,8 @@ function moretrees.grow_fir_snow(pos)
minetest.spawn_tree(pos,moretrees.fir_model)
end
minetest.log("action", S("[Moretrees] Loaded (2013-02-11)"))
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
print(dump(node.name)..": param1 = "..dump(node.param1)..", param2 = "..dump(node.param2))
end)
print(S("[Moretrees] Loaded (2013-02-11)"))

117
leafdecay.lua Normal file
View File

@ -0,0 +1,117 @@
-- leaf decay
-- this function is based on the default leafdecay code
local process_drops = function(pos, name)
local drops = minetest.get_node_drops(name)
for _,dropitem in ipairs(drops) do
if dropitem ~= name
or (string.find(name, "leaves") and moretrees.decay_leaves_as_items) then
local newpos = {
x=pos.x + math.random() - 0.5,
y=pos.y + math.random() - 0.5,
z=pos.z + math.random() - 0.5
}
minetest.add_item(newpos, dropitem)
end
end
end
if moretrees.enable_leafdecay then
for i in ipairs(moretrees.treelist) do
local treename = moretrees.treelist[i][1]
if treename ~= "jungletree" and treename ~= "fir" and treename ~= "palm" then
minetest.register_abm({
nodenames = "moretrees:"..treename.."_leaves",
interval = moretrees.leafdecay_delay,
chance = moretrees.leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.leafdecay_radius, { "ignore", "moretrees:"..treename.."_trunk" }) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
end
end
minetest.register_abm({
nodenames = {"moretrees:jungletree_leaves_red","moretrees:jungletree_leaves_green","moretrees:jungletree_leaves_yellow"},
interval = moretrees.leafdecay_delay,
chance = moretrees.leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.leafdecay_radius, {"ignore", "default:jungletree", "moretrees:jungletree_trunk"}) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
minetest.register_abm({
nodenames = {"moretrees:fir_leaves", "moretrees:fir_leaves_bright"},
interval = moretrees.leafdecay_delay,
chance = moretrees.leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.leafdecay_radius, { "ignore", "moretrees:fir_trunk" }) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
minetest.register_abm({
nodenames = "moretrees:palm_leaves",
interval = moretrees.leafdecay_delay,
chance = moretrees.leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.palm_leafdecay_radius, { "ignore", "moretrees:palm_trunk" }) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
end
if moretrees.enable_default_leafdecay then
minetest.register_abm({
nodenames = "default:leaves",
interval = moretrees.default_leafdecay_delay,
chance = moretrees.default_leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.default_leafdecay_radius, { "ignore", "default:tree" }) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
end
-- Decay apple tree blossoms from nature_classic mod
if minetest.get_modpath("nature_classic") then
minetest.register_abm({
nodenames = "moretrees:apple_blossoms",
interval = moretrees.default_leafdecay_delay,
chance = moretrees.default_leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.leafdecay_radius, { "ignore", "moretrees:apple_tree_trunk" }) then return end
process_drops(pos, "moretrees:apple_tree_leaves")
minetest.remove_node(pos)
nodeupdate(pos)
end
})
end
if moretrees.enable_default_jungle_leafdecay then
minetest.register_abm({
nodenames = "default:jungleleaves",
interval = moretrees.default_jungle_leafdecay_delay,
chance = moretrees.default_jungle_leafdecay_chance,
action = function(pos, node, active_object_count, active_object_count_wider)
if minetest.find_node_near(pos, moretrees.default_jungle_leafdecay_radius, { "ignore", "default:jungletree" }) then return end
process_drops(pos, node.name)
minetest.remove_node(pos)
nodeupdate(pos)
end
})
end

1
locale/de.txt Executable file → Normal file
View File

@ -65,6 +65,7 @@ Spruce Cone = Fichtenzapfen
Pine Cone = Kiefernzapfen
Fir Cone = Tannenzapfen
Jungle Sapling = Tropenbaumsetzling
Jungle Tree Leaves (Green) = Tropenbaumlaub (gruen)
Jungle Tree Leaves (Yellow) = Tropenbaumlaub (gelb)
Jungle Tree Leaves (Red) = Tropenbaumlaub (rot)
Douglas Fir Leaves (Bright) = Douglasiennadeln (breit)

1
locale/template.txt Executable file → Normal file
View File

@ -65,6 +65,7 @@ Spruce Cone =
Pine Cone =
Fir Cone =
Jungle Sapling =
Jungle Tree Leaves (Green) =
Jungle Tree Leaves (Yellow) =
Jungle Tree Leaves (Red) =
Douglas Fir Leaves (Bright) =

View File

@ -1 +0,0 @@
name = moretrees

301
node_defs.lua Executable file → Normal file
View File

@ -5,18 +5,17 @@ moretrees.avoidnodes = {}
moretrees.treelist = {
{"beech", "Beech Tree"},
{"apple_tree", "Apple Tree"},
{"oak", "Oak Tree", "acorn", "Acorn", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"oak", "Oak Tree", "acorn", "Acorn", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"sequoia", "Giant Sequoia"},
{"birch", "Birch Tree"},
{"palm", "Palm Tree", "coconut", "Coconut", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 1.0 },
{"spruce", "Spruce Tree", "spruce_cone", "Spruce Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"cedar", "Cedar Tree", "cedar_cone", "Cedar Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"palm", "Palm Tree", "coconut", "Coconut", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 1.0 },
{"spruce", "Spruce Tree", "spruce_cone", "Spruce Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"pine", "Pine Tree", "pine_cone", "Pine Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"willow", "Willow Tree"},
{"acacia", "Acacia Tree"},
{"rubber_tree", "Rubber Tree"},
{"fir", "Douglas Fir", "fir_cone", "Fir Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
{"jungletree", "Jungle Tree", nil, nil, nil, nil, "default_junglesapling.png" },
{"acacia", "Acacia Tree", nil, nil, nil, nil, "default_acacia_sapling.png" },
{"jungletree", "Jungle Tree"},
{"fir", "Douglas Fir", "fir_cone", "Fir Cone", {-0.2, -0.5, -0.2, 0.2, 0, 0.2}, 0.8 },
}
local dirs1 = { 21, 20, 23, 22, 21 }
@ -33,6 +32,11 @@ end
-- redefine default leaves to handle plantlike and/or leaf decay options
if moretrees.enable_default_leafdecay then
minetest.override_item("default:leaves", {
groups = { snappy = 3, flammable = 2, leaves = 1 }
})
end
if moretrees.plantlike_leaves then
minetest.override_item("default:leaves", {
inventory_image = minetest.inventorycube("default_leaves.png"),
@ -47,6 +51,11 @@ end
-- redefine default jungle leaves for same
if moretrees.enable_default_leafdecay then
minetest.override_item("default:jungleleaves", {
groups = { snappy = 3, flammable = 2, leaves = 1 }
})
end
if moretrees.plantlike_leaves then
minetest.override_item("default:jungleleaves", {
inventory_image = minetest.inventorycube("default_jungleleaves.png"),
@ -67,13 +76,7 @@ for i in ipairs(moretrees.treelist) do
local selbox = moretrees.treelist[i][5]
local vscale = moretrees.treelist[i][6]
local saptex = moretrees.treelist[i][7]
if treename ~= "jungletree" -- the default game provides jungle tree, acacia, and pine trunk/planks nodes.
and treename ~= "acacia"
and treename ~= "pine" then
saptex = "moretrees_"..treename.."_sapling.png"
if treename ~= "jungletree" then -- the default game provides jungle tree trunk/planks nodes.
minetest.register_node("moretrees:"..treename.."_trunk", {
description = S(treedesc.." Trunk"),
@ -100,10 +103,9 @@ for i in ipairs(moretrees.treelist) do
minetest.register_node("moretrees:"..treename.."_sapling", {
description = S(treedesc.." Sapling"),
drawtype = "plantlike",
tiles = {saptex},
inventory_image = saptex,
tiles = {"moretrees_"..treename.."_sapling.png"},
inventory_image = "moretrees_"..treename.."_sapling.png",
paramtype = "light",
paramtype2 = "waving",
walkable = false,
selection_box = {
type = "fixed",
@ -113,16 +115,31 @@ for i in ipairs(moretrees.treelist) do
sounds = default.node_sound_defaults(),
})
minetest.register_node("moretrees:"..treename.."_sapling_ongen", {
description = S(treedesc.." Sapling"),
drawtype = "plantlike",
tiles = {"moretrees_"..treename.."_sapling.png"},
inventory_image = "moretrees_"..treename.."_sapling.png",
paramtype = "light",
walkable = false,
selection_box = {
type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
},
groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1,not_in_creative_inventory=1,sapling=1},
sounds = default.node_sound_defaults(),
drop = "moretrees:"..treename.."_sapling"
})
-- player will get a sapling with 1/100 chance
-- player will get leaves only if he/she gets no saplings,
-- this is because max_items is 1
local droprarity = 100
local decay = moretrees.leafdecay_radius
if treename == "palm" then
droprarity = 20
decay = moretrees.palm_leafdecay_radius
end
local moretrees_leaves_inventory_image = nil
@ -142,7 +159,7 @@ for i in ipairs(moretrees.treelist) do
tiles = { "moretrees_"..treename.."_leaves.png" },
inventory_image = moretrees_leaves_inventory_image,
paramtype = "light",
groups = {snappy = 3, flammable = 2, leaves = 1, moretrees_leaves = 1, leafdecay = decay},
groups = {snappy=3, flammable=2, leaves=1, moretrees_leaves=1},
sounds = default.node_sound_leaves_defaults(),
drop = {
@ -154,83 +171,40 @@ for i in ipairs(moretrees.treelist) do
},
})
if moretrees.enable_stairs then
if minetest.get_modpath("moreblocks") then
if minetest.get_modpath("moreblocks") and moretrees.enable_stairsplus then
-- stairsplus:register_all(modname, subname, recipeitem, {fields})
-- stairsplus:register_all(modname, subname, recipeitem, {fields})
stairsplus:register_all(
"moretrees",
treename.."_trunk",
"moretrees:"..treename.."_trunk",
{
groups = { snappy=1, choppy=2, oddly_breakable_by_hand=1, flammable=2, not_in_creative_inventory=1 },
tiles = {
"moretrees_"..treename.."_trunk_top.png",
"moretrees_"..treename.."_trunk_top.png",
"moretrees_"..treename.."_trunk.png"
},
description = S(treedesc.." Trunk"),
drop = treename.."_trunk",
}
)
stairsplus:register_all(
"moretrees",
treename.."_planks",
"moretrees:"..treename.."_planks",
{
groups = { snappy=1, choppy=2, oddly_breakable_by_hand=2, flammable=3, not_in_creative_inventory=1 },
tiles = { "moretrees_"..treename.."_wood.png" },
description = S(treedesc.." Planks"),
drop = treename.."_planks",
}
)
elseif minetest.get_modpath("stairs") then
stairs.register_stair_and_slab(
"moretrees_"..treename.."_trunk",
"moretrees:"..treename.."_trunk",
{ snappy=1, choppy=2, oddly_breakable_by_hand=1, flammable=2 },
{ "moretrees_"..treename.."_trunk_top.png",
stairsplus:register_all(
"moretrees",
treename.."_trunk",
"moretrees:"..treename.."_trunk",
{
groups = { snappy=1, choppy=2, oddly_breakable_by_hand=1, flammable=2, not_in_creative_inventory=1 },
tiles = {
"moretrees_"..treename.."_trunk_top.png",
"moretrees_"..treename.."_trunk_top.png",
"moretrees_"..treename.."_trunk.png"
},
S(treedesc.." Trunk Stair"),
S(treedesc.." Trunk Slab"),
default.node_sound_wood_defaults()
)
description = S(treedesc.." Trunk"),
drop = treename.."_trunk",
}
)
stairs.register_stair_and_slab(
"moretrees_"..treename.."_planks",
"moretrees:"..treename.."_planks",
{ snappy=1, choppy=2, oddly_breakable_by_hand=2, flammable=3 },
{ "moretrees_"..treename.."_wood.png" },
S(treedesc.." Planks Stair"),
S(treedesc.." Planks Slab"),
default.node_sound_wood_defaults()
)
end
stairsplus:register_all(
"moretrees",
treename.."_planks",
"moretrees:"..treename.."_planks",
{
groups = { snappy=1, choppy=2, oddly_breakable_by_hand=2, flammable=3, not_in_creative_inventory=1 },
tiles = { "moretrees_"..treename.."_wood.png" },
description = S(treedesc.." Planks"),
drop = treename.."_planks",
}
)
end
end
minetest.register_node("moretrees:"..treename.."_sapling_ongen", {
description = S(treedesc.." Sapling"),
drawtype = "plantlike",
tiles = {saptex},
inventory_image = saptex,
paramtype = "light",
paramtype2 = "waving",
walkable = false,
selection_box = {
type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
},
groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1,not_in_creative_inventory=1,sapling=1},
sounds = default.node_sound_defaults(),
drop = "moretrees:"..treename.."_sapling"
})
if fruit then
minetest.register_node("moretrees:"..fruit, {
description = S(fruitdesc),
@ -239,9 +213,8 @@ for i in ipairs(moretrees.treelist) do
inventory_image = "moretrees_"..fruit..".png^[transformR180",
wield_image = "moretrees_"..fruit..".png^[transformR180",
visual_scale = vscale,
paramtype = "light",
sunlight_propagates = true,
walkable = false,
paramtype = "light",
selection_box = {
type = "fixed",
fixed = selbox
@ -257,7 +230,7 @@ for i in ipairs(moretrees.treelist) do
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
local fdir = node.param2 or 0
local nfdir = dirs2[fdir+1]
nfdir = dirs2[fdir+1]
minetest.add_node(pos, {name = "moretrees:"..treename.."_trunk", param2 = nfdir})
end,
})
@ -265,16 +238,51 @@ for i in ipairs(moretrees.treelist) do
table.insert(moretrees.avoidnodes, "moretrees:"..treename.."_trunk")
if moretrees.spawn_saplings then
table.insert(moretrees.avoidnodes, "moretrees:"..treename.."_sapling")
table.insert(moretrees.avoidnodes, "moretrees:"..treename.."_sapling_ongen")
table.insert(moretrees.avoidnodes, "moretrees:"..treename.."_sapling")
table.insert(moretrees.avoidnodes, "moretrees:"..treename.."_sapling_ongen")
end
end
-- Extra nodes for jungle trees:
local jungleleaves = {"yellow","red"}
local jungleleavesnames = {"Yellow", "Red"}
for color = 1, #jungleleaves do
minetest.register_node("moretrees:jungletree_sapling", {
description = S("Jungle Sapling"),
drawtype = "plantlike",
visual_scale = 1.0,
tiles = {"default_junglesapling.png"},
inventory_image = "default_junglesapling.png",
wield_image = "default_junglesapling.png",
paramtype = "light",
walkable = false,
selection_box = {
type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
},
groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1,sapling=1},
sounds = default.node_sound_leaves_defaults(),
})
minetest.register_node("moretrees:jungletree_sapling_ongen", {
description = S("Jungle Sapling"),
drawtype = "plantlike",
visual_scale = 1.0,
tiles = {"default_junglesapling.png"},
inventory_image = "default_junglesapling.png",
wield_image = "default_junglesapling.png",
paramtype = "light",
walkable = false,
selection_box = {
type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
},
groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1,not_in_creative_inventory=1,sapling=1},
sounds = default.node_sound_leaves_defaults(),
drop = "moretrees:jungletree_sapling"
})
local jungleleaves = {"green","yellow","red"}
local jungleleavesnames = {"Green", "Yellow", "Red"}
for color = 1, 3 do
local leave_name = "moretrees:jungletree_leaves_"..jungleleaves[color]
local moretrees_leaves_inventory_image = nil
@ -293,11 +301,11 @@ for color = 1, #jungleleaves do
tiles = {"moretrees_jungletree_leaves_"..jungleleaves[color]..".png"},
inventory_image = moretrees_leaves_inventory_image,
paramtype = "light",
groups = {snappy = 3, flammable = 2, leaves = 1, moretrees_leaves = 1, leafdecay = moretrees.leafdecay_radius },
groups = {snappy=3, flammable=2, leaves=1, moretrees_leaves=1},
drop = {
max_items = 1,
items = {
{items = {"default:junglesapling"}, rarity = 100 },
{items = {'moretrees:jungletree_sapling'}, rarity = 100 },
{items = {"moretrees:jungletree_leaves_"..jungleleaves[color]} }
}
},
@ -321,7 +329,7 @@ minetest.register_node("moretrees:fir_leaves_bright", {
tiles = { "moretrees_fir_leaves_bright.png" },
inventory_image = moretrees_leaves_inventory_image,
paramtype = "light",
groups = {snappy = 3, flammable = 2, leaves = 1, moretrees_leaves = 1, leafdecay = moretrees.leafdecay_radius },
groups = {snappy=3, flammable=2, leaves=1, moretrees_leaves=1 },
drop = {
max_items = 1,
items = {
@ -333,22 +341,21 @@ minetest.register_node("moretrees:fir_leaves_bright", {
})
if moretrees.enable_redefine_apple then
local appledef = moretrees.clone_node("default:apple")
appledef.groups.attached_node = 1
minetest.register_node(":default:apple", appledef)
minetest.override_item("default:apple",
{groups = { fleshy=3, dig_immediate=3, flammable=2, leafdecay=3, leafdecay_drop=1, attached_node = 1}
})
end
table.insert(moretrees.avoidnodes, "default:jungletree")
table.insert(moretrees.avoidnodes, "default:pine_tree")
table.insert(moretrees.avoidnodes, "default:acacia_tree")
table.insert(moretrees.avoidnodes, "moretrees:jungletree_trunk")
table.insert(moretrees.avoidnodes, "moretrees:fir_trunk")
table.insert(moretrees.avoidnodes, "default:tree")
if moretrees.spawn_saplings then
table.insert(moretrees.avoidnodes, "snow:sapling_pine")
table.insert(moretrees.avoidnodes, "default:junglesapling")
table.insert(moretrees.avoidnodes, "default:pine_sapling")
table.insert(moretrees.avoidnodes, "default:acacia_sapling")
table.insert(moretrees.avoidnodes, "snow:sapling_pine")
table.insert(moretrees.avoidnodes, "default:junglesapling")
table.insert(moretrees.avoidnodes, "moretrees:jungle_tree_sapling")
table.insert(moretrees.avoidnodes, "moretrees:jungle_tree_sapling_ongen")
end
-- "empty" (tapped) rubber tree nodes
@ -378,60 +385,38 @@ minetest.register_abm({
end,
})
-- To get Moretrees to generate its own jungle trees among the default mapgen
-- we need our own copy of that node, which moretrees will match against.
-- For compatibility with old nodes and recently-changed nodes.
local jungle_tree = moretrees.clone_node("default:jungletree")
jungle_tree.drop = jungle_tree.drop or { items = {} }
table.insert(jungle_tree.drop.items, { items = {"default:jungletree"}})
minetest.register_node("moretrees:jungletree_trunk", jungle_tree)
minetest.register_alias("technic:rubber_tree_full", "moretrees:rubber_tree_trunk")
minetest.register_alias("farming_plus:rubber_tree_full", "moretrees:rubber_tree_trunk")
minetest.register_alias("farming:rubber_tree_full", "moretrees:rubber_tree_trunk")
-- For compatibility with old nodes, recently-changed nodes, and default nodes
minetest.register_alias("technic:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("farming_plus:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("farming:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("technic:rubber_tree_full", "moretrees:rubber_tree_trunk")
minetest.register_alias("farming_plus:rubber_tree_full", "moretrees:rubber_tree_trunk")
minetest.register_alias("farming:rubber_tree_full", "moretrees:rubber_tree_trunk")
minetest.register_alias("technic:rubber_tree_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("farming_plus:rubber_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("farming:rubber_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("technic:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("farming_plus:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("farming:rubber_leaves", "moretrees:rubber_tree_leaves")
minetest.register_alias("default:junglesapling","moretrees:jungletree_sapling")
minetest.register_alias("moretrees:jungletree_trunk_sideways", "moreblocks:horizontal_jungle_tree")
minetest.register_alias("moretrees:jungletree_trunk", "default:jungletree")
minetest.register_alias("moretrees:jungletree_planks", "default:junglewood")
minetest.register_alias("technic:rubber_tree_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("farming_plus:rubber_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("farming:rubber_sapling", "moretrees:rubber_tree_sapling")
minetest.register_alias("jungletree:leaves_green", "moretrees:jungletree_leaves_green")
minetest.register_alias("jungletree:leaves_red", "moretrees:jungletree_leaves_red")
minetest.register_alias("jungletree:leaves_yellow", "moretrees:jungletree_leaves_yellow")
minetest.register_alias("moretrees:conifer_trunk", "moretrees:fir_trunk")
minetest.register_alias("moretrees:conifer_trunk_sideways", "moretrees:fir_trunk_sideways")
minetest.register_alias("moretrees:conifer_leaves", "moretrees:fir_leaves")
minetest.register_alias("moretrees:conifer_leaves_bright", "moretrees:fir_leaves_bright")
minetest.register_alias("moretrees:conifer_sapling", "moretrees:fir_sapling")
minetest.register_alias("moretrees:conifer_trunk", "moretrees:fir_trunk")
minetest.register_alias("moretrees:conifer_trunk_sideways", "moretrees:fir_trunk_sideways")
minetest.register_alias("moretrees:conifer_leaves", "moretrees:fir_leaves")
minetest.register_alias("moretrees:conifer_leaves_bright", "moretrees:fir_leaves_bright")
minetest.register_alias("moretrees:conifer_sapling", "moretrees:fir_sapling")
minetest.register_alias("conifers:trunk", "moretrees:fir_trunk")
minetest.register_alias("conifers:trunk_reversed", "moretrees:fir_trunk_sideways")
minetest.register_alias("conifers:leaves", "moretrees:fir_leaves")
minetest.register_alias("conifers:leaves_special", "moretrees:fir_leaves_bright")
minetest.register_alias("conifers:sapling", "moretrees:fir_sapling")
minetest.register_alias("conifers:trunk", "moretrees:fir_trunk")
minetest.register_alias("conifers:trunk_reversed", "moretrees:fir_trunk_sideways")
minetest.register_alias("conifers:leaves", "moretrees:fir_leaves")
minetest.register_alias("conifers:leaves_special", "moretrees:fir_leaves_bright")
minetest.register_alias("conifers:sapling", "moretrees:fir_sapling")
minetest.register_alias("moretrees:jungletree_sapling", "default:junglesapling")
minetest.register_alias("moretrees:jungletree_trunk_sideways", "moreblocks:horizontal_jungle_tree")
minetest.register_alias("moretrees:jungletree_planks", "default:junglewood")
minetest.register_alias("moretrees:jungletree_leaves_green", "default:jungleleaves")
minetest.register_alias("jungletree:leaves_green", "default:jungleleaves")
minetest.register_alias("jungletree:leaves_red", "moretrees:jungletree_leaves_red")
minetest.register_alias("jungletree:leaves_yellow", "moretrees:jungletree_leaves_yellow")
minetest.register_alias("moretrees:acacia_trunk", "default:acacia_tree")
minetest.register_alias("moretrees:acacia_planks", "default:acacia_wood")
minetest.register_alias("moretrees:acacia_sapling", "default:acacia_sapling")
minetest.register_alias("moretrees:acacia_leaves", "default:acacia_leaves")
minetest.register_alias("moretrees:pine_trunk", "moretrees:cedar_trunk")
minetest.register_alias("moretrees:pine_planks", "moretrees:cedar_planks")
minetest.register_alias("moretrees:pine_sapling", "moretrees:cedar_sapling")
minetest.register_alias("moretrees:pine_leaves", "moretrees:cedar_leaves")
minetest.register_alias("moretrees:pine_cone", "moretrees:cedar_cone")
minetest.register_alias("moretrees:pine_nuts", "moretrees:cedar_nuts")
-- Overriding moretrees' palm leaves:
minetest.override_item("moretrees:palm_leaves",{walkable = false})

40
saplings.lua Executable file → Normal file
View File

@ -7,8 +7,8 @@ for i in ipairs(moretrees.treelist) do
if treename ~= "birch" and treename ~= "spruce" and treename ~= "fir" and treename ~= "jungletree" then
biome_lib:dbg(dump(moretrees[tree_biome].surface))
biome_lib:grow_plants({
plantslib:dbg(dump(moretrees[tree_biome].surface))
plantslib:grow_plants({
grow_delay = moretrees.sapling_interval,
grow_chance = moretrees.sapling_chance,
grow_plant = "moretrees:"..treename.."_sapling",
@ -16,7 +16,7 @@ for i in ipairs(moretrees.treelist) do
grow_function = moretrees[tree_model],
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = 2,
grow_chance = 30,
grow_plant = "moretrees:"..treename.."_sapling_ongen",
@ -27,67 +27,67 @@ for i in ipairs(moretrees.treelist) do
end
end
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = moretrees.sapling_interval,
grow_chance = moretrees.sapling_chance,
grow_plant = "moretrees:birch_sapling",
grow_nodes = moretrees.birch_biome.surface,
grow_function = "moretrees.grow_birch"
grow_function = "moretrees:grow_birch"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = 2,
grow_chance = 30,
grow_plant = "moretrees:birch_sapling_ongen",
grow_nodes = moretrees.birch_biome.surface,
grow_function = "moretrees.grow_birch"
grow_function = "moretrees:grow_birch"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = moretrees.sapling_interval,
grow_chance = moretrees.sapling_chance,
grow_plant = "moretrees:spruce_sapling",
grow_nodes = moretrees.spruce_biome.surface,
grow_function = "moretrees.grow_spruce"
grow_function = "moretrees:grow_spruce"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = 2,
grow_chance = 30,
grow_plant = "moretrees:spruce_sapling_ongen",
grow_nodes = moretrees.spruce_biome.surface,
grow_function = "moretrees.grow_spruce"
grow_function = "moretrees:grow_spruce"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = moretrees.sapling_interval,
grow_chance = moretrees.sapling_chance,
grow_plant = "moretrees:fir_sapling",
grow_nodes = moretrees.fir_biome.surface,
grow_function = "moretrees.grow_fir"
grow_function = "moretrees:grow_fir"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = 2,
grow_chance = 30,
grow_plant = "moretrees:fir_sapling_ongen",
grow_nodes = moretrees.fir_biome.surface,
grow_function = "moretrees.grow_fir"
grow_function = "moretrees:grow_fir"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = moretrees.sapling_interval,
grow_chance = moretrees.sapling_chance,
grow_plant = "default:junglesapling",
grow_plant = "moretrees:jungletree_sapling",
grow_nodes = moretrees.jungletree_biome.surface,
grow_function = "moretrees.grow_jungletree"
grow_function = "moretrees:grow_jungletree"
})
biome_lib:grow_plants({
plantslib:grow_plants({
grow_delay = 2,
grow_chance = 30,
grow_plant = "moretrees:jungletree_sapling_ongen",
grow_nodes = moretrees.jungletree_biome.surface,
grow_function = "moretrees.grow_jungletree"
grow_function = "moretrees:grow_jungletree"
})

Binary file not shown.

After

Width:  |  Height:  |  Size: 150 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 205 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 599 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 651 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 175 B

BIN
textures/moretrees_acorn.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 398 B

After

Width:  |  Height:  |  Size: 417 B

BIN
textures/moretrees_acorn_muffin.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 765 B

After

Width:  |  Height:  |  Size: 782 B

BIN
textures/moretrees_acorn_muffin_batter.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 602 B

After

Width:  |  Height:  |  Size: 619 B

0
textures/moretrees_apple_tree_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 351 B

After

Width:  |  Height:  |  Size: 351 B

BIN
textures/moretrees_apple_tree_sapling.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 178 B

After

Width:  |  Height:  |  Size: 183 B

0
textures/moretrees_apple_tree_trunk.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

0
textures/moretrees_apple_tree_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 503 B

After

Width:  |  Height:  |  Size: 503 B

0
textures/moretrees_apple_tree_wood.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 464 B

After

Width:  |  Height:  |  Size: 464 B

0
textures/moretrees_beech_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 201 B

After

Width:  |  Height:  |  Size: 201 B

0
textures/moretrees_beech_sapling.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 177 B

After

Width:  |  Height:  |  Size: 177 B

BIN
textures/moretrees_beech_trunk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 964 B

After

Width:  |  Height:  |  Size: 980 B

0
textures/moretrees_beech_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 926 B

After

Width:  |  Height:  |  Size: 926 B

BIN
textures/moretrees_beech_wood.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 170 B

After

Width:  |  Height:  |  Size: 175 B

0
textures/moretrees_birch_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 459 B

After

Width:  |  Height:  |  Size: 459 B

BIN
textures/moretrees_birch_sapling.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 204 B

After

Width:  |  Height:  |  Size: 208 B

BIN
textures/moretrees_birch_trunk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 959 B

After

Width:  |  Height:  |  Size: 975 B

0
textures/moretrees_birch_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 811 B

After

Width:  |  Height:  |  Size: 811 B

0
textures/moretrees_birch_wood.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

0
textures/moretrees_coconut.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 963 B

After

Width:  |  Height:  |  Size: 963 B

BIN
textures/moretrees_coconut_milk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 211 B

After

Width:  |  Height:  |  Size: 227 B

0
textures/moretrees_coconut_milk_inv.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 199 B

After

Width:  |  Height:  |  Size: 199 B

BIN
textures/moretrees_fir_cone.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 227 B

After

Width:  |  Height:  |  Size: 244 B

0
textures/moretrees_fir_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 205 B

After

Width:  |  Height:  |  Size: 205 B

0
textures/moretrees_fir_leaves_bright.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 205 B

After

Width:  |  Height:  |  Size: 205 B

0
textures/moretrees_fir_nuts.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 361 B

After

Width:  |  Height:  |  Size: 361 B

BIN
textures/moretrees_fir_sapling.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 161 B

After

Width:  |  Height:  |  Size: 166 B

0
textures/moretrees_fir_trunk.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 753 B

After

Width:  |  Height:  |  Size: 753 B

0
textures/moretrees_fir_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 924 B

After

Width:  |  Height:  |  Size: 924 B

BIN
textures/moretrees_fir_wood.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

0
textures/moretrees_jungletree_leaves_green.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 201 B

After

Width:  |  Height:  |  Size: 201 B

0
textures/moretrees_jungletree_leaves_red.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 201 B

After

Width:  |  Height:  |  Size: 201 B

0
textures/moretrees_jungletree_leaves_yellow.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 201 B

After

Width:  |  Height:  |  Size: 201 B

0
textures/moretrees_oak_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 730 B

After

Width:  |  Height:  |  Size: 730 B

0
textures/moretrees_oak_sapling.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 172 B

After

Width:  |  Height:  |  Size: 172 B

BIN
textures/moretrees_oak_trunk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 982 B

After

Width:  |  Height:  |  Size: 998 B

0
textures/moretrees_oak_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 519 B

After

Width:  |  Height:  |  Size: 519 B

BIN
textures/moretrees_oak_wood.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 599 B

After

Width:  |  Height:  |  Size: 618 B

BIN
textures/moretrees_palm_leaves.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 902 B

After

Width:  |  Height:  |  Size: 918 B

0
textures/moretrees_palm_sapling.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 122 B

After

Width:  |  Height:  |  Size: 122 B

0
textures/moretrees_palm_trunk.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 295 B

After

Width:  |  Height:  |  Size: 295 B

0
textures/moretrees_palm_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 400 B

After

Width:  |  Height:  |  Size: 400 B

BIN
textures/moretrees_palm_wood.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 580 B

After

Width:  |  Height:  |  Size: 598 B

View File

Before

Width:  |  Height:  |  Size: 315 B

After

Width:  |  Height:  |  Size: 315 B

View File

Before

Width:  |  Height:  |  Size: 205 B

After

Width:  |  Height:  |  Size: 205 B

View File

Before

Width:  |  Height:  |  Size: 369 B

After

Width:  |  Height:  |  Size: 369 B

View File

Before

Width:  |  Height:  |  Size: 202 B

After

Width:  |  Height:  |  Size: 202 B

View File

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

Before

Width:  |  Height:  |  Size: 451 B

After

Width:  |  Height:  |  Size: 451 B

View File

Before

Width:  |  Height:  |  Size: 648 B

After

Width:  |  Height:  |  Size: 648 B

0
textures/moretrees_raw_coconut.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 466 B

After

Width:  |  Height:  |  Size: 466 B

0
textures/moretrees_rubber_tree_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 201 B

After

Width:  |  Height:  |  Size: 201 B

0
textures/moretrees_rubber_tree_sapling.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 151 B

After

Width:  |  Height:  |  Size: 151 B

0
textures/moretrees_rubber_tree_trunk.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 693 B

After

Width:  |  Height:  |  Size: 693 B

BIN
textures/moretrees_rubber_tree_trunk_empty.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

0
textures/moretrees_rubber_tree_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 534 B

After

Width:  |  Height:  |  Size: 534 B

0
textures/moretrees_rubber_tree_wood.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 435 B

After

Width:  |  Height:  |  Size: 435 B

0
textures/moretrees_sequoia_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 205 B

After

Width:  |  Height:  |  Size: 205 B

BIN
textures/moretrees_sequoia_sapling.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 199 B

After

Width:  |  Height:  |  Size: 209 B

BIN
textures/moretrees_sequoia_trunk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 620 B

After

Width:  |  Height:  |  Size: 621 B

0
textures/moretrees_sequoia_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 594 B

After

Width:  |  Height:  |  Size: 594 B

BIN
textures/moretrees_sequoia_wood.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1021 B

After

Width:  |  Height:  |  Size: 1.0 KiB

BIN
textures/moretrees_spruce_cone.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 478 B

After

Width:  |  Height:  |  Size: 496 B

0
textures/moretrees_spruce_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 205 B

After

Width:  |  Height:  |  Size: 205 B

0
textures/moretrees_spruce_nuts.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 365 B

After

Width:  |  Height:  |  Size: 365 B

BIN
textures/moretrees_spruce_sapling.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 151 B

After

Width:  |  Height:  |  Size: 153 B

0
textures/moretrees_spruce_trunk.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 753 B

After

Width:  |  Height:  |  Size: 753 B

0
textures/moretrees_spruce_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 414 B

After

Width:  |  Height:  |  Size: 414 B

0
textures/moretrees_spruce_wood.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 536 B

After

Width:  |  Height:  |  Size: 536 B

0
textures/moretrees_willow_leaves.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 409 B

After

Width:  |  Height:  |  Size: 409 B

0
textures/moretrees_willow_sapling.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 168 B

After

Width:  |  Height:  |  Size: 168 B

BIN
textures/moretrees_willow_trunk.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 620 B

After

Width:  |  Height:  |  Size: 630 B

0
textures/moretrees_willow_trunk_top.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 513 B

After

Width:  |  Height:  |  Size: 513 B

0
textures/moretrees_willow_wood.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 565 B

After

Width:  |  Height:  |  Size: 565 B

5
tree_biomes.txt Executable file → Normal file
View File

@ -11,7 +11,7 @@ oak 0 to +10 + 4 to +16 n/a n/a dirt_with grass 332 15
sequoia 0 to +10 -30 to +50 n/a n/a dirt_with grass 333 10
birch +10 to +15 -20 to +10 n/a n/a dirt_with grass 334 5
spruce above +20 -20 to +10 n/a n/a dirt_with grass 335 10
cedar n/a n/a water, 15 5 dirt_with grass 336 10
pine n/a n/a water, 15 5 dirt_with grass 336 10
willow - 5 to + 5 n/a water, 15 5 dirt_with grass 337 20
acacia n/a n/a n/a n/a dirt_with_grass,
desert_sand n/a 15
@ -32,6 +32,3 @@ where the humidity is low (but not bone dry).
Fir trees appear in a snow biome only with older versions of SPlizard's Snow Biomes mod. In more recent versions,
these trees will not grow, due to an engine bug.
Cedar trees replace, and are identical to, the original pine trees, as the minetest default game now has (a completely
different type of) pine trees.

55
tree_models.lua Executable file → Normal file
View File

@ -10,7 +10,8 @@ moretrees.beech_model={
iterations=2,
random_level=0,
trunk_type="single",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.apple_tree_model={
@ -26,6 +27,7 @@ moretrees.apple_tree_model={
thin_branches=true,
fruit="default:apple",
fruit_chance=15,
enable_unique_ids = true,
}
moretrees.oak_model={
@ -41,6 +43,7 @@ moretrees.oak_model={
thin_branches=false,
fruit="moretrees:acorn",
fruit_chance=3,
enable_unique_ids = true,
}
moretrees.sequoia_model={
@ -55,7 +58,8 @@ moretrees.sequoia_model={
iterations=2,
random_level=0,
trunk_type="crossed",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.birch_model1={
@ -70,7 +74,8 @@ moretrees.birch_model1={
iterations=2,
random_level=0,
trunk_type="single",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.birch_model2={
@ -85,7 +90,8 @@ moretrees.birch_model2={
iterations=2,
random_level=0,
trunk_type="single",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.palm_model={
@ -102,7 +108,8 @@ moretrees.palm_model={
trunk_type="single",
thin_branches=true,
fruit="moretrees:coconut",
fruit_chance=0
fruit_chance=0,
enable_unique_ids = true,
}
moretrees.spruce_model1={
@ -119,7 +126,8 @@ moretrees.spruce_model1={
trunk_type="crossed",
thin_branches=true,
fruit="moretrees:spruce_cone",
fruit_chance=8
fruit_chance=8,
enable_unique_ids = true,
}
moretrees.spruce_model2={
@ -135,24 +143,26 @@ moretrees.spruce_model2={
trunk_type="crossed",
thin_branches=true,
fruit="moretrees:spruce_cone",
fruit_chance=8
fruit_chance=8,
enable_unique_ids = true,
}
moretrees.cedar_model={
moretrees.pine_model={
axiom="FFFFFcccdddB///cFdFB////cFdFB///cFdFB///cFdFA///cFdFA///cFdFB[FF]f",
rules_a="[&&&TTTT[++^TFdd][--&TFd]//Tdd[+^Fd][--&Fdd]]",
rules_b="[&&&TTT[++^Fdd][--&Fdd]//dd[+^d][--&Fd]]",
rules_c="/",
rules_d="F",
trunk="moretrees:cedar_trunk",
leaves="moretrees:cedar_leaves",
trunk="moretrees:pine_trunk",
leaves="moretrees:pine_leaves",
angle=30,
iterations=2,
random_level=0,
trunk_type="single",
thin_branches=true,
fruit="moretrees:cedar_cone",
fruit_chance=8
fruit="moretrees:pine_cone",
fruit_chance=8,
enable_unique_ids = true,
}
moretrees.willow_model={
@ -166,7 +176,8 @@ moretrees.willow_model={
iterations=2,
random_level=0,
trunk_type="crossed",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.acacia_model={
@ -191,13 +202,14 @@ moretrees.acacia_model={
.."GGfffff--G--"
.."ffffGGG",
rules_c = "/",
trunk="default:acacia_tree",
leaves="default:acacia_leaves",
trunk="moretrees:acacia_trunk",
leaves="moretrees:acacia_leaves",
angle=45,
iterations=3,
random_level=0,
trunk_type="single",
thin_branches=true,
enable_unique_ids = true,
}
moretrees.rubber_tree_model={
@ -210,15 +222,16 @@ moretrees.rubber_tree_model={
iterations=3,
random_level=1,
trunk_type="double",
thin_branches=true
thin_branches=true,
enable_unique_ids = true,
}
moretrees.jungletree_model={
axiom=nil,
rules_a=nil,
rules_b=nil,
trunk="moretrees:jungletree_trunk",
leaves="default:jungleleaves",
trunk="default:jungletree",
leaves="moretrees:jungletree_leaves_green",
leaves2=nil,
leaves2_chance=nil,
angle=45,
@ -227,7 +240,8 @@ moretrees.jungletree_model={
trunk_type=nil,
thin_branches=true,
fruit_chance=15,
fruit="vines:vine"
fruit="vines:vine",
enable_unique_ids = true,
}
moretrees.fir_model={
@ -242,5 +256,6 @@ moretrees.fir_model={
trunk_type="single",
thin_branches=true,
fruit="moretrees:fir_cone",
fruit_chance=8
fruit_chance=8,
enable_unique_ids = true,
}