hch
2026-01-26 aa84cb62bebb9c8a4e586bcc1ec28eb7a16a8860
Main/System/HeroUI/HeroTrainWin.cs
@@ -30,6 +30,7 @@
    [SerializeField] HeroConnectionCell connetionForm;  //羁绊
    [SerializeField] Button resetBtn;
    [SerializeField] Button deleteBtn;
    [SerializeField] Transform deleteTip;
    [SerializeField] Button seeLhBtn;   //查看立绘
    [SerializeField] SkillBaseCell normalSkillCell;
    [SerializeField] SkillBaseCell angerSkillCell;
@@ -208,6 +209,7 @@
        {
            functionOrder = 0;
            DisplayTrainOrBreak(hero);
            ForceRefreshLayout();
        });
        breakMainButton.AddListener(() =>
@@ -294,11 +296,23 @@
        RefreshFreeze();
        RefreshRedImg();
        DisplayTrainOrBreak(hero);
        ShowDeleteTip();
        HeroUIManager.Instance.RemoveNewHero(hero.heroId);
        ForceRefreshLayout();
    }
    void ShowDeleteTip()
    {
        deleteTip.SetActive(false);
        if (hero != null && hero.Quality == 1 && HeroUIManager.Instance.IsTheSameHeroFullStar(hero.heroId))
        {
            deleteTip.SetActive(true);
        }
    }
    /// <summary>
    /// 强制刷新Layout,解决嵌套Layout和ContentSizeFitter的重叠问题
@@ -392,8 +406,24 @@
        //     SysNotifyMgr.Instance.ShowTip("UnlockHero");
        //     return;
        // }
        HeroUIManager.Instance.jumpDeleteHeroGuid = guid;
        if (CanDelete())
        {
            HeroUIManager.Instance.jumpDeleteHeroGuid = guid;
        }
        else
        {
            HeroUIManager.Instance.jumpDeleteHeroGuid = "";
        }
        UIManager.Instance.OpenWindow<HeroDeleteWin>();
    }
    bool CanDelete()
    {
        if (hero.isActive)
            return false;
        return HeroUIManager.Instance.IsTheSameHeroFullStar(hero.heroId);
    }
    void RefreshStars()
@@ -793,9 +823,9 @@
        }
    }
    void TeamPosChangeEvent(TeamType teamType)
    void TeamPosChangeEvent(int teamType)
    {
        if (teamType != TeamType.Story)
        if (teamType != TeamManager.Instance.GetMainTeamID())
            return;
        fightPowerText.text = UIHelper.ReplaceLargeArtNum(hero.CalculateFightPower());
    }
@@ -846,7 +876,7 @@
        var itemPack = PackManager.Instance.GetSinglePack(PackType.Item);
        if (heroCnt > 1)
        if (heroCnt > 1 && hero.heroStar < hero.GetCurMaxStar())
        {
            redpointGift.SetActive(true);
            trainMainRedImg.SetActive(true);
@@ -865,14 +895,14 @@
        }
        if (!hero.IsInTeamByTeamType(TeamType.Story))
        if (!hero.IsInTeamByTeamType(BattlePreSetType.Story))
        {
            return;
        }
        //5星后才能觉醒
        if (hero.heroStar >= HeroUIManager.Instance.starLevelCanAwake)
        if (hero.heroStar >= HeroUIManager.Instance.starLevelCanAwake && FuncOpen.Instance.IsFuncOpen((int)FuncOpenEnum.HeroAwake))
        {
            //判断觉醒材料是否足够
            var maxAwakeLV = HeroAwakeConfig.GetMaxAwakeLV(hero.heroId);