Пример #1
0
        private static string GetTopMostPriorityCategory(ChallengeCategoryParam[] categories)
        {
            TrophyParam mostPriorityTrophy = ChallengeMission.GetTopMostPriorityTrophy(categories);

            if (mostPriorityTrophy == null)
            {
                return((string)null);
            }
            return(mostPriorityTrophy.Category);
        }
Пример #2
0
        private void Refresh(bool fromRefresh)
        {
            this.mShowingOverlay = false;
            TrophyParam mostPriorityTrophy = ChallengeMission.GetTopMostPriorityTrophy();

            if (mostPriorityTrophy == null)
            {
                return;
            }
            TrophyState trophyCounter = ChallengeMission.GetTrophyCounter(mostPriorityTrophy);

            if (!trophyCounter.IsEnded)
            {
                DataSource.Bind <TrophyParam>(((Component)this).get_gameObject(), mostPriorityTrophy);
                DataSource.Bind <TrophyState>(((Component)this).get_gameObject(), trophyCounter);
                this.RefreshRewardIcon(mostPriorityTrophy);
            }
            if (!((Component)this).get_gameObject().get_activeSelf())
            {
                ((Component)this).get_gameObject().SetActive(true);
            }
            GameParameter.UpdateAll(((Component)this).get_gameObject());
            ChallengeCategoryParam[] challengeCategories = MonoSingleton <GameManager> .Instance.MasterParam.ChallengeCategories;
            if (challengeCategories != null && challengeCategories.Length > 0)
            {
                DataSource.Bind <ChallengeCategoryParam>(((Component)this.HelpIcon).get_gameObject(), ((IEnumerable <ChallengeCategoryParam>)challengeCategories).FirstOrDefault <ChallengeCategoryParam>());
            }
            bool flag = mostPriorityTrophy.IsChallengeMissionRoot || trophyCounter.IsCompleted;

            if (!UnityEngine.Object.op_Inequality((UnityEngine.Object) this.ButtonTry, (UnityEngine.Object)null) || !UnityEngine.Object.op_Inequality((UnityEngine.Object) this.ButtonDetail, (UnityEngine.Object)null) || (!UnityEngine.Object.op_Inequality((UnityEngine.Object) this.ButtonReward, (UnityEngine.Object)null) || !UnityEngine.Object.op_Inequality((UnityEngine.Object) this.ButtonHelp, (UnityEngine.Object)null)))
            {
                return;
            }
            ((Component)this.ButtonTry).get_gameObject().SetActive(!flag);
            ((Component)this.ButtonDetail).get_gameObject().SetActive(!flag);
            ((Component)this.ButtonReward).get_gameObject().SetActive(flag);
            ((Component)this.ButtonHelp).get_gameObject().SetActive(!flag);
        }
Пример #3
0
 public static TrophyParam GetTopMostPriorityTrophy()
 {
     return(ChallengeMission.GetTopMostPriorityTrophy(ChallengeMission.GetOpeningCategory()));
 }
Пример #4
0
 private static string GetTopMostPriorityCategory(ChallengeCategoryParam[] categories)
 {
     return(ChallengeMission.GetTopMostPriorityTrophy(categories)?.Category);
 }