minetest-mod-snow/src/mapgen_v7.lua

236 lines
5.2 KiB
Lua
Raw Normal View History

--[[minetest.register_biome({
name = "snow_biome_default",
node_dust = "default:snow",
node_top = "default:dirt_with_snow",
depth_top = 1,
node_filler = "default:dirt",
depth_filler = 1,
node_riverbed = "default:sand",
depth_riverbed = 2,
y_min = 5,
y_max = 31000,
heat_point = 10.0,
humidity_point = 40.0,
})
]]--
minetest.register_biome({
name = "snow_biome_forest",
node_dust = "default:snow",
node_top = "default:dirt_with_snow",
depth_top = 1,
node_filler = "default:dirt",
depth_filler = 2,
node_riverbed = "default:sand",
depth_riverbed = 2,
2018-11-14 22:26:29 +01:00
y_min = 2,
y_max = 31000,
heat_point = 20.0,
humidity_point = 70.0,
})
2018-11-14 22:26:29 +01:00
minetest.register_biome({
name = "pine_forest",
node_top = "default:dirt_with_grass",
depth_top = 1,
node_filler = "default:dirt",
depth_filler = 3,
node_riverbed = "default:sand",
depth_riverbed = 2,
y_min = 60,
y_max = 31000,
heat_point = 40,
humidity_point = 68,
})
minetest.register_biome({
name = "snow_biome_lush",
node_dust = "default:snow",
node_top = "default:dirt_with_snow",
depth_top = 1,
node_filler = "default:dirt",
depth_filler = 2,
node_riverbed = "default:sand",
depth_riverbed = 2,
2018-11-14 22:26:29 +01:00
y_min = 2,
y_max = 31000,
heat_point = 10.0,
humidity_point = 70.0,
})
2018-11-14 22:26:29 +01:00
minetest.register_biome({
name = "snow_biome_alpine",
2018-11-14 22:26:29 +01:00
node_top = "default:dirt_with_snow",
depth_top = 1,
node_filler = "default:stone",
2018-11-14 22:26:29 +01:00
y_min = 60,
y_max = 31000,
heat_point = 10.0,
humidity_point = 40.0,
})
2018-11-14 22:26:29 +01:00
minetest.register_biome({
name = "snow_biome_sand",
node_top = "default:sand",
depth_top = 3,
node_filler = "default:stone",
depth_filler = 0,
y_min = -2,
y_max = 31000,
heat_point = 10.0,
humidity_point = 40.0,
})
--Pine tree.
minetest.register_decoration({
deco_type = "schematic",
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
offset = -0.004,
scale = 0.01,
spread = {x = 100, y = 100, z = 100},
seed = 4087,
octaves = 3,
persist = 0.7,
},
y_max = 31000,
2018-11-14 22:26:29 +01:00
y_min = 4,
biomes = {"snowy_grassland", "coniferous_forest", "taiga", "snow_biome_alpine"},
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
flags = "place_center_x, place_center_z",
})
minetest.register_decoration({
deco_type = "schematic",
2018-11-14 22:26:29 +01:00
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
sidelen = 16,
noise_params = {
--offset = 0.036,
offset = 0.020,
2018-11-14 22:26:29 +01:00
scale = 0.002,
spread = {x = 250, y = 250, z = 250},
seed = 2861,
octaves = 3,
persist = 0.66
},
y_max = 31000,
2018-11-14 22:26:29 +01:00
y_min = 4,
biomes = {"snow_biome_forest", "pine_forest"},
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
flags = "place_center_x, place_center_z",
})
minetest.register_decoration({
deco_type = "schematic",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 0.05,
y_max = 31000,
2018-11-14 22:26:29 +01:00
y_min = 4,
biomes = {"snow_biome_lush"},
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
flags = "place_center_x, place_center_z",
})
--Dry shrubs.
minetest.register_decoration({
deco_type = "simple",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 0.001,
y_max = 31000,
y_min = 1,
biomes = {"snowy_grassland"},
decoration = "default:dry_shrub",
})
minetest.register_decoration({
deco_type = "simple",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 0.01,
y_max = 31000,
y_min = 1,
biomes = {"snow_biome_forest", "snow_biome_lush"},
decoration = "default:dry_shrub",
})
--Snow shrubs.
minetest.register_decoration({
deco_type = "simple",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 0.005,
y_max = 31000,
y_min = 1,
biomes = {"snowy_grassland"},
decoration = "snow:shrub_covered",
})
minetest.register_decoration({
deco_type = "simple",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 0.05,
y_max = 31000,
y_min = 1,
biomes = {"snow_biome_forest", "snow_biome_lush"},
decoration = "snow:shrub_covered",
})
-- Snow Flowers
local function register_flower(seed, name)
minetest.register_decoration({
deco_type = "simple",
place_on = {"default:dirt_with_snow"},
sidelen = 16,
noise_params = {
offset = -0.015,
scale = 0.025,
spread = {x = 200, y = 200, z = 200},
seed = seed,
octaves = 3,
persist = 0.6
},
biomes = {"snow_biome_lush", "snow_biome_forest", "taiga", "snowy_grassland", "tundra"},
y_min = 1,
y_max = 31000,
decoration = "snow:flower_"..name,
})
end
register_flower(436, "rose")
register_flower(19822, "tulip")
register_flower(1220999, "dandelion_yellow")
register_flower(36662, "geranium")
register_flower(1133, "viola")
register_flower(73133, "dandelion_white")
--Snow.
minetest.register_decoration({
deco_type = "simple",
place_on = "default:dirt_with_snow",
sidelen = 16,
fill_ratio = 10,
y_max = 31000,
y_min = 1,
biomes = {"snow_biome_forest", "snow_biome_lush"},
decoration = "default:snow",
})
2018-11-14 22:26:29 +01:00
minetest.register_decoration({
deco_type = "simple",
place_on = "default:stone",
sidelen = 16,
fill_ratio = 10,
y_max = 31000,
y_min = 1,
biomes = {"snow_biome_alpine"},
decoration = "default:snow",
})