sp/src/game/server/lab/npc_shadow_walker.cpp
void CNPC_ShadowWalker::FoundEnemySound(void)
{
	if (gpGlobals->curtime > m_flNextFoundEnemySoundTime)
	{
		m_flNextFoundEnemySoundTime = gpGlobals->curtime + random->RandomFloat(MIN_TIME_NEXT_FOUNDENEMY_SOUND, MAX_TIME_NEXT_FOUNDENEMY_SOUND);
		PlaySound(m_iszFoundEnemySound, true);
	}
}
//-----------------------------------------------------------------------------
// Purpose: Play sound when an enemy is spotted. This sound has a separate
//	timer from other sounds to prevent looping if the NPC gets caught
//	in a 'found enemy' condition.
//-----------------------------------------------------------------------------
Play sound when an enemy is spotted. This sound has a separate
timer from other sounds to prevent looping if the NPC gets caught
in a 'found enemy' condition.
Play sound when an enemy is spotted . This sound has a separate timer from other sounds to prevent looping if the NPC gets caught in a ' found enemy ' condition .
void CNPC_ShadowWalker::FoundEnemySound(void)
{
	if (gpGlobals->curtime > m_flNextFoundEnemySoundTime)
	{
		m_flNextFoundEnemySoundTime = gpGlobals->curtime + random->RandomFloat(MIN_TIME_NEXT_FOUNDENEMY_SOUND, MAX_TIME_NEXT_FOUNDENEMY_SOUND);
		PlaySound(m_iszFoundEnemySound, true);
	}
}
void CNPC_ShadowWalker :: FoundEnemySound ( void ) { if ( gpGlobals -> curtime > m_flNextFoundEnemySoundTime ) { m_flNextFoundEnemySoundTime = gpGlobals -> curtime + random -> RandomFloat ( MIN_TIME_NEXT_FOUNDENEMY_SOUND , MAX_TIME_NEXT_FOUNDENEMY_SOUND ) ; PlaySound ( m_iszFoundEnemySound , true ) ; } }
Purpose: Play sound when an enemy is spotted.
Purpose : Play sound when an enemy is spotted .