From 66d191c7cdc1d9242f6f8640f2e415ffbb1380c3 Mon Sep 17 00:00:00 2001 From: FaceDeer Date: Thu, 30 Jan 2020 18:06:24 -0700 Subject: [PATCH] swap out deprecated functions for current ones --- config.lua | 6 +++--- volcanoes.lua | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/config.lua b/config.lua index 131fd41..c32f2fc 100644 --- a/config.lua +++ b/config.lua @@ -7,11 +7,11 @@ local print_settingtypes = false local function setting(stype, name, default, description) local value if stype == "bool" then - value = minetest.setting_getbool(CONFIG_FILE_PREFIX..name) + value = minetest.settings:get_bool(CONFIG_FILE_PREFIX..name, default) elseif stype == "string" then - value = minetest.setting_get(CONFIG_FILE_PREFIX..name) + value = minetest.settings:get(CONFIG_FILE_PREFIX..name) elseif stype == "int" or stype == "float" then - value = tonumber(minetest.setting_get(CONFIG_FILE_PREFIX..name)) + value = tonumber(minetest.settings:get(CONFIG_FILE_PREFIX..name)) end if value == nil then value = default diff --git a/volcanoes.lua b/volcanoes.lua index a09826f..4fdb084 100644 --- a/volcanoes.lua +++ b/volcanoes.lua @@ -211,7 +211,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local chunk_lengths = {x = sidelen, y = sidelen, z = sidelen} --table of chunk edges nobj_perlin = nobj_perlin or minetest.get_perlin_map(perlin_params, chunk_lengths) - local nvals_perlin = nobj_perlin:get3dMap_flat(minp, nvals_perlin_buffer) -- switch to get_3d_map_flat for minetest v0.5 + local nvals_perlin = nobj_perlin:get_3d_map_flat(minp, nvals_perlin_buffer) local noise_area = VoxelArea:new{MinEdge=minp, MaxEdge=maxp} local noise_iterator = noise_area:iterp(minp, maxp)