updated enemy body part decetion

updated friend alarm notification
removed shaky aiming thru walls
This commit is contained in:
jeefo 2016-02-11 23:07:43 +03:00
commit 6d257e5375
3 changed files with 58 additions and 86 deletions

View file

@ -289,7 +289,7 @@ void NetworkMsg::Execute (void *p)
{
Bot *bot = bots.GetBot (i);
if (bot != NULL && IsAlive (bot->GetEntity ()) && GetTeam (bot->GetEntity ()) == GetTeam (victim) && IsVisible (killer->v.origin, bot->GetEntity ()) && IsEntityNull (bot->m_enemy) && GetTeam (killer) != GetTeam (victim))
if (bot != NULL && bot->m_seeEnemyTime + 2.0f < GetWorldTime () && IsAlive (bot->GetEntity ()) && GetTeam (bot->GetEntity ()) == GetTeam (victim) && IsVisible (killer->v.origin, bot->GetEntity ()) && IsEntityNull (bot->m_enemy) && GetTeam (killer) != GetTeam (victim))
{
bot->m_actualReactionTime = 0.0f;
bot->m_seeEnemyTime = GetWorldTime ();