1
0
mirror of https://github.com/minetest/minetest_game.git synced 2024-12-23 15:20:19 +01:00

Fire: Disable fire by default in multiplayer

This commit is contained in:
ezhh 2017-04-10 02:23:00 +01:00 committed by paramat
parent 63b3542d00
commit 758d5010b8

View File

@ -292,9 +292,14 @@ minetest.register_abm({
local fire_enabled = minetest.setting_getbool("enable_fire") local fire_enabled = minetest.setting_getbool("enable_fire")
if fire_enabled == nil then if fire_enabled == nil then
-- New setting not specified, check for old setting. -- enable_fire setting not specified, check for disable_fire
-- If old setting is also not specified, 'not nil' is true. local fire_disabled = minetest.setting_getbool("disable_fire")
fire_enabled = not minetest.setting_getbool("disable_fire") if fire_disabled == nil then
-- Neither setting specified, check whether singleplayer
fire_enabled = minetest.is_singleplayer()
else
fire_enabled = not fire_disabled
end
end end
if not fire_enabled then if not fire_enabled then