mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 01:37:37 +01:00
Core/Achievements: ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM should only be counted once for each new item you receive
closes #5065 Signed-off-by: Subv <s.v.h21@hotmail.com>
This commit is contained in:
@@ -11985,6 +11985,7 @@ Item* Player::StoreNewItem(ItemPosCountVec const& dest, uint32 item, bool update
|
||||
{
|
||||
ItemAddedQuestCheck(item, count);
|
||||
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_RECEIVE_EPIC_ITEM, item, count);
|
||||
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM, item, 1);
|
||||
if (randomPropertyId)
|
||||
pItem->SetItemRandomProperties(randomPropertyId);
|
||||
pItem = StoreItem(dest, pItem, update);
|
||||
@@ -12038,7 +12039,6 @@ Item* Player::StoreItem(ItemPosCountVec const& dest, Item* pItem, bool update)
|
||||
|
||||
lastItem = _StoreItem(pos, pItem, count, true, update);
|
||||
}
|
||||
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM, entry, 1);
|
||||
return lastItem;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user