Replace deprecated method 'setting_getbool' with 'settings:get_bool' (#369)

This commit is contained in:
Jordan Irwin 2017-06-05 07:50:30 -07:00 committed by Vanessa Ezekowitz
parent 9cc1a78371
commit 97e1c8b7f2
3 changed files with 4 additions and 4 deletions

@ -5,7 +5,7 @@
local load_start = os.clock()
technic = rawget(_G, "technic") or {}
technic.creative_mode = minetest.setting_getbool("creative_mode")
technic.creative_mode = minetest.settings:get_bool("creative_mode")
local modpath = minetest.get_modpath("technic")
@ -47,7 +47,7 @@ dofile(modpath.."/tools/init.lua")
-- Aliases for legacy node/item names
dofile(modpath.."/legacy.lua")
if minetest.setting_getbool("log_mods") then
if minetest.settings:get_bool("log_mods") then
print(S("[Technic] Loaded in %f seconds"):format(os.clock() - load_start))
end

@ -3,7 +3,7 @@ local S = technic.getter
frames = {}
local infinite_stacks = minetest.setting_getbool("creative_mode") and minetest.get_modpath("unified_inventory") == nil
local infinite_stacks = minetest.settings:get_bool("creative_mode") and minetest.get_modpath("unified_inventory") == nil
local frames_pos = {}

@ -344,7 +344,7 @@ local function dmg_abm(pos, node)
end
end
if minetest.setting_getbool("enable_damage") then
if minetest.settings:get_bool("enable_damage") then
minetest.register_abm({
label = "Radiation damage",
nodenames = {"group:radioactive"},