|
@@ -32,6 +32,8 @@ namespace GFGGame
|
|
|
private GButton _btnField;
|
|
|
private GButton _btnBag;
|
|
|
|
|
|
+ private GButton _btnActivityDay7;
|
|
|
+
|
|
|
|
|
|
private GameObject _effectObj4;
|
|
|
private GoWrapper _wrapper4;
|
|
@@ -52,11 +54,11 @@ namespace GFGGame
|
|
|
private List<GameObject> _effects1 = new List<GameObject>();
|
|
|
private List<GoWrapper> _wrappers1 = new List<GoWrapper>();
|
|
|
private UI_ButtonModle1[] _btns;
|
|
|
+
|
|
|
public override void Dispose()
|
|
|
{
|
|
|
if (_valueBarController != null)
|
|
|
{
|
|
|
-
|
|
|
_valueBarController.Dispose();
|
|
|
_valueBarController = null;
|
|
|
}
|
|
@@ -92,7 +94,6 @@ namespace GFGGame
|
|
|
viewCom = _ui.target;
|
|
|
isfullScreen = true;
|
|
|
_scenePrefab = GFGAsset.Load<GameObject>(ResPathUtil.GetPrefabPath("SceneMain"));
|
|
|
-
|
|
|
}
|
|
|
|
|
|
protected override void OnInit()
|
|
@@ -114,6 +115,8 @@ namespace GFGGame
|
|
|
// _btnStudio = _ui.m_list.GetChild("btnStudio").asButton;
|
|
|
// _btnField = _ui.m_list.GetChild("btnField").asButton;
|
|
|
_btnBag = _ui.m_list.GetChild("btnBag").asButton;
|
|
|
+
|
|
|
+ _btnActivityDay7 = _ui.m_ActivityDay7.asButton;
|
|
|
|
|
|
// _btnGongGao.visible = false;
|
|
|
// _btnHaoYou.visible = false;
|
|
@@ -144,6 +147,7 @@ namespace GFGGame
|
|
|
_btnHaoYou.onClick.Add(OnClickBtnHaoYou);
|
|
|
_btnGongGao.onClick.Add(OnClickBtnGongGao);
|
|
|
_btnRenWu.onClick.Add(OnClickBtnRenWu);
|
|
|
+ _btnActivityDay7.onClick.Add(OnClickBtnDay7);
|
|
|
// _btnStudio.onClick.Add(OnClickBtnStudio);
|
|
|
// _btnField.onClick.Add(OnClickBtnField);
|
|
|
_btnBag.onClick.Add(OnClickBtnBag);
|
|
@@ -164,6 +168,7 @@ namespace GFGGame
|
|
|
// StorageSProxy.ReqSetClientValue(ConstStorageId.STORAGE_GUIDE + cfg.id, 1).Coroutine();
|
|
|
AddEffect();
|
|
|
}
|
|
|
+
|
|
|
protected override void AddEventListener()
|
|
|
{
|
|
|
base.AddEventListener();
|
|
@@ -172,6 +177,7 @@ namespace GFGGame
|
|
|
EventAgent.AddEventListener(ConstMessage.RED_CHANGE, UpdateRedDot);
|
|
|
EventAgent.AddEventListener(ConstMessage.CHANGE_ROLE_HEAD, UpdateHead);
|
|
|
}
|
|
|
+
|
|
|
protected override void OnShown()
|
|
|
{
|
|
|
base.OnShown();
|
|
@@ -194,8 +200,11 @@ namespace GFGGame
|
|
|
_valueBarController.OnShown();
|
|
|
|
|
|
|
|
|
- long lastTime = GameGlobal.lastLoginTime;// GameGlobal.myNumericComponent.GetAsInt(NumericType.OnlineTimeSecs);
|
|
|
- if (!TimeUtil.CheckIsSameTime(lastTime * 1000, TimeHelper.ClientNow()) && ActivityDataManager.Instance.sevenDayLoginBonusStatus == ConstBonusStatus.CAN_GET && GuideDataManager.currentGuideId <= 0)
|
|
|
+ long lastTime =
|
|
|
+ GameGlobal.lastLoginTime; // GameGlobal.myNumericComponent.GetAsInt(NumericType.OnlineTimeSecs);
|
|
|
+ if (!TimeUtil.CheckIsSameTime(lastTime * 1000, TimeHelper.ClientNow()) &&
|
|
|
+ ActivityDataManager.Instance.sevenDayLoginBonusStatus == ConstBonusStatus.CAN_GET &&
|
|
|
+ GuideDataManager.currentGuideId <= 0)
|
|
|
{
|
|
|
ViewManager.Show<SevenDayLoginView>();
|
|
|
GameGlobal.lastLoginTime = GameGlobal.myNumericComponent.GetAsInt(NumericType.OnlineTimeSecs);
|
|
@@ -217,6 +226,7 @@ namespace GFGGame
|
|
|
Timers.inst.Remove(Update);
|
|
|
Timers.inst.Remove(CheckGuide);
|
|
|
}
|
|
|
+
|
|
|
protected override void RemoveEventListener()
|
|
|
{
|
|
|
base.RemoveEventListener();
|
|
@@ -224,8 +234,8 @@ namespace GFGGame
|
|
|
EventAgent.RemoveEventListener(ConstMessage.STORY_LEVEL_CHANGE, CheckFunOpen);
|
|
|
EventAgent.RemoveEventListener(ConstMessage.RED_CHANGE, UpdateRedDot);
|
|
|
EventAgent.RemoveEventListener(ConstMessage.CHANGE_ROLE_HEAD, UpdateHead);
|
|
|
-
|
|
|
}
|
|
|
+
|
|
|
private void AddEffect()
|
|
|
{
|
|
|
// string resPath0 = ResPathUtil.GetViewEffectPath("ui_zjm", "ui_xf_tx");
|
|
@@ -246,13 +256,16 @@ namespace GFGGame
|
|
|
|
|
|
string resPath1 = ResPathUtil.GetViewEffectPath("ui_zjm", "ui_zjm_zzl_d");
|
|
|
string resPath3 = ResPathUtil.GetViewEffectPath("ui_zjm", "ui_zjm_zzl");
|
|
|
- SceneController.AddObjectToView(_effectObj4, _wrapper4, _ui.m_btnMain.m_holder, resPath1, out _effectObj4, out _wrapper4);
|
|
|
- SceneController.AddObjectToView(_effectObj4_1, _wrapper4_1, _ui.m_btnMain.m_holder1, resPath3, out _effectObj4_1, out _wrapper4_1);
|
|
|
+ SceneController.AddObjectToView(_effectObj4, _wrapper4, _ui.m_btnMain.m_holder, resPath1, out _effectObj4,
|
|
|
+ out _wrapper4);
|
|
|
+ SceneController.AddObjectToView(_effectObj4_1, _wrapper4_1, _ui.m_btnMain.m_holder1, resPath3,
|
|
|
+ out _effectObj4_1, out _wrapper4_1);
|
|
|
|
|
|
string resPath4 = ResPathUtil.GetViewEffectPath("ui_zjm", "ui_zjm_jt");
|
|
|
- SceneController.AddObjectToView(_effectObj6, _wrapper6, _ui.m_loaLeft.m_holder, resPath4, out _effectObj6, out _wrapper6);
|
|
|
- SceneController.AddObjectToView(_effectObj7, _wrapper7, _ui.m_loaRight.m_holder, resPath4, out _effectObj7, out _wrapper7);
|
|
|
-
|
|
|
+ SceneController.AddObjectToView(_effectObj6, _wrapper6, _ui.m_loaLeft.m_holder, resPath4, out _effectObj6,
|
|
|
+ out _wrapper6);
|
|
|
+ SceneController.AddObjectToView(_effectObj7, _wrapper7, _ui.m_loaRight.m_holder, resPath4, out _effectObj7,
|
|
|
+ out _wrapper7);
|
|
|
|
|
|
|
|
|
// string resPath2 = ResPathUtil.GetViewEffectPath("ui_zjm", "ui_zjm_tx");
|
|
@@ -269,7 +282,8 @@ namespace GFGGame
|
|
|
Scene.SetActive(true);
|
|
|
Bg.SetActive(true);
|
|
|
Bg1.SetActive(false);
|
|
|
- _ui.m_t3.Play(); ;
|
|
|
+ _ui.m_t3.Play();
|
|
|
+ ;
|
|
|
}
|
|
|
else if (MainDataManager.Instance.ViewType == 1)
|
|
|
{
|
|
@@ -280,21 +294,25 @@ namespace GFGGame
|
|
|
// _sceneObject.transform.position = new Vector2(-GRoot.inst.width / 100f, 0);
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void OnSwipe(EventContext context)
|
|
|
{
|
|
|
if (!MainDataManager.Instance.CanSwipe) return;
|
|
|
if (!FunctionOpenDataManager.Instance.CheckIsFunOpenById(ConstFunctionId.MAIN_SECOND_VIEW, false)) return;
|
|
|
|
|
|
SwipeGesture swipeture = (SwipeGesture)context.sender;
|
|
|
- if (MainDataManager.Instance.ViewType == 0 && swipeture.position.x < 0 && swipeture.position.y < -swipeture.position.x && swipeture.position.y > swipeture.position.x)
|
|
|
+ if (MainDataManager.Instance.ViewType == 0 && swipeture.position.x < 0 &&
|
|
|
+ swipeture.position.y < -swipeture.position.x && swipeture.position.y > swipeture.position.x)
|
|
|
{
|
|
|
MoveLeft();
|
|
|
}
|
|
|
- else if (MainDataManager.Instance.ViewType == 1 && swipeture.position.x > 0 && swipeture.position.y > -swipeture.position.x && swipeture.position.y < swipeture.position.x)
|
|
|
+ else if (MainDataManager.Instance.ViewType == 1 && swipeture.position.x > 0 &&
|
|
|
+ swipeture.position.y > -swipeture.position.x && swipeture.position.y < swipeture.position.x)
|
|
|
{
|
|
|
MoveRight();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void MoveLeft()
|
|
|
{
|
|
|
_ui.target.touchable = false;
|
|
@@ -307,15 +325,16 @@ namespace GFGGame
|
|
|
MainDataManager.Instance.ViewType = 1;
|
|
|
});
|
|
|
}
|
|
|
+
|
|
|
private void ChangeSceneBg(object param)
|
|
|
{
|
|
|
_sceneObject.transform.Find("Scene").gameObject.SetActive(false);
|
|
|
_sceneObject.transform.Find("Bg").gameObject.SetActive(false);
|
|
|
_sceneObject.transform.Find("Bg1").gameObject.SetActive(true);
|
|
|
}
|
|
|
+
|
|
|
private void MoveRight()
|
|
|
{
|
|
|
-
|
|
|
_ui.target.touchable = false;
|
|
|
Timers.inst.Add(0.5f, 1, ChangeSceneBg1);
|
|
|
_ui.m_t2.Play(() =>
|
|
@@ -324,12 +343,14 @@ namespace GFGGame
|
|
|
MainDataManager.Instance.ViewType = 0;
|
|
|
});
|
|
|
}
|
|
|
+
|
|
|
private void ChangeSceneBg1(object param)
|
|
|
{
|
|
|
_sceneObject.transform.Find("Scene").gameObject.SetActive(true);
|
|
|
_sceneObject.transform.Find("Bg").gameObject.SetActive(true);
|
|
|
_sceneObject.transform.Find("Bg1").gameObject.SetActive(false);
|
|
|
}
|
|
|
+
|
|
|
private void OnBtnChangClick()
|
|
|
{
|
|
|
int count = 0;
|
|
@@ -344,10 +365,7 @@ namespace GFGGame
|
|
|
_ui.m_btnChange.m_c1.selectedIndex = 1;
|
|
|
|
|
|
GTween.To(_ui.m_list.height, height, 0.4f).SetTarget(_ui.m_list)
|
|
|
- .OnUpdate((GTweener t) =>
|
|
|
- {
|
|
|
- _ui.m_list.height = t.value.x;
|
|
|
- }).SetEase(EaseType.QuintInOut);
|
|
|
+ .OnUpdate((GTweener t) => { _ui.m_list.height = t.value.x; }).SetEase(EaseType.QuintInOut);
|
|
|
// _ui.m_list.ResizeToFit();
|
|
|
// _ui.m_btnChange.m_c1.selectedIndex = 1;
|
|
|
}
|
|
@@ -356,14 +374,12 @@ namespace GFGGame
|
|
|
_ui.m_btnChange.m_c1.selectedIndex = 0;
|
|
|
|
|
|
GTween.To(_ui.m_list.height, oneItemHeight, 0.4f).SetTarget(_ui.m_list)
|
|
|
- .OnUpdate((GTweener t) =>
|
|
|
- {
|
|
|
- _ui.m_list.height = t.value.x;
|
|
|
- }).SetEase(EaseType.QuintInOut);
|
|
|
+ .OnUpdate((GTweener t) => { _ui.m_list.height = t.value.x; }).SetEase(EaseType.QuintInOut);
|
|
|
// _ui.m_list.height = 0;
|
|
|
// _ui.m_btnChange.m_c1.selectedIndex = 0;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnMain()
|
|
|
{
|
|
|
LogServerHelper.SendPlayParticipationLog((int)PlayParticipationEnum.CHUN_ZHONG_LOU, 1);
|
|
@@ -374,8 +390,10 @@ namespace GFGGame
|
|
|
// {
|
|
|
// _ui.m_btnMain.m_holder1.visible = false;
|
|
|
// this.Hide();
|
|
|
- ViewManager.Show(ViewName.STORY_CHAPTER_LIST_VIEW, null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
- isOpen = false; ;
|
|
|
+ ViewManager.Show(ViewName.STORY_CHAPTER_LIST_VIEW, null,
|
|
|
+ new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
+ isOpen = false;
|
|
|
+ ;
|
|
|
|
|
|
|
|
|
// });
|
|
@@ -430,6 +448,7 @@ namespace GFGGame
|
|
|
|
|
|
// });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnDailyLogin()
|
|
|
{
|
|
|
// if (isOpen) return;
|
|
@@ -447,8 +466,8 @@ namespace GFGGame
|
|
|
ViewManager.Show<SevenDayLoginView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
// isOpen = false;
|
|
|
// });
|
|
|
-
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnDailyWelfare()
|
|
|
{
|
|
|
// if (isOpen) return;
|
|
@@ -466,12 +485,14 @@ namespace GFGGame
|
|
|
ViewManager.Show<DailyWelfareView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
// isOpen = false;
|
|
|
// });
|
|
|
-
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnActivityLuckyBox()
|
|
|
{
|
|
|
- ViewManager.Show<ActivityThemeLuckyBoxView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData }, true);
|
|
|
+ ViewManager.Show<ActivityThemeLuckyBoxView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData },
|
|
|
+ true);
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnCiPai()
|
|
|
{
|
|
|
LogServerHelper.SendPlayParticipationLog((int)PlayParticipationEnum.CI_PAI, 1);
|
|
@@ -494,18 +515,21 @@ namespace GFGGame
|
|
|
{
|
|
|
ViewManager.Show<StudioView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnField()
|
|
|
{
|
|
|
LogServerHelper.SendPlayParticipationLog((int)PlayParticipationEnum.TIAN_YE_DIAO_CHA, 1);
|
|
|
|
|
|
ViewManager.Show<FieldView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnPoem()
|
|
|
{
|
|
|
// LogServerHelper.SendNodeLog((int)PlayParticipationEnum.TIAN_YE_DIAO_CHA, 1);
|
|
|
|
|
|
ViewManager.Show<PoemView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnArena()
|
|
|
{
|
|
|
// LogServerHelper.SendNodeLog((int)PlayParticipationEnum.TIAN_YE_DIAO_CHA, 1);
|
|
@@ -520,12 +544,14 @@ namespace GFGGame
|
|
|
ViewManager.Show<ArenaLoadingView>();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnTravel()
|
|
|
{
|
|
|
// LogServerHelper.SendNodeLog((int)PlayParticipationEnum.TIAN_YE_DIAO_CHA, 1);
|
|
|
|
|
|
ViewManager.Show<TravelView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnBag()
|
|
|
{
|
|
|
ViewManager.Show<BagView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
@@ -540,15 +566,16 @@ namespace GFGGame
|
|
|
// PromptController.Instance.ShowFloatTextPrompt("数据来的有点慢,稍后再试下吧");
|
|
|
// return;
|
|
|
// }
|
|
|
- if (LeagueDataManager.Instance.Type == 1)//已加入联盟
|
|
|
+ if (LeagueDataManager.Instance.Type == 1) //已加入联盟
|
|
|
{
|
|
|
ViewManager.Show<LeagueView>();
|
|
|
}
|
|
|
- else//未加入联盟
|
|
|
+ else //未加入联盟
|
|
|
{
|
|
|
ViewManager.Show<LeagueJoinView>();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnStore()
|
|
|
{
|
|
|
LogServerHelper.SendPlayParticipationLog((int)PlayParticipationEnum.SHANG_CHENG, 1);
|
|
@@ -562,20 +589,23 @@ namespace GFGGame
|
|
|
|
|
|
ViewManager.Show(ViewName.FIELD_GUIDE_VIEW, null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnYouJian()
|
|
|
{
|
|
|
ViewManager.Show<MailView>();
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnHaoYou()
|
|
|
{
|
|
|
-
|
|
|
ViewManager.Show<FriendView>(null, new object[] { ViewName.MAINUI_VIEW, this.viewData }, true);
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnGongGao()
|
|
|
{
|
|
|
// /null, new object[] { ViewName.MAINUI_VIEW, this.viewData }
|
|
|
ViewManager.Show<NoticeView>();
|
|
|
}
|
|
|
+
|
|
|
private void OnClickBtnRenWu()
|
|
|
{
|
|
|
ViewManager.Show<TaskView>(null, new[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
@@ -583,17 +613,23 @@ namespace GFGGame
|
|
|
// LogServerHelper.SendPlayParticipationLog((int)PlayParticipationEnum.MEI_RI_REN_WU, 1);
|
|
|
// ViewManager.Show<DailyTaskView>();
|
|
|
}
|
|
|
+
|
|
|
+ private void OnClickBtnDay7()
|
|
|
+ {
|
|
|
+ ViewManager.Show<ActivityDay7View>(null, new[] { ViewName.MAINUI_VIEW, this.viewData });
|
|
|
+ }
|
|
|
+
|
|
|
private void OnClickHeadBar()
|
|
|
{
|
|
|
ViewManager.Show(ViewName.ROLE_INFO_VIEW);
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
private void Update(object param)
|
|
|
{
|
|
|
ShowExitAlert();
|
|
|
- int activityId = ActivityDataManager.Instance.GetCurOpenActiveByType(ConstLimitTimeActivityType.LimitLuckyBox);
|
|
|
+ int activityId =
|
|
|
+ ActivityDataManager.Instance.GetCurOpenActiveByType(ConstLimitTimeActivityType.LimitLuckyBox);
|
|
|
_ui.m_btnActivityLuckyBox.target.visible = activityId > 0;
|
|
|
if (activityId > 0)
|
|
|
{
|
|
@@ -603,21 +639,22 @@ namespace GFGGame
|
|
|
_luckyBoxActivtyId = activityId;
|
|
|
}
|
|
|
ActivityOpenCfg activityOpenCfg = ActivityOpenCfgArray.Instance.GetCfg(activityId);
|
|
|
- _ui.m_btnActivityLuckyBox.target.title = TimeUtil.FormattingTimeTo_DDHHmm(TimeUtil.DateTimeToTimestamp(activityOpenCfg.endTime) - TimeHelper.ServerNow());
|
|
|
+ _ui.m_btnActivityLuckyBox.target.title =
|
|
|
+ TimeUtil.FormattingTimeTo_DDHHmm(TimeUtil.DateTimeToTimestamp(activityOpenCfg.endTime) -
|
|
|
+ TimeHelper.ServerNow());
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void ShowExitAlert()
|
|
|
{
|
|
|
if (Input.GetKeyDown(KeyCode.Escape) || Input.GetKeyDown(KeyCode.Home))
|
|
|
{
|
|
|
AlertSystem.Show("我会想你的")
|
|
|
- .SetLeftButton(true, "继续游戏")
|
|
|
- .SetRightButton(true, "退出游戏", (object data) =>
|
|
|
- {
|
|
|
- Application.Quit();
|
|
|
- });
|
|
|
+ .SetLeftButton(true, "继续游戏")
|
|
|
+ .SetRightButton(true, "退出游戏", (object data) => { Application.Quit(); });
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void OnNumericChange(EventContext context)
|
|
|
{
|
|
|
if ((int)context.data == NumericType.Lvl)
|
|
@@ -626,6 +663,7 @@ namespace GFGGame
|
|
|
CheckFunOpen();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
private void UpdateRoleLvl()
|
|
|
{
|
|
|
_ui.m_headBar.m_txtLvl.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl);
|
|
@@ -633,49 +671,70 @@ namespace GFGGame
|
|
|
|
|
|
private void UpdateHead()
|
|
|
{
|
|
|
- RoleInfoManager.Instance.UpdateHead(_ui.m_headBar.m_comHead, RoleDataManager.headId, RoleDataManager.headBorderId);
|
|
|
+ RoleInfoManager.Instance.UpdateHead(_ui.m_headBar.m_comHead, RoleDataManager.headId,
|
|
|
+ RoleDataManager.headBorderId);
|
|
|
}
|
|
|
|
|
|
private void CheckFunOpen()
|
|
|
{
|
|
|
- _ui.m_btnXiuFang.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(XiuFangView).Name, false);
|
|
|
- _ui.m_btnHuanZhuang.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(DressUpView).Name, false);
|
|
|
- _ui.m_btnCiPai.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(CardDetailView).Name, false);
|
|
|
- _ui.m_btnZhaiXing.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(LuckyBoxView).Name, false);
|
|
|
- _ui.m_btnMain.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(StoryChapterListView).Name, false);
|
|
|
- _ui.m_btnStudio.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(StudioView).Name, false);
|
|
|
- _ui.m_btnField.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(FieldView).Name, false);
|
|
|
- _ui.m_btnPoem.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(PoemView).Name, false);
|
|
|
- _ui.m_btnTravel.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(TravelView).Name, false);
|
|
|
- _ui.m_btnArena.m_loaLockIcon.visible = !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(ArenaView).Name, false);
|
|
|
- _ui.m_btnActivityLuckyBox.target.visible = ActivityDataManager.Instance.GetCurOpenActiveByType(ConstLimitTimeActivityType.LimitLuckyBox) > 0;
|
|
|
-
|
|
|
- _ui.m_btnDailyLogin.target.visible = !(!FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(SevenDayLoginView).Name, false)
|
|
|
- || (ActivityDataManager.Instance.sevenDayLoginLoginId >= 7 && ActivityDataManager.Instance.sevenDayLoginBonusStatus == ConstBonusStatus.GOT));
|
|
|
- _ui.m_btnDailyWelfare.target.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(DailyWelfareView).Name, false);
|
|
|
+ _ui.m_btnXiuFang.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(XiuFangView).Name, false);
|
|
|
+ _ui.m_btnHuanZhuang.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(DressUpView).Name, false);
|
|
|
+ _ui.m_btnCiPai.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(CardDetailView).Name, false);
|
|
|
+ _ui.m_btnZhaiXing.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(LuckyBoxView).Name, false);
|
|
|
+ _ui.m_btnMain.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(StoryChapterListView).Name, false);
|
|
|
+ _ui.m_btnStudio.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(StudioView).Name, false);
|
|
|
+ _ui.m_btnField.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(FieldView).Name, false);
|
|
|
+ _ui.m_btnPoem.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(PoemView).Name, false);
|
|
|
+ _ui.m_btnTravel.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(TravelView).Name, false);
|
|
|
+ _ui.m_btnArena.m_loaLockIcon.visible =
|
|
|
+ !FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(ArenaView).Name, false);
|
|
|
+ _ui.m_btnActivityLuckyBox.target.visible =
|
|
|
+ ActivityDataManager.Instance.GetCurOpenActiveByType(ConstLimitTimeActivityType.LimitLuckyBox) > 0;
|
|
|
+
|
|
|
+ _ui.m_btnDailyLogin.target.visible =
|
|
|
+ !(!FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(SevenDayLoginView).Name, false)
|
|
|
+ || (ActivityDataManager.Instance.sevenDayLoginLoginId >= 7 &&
|
|
|
+ ActivityDataManager.Instance.sevenDayLoginBonusStatus == ConstBonusStatus.GOT));
|
|
|
+ _ui.m_btnDailyWelfare.target.visible =
|
|
|
+ FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(DailyWelfareView).Name, false);
|
|
|
|
|
|
_btnGongGao.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(NoticeView).Name, false);
|
|
|
_btnHaoYou.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(FriendView).Name, false);
|
|
|
_btnYouJian.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(MailView).Name, false);
|
|
|
_btnLeague.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(LeagueView).Name, false);
|
|
|
_btnStore.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(StoreView).Name, false);
|
|
|
- _btnTuJian.visible = FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(FieldGuideView).Name, false);
|
|
|
-
|
|
|
+ _btnTuJian.visible =
|
|
|
+ FunctionOpenDataManager.Instance.CheckIsFunOpenById(typeof(FieldGuideView).Name, false);
|
|
|
}
|
|
|
+
|
|
|
private void UpdateRedDot()
|
|
|
{
|
|
|
RedDotController.Instance.SetComRedDot(_btnGongGao, RedDotDataManager.Instance.GetNoticeRed());
|
|
|
RedDotController.Instance.SetComRedDot(_btnRenWu, RedDotDataManager.Instance.GetTaskRed());
|
|
|
- RedDotController.Instance.SetComRedDot(_ui.m_btnDailyLogin.target, RedDotDataManager.Instance.GetDailyLoginRed());
|
|
|
+ RedDotController.Instance.SetComRedDot(_ui.m_btnDailyLogin.target,
|
|
|
+ RedDotDataManager.Instance.GetDailyLoginRed());
|
|
|
RedDotController.Instance.SetComRedDot(_btnYouJian, RedDotDataManager.Instance.GetMailRed());
|
|
|
- RedDotController.Instance.SetComRedDot(_btnTuJian, RedDotDataManager.Instance.GetFieldGuideRed() || RedDotDataManager.Instance.GetTravelGuideRed());
|
|
|
+ RedDotController.Instance.SetComRedDot(_btnTuJian,
|
|
|
+ RedDotDataManager.Instance.GetFieldGuideRed() || RedDotDataManager.Instance.GetTravelGuideRed());
|
|
|
RedDotController.Instance.SetComRedDot(_btnHaoYou, RedDotDataManager.Instance.GetFriendRed());
|
|
|
RedDotController.Instance.SetComRedDot(_btnStore, RedDotDataManager.Instance.GetChargeAddUpReward());
|
|
|
- RedDotController.Instance.SetComRedDot(_ui.m_btnField.target, RedDotDataManager.Instance.GetFieldRed(), "", 10);
|
|
|
- RedDotController.Instance.SetComRedDot(_ui.m_btnStudio.target, RedDotDataManager.Instance.GetStudioFilingRed(), "", -38);
|
|
|
- RedDotController.Instance.SetComRedDot(_ui.m_headBar.target, RedDotDataManager.Instance.GetHeadRed() || RedDotDataManager.Instance.GetHeadBorderRed(), "", 5, 7);
|
|
|
- RedDotController.Instance.SetComRedDot(_ui.m_btnTravel.target, RedDotDataManager.Instance.GetTravelRed(), "", -38);
|
|
|
-
|
|
|
+ RedDotController.Instance.SetComRedDot(_ui.m_btnField.target, RedDotDataManager.Instance.GetFieldRed(), "",
|
|
|
+ 10);
|
|
|
+ RedDotController.Instance.SetComRedDot(_ui.m_btnStudio.target,
|
|
|
+ RedDotDataManager.Instance.GetStudioFilingRed(), "", -38);
|
|
|
+ RedDotController.Instance.SetComRedDot(_ui.m_headBar.target,
|
|
|
+ RedDotDataManager.Instance.GetHeadRed() || RedDotDataManager.Instance.GetHeadBorderRed(), "", 5, 7);
|
|
|
+ RedDotController.Instance.SetComRedDot(_ui.m_btnTravel.target, RedDotDataManager.Instance.GetTravelRed(),
|
|
|
+ "", -38);
|
|
|
}
|
|
|
|
|
|
private void CheckGuide(object param)
|
|
@@ -683,14 +742,14 @@ namespace GFGGame
|
|
|
MainDataManager.Instance.CanSwipe = true;
|
|
|
GRoot.inst.touchable = true;
|
|
|
if (GuideDataManager.IsGuideFinish(ConstGuideId.FREEDOM_DRESS) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.CLOTHING_DECOMPOSE) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.CLOTHING_SYNTHETIC) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.UP_CARD_LV) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.ENTER_CHAPTER) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.STUDIO_FILING) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.FIELD) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.STUDIO_METAL) <= 0
|
|
|
- || GuideDataManager.IsGuideFinish(ConstGuideId.SUIT_LIST_VIEW) <= 0)
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.CLOTHING_DECOMPOSE) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.CLOTHING_SYNTHETIC) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.UP_CARD_LV) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.ENTER_CHAPTER) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.STUDIO_FILING) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.FIELD) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.STUDIO_METAL) <= 0
|
|
|
+ || GuideDataManager.IsGuideFinish(ConstGuideId.SUIT_LIST_VIEW) <= 0)
|
|
|
{
|
|
|
UpdateToCheckGuide(null);
|
|
|
}
|
|
@@ -706,21 +765,29 @@ namespace GFGGame
|
|
|
if (!ViewManager.CheckIsTopView(this.viewCom)) return;
|
|
|
if (MainDataManager.Instance.ViewType == 0)
|
|
|
{
|
|
|
- GuideController.TryGuide(_ui.m_btnHuanZhuang.target, ConstGuideId.FREEDOM_DRESS, 2, "在这里,自由搭配服饰和分享哦~", -1, false);
|
|
|
- GuideController.TryGuide(_ui.m_btnMain.target, ConstGuideId.ENTER_CHAPTER, 3, "海市蜃楼,镜花水月,是所有故事开始的地方。", -1, false);
|
|
|
+ GuideController.TryGuide(_ui.m_btnHuanZhuang.target, ConstGuideId.FREEDOM_DRESS, 2, "在这里,自由搭配服饰和分享哦~",
|
|
|
+ -1, false);
|
|
|
+ GuideController.TryGuide(_ui.m_btnMain.target, ConstGuideId.ENTER_CHAPTER, 3, "海市蜃楼,镜花水月,是所有故事开始的地方。",
|
|
|
+ -1, false);
|
|
|
|
|
|
- GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.CLOTHING_DECOMPOSE, 2, "绣坊里增添了新功能。", -1, false);
|
|
|
+ GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.CLOTHING_DECOMPOSE, 2, "绣坊里增添了新功能。", -1,
|
|
|
+ false);
|
|
|
|
|
|
- GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.CLOTHING_SYNTHETIC, 1, "进入绣坊界面。", -1, false);
|
|
|
+ GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.CLOTHING_SYNTHETIC, 1, "进入绣坊界面。", -1,
|
|
|
+ false);
|
|
|
GuideController.TryCompleteGuide(ConstGuideId.CLOTHING_SYNTHETIC, 7);
|
|
|
|
|
|
GuideController.TryGuide(_ui.m_btnCiPai.target, ConstGuideId.UP_CARD_LV, 2, "“词牌”可进行升级和管理。", -1, false);
|
|
|
|
|
|
- GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.SUIT_LIST_VIEW, 1, "获得“天衣”服饰后,可进行养护和焕新,到绣坊看看。");
|
|
|
+ GuideController.TryGuide(_ui.m_btnXiuFang.target, ConstGuideId.SUIT_LIST_VIEW, 1,
|
|
|
+ "获得“天衣”服饰后,可进行养护和焕新,到绣坊看看。");
|
|
|
|
|
|
- bool isStudioMetalGuide = GuideController.TryGuide(null, ConstGuideId.STUDIO_METAL, 2, "向左滑动界面。", -1, false, _ui.target.height - 700);
|
|
|
- bool isStudioFilingGuide = GuideController.TryGuide(null, ConstGuideId.STUDIO_FILING, 2, "向左滑动界面。", -1, false, _ui.target.height - 700);
|
|
|
- bool isFieldGuide = GuideController.TryGuide(null, ConstGuideId.FIELD, 1, "向左滑动界面。", -1, false, _ui.target.height - 700);
|
|
|
+ bool isStudioMetalGuide = GuideController.TryGuide(null, ConstGuideId.STUDIO_METAL, 2, "向左滑动界面。", -1,
|
|
|
+ false, _ui.target.height - 700);
|
|
|
+ bool isStudioFilingGuide = GuideController.TryGuide(null, ConstGuideId.STUDIO_FILING, 2, "向左滑动界面。", -1,
|
|
|
+ false, _ui.target.height - 700);
|
|
|
+ bool isFieldGuide = GuideController.TryGuide(null, ConstGuideId.FIELD, 1, "向左滑动界面。", -1, false,
|
|
|
+ _ui.target.height - 700);
|
|
|
|
|
|
if (isStudioMetalGuide || isStudioFilingGuide || isFieldGuide)
|
|
|
{
|
|
@@ -739,7 +806,6 @@ namespace GFGGame
|
|
|
GuideController.TryGuide(_ui.m_btnStudio.target, ConstGuideId.STUDIO_FILING, 3, "工作室有新的任务啦。");
|
|
|
GuideController.TryGuide(_ui.m_btnField.target, ConstGuideId.FIELD, 2, "外出进行历史考察,会有意想不到的收获哦。");
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
}
|
|
|
}
|