Показать сообщение отдельно
Старый 26.06.2013, 12:18
PsixokoT вне форума Посмотреть профиль Отправить личное сообщение для PsixokoT Найти все сообщения от PsixokoT
  № 7  
Ответить с цитированием
PsixokoT

Регистрация: May 2008
Сообщений: 63
Код AS3:
public function removeAllSounds():void
{
	SoundMixer.stopAll();
        var thisSoundChannel:SoundChannel;
 
	while (mSoundChannels.length)
	{
		thisSoundChannel  = mSoundChannels.pop() as SoundChannel;
 
		if (thisSoundChannel)
		{
                        thisSoundChannel.stop(); // остановка звука
			thisSoundChannel.removeEventListener(Event.SOUND_COMPLETE, OnSFXComplete);
		}
	}
        soundTransforms.splice(idx, soundTransforms.length); // soundTransforms = [];
}