electric/mods/electric_biomes/biomes/grasslands.lua
Alexey Chubukov b3a3ec421f wip
2023-12-14 15:05:44 +04:00

59 lines
1.4 KiB
Lua

local S = minetest.get_translator("electric_biomes")
minetest.register_biome({
name = "grasslands",
node_top = "mapgen_topsoil",
depth_top = 1,
node_filler = "mapgen_soil",
depth_filler = 3,
y_max = 1000,
y_min = -3,
heat_point = 50,
humidity_point = 50,
})
ebiometrees.register_tree("electric_biomes:oak",{
description = "Oak",
groups = {flammable = 2},
life = 30,
growth_preferences = {
{ebiometrees.directions.up},
{
ebiometrees.directions.north,
ebiometrees.directions.east,
ebiometrees.directions.south,
ebiometrees.directions.west
}
},
growth_limit = 10,
age_max = 20,
})
minetest.register_node("electric_biomes:grass", {
description = S("Grass"),
tiles = {"electric_biomes_grass.png"},
drawtype = "plantlike",
visual_scale = 1.4,
waving = 1,
paramtype = "light",
sunlight_propagates = true,
walkable = false,
buildable_to = true,
groups = {snappy = 3, attached_node = 1,
flora = 1, grass = 1, flammable = 1,
fuel = 1
},
})
minetest.register_alias("grass", "electric_biomes:grass")
minetest.register_alias("grassplant", "electric_biomes:grass")
minetest.register_decoration({
deco_type = "simple",
place_on = {"mapgen_topsoil"},
sidelen = 16,
fill_ratio = 0.9,
biomes = {"grasslands"},
y_max = 200,
y_min = 1,
decoration = "electric_biomes:grass",
})