[10676] Fix repeating looting for milling/prospecting.

This commit is contained in:
VladimirMangos 2010-11-03 01:51:55 +03:00
parent cb5a666ce3
commit 62c0963f37
2 changed files with 8 additions and 1 deletions

View file

@ -430,6 +430,10 @@ void WorldSession::DoLootRelease(ObjectGuid lguid)
if(count > 5)
count = 5;
// reset loot for allow repeat looting if stack > 5
pItem->loot.clear();
pItem->SetLootState(ITEM_LOOT_REMOVED);
player->DestroyItemCount(pItem, count, true);
break;
}
@ -446,7 +450,10 @@ void WorldSession::DoLootRelease(ObjectGuid lguid)
{
// must be destroyed only if no loot
if (pItem->loot.isLooted())
{
pItem->SetLootState(ITEM_LOOT_REMOVED);
player->DestroyItem( pItem->GetBagSlot(),pItem->GetSlot(), true);
}
break;
}
}