1
0
mirror of https://github.com/Gael-de-Sailly/30-biomes.git synced 2024-12-23 01:10:33 +01:00

Big update, various things

- Added fir tree and its log, textures from my old Forest mod
- Moved pine tree to hot regions and with a different shape (Pinus Pinea)
- Renamed mod (biomes -> 30biomes)
This commit is contained in:
Gael-de-Sailly 2018-02-04 02:00:15 +01:00
parent 40d14c4775
commit 03967a9f1b
13 changed files with 190 additions and 34 deletions

View File

@ -1,7 +1,10 @@
local path = minetest.get_modpath("30biomes")
local defaultpath = minetest.get_modpath("default")
-- Mud in swamps -- Mud in swamps
minetest.register_ore({ minetest.register_ore({
ore_type = "blob", ore_type = "blob",
ore = "biomes:mud", ore = "30biomes:mud",
wherein = {"default:dirt", "default:dirt_with_grass"}, wherein = {"default:dirt", "default:dirt_with_grass"},
clust_scarcity = 12*12*12, clust_scarcity = 12*12*12,
clust_size = 10, clust_size = 10,
@ -43,7 +46,7 @@ minetest.register_ore({
-- Jungle grass -- Jungle grass
minetest.register_decoration({ minetest.register_decoration({
deco_type = "simple", deco_type = "simple",
place_on = {"default:dirt_with_grass", "biomes:mud"}, place_on = {"default:dirt_with_grass", "30biomes:mud"},
sidelen = 16, sidelen = 16,
noise_params = { noise_params = {
offset = 0.15, offset = 0.15,
@ -172,7 +175,7 @@ minetest.register_decoration({
biomes = {"deciduous_forest", "cold_deciduous_forest", "orchard", "hot_deciduous_forest"}, biomes = {"deciduous_forest", "cold_deciduous_forest", "orchard", "hot_deciduous_forest"},
y_min = 1, y_min = 1,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/apple_tree.mts", schematic = defaultpath.."/schematics/apple_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
}) })
@ -225,7 +228,7 @@ minetest.register_decoration({
biomes = {"semi-tropical_forest", "mixed_forest"}, biomes = {"semi-tropical_forest", "mixed_forest"},
y_min = 1, y_min = 1,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/apple_tree.mts", schematic = defaultpath.."/schematics/apple_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
}) })
@ -278,7 +281,7 @@ minetest.register_decoration({
biomes = {"rainforest", "mangrove"}, biomes = {"rainforest", "mangrove"},
y_min = 0, y_min = 0,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/jungle_tree.mts", schematic = defaultpath.."/schematics/jungle_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
rotation = "random", rotation = "random",
}) })
@ -332,7 +335,7 @@ minetest.register_decoration({
biomes = {"semi-tropical_forest"}, biomes = {"semi-tropical_forest"},
y_min = 0, y_min = 0,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/jungle_tree.mts", schematic = defaultpath.."/schematics/jungle_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
rotation = "random", rotation = "random",
}) })
@ -383,10 +386,10 @@ minetest.register_decoration({
octaves = 3, octaves = 3,
persist = 0.66 persist = 0.66
}, },
biomes = {"taiga", "coniferous_forest"}, biomes = {"hot_pine_forest"},
y_min = 2, y_min = 2,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/pine_tree.mts", schematic = path.."/schematics/pine_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
}) })
@ -402,7 +405,7 @@ minetest.register_decoration({
octaves = 3, octaves = 3,
persist = 0.66 persist = 0.66
}, },
biomes = {"taiga", "coniferous_forest"}, biomes = {"hot_pine_forest"},
y_min = 1, y_min = 1,
y_max = 31000, y_max = 31000,
schematic = { schematic = {
@ -424,6 +427,112 @@ minetest.register_decoration({
}) })
-- Rarer pine tree and log -- Rarer pine tree and log
minetest.register_decoration({
deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
offset = 0.020,
scale = -0.020,
spread = {x = 250, y = 250, z = 250},
seed = 45,
octaves = 3,
persist = 0.66
},
biomes = {"hot_deciduous_forest", "scrub"},
y_min = 2,
y_max = 31000,
schematic = path.."/schematics/pine_tree.mts",
flags = "place_center_x, place_center_z",
})
minetest.register_decoration({
deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
offset = 0.001,
scale = -0.001,
spread = {x = 250, y = 250, z = 250},
seed = 2,
octaves = 3,
persist = 0.66
},
biomes = {"hot_deciduous_forest", "scrub"},
y_min = 1,
y_max = 31000,
schematic = {
size = {x = 3, y = 3, z = 1},
data = {
{name = "air", prob = 0},
{name = "air", prob = 0},
{name = "air", prob = 0},
{name = "default:pine_tree", param2 = 12, prob = 191},
{name = "default:pine_tree", param2 = 12},
{name = "default:pine_tree", param2 = 12, prob = 127},
{name = "air", prob = 0},
{name = "flowers:mushroom_red", prob = 63},
{name = "air", prob = 0},
},
},
flags = "place_center_x",
rotation = "random",
})
-- Fir tree and log
minetest.register_decoration({
deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
offset = 0.036,
scale = 0.022,
spread = {x = 250, y = 250, z = 250},
seed = 2,
octaves = 3,
persist = 0.66
},
biomes = {"taiga", "coniferous_forest"},
y_min = 2,
y_max = 31000,
schematic = path.."/schematics/fir_tree.mts",
flags = "place_center_x, place_center_z",
})
minetest.register_decoration({
deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
offset = 0.0018,
scale = 0.0011,
spread = {x = 250, y = 250, z = 250},
seed = 2,
octaves = 3,
persist = 0.66
},
biomes = {"taiga", "coniferous_forest"},
y_min = 1,
y_max = 31000,
schematic = {
size = {x = 3, y = 3, z = 1},
data = {
{name = "air", prob = 0},
{name = "air", prob = 0},
{name = "air", prob = 0},
{name = "30biomes:fir_tree", param2 = 12, prob = 191},
{name = "30biomes:fir_tree", param2 = 12},
{name = "30biomes:fir_tree", param2 = 12, prob = 127},
{name = "air", prob = 0},
{name = "flowers:mushroom_red", prob = 63},
{name = "air", prob = 0},
},
},
flags = "place_center_x",
rotation = "random",
})
-- Rarer fir tree and log
minetest.register_decoration({ minetest.register_decoration({
deco_type = "schematic", deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"}, place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
@ -439,7 +548,7 @@ minetest.register_decoration({
biomes = {"mixed_forest"}, biomes = {"mixed_forest"},
y_min = 2, y_min = 2,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/pine_tree.mts", schematic = path.."/schematics/fir_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
}) })
@ -464,9 +573,9 @@ minetest.register_decoration({
{name = "air", prob = 0}, {name = "air", prob = 0},
{name = "air", prob = 0}, {name = "air", prob = 0},
{name = "air", prob = 0}, {name = "air", prob = 0},
{name = "default:pine_tree", param2 = 12, prob = 191}, {name = "30biomes:fir_tree", param2 = 12, prob = 191},
{name = "default:pine_tree", param2 = 12}, {name = "30biomes:fir_tree", param2 = 12},
{name = "default:pine_tree", param2 = 12, prob = 127}, {name = "30biomes:fir_tree", param2 = 12, prob = 127},
{name = "air", prob = 0}, {name = "air", prob = 0},
{name = "flowers:mushroom_red", prob = 63}, {name = "flowers:mushroom_red", prob = 63},
{name = "air", prob = 0}, {name = "air", prob = 0},
@ -492,7 +601,7 @@ minetest.register_decoration({
biomes = {"savanna", "red_savanna"}, biomes = {"savanna", "red_savanna"},
y_min = 1, y_min = 1,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/acacia_tree.mts", schematic = defaultpath.."/schematics/acacia_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
rotation = "random", rotation = "random",
}) })
@ -543,7 +652,7 @@ minetest.register_decoration({
biomes = {"cold_deciduous_forest", "mixed_forest"}, biomes = {"cold_deciduous_forest", "mixed_forest"},
y_min = 1, y_min = 1,
y_max = 31000, y_max = 31000,
schematic = minetest.get_modpath("default").."/schematics/aspen_tree.mts", schematic = defaultpath.."/schematics/aspen_tree.mts",
flags = "place_center_x, place_center_z", flags = "place_center_x, place_center_z",
rotation = "random", rotation = "random",
}) })
@ -597,7 +706,7 @@ minetest.register_decoration({
biomes = {"swamp_shore", "hot_swamp_shore", "mangrove"}, biomes = {"swamp_shore", "hot_swamp_shore", "mangrove"},
y_min = 0, y_min = 0,
y_max = 0, y_max = 0,
schematic = minetest.get_modpath("default").."/schematics/papyrus.mts", schematic = defaultpath.."/schematics/papyrus.mts",
}) })
-- Cactus -- Cactus

View File

@ -1,24 +1,8 @@
local path = minetest.get_modpath("biomes") local path = minetest.get_modpath("30biomes")
minetest.clear_registered_decorations() minetest.clear_registered_decorations()
minetest.clear_registered_biomes() minetest.clear_registered_biomes()
minetest.register_node("biomes:mud", {
description = "Mud",
tiles = {"biomes_mud.png"},
liquid_viscosity = 8,
liquidtype = "source",
liquid_renewable = false,
liquid_alternative_source = "biomes:mud",
liquid_alternative_flowing = "biomes:mud",
liquid_range = 0,
post_effect_color = {r=115, g=61, b=31, a=255},
drowning = 1,
walkable = false,
groups = {crumbly = 2},
sounds = default.node_sound_dirt_defaults(),
})
local file = io.open(path .. "/biomes.csv", "r") local file = io.open(path .. "/biomes.csv", "r")
for line in file:lines() do for line in file:lines() do
local attribs = line:split(",", true) local attribs = line:split(",", true)
@ -77,6 +61,8 @@ end
file:close() file:close()
dofile(path .. "/nodes.lua")
--dofile(path .. "/main_biomes.lua") --dofile(path .. "/main_biomes.lua")
--dofile(path .. "/beach_biomes.lua") --dofile(path .. "/beach_biomes.lua")
--dofile(path .. "/sea_biomes.lua") --dofile(path .. "/sea_biomes.lua")

View File

@ -1 +1 @@
name = biomes name = 30biomes

59
nodes.lua Normal file
View File

@ -0,0 +1,59 @@
-- Mud for swamps
minetest.register_node("30biomes:mud", {
description = "Mud",
tiles = {"biomes_mud.png"},
liquid_viscosity = 8,
liquidtype = "source",
liquid_renewable = false,
liquid_alternative_source = "30biomes:mud",
liquid_alternative_flowing = "30biomes:mud",
liquid_range = 0,
post_effect_color = {r=115, g=61, b=31, a=255},
drowning = 1,
walkable = false,
groups = {crumbly = 2},
sounds = default.node_sound_dirt_defaults(),
})
-- Fir tree
minetest.register_node("30biomes:fir_tree", {
description = "Fir Tree",
tiles = {"biomes_fir_tree_top.png", "biomes_fir_tree_top.png", "biomes_fir_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
})
-- Fir needles
minetest.register_node("30biomes:fir_needles", {
description = "Fir Needles",
drawtype = "allfaces_optional",
waving = 1,
tiles = {"biomes_fir_leaves.png"},
paramtype = "light",
is_ground_content = false,
groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1},
--[[drop = {
max_items = 1,
items = {
{
-- player will get sapling with 1/20 chance
items = {'default:sapling'},
rarity = 20,
},
{
-- player will get leaves only if he get no saplings,
-- this is because max_items is 1
items = {'default:leaves'},
}
}
},]]
sounds = default.node_sound_leaves_defaults(),
after_place_node = default.after_place_leaves,
})
minetest.register_alias("30biomes:fir_needles", "fir_needles")

BIN
schematics/fir_tree.mts Normal file

Binary file not shown.

View File

@ -0,0 +1,2 @@
MTSM\00\00\00\00?????\00\00air\00biomes:fir_needles\00biomes:fir_treex\9C\EDR[
\C00\8B\BDh\8F\E0r\F4\AE{\E0\FA%ݴ\ECg)\88!%\84 \80\D8\CBV\A3\A9\C6)i\EA\8E\F2r\93k;\9D\8B9?W\EFT\F1\EE\D6vI\F5\C1]U\A5\D6Y\EAC *H\CEP\A09\83}\F4\FF\8D=\AC\CC.)\95\87Į~,\C2 a5

BIN
schematics/pine_tree.mts Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 379 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 289 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 443 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 362 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 268 B