Beispiel #1
0
    public void QueueAudio(AudioClip audioFile, EAudioType type, UAP_GenericCallback callbackOnDone = null, EInterrupt interruptsAudioTypes = EInterrupt.None, bool isInterruptible = true)
    {
        //Debug.Log("playing " + audioFile.name);
        // Build struct and call internal add function
        SAudioEntry newEntry = new SAudioEntry();

        newEntry.m_Audio           = audioFile;
        newEntry.m_AudioType       = type;
        newEntry.m_IsInterruptible = isInterruptible;
        newEntry.m_CallbackOnDone  = callbackOnDone;
        QueueAudio(newEntry, interruptsAudioTypes);
    }
Beispiel #2
0
    //////////////////////////////////////////////////////////////////////////

    public void QueueAudio(string textForTTS, EAudioType type, bool allowVoiceOver, UAP_GenericCallback callbackOnDone = null, EInterrupt interruptsAudioTypes = EInterrupt.None, bool isInterruptible = true)
    {
        //Debug.Log("speaking " + textForTTS);
        // Build struct and call internal add function
        SAudioEntry newEntry = new SAudioEntry();

        newEntry.m_TTS_Text        = textForTTS;
        newEntry.m_AllowVoiceOver  = allowVoiceOver;
        newEntry.m_AudioType       = type;
        newEntry.m_IsInterruptible = isInterruptible;
        newEntry.m_CallbackOnDone  = callbackOnDone;
        QueueAudio(newEntry, interruptsAudioTypes);
    }