1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Don't send an InventoryAction at each setInventoryModified, we only need one SendInventory per inventory modification

Client doesn't like to receive multiples SendInventory for one action, this can trigger glitches on clients (sometimes due to incorrect UDP packet ordering due to UDP protocol)

This fix issue #2544
This commit is contained in:
Loic Blot 2015-03-24 09:36:54 +01:00
parent 9fbc3a8ca3
commit 7851c4f7a2
5 changed files with 15 additions and 10 deletions

View file

@ -237,7 +237,7 @@ public:
Shall be called with the environment and the connection locked.
*/
Inventory* getInventory(const InventoryLocation &loc);
void setInventoryModified(const InventoryLocation &loc);
void setInventoryModified(const InventoryLocation &loc, bool playerSend = true);
// Connection must be locked when called
std::wstring getStatusString();