void ReleaseDesignerOutlets()
        {
            if (RewardCategoryName != null)
            {
                RewardCategoryName.Dispose();
                RewardCategoryName = null;
            }

            if (RewardIcon != null)
            {
                RewardIcon.Dispose();
                RewardIcon = null;
            }

            if (RewardItemBackground != null)
            {
                RewardItemBackground.Dispose();
                RewardItemBackground = null;
            }

            if (RewardsCountLabel != null)
            {
                RewardsCountLabel.Dispose();
                RewardsCountLabel = null;
            }
        }
Exemplo n.º 2
0
    public void GetLifes()
    {
        RewardIcon reward = MenuManager.Instance.RewardPopup.GetComponent <RewardIcon>();

        reward.SetIconSprite(1);
        reward.gameObject.SetActive(true);
        InitScript.Instance.RestoreLifes();
        MenuManager.Instance.MenuLifeShop.GetComponent <AnimationManager>().CloseMenu();
    }
Exemplo n.º 3
0
    public void GetCoins(int addCoins)
    {
        RewardIcon reward = MenuManager.Instance.RewardPopup.GetComponent <RewardIcon>();

        reward.SetIconSprite(0);
        reward.gameObject.SetActive(true);
        InitScript.Instance.AddGems(addCoins);
        MenuManager.Instance.MenuCurrencyShop.GetComponent <AnimationManager>().CloseMenu();
    }
Exemplo n.º 4
0
    void CheckRewardedAds()
    {
        RewardIcon reward = GameObject.Find("CanvasGlobal").transform.Find("Reward").GetComponent <RewardIcon>();

        if (currentReward == RewardedAdsType.GetGoOn)
        {
            GameObject.Find("CanvasGlobal").transform.Find("PreFailed").GetComponent <AnimationManager>().GoOnFailed();
        }
    }
Exemplo n.º 5
0
    public void getReward()
    {
        RewardIcon reward = MenuManager.Instance.RewardPopup.GetComponent <RewardIcon> ();

        reward.SetIconSprite(0);
        reward.gameObject.SetActive(true);
        InitScriptName.InitScript.Instance.AddGems(mission.getGift()[0].amount);
        mission.rewarded = true;
        setUI();
    }
Exemplo n.º 6
0
    void CheckRewardedAds()
    {
        RewardIcon reward = GameObject.Find("CanvasGlobal").transform.Find("Reward").GetComponent <RewardIcon> ();

        if (currentReward == RewardedAdsType.GetGems)
        {
            reward.SetIconSprite(0);

            reward.gameObject.SetActive(true);
            AddGems(rewardedGems);
            GameObject.Find("CanvasGlobal").transform.Find("GemsShop").GetComponent <AnimationManager> ().CloseMenu();
        }
        else if (currentReward == RewardedAdsType.GetLifes)
        {
            reward.SetIconSprite(1);
            reward.gameObject.SetActive(true);
            RestoreLifes();
            GameObject.Find("CanvasGlobal").transform.Find("LiveShop").GetComponent <AnimationManager> ().CloseMenu();
        }
        else if (currentReward == RewardedAdsType.GetGoOn)
        {
            GameObject.Find("CanvasGlobal").transform.Find("PreFailed").GetComponent <AnimationManager> ().GoOnFailed();
        }
    }