IEnumerator PlayGreetingSound()
    {
        soundSource.PlayOneShot(instrSound.GetInstructionAudioClip(
                                    (int)InstructionSound.InstructionAC.Hello));
        yield return(new WaitWhile(() => soundSource.isPlaying));

        soundSource.PlayOneShot(instrSound.GetInstructionAudioClip(
                                    (int)InstructionSound.InstructionAC.WhatsName));
        //yield return new WaitWhile(() => soundSource.isPlaying);
    }
Esempio n. 2
0
    // Use this for initialization
    void Start()
    {
        //get the game object that has all the instruction audio clips
        instrSound  = GameObject.Find("InstructionSound").GetComponent <InstructionSound>();
        soundSource = GetComponent <AudioSource>();

        soundSource.PlayOneShot(instrSound.GetInstructionAudioClip(InstructionSound.THANKS));
    }
 IEnumerator PlayGreetingSound()
 {
     sound_source.PlayOneShot(instr_sound.GetInstructionAudioClip(InstructionSound.WHATS_LANGUAGE));
     yield return(new WaitWhile(() => sound_source.isPlaying));
 }
 private void PlayInstructionSound()
 {
     soundSource.PlayOneShot(instrSound.GetInstructionAudioClip(
                                 (int)InstructionSound.InstructionAC.WhatsActivity));
     //  StartCoroutine(PlayGreetingSound());
 }
 private void PlayInstructionSound()
 {
     SoundSource.PlayOneShot(instrSound.GetInstructionAudioClip(
                                 (int)InstructionSound.InstructionAC.MemoryInstruction));
 }
 private void PlayInstructionSound()
 {
     _sound_source.PlayOneShot(instr_sound.GetInstructionAudioClip(InstructionSound.RECALL_INSTRUCTION));
 }
Esempio n. 7
0
 public void PlayQuitSound()
 {
     SoundSource.Stop();
     SoundSource.PlayOneShot(instrSound.GetInstructionAudioClip(
                                 (int)InstructionSound.InstructionAC.Thanks));
 }