Core/Criteria: Implemented CriteriaType EarnArtifactXP
Port From (https://github.com/TrinityCore/TrinityCore/commit/d1d8f907fe0f1e42d9a8569ef2afdd89e2739b3a)
This commit is contained in:
@@ -2304,6 +2304,7 @@ namespace Game.Entities
|
||||
}
|
||||
|
||||
public void SetArtifactXP(ulong xp) { SetUpdateFieldValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.ArtifactXP), xp); }
|
||||
|
||||
public void GiveArtifactXp(ulong amount, Item sourceItem, ArtifactCategory artifactCategoryId)
|
||||
{
|
||||
Player owner = GetOwner();
|
||||
@@ -2336,6 +2337,8 @@ namespace Game.Entities
|
||||
owner.SendPacket(artifactXpGain);
|
||||
|
||||
SetState(ItemUpdateState.Changed, owner);
|
||||
|
||||
owner.UpdateCriteria(CriteriaType.EarnArtifactXP, amount);
|
||||
}
|
||||
|
||||
public ItemContext GetContext() { return (ItemContext)(int)m_itemData.Context; }
|
||||
|
||||
Reference in New Issue
Block a user