Add: page click tracking

This commit is contained in:
shivajiva101 2019-03-20 17:15:46 +00:00 committed by GitHub
parent 3e46a5e058
commit 2214768e8e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -144,6 +144,9 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
unified_inventory.current_item[player_name] = clicked_item
unified_inventory.alternate[player_name] = 1
unified_inventory.set_inventory_formspec(player, "craftguide")
elseif unified_inventory.page_click_tracking[page] then
unified_inventory.current_item[player_name] = clicked_item
unified_inventory.set_inventory_formspec(player, page)
elseif player_creative then
local inv = player:get_inventory()
local stack = ItemStack(clicked_item)