mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[7737] Implement ACHIEVEMENT_CRITERIA_TYPE_LOOT_TYPE.
Zone dependent achievement criteria required DB support. Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
b22b603c0e
commit
dba73b611d
6 changed files with 62 additions and 24 deletions
|
|
@ -141,6 +141,7 @@ void WorldSession::HandleAutostoreLootItemOpcode( WorldPacket & recv_data )
|
|||
|
||||
player->SendNewItem(newitem, uint32(item->count), false, false, true);
|
||||
player->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_LOOT_ITEM, item->itemid, item->count);
|
||||
player->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_LOOT_TYPE, loot->loot_type, item->count);
|
||||
}
|
||||
else
|
||||
player->SendEquipError( msg, NULL, NULL );
|
||||
|
|
@ -497,6 +498,7 @@ void WorldSession::HandleLootMasterGiveOpcode( WorldPacket & recv_data )
|
|||
Item * newitem = target->StoreNewItem( dest, item.itemid, true, item.randomPropertyId );
|
||||
target->SendNewItem(newitem, uint32(item.count), false, false, true );
|
||||
target->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_LOOT_ITEM, item.itemid, item.count);
|
||||
target->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_LOOT_TYPE, pLoot->loot_type, item.count);
|
||||
|
||||
// mark as looted
|
||||
item.count=0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue