From ad8309638a4149fdda2a24e8d25e411b3dee69f2 Mon Sep 17 00:00:00 2001 From: Jordan Irwin Date: Tue, 29 Aug 2017 13:23:57 -0700 Subject: [PATCH] [bags] Update to Git patch f275dc0: https://github.com/AntumMT/mod-bags/tree/f275dc0 --- README.md | 3 ++- mods/inventory/bags/init.lua | 20 +++++++++++--------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 4a9984d5..9c20279b 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m * [waffles][] ([CC0][lic.cc0]) -- version [b02ffbf Git][ver.waffles] *2017-08-04* * [intllib][] ([Unlicense][lic.unlicense]) -- version: [7b818cb Git][ver.intllib] *2017-07-10* * inventory/ - * [bags][] ([BSD 3-Clause][lic.bags]) -- version: [8a02b4d Git][ver.bags] *2017-08-07* + * [bags][] ([BSD 3-Clause][lic.bags]) -- version: [8a02b4d Git][ver.bags] *2017-08-07* ([patched][patch.bags]) * [sfinv_buttons][] ([MIT][lic.mit]) -- version [1.0.0 (4f3b075 Git)][ver.sfinv_buttons] *2017-03-19* * lighting/ * [glow][] ([GPL][lic.gpl2.0]) -- version: [c611ae0 Git][ver.glow] *2017-07-18* @@ -484,6 +484,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m [patch.airtanks]: https://github.com/AntumMT/mod-airtanks/tree/71ea616 [patch.awards]: https://github.com/AntumMT/mod-awards/tree/638c137 [patch.away]: https://github.com/AntumMT/mod-away/tree/3b0bf9e +[patch.bags]: https://github.com/AntumMT/mod-bags/tree/f275dc0 [patch.bedrock2]: https://github.com/AntumMT/mod-bedrock2/tree/344fdae [patch.biome_lib]: https://github.com/AntumMT/mod-biome_lib/tree/4e95b1e [patch.boats2]: https://github.com/AntumMT/mod-boats2/tree/9b2bcb7 diff --git a/mods/inventory/bags/init.lua b/mods/inventory/bags/init.lua index 743df489..a824b8da 100644 --- a/mods/inventory/bags/init.lua +++ b/mods/inventory/bags/init.lua @@ -78,17 +78,19 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) end end) +if use_sfinv then + sfinv_buttons.register_button("bags", { + title = "Bags", + action = function(player) + player:set_inventory_formspec(get_formspec(player, "bags")) + end, + image = "bags_small.png", + }) +end + -- register_on_joinplayer minetest.register_on_joinplayer(function(player) - if use_sfinv then - sfinv_buttons.register_button("bags", { - title = "Bags", - action = function(player) - player:set_inventory_formspec(get_formspec(player, "bags")) - end, - image = "bags_small.png", - }) - else + if not use_sfinv then inventory_plus.register_button(player,"bags","Bags") end