// Use this for initialization
    void Start()
    {
        vpManager = GameObject.Find("VideoPlayerManager").GetComponent <VideoPlayerManager>();

        while (true)
        {
            ViewLayout = vpManager.getViewLayout();
            if (ViewLayout != 0)
            {
                break;
            }
        }

        for (int i = 0; i < ViewLayout; i++)
        {
            Vp[i] = GameObject.Find(MoviePanelString[i]).GetComponent <VideoPlayer>();
        }
    }
Exemple #2
0
    // Use this for initialization
    void Start()
    {
        vpManager = GameObject.Find("VideoPlayerManager").GetComponent <VideoPlayerManager>();

        while (true)
        {
            ViewLayout = vpManager.getViewLayout();
            if (ViewLayout != 0)
            {
                break;
            }
        }

        for (int i = 0; i < ViewLayout; i++)
        {
            Cam[i]   = GameObject.Find(CameraString[i]).GetComponent <Camera>();
            Sd[i]    = GameObject.Find(SliderString[i]).GetComponent <Slider>();
            FName[i] = GameObject.Find(FNameString[i]).GetComponent <Text>();
            DTime[i] = GameObject.Find(DTimeString[i]).GetComponent <Text>();
            ETime[i] = GameObject.Find(ETimeString[i]).GetComponent <Text>();
            Vp[i]    = GameObject.Find(MoviePanelString[i]).GetComponent <VideoPlayer>();
        }
    }