void C_SoundscapeSystem::Shutdown()
{
	for ( int i = m_loopingSounds.Count() - 1; i >= 0; --i )
	{
		loopingsound_t &sound = m_loopingSounds[i];

		// sound is done, remove from list.
		StopLoopingSound( sound );
	}
	
	// These are only necessary so we can use shutdown/init calls
	// to flush soundscape data
	m_loopingSounds.RemoveAll();
	m_randomSounds.RemoveAll();
	m_soundscapes.RemoveAll();
	m_params.ent.Set( NULL );
	m_params.soundscapeIndex = -1;

	while ( m_SoundscapeScripts.Count() > 0 )
	{
		KeyValues *kv = m_SoundscapeScripts[ 0 ];
		m_SoundscapeScripts.Remove( 0 );
		kv->deleteThis();
	}
}
Exemplo n.º 2
0
void CAudio::StopAllChannels (void)
{
#if 1
StopLoopingSound ();
StopObjectSounds ();
#endif
for (int i = 0; i < MAX_SOUND_CHANNELS; i++)
	audio.StopSound (i);
gameData.multiplayer.bMoving = -1;
gameData.weapons.firing [0].bSound = 0;
soundQueue.Init ();
}
Exemplo n.º 3
0
void CSkaterLoopingSoundComponent::Suspend ( bool suspend )
{
	CBaseComponent::Suspend(suspend);
	
	if (suspend)
	{
		StopLoopingSound();
	}
	else
	{
		m_update_sound_info = true;
	}
}
Exemplo n.º 4
0
CSkaterLoopingSoundComponent::~CSkaterLoopingSoundComponent()
{
	StopLoopingSound();
}