Add button for Unified Inventory

master
Wuzzy 2016-07-30 02:13:12 +02:00
parent 6a4ff6a8f5
commit 95eb6d9909
2 changed files with 13 additions and 1 deletions

View File

@ -0,0 +1 @@
unified_inventory?

View File

@ -787,7 +787,7 @@ ltool.treeform = ltool.formspec_size..ltool.formspec_header(1)..ltool.tab_edit()
minetest.register_chatcommand("treeform",
{
params = "",
description = "Open L-system tree builder formular.",
description = "Open L-System Tree Utility.",
privs = {},
func = function(playername, param)
ltool.show_treeform(playername)
@ -1232,3 +1232,14 @@ minetest.register_on_leaveplayer(ltool.leave)
minetest.register_on_joinplayer(ltool.join)
minetest.register_on_shutdown(ltool.save_to_file)
if minetest.get_modpath("unified_inventory") ~= nil then
unified_inventory.register_button("ltool", {
type = "image",
image = "ltool_sapling.png",
tooltip = "L-System Tree Utility",
action = function(player)
ltool.show_treeform(player:get_player_name())
end,
})
end