Water abm's affect river water also
This commit is contained in:
parent
426a30bb40
commit
e81a542706
@ -42,7 +42,7 @@ minetest.register_craft({
|
|||||||
-- Over time Cobble placed in water changes to Mossy Cobble
|
-- Over time Cobble placed in water changes to Mossy Cobble
|
||||||
minetest.register_abm({
|
minetest.register_abm({
|
||||||
nodenames = {"default:cobble"},
|
nodenames = {"default:cobble"},
|
||||||
neighbors={"default:water_source"},
|
neighbors={"group:water"},
|
||||||
interval = 30,
|
interval = 30,
|
||||||
chance = 10,
|
chance = 10,
|
||||||
action = function(pos, node)
|
action = function(pos, node)
|
||||||
@ -56,14 +56,14 @@ minetest.register_abm({
|
|||||||
"ethereal:crystal_spike", "default:snow", "default:snowblock",
|
"ethereal:crystal_spike", "default:snow", "default:snowblock",
|
||||||
"ethereal:snowbrick"
|
"ethereal:snowbrick"
|
||||||
},
|
},
|
||||||
neighbors = {"default:water_source"},
|
neighbors = {"default:water_source", "default:river_water_source"},
|
||||||
interval = 15,
|
interval = 15,
|
||||||
chance = 2,
|
chance = 2,
|
||||||
action = function(pos, node)
|
action = function(pos, node)
|
||||||
local water = minetest.find_nodes_in_area(
|
local water = minetest.find_nodes_in_area(
|
||||||
{x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
|
{x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
|
||||||
{x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
|
{x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
|
||||||
"default:water_source")
|
{"default:water_source", "default:river_water_source"})
|
||||||
if water then
|
if water then
|
||||||
minetest.set_node(water[1], {name = "default:ice"})
|
minetest.set_node(water[1], {name = "default:ice"})
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user