diff options
Diffstat (limited to 'src/net')
-rw-r--r-- | src/net/ea/inventoryhandler.cpp | 11 | ||||
-rw-r--r-- | src/net/ea/inventoryhandler.h | 2 | ||||
-rw-r--r-- | src/net/inventoryhandler.h | 2 |
3 files changed, 15 insertions, 0 deletions
diff --git a/src/net/ea/inventoryhandler.cpp b/src/net/ea/inventoryhandler.cpp index f3c8040e1..ea7390ccb 100644 --- a/src/net/ea/inventoryhandler.cpp +++ b/src/net/ea/inventoryhandler.cpp @@ -486,6 +486,11 @@ void InventoryHandler::processPlayerStorageClose(Net::MessageIn &msg A_UNUSED) { // Storage access has been closed // Storage window deletes itself + if (mStorageWindow) + { + mStorageWindow->unsetInventory(); + mStorageWindow->close(); + } mStorageWindow = nullptr; if (mStorage) @@ -592,9 +597,15 @@ void InventoryHandler::closeStorage() { if (mStorageWindow) { + mStorageWindow->unsetInventory(); mStorageWindow->close(); mStorageWindow = nullptr; } } +void InventoryHandler::forgotStorage() +{ + mStorageWindow = nullptr; +} + } // namespace Ea diff --git a/src/net/ea/inventoryhandler.h b/src/net/ea/inventoryhandler.h index ac88c1d6c..4546b75bb 100644 --- a/src/net/ea/inventoryhandler.h +++ b/src/net/ea/inventoryhandler.h @@ -210,6 +210,8 @@ class InventoryHandler : public Net::InventoryHandler void closeStorage() override final; + void forgotStorage() override final; + Inventory *getStorage() const { return mStorage; } diff --git a/src/net/inventoryhandler.h b/src/net/inventoryhandler.h index 53e7d15b1..42649bae6 100644 --- a/src/net/inventoryhandler.h +++ b/src/net/inventoryhandler.h @@ -71,6 +71,8 @@ class InventoryHandler virtual void closeStorage() = 0; + virtual void forgotStorage() = 0; + virtual int convertFromServerSlot(const int eAthenaSlot) const = 0; }; |