electric/mods/ebiome/biomes/grasslands.lua

76 lines
2.1 KiB
Lua
Raw Normal View History

local S = minetest.get_translator("eterrain")
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,
})
minetest.register_node("ebiome:oak_trunk_normal", {
description = S("Oak tree trunk"),
tiles = { "ebiome_oak_trunk_slice_normal.png", "ebiome_oak_trunk_slice_normal.png","ebiome_oak_trunk_normal.png"},
paramtype2 = "facedir",
is_ground_content = false,
groups = {tree = 1, choppy = 2, flammable = 2},
on_place = minetest.rotate_node
})
minetest.register_node("ebiome:oak_trunk_normal_corner", {
description = S("Oak tree trunk corner branch"),
tiles = {
"ebiome_oak_trunk_normal.png",
"ebiome_oak_trunk_slice_normal.png",
"ebiome_oak_trunk_corner_normal.png^[transformFX",
"ebiome_oak_trunk_corner_normal.png",
"ebiome_oak_trunk_normal.png",
"ebiome_oak_trunk_slice_normal.png",
},
paramtype2 = "facedir",
is_ground_content = false,
groups = {tree = 1, choppy = 2, flammable = 2},
on_place = minetest.rotate_node
})
minetest.register_node("ebiome:oak_sapling", {
description = S("Oak tree sapling"),
drawtype = "plantlike",
tiles = { "ebiome_oak_sapling.png" },
paramtype = "light",
sunlight_propagates = true,
walkable = false,
groups = {snappy = 2, dig_immediate = 3, flammable = 2,
attached_node = 1, sapling = 1}
})
minetest.register_node("ebiome:grass", {
description = S("Grass"),
tiles = {"ebiome_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", "ebiome:grass")
minetest.register_alias("grassplant", "ebiome: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 = "ebiome:grass",
})