diff --git a/minetest-mod-womd/init.lua b/minetest-mod-womd/init.lua index 022f846..0ac5b1b 100644 --- a/minetest-mod-womd/init.lua +++ b/minetest-mod-womd/init.lua @@ -9,4 +9,24 @@ minetest.register_node("womd:radioactive_air", { drop = "", damage_per_second = 1, groups = {not_in_creative_inventory=1}, +}) + +minetest.register_abm({ + nodenames = {"womd:radioactive_air"}, + neighbors = {"default:air"}, + interval = 10.0, + chance = 10, + action = function(pos, node, active_object_count, active_object_count_wider) + minetest.set_node(pos, {name = "default:air"}) + end, +}) + +minetest.register_abm({ + nodenames = {"default:air"}, + neighbors = {"womd:radioactive_air"}, + interval = 15.0, + chance = 10, + action = function(pos, node, active_object_count, active_object_count_wider) + minetest.set_node(pos, {name = "womd:radioactive_air"}) + end, }) \ No newline at end of file