diff options
Diffstat (limited to 'src/game-server/inventory.cpp')
-rw-r--r-- | src/game-server/inventory.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/game-server/inventory.cpp b/src/game-server/inventory.cpp index bec5961b..e33e94a1 100644 --- a/src/game-server/inventory.cpp +++ b/src/game-server/inventory.cpp @@ -224,7 +224,14 @@ unsigned Inventory::insert(unsigned itemId, unsigned amount) break; } - item->useTrigger(mCharacter, ITT_IN_INVY); + 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) |