write something there

This commit is contained in:
N-Nachtigal 2025-05-04 16:01:41 +02:00
commit b4b6c08f4f
8546 changed files with 309825 additions and 0 deletions

View file

@ -0,0 +1,2 @@
# badland
Adds a Badlands biome with a few more objects.

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

View file

@ -0,0 +1,15 @@
------------Crafting
minetest.register_craft({
output = "badland:badland_wood 4",
recipe = {
{"badland:badland_tree"},
}
})
minetest.register_craft({
output = "badland:badland_trapdoor 2",
recipe = {
{"badland:badland_wood", "badland:badland_wood", "badland:badland_wood"},
{"badland:badland_wood", "badland:badland_wood", "badland:badland_wood"},
}
})

View file

@ -0,0 +1,103 @@
badland = {}
local mpath = minetest.get_modpath("badland")
local pot = minetest.get_modpath("flowerpot")
minetest.register_node("badland:toadstool", {
description = "Toadstool",
drawtype = "plantlike",
waving = 1,
on_use = minetest.item_eat(1),
visual_scale = 1,
tiles = {"toadstool.png"},
inventory_image = "toadstool.png",
wield_image = "toadstool.png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, prairie = 1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = box or {-0.15, -0.5, -0.15, 0.15, 0.15, 0.15},
},
})
minetest.register_node("badland:brown_mushroom_2", {
description = "Brown Mushroom",
drawtype = "plantlike",
waving = 1,
on_use = minetest.item_eat(1),
visual_scale = 1,
tiles = {"brown_mushroom_2.png"},
inventory_image = "brown_mushroom_2.png",
wield_image = "brown_mushroom_2.png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, prairie = 1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = box or {-0.15, -0.5, -0.15, 0.15, 0.15, 0.15},
},
})
minetest.register_node("badland:brown_mushroom_3", {
description = "Brown Mushroom",
drawtype = "plantlike",
waving = 1,
on_use = minetest.item_eat(1),
visual_scale = 1,
tiles = {"brown_mushroom_3.png"},
inventory_image = "brown_mushroom_3.png",
wield_image = "brown_mushroom_3.png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, prairie = 1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = box or {-0.15, -0.5, -0.15, 0.15, 0.15, 0.15},
},
})
minetest.register_node("badland:brown_mushroom_4", {
description = "Brown Mushroom",
drawtype = "plantlike",
waving = 1,
on_use = minetest.item_eat(1),
visual_scale = 1,
tiles = {"brown_mushroom_4.png"},
inventory_image = "brown_mushroom_4.png",
wield_image = "brown_mushroom_4.png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, flower = 1, flora = 1, attached_node = 1, flammable = 1, prairie = 1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = box or {-0.15, -0.5, -0.15, 0.15, 0.15, 0.15},
},
})
minetest.register_decoration({
deco_type = "simple",
place_on = {"badland:badland_grass"},
sidelen = 16,
fill_ratio = 0.01,
biomes = {"badland"},
decoration = {
"badland:toadstool", "badland:brown_mushroom_4", "badland:brown_mushroom_3", "badland:brown_mushroom_2",
}
})

View file

@ -0,0 +1,7 @@
local default_path = minetest.get_modpath("badland")
dofile(default_path.."/mapgen.lua")
dofile(default_path.."/nodes.lua")
--dofile(default_path.."/flowers.lua") -- replaced with brown mushrooms in asuna_core/decor.lua
dofile(default_path.."/crafting.lua")
dofile(default_path.."/moreblocks.lua")

View file

@ -0,0 +1,18 @@
License
------------------------------------------------------------------------------------------------------------------------
Copyright (C) 2021-2022: Atlante - AFL-1.1
License for code: AFL-1.1
Attribution — You must give appropriate credit, provide a link to the license, and
indicate if changes were made. You may do so in any reasonable manner, but not in any way
that suggests the licensor endorses you or your use.
ShareAlike — If you remix, transform, or build upon the material, you must distribute
your contributions under the same license as the original.
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Anyone can fix the mod. My Discord "Atlante#1952" And my Mail Address "AtlanteEtDocteur@gmail.com"

View file

@ -0,0 +1,180 @@
-----------------------Trees
minetest.register_decoration({
name = "badland:badland_tree_1",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
noise_params = {
offset = 0.00125,
scale = 0.0075,
spread = {x = 80, y = 20, z = 80},
seed = 777,
octaves = 1,
},
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_tree_1.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
minetest.register_decoration({
name = "badland:badland_tree_2",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.00025,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_tree_2.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
minetest.register_decoration({
name = "badland:badland_tree_3",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
noise_params = {
offset = 0.001,
scale = 0.0025,
spread = {x = 40, y = 40, z = 40},
seed = 999,
octaves = 1,
},
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_tree_3.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
minetest.register_decoration({
name = "badland:badland_tree_4",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
noise_params = {
offset = -0.005,
scale = 0.01,
spread = {x = 80, y = 20, z = 80},
seed = 101010,
octaves = 2,
persistence = 0.5,
lacunarity = 0.9,
},
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_tree_4.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
---------------------------------------Bush
minetest.register_decoration({
name = "badland:badland_brush",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.008265,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_bush.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
----------------------------------Log 1
minetest.register_decoration({
name = "badland:badland_log_1",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.008265,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_log_1.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
----------------------------------Log 2
minetest.register_decoration({
name = "badland:badland_log_2",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.008265,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/badland_log_2.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
---------------------Racine
minetest.register_decoration({
name = "badland:racine_1",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.000665,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/racine_1.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
---------------------------Puit
minetest.register_decoration({
name = "badland:puit_1",
deco_type = "schematic",
place_on = {"badland:badland_grass"},
place_offset_y = 0,
sidelen = 16,
fill_ratio = 0.000165,
biomes = {"badland"},
y_max = 31000,
y_min = -20,
schematic = minetest.get_modpath("badland").."/schematics/puit_1.mts",
flags = "place_center_x, place_center_z",
rotation = "random",
})
---------------------------Grass
minetest.register_decoration({
deco_type = "simple",
place_on = {"badland:badland_grass"},
sidelen = 16,
fill_ratio = 0.35,
biomes = {"badland"},
decoration = {
"badland:badland_grass_1", "badland:badland_grass_2", "badland:badland_grass_3", "badland:badland_grass_4", "badland:badland_grass_5",
}
})
---------------------------Pumpkins
minetest.register_decoration({
deco_type = "simple",
place_on = {"badland:badland_grass"},
sidelen = 16,
fill_ratio = 0.0025,
param2 = 0,
param2_max = 3,
biomes = {"badland"},
decoration = {
"badland:pumpkin_block",
}
})

View file

@ -0,0 +1,8 @@
author = Atlante
name = badland
description = Adds a Badlands biome with a few more objects.
title = Badlands
depends = default, doors, japaneseforest, flowerpot, x_farming
optional_depends = flowers, moreblocks

View file

@ -0,0 +1,278 @@
# Blender v2.78 (sub 0) OBJ File: ''
# www.blender.org
mtllib scarecrow.mtl
o Cube_Cube.001
v -0.561998 1.323839 0.300580
v -0.561998 2.981953 0.300579
v -0.561998 2.981953 -0.300582
v -0.561998 1.323839 -0.300581
v 0.563007 2.981953 -0.300580
v 0.563007 1.323839 -0.300580
v 0.563007 2.981953 0.300581
v 0.563007 1.323839 0.300581
v -0.561998 2.981304 0.562503
v -0.561998 4.106310 0.562503
v -0.561998 4.106310 -0.562503
v -0.561998 2.981304 -0.562504
v 0.563007 4.106310 -0.562503
v 0.563007 2.981304 -0.562503
v 0.563007 4.106310 0.562503
v 0.563007 2.981304 0.562503
v 0.139760 -0.287793 0.292342
v -0.000793 1.318738 0.292342
v -0.000793 1.318738 -0.292342
v 0.139761 -0.287793 -0.292342
v 0.546074 1.366583 -0.292342
v 0.686627 -0.239948 -0.292342
v 0.546074 1.366583 0.292342
v 0.686627 -0.239948 0.292342
v -0.139991 -0.287924 -0.292342
v -0.139991 -0.287924 0.292342
v -0.686857 -0.240079 0.292342
v -0.686857 -0.240079 -0.292342
v -0.546304 1.366452 -0.292342
v 0.000563 1.318607 -0.292342
v 0.000563 1.318607 0.292342
v -0.546304 1.366452 0.292342
v -0.128807 -1.218078 0.129312
v -0.128807 1.378430 0.129312
v -0.128807 1.378430 -0.129312
v -0.128807 -1.218078 -0.129312
v 0.129816 1.378430 -0.129312
v 0.129816 -1.218078 -0.129312
v 0.129816 1.378430 0.129312
v 0.129816 -1.218078 0.129312
v -2.627234 2.609297 0.129310
v 2.628242 2.609298 0.129312
v 2.628242 2.867920 0.129312
v -2.627234 2.867920 0.129310
v 2.628242 2.867921 -0.129311
v -2.627234 2.867921 -0.129313
v 2.628242 2.609297 -0.129311
v -2.627234 2.609297 -0.129313
v -2.219586 2.414515 0.300579
v -2.219586 2.414515 -0.300582
v -0.561471 2.414515 -0.300581
v -0.561471 2.414515 0.300580
v -2.219586 2.978941 -0.300582
v -0.561471 2.978941 -0.300582
v -2.219586 2.978941 0.300579
v -0.561471 2.978941 0.300579
v 2.219980 2.414515 0.300581
v 0.561866 2.414515 0.300581
v 0.561866 2.414515 -0.300580
v 2.219980 2.414515 -0.300580
v 0.561866 2.978941 -0.300580
v 2.219980 2.978941 -0.300580
v 0.561865 2.978941 0.300581
v 2.219980 2.978941 0.300581
v -1.668880 2.412450 0.302779
v -1.668880 2.412450 -0.302782
v -1.668880 2.981006 -0.302782
v -1.668880 2.981006 0.302779
v 1.669274 2.412450 0.302781
v 1.669274 2.412450 -0.302780
v 1.669274 2.981006 -0.302779
v 1.669274 2.981006 0.302782
vt 0.5000 0.5000
vt 0.5000 0.6875
vt 0.4375 0.6875
vt 0.4375 0.5000
vt 0.3125 0.6875
vt 0.3125 0.5000
vt 0.2500 0.6875
vt 0.2500 0.5000
vt 0.6250 0.5000
vt 0.6250 0.6875
vt 0.4375 0.6875
vt 0.5625 0.6875
vt 0.5625 0.7500
vt 0.4375 0.7500
vt 0.4375 0.7500
vt 0.3125 0.7500
vt 0.3750 0.7500
vt 0.3750 0.8750
vt 0.2500 0.8750
vt 0.2500 0.7500
vt 0.1250 0.8750
vt 0.1250 0.7500
vt -0.0000 0.8750
vt -0.0000 0.7500
vt 0.5000 0.7500
vt 0.5000 0.8750
vt 0.2500 0.8750
vt 0.3750 0.8750
vt 0.3750 1.0000
vt 0.2500 1.0000
vt 0.2500 1.0000
vt 0.1250 1.0000
vt 0.1875 0.5000
vt 0.1875 0.6875
vt 0.1250 0.6875
vt 0.1250 0.5000
vt 0.0625 0.6875
vt 0.0625 0.5000
vt -0.0000 0.6875
vt -0.0000 0.5000
vt 0.2500 0.5000
vt 0.2500 0.6875
vt 0.1250 0.6875
vt 0.1875 0.6875
vt 0.1875 0.7500
vt 0.1250 0.7500
vt 0.1250 0.7500
vt 0.0625 0.7500
vt 0.1250 0.6875
vt 0.1250 0.7500
vt 0.1875 0.7500
vt 0.1875 0.6875
vt 0.1250 0.5000
vt 0.0625 0.5000
vt 0.0625 0.6875
vt 0.1250 0.6875
vt 0.1875 0.5000
vt 0.1875 0.6875
vt 0.2500 0.5000
vt 0.2500 0.6875
vt 0.0625 0.7500
vt 0.1250 0.7500
vt -0.0000 0.5000
vt -0.0000 0.6875
vt 0.0938 0.1406
vt 0.0938 0.4688
vt 0.0625 0.4688
vt 0.0625 0.1406
vt 0.0312 0.4688
vt 0.0312 0.1406
vt 0.0000 0.4688
vt -0.0000 0.1406
vt 0.1250 0.1406
vt 0.1250 0.4688
vt 0.0625 0.4688
vt 0.0938 0.4688
vt 0.0938 0.5000
vt 0.0625 0.5000
vt 0.0625 0.5000
vt 0.0312 0.5000
vt 0.9688 0.0000
vt 0.9688 0.5938
vt 0.9375 0.5938
vt 0.9375 0.0000
vt 0.9062 0.5938
vt 0.9062 0.0000
vt 0.8750 0.5938
vt 0.8750 0.0000
vt 1.0000 0.0000
vt 1.0000 0.5938
vt 0.9375 0.5938
vt 0.9688 0.5938
vt 0.9688 0.6250
vt 0.9375 0.6250
vt 0.9375 0.6250
vt 0.9062 0.6250
vt 0.8125 0.5000
vt 0.7500 0.5000
vt 0.7500 0.6875
vt 0.8125 0.6875
vt 0.6875 0.5000
vt 0.6875 0.6875
vt 0.6250 0.5000
vt 0.6250 0.6875
vt 0.8750 0.5000
vt 0.8750 0.6875
vt 0.7500 0.6875
vt 0.7500 0.7500
vt 0.8125 0.7500
vt 0.8125 0.6875
vt 0.6875 0.7500
vt 0.7500 0.7500
vt 0.8125 0.5000
vt 0.8125 0.6875
vt 0.7500 0.6875
vt 0.7500 0.5000
vt 0.6875 0.6875
vt 0.6875 0.5000
vt 0.6250 0.6875
vt 0.6250 0.5000
vt 0.8750 0.5000
vt 0.8750 0.6875
vt 0.7500 0.6875
vt 0.8125 0.6875
vt 0.8125 0.7500
vt 0.7500 0.7500
vt 0.7500 0.7500
vt 0.6875 0.7500
vt 0.7500 0.6875
vt 0.7500 0.7500
vt 0.8125 0.7500
vt 0.8125 0.6875
vt 0.7500 0.6875
vt 0.8125 0.6875
vt 0.8125 0.7500
vt 0.7500 0.7500
vn -1.0000 0.0000 0.0000
vn 0.0000 -0.0000 -1.0000
vn 1.0000 0.0000 0.0000
vn -0.0000 0.0000 1.0000
vn 0.0000 -1.0000 0.0000
vn 0.0000 1.0000 0.0000
vn -0.9962 -0.0872 -0.0000
vn 0.9962 0.0872 0.0000
vn 0.0872 -0.9962 -0.0000
vn -0.0872 0.9962 0.0000
vn -0.0872 -0.9962 -0.0000
vn 0.9962 -0.0872 -0.0000
vn 0.0872 0.9962 0.0000
vn -0.9962 0.0872 0.0000
usemtl None
s 1
f 1/1/1 2/2/1 3/3/1 4/4/1
f 4/4/2 3/3/2 5/5/2 6/6/2
f 6/6/3 5/5/3 7/7/3 8/8/3
f 8/9/4 7/10/4 2/2/4 1/1/4
f 4/11/5 6/12/5 8/13/5 1/14/5
f 5/5/6 3/3/6 2/15/6 7/16/6
f 9/17/1 10/18/1 11/19/1 12/20/1
f 12/20/2 11/19/2 13/21/2 14/22/2
f 14/22/3 13/21/3 15/23/3 16/24/3
f 16/25/4 15/26/4 10/18/4 9/17/4
f 12/27/5 14/28/5 16/29/5 9/30/5
f 13/21/6 11/19/6 10/31/6 15/32/6
f 17/33/7 18/34/7 19/35/7 20/36/7
f 20/36/2 19/35/2 21/37/2 22/38/2
f 22/38/8 21/37/8 23/39/8 24/40/8
f 24/41/4 23/42/4 18/34/4 17/33/4
f 20/43/9 22/44/9 24/45/9 17/46/9
f 21/37/10 19/35/10 18/47/10 23/48/10
f 25/49/11 26/50/11 27/51/11 28/52/11
f 25/53/2 28/54/2 29/55/2 30/56/2
f 26/57/12 25/53/12 30/56/12 31/58/12
f 27/59/4 26/57/4 31/58/4 32/60/4
f 29/55/13 32/61/13 31/62/13 30/56/13
f 28/54/14 27/63/14 32/64/14 29/55/14
f 33/65/1 34/66/1 35/67/1 36/68/1
f 36/68/2 35/67/2 37/69/2 38/70/2
f 38/70/3 37/69/3 39/71/3 40/72/3
f 40/73/4 39/74/4 34/66/4 33/65/4
f 36/75/5 38/76/5 40/77/5 33/78/5
f 37/69/6 35/67/6 34/79/6 39/80/6
f 41/81/4 42/82/4 43/83/4 44/84/4
f 44/84/6 43/83/6 45/85/6 46/86/6
f 46/86/2 45/85/2 47/87/2 48/88/2
f 48/89/5 47/90/5 42/82/5 41/81/5
f 44/91/1 46/92/1 48/93/1 41/94/1
f 45/85/3 43/83/3 42/95/3 47/96/3
f 49/97/5 50/98/5 51/99/5 52/100/5
f 50/98/2 53/101/2 54/102/2 51/99/2
f 53/101/6 55/103/6 56/104/6 54/102/6
f 55/105/4 49/97/4 52/100/4 56/106/4
f 50/107/1 49/108/1 55/109/1 53/110/1
f 54/102/3 56/111/3 52/112/3 51/99/3
f 57/113/5 58/114/5 59/115/5 60/116/5
f 60/116/2 59/115/2 61/117/2 62/118/2
f 62/118/6 61/117/6 63/119/6 64/120/6
f 64/121/4 63/122/4 58/114/4 57/113/4
f 60/123/3 62/124/3 64/125/3 57/126/3
f 61/117/1 59/115/1 58/127/1 63/128/1
f 66/129/1 65/130/1 68/131/1 67/132/1
f 70/133/3 71/134/3 72/135/3 69/136/3

View file

@ -0,0 +1,21 @@
-----------------Moreblock
if minetest.get_modpath("moreblocks") then
stairsplus:register_all("badland_wood", "wood", "badland:badland_wood", {
description = "Frost Land Wood",
tiles = {"badland_wood.png"},
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3, wood = 1},
sounds = default.node_sound_wood_defaults(),
})
stairsplus:register_all("badland_tree", "tree", "badland:badland_tree", {
description = "Japanese Tree",
tiles = {"badland_tree_top.png", "badland_tree_top.png",
"badland_tree.png"},
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3, wood = 1},
sounds = default.node_sound_wood_defaults(),
})
end

View file

@ -0,0 +1,328 @@
local modpath = minetest.get_modpath("badland")
minetest.register_node("badland:badland_grass", {
description = "Badland Grass",
tiles = {"badland_grass.png", "default_dirt.png",
{name = "default_dirt.png^badland_grass_side.png",
tileable_vertical = false}},
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
drop = "default:dirt",
sounds = default.node_sound_dirt_defaults({
footstep = {name = "default_grass_footstep", gain = 0.25},
}),
})
minetest.register_node("badland:badland_leaves", {
description = "Spooky Badland Leaves",
drawtype = "allfaces_optional",
waving = 1,
tiles = {"badland_leaves.png"},
paramtype = "light",
is_ground_content = false,
groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1},
drop = {
max_items = 1,
items = {
{items = {"badland:badland_sapling_1"}, rarity = 20},
{items = {"badland:badland_leaves"}}
}
},
sounds = default.node_sound_leaves_defaults(),
after_place_node = default.after_place_leaves,
})
minetest.register_node("badland:badland_leaves_2", {
description = "Haunted Badland Leaves",
drawtype = "allfaces_optional",
waving = 1,
tiles = {"badland_leaves_2.png"},
paramtype = "light",
is_ground_content = false,
groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1},
drop = {
max_items = 1,
items = {
{items = {"badland:badland_sapling_2"}, rarity = 20},
{items = {"badland:badland_leaves_2"}}
}
},
sounds = default.node_sound_leaves_defaults(),
after_place_node = default.after_place_leaves,
})
minetest.register_node("badland:badland_leaves_3", {
description = "Dusky Badland Leaves",
drawtype = "allfaces_optional",
waving = 1,
tiles = {"badland_leaves_3.png"},
paramtype = "light",
is_ground_content = false,
groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1},
drop = {
max_items = 1,
items = {
{items = {"badland:badland_sapling_3"}, rarity = 20},
{items = {"badland:badland_leaves_3"}},
},
},
sounds = default.node_sound_leaves_defaults(),
after_place_node = default.after_place_leaves,
})
minetest.register_node("badland:badland_tree", {
description = "Badland Tree",
tiles = {"badland_tree_top.png", "badland_tree_top.png",
"badland_tree.png"},
paramtype2 = "facedir",
is_ground_content = false,
groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
sounds = default.node_sound_wood_defaults(),
on_place = minetest.rotate_node
})
minetest.register_node("badland:badland_wood", {
description = "Badland Wood",
tiles = {"badland_wood.png"},
paramtype2 = "facedir",
is_ground_content = false,
groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
sounds = default.node_sound_wood_defaults(),
on_place = minetest.rotate_node
})
stairs.register_stair_and_slab(
"badland_wood",
"badland:badland_wood",
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
{"badland_wood.png"},
"Badland Wood Stair",
"Badland Wood Slab",
default.node_sound_wood_defaults(),
true
)
doors.register_trapdoor("badland:badland_trapdoor", {
description = "Badland Trapdoor",
inventory_image = "badland_trapdoor.png",
wield_image = "badland_trapdoor.png",
tile_front = "badland_trapdoor.png",
tile_side = "badland_trapdoor_side.png",
gain_open = 0.06,
gain_close = 0.13,
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2, door = 1},
})
doors.register("badland_door", {
tiles = {{ name = "doors_badland_door.png", backface_culling = true }},
description = "Badland Door",
inventory_image = "doors_item_badland.png",
groups = {node = 1, choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
gain_open = 0.06,
gain_close = 0.13,
recipe = {
{"badland:badland_wood", "badland:badland_wood"},
{"badland:badland_wood", "badland:badland_wood"},
{"badland:badland_wood", "badland:badland_wood"},
}
})
doors.register_fencegate("badland:gate_badland", {
description = "Badland Wood Fence Gate",
texture = "badland_wood_fence.png",
material = "badland:badland_wood",
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}
})
default.register_fence("badland:fence_badland_wood", {
description = "Badland Wood Fence",
texture = "badland_wood_fence.png",
inventory_image = "default_fence_overlay.png^badland_wood_fence.png^" ..
"default_fence_overlay.png^[makealpha:255,126,126",
wield_image = "default_fence_overlay.png^badland_wood_fence.png^" ..
"default_fence_overlay.png^[makealpha:255,126,126",
material = "badland:badland_wood",
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3},
sounds = default.node_sound_wood_defaults()
})
default.register_fence_rail("badland:fence_rail_badland_wood", {
description = "Badland Wood Fence Rail",
texture = "badland_wood_fence.png",
inventory_image = "default_fence_rail_overlay.png^badland_wood_fence.png^" ..
"default_fence_rail_overlay.png^[makealpha:255,126,126",
wield_image = "default_fence_rail_overlay.png^badland_wood_fence.png^" ..
"default_fence_rail_overlay.png^[makealpha:255,126,126",
material = "badland:badland_wood",
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3},
sounds = default.node_sound_wood_defaults()
})
minetest.register_node("badland:badland_grass_1", {
description = "Badland Grass",
drawtype = "plantlike",
waving = 1,
tiles = {"badland_grass_1.png"},
-- Use texture of a taller grass stage in inventory
inventory_image = "badland_grass_3.png",
wield_image = "badland_grass_3.png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, flora = 1, attached_node = 1, grass = 1, flammable = 1},
max_items = 1,
items = {
{items = {"farming:seed_wheat"}, rarity = 5},
{items = {"badland:badland_grass_1"}},
},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-6 / 16, -0.5, -6 / 16, 6 / 16, -5 / 16, 6 / 16},
},
on_place = function(itemstack, placer, pointed_thing)
-- place a random grass node
local stack = ItemStack("badland:badland_grass_" .. math.random(1,5))
local ret = minetest.item_place(stack, placer, pointed_thing)
return ItemStack("badland:badland_grass_1 " ..
itemstack:get_count() - (1 - ret:get_count()))
end,
})
for i = 2, 5 do
minetest.register_node("badland:badland_grass_" .. i, {
description = "Badland Grass",
drawtype = "plantlike",
waving = 1,
tiles = {"badland_grass_" .. i .. ".png"},
inventory_image = "badland_grass_" .. i .. ".png",
wield_image = "badland_grass_" .. i .. ".png",
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
drop = "badland:badland_grass_1",
groups = {snappy = 3, flora = 1, attached_node = 1,
not_in_creative_inventory = 1, grass = 1, flammable = 1},
max_items = 1,
items = {
{items = {"farming:seed_wheat"}, rarity = 5},
{items = {"badland:badland_grass_1"}},
},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-6 / 16, -0.5, -6 / 16, 6 / 16, -3 / 16, 6 / 16},
},
})
end
-- Aliases for X Farming nodes
minetest.register_alias("badland:scarecrow","x_farming:scarecrow")
minetest.register_alias("badland:pumpkin_lantern","x_farming:pumpkin_lantern")
minetest.register_alias("badland:pumpkin_block","x_farming:pumpkin_block")
--[[
Trees
]]
local trees = {
{
name = "Spooky",
grow_function = function(pos)
minetest.remove_node(pos)
minetest.place_schematic({x = pos.x-2, y = pos.y, z = pos.z-2}, modpath.."/schematics/badland_tree_1.mts", "0", nil, false)
end,
},
{
name = "Haunted",
grow_function = function(pos)
minetest.remove_node(pos)
minetest.place_schematic({x = pos.x-3, y = pos.y, z = pos.z-2}, modpath.."/schematics/badland_tree_3.mts", "0", nil, false)
end,
},
{
name = "Dusky",
grow_function = function(pos)
minetest.remove_node(pos)
minetest.place_schematic({x = pos.x-3, y = pos.y, z = pos.z-2}, modpath.."/schematics/badland_tree_4.mts", "0", nil, false)
end,
},
}
local mod_bonemeal = minetest.get_modpath("bonemeal")
for index,def in ipairs(trees) do
local sapling = "badland:badland_sapling_" .. index
local image = "badland_sapling_" .. index .. ".png"
local leaves = "badland:badland_leaves_" .. index
-- Register sapling
minetest.register_node(sapling, {
description = def.name .. " Badland Sapling",
drawtype = "plantlike",
tiles = {image},
inventory_image = image,
wield_image = image,
paramtype = "light",
sunlight_propagates = true,
walkable = false,
on_timer = function(pos)
if not default.can_grow(pos) then
-- try a bit later again
minetest.get_node_timer(pos):start(math.random(240, 600))
else
def.grow_function(pos)
end
end,
selection_box = {
type = "fixed",
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, 2 / 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(300, 1500))
end,
on_place = function(itemstack, placer, pointed_thing)
itemstack = default.sapling_on_place(itemstack, placer, pointed_thing,
sapling,
-- minp, maxp to be checked, relative to sapling pos
{x = -1, y = 0, z = -1},
{x = 1, y = 1, z = 1},
-- maximum interval of interior volume check
2)
return itemstack
end,
})
-- Register sapling crafting recipe
minetest.register_craft({
output = sapling,
recipe = {
{"", leaves, ""},
{leaves, "default:stick", leaves}
},
})
-- Add bonemeal integration if supported
if mod_bonemeal then
bonemeal:add_sapling({
{sapling, def.grow_function, "soil"},
})
end
end

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 274 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 451 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 203 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 222 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 258 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 218 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 363 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 342 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 365 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 383 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 169 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 211 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 449 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 542 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 291 B