summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVanessa Dannenberg <vanessa.e.dannenberg@gmail.com>2019-06-07 00:54:45 -0400
committerVanessa Dannenberg <vanessa.e.dannenberg@gmail.com>2019-06-07 00:54:45 -0400
commitf11997ad956da3735bf118cdc43dc68b8a811b4f (patch)
tree672f9fcd0abf4b246643665375492bfce6253012
parentd4e5d04b4cc65846af7dae950e10c00eca8e2716 (diff)
downloaddreambuilder_modpack-f11997ad956da3735bf118cdc43dc68b8a811b4f.tar
dreambuilder_modpack-f11997ad956da3735bf118cdc43dc68b8a811b4f.tar.gz
dreambuilder_modpack-f11997ad956da3735bf118cdc43dc68b8a811b4f.tar.bz2
dreambuilder_modpack-f11997ad956da3735bf118cdc43dc68b8a811b4f.tar.xz
dreambuilder_modpack-f11997ad956da3735bf118cdc43dc68b8a811b4f.zip
update caverealms lite, farming redo, homedecor, pipeworks, and xban2
-rw-r--r--caverealms_lite/config.lua6
-rw-r--r--farming/hoes.lua4
-rw-r--r--homedecor_common/depends.txt2
-rw-r--r--homedecor_lighting/init.lua1
-rw-r--r--pipeworks/luaentity.lua5
-rw-r--r--xban2/README.md6
-rw-r--r--xban2/init.lua25
7 files changed, 45 insertions, 4 deletions
diff --git a/caverealms_lite/config.lua b/caverealms_lite/config.lua
index a4c9a0f..5a5f9cc 100644
--- a/caverealms_lite/config.lua
+++ b/caverealms_lite/config.lua
@@ -7,11 +7,11 @@ caverealms.config = {}
local function setting(stype, name, default)
local value
if stype == "bool" then
- value = minetest.setting_getbool(CONFIG_FILE_PREFIX..name)
+ value = minetest.settings:get_bool(CONFIG_FILE_PREFIX..name)
elseif stype == "string" then
- value = minetest.setting_get(CONFIG_FILE_PREFIX..name)
+ value = minetest.settings:get(CONFIG_FILE_PREFIX..name)
elseif stype == "number" 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/farming/hoes.lua b/farming/hoes.lua
index ed833e5..1b33774 100644
--- a/farming/hoes.lua
+++ b/farming/hoes.lua
@@ -24,6 +24,10 @@ farming.register_hoe = function(name, def)
def.max_uses = 30
end
+ -- add hoe group
+ def.groups = def.groups or {}
+ def.groups.hoe = 1
+
-- Register the tool
minetest.register_tool(name, {
description = def.description,
diff --git a/homedecor_common/depends.txt b/homedecor_common/depends.txt
index a78a220..0d59c2b 100644
--- a/homedecor_common/depends.txt
+++ b/homedecor_common/depends.txt
@@ -1,3 +1,3 @@
default
creative
-
+intllib?
diff --git a/homedecor_lighting/init.lua b/homedecor_lighting/init.lua
index cc0fdbb..e111dcd 100644
--- a/homedecor_lighting/init.lua
+++ b/homedecor_lighting/init.lua
@@ -1785,6 +1785,7 @@ unifieddyes.register_color_craft({
minetest.register_alias("chains:chain_top", "homedecor:chain_steel_top")
minetest.register_alias("chains:chain_top_brass", "homedecor:chain_brass_top")
+minetest.register_alias("chains:chandelier", "homedecor:chandelier_steel")
minetest.register_alias("chains:chandelier_steel", "homedecor:chandelier_steel")
minetest.register_alias("chains:chandelier_brass", "homedecor:chandelier_brass")
diff --git a/pipeworks/luaentity.lua b/pipeworks/luaentity.lua
index c11c030..8385264 100644
--- a/pipeworks/luaentity.lua
+++ b/pipeworks/luaentity.lua
@@ -46,6 +46,11 @@ local function read_entities()
end
local function write_entities()
+ if not luaentity.entities then
+ -- This can happen if crashing on startup, causing another error that
+ -- masks the original one. Return gracefully in that case instead.
+ return
+ end
for _, entity in pairs(luaentity.entities) do
setmetatable(entity, nil)
for _, attached in pairs(entity._attached_entities) do
diff --git a/xban2/README.md b/xban2/README.md
index 90eed0d..75f8e88 100644
--- a/xban2/README.md
+++ b/xban2/README.md
@@ -104,3 +104,9 @@ the supported import plugins at the time of writing:
* `v2`: Old format used by xban (`players.iplist.v2`).
**Example:** `/xban_dbi minetest`
+
+### `xban_cleanup`
+
+Removes all non-banned entries from the xban db.
+
+**Usage:** `/xban_cleanup`
diff --git a/xban2/init.lua b/xban2/init.lua
index 6f15f14..68a3508 100644
--- a/xban2/init.lua
+++ b/xban2/init.lua
@@ -314,6 +314,7 @@ minetest.register_chatcommand("xban_wl", {
end,
})
+
local function check_temp_bans()
minetest.after(60, check_temp_bans)
local to_rm = { }
@@ -374,6 +375,30 @@ local function load_db()
end
end
+minetest.register_chatcommand("xban_cleanup", {
+ description = "Removes all non-banned entries from the xban db",
+ privs = { server=true },
+ func = function(name, params)
+ local old_count = #db
+
+ local i = 1
+ while i <= #db do
+ if not db[i].banned then
+ -- not banned, remove from db
+ table.remove(db, i)
+ else
+ -- banned, hold entry back
+ i = i + 1
+ end
+ end
+
+ -- save immediately
+ save_db()
+
+ return true, "Removed " .. (old_count - #db) .. " entries, new db entry-count: " .. #db
+ end,
+})
+
minetest.register_on_shutdown(save_db)
minetest.after(SAVE_INTERVAL, save_db)
load_db()