qbcore-framework / qb-inventory

Slot Based Inventory System Used With QB-Core :school_satchel:
GNU General Public License v3.0
50 stars 377 forks source link

[BUG] OpenInventory loses focus #383

Closed JonasDev17 closed 10 months ago

JonasDev17 commented 1 year ago

Summary

OpenInventory loses focus

Reproduction

Triggering the following event: TriggerServerEvent("inventory:server:OpenInventory", "otherplayer", target)

where target is a players source.

Expected behavior

The inventory of the other players opens where you can move items.

Actual behavior

The inventory opens but loses focus.

The Issue is here: https://github.com/qbcore-framework/qb-inventory/blob/6d6b14e59a7894f7653c1e97362488fc9cab3026/server/main.lua#L1420

closeInv does SetNuiFocus(false, false) but after SetNuiFocus(true, true) of inventory:server:OpenInventory.

One solution which is not very nice but works is add a delay between the events.

Additional context

No response

Last Updated

about 3 weeks ago

Custom Resources

none

Resource Rename

no

XxDeezixX commented 1 year ago

i love the inventory for the qbcore you did. my best one. on the next update you do could you add the inventory weight so we could see how much room we have left in our pockets and car trunks thank you boss keep up the best work

github-actions[bot] commented 11 months ago

This issue has had 60 days of inactivity & will close within 7 days