public override void execute()
	{
		txUIObject window = mReceiver as txUIObject;
		WindowComponentAudio audioComponent = window.getFirstActiveComponent<WindowComponentAudio>();
		if (audioComponent != null)
		{
			string soundName = mSound != SOUND_DEFINE.SD_MAX ? mAudioManager.getAudioName(mSound) : mSoundFileName;
			if (mUseVolumeCoe)
			{
				mVolume *= mAudioManager.getVolumeScale(mSound);
			}
			audioComponent.play(soundName, mLoop, mVolume);
		}
	}
Beispiel #2
0
    public override void execute()
    {
        txUIObject           window         = mReceiver as txUIObject;
        WindowComponentAudio audioComponent = window.getFirstActiveComponent <WindowComponentAudio>();

        if (audioComponent != null)
        {
            string soundName;
            if (mSound != SOUND_DEFINE.SD_MIN)
            {
                soundName = ComponentAudio.getAudioName(mSound);
            }
            else
            {
                soundName = mSoundFileName;
            }
            audioComponent.play(soundName, mLoop, mVolume);
        }
    }