hch
2026-01-14 1f9e96a4df74d017b39e9ec9a3f91d87b86532d8
287 【公会】BOSS讨伐
2个文件已修改
52 ■■■■■ 已修改文件
Main/System/Guild/GuildBossWin.cs 45 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/Horse/HorseController.cs 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Main/System/Guild/GuildBossWin.cs
@@ -49,7 +49,7 @@
    [SerializeField] Text awardCntText;
    //攻击区
    [SerializeField] UIHeroController bossModel;
    [SerializeField] UIHeroController heroModel;
    [SerializeField] HorseController heroModel;
    [SerializeField] Transform attackArea1;
    [SerializeField] Transform attackArea2;
    [SerializeField] Transform attackArea3;
@@ -90,7 +90,7 @@
        });
        bossModel.Create(GuildBossManager.Instance.bossSkinID, 1, motionName: "chuxian");
        heroModel.Create(PhantasmPavilionManager.Instance.GetMyModelSkinID(), 1.5f);
    }
@@ -193,7 +193,7 @@
            }
        }
        var hasCnt = GuildBossManager.Instance.GetHasAtkCnt();
        if (hasCnt > 0)
        if (hasCnt > 0 || GuildBossManager.Instance.m_Anger >= GuildBossManager.Instance.maxAngerValue)
        {
            addTimesRect.SetActive(false);
        }
@@ -363,7 +363,10 @@
                {
                    if (isOK)
                    {
                        ItemLogicUtility.Instance.UseItem(PackManager.Instance.GetItemGUIDByID(GuildBossManager.Instance.addAtkCntItemID));
                        if (ItemLogicUtility.CheckItemCount(PackType.Item, GuildBossManager.Instance.addAtkCntItemID, 1, 2))
                        {
                            ItemLogicUtility.Instance.UseItem(PackManager.Instance.GetItemGUIDByID(GuildBossManager.Instance.addAtkCntItemID));
                        }
                    }
                });
                return;
@@ -397,8 +400,8 @@
        //1. 玩家从pos1 移动到pos2
        //2. 播放攻击动作 - 显示对应类型特效
        //3. 延迟100毫秒飘血物品
        heroModel.onComplete = null;
        heroModel.PlayAnimation("run");
        heroModel.GetHero().onComplete = null;
        heroModel.PlayAnimation("run", true);
        heroModel.transform.localPosition = pos1.localPosition;
        heroModel.transform.DOLocalMove(pos2.localPosition, 0.3f).OnComplete(() =>
        {
@@ -409,11 +412,11 @@
    async UniTask ShowDmg()
    {
        heroModel.onComplete = () =>
        heroModel.GetHero().onComplete = () =>
        {
            heroModel.transform.localPosition = pos1.localPosition;
        };
        heroModel.PlayAnimation("attack");
        heroModel.HeroPlay("attack");
        if (GuildBossManager.Instance.atkResult.AtkType == 0)
        {
            hurtEffect.Play();
@@ -436,11 +439,14 @@
                int index = i;
                hurtValues[i].transform.localScale = Vector3.one;
                var tween = hurtValues[i].GetComponent<PositionTween>();
                tween.SetStartState();
                tween.Play(() =>
                if (tween.isActiveAndEnabled)
                {
                    hurtValues[index].transform.localScale = Vector3.zero;
                });
                    tween.SetStartState();
                    tween.Play(() =>
                    {
                        hurtValues[index].transform.localScale = Vector3.zero;
                    });
                }
                var hurtData = GuildBossManager.Instance.atkResult.HurtList[i];
                BattleDmg dmg = new BattleDmg()
                {
@@ -462,13 +468,16 @@
            {
                var itemData = GuildBossManager.Instance.atkResult.ItemList[i];
                awardValues[i].transform.localScale = Vector3.one;
                var tween = awardValues[i].GetComponent<PositionTween>();
                tween.SetStartState();
                int index = i;
                tween.Play(() =>
                var tween = awardValues[i].GetComponent<PositionTween>();
                if (tween.isActiveAndEnabled)
                {
                    awardValues[index].transform.localScale = Vector3.zero;
                });
                    tween.SetStartState();
                    tween.Play(() =>
                    {
                        awardValues[index].transform.localScale = Vector3.zero;
                    });
                }
                awardValues[i].text = itemData.Count.ToString();
@@ -485,6 +494,8 @@
    void InitAttack()
    {
        var skinConfig = HorseSkinConfig.Get(HorseManager.Instance.GetUsingHorseSkinID(true));
        heroModel.Create(skinConfig.SkinID, PhantasmPavilionManager.Instance.GetMyModelSkinID(), 1.2f);
        for (int i = 0; i < hurtValues.Length; i++)
        {
            hurtValues[i].transform.localScale = Vector3.zero;
Main/System/Horse/HorseController.cs
@@ -150,12 +150,17 @@
        }
    }
    public void HeroPlay(string motionName, bool loop = false, bool replay=true)
    public void HeroPlay(string motionName, bool loop = false, bool replay = true)
    {
        if (hero == null)
            return;
        hero.PlayAnimation(motionName, loop, replay);
    }
    public UIHeroController GetHero()
    {
        return hero;
    }
    protected void OnDestroy()