fix(Core): do not start combat with pet's current victim on spell hit if it's not in combat (#7293)

- Closes #7247
This commit is contained in:
UltraNix
2021-08-14 13:51:26 +02:00
committed by GitHub
parent 6ff9b21b73
commit 004af40cc0

View File

@@ -2786,10 +2786,7 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit* unit, uint32 effectMask, bool scaleA
// xinef: triggered spells should not prolong combat
if (unit->IsInCombat() && !m_spellInfo->HasAttribute(SPELL_ATTR3_SUPRESS_TARGET_PROCS) && !m_triggeredByAuraSpell)
{
// xinef: start combat with hostile unit...
if (Unit* hostile = unit->getAttackerForHelper())
m_caster->CombatStart(hostile, true);
//m_caster->SetInCombatState(unit->GetCombatTimer() > 0, unit);
m_caster->SetInCombatState(unit->GetCombatTimer() > 0, unit);
unit->getHostileRefManager().threatAssist(m_caster, 0.0f);
}
}