|
@@ -43,12 +43,13 @@ namespace GFGGame
|
|
|
|
|
|
_ui.m_listTab.selectedIndex = 0;
|
|
_ui.m_listTab.selectedIndex = 0;
|
|
_ui.m_listType.selectedIndex = 0;
|
|
_ui.m_listType.selectedIndex = 0;
|
|
|
|
+ _ui.m_loaBg.url = ResPathUtil.GetBgImgPath("zxian_bg3");
|
|
|
|
+
|
|
}
|
|
}
|
|
|
|
|
|
protected override void OnShown()
|
|
protected override void OnShown()
|
|
{
|
|
{
|
|
base.OnShown();
|
|
base.OnShown();
|
|
- _ui.m_loaBg.url = ResPathUtil.GetBgImgPath("fuben_bjbj");
|
|
|
|
|
|
|
|
subType = 0;//MainStoryDataManager.GetChapterSubType(MainStoryDataManager.currentChapterCfgId);
|
|
subType = 0;//MainStoryDataManager.GetChapterSubType(MainStoryDataManager.currentChapterCfgId);
|
|
if (this.viewData != null && (this.viewData as object[]).Length > 0)
|
|
if (this.viewData != null && (this.viewData as object[]).Length > 0)
|
|
@@ -108,17 +109,24 @@ namespace GFGGame
|
|
private void ListChapterItem(int index, GObject item)
|
|
private void ListChapterItem(int index, GObject item)
|
|
{
|
|
{
|
|
UI_ListChapterItem listItem = UI_ListChapterItem.Proxy(item);
|
|
UI_ListChapterItem listItem = UI_ListChapterItem.Proxy(item);
|
|
- if (index % 2 == 0)
|
|
|
|
- {
|
|
|
|
- listItem.m_content.target.y = 102;
|
|
|
|
- }
|
|
|
|
- else
|
|
|
|
- {
|
|
|
|
- listItem.m_content.target.y = 0;
|
|
|
|
- }
|
|
|
|
|
|
+ // if (index % 2 == 0)
|
|
|
|
+ // {
|
|
|
|
+ // listItem.m_content.target.y = 102;
|
|
|
|
+ // }
|
|
|
|
+ // else
|
|
|
|
+ // {
|
|
|
|
+ // listItem.m_content.target.y = 0;
|
|
|
|
+ // }
|
|
StoryChapterCfg chapterCfg = _chapterCfgs[index];
|
|
StoryChapterCfg chapterCfg = _chapterCfgs[index];
|
|
- listItem.m_content.m_txtLv.text = StoryUtil.GetChapterOrder(chapterCfg.id).ToString();
|
|
|
|
- listItem.m_content.m_txtTitle.text = chapterCfg.name;
|
|
|
|
|
|
+ listItem.m_content.m_txtChapterName0.text = chapterCfg.name.Length > 0 ? chapterCfg.name[0].ToString() : "";
|
|
|
|
+ listItem.m_content.m_txtChapterName1.text = chapterCfg.name.Length > 1 ? chapterCfg.name[1].ToString() : "";
|
|
|
|
+ listItem.m_content.m_txtChapterName2.text = chapterCfg.name.Length > 2 ? chapterCfg.name[2].ToString() : "";
|
|
|
|
+ listItem.m_content.m_txtChapterName3.text = chapterCfg.name.Length > 3 ? chapterCfg.name[3].ToString() : "";
|
|
|
|
+ listItem.m_content.m_txtChapterName4.text = chapterCfg.name.Length > 4 ? chapterCfg.name[4].ToString() : "";
|
|
|
|
+ int order = StoryUtil.GetChapterOrder(chapterCfg.id);
|
|
|
|
+ listItem.m_content.m_txtChapter.text = order < 10 ? "0" + order : order.ToString();
|
|
|
|
+
|
|
|
|
+ // listItem.m_content.m_txtTitle.text = chapterCfg.name;
|
|
listItem.m_content.m_compPic.m_pic.url = "ui://Main/" + chapterCfg.res;
|
|
listItem.m_content.m_compPic.m_pic.url = "ui://Main/" + chapterCfg.res;
|
|
if (listItem.m_content.target.data == null)
|
|
if (listItem.m_content.target.data == null)
|
|
{
|
|
{
|
|
@@ -126,7 +134,7 @@ namespace GFGGame
|
|
}
|
|
}
|
|
listItem.target.data = chapterCfg.id;
|
|
listItem.target.data = chapterCfg.id;
|
|
listItem.m_content.target.data = chapterCfg.id;
|
|
listItem.m_content.target.data = chapterCfg.id;
|
|
- RedDotController.Instance.SetComRedDot(listItem.m_content.target, RedDotDataManager.Instance.GetChapterRed(chapterCfg.id), "", 0, (int)listItem.m_content.m_txtProgress.y - 20);
|
|
|
|
|
|
+ RedDotController.Instance.SetComRedDot(listItem.m_content.target, RedDotDataManager.Instance.GetChapterRed(chapterCfg.id), "", 0, (int)listItem.m_content.m_txtCurProgress.y - 20);
|
|
UI_ListChapterItem.ProxyEnd();
|
|
UI_ListChapterItem.ProxyEnd();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -140,7 +148,8 @@ namespace GFGGame
|
|
int chapterID = (int)listItem.target.data;
|
|
int chapterID = (int)listItem.target.data;
|
|
StoryChapterCfg chapterCfg = _chapterCfgs[i];
|
|
StoryChapterCfg chapterCfg = _chapterCfgs[i];
|
|
int starCountChapter = InstanceZonesDataManager.GetChapterStarCount(chapterCfg.id, chapterCfg.type, chapterCfg.subType);
|
|
int starCountChapter = InstanceZonesDataManager.GetChapterStarCount(chapterCfg.id, chapterCfg.type, chapterCfg.subType);
|
|
- listItem.m_content.m_txtProgress.text = "" + starCountChapter + "/" + chapterCfg.bonusStar3;
|
|
|
|
|
|
+ listItem.m_content.m_txtCurProgress.text = starCountChapter.ToString();
|
|
|
|
+ listItem.m_content.m_txtMaxProgress.text = chapterCfg.bonusStar3.ToString();
|
|
if (MainStoryDataManager.CheckChapterUnlock(chapterCfg.id))
|
|
if (MainStoryDataManager.CheckChapterUnlock(chapterCfg.id))
|
|
{
|
|
{
|
|
listItem.m_content.m_imgLock.visible = false;
|
|
listItem.m_content.m_imgLock.visible = false;
|