diff --git a/README.md b/README.md index c5de679..baa72e0 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # minetest-toolranks-extras This minetest mod adds [toolranks](https://github.com/lisacvuk/minetest-toolranks) support for `minetest-games`’s mods (except `default`). +This mod currently add support for hoes from `farming` mod. +This mod is compatible with [farming redo](https://notabug.org/tenplus1/farming) (nothing breaks if you have both installed). ## License - CC0-1.0, Louis Royer 2020 diff --git a/init.lua b/init.lua index 040e8ea..14dbccd 100644 --- a/init.lua +++ b/init.lua @@ -1,6 +1,12 @@ local MP = minetest.get_modpath("toolranks_extras") -local use_mtg_farming = minetest.get_modpath("farming") +local enable_farming_tools = minetest.settings:get_bool("toolranks_extra.farming", true) +local use_farming = minetest.get_modpath("farming") -if use_mtg_farming and minetest.settings:get_bool("toolranks_extra.farming", true) then +-- farming redo (https://notabug.org/tenplus1/farming) +-- already implements toolranks support +local use_farming_redo = (farming.mod == "redo") + + +if use_farming and (not use_farming_redo) and enable_farming_tools then dofile(MP.."/hoe.lua") end