From d580288402fa834f89ed8be0da8bd75e88b24d02 Mon Sep 17 00:00:00 2001 From: luk3yx Date: Tue, 2 Apr 2019 20:06:28 +1300 Subject: [PATCH] Add unified_inventory support --- menu.lua | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/menu.lua b/menu.lua index e18b37a..1cf99e3 100644 --- a/menu.lua +++ b/menu.lua @@ -263,7 +263,7 @@ if mymenu then end -if sfinv_menu then +if minetest.global_exists("sfinv_menu") then sfinv_menu.register_button("multichat:menu", { title = S("Bate-Papo"), icon = "multichat_botao.png", @@ -272,3 +272,14 @@ if sfinv_menu then end, }) end + +if minetest.global_exists("unified_inventory") then + unified_inventory.register_button("multichat:menu", { + type = "image", + image = "multichat_botao.png", + tooltip = S("Bate-Papo"), + action = function(player) + multichat.acessar_menu(player:get_player_name()) + end, + }) +end