yyl
2026-03-04 bc1cb6da854cb2e9144f10ed55330a537ecdca16
Main/System/Main/MainWin.cs
@@ -40,10 +40,13 @@
    protected override void InitComponent()
    {
        base.InitComponent();
        avatarCell.redpoint.redpointId = MainRedDot.PhantasmPavilionRepoint;
        avatarCell.SetListener(() =>
        avatarCell.SetOnLoaded(() =>
        {
            UIManager.Instance.OpenWindow<PlayerProfileWin>();
            avatarCell.redpoint.redpointId = MainRedDot.PhantasmPavilionRepoint;
            avatarCell.SetListener(() =>
            {
                UIManager.Instance.OpenWindowAsync<PlayerProfileWin>().Forget();
            });
        });
    }
@@ -250,7 +253,7 @@
        else if (index == 4 && !PlayerDatas.Instance.fairyData.HasFairy)
        {
            //未加入公会不切换标签,打开申请界面
            UIManager.Instance.OpenWindow<GuildJoinWin>();
            UIManager.Instance.OpenWindowAsync<GuildJoinWin>().Forget();
            return;
        }
@@ -263,7 +266,7 @@
        if (index == 3)
        {
            //挑战特殊显示逻辑
            UIManager.Instance.OpenWindow<ChallengeTabWin>();
            UIManager.Instance.OpenWindowAsync<ChallengeTabWin>().Forget();
            return;
        }
@@ -304,18 +307,18 @@
                // 打开主页界面
                if (!UIManager.Instance.IsOpened<BattleWin>())
                {
                    BattleWin battleWin = UIManager.Instance.OpenWindow<BattleWin>();
                    battleWin.SetBattleField(BattleManager.Instance.storyBattleField);
                    UIManager.Instance.OpenWindowAsync<BattleWin>().ContinueWith(battleWin =>
                        battleWin.SetBattleField(BattleManager.Instance.storyBattleField)).Forget();
                }
                else
                {
                    BattleWin battleWin = UIManager.Instance.GetUI<BattleWin>();
                    battleWin.SetBattleField(BattleManager.Instance.storyBattleField);
                }
                currentSubUI = UIManager.Instance.OpenWindow<HomeWin>();
                UIManager.Instance.OpenWindowAsync<HomeWin>().ContinueWith(w => currentSubUI = w).Forget();
                break;
            case 1:
                currentSubUI = UIManager.Instance.OpenWindow<AffairBaseWin>();
                UIManager.Instance.OpenWindowAsync<AffairBaseWin>().ContinueWith(w => currentSubUI = w).Forget();
                break;
            case 2:
                if (gameTip.gameObject.activeSelf)
@@ -325,14 +328,14 @@
                        HappyXBModel.Instance.startTenCallGuide = true;
                    }
                }
                currentSubUI = UIManager.Instance.OpenWindow<HeroBaseWin>(0);
                UIManager.Instance.OpenWindowAsync<HeroBaseWin>(0).ContinueWith(w => currentSubUI = w).Forget();
                break;
            // case 3:
            //     挑战界面不跳转
            //     Debug.Log("打开挑战界面");
            //     break;
            case 4:
                currentSubUI = UIManager.Instance.OpenWindow<GuildBaseWin>();
                UIManager.Instance.OpenWindowAsync<GuildBaseWin>().ContinueWith(w => currentSubUI = w).Forget();
                break;
            default:
                Debug.LogWarning("未知的标签索引: " + functionOrder);