hch
11 小时以前 ed63aa36ced400b4eef79862e85498213ae40c4a
0312 满星蓝卡提醒可遣散
2个文件已修改
54 ■■■■■ 已修改文件
Main/System/HeroUI/HeroTrainWin.cs 32 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/HeroUI/HeroUIManager.Reborn.cs 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
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;
@@ -295,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的重叠问题
@@ -409,23 +422,8 @@
    {
        if (hero.isAttrActive)
            return false;
        bool isFullStar = false;
        var _list = HeroManager.Instance.GetHeroListByID(hero.heroId);
        foreach (var heroInfo in _list)
        {
            if (heroInfo.heroStar < heroInfo.GetCurMaxStar())
            {
                continue;
            }
            //相同武将中已经有满星的
            isFullStar = true;
            break;
        }
        return isFullStar;
        return HeroUIManager.Instance.IsTheSameHeroFullStar(hero.heroId);
    }
    void RefreshStars()
Main/System/HeroUI/HeroUIManager.Reborn.cs
@@ -266,7 +266,7 @@
        //先计算有没消耗
        rebornParam.Add("heroLV", hero.heroLevel);
        int costCnt = (int)JaceCalculator.Calculate(rebornFormula, rebornParam);
        //重生等级重置的消耗,参数 heroLV武将等级,最终消耗为公式+觉醒消耗
        if (hero.awakeLevel == 0)
        {
@@ -289,7 +289,7 @@
                        //发包
                        SendReborn(hero);
                    }
                }, itemName:$"( {rebornPayBackPer}% )");
                }, itemName: $"( {rebornPayBackPer}% )");
            }
            else
            {
@@ -375,7 +375,7 @@
        }
        if (hero.IsInAnyTeamJustOne())
        {
        {
            //阵容至少要有一个武将上阵
            SysNotifyMgr.Instance.ShowTip("HeroFunc3");
            return false;
@@ -418,5 +418,21 @@
        return true;
    }
    // 同ID武将中有没满星
    public bool IsTheSameHeroFullStar(int heroID)
    {
        var _list = HeroManager.Instance.GetHeroListByID(heroID);
        foreach (var heroInfo in _list)
        {
            if (heroInfo.heroStar < heroInfo.GetCurMaxStar())
            {
                continue;
            }
            //相同武将中已经有满星的
            return true;
        }
        return false;
    }
}