public void Init(Hotfix_LT.Data.LostMainChapterTemplate data) { m_ChapterData = data; mDMono.transform.name = m_ChapterData.Id; chapterId = int.Parse(m_ChapterData.Id); newChapterFX.CustomSetActive(false); ContainerObj.CustomSetActive(true); BGSprite.spriteName = m_ChapterData.Icon; if (m_ChapterData.IsBoxRewardType()) { InfoObj.CustomSetActive(false); BoxTipObj.CustomSetActive(true); PerfectObj.CustomSetActive(false); int mForwardChapterId = 0; int.TryParse(m_ChapterData.ForwardChapterId, out mForwardChapterId); BoxLabel.text = string.Format(EB.Localizer.GetString("ID_INSTANCE_MAP_BOX_REWRAD_TIP"), mForwardChapterId % 100); if (LTInstanceUtil.IsChapterComplete(m_ChapterData.ForwardChapterId)) { if (LTInstanceMapModel.Instance.GetMainChapterRewardState(m_ChapterData.Id)) { ContainerObj.CustomSetActive(false); } else { RedPoint.CustomSetActive(true); } } else { RedPoint.CustomSetActive(false); } BGSprite.target.width = 376; BGSprite.target.height = 360; } else { InfoObj.CustomSetActive(true); BoxTipObj.CustomSetActive(false); int allStarNum = LTInstanceUtil.GetChapterCurStarNum(m_ChapterData.Id); int fullStarNum = Hotfix_LT.Data.SceneTemplateManager.Instance.GetLostMainChapterMaxStarNumById(m_ChapterData.Id); PerfectObj.CustomSetActive(LTInstanceUtil.GetChapterIsPerfectComplete(m_ChapterData.Id) && allStarNum == fullStarNum); StarLabel.text = string.Format("{0}{1}/{2}", (allStarNum >= fullStarNum) ? "[42fe76]" : "", allStarNum, fullStarNum); NameLabel.text = m_ChapterData.Name; UpdateRedPoint(); BGSprite.target.width = 360; BGSprite.target.height = 420; } mDMono.transform.localPosition = data.ChapterPos; mDMono.gameObject.CustomSetActive(true); }