From 4a0b45f472ddb63545ee795055ad81fe5ffbb9b5 Mon Sep 17 00:00:00 2001 From: Juraj Vajda Date: Sun, 26 Feb 2023 10:34:18 -0500 Subject: [PATCH 1/2] 3 Add support for item_drop mod --- README.md | 1 + mod.conf | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 22939ae..62e938a 100644 --- a/README.md +++ b/README.md @@ -178,6 +178,7 @@ end ## Optional Dependencies - xdecor (adjusts conflicting recipe) +- item_drop (make sure fortune will execute before item_drop mod overrides `handle_node_drops`) ## License: diff --git a/mod.conf b/mod.conf index 24bb8a3..a8c0b1f 100644 --- a/mod.conf +++ b/mod.conf @@ -1,6 +1,6 @@ name = x_enchanting description = Adds Enchanting Mechanics and API. depends = -optional_depends = xdecor +optional_depends = xdecor, item_drop supported_games = minetest_game min_minetest_version = 5.4 From c5c53b63eeb2f9d409d6e008c6ec4e2c89b88d64 Mon Sep 17 00:00:00 2001 From: Juraj Vajda Date: Sun, 26 Feb 2023 10:42:06 -0500 Subject: [PATCH 2/2] 3 Fix indentation --- api.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/api.lua b/api.lua index 8932f7d..7bae93f 100644 --- a/api.lua +++ b/api.lua @@ -309,9 +309,9 @@ end ---Find element v of t satisfying f(v) local function tableFind(t, f) for _, v in ipairs(t) do - if f(v) then - return v - end + if f(v) then + return v + end end return nil