Config setting to nerf corium

For use on servers that have a mainly creative purpose, the setting
enable_corium_griefing=false will prevent corium from flowing far or
unpredictably and from destroying nodes other than water.  All reactor
meltdowns will stay contained.
This commit is contained in:
Zefram 2014-07-23 22:13:45 +01:00 committed by Vanessa Ezekowitz
parent 366fc3bc65
commit c5e9480d99
2 changed files with 23 additions and 18 deletions

View File

@ -13,6 +13,7 @@ local defaults = {
enable_marble_generation = "true",
enable_granite_generation = "true",
enable_wind_mill = "false",
enable_corium_griefing = "true",
}
for k, v in pairs(defaults) do

View File

@ -351,16 +351,19 @@ minetest.register_abm({
end,
})
local griefing = technic.config:get_bool("enable_corium_griefing")
minetest.register_abm({
nodenames = {"technic:corium_flowing"},
interval = 5,
chance = 10,
chance = (griefing and 10 or 1),
action = function (pos, node)
minetest.set_node(pos, {name="technic:chernobylite_block"})
end,
})
minetest.register_abm({
if griefing then
minetest.register_abm({
nodenames = { "technic:corium_source", "technic:corium_flowing" },
interval = 4,
chance = 4,
@ -377,4 +380,5 @@ minetest.register_abm({
end
end
end,
})
})
end