Ejemplo n.º 1
0
        /// <summary>
        /// Show alert poup with message.
        /// </summary>
        public static void ShowAlertPopUp(string msg)
        {
            AlertPopUpController alert = Instantiate(Resources.Load <AlertPopUpController>("Prefabs/AlertPopUp"));

            alert.InitAlertPopUp(msg);
            alert.transform.parent     = FindObjectOfType <Canvas>().transform;
            alert.transform.localScale = Vector3.one;
            RectTransform alertRect = alert.GetComponent <RectTransform>();

            alertRect.sizeDelta     = new Vector2(0, 0);
            alertRect.localPosition = new Vector2(0, 0);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Show no ads info pop up.
 /// </summary>
 public void ShowNoAdsInfoPopUp()
 {
     AlertPopUpController.ShowAlertPopUp("After watching rewarded video Ads will be disappear for one game session. Video start from " + DataConfig.Instance.NoAdsRewardAppearDelay + " seconds.");
     StartCoroutine(NoAdsClickedCoroutine());
 }