From 336d16373e0ee120b52128333f9ce33f6934e9aa Mon Sep 17 00:00:00 2001 From: sys4 Date: Fri, 10 May 2019 10:16:44 +0200 Subject: [PATCH] =?UTF-8?q?Supprime=20la=20d=C3=A9pendance=20de=20farming?= =?UTF-8?q?=20devenue=20obsol=C3=A8te=20et=20probl=C3=A9matique?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Moreores est devenue une dépendance de farming afin de définir les hoes en argent et mythril. Les hoes définies par moreores sont donc devenues redondantes. De plus, cela a créé une dépendance circulaire entre les mods farming -> toolranks -> moreores -> farming --- init.lua | 30 ++++++------------------------ mod.conf | 2 +- 2 files changed, 7 insertions(+), 25 deletions(-) diff --git a/init.lua b/init.lua index d3b1cc0..8b4bcfb 100644 --- a/init.lua +++ b/init.lua @@ -195,25 +195,13 @@ local function add_ore(modname, description, mineral_name, oredef) local fulltool_name = tool_base .. tool_name .. tool_post - if tool_name == "hoe" and minetest.get_modpath("farming") then - tdef.max_uses = tooldef.uses - tdef.description = S("%s Hoe"):format(S(description)) - farming.register_hoe(fulltool_name, tdef) - end + minetest.register_tool(fulltool_name, tdef) - -- Hoe registration is handled above. - -- There are no crafting recipes for hoes, as they have been - -- deprecated from Minetest Game: - -- https://github.com/minetest/minetest_game/commit/9c459e77a - if tool_name ~= "hoe" then - minetest.register_tool(fulltool_name, tdef) - - if oredef.makes.ingot then - minetest.register_craft({ - output = fulltool_name, - recipe = get_recipe(ingot, tool_name) - }) - end + if oredef.makes.ingot then + minetest.register_craft({ + output = fulltool_name, + recipe = get_recipe(ingot, tool_name) + }) end minetest.register_alias(tool_name .. tool_post, fulltool_name) @@ -235,9 +223,6 @@ local oredefs = { pick = { cracky = {times = {[1] = 2.60, [2] = 1.00, [3] = 0.60}, uses = 100, maxlevel = 1}, }, - hoe = { - uses = 300, - }, shovel = { crumbly = {times = {[1] = 1.10, [2] = 0.40, [3] = 0.25}, uses = 100, maxlevel = 1}, }, @@ -268,9 +253,6 @@ local oredefs = { pick = { cracky = {times = {[1] = 2.25, [2] = 0.55, [3] = 0.35}, uses = 200, maxlevel = 2} }, - hoe = { - uses = 1000, - }, shovel = { crumbly = {times = {[1] = 0.70, [2] = 0.35, [3] = 0.20}, uses = 200, maxlevel = 2}, }, diff --git a/mod.conf b/mod.conf index 2b96161..1262b58 100644 --- a/mod.conf +++ b/mod.conf @@ -1,4 +1,4 @@ name = moreores description = Adds new ore types. depends = default -optional_depends = farming,intllib,mg +optional_depends = intllib,mg