public override void onShowed() { Refresh(); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.RANKADDLV, Refresh); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.RANKREFRESH, Refresh); UiEventCenter.getInstance().onWinOpen(uiName); }
public override void onShowed() { RefreshInfos(a3_RankModel.now_id); refreshAch_point(); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.RANKADDLV, onAddLvOver); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.RANKREFRESH, OnRefresh); }
//打开 public override void onShowed() { UIClient.instance.addEventListener(UI_EVENT.ON_MONEY_CHANGE, RefreshBdyb); A3_RankProxy.getInstance().sendProxy(A3_RankProxy.ON_GET_ACHIEVEMENT_PRIZE);//获取玩家成就信息 A3_RankProxy.getInstance().addEventListener(A3_RankProxy.RANKREFRESH, RefreshPage); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.ON_ACHIEVEMENT_CHANGE, OnRefreshPageEvent); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.ON_GET_ACHIEVEMENT_PRIZE, OnShowGetPrize); A3_RankProxy.getInstance().addEventListener(A3_RankProxy.ON_REACH_ACHIEVEMENT, OnRefreshPageEvent); A3_RankProxy.getInstance().sendProxy(A3_RankProxy.ON_GET_ACHIEVEMENT_PRIZE); achModel.OnAchievementChange += OnPointChange; OnPointChange(); base.onShowed(); }
//关闭 public override void onClosed() { A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.RANKREFRESH, RefreshPage); A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.ON_ACHIEVEMENT_CHANGE, OnRefreshPageEvent); A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.ON_GET_ACHIEVEMENT_PRIZE, OnShowGetPrize); A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.ON_REACH_ACHIEVEMENT, OnRefreshPageEvent); UIClient.instance.removeEventListener(UI_EVENT.ON_MONEY_CHANGE, RefreshBdyb); achModel.OnAchievementChange -= OnPointChange; ClearContainer(); scrollPage.StopMovement(); base.onClosed(); }
public override void onShowed() { if (uiData == null) { tc.setSelectedIndex(0, true); } else { int index = (int)uiData[0]; tc.setSelectedIndex(index, true); } GRMap.GAME_CAMERA.SetActive(false); UiEventCenter.getInstance().onWinOpen(uiName); A3_RankProxy.getInstance().sendProxy(A3_RankProxy.ON_GET_ACHIEVEMENT_PRIZE);//获取玩家成就信息 }
void onAddLv(GameObject go) { if (PlayerModel.getInstance().ach_point >= 100) { if (go.name == "upgrade_btn1") { A3_RankProxy.getInstance().sendProxy(A3_RankProxy.RANKADDLV, 1); } else if (go.name == "upgrade_btn2") { A3_RankProxy.getInstance().sendProxy(A3_RankProxy.RANKADDLV, 2); } } else { flytxt.instance.fly(ContMgr.getCont("a3_rank_nomw")); } }
void onShoeorHideTitile(GameObject go) { if (a3_RankModel.now_id > 0) { if (a3_RankModel.nowisactive) { a3_RankModel.nowisactive = false; onShoeorHideTitileTxt.text = ContMgr.getCont("a3_rank_showch"); } else { a3_RankModel.nowisactive = true; onShoeorHideTitileTxt.text = ContMgr.getCont("a3_rank_noshowch"); } A3_RankProxy.getInstance().sendProxy(A3_RankProxy.RANKREFRESH, -1, a3_RankModel.nowisactive); } else { flytxt.instance.fly(ContMgr.getCont("a3_rank_nohave"), 1); } }
public override void onClosed() { A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.RANKADDLV, Refresh); A3_RankProxy.getInstance().removeEventListener(A3_RankProxy.RANKREFRESH, Refresh); }
public void refreshAch_point() { A3_RankProxy.getInstance().sendProxy(A3_RankProxy.RANKREFRESH); ach_num.text = "" + Globle.getBigText((uint)PlayerModel.getInstance().ach_point); }
void onShoeorHideTitile(GameObject go) { A3_RankProxy.getInstance().sendProxy(A3_RankProxy.RANKREFRESH, -1, showontoggle.isOn); a3_RankModel.nowisactive = showontoggle.isOn; Refresh(); }
private void OnGetPrzieClick(GameObject go) { uint id = uint.Parse(go.transform.parent.name); A3_RankProxy.getInstance().GetAchievementPrize(id); }