コード例 #1
0
        // Token: 0x06008FBA RID: 36794 RVA: 0x0029D3E4 File Offset: 0x0029B5E4
        private void SetOpenServiceMissionState(bool hasGot)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_SetOpenServiceMissionStateBoolean_hotfix != null)
            {
                this.m_SetOpenServiceMissionStateBoolean_hotfix.call(new object[]
                {
                    this,
                    hasGot
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            ProjectLPlayerContext projectLPlayerContext = GameManager.Instance.PlayerContext as ProjectLPlayerContext;
            long missionCompleteProcess = projectLPlayerContext.GetMissionCompleteProcess(this.Mission);
            long num = (long)projectLPlayerContext.GetMissionMaxProcess(this.Mission);

            if (hasGot)
            {
                this.m_buttonGroupStateCtrl.SetToUIState("Got", false, true);
                this.m_progressBar.fillAmount = 1f;
                this.m_progressBarValueStateCtrl.SetToUIState("White", false, true);
                this.m_progressHaveCount.text = num.ToString();
                this.m_progressNeedCount.text = num.ToString();
                this.m_progressDoneText.SetActive(true);
            }
            else
            {
                if (missionCompleteProcess < num)
                {
                    this.m_buttonGroupStateCtrl.SetToUIState("Go", false, true);
                }
                else
                {
                    this.m_buttonGroupStateCtrl.SetToUIState("CanGet", false, true);
                }
                this.m_progressBar.fillAmount = (float)missionCompleteProcess / (float)num;
                if (missionCompleteProcess < num)
                {
                    this.m_progressBarValueStateCtrl.SetToUIState("Red", false, true);
                }
                else
                {
                    this.m_progressBarValueStateCtrl.SetToUIState("White", false, true);
                }
                this.m_progressHaveCount.text = missionCompleteProcess.ToString();
                this.m_progressNeedCount.text = num.ToString();
                this.m_progressDoneText.SetActive(missionCompleteProcess >= num);
            }
        }