From a6214a3f1c2b481707700e36410376136ea13b50 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Sun, 19 Mar 2017 21:12:49 +0100 Subject: [PATCH] Add sfinv_buttons support --- depends.txt | 1 + init.lua | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 depends.txt diff --git a/depends.txt b/depends.txt new file mode 100644 index 0000000..84ff3c0 --- /dev/null +++ b/depends.txt @@ -0,0 +1 @@ +sfinv_buttons? diff --git a/init.lua b/init.lua index a04a8e0..d1efb7b 100644 --- a/init.lua +++ b/init.lua @@ -474,4 +474,15 @@ mt.register_craft({ burntime = 10 }) +if mt.get_modpath("sfinv_buttons") then + sfinv_buttons.register_button("craftguide", { + title = "Crafting guide", + tooltip = "Shows a list of available crafting recipes, cooking recipes and fuels", + action = function(player) + craftguide:on_use(nil, player) + end, + image = "craftguide_book.png", + }) +end + mt.register_alias("xdecor:crafting_guide", "craftguide:book")