mirror of
https://github.com/Splizard/minetest-mod-snow.git
synced 2025-06-30 07:10:21 +02:00
Fix crash et modifications de la génération du terrain
This commit is contained in:
@ -1,58 +1,61 @@
|
||||
minetest.register_biome({
|
||||
--[[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 = 2,
|
||||
|
||||
height_min = snow.min_height,
|
||||
height_max = snow.min_height+60,
|
||||
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,
|
||||
|
||||
height_min = snow.min_height,
|
||||
height_max = snow.min_height+60,
|
||||
heat_point = 10.0,
|
||||
humidity_point = 55.0,
|
||||
})
|
||||
|
||||
minetest.register_biome({
|
||||
name = "snow_biome_lush",
|
||||
|
||||
node_top = "default:dirt_with_snow",
|
||||
depth_top = 1,
|
||||
node_filler = "default:dirt",
|
||||
depth_filler = 2,
|
||||
|
||||
height_min = snow.min_height,
|
||||
height_max = snow.min_height+60,
|
||||
heat_point = 10.0,
|
||||
node_riverbed = "default:sand",
|
||||
depth_riverbed = 2,
|
||||
y_min = 2,
|
||||
y_max = 31000,
|
||||
heat_point = 20.0,
|
||||
humidity_point = 70.0,
|
||||
})
|
||||
|
||||
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,
|
||||
y_min = 2,
|
||||
y_max = 31000,
|
||||
heat_point = 10.0,
|
||||
humidity_point = 70.0,
|
||||
})
|
||||
|
||||
--[[minetest.register_biome({
|
||||
name = "snow_biome_alpine",
|
||||
|
||||
node_top = "default:stone",
|
||||
depth_top = 1,
|
||||
node_filler = "default:stone",
|
||||
|
||||
height_min = snow.min_height+60,
|
||||
height_max = 31000,
|
||||
y_min = snow.min_height+60,
|
||||
y_max = 31000,
|
||||
heat_point = 10.0,
|
||||
humidity_point = 40.0,
|
||||
})
|
||||
|
||||
]]--
|
||||
minetest.register_biome({
|
||||
name = "snow_biome_sand",
|
||||
|
||||
@ -61,8 +64,8 @@ minetest.register_biome({
|
||||
node_filler = "default:stone",
|
||||
depth_filler = 0,
|
||||
|
||||
height_min = -31000,
|
||||
height_max = 2,
|
||||
y_min = -2,
|
||||
y_max = 31000,
|
||||
heat_point = 10.0,
|
||||
humidity_point = 40.0,
|
||||
})
|
||||
@ -71,10 +74,19 @@ minetest.register_biome({
|
||||
--Pine tree.
|
||||
minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = "default:dirt_with_snow",
|
||||
place_on = {"default:dirt_with_snow", "default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.005,
|
||||
biomes = {"snow_biome_default"},
|
||||
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,
|
||||
y_min = 4,
|
||||
biomes = {"snowy_grassland", "coniferous_forest", "taiga"},
|
||||
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
})
|
||||
@ -83,7 +95,16 @@ minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = "default:dirt_with_snow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.05,
|
||||
noise_params = {
|
||||
offset = 0.036,
|
||||
scale = 0.022,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
y_max = 31000,
|
||||
y_min = 4,
|
||||
biomes = {"snow_biome_forest"},
|
||||
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
@ -93,7 +114,9 @@ minetest.register_decoration({
|
||||
deco_type = "schematic",
|
||||
place_on = "default:dirt_with_snow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.1,
|
||||
fill_ratio = 0.05,
|
||||
y_max = 31000,
|
||||
y_min = 4,
|
||||
biomes = {"snow_biome_lush"},
|
||||
schematic = minetest.get_modpath("snow").."/schematics/pine.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
@ -104,35 +127,95 @@ minetest.register_decoration({
|
||||
deco_type = "simple",
|
||||
place_on = "default:dirt_with_snow",
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.005,
|
||||
biomes = {"snow_biome_default"},
|
||||
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 = "default:dry_shrub",
|
||||
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,
|
||||
biomes = {"snow_biome_default", "snow_biome_forest", "snow_biome_lush"},
|
||||
y_max = 31000,
|
||||
y_min = 1,
|
||||
biomes = {"snow_biome_forest", "snow_biome_lush"},
|
||||
decoration = "default:snow",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
--[[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",
|
||||
})
|
||||
]]
|
||||
|
Reference in New Issue
Block a user