dfcaverns/ground_cover.lua
2017-03-07 23:50:58 -07:00

56 lines
1.6 KiB
Lua

-- internationalization boilerplate
local MP = minetest.get_modpath(minetest.get_current_modname())
local S, NS = dofile(MP.."/intllib.lua")
--------------------------------------------------
-- Cave moss
-- cyan/dark cyan
minetest.register_node("dfcaverns:cobble_cave_moss", {
description = S("Cobblestone With Cave Moss"),
tiles = {"default_cobble.png^dfcaverns_cave_moss.png", "default_cobble.png", "default_cobble.png^dfcaverns_cave_moss_side.png"},
drop = "default:cobble",
is_ground_content = false,
groups = {cracky = 3, stone = 2},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_abm{
label = "cave moss spread",
nodenames = {"default:cobble"},
neighbors = {"dfcaverns:cobble_cave_moss"},
interval = 30,
chance = 10,
catch_up = true,
action = function(pos)
minetest.swap_node(pos, {name="dfcaverns:cobble_cave_moss"})
end,
}
--------------------------------------------------
-- floor fungus
-- white/yellow
minetest.register_node("dfcaverns:cobble_floor_fungus", {
description = S("Cobblestone With Floor Fungus"),
tiles = {"default_cobble.png^dfcaverns_floor_fungus.png", "default_cobble.png", "default_cobble.png^dfcaverns_floor_fungus_side.png"},
drops= "default:cobble",
is_ground_content = false,
groups = {cracky = 3, stone = 2},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_abm{
label = "floor fungus spread",
nodenames = {"default:cobble"},
neighbors = {"dfcaverns:cobble_floor_fungus"},
interval = 30,
chance = 10,
catch_up = true,
action = function(pos)
minetest.swap_node(pos, {name="dfcaverns:cobble_floor_fungus"})
end,
}