diff options
Diffstat (limited to 'src/game-server/inventory.cpp')
-rw-r--r-- | src/game-server/inventory.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/game-server/inventory.cpp b/src/game-server/inventory.cpp index 532b3f42..4f5e1811 100644 --- a/src/game-server/inventory.cpp +++ b/src/game-server/inventory.cpp @@ -210,6 +210,16 @@ unsigned int Inventory::insert(unsigned int itemId, unsigned int amount) break; } + ItemClass *item = itemManager->getItem(itemId); + if (item) + { + // EVIL HACK!! This allows to prevent sending the item to client. + // We need this hack for money items in lpc! + // REVERT THIS AS SOON AS POSSIBLE + if (item->useTrigger(mCharacter, ITT_IN_INVY)) + return amount; + } + // Send that first, before checking potential removals if (invMsg.getLength() > 2) gameHandler->sendTo(mCharacter, invMsg); |