From 4d526fd73dfd9cc850bf748dfb524aad9553967d Mon Sep 17 00:00:00 2001 From: Subv Date: Tue, 16 Oct 2012 14:28:41 -0500 Subject: Core/Vendors: Fixed the "Item not found" error message when trying to buy an item from a vendor. --- src/server/game/Handlers/ItemHandler.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/server') diff --git a/src/server/game/Handlers/ItemHandler.cpp b/src/server/game/Handlers/ItemHandler.cpp index eca195e7586..fe0e5098180 100644 --- a/src/server/game/Handlers/ItemHandler.cpp +++ b/src/server/game/Handlers/ItemHandler.cpp @@ -781,7 +781,8 @@ void WorldSession::SendListInventory(uint64 vendorGuid) if (int32 priceMod = _player->GetTotalAuraModifier(SPELL_AURA_MOD_VENDOR_ITEMS_PRICES)) price -= CalculatePct(price, priceMod); - itemsData << uint32(count++ + 1); // client expects counting to start at 1 + ++count; + itemsData << uint32(slot + 1); // client expects counting to start at 1 itemsData << uint32(itemTemplate->MaxDurability); if (vendorItem->ExtendedCost != 0) @@ -812,7 +813,8 @@ void WorldSession::SendListInventory(uint64 vendorGuid) uint32 precision = (currencyTemplate->Flags & CURRENCY_FLAG_HIGH_PRECISION) ? 100 : 1; - itemsData << uint32(count++ + 1); // client expects counting to start at 1 + ++count; + itemsData << uint32(slot + 1); // client expects counting to start at 1 itemsData << uint32(0); // max durability if (vendorItem->ExtendedCost != 0) -- cgit v1.2.3