/** 再生。 */ public void PlayOneShot(long a_id, int a_index) { Fee.Audio.Bank t_bank = this.GetBank(a_id); if (t_bank != null) { float t_data_volume = 0.0f; UnityEngine.AudioClip t_audioclip = null; string t_name = null; t_bank.GetAudioClip(a_index, out t_audioclip, out t_data_volume); if (t_audioclip != null) { this.audiosource[0].SetAudioClip(t_audioclip); this.audiosource[0].SetDataVolume(t_data_volume); this.audiosource[0].ApplyVolume(); this.audiosource[0].PlayOneShot(); } else { t_bank.GetSoundPool(a_index, out t_name, out t_data_volume); if (t_name != null) { Fee.SoundPool.SoundPool.GetInstance().GetPlayer().Play(t_name, this.volume.CalcAudioSourceVolume() * t_data_volume); } } } }
/** 再生。 */ public void PlayOneShot(long a_id, int a_index) { Fee.Audio.Bank t_bank = this.GetBank(a_id); if (t_bank != null) { float t_volume = 0.0f; UnityEngine.AudioClip t_audioclip = null; string t_name = null; t_bank.GetAudioClip(a_index, out t_audioclip, out t_volume); if (t_audioclip != null) { this.myaudiosource.PlayOneShot(t_audioclip, this.volume_master.GetVolume() * this.volume_se.GetVolume() * t_volume); } else { t_bank.GetSoundPool(a_index, out t_name, out t_volume); if (t_name != null) { Fee.Audio.Audio.GetInstance().GetSoundPool().Play(t_name, this.volume_master.GetVolume() * this.volume_se.GetVolume() * t_volume); } } } }