[7723] New AI call EnterCombat called at enter creature to combat (and re-enter if leave by some reason).

This commit is contained in:
VladimirMangos 2009-04-27 03:36:31 +04:00
parent f2f817883a
commit 73db1cbe01
10 changed files with 30 additions and 25 deletions

View file

@ -48,11 +48,12 @@ ReactorAI::AttackStart(Unit *p)
if(m_creature->Attack(p,true))
{
DEBUG_LOG("Tag unit GUID: %u (TypeId: %u) as a victim", p->GetGUIDLow(), p->GetTypeId());
i_victimGuid = p->GetGUID();
m_creature->AddThreat(p, 0.0f);
m_creature->SetInCombatWith(p);
p->SetInCombatWith(m_creature);
m_creature->AddThreat(p, 0.0f);
i_victimGuid = p->GetGUID();
m_creature->GetMotionMaster()->MoveChase(p);
}
}