forked from mtcontrib/3d_armor
Prevent switching pages when using sfinv
Previously, 3d_armor would issue an inventory update even if the 3d_armor page wasn't shown..
This commit is contained in:
@ -15,7 +15,7 @@ sfinv.register_page("3d_armor:armor", {
|
|||||||
end
|
end
|
||||||
})
|
})
|
||||||
armor:register_on_update(function(player)
|
armor:register_on_update(function(player)
|
||||||
if sfinv.enabled then
|
if sfinv.enabled and sfinv.get_page(player) == "3d_armor:armor" then
|
||||||
sfinv.set_player_inventory_formspec(player)
|
sfinv.set_player_inventory_formspec(player)
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
|
Reference in New Issue
Block a user