diff options
Diffstat (limited to 'unified_inventory/callbacks.lua')
-rw-r--r-- | unified_inventory/callbacks.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/unified_inventory/callbacks.lua b/unified_inventory/callbacks.lua index ad6de0a..e6ea3e7 100644 --- a/unified_inventory/callbacks.lua +++ b/unified_inventory/callbacks.lua @@ -43,7 +43,7 @@ minetest.register_on_joinplayer(function(player) minetest.sound_play("electricity", {to_player=player_name, gain = 1.0}) end, - }) + }, player_name) refill:set_size("main", 1) end) @@ -154,7 +154,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) end end - if fields.searchbutton then + if fields.searchbutton + or fields.key_enter_field == "searchbox" then unified_inventory.apply_filter(player, unified_inventory.current_searchbox[player_name], "nochange") unified_inventory.set_inventory_formspec(player, unified_inventory.current_page[player_name]) |