ignore distance to last enemy
This commit is contained in:
parent
7ee191387a
commit
d1caf7cc48
1 changed files with 3 additions and 6 deletions
|
|
@ -2018,15 +2018,12 @@ void Bot::SetConditions (void)
|
||||||
m_states &= ~STATE_HEARING_ENEMY;
|
m_states &= ~STATE_HEARING_ENEMY;
|
||||||
|
|
||||||
if (IsEntityNull (m_enemy) && !IsEntityNull (m_lastEnemy) && m_lastEnemyOrigin != nullvec)
|
if (IsEntityNull (m_enemy) && !IsEntityNull (m_lastEnemy) && m_lastEnemyOrigin != nullvec)
|
||||||
{
|
|
||||||
if ((pev->origin - m_lastEnemyOrigin).GetLength () < 1600.0f)
|
|
||||||
{
|
{
|
||||||
m_aimFlags |= AIM_PREDICT_PATH;
|
m_aimFlags |= AIM_PREDICT_PATH;
|
||||||
|
|
||||||
if (EntityIsVisible (m_lastEnemyOrigin))
|
if (EntityIsVisible (m_lastEnemyOrigin))
|
||||||
m_aimFlags |= AIM_LAST_ENEMY;
|
m_aimFlags |= AIM_LAST_ENEMY;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
CheckGrenadeThrow ();
|
CheckGrenadeThrow ();
|
||||||
|
|
||||||
// check if there are items needing to be used/collected
|
// check if there are items needing to be used/collected
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue