Exemplo n.º 1
0
    public void PlayVideo()
    {
        m_canvas.SetActive(true);
        StreamVideo stream = m_canvas.GetComponent <StreamVideo>();

        stream.SetAdress(m_videoAdress);
        stream.PlayVideo();
    }
Exemplo n.º 2
0
        public override void Enter()
        {
            levelManager = FindObjectOfType <LevelManager>();
            ui           = context.gameManager.GetUIManager();

            videoStream = levelManager.GetVideoStream();
            if (videoStream != null)
            {
                videoStream.OnVideoEnd += SetupStartGame;
                videoStream.PlayVideo();
            }
            else
            {
                SetupStartGame();
            }
        }
Exemplo n.º 3
0
    void ShowCurrentSubtitles()
    {
        gameObject.SetActive(true);
        text.text        = subtitles[subtitlesId].text;
        audioSource.clip = subtitles[subtitlesId].audio;

        if (subtitles[subtitlesId].audio != null)
        {
            StartCoroutine(HideSubtitles(subtitles[subtitlesId].audio.length + subtitles[subtitlesId].extraTime));
        }
        else
        {
            StartCoroutine(HideSubtitles(subtitles[subtitlesId].extraTime));
        }

        streamVideoScript.PlayVideo(audioSource);
    }