[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

@ -60,8 +60,8 @@ AggressorAI::MoveInLineOfSight(Unit *u)
}
else if(sMapStore.LookupEntry(m_creature->GetMapId())->IsDungeon())
{
u->SetInCombatWith(m_creature);
m_creature->AddThreat(u, 0.0f);
u->SetInCombatWith(m_creature);
}
}
}
@ -152,13 +152,13 @@ AggressorAI::AttackStart(Unit *u)
if(m_creature->Attack(u,true))
{
m_creature->SetInCombatWith(u);
u->SetInCombatWith(m_creature);
m_creature->AddThreat(u, 0.0f);
// DEBUG_LOG("Creature %s tagged a victim to kill [guid=%u]", m_creature->GetName(), u->GetGUIDLow());
i_victimGuid = u->GetGUID();
m_creature->AddThreat(u, 0.0f);
m_creature->SetInCombatWith(u);
u->SetInCombatWith(m_creature);
m_creature->GetMotionMaster()->MoveChase(u);
}
}