[8627] Avoid not needed too oftent send update data, cleanups.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
SilverIce 2009-10-11 19:26:31 +04:00 committed by VladimirMangos
parent 9cb356851c
commit 023b13f348
9 changed files with 29 additions and 75 deletions

View file

@ -565,12 +565,12 @@ void WorldSession::HandleSellItemOpcode( WorldPacket & recv_data )
pItem->SetCount( pItem->GetCount() - count );
_player->ItemRemovedQuestCheck( pItem->GetEntry(), count );
if( _player->IsInWorld() )
pItem->SendUpdateToPlayer( _player );
pItem->SendCreateUpdateToPlayer( _player );
pItem->SetState(ITEM_CHANGED, _player);
_player->AddItemToBuyBackSlot( pNewItem );
if( _player->IsInWorld() )
pNewItem->SendUpdateToPlayer( _player );
pNewItem->SendCreateUpdateToPlayer( _player );
}
else
{