Skip to content
Permalink
Browse files

Add 'dry dirt' and 'dry dirt with dry grass' nodes for savanna biome

  • Loading branch information...
TumeniNodes authored and paramat committed Jul 26, 2019
1 parent 4282a93 commit c32b8adaa36353f9b21d896e93cce732e26cf0a0
@@ -129,6 +129,7 @@ TumeniNodes (CC BY-SA 3.0):
default_coniferous_litter.png
default_coniferous_litter_side.png
default_grass.png
default_dry_dirt.png

BlockMen (CC BY-SA 3.0):
default_aspen_leaves.png -- Derived from Sofar's texture
@@ -477,7 +477,6 @@ minetest.register_abm({
neighbors = {
"air",
"group:grass",
"group:dry_grass",
"default:snow",
},
interval = 6,
@@ -504,11 +503,8 @@ minetest.register_abm({
-- Snow check is cheapest, so comes first
if name == "default:snow" then
minetest.set_node(pos, {name = "default:dirt_with_snow"})
-- Most likely case first
elseif minetest.get_item_group(name, "grass") ~= 0 then
minetest.set_node(pos, {name = "default:dirt_with_grass"})
elseif minetest.get_item_group(name, "dry_grass") ~= 0 then
minetest.set_node(pos, {name = "default:dirt_with_dry_grass"})
end
end
})
@@ -520,7 +516,7 @@ minetest.register_abm({

minetest.register_abm({
label = "Grass covered",
nodenames = {"group:spreading_dirt_type"},
nodenames = {"group:spreading_dirt_type", "default:dry_dirt_with_dry_grass"},
interval = 8,
chance = 50,
catch_up = false,
@@ -531,7 +527,11 @@ minetest.register_abm({
if name ~= "ignore" and nodedef and not ((nodedef.sunlight_propagates or
nodedef.paramtype == "light") and
nodedef.liquidtype == "none") then
minetest.set_node(pos, {name = "default:dirt"})
if node.name == "default:dry_dirt_with_dry_grass" then
minetest.set_node(pos, {name = "default:dry_dirt"})
else
minetest.set_node(pos, {name = "default:dirt"})
end
end
end
})
@@ -575,8 +575,8 @@ function default.register_ores()
},
-- Only where default:dirt is present as surface material
biomes = {"taiga", "snowy_grassland", "grassland", "coniferous_forest",
"deciduous_forest", "deciduous_forest_shore", "savanna", "savanna_shore",
"rainforest", "rainforest_swamp", "floatland_coniferous_forest"}
"deciduous_forest", "deciduous_forest_shore", "rainforest",
"rainforest_swamp", "floatland_coniferous_forest"}
})

-- Gravel
@@ -1487,9 +1487,9 @@ function default.register_biomes(upper_limit)

minetest.register_biome({
name = "savanna",
node_top = "default:dirt_with_dry_grass",
node_top = "default:dry_dirt_with_dry_grass",
depth_top = 1,
node_filler = "default:dirt",
node_filler = "default:dry_dirt",
depth_filler = 1,
node_riverbed = "default:sand",
depth_riverbed = 2,
@@ -1504,9 +1504,9 @@ function default.register_biomes(upper_limit)

minetest.register_biome({
name = "savanna_shore",
node_top = "default:dirt",
node_top = "default:dry_dirt",
depth_top = 1,
node_filler = "default:dirt",
node_filler = "default:dry_dirt",
depth_filler = 3,
node_riverbed = "default:sand",
depth_riverbed = 2,
@@ -1798,7 +1798,7 @@ local function register_dry_grass_decoration(offset, scale, length)
minetest.register_decoration({
name = "default:dry_grass_" .. length,
deco_type = "simple",
place_on = {"default:dirt_with_dry_grass"},
place_on = {"default:dry_dirt_with_dry_grass"},
sidelen = 16,
noise_params = {
offset = offset,
@@ -2012,7 +2012,7 @@ function default.register_decorations()
minetest.register_decoration({
name = "default:acacia_tree",
deco_type = "schematic",
place_on = {"default:dirt_with_dry_grass"},
place_on = {"default:dry_dirt_with_dry_grass"},
sidelen = 16,
noise_params = {
offset = 0,
@@ -2033,7 +2033,7 @@ function default.register_decorations()
minetest.register_decoration({
name = "default:acacia_log",
deco_type = "schematic",
place_on = {"default:dirt_with_dry_grass"},
place_on = {"default:dry_dirt_with_dry_grass"},
place_offset_y = 1,
sidelen = 16,
noise_params = {
@@ -2050,7 +2050,7 @@ function default.register_decorations()
schematic = minetest.get_modpath("default") .. "/schematics/acacia_log.mts",
flags = "place_center_x",
rotation = "random",
spawn_by = "default:dirt_with_dry_grass",
spawn_by = "default:dry_dirt_with_dry_grass",
num_spawn_by = 8,
})

@@ -2218,7 +2218,7 @@ function default.register_decorations()
minetest.register_decoration({
name = "default:acacia_bush",
deco_type = "schematic",
place_on = {"default:dirt_with_dry_grass"},
place_on = {"default:dry_dirt_with_dry_grass"},
sidelen = 16,
noise_params = {
offset = -0.004,
@@ -52,6 +52,8 @@ default:dirt_with_dry_grass
default:dirt_with_snow
default:dirt_with_rainforest_litter
default:dirt_with_coniferous_litter
default:dry_dirt
default:dry_dirt_with_dry_grass
default:permafrost
default:permafrost_with_stones
@@ -459,7 +461,7 @@ minetest.register_node("default:dirt_with_dry_grass", {
"default_dirt.png",
{name = "default_dirt.png^default_dry_grass_side.png",
tileable_vertical = false}},
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
groups = {crumbly = 3, soil = 1},
drop = 'default:dirt',
sounds = default.node_sound_dirt_defaults({
footstep = {name = "default_grass_footstep", gain = 0.4},
@@ -508,6 +510,25 @@ minetest.register_node("default:dirt_with_coniferous_litter", {
}),
})

minetest.register_node("default:dry_dirt", {
description = "Dry Dirt",
tiles = {"default_dry_dirt.png"},
groups = {crumbly = 3, soil = 1},
sounds = default.node_sound_dirt_defaults(),
})

minetest.register_node("default:dry_dirt_with_dry_grass", {
description = "Dry Dirt with Dry Grass",
tiles = {"default_dry_grass.png", "default_dry_dirt.png",
{name = "default_dry_dirt.png^default_dry_grass_side.png",
tileable_vertical = false}},
groups = {crumbly = 3, soil = 1},
drop = "default:dry_dirt",
sounds = default.node_sound_dirt_defaults({
footstep = {name = "default_grass_footstep", gain = 0.4},
}),
})

minetest.register_node("default:permafrost", {
description = "Permafrost",
tiles = {"default_permafrost.png"},
Binary file not shown.
@@ -38,6 +38,22 @@ minetest.override_item("default:dirt_with_coniferous_litter", {
}
})

minetest.override_item("default:dry_dirt", {
soil = {
base = "default:dry_dirt",
dry = "farming:dry_soil",
wet = "farming:dry_soil_wet"
}
})

minetest.override_item("default:dry_dirt_with_dry_grass", {
soil = {
base = "default:dry_dirt_with_dry_grass",
dry = "farming:dry_soil",
wet = "farming:dry_soil_wet"
}
})

minetest.register_node("farming:soil", {
description = "Soil",
tiles = {"default_dirt.png^farming_soil.png", "default_dirt.png"},
@@ -64,6 +80,32 @@ minetest.register_node("farming:soil_wet", {
}
})

minetest.register_node("farming:dry_soil", {
description = "Dry Soil",
tiles = {"default_dry_dirt.png^farming_soil.png", "default_dry_dirt.png"},
drop = "default:dry_dirt",
groups = {crumbly=3, not_in_creative_inventory=1, soil=2, grassland = 1, field = 1},
sounds = default.node_sound_dirt_defaults(),
soil = {
base = "default:dry_dirt",
dry = "farming:dry_soil",
wet = "farming:dry_soil_wet"
}
})

minetest.register_node("farming:dry_soil_wet", {
description = "Wet Dry Soil",
tiles = {"default_dry_dirt.png^farming_soil_wet.png", "default_dry_dirt.png^farming_soil_wet_side.png"},
drop = "default:dry_dirt",
groups = {crumbly=3, not_in_creative_inventory=1, soil=3, wet = 1, grassland = 1, field = 1},
sounds = default.node_sound_dirt_defaults(),
soil = {
base = "default:dry_dirt",
dry = "farming:dry_soil",
wet = "farming:dry_soil_wet"
}
})

minetest.override_item("default:desert_sand", {
groups = {crumbly=3, falling_node=1, sand=1, soil = 1},
soil = {

0 comments on commit c32b8ad

Please sign in to comment.
You can’t perform that action at this time.