add cool_trees modpack (all components)
update castles, farming redo, maptools, mesecons, moreblocks, moreores, signs_lib, technic, unified inventory, and worldedit
@ -25,10 +25,14 @@ Mod settings can allow for the basic castle masonry forms to be made for the fol
|
||||
* Desert stone brick
|
||||
* Sandstone
|
||||
* Sandstone brick
|
||||
* Desert Sandstone
|
||||
* Desert Sandstone brick
|
||||
* Silver Sandstone
|
||||
* Silver Sandstone brick
|
||||
* Stone
|
||||
* Stone brick
|
||||
* Castle wall
|
||||
* Wood
|
||||
* Snow
|
||||
* Ice
|
||||
* Obsidian Brick
|
||||
* Obsidian Brick
|
||||
|
@ -40,6 +40,12 @@ end
|
||||
if read_setting("castle_masonry_desertstonebrick", true) then
|
||||
table.insert(castle_masonry.materials, {name="desertstonebrick", desc=S("Desert Stone Brick"), tile="default_desert_stone_brick.png", craft_material="default:desert_stonebrick"})
|
||||
end
|
||||
if read_setting("castle_masonry_desertsandstonebrick", true) then
|
||||
table.insert(castle_masonry.materials, {name="desertsandstonebrick", desc=S("Desert Sandstone Brick"), tile="default_desert_sandstone_brick.png", craft_material="default:desert_sandstone_brick"})
|
||||
end
|
||||
if read_setting("castle_masonry_silversandstonebrick", true) then
|
||||
table.insert(castle_masonry.materials, {name="silversandstonebrick", desc=S("Silver Sandstone Brick"), tile="default_silver_sandstone_brick.png", craft_material="default:silver_sandstone_brick"})
|
||||
end
|
||||
if read_setting("castle_masonry_stone", true) then
|
||||
table.insert(castle_masonry.materials, {name="stone", desc=S("Stone"), tile="default_stone.png", craft_material="default:stone"})
|
||||
end
|
||||
@ -49,6 +55,12 @@ end
|
||||
if read_setting("castle_masonry_desertstone", true) then
|
||||
table.insert(castle_masonry.materials, {name="desertstone", desc=S("Desert Stone"), tile="default_desert_stone.png", craft_material="default:desert_stone"})
|
||||
end
|
||||
if read_setting("castle_masonry_desertsandstone", true) then
|
||||
table.insert(castle_masonry.materials, {name="desertsandstone", desc=S("Desert Sandstone"), tile="default_desert_sandstone.png", craft_material="default:desert_sandstone"})
|
||||
end
|
||||
if read_setting("castle_masonry_silversandstone", true) then
|
||||
table.insert(castle_masonry.materials, {name="silversandstone", desc=S("Silver Sandstone"), tile="default_silver_sandstone.png", craft_material="default:silver_sandstone"})
|
||||
end
|
||||
if read_setting("castle_masonry_wood", false) then
|
||||
table.insert(castle_masonry.materials, {name="wood", desc=S("Wood"), tile="default_wood.png", craft_material="group:wood", composition_material="default:wood"})
|
||||
end
|
||||
|
@ -5,9 +5,13 @@ castle_masonry_cobble (Cobble) bool true
|
||||
castle_masonry_stonebrick (Stone Brick) bool true
|
||||
castle_masonry_sandstonebrick (Sandstone Brick) bool true
|
||||
castle_masonry_desertstonebrick (Desert Stone Brick) bool true
|
||||
castle_masonry_desertsandstonebrick (Desert Sandstone Brick) bool true
|
||||
castle_masonry_silversandstonebrick (Silver Sandstone Brick) bool true
|
||||
castle_masonry_stone (Stone) bool true
|
||||
castle_masonry_sandstone (Sandstone) bool true
|
||||
castle_masonry_desertstone (Desert Stone) bool true
|
||||
castle_masonry_desertsandstone (Desert Sandstone) bool true
|
||||
castle_masonry_silversandstone (Silver Sandstone) bool true
|
||||
castle_masonry_wood (Wood) bool false
|
||||
castle_masonry_ice (Ice) bool false
|
||||
castle_masonry_snow (Snow) bool false
|
||||
@ -17,4 +21,4 @@ castle_masonry_obsidianbrick (Obsidian Brick) bool false
|
||||
|
||||
castle_masonry_pillar (Pillars) bool true
|
||||
castle_masonry_arrowslit (Arrow slits) bool true
|
||||
castle_masonry_murderhole (Murder holes and machicolations) bool true
|
||||
castle_masonry_murderhole (Murder holes and machicolations) bool true
|
||||
|
3
cool_trees/LICENSE.md
Normal file
@ -0,0 +1,3 @@
|
||||
Models, icons and textures by runs.
|
||||
License: GPLv3
|
||||
|
1
cool_trees/README.md
Normal file
@ -0,0 +1 @@
|
||||
# cool_trees
|
275
cool_trees/bamboo/init.lua
Normal file
@ -0,0 +1,275 @@
|
||||
--
|
||||
-- Bamboo
|
||||
--
|
||||
|
||||
-- Thanks to VanessaE, Tenplus1, paramat and all others who
|
||||
-- contribute to this mod
|
||||
|
||||
local modname = "bamboo"
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
bamboo = {}
|
||||
|
||||
-- bamboo stalk with leaves
|
||||
|
||||
local ai = {name = "air", param1 = 000}
|
||||
local bt = {name = "bamboo:trunk", param1 = 255}
|
||||
local bf = {name = "bamboo:trunk", param1 = 255, force_place = true}
|
||||
local fd = {name = "default:dirt", param1 = 255, force_place = true}
|
||||
local lp = {name = "bamboo:leaves", param1 = 255}
|
||||
local lr = {name = "bamboo:leaves", param1 = 100}
|
||||
|
||||
bamboo.bambootree = {
|
||||
|
||||
size = {x = 3, y = 18, z = 3},
|
||||
|
||||
data = {
|
||||
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
lr, lr, lr,
|
||||
lr, lp, lr,
|
||||
ai, lp, ai,
|
||||
ai, ai, ai,
|
||||
|
||||
ai, fd, ai,
|
||||
ai, bf, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
ai, bt, ai,
|
||||
lr, bt, lr,
|
||||
lr, lp, lr,
|
||||
ai, lp, ai,
|
||||
ai, lr, ai,
|
||||
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
ai, ai, ai,
|
||||
lr, lr, lr,
|
||||
lr, lp, lr,
|
||||
ai, lp, ai,
|
||||
ai, ai, ai,
|
||||
|
||||
},
|
||||
|
||||
yslice_prob = {
|
||||
{ypos = 3, prob = 127},
|
||||
{ypos = 4, prob = 127},
|
||||
{ypos = 5, prob = 127},
|
||||
{ypos = 6, prob = 127},
|
||||
{ypos = 7, prob = 127},
|
||||
{ypos = 8, prob = 127},
|
||||
{ypos = 9, prob = 127},
|
||||
{ypos = 10, prob = 127},
|
||||
{ypos = 11, prob = 127},
|
||||
{ypos = 12, prob = 127},
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
local function grow_new_bambootree_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.place_schematic({x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
|
||||
bamboo.bambootree, "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.001,
|
||||
spread = {x = 240, y = 240, z = 240},
|
||||
seed = 2776,
|
||||
octaves = 3,
|
||||
persist = 0.65
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
y_min = 2,
|
||||
y_max = 20,
|
||||
schematic = bamboo.bambootree,
|
||||
flags = "place_center_x, place_center_z",
|
||||
})
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
-- Bamboo (thanks to Nelo-slay on DeviantArt for the free Bamboo base image)
|
||||
minetest.register_node("bamboo:trunk", {
|
||||
description = S("Bamboo"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"bamboo.png"},
|
||||
inventory_image = "bamboo.png",
|
||||
wield_image = "bamboo.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = true,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3}
|
||||
},
|
||||
is_ground_content = false,
|
||||
groups = {choppy = 3, oddly_breakable_by_hand = 1, flammable = 2, tree = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_dig_node = function(pos, node, metadata, digger)
|
||||
default.dig_up(pos, node, digger)
|
||||
end,
|
||||
|
||||
})
|
||||
|
||||
-- bamboo wood
|
||||
minetest.register_node("bamboo:wood", {
|
||||
description = S("Bamboo Wood"),
|
||||
tiles = {"bamboo_floor.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(),
|
||||
})
|
||||
|
||||
-- bamboo stalk leaves
|
||||
minetest.register_node("bamboo:leaves", {
|
||||
description = S("Bamboo Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"bamboo_leaves.png"},
|
||||
inventory_image = "bamboo_leaves.png",
|
||||
wield_image = "bamboo_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"bamboo:sprout"}, rarity = 10},
|
||||
{items = {"bamboo:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
|
||||
-- Bamboo Sprout
|
||||
minetest.register_node("bamboo:sprout", {
|
||||
description = S("Bamboo Sprout"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"bamboo_sprout.png"},
|
||||
inventory_image = "bamboo_sprout.png",
|
||||
wield_image = "bamboo_sprout.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
groups = {
|
||||
snappy = 3, attached_node = 1, flammable = 2,
|
||||
dig_immediate = 3, ethereal_sapling = 1
|
||||
},
|
||||
sounds = default.node_sound_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, 0, 4 / 16}
|
||||
},
|
||||
on_use = minetest.item_eat(2),
|
||||
grown_height = 11,
|
||||
on_timer = grow_new_bambootree_tree,
|
||||
on_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(2400,4800))
|
||||
end,
|
||||
})
|
||||
|
||||
-- crafts
|
||||
minetest.register_craft({
|
||||
output = "bamboo:wood 4",
|
||||
recipe = {{"bamboo:trunk"}}
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"bamboo:trunk"},
|
||||
leaves = {"bamboo:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "bamboo:convert_bambootree_sprouts_to_node_timer",
|
||||
nodenames = {"bamboo:sprout"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"bamboo:sprout", grow_new_bambootree_tree, "soil"},
|
||||
})
|
||||
end
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"bamboo_trunk",
|
||||
"bamboo:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"bamboo_floor.png"},
|
||||
S("Bamboo Stair"),
|
||||
S("Bamboo Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
-- stairsplus/moreblocks
|
||||
if minetest.get_modpath("moreblocks") then
|
||||
stairsplus:register_all("bamboo", "wood", "bamboo:wood", {
|
||||
description = "Bamboo",
|
||||
tiles = {"bamboo_floor.png"},
|
||||
groups = {choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
end
|
7
cool_trees/bamboo/locale/bamboo.es.tr
Normal file
@ -0,0 +1,7 @@
|
||||
# textdomain: bamboo
|
||||
Bamboo=Bambú
|
||||
Bamboo Leaves=Hojas de bambú
|
||||
Bamboo Sprout=Brote de bambú
|
||||
Bamboo Wood=Tablas de bambú
|
||||
Bamboo Stair=Escaleras de bambú
|
||||
Bamboo Slab=Losa de bambú
|
4
cool_trees/bamboo/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = bamboo
|
||||
description = Bamboo Tree for Grassland
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal, moreblocks
|
BIN
cool_trees/bamboo/textures/bamboo.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
cool_trees/bamboo/textures/bamboo_floor.png
Normal file
After Width: | Height: | Size: 564 B |
BIN
cool_trees/bamboo/textures/bamboo_leaves.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
cool_trees/bamboo/textures/bamboo_sprout.png
Normal file
After Width: | Height: | Size: 908 B |
0
cool_trees/baobab/init.lua
Normal file
BIN
cool_trees/baobab/schematics/baobab.mts
Normal file
BIN
cool_trees/baobab/schematics/baobab1.mts
Normal file
BIN
cool_trees/baobab/schematics/baobab2.mts
Normal file
259
cool_trees/birch/init.lua
Normal file
@ -0,0 +1,259 @@
|
||||
|
||||
--
|
||||
-- Birch Tree
|
||||
--
|
||||
|
||||
local modname = "birch"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
|
||||
-- internationalization boilerplate
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
birch = {}
|
||||
|
||||
|
||||
-- birch tree
|
||||
|
||||
local ai = {name = "air", param1 = 000}
|
||||
local tr = {name = "birch:trunk", param1 = 255, force_place = true}
|
||||
local lp = {name = "birch:leaves", param1 = 255}
|
||||
local lr = {name = "birch:leaves", param1 = 255}
|
||||
|
||||
birch.birchtree = {
|
||||
|
||||
size = {x = 5, y = 7, z = 5},
|
||||
|
||||
data = {
|
||||
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
lr, lp, lp, lp, lr,
|
||||
lr, lp, lp, lp, lr,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
lp, lp, lp, lp, lp,
|
||||
lp, lp, lp, lp, lp,
|
||||
ai, lr, lp, lr, ai,
|
||||
ai, ai, lp, ai, ai,
|
||||
|
||||
ai, ai, tr, ai, ai,
|
||||
ai, ai, tr, ai, ai,
|
||||
ai, ai, tr, ai, ai,
|
||||
lp, lp, tr, lp, lp,
|
||||
lp, lp, tr, lp, lp,
|
||||
ai, lp, tr, lp, ai,
|
||||
ai, lp, lp, lp, ai,
|
||||
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
lp, lp, lp, lp, lp,
|
||||
lp, lp, lp, lp, lp,
|
||||
ai, lr, lp, lr, ai,
|
||||
ai, ai, lp, ai, ai,
|
||||
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
lr, lp, lp, lp, lr,
|
||||
lr, lp, lp, lp, lr,
|
||||
ai, ai, ai, ai, ai,
|
||||
ai, ai, ai, ai, ai,
|
||||
|
||||
},
|
||||
|
||||
yslice_prob = {
|
||||
{ypos = 1, prob = 127}
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
local function grow_new_birch_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.place_schematic({x = pos.x - 2, y = pos.y - 1, z = pos.z - 2}, birch.birchtree, "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.008,
|
||||
scale = 0.001,
|
||||
spread = {x = 255, y = 255, z = 255},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.67
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
y_min = 10,
|
||||
y_max = 80,
|
||||
schematic = birch.birchtree,
|
||||
flags = "place_center_x, place_center_z",
|
||||
})
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("birch:sapling", {
|
||||
description = S("Birch Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"birch_sapling.png"},
|
||||
inventory_image = "birch_sapling.png",
|
||||
wield_image = "birch_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_birch_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,
|
||||
"birch: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,
|
||||
})
|
||||
|
||||
-- birch trunk
|
||||
minetest.register_node("birch:trunk", {
|
||||
description = S("Birch Trunk"),
|
||||
tiles = {
|
||||
"birch_trunk_top.png",
|
||||
"birch_trunk_top.png",
|
||||
"birch_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,
|
||||
is_ground_content = false,
|
||||
--on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
--minetest.item_place_node(itemstack, player, pointed_thing, nil)
|
||||
--end
|
||||
})
|
||||
|
||||
-- birch wood
|
||||
minetest.register_node("birch:wood", {
|
||||
description = S("Birch Wood"),
|
||||
tiles = {"birch_wood.png"},
|
||||
is_ground_content = false,
|
||||
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
-- birch tree leaves
|
||||
minetest.register_node("birch:leaves", {
|
||||
description = S("Birch Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"birch_leaves.png"},
|
||||
inventory_image = "birch_leaves.png",
|
||||
wield_image = "birch_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"birch:sapling"}, rarity = 20},
|
||||
{items = {"birch:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "birch:wood 4",
|
||||
recipe = {{"birch:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "birch:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "birch:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "birch:convert_birch_saplings_to_node_timer",
|
||||
nodenames = {"birch:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"birch:trunk"},
|
||||
leaves = {"birch:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"birch_trunk",
|
||||
"birch:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"birch_wood.png"},
|
||||
S("Birch Tree Stair"),
|
||||
S("Birch Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"birch:sapling", grow_new_birch_tree, "soil"},
|
||||
})
|
||||
end
|
10
cool_trees/birch/locale/birch.es.tr
Normal file
@ -0,0 +1,10 @@
|
||||
# textdomain: birch
|
||||
Birch Sapling=Retoño de abedul
|
||||
Birch Trunk=Madera de abedul
|
||||
Birch Wood=Tablas de abedul
|
||||
Birch Leaves=Hojas de abedul
|
||||
Birch Tree Stair=Escaleras de abedul
|
||||
Birch Tree Slab=Losa de abedul
|
||||
Inner Birch Tree Stair=Escaleras de abedul interior
|
||||
Outer Birch Tree Stair=Escaleras de abedul exterior
|
||||
Birch Slab=Losa de abedul
|
4
cool_trees/birch/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = birch
|
||||
description = Birch Tree for Grassland
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
BIN
cool_trees/birch/textures/birch_leaves.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
cool_trees/birch/textures/birch_sapling.png
Normal file
After Width: | Height: | Size: 649 B |
BIN
cool_trees/birch/textures/birch_trunk.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
cool_trees/birch/textures/birch_trunk_top.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
cool_trees/birch/textures/birch_wood.png
Normal file
After Width: | Height: | Size: 2.8 KiB |
271
cool_trees/cherrytree/init.lua
Normal file
@ -0,0 +1,271 @@
|
||||
--
|
||||
-- Cherrytree
|
||||
--
|
||||
local modname = "cherrytree"
|
||||
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())
|
||||
|
||||
-- Cherry Fruit
|
||||
|
||||
minetest.register_node("cherrytree:cherries", {
|
||||
description = S("Cherries"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"cherrytree_cherries.png"},
|
||||
inventory_image = "cherrytree_cherries.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 = "cherrytree:cherries", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
-- Cherrytree
|
||||
|
||||
local function grow_new_cherrytree_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.place_schematic({x = pos.x-2, y = pos.y, z = pos.z-2}, modpath.."/schematics/cherrytree.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0005,
|
||||
scale = 0.00005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"deciduous_forest"},
|
||||
y_min = 1,
|
||||
y_max = 32,
|
||||
schematic = modpath.."/schematics/cherrytree.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("cherrytree:sapling", {
|
||||
description = S("Cherrytree Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"cherrytree_sapling.png"},
|
||||
inventory_image = "cherrytree_sapling.png",
|
||||
wield_image = "cherrytree_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_cherrytree_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,
|
||||
"cherrytree: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("cherrytree:trunk", {
|
||||
description = S("Cherrytree Trunk"),
|
||||
tiles = {
|
||||
"cherrytree_trunk_top.png",
|
||||
"cherrytree_trunk_top.png",
|
||||
"cherrytree_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,
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
--minetest.item_place_node(itemstack, player, pointed_thing, nil)
|
||||
end
|
||||
})
|
||||
|
||||
-- cherrytree wood
|
||||
minetest.register_node("cherrytree:wood", {
|
||||
description = S("Cherrytree Wood"),
|
||||
tiles = {"cherrytree_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(),
|
||||
})
|
||||
|
||||
-- cherrytree tree leaves
|
||||
minetest.register_node("cherrytree:blossom_leaves", {
|
||||
description = S("Cherrytree Blossom Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"cherrytree_blossom_leaves.png"},
|
||||
inventory_image = "cherrytree_blossom_leaves.png",
|
||||
wield_image = "cherrytree_blossom_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"cherrytree:sapling"}, rarity = 20},
|
||||
{items = {"cherrytree:blossom_leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
-- cherrytree tree leaves
|
||||
minetest.register_node("cherrytree:leaves", {
|
||||
description = S("Cherrytree Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"cherrytree_leaves.png"},
|
||||
inventory_image = "cherrytree_leaves.png",
|
||||
wield_image = "cherrytree_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"cherrytree:sapling"}, rarity = 20},
|
||||
{items = {"cherrytree:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "cherrytree:wood 4",
|
||||
recipe = {{"cherrytree:trunk"}}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "cherrytree:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "cherrytree:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "cherrytree:convert_cherrytree_saplings_to_node_timer",
|
||||
nodenames = {"cherrytree:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"cherrytree:trunk"},
|
||||
leaves = {"cherrytree:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"cherrytree_trunk",
|
||||
"cherrytree:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"cherrytree_wood.png"},
|
||||
S("Cherry Tree Stair"),
|
||||
S("Cherry Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
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
|
||||
bonemeal:add_sapling({
|
||||
{"cherrytree:sapling", grow_new_cherrytree_tree, "soil"},
|
||||
})
|
||||
end
|
12
cool_trees/cherrytree/locale/cherrytree.es.tr
Normal file
@ -0,0 +1,12 @@
|
||||
# textdomain: cherrytree
|
||||
Cherries=Cerezas
|
||||
Cherrytree Trunk=Madera de cerezo
|
||||
Cherrytree Wood=Tablas de cerezo
|
||||
Cherrytree Leaves=Hojas de cerezo
|
||||
Cherrytree Blossom Leaves=Flores de cerezo
|
||||
Cherrytree Tree Sapling=Retoño de cerezo
|
||||
Cherry Tree Stair=Escaleras de cerezo
|
||||
Cherry Tree Slab=Losa de cerezo
|
||||
Inner Cherrytree Stair=Escaleras de cerezo interior
|
||||
Outer Cherrytree Stair=Escaleras de cerezo exterior
|
||||
Cherrytree Slab=Losa de cerezo
|
4
cool_trees/cherrytree/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = cherrytree
|
||||
description = Cherry Tree for Decidious Forest
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
224
cool_trees/cherrytree/schematics/cherrytree.lua
Normal file
@ -0,0 +1,224 @@
|
||||
schematic = {
|
||||
size = {x=6, y=7, z=5},
|
||||
yslice_prob = {
|
||||
{ypos=0, prob=254},
|
||||
{ypos=1, prob=254},
|
||||
{ypos=2, prob=254},
|
||||
{ypos=3, prob=254},
|
||||
{ypos=4, prob=254},
|
||||
{ypos=5, prob=254},
|
||||
{ypos=6, prob=254},
|
||||
},
|
||||
data = {
|
||||
{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="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="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="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=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="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="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="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="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="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="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="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="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="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="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="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="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:trunk", prob=254, param2=2},
|
||||
{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:trunk", prob=254, param2=2},
|
||||
{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:trunk", prob=254, param2=2},
|
||||
{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: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="air", prob=0, param2=0},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:blossom_leaves", prob=254, param2=1},
|
||||
{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:trunk", prob=254, param2=3},
|
||||
{name="cherrytree:blossom_leaves", prob=126, param2=1},
|
||||
{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="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="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="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="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=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="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="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="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="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="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="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="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="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="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="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="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="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="air", prob=0, param2=0},
|
||||
},
|
||||
}
|
BIN
cool_trees/cherrytree/schematics/cherrytree.mts
Normal file
BIN
cool_trees/cherrytree/textures/cherrytree_blossom_leaves.png
Normal file
After Width: | Height: | Size: 2.9 KiB |
BIN
cool_trees/cherrytree/textures/cherrytree_cherries.png
Normal file
After Width: | Height: | Size: 865 B |
BIN
cool_trees/cherrytree/textures/cherrytree_leaves.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
cool_trees/cherrytree/textures/cherrytree_sapling.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
cool_trees/cherrytree/textures/cherrytree_trunk.png
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
cool_trees/cherrytree/textures/cherrytree_trunk_top.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
cool_trees/cherrytree/textures/cherrytree_wood.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
236
cool_trees/chestnuttree/init.lua
Normal file
@ -0,0 +1,236 @@
|
||||
--
|
||||
-- Chestnuttree
|
||||
--
|
||||
|
||||
local modname = "chestnuttree"
|
||||
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())
|
||||
|
||||
--Chesnut Bur
|
||||
|
||||
minetest.register_node("chestnuttree:bur", {
|
||||
description = S("Chestnut Bur"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"chestnuttree_bur.png"},
|
||||
inventory_image = "chestnuttree_bur.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 = "chestnuttree:bur", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
--Chesnut Fruit
|
||||
|
||||
minetest.register_craftitem("chestnuttree:fruit", {
|
||||
description = S("Chestnut"),
|
||||
inventory_image = "chestnuttree_fruit.png",
|
||||
on_use = minetest.item_eat(2),
|
||||
groups = {flammable = 2, food = 2},
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "chestnuttree:fruit",
|
||||
recipe = {
|
||||
{'chestnuttree:bur'}
|
||||
}
|
||||
})
|
||||
|
||||
-- chestnuttree
|
||||
|
||||
local function grow_new_chestnuttree_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.place_schematic({x = pos.x-6, y = pos.y, z = pos.z-6}, modpath.."/schematics/chestnuttree.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.00005,
|
||||
scale = 0.00004,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"grassland"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = modpath.."/schematics/chestnuttree.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
place_offset_y = 1,
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("chestnuttree:sapling", {
|
||||
description = S("Chestnut Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"chestnuttree_sapling.png"},
|
||||
inventory_image = "chestnuttree_sapling.png",
|
||||
wield_image = "chestnuttree_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_chestnuttree_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,
|
||||
"chestnuttree: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("chestnuttree:trunk", {
|
||||
description = S("Chestnut Tree Trunk"),
|
||||
tiles = {
|
||||
"chestnuttree_trunk_top.png",
|
||||
"chestnuttree_trunk_top.png",
|
||||
"chestnuttree_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,
|
||||
})
|
||||
|
||||
-- chestnuttree wood
|
||||
minetest.register_node("chestnuttree:wood", {
|
||||
description = S("Chestnut Tree Wood"),
|
||||
tiles = {"chestnuttree_wood.png"},
|
||||
is_ground_content = false,
|
||||
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
-- chestnuttree tree leaves
|
||||
minetest.register_node("chestnuttree:leaves", {
|
||||
description = S("Chestnut Tree Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"chestnuttree_leaves.png"},
|
||||
inventory_image = "chestnuttree_leaves.png",
|
||||
wield_image = "chestnuttree_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"chestnuttree:sapling"}, rarity = 20},
|
||||
{items = {"chestnuttree:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "chestnuttree:wood 4",
|
||||
recipe = {{"chestnuttree:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "chestnuttree:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "chestnuttree:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "chestnuttree:convert_chestnuttree_saplings_to_node_timer",
|
||||
nodenames = {"chestnuttree:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"chestnuttree:trunk"},
|
||||
leaves = {"chestnuttree:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"chestnuttree_trunk",
|
||||
"chestnuttree:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"chestnuttree_wood.png"},
|
||||
S("Chestnut Tree Stair"),
|
||||
S("Chestnut Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"chestnuttree:sapling", grow_new_chestnuttree_tree, "soil"},
|
||||
})
|
||||
end
|
11
cool_trees/chestnuttree/locale/chestnuttree.es.tr
Normal file
@ -0,0 +1,11 @@
|
||||
# textdomain: chestnuttree
|
||||
Chestnut=Castaña
|
||||
Chestnut Bur=Zurrón de castaña
|
||||
Chestnut Tree Inner Stair=Escalera interior de castaño
|
||||
Chestnut Tree Leaves=Hojas de castaño
|
||||
Chestnut Tree Outer Stair=Escalera exterior de castaño
|
||||
Chestnut Tree Slab=Losa de castaño
|
||||
Chestnut Tree Stair=Escalera de castaño
|
||||
Chestnut Tree Sapling=Retoño de castaño
|
||||
Chestnut Tree Trunk=Madera de castaño
|
||||
Chestnut Tree Wood=Tablas de castaño
|
4
cool_trees/chestnuttree/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = chestnuttree
|
||||
description = Chesnut Tree for Grassland
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
2386
cool_trees/chestnuttree/schematics/chestnuttree.lua
Normal file
BIN
cool_trees/chestnuttree/schematics/chestnuttree.mts
Normal file
BIN
cool_trees/chestnuttree/textures/chestnuttree_bur.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_fruit.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_leaves.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_sapling.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_trunk.png
Normal file
After Width: | Height: | Size: 2.8 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_trunk_top.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
cool_trees/chestnuttree/textures/chestnuttree_wood.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
cool_trees/chestnuttree/textures/ts_chestnuttree_front.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
cool_trees/chestnuttree/textures/ts_chestnuttree_front_right.png
Normal file
After Width: | Height: | Size: 2.4 KiB |
217
cool_trees/clementinetree/init.lua
Normal file
@ -0,0 +1,217 @@
|
||||
--
|
||||
-- Clementinetree
|
||||
--
|
||||
|
||||
local modname = "clementinetree"
|
||||
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())
|
||||
|
||||
minetest.register_node("clementinetree:clementine", {
|
||||
description = S("Clementine"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"clementinetree_clementine.png"},
|
||||
inventory_image = "clementinetree_clementine.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 = "clementinetree:clementine", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
-- clementinetree
|
||||
|
||||
local function grow_new_clementinetree_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.place_schematic({x = pos.x-2, y = pos.y, z = pos.z-2}, modpath.."/schematics/clementinetree.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0005,
|
||||
scale = 0.00004,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"deciduous_forest"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = modpath.."/schematics/clementinetree.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("clementinetree:sapling", {
|
||||
description = S("Clementine Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"clementinetree_sapling.png"},
|
||||
inventory_image = "clementinetree_sapling.png",
|
||||
wield_image = "clementinetree_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_clementinetree_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,
|
||||
"clementinetree: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("clementinetree:trunk", {
|
||||
description = S("Clementine Tree Trunk"),
|
||||
tiles = {
|
||||
"clementinetree_trunk_top.png",
|
||||
"clementinetree_trunk_top.png",
|
||||
"clementinetree_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,
|
||||
})
|
||||
|
||||
-- clementinetree wood
|
||||
minetest.register_node("clementinetree:wood", {
|
||||
description = S("Clementine Tree Wood"),
|
||||
tiles = {"clementinetree_wood.png"},
|
||||
is_ground_content = false,
|
||||
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
-- clementinetree tree leaves
|
||||
minetest.register_node("clementinetree:leaves", {
|
||||
description = S("Clementine Tree Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"clementinetree_leaves.png"},
|
||||
inventory_image = "clementinetree_leaves.png",
|
||||
wield_image = "clementinetree_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"clementinetree:sapling"}, rarity = 20},
|
||||
{items = {"clementinetree:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "clementinetree:wood 4",
|
||||
recipe = {{"clementinetree:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "clementinetree:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "clementinetree:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "clementinetree:convert_clementinetree_saplings_to_node_timer",
|
||||
nodenames = {"clementinetree:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"clementinetree:trunk"},
|
||||
leaves = {"clementinetree:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"clementinetree_trunk",
|
||||
"clementinetree:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"clementinetree_wood.png"},
|
||||
S("Clementine Tree Stair"),
|
||||
S("Clementine Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"clementinetree:sapling", grow_new_clementinetree_tree, "soil"},
|
||||
})
|
||||
end
|
10
cool_trees/clementinetree/locale/clementinetree.es.tr
Normal file
@ -0,0 +1,10 @@
|
||||
# textdomain: clementinetree
|
||||
Clementine=Clementina
|
||||
Clementine Tree Inner Stair=Escalera interior de clementinero
|
||||
Clementine Tree Leaves=Hojas de clementinero
|
||||
Clementine Tree Outer Stair=Escalera exterior de clementinero
|
||||
Clementine Tree Slab=Losa de clementinero
|
||||
Clementine Tree Stair=Escalera de clementinero
|
||||
Clementine Tree Sapling=Retoño de clementinero
|
||||
Clementine Tree Trunk=Madera de clementinero
|
||||
Clementine Tree Wood=Tablas de clementinero
|
4
cool_trees/clementinetree/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = clementinetree
|
||||
description = Clementine Tree for Decidious Forest
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
163
cool_trees/clementinetree/schematics/clementinetree.lua
Normal file
@ -0,0 +1,163 @@
|
||||
schematic = {
|
||||
size = {x=5, y=6, z=5},
|
||||
yslice_prob = {
|
||||
{ypos=0, prob=254},
|
||||
{ypos=1, prob=254},
|
||||
{ypos=2, prob=254},
|
||||
{ypos=3, prob=254},
|
||||
{ypos=4, prob=254},
|
||||
{ypos=5, prob=254},
|
||||
},
|
||||
data = {
|
||||
{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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:trunk", prob=254, param2=2},
|
||||
{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="clementinetree:trunk", prob=254, param2=21},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:clementine", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{name="clementinetree:trunk", prob=254, param2=20},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:trunk", prob=254, param2=20},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:clementine", prob=126, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="clementinetree:leaves", prob=126, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{name="clementinetree:leaves", prob=254, param2=1},
|
||||
{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="air", prob=0, param2=0},
|
||||
},
|
||||
}
|
BIN
cool_trees/clementinetree/schematics/clementinetree.mts
Normal file
BIN
cool_trees/clementinetree/textures/clementinetree_clementine.png
Normal file
After Width: | Height: | Size: 886 B |
BIN
cool_trees/clementinetree/textures/clementinetree_leaves.png
Normal file
After Width: | Height: | Size: 2.4 KiB |
BIN
cool_trees/clementinetree/textures/clementinetree_sapling.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
cool_trees/clementinetree/textures/clementinetree_trunk.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
cool_trees/clementinetree/textures/clementinetree_trunk_top.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
cool_trees/clementinetree/textures/clementinetree_wood.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
cool_trees/clementinetree/textures/ts_clementinetree_front.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 2.0 KiB |
262
cool_trees/ebony/init.lua
Normal file
@ -0,0 +1,262 @@
|
||||
--
|
||||
-- Ebony
|
||||
--
|
||||
|
||||
local modname = "ebony"
|
||||
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())
|
||||
|
||||
-- Ebony
|
||||
|
||||
local function grow_new_ebony_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.place_schematic({x = pos.x-5, y = pos.y, z = pos.z-5}, modpath.."/schematics/ebony.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_rainforest_litter"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.005,
|
||||
scale = 0.002,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainforest"},
|
||||
height = 2,
|
||||
y_min = 1,
|
||||
y_max = 62,
|
||||
schematic = modpath.."/schematics/ebony.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("ebony:sapling", {
|
||||
description = S("Ebony Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"ebony_sapling.png"},
|
||||
inventory_image = "ebony_sapling.png",
|
||||
wield_image = "ebony_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_ebony_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,
|
||||
"ebony: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("ebony:trunk", {
|
||||
description = S("Ebony Trunk"),
|
||||
tiles = {
|
||||
"ebony_trunk_top.png",
|
||||
"ebony_trunk_top.png",
|
||||
"ebony_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,
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
--minetest.item_place_node(itemstack, player, pointed_thing, nil)
|
||||
end
|
||||
})
|
||||
|
||||
-- ebony wood
|
||||
minetest.register_node("ebony:wood", {
|
||||
description = S("Ebony Wood"),
|
||||
tiles = {"ebony_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(),
|
||||
})
|
||||
|
||||
-- ebony tree leaves
|
||||
minetest.register_node("ebony:leaves", {
|
||||
description = S("Ebony Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"ebony_leaves.png"},
|
||||
inventory_image = "ebony_leaves.png",
|
||||
wield_image = "ebony_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"ebony:sapling"}, rarity = 20},
|
||||
{items = {"ebony:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Creeper/Vines...
|
||||
--
|
||||
|
||||
minetest.register_node("ebony:creeper", {
|
||||
description = S("Ebony Creeper"),
|
||||
drawtype = "nodebox",
|
||||
walkable = true,
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"ebony_creeper.png"},
|
||||
inventory_image = "ebony_creeper.png",
|
||||
wield_image = "ebony_creeper.png",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -0.5, 0.49, 0.5, 0.5, 0.5}
|
||||
},
|
||||
groups = {
|
||||
snappy = 2, flammable = 3, oddly_breakable_by_hand = 3, choppy = 2, carpet = 1, leafdecay = 3, leaves = 1
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("ebony:creeper_leaves", {
|
||||
description = S("Ebony Creeper with Leaves"),
|
||||
drawtype = "nodebox",
|
||||
walkable = true,
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"ebony_creeper_leaves.png"},
|
||||
inventory_image = "ebony_creeper_leaves.png",
|
||||
wield_image = "ebony_creeper_leaves.png",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -0.5, 0.49, 0.5, 0.5, 0.5}
|
||||
},
|
||||
groups = {
|
||||
snappy = 2, flammable = 3, oddly_breakable_by_hand = 3, choppy = 2, carpet = 1, leafdecay = 3, leaves = 1
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("ebony:liana", {
|
||||
description = S("Ebony Liana"),
|
||||
drawtype = "nodebox",
|
||||
walkable = true,
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"ebony_liana.png"},
|
||||
inventory_image = "ebony_liana.png",
|
||||
wield_image = "ebony_liana.png",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -0.5, 0.0, 0.5, 0.5, 0.0}
|
||||
},
|
||||
groups = {
|
||||
snappy = 2, flammable = 3, oddly_breakable_by_hand = 3, choppy = 2, carpet = 1, leafdecay = 3, leaves = 1,
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "ebony:wood 4",
|
||||
recipe = {{"ebony:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "ebony:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "ebony:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "ebony:convert_ebony_saplings_to_node_timer",
|
||||
nodenames = {"ebony:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"ebony:trunk"},
|
||||
leaves = {"ebony:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"ebony_trunk",
|
||||
"ebony:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"ebony_wood.png"},
|
||||
S("Ebony Stair"),
|
||||
S("Ebony Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"ebony:sapling", grow_new_ebony_tree, "soil"},
|
||||
})
|
||||
end
|
12
cool_trees/ebony/locale/ebony.es.tr
Normal file
@ -0,0 +1,12 @@
|
||||
# textdomain: ebony
|
||||
Ebony Trunk=Madera de ébano
|
||||
Ebony Wood=Tablas de ébano
|
||||
Ebony Leaves=Hojas de ébano
|
||||
Ebony Creeper=Enredadera de ébano
|
||||
Ebony Creeper with Leaves=Enredadera colgante con hojas de ébano
|
||||
Ebony Liana=Liana de ébano
|
||||
Ebony Tree Sapling=Retoño de árbol de ébano
|
||||
Ebony Stair=Escaleras de ébano
|
||||
Inner Ebony Stair=Escaleras de ébano interior
|
||||
Outer Ebony Stair=Escaleras de ébano exterior
|
||||
Ebony Slab=Losa de ébano
|
4
cool_trees/ebony/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = ebony
|
||||
description = Ebony Tree for Rainforest Biome
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
2081
cool_trees/ebony/schematics/ebony.lua
Normal file
BIN
cool_trees/ebony/schematics/ebony.mts
Normal file
BIN
cool_trees/ebony/textures/ebony_creeper.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
cool_trees/ebony/textures/ebony_creeper_leaves.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
cool_trees/ebony/textures/ebony_leaves.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
cool_trees/ebony/textures/ebony_liana.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
cool_trees/ebony/textures/ebony_sapling.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
cool_trees/ebony/textures/ebony_trunk.png
Normal file
After Width: | Height: | Size: 2.9 KiB |
BIN
cool_trees/ebony/textures/ebony_trunk_top.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
cool_trees/ebony/textures/ebony_wood.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
202
cool_trees/jacaranda/init.lua
Normal file
@ -0,0 +1,202 @@
|
||||
--
|
||||
-- Jacaranda
|
||||
--
|
||||
local modname = "jacaranda"
|
||||
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())
|
||||
|
||||
-- Jacaranda
|
||||
|
||||
local function grow_new_jacaranda_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.place_schematic({x = pos.x-3, y = pos.y, z = pos.z-3}, modpath.."/schematics/jacaranda.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_rainforest_litter"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0005,
|
||||
scale = 0.00005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"rainforest"},
|
||||
y_min = 1,
|
||||
y_max = 32,
|
||||
schematic = modpath.."/schematics/jacaranda.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("jacaranda:sapling", {
|
||||
description = S("Jacaranda Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"jacaranda_sapling.png"},
|
||||
inventory_image = "jacaranda_sapling.png",
|
||||
wield_image = "jacaranda_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_jacaranda_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,
|
||||
"jacaranda: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("jacaranda:trunk", {
|
||||
description = S("Jacaranda Trunk"),
|
||||
tiles = {
|
||||
"jacaranda_trunk_top.png",
|
||||
"jacaranda_trunk_top.png",
|
||||
"jacaranda_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,
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
--minetest.item_place_node(itemstack, player, pointed_thing, nil)
|
||||
end
|
||||
})
|
||||
|
||||
-- jacaranda wood
|
||||
minetest.register_node("jacaranda:wood", {
|
||||
description = S("Jacaranda Wood"),
|
||||
tiles = {"jacaranda_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(),
|
||||
})
|
||||
|
||||
-- jacaranda tree leaves
|
||||
minetest.register_node("jacaranda:blossom_leaves", {
|
||||
description = S("Jacaranda Blossom Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"jacaranda_blossom_leaves.png"},
|
||||
inventory_image = "jacaranda_blossom_leaves.png",
|
||||
wield_image = "jacaranda_blossom_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"jacaranda:sapling"}, rarity = 20},
|
||||
{items = {"jacaranda:blossom_leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "jacaranda:wood 4",
|
||||
recipe = {{"jacaranda:trunk"}}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "jacaranda:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "jacaranda:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "jacaranda:convert_jacaranda_saplings_to_node_timer",
|
||||
nodenames = {"jacaranda:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"jacaranda:trunk"},
|
||||
leaves = {"jacaranda:blossom_leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"jacaranda_trunk",
|
||||
"jacaranda:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"jacaranda_wood.png"},
|
||||
S("Jacaranda Tree Stair"),
|
||||
S("Jacaranda Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"jacaranda:sapling", grow_new_jacaranda_tree, "soil"},
|
||||
})
|
||||
end
|
||||
|
||||
|
10
cool_trees/jacaranda/locale/jacaranda.es.tr
Normal file
@ -0,0 +1,10 @@
|
||||
# textdomain: jacaranda
|
||||
Jacaranda Trunk=Madera de jacaranda
|
||||
Jacaranda Wood=Tablas de jacaranda
|
||||
Jacaranda Blossom Leaves=Flores de jacaranda
|
||||
Jacaranda Tree Sapling=Retoño de jacaranda
|
||||
Jacaranda Tree Stair=Escaleras de jacaranda
|
||||
Jacaranda Tree Slab=Losa de jacaranda
|
||||
Inner Jacaranda Tree Stair=Escaleras de jacaranda interior
|
||||
Outer Jacaranda Tree Stair=Escaleras de jacaranda exterior
|
||||
Jacaranda Slab=Losa de jacaranda
|
4
cool_trees/jacaranda/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = jacaranda
|
||||
description = Jacaranda for jungles
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|
407
cool_trees/jacaranda/schematics/jacaranda.lua
Normal file
@ -0,0 +1,407 @@
|
||||
schematic = {
|
||||
size = {x=7, y=8, z=7},
|
||||
yslice_prob = {
|
||||
{ypos=0, prob=254},
|
||||
{ypos=1, prob=254},
|
||||
{ypos=2, prob=254},
|
||||
{ypos=3, prob=254},
|
||||
{ypos=4, prob=254},
|
||||
{ypos=5, prob=254},
|
||||
{ypos=6, prob=254},
|
||||
{ypos=7, prob=254},
|
||||
},
|
||||
data = {
|
||||
{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="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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="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="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="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="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="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="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="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="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="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="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="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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:trunk", prob=254, param2=1},
|
||||
{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="air", prob=0, param2=0},
|
||||
{name="jacaranda:trunk", prob=254, param2=1},
|
||||
{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="air", prob=0, param2=0},
|
||||
{name="jacaranda:trunk", prob=254, param2=2},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:trunk", prob=254, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:trunk", prob=254, param2=3},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:trunk", prob=254, param2=3},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:trunk", prob=254, param2=3},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{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="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="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="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="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="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="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="jacaranda:blossom_leaves", prob=128, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="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="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="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="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="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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="jacaranda:blossom_leaves", prob=254, param2=1},
|
||||
{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="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="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="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="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
{name="air", prob=0, param2=0},
|
||||
},
|
||||
}
|
BIN
cool_trees/jacaranda/schematics/jacaranda.mts
Normal file
BIN
cool_trees/jacaranda/textures/jacaranda_blossom_leaves.png
Normal file
After Width: | Height: | Size: 2.9 KiB |
BIN
cool_trees/jacaranda/textures/jacaranda_sapling.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
cool_trees/jacaranda/textures/jacaranda_trunk.png
Normal file
After Width: | Height: | Size: 3.2 KiB |
BIN
cool_trees/jacaranda/textures/jacaranda_trunk_top.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
cool_trees/jacaranda/textures/jacaranda_wood.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
221
cool_trees/larch/init.lua
Normal file
@ -0,0 +1,221 @@
|
||||
--
|
||||
-- Larch
|
||||
--
|
||||
local modname = "larch"
|
||||
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())
|
||||
|
||||
-- Larch
|
||||
|
||||
local function grow_new_larch_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.place_schematic({x = pos.x-5, y = pos.y, z = pos.z-5}, modpath.."/schematics/larch.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_coniferous_litter"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0005,
|
||||
scale = 0.0005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"coniferous_forest"},
|
||||
y_min = 1,
|
||||
y_max = 32,
|
||||
place_offset_y = 1,
|
||||
schematic = modpath.."/schematics/larch.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("larch:sapling", {
|
||||
description = S("Larch Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"larch_sapling.png"},
|
||||
inventory_image = "larch_sapling.png",
|
||||
wield_image = "larch_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_larch_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,
|
||||
"larch: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("larch:trunk", {
|
||||
description = S("Larch Trunk"),
|
||||
tiles = {
|
||||
"larch_trunk_top.png",
|
||||
"larch_trunk_top.png",
|
||||
"larch_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,
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
minetest.item_place_node(itemstack, player, pointed_thing, nil)
|
||||
end
|
||||
})
|
||||
|
||||
-- larch wood
|
||||
minetest.register_node("larch:wood", {
|
||||
description = S("Larch Wood"),
|
||||
tiles = {"larch_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(),
|
||||
})
|
||||
|
||||
-- larch tree leaves
|
||||
minetest.register_node("larch:leaves", {
|
||||
description = S("Larch Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"larch_leaves.png"},
|
||||
inventory_image = "larch_leaves.png",
|
||||
wield_image = "larch_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"larch:sapling"}, rarity = 20},
|
||||
{items = {"larch:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
minetest.register_node("larch:moss", {
|
||||
description = S("Larch Moss"),
|
||||
drawtype = "nodebox",
|
||||
walkable = true,
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"larch_moss.png"},
|
||||
inventory_image = "larch_moss.png",
|
||||
wield_image = "larch_moss.png",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -0.5, 0.49, 0.5, 0.5, 0.5}
|
||||
},
|
||||
groups = {
|
||||
snappy = 2, flammable = 3, oddly_breakable_by_hand = 3, choppy = 2, carpet = 1, leafdecay = 3, leaves = 1,
|
||||
falling_node = 1
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "larch:wood 4",
|
||||
recipe = {{"larch:trunk"}}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "larch:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "larch:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "larch:convert_larch_saplings_to_node_timer",
|
||||
nodenames = {"larch:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"larch:trunk"},
|
||||
leaves = {"larch:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"larch_trunk",
|
||||
"larch:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"larch_wood.png"},
|
||||
S("Larch Tree Stair"),
|
||||
S("Larch Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"larch:sapling", grow_new_larch_tree, "soil"},
|
||||
})
|
||||
end
|
5
cool_trees/larch/locale/larch.es.tr
Normal file
@ -0,0 +1,5 @@
|
||||
# textdomain: larch
|
||||
Larch Sapling=Retoño de alerce
|
||||
Larch Trunk=Madera de alerce
|
||||
Larch Wood=Tablas de alerce
|
||||
Larch Leaves=Hojas de alerce
|
3
cool_trees/larch/mod.conf
Normal file
@ -0,0 +1,3 @@
|
||||
name = larch
|
||||
description = Larch Tree
|
||||
optional_depends = stairs, bonemeal
|
2203
cool_trees/larch/schematics/larch.lua
Normal file
BIN
cool_trees/larch/schematics/larch.mts
Normal file
BIN
cool_trees/larch/textures/larch_leaves.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
cool_trees/larch/textures/larch_moss.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
cool_trees/larch/textures/larch_sapling.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
cool_trees/larch/textures/larch_trunk.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
BIN
cool_trees/larch/textures/larch_trunk_top.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
cool_trees/larch/textures/larch_wood.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
252
cool_trees/lemontree/init.lua
Normal file
@ -0,0 +1,252 @@
|
||||
--
|
||||
-- Lemontree
|
||||
--
|
||||
|
||||
local modname = "lemontree"
|
||||
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())
|
||||
|
||||
-- Lemon Fruit
|
||||
|
||||
minetest.register_node("lemontree:lemon", {
|
||||
description = S("Lemon"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {"lemontree_lemon.png"},
|
||||
inventory_image = "lemontree_lemon.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 = "lemontree:lemon", param2 = 1})
|
||||
end,
|
||||
})
|
||||
|
||||
-- lemontree
|
||||
|
||||
local function grow_new_lemontree_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.place_schematic({x = pos.x-2, y = pos.y, z = pos.z-2}, modpath.."/schematics/lemontree.mts", "0", nil, false)
|
||||
end
|
||||
|
||||
--
|
||||
-- Decoration
|
||||
--
|
||||
|
||||
if mg_name ~= "v6" and mg_name ~= "singlenode" then
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0.0005,
|
||||
scale = 0.00005,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"deciduous_forest"},
|
||||
y_min = 1,
|
||||
y_max = 80,
|
||||
schematic = modpath.."/schematics/lemontree.mts",
|
||||
flags = "place_center_x, place_center_z, force_placement",
|
||||
rotation = "random",
|
||||
})
|
||||
end
|
||||
|
||||
--
|
||||
-- Nodes
|
||||
--
|
||||
|
||||
minetest.register_node("lemontree:sapling", {
|
||||
description = S("Lemon Tree Sapling"),
|
||||
drawtype = "plantlike",
|
||||
visual_scale = 1.0,
|
||||
tiles = {"lemontree_sapling.png"},
|
||||
inventory_image = "lemontree_sapling.png",
|
||||
wield_image = "lemontree_sapling.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = grow_new_lemontree_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,
|
||||
"lemontree: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("lemontree:trunk", {
|
||||
description = S("Lemon Tree Trunk"),
|
||||
tiles = {
|
||||
"lemontree_trunk_top.png",
|
||||
"lemontree_trunk_top.png",
|
||||
"lemontree_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,
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
if minetest.get_modpath("cork") ~= nil then
|
||||
cork.get_cork(pos, node, player, itemstack, pointed_thing)
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
-- lemontree wood
|
||||
minetest.register_node("lemontree:wood", {
|
||||
description = S("Lemon Tree Wood"),
|
||||
tiles = {"lemontree_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(),
|
||||
})
|
||||
|
||||
-- lemontree tree leaves
|
||||
minetest.register_node("lemontree:leaves", {
|
||||
description = S("Lemon Tree Leaves"),
|
||||
drawtype = "allfaces_optional",
|
||||
visual_scale = 1.2,
|
||||
tiles = {"lemontree_leaves.png"},
|
||||
inventory_image = "lemontree_leaves.png",
|
||||
wield_image = "lemontree_leaves.png",
|
||||
paramtype = "light",
|
||||
walkable = true,
|
||||
waving = 1,
|
||||
groups = {snappy = 3, leafdecay = 3, leaves = 1, flammable = 2},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"lemontree:sapling"}, rarity = 20},
|
||||
{items = {"lemontree:leaves"}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
--
|
||||
-- Craftitems
|
||||
--
|
||||
|
||||
--
|
||||
-- Recipes
|
||||
--
|
||||
|
||||
minetest.register_craft({
|
||||
output = "lemontree:wood 4",
|
||||
recipe = {{"lemontree:trunk"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "lemontree:trunk",
|
||||
burntime = 30,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "lemontree:wood",
|
||||
burntime = 7,
|
||||
})
|
||||
|
||||
minetest.register_lbm({
|
||||
name = "lemontree:convert_lemontree_saplings_to_node_timer",
|
||||
nodenames = {"lemontree:sapling"},
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1200, 2400))
|
||||
end
|
||||
})
|
||||
|
||||
default.register_leafdecay({
|
||||
trunks = {"lemontree:trunk"},
|
||||
leaves = {"lemontree:leaves"},
|
||||
radius = 3,
|
||||
})
|
||||
|
||||
--Stairs
|
||||
|
||||
if minetest.get_modpath("stairs") ~= nil then
|
||||
stairs.register_stair_and_slab(
|
||||
"lemontree_trunk",
|
||||
"lemontree:trunk",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"lemontree_wood.png"},
|
||||
S("Lemon Tree Stair"),
|
||||
S("Lemon Tree Slab"),
|
||||
default.node_sound_wood_defaults()
|
||||
)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{"lemontree:sapling", grow_new_lemontree_tree, "soil"},
|
||||
})
|
||||
end
|
||||
|
||||
if minetest.get_modpath("cork") ~= nil then
|
||||
minetest.register_node("lemontree:trunk_nobark", {
|
||||
description = S("Lemon Tree Trunk"),
|
||||
tiles = {
|
||||
"lemontree_trunk_top.png",
|
||||
"lemontree_trunk_top.png",
|
||||
"lemontree_trunk_nobark.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,
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "lemontree:wood 4",
|
||||
recipe = {{"lemontree:trunk_nobark"}}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "lemontree:trunk_nobark",
|
||||
burntime = 25,
|
||||
})
|
||||
end
|
10
cool_trees/lemontree/locale/lemontree.es.tr
Normal file
@ -0,0 +1,10 @@
|
||||
# textdomain: lemontree
|
||||
Lemon Tree Inner Stair=Escalera interior de limonero
|
||||
Lemon Tree Leaves=Hojas de limonero
|
||||
Lemon Tree Outer Stair=Escalera exterior de limonero
|
||||
Lemon Tree Sapling=Retoño de limonero
|
||||
Lemon Tree Slab=Losa de limonero
|
||||
Lemon Tree Stair=Escalera de limonero
|
||||
Lemon Tree Trunk=Madera de limonero
|
||||
Lemon Tree Wood=Tablas de limonero
|
||||
Lemon=Limón
|
4
cool_trees/lemontree/mod.conf
Normal file
@ -0,0 +1,4 @@
|
||||
name = lemontree
|
||||
description = Lemon Tree for Decidious Forest
|
||||
depends = default
|
||||
optional_depends = stairs, bonemeal
|