fix(Core/Achievements): Fixed showing achievement statistics of inspected player. (#8093)

* fix(Core/Spells): Implemented SPELL_ATTR0_CU_NO_PVP_FLAG.

Fixes #7938

* fix(Core/Achievements): Fixed showing achievement statistics of inspected player.

Fixes #7979
This commit is contained in:
UltraNix
2021-10-03 18:12:12 +02:00
committed by GitHub
parent 396070ee4d
commit 06e50a9690
5 changed files with 33 additions and 29 deletions

View File

@@ -2743,7 +2743,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo* target)
// if target is fallged for pvp also flag caster if a player
// xinef: do not flag spells with aura bind sight (no special attribute)
if (effectUnit->IsPvP() && effectUnit != m_caster && effectUnit->GetOwnerGUID() != m_caster->GetGUID() &&
m_caster->GetTypeId() == TYPEID_PLAYER && !m_spellInfo->HasAura(SPELL_AURA_BIND_SIGHT))
m_caster->GetTypeId() == TYPEID_PLAYER && !m_spellInfo->HasAttribute(SPELL_ATTR0_CU_NO_PVP_FLAG))
{
m_caster->ToPlayer()->UpdatePvP(true);
}
@@ -2830,7 +2830,7 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit* unit, uint32 effectMask, bool scaleA
if (unit->HasUnitState(UNIT_STATE_ATTACK_PLAYER))
{
m_caster->SetContestedPvP();
if (m_caster->GetTypeId() == TYPEID_PLAYER && !m_spellInfo->HasAura(SPELL_AURA_BIND_SIGHT))
if (m_caster->GetTypeId() == TYPEID_PLAYER && !m_spellInfo->HasAttribute(SPELL_ATTR0_CU_NO_PVP_FLAG))
m_caster->ToPlayer()->UpdatePvP(true);
}