--- fire.old/init.lua +++ fire/init.lua @@ -31,11 +31,14 @@ damage_per_second = 4, groups = {igniter = 2, dig_immediate = 3, not_in_creative_inventory = 1}, on_timer = function(pos) - local f = minetest.find_node_near(pos, 1, {"group:flammable"}) + if not eregions:has_feature (pos, "noburn") then + local f = minetest.find_node_near (pos, 1, + { "group:flammable" }) if not f then minetest.remove_node(pos) return end + end -- Restart timer return true end, @@ -327,6 +330,8 @@ chance = 12, catch_up = false, action = function(pos, node, active_object_count, active_object_count_wider) + + if eregions:has_feature (pos, "noburn") then return end -- If there is water or stuff like that around node, don't ignite if minetest.find_node_near(pos, 1, {"group:puts_out_fire"}) then return @@ -347,7 +352,10 @@ interval = 5, chance = 18, catch_up = false, - action = function(pos, node, active_object_count, active_object_count_wider) + action = function(pos, node, active_object_count, + active_object_count_wider) + + if eregions:has_feature (pos, "noburn") then return end local p = minetest.find_node_near(pos, 1, {"group:flammable"}) if p then local flammable_node = minetest.get_node(p) @@ -361,5 +369,4 @@ end end, }) - end