|
@@ -55,14 +55,22 @@ namespace GFGGame
|
|
base.AddEventListener();
|
|
base.AddEventListener();
|
|
EventAgent.AddEventListener(ConstMessage.DOWNLOAD_FINISH, UpdateView);
|
|
EventAgent.AddEventListener(ConstMessage.DOWNLOAD_FINISH, UpdateView);
|
|
EventAgent.AddEventListener(ConstMessage.REQ_CURRENT_RANK, UpdateView);
|
|
EventAgent.AddEventListener(ConstMessage.REQ_CURRENT_RANK, UpdateView);
|
|
|
|
+ EventAgent.AddEventListener(ConstMessage.DOWNLOAD_FINISH, ViewUseCoroutine);
|
|
}
|
|
}
|
|
protected override void RemoveEventListener()
|
|
protected override void RemoveEventListener()
|
|
{
|
|
{
|
|
base.RemoveEventListener();
|
|
base.RemoveEventListener();
|
|
EventAgent.RemoveEventListener(ConstMessage.DOWNLOAD_FINISH, UpdateView);
|
|
EventAgent.RemoveEventListener(ConstMessage.DOWNLOAD_FINISH, UpdateView);
|
|
EventAgent.RemoveEventListener(ConstMessage.REQ_CURRENT_RANK, UpdateView);
|
|
EventAgent.RemoveEventListener(ConstMessage.REQ_CURRENT_RANK, UpdateView);
|
|
|
|
+ EventAgent.RemoveEventListener(ConstMessage.DOWNLOAD_FINISH, ViewUseCoroutine);
|
|
}
|
|
}
|
|
- private void UpdateView()
|
|
|
|
|
|
+
|
|
|
|
+ private void ViewUseCoroutine()
|
|
|
|
+ {
|
|
|
|
+ MatchingCompetitionSproxy.UseCoroutine();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ private void UpdateView()
|
|
{
|
|
{
|
|
//排序
|
|
//排序
|
|
MatchingCompetitionDataManager.Instance._currentRankList.Sort((a, b) =>
|
|
MatchingCompetitionDataManager.Instance._currentRankList.Sort((a, b) =>
|
|
@@ -84,7 +92,7 @@ namespace GFGGame
|
|
|
|
|
|
if(MatchingCompetitionDataManager.Instance._currentRankList.Count > 0)
|
|
if(MatchingCompetitionDataManager.Instance._currentRankList.Count > 0)
|
|
{
|
|
{
|
|
- MatchingPhotoWorksData otherInfo = MatchingCompetitionDataManager.Instance._currentRankList[0];
|
|
|
|
|
|
+ CurRanMatchingPhotoWorksData otherInfo = MatchingCompetitionDataManager.Instance._currentRankList[0];
|
|
_ui.m_playerImage.texture = otherInfo.Ntexture;
|
|
_ui.m_playerImage.texture = otherInfo.Ntexture;
|
|
}
|
|
}
|
|
else
|
|
else
|
|
@@ -104,7 +112,7 @@ namespace GFGGame
|
|
private void RenderRankList(int index, GObject obj)
|
|
private void RenderRankList(int index, GObject obj)
|
|
{
|
|
{
|
|
UI_Component3 item = UI_Component3.Proxy(obj);
|
|
UI_Component3 item = UI_Component3.Proxy(obj);
|
|
- MatchingPhotoWorksData otherdata = MatchingCompetitionDataManager.Instance._currentRankList[index];
|
|
|
|
|
|
+ CurRanMatchingPhotoWorksData otherdata = MatchingCompetitionDataManager.Instance._currentRankList[index];
|
|
JudgingRoundRoleInfo otherInfo = otherdata.JudgingInfo;
|
|
JudgingRoundRoleInfo otherInfo = otherdata.JudgingInfo;
|
|
otherInfo.Rank = index + 1;
|
|
otherInfo.Rank = index + 1;
|
|
RoleInfoManager.Instance.UpdateHead(item.m_head, otherInfo.HeadItemId, otherInfo.HeadBorderItemId);
|
|
RoleInfoManager.Instance.UpdateHead(item.m_head, otherInfo.HeadItemId, otherInfo.HeadBorderItemId);
|
|
@@ -123,7 +131,7 @@ namespace GFGGame
|
|
GObject item = context.sender as GObject;
|
|
GObject item = context.sender as GObject;
|
|
int index = (int)item.data;
|
|
int index = (int)item.data;
|
|
_currentIndex = index;
|
|
_currentIndex = index;
|
|
- MatchingPhotoWorksData otherInfo = MatchingCompetitionDataManager.Instance._currentRankList[index];
|
|
|
|
|
|
+ CurRanMatchingPhotoWorksData otherInfo = MatchingCompetitionDataManager.Instance._currentRankList[index];
|
|
_ui.m_playerImage.texture = otherInfo.Ntexture;
|
|
_ui.m_playerImage.texture = otherInfo.Ntexture;
|
|
}
|
|
}
|
|
private void OnClickBtnBack()
|
|
private void OnClickBtnBack()
|