Esempio n. 1
0
 void Awake()
 {
     gameOver   = ModalPanelControl.Instance();
     watchVideo = ModalPanelAskForWatchVideo.Instance();
     UnityAdsButton.AdsOnComplet = false;
     wasAskedToWatch             = false;
 }
Esempio n. 2
0
    public static ModalPanelAskForWatchVideo Instance()
    {
        if (!modalPanel)
        {
            modalPanel = FindObjectOfType(typeof(ModalPanelAskForWatchVideo)) as ModalPanelAskForWatchVideo;
            if (!modalPanel)             // Make sure that Modalpanel existes.
            {
                Debug.Log("There needs to be one active ModalPanelAskForWatchVideo Script on a GameObject in your scene");
            }
        }

        return(modalPanel);
    }