public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
        {
            this.screenData = (DRewardPopupScreenCoinsXP)screenData;
            popupController.RewardPopupAnimator.SetTrigger("ChestDismiss");
            CoinsText.text = string.Format(Service.Get <Localizer>().GetTokenTranslation("GlobalUI.Notification.Coins"), this.screenData.CoinCount);
            if (this.screenData.CoinCount == 0)
            {
                CoinsGO.SetActive(value: false);
            }
            if (this.screenData.XPCount == 0)
            {
                XPGO.SetActive(value: false);
            }
            else
            {
                CoroutineRunner.Start(loadMascotXPPrefab(this.screenData.mascotName), this, "RewardPopupScreenCoinsXP.loadMascotXPPrefab");
            }
            CPDataEntityCollection cPDataEntityCollection = Service.Get <CPDataEntityCollection>();

            if (cPDataEntityCollection.TryGetComponent <MembershipData>(cPDataEntityCollection.LocalPlayerHandle, out var component))
            {
                component.MembershipDataUpdated += onMembershipDataUpdated;
            }
            Service.Get <TrayNotificationManager>().DismissAllNotifications();
            membershipNotificationText = Service.Get <Localizer>().GetTokenTranslation("MemberNotification.RewardScreen.LevelText");
            checkMembershipDisclaimer();
        }
 public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
 {
     this.screenData         = (DRewardPopupScreenCount)screenData;
     RewardCategoryText.text = RewardUtils.GetUnlockText(this.screenData.CountCategory);
     RewardCountText.text    = $"+ {this.screenData.Count}";
     popupController.RewardChest.ChestAnimator.SetTrigger("LaunchItems");
     isIntroComplete = false;
     tweenCountText();
 }
Exemplo n.º 3
0
 public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
 {
     this.screenData         = (DRewardPopupScreenQuests)screenData;
     RewardCategoryText.text = Service.Get <Localizer>().GetTokenTranslation(TITLE_TEXT_KEY);
     isIntroComplete         = false;
     loadItems(this.screenData.quests);
     UnlockedText.SetActive(Service.Get <CPDataEntityCollection>().IsLocalPlayerMember() && !this.screenData.IsRewardsAllNonMember);
     Service.Get <TrayNotificationManager>().DismissAllNotifications();
     membershipNotificationText = Service.Get <Localizer>().GetTokenTranslation("MemberNotification.RewardScreen.QuestText");
     checkMembershipDisclaimer();
 }
Exemplo n.º 4
0
        public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
        {
            controller              = popupController;
            this.screenData         = (DRewardPopupScreenItems)screenData;
            RewardCategoryText.text = RewardUtils.GetUnlockText(this.screenData.ItemCategory);
            popupController.RewardChest.ChestAnimator.SetTrigger("LaunchItems");
            isIntroComplete = false;
            loadItems(this.screenData.ItemCategory, this.screenData.Rewards);
            CPDataEntityCollection cPDataEntityCollection = Service.Get <CPDataEntityCollection>();

            if (cPDataEntityCollection.TryGetComponent <MembershipData>(cPDataEntityCollection.LocalPlayerHandle, out var component))
            {
                component.MembershipDataUpdated += onMembershipDataUpdated;
            }
            checkMembershipDisclaimer();
            showMemberStatusIndicator();
            setBackground();
            UnlockedText.SetActive(Service.Get <CPDataEntityCollection>().IsLocalPlayerMember() && !this.screenData.IsRewardsAllNonMember);
        }
Exemplo n.º 5
0
 public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
 {
     this.popupController = popupController;
     Service.Get <EventDispatcher>().DispatchEvent(default(LevelUpPopupShown));
 }
Exemplo n.º 6
0
 public override void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
 {
     this.screenData      = (DRewardPopupScreenSplash)screenData;
     this.popupController = popupController;
     Service.Get <EventDispatcher>().DispatchEvent(default(RewardPopupSplashShown));
 }
Exemplo n.º 7
0
 public virtual void Init(DRewardPopupScreen screenData, RewardPopupController popupController)
 {
 }