default: flowing lava can cool down to basalt
This commit is contained in:
parent
3a42666e46
commit
1e7ea09713
@ -100,11 +100,16 @@ end
|
|||||||
-- Lavacooling
|
-- Lavacooling
|
||||||
--
|
--
|
||||||
|
|
||||||
|
lavagen = {
|
||||||
|
"darkage:basalt",
|
||||||
|
"default:stone"
|
||||||
|
}
|
||||||
|
|
||||||
default.cool_lava = function(pos, node)
|
default.cool_lava = function(pos, node)
|
||||||
if node.name == "default:lava_source" then
|
if node.name == "default:lava_source" then
|
||||||
minetest.set_node(pos, {name = "default:obsidian"})
|
minetest.set_node(pos, {name = "default:obsidian"})
|
||||||
else -- Lava flowing
|
else
|
||||||
minetest.set_node(pos, {name = "default:stone"})
|
minetest.set_node(pos, {name = lavagen[math.random(1,#lavagen)]})
|
||||||
end
|
end
|
||||||
minetest.sound_play("default_cool_lava",
|
minetest.sound_play("default_cool_lava",
|
||||||
{pos = pos, max_hear_distance = 16, gain = 0.25})
|
{pos = pos, max_hear_distance = 16, gain = 0.25})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user