少年修仙传客户端代码仓库
client_Wu Xijin
2018-09-10 34c01f30d2e26aa76a0ee0a5a06664a25ef3fe5a
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
10个文件已修改
535 ■■■■■ 已修改文件
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0405_tagPlayerDisappear.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0434_tagAreaPlayerAppearEx.cs 18 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Fight/GameActor/GAMgr.cs 85 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Fight/GameActor/GA_Player.cs 269 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Chat/ChatCtrl.cs 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasureAnimation.cs 71 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasurePotentialBriefInfo.cs 31 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasurePotentialLines.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasurePotentialPanel.cs 45 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasureSoulWin.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0405_tagPlayerDisappear.cs
@@ -30,6 +30,9 @@
            {
                GAMgr.Instance.ServerDie(vNetData.Players[i]);
                GAMgr.Instance.Release(_actor);
                // 离线玩家
                GAMgr.Instance.RemoveOffLinePlayer(vNetData.Players[i]);
            }
            else
            {
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0434_tagAreaPlayerAppearEx.cs
@@ -1,8 +1,10 @@
using UnityEngine;
using System.Collections;
//04 34 周围玩家出现合并封包#tagAreaPlayerAppearEx
//04 34 周围玩家出现合并封包#tagAreaPlayerAppearEx
public class DTC0434_tagAreaPlayerAppearEx : DtcBasic
{
    public override void Done(GameNetPackBasic vNetPack)
@@ -21,6 +23,12 @@
        if (_player != null)
        {
            // 异常
        }
        // 离线玩家
        if (vNetData.State == 1)
        {
            GAMgr.Instance.AddOffLinePlayer(vNetData.PlayerID);
        }
        _player = GAMgr.Instance.RequestPlayer<GA_Player>(vNetData.PlayerID, E_ActorGroup.Player, vNetData);
@@ -70,5 +78,7 @@
            StatusMgr.Instance.Request(_h0605);
        }
    }
}
}
Fight/GameActor/GAMgr.cs
@@ -63,6 +63,8 @@
    // 客户端id对应相应角色
    private Dictionary<uint, GActor> m_Cid2GA;
    private List<uint> m_OffLineList;
    // 服务端通知的死亡目标对应的客户端id,
    // 这里为了处理可能出现的无法死亡现象,对每一只目标进行计时,强制其死亡
    private List<uint> serverDeadList = new List<uint>();
@@ -85,10 +87,91 @@
            m_AllList = new List<GActor>();
            m_Sid2Cid = new Dictionary<uint, uint>();
            m_Cid2GA = new Dictionary<uint, GActor>();
            m_OffLineList = new List<uint>();
            m_Inited = true;
            SystemSetting.Instance.playerSyncCountChangeEvent += OnPlayerSyncCountChange;
            SystemSetting.Instance.OnSettingChanged += OnSettingChanged;
        }
    }
    public void AddOffLinePlayer(uint sid)
    {
        if (m_OffLineList.Contains(sid))
        {
            return;
        }
        m_OffLineList.Add(sid);
    }
    public void RemoveOffLinePlayer(uint sid)
    {
        if (m_OffLineList.Contains(sid))
        {
            m_OffLineList.Remove(sid);
        }
    }
    public void ClearOffLinePlayer()
    {
        m_OffLineList.Clear();
    }
    private float m_UpdateOffLineInterval;
    private List<uint> m_CacheList = new List<uint>();
    private List<uint> m_ContaintList = new List<uint>();
    private void UpdateOffLinePlayer()
    {
        if (m_OffLineList == null || m_OffLineList.Count == 0)
        {
            return;
        }
        if (Time.realtimeSinceStartup - m_UpdateOffLineInterval > 2)
        {
            m_CacheList.Clear();
            m_ContaintList.Clear();
            int _count = Mathf.Min(m_OffLineList.Count, 4);
            //Debug.LogFormat("此次将会有: {0} 个挂机者释放技能", _count);
            for (int i = 0; i < m_OffLineList.Count; ++i)
            {
                m_CacheList.Add(m_OffLineList[i]);
            }
            int _time = 0;
            while (m_ContaintList.Count < _count)
            {
                int _index = UnityEngine.Random.Range(0, m_CacheList.Count);
                m_ContaintList.Add(m_CacheList[_index]);
                //Debug.LogFormat("添加对象: {0}, 已添加: {1} 个", m_CacheList[_index], m_ContaintList.Count);
                m_CacheList.RemoveAt(_index);
                if (_time > _count)
                {
                    //Debug.LogFormat("共添加了: {0} 个玩家", m_ContaintList.Count);
                    break;
                }
                _time++;
            }
            GA_Player _player = null;
            for (int i = 0; i < m_ContaintList.Count; ++i)
            {
                _player = GAMgr.Instance.GetBySID(m_ContaintList[i]) as GA_Player;
                if (_player == null)
                {
                    continue;
                }
                _player.UpdateOffLineAction();
            }
            m_UpdateOffLineInterval = Time.realtimeSinceStartup;
        }
    }
@@ -838,6 +921,8 @@
        {
            m_AllList[i].Update();
        }
        UpdateOffLinePlayer();
    }
    public void DoLateUpdate()
Fight/GameActor/GA_Player.cs
@@ -9,23 +9,16 @@
    // 为守护特殊定义的当前是否装备守护id
    public int serverGuardId;
    // 简易的脱机挂AI草稿
    // 步骤 1. 寻点 2. 移动至 3. 放个普攻
    private byte m_Step;
    private Vector3 m_DestPos;
    private Vector3 m_RecordBornPos;
    private float m_WaitTime;
    public static UnityAction<uint, bool> s_OnSelected;
    public static UnityAction<uint, ulong, ulong> s_OnRefreshLife;
    private H0434_tagAreaPlayerAppearEx m_H0434;
    protected H0434_tagAreaPlayerAppearEx m_H0434;
    private CmdManager m_CmdManager;
    private int m_ComAtkIndex;// 普攻索引
    private Skill m_CastSkill;// 要释放的技能
    protected sealed override void OnInit(GameNetPackBasic package)
    private int m_ComAtkIndex;// 普攻索引
    protected override void OnInit(GameNetPackBasic package)
    {
        m_H0434 = package as H0434_tagAreaPlayerAppearEx;
@@ -157,12 +150,6 @@
        RequestName();
        m_CmdManager = new CmdManager();
        if (m_H0434.State == 1)
        {
            m_RecordBornPos = Pos;
            m_Step = 0;
        }
    }
    protected sealed override void OnUnit()
@@ -183,151 +170,13 @@
    {
    }
    protected sealed override void OnUpdate()
    protected override void OnUpdate()
    {
        base.OnUpdate();
        if (m_CmdManager != null)
        {
            m_CmdManager.Update();
        }
        // 脱机挂
        if (m_H0434.State == 1)
        {
            switch (m_Step)
            {
                case 0:
                    //m_DestPos = m_RecordBornPos + Quaternion.Euler(0, Random.Range(0, 359), 0) * Vector3.forward * Random.Range(1f, 2f);
                    //TryGetValidPos(m_DestPos, ref m_DestPos);
                    if (SelectTarget == null)
                    {
                        SelectTarget = GAMgr.Instance.GetCloserFightNpc(Pos);
                    }
                    if (SelectTarget != null)
                    {
                        destForward = Forward = MathUtility.ForwardXZ(SelectTarget.Pos, Pos);
                    }
                    m_Step = 1;
                    break;
                case 1:
                    m_CastSkill = null;
                    for (int i = 0; i < JobSetup.HangupSkillList.Length; ++i)
                    {
                        if (SkillMgr.Get(JobSetup.HangupSkillList[i]).IsValid())
                        {
                            m_CastSkill = SkillMgr.Get(JobSetup.HangupSkillList[i]);
                            break;
                        }
                    }
                    if (m_CastSkill == null)
                    {
                        if (m_ComAtkIndex > JobSetup.ComAtkIdList.Length - 1)
                        {
                            m_ComAtkIndex = 0;
                        }
                        int _comSkillId = JobSetup.ComAtkIdList[m_ComAtkIndex];
                        m_CastSkill = SkillMgr.Get(_comSkillId);
                        m_ComAtkIndex += 1;
                    }
                    m_Step = 2;
                    break;
                case 2:
                    if (m_CastSkill != null)
                    {
                        SkillMgr.CastSkill(ServerInstID, m_CastSkill.id, true);
                        Vector3 _targetPosition = Pos + Forward * (m_CastSkill.skillInfo.config.AtkDist * .5f);
                        _targetPosition.y = 0;
                        UnityEngine.AI.NavMeshHit _navMeshHit;
                        if (UnityEngine.AI.NavMesh.Raycast(Pos, _targetPosition, out _navMeshHit, -1))
                        {
                            _targetPosition = _navMeshHit.position;
                        }
                        _targetPosition.y = Pos.y;
                        m_CastSkill.targetPosition = _targetPosition;
                        if (m_CastSkill.skillInfo.config.Skillactmark > 0
                         && m_CastSkill.skillInfo.config.Skillactmark < 20)
                        {
                            switch (m_CastSkill.skillInfo.config.Skillactmark)
                            {
                                case 10:
                                    Play(GAStaticDefine.State_Attack1Hash, 0);
                                    break;
                                case 11:
                                    Play(GAStaticDefine.State_Attack2Hash, 0);
                                    break;
                                case 12:
                                    Play(GAStaticDefine.State_Attack3Hash, 0);
                                    break;
                                case 13:
                                    Play(GAStaticDefine.State_Attack4Hash, 0);
                                    break;
                            }
                        }
                        else
                        {
                            switch (m_CastSkill.skillInfo.config.Skillactmark)
                            {
                                case 21:
                                    Play(GAStaticDefine.State_Skill21, 0);
                                    break;
                                case 22:
                                    Play(GAStaticDefine.State_Skill22, 0);
                                    break;
                                case 23:
                                    Play(GAStaticDefine.State_Skill23, 0);
                                    break;
                                case 24:
                                    Play(GAStaticDefine.State_Skill24, 0);
                                    break;
                                case 25:
                                    Play(GAStaticDefine.State_Skill25, 0);
                                    break;
                                case 26:
                                    Play(GAStaticDefine.State_Skill26, 0);
                                    break;
                                case 27:
                                    Play(GAStaticDefine.State_Skill27, 0);
                                    break;
                                case 28:
                                    Play(GAStaticDefine.State_Skill28, 0);
                                    break;
                                case 29:
                                    Play(GAStaticDefine.State_Skill29, 0);
                                    break;
                                case 99:
                                    Play(GAStaticDefine.State_RollHash, 0);
                                    break;
                            }
                        }
                    }
                    m_Step = 3;
                    break;
                case 3:
                    if (IsIdle())
                    {
                        m_Step = 0;
                    }
                    break;
            }
        }
    }
@@ -695,4 +544,112 @@
    {
        m_CmdManager.Clear();
    }
    public void UpdateOffLineAction()
    {
        if (!IsIdle())
        {
            return;
        }
        if (SelectTarget == null)
        {
            SelectTarget = GAMgr.Instance.GetCloserFightNpc(Pos);
        }
        if (SelectTarget != null)
        {
            destForward = Forward = MathUtility.ForwardXZ(SelectTarget.Pos, Pos);
        }
        Skill _castSkill = null;
        int _skillIndex = UnityEngine.Random.Range(0, JobSetup.HangupSkillList.Length);
        if (SkillMgr.Get(JobSetup.HangupSkillList[_skillIndex]).IsValid())
        {
            _castSkill = SkillMgr.Get(JobSetup.HangupSkillList[_skillIndex]);
        }
        if (_castSkill == null)
        {
            if (m_ComAtkIndex > JobSetup.ComAtkIdList.Length - 1)
            {
                m_ComAtkIndex = 0;
            }
            int _comSkillId = JobSetup.ComAtkIdList[m_ComAtkIndex];
            _castSkill = SkillMgr.Get(_comSkillId);
            m_ComAtkIndex += 1;
        }
        if (_castSkill != null)
        {
            SkillMgr.CastSkill(ServerInstID, _castSkill.id, true);
            Vector3 _targetPosition = Pos + Forward * (_castSkill.skillInfo.config.AtkDist * .5f);
            _targetPosition.y = 0;
            UnityEngine.AI.NavMeshHit _navMeshHit;
            if (UnityEngine.AI.NavMesh.Raycast(Pos, _targetPosition, out _navMeshHit, -1))
            {
                _targetPosition = _navMeshHit.position;
            }
            _targetPosition.y = Pos.y;
            _castSkill.targetPosition = _targetPosition;
            if (_castSkill.skillInfo.config.Skillactmark > 0
             && _castSkill.skillInfo.config.Skillactmark < 20)
            {
                switch (_castSkill.skillInfo.config.Skillactmark)
                {
                    case 10:
                        Play(GAStaticDefine.State_Attack1Hash, 0);
                        break;
                    case 11:
                        Play(GAStaticDefine.State_Attack2Hash, 0);
                        break;
                    case 12:
                        Play(GAStaticDefine.State_Attack3Hash, 0);
                        break;
                    case 13:
                        Play(GAStaticDefine.State_Attack4Hash, 0);
                        break;
                }
            }
            else
            {
                switch (_castSkill.skillInfo.config.Skillactmark)
                {
                    case 21:
                        Play(GAStaticDefine.State_Skill21, 0);
                        break;
                    case 22:
                        Play(GAStaticDefine.State_Skill22, 0);
                        break;
                    case 23:
                        Play(GAStaticDefine.State_Skill23, 0);
                        break;
                    case 24:
                        Play(GAStaticDefine.State_Skill24, 0);
                        break;
                    case 25:
                        Play(GAStaticDefine.State_Skill25, 0);
                        break;
                    case 26:
                        Play(GAStaticDefine.State_Skill26, 0);
                        break;
                    case 27:
                        Play(GAStaticDefine.State_Skill27, 0);
                        break;
                    case 28:
                        Play(GAStaticDefine.State_Skill28, 0);
                        break;
                    case 29:
                        Play(GAStaticDefine.State_Skill29, 0);
                        break;
                    case 99:
                        Play(GAStaticDefine.State_RollHash, 0);
                        break;
                }
            }
        }
    }
}
System/Chat/ChatCtrl.cs
@@ -257,7 +257,8 @@
        ChatReport(type, msg, PteChatName);
        if (!ChatCenter.s_VoiceRegex.IsMatch(msg))
        if (!ChatCenter.s_VoiceRegex.IsMatch(msg)
            && !InviteRegex.IsMatch(msg))
        {
            _dirty = DirtyWordConfig.IsDirtWord(msg);
            msg = DirtyWordConfig.IsDirtWord(msg, '*');
System/Treasure/TreasureAnimation.cs
@@ -48,6 +48,7 @@
        }
        #region const
        const int POTENTIALUNLOCKSFX = 5190;
        public const int SPIRALSFX = 5126;
        const int CONVERGESFX = 5127;
        public const float LINE_NORMAL_LENGTH = 187f;
@@ -81,6 +82,7 @@
        public event Action OnAchievementTweenComplete;
        public event Action<int> OnUnlockPotentialComplete;
        public event Action<int> OnPotentialLevelUpComplete;
        public event Action<int> OnPotentialLineAnimComplete;
        TreasureShowStep m_Step = TreasureShowStep.None;
        TreasureShowStep m_BeforeStep = TreasureShowStep.None;
@@ -151,29 +153,29 @@
        IEnumerator Co_PotentialLevelUp(int _index, int level)
        {
            yield return StartCoroutine(Co_PotentialSpiral(_index));
            yield return StartCoroutine(Co_PotentialSpiral(_index, SPIRALSFX));
            if (displayTreasure != model.selectedTreasure)
            {
                stepComplete = true;
                yield break;
            }
            UIEffect effect = null;
            if (level == 1)
            {
                effect = EffectMgr.Instance.PlayUIEffect(POTENTIAL_LINESFX, 2100, transform, false);
                if (effect == null)
                {
                    stepComplete = true;
                    yield break;
                }
                effect.keep = true;
                effect.maskArea = m_PotentialLineMasks[_index];
                effect.SetMask();
                yield return StartCoroutine(Co_DisplayPotentialLine(_index,effect));
            }
            //UIEffect effect = null;
            //if (level == 1)
            //{
            //    effect = EffectMgr.Instance.PlayUIEffect(POTENTIAL_LINESFX, 2100, transform, false);
            //    if (effect == null)
            //    {
            //        stepComplete = true;
            //        yield break;
            //    }
            //    effect.keep = true;
            //    effect.maskArea = m_PotentialLineMasks[_index];
            //    effect.SetMask();
            //    yield return StartCoroutine(Co_DisplayPotentialLine(_index,effect));
            //}
            if (displayTreasure != model.selectedTreasure)
            {
                StopPotentialLineEffect(effect);
                //StopPotentialLineEffect(effect);
                stepComplete = true;
                yield break;
            }
@@ -182,8 +184,34 @@
                OnPotentialLevelUpComplete(_index);
            }
            stepComplete = true;
            yield return null;
            //yield return null;
            //StopPotentialLineEffect(effect);
        }
        public void DisplayPotentialLine(int _index)
        {
            stepComplete = false;
            StartCoroutine(Co_PotentialLineAnim(_index));
        }
        IEnumerator Co_PotentialLineAnim(int _index)
        {
            UIEffect effect = EffectMgr.Instance.PlayUIEffect(POTENTIAL_LINESFX, 2100, transform, false);
            if (effect == null)
            {
                stepComplete = true;
                yield break;
            }
            effect.keep = true;
            effect.maskArea = m_PotentialLineMasks[_index];
            effect.SetMask();
            yield return StartCoroutine(Co_DisplayPotentialLine(_index, effect));
            stepComplete = true;
            StopPotentialLineEffect(effect);
            if (OnPotentialLineAnimComplete != null)
            {
                OnPotentialLineAnimComplete(_index);
            }
        }
        private void StopPotentialLineEffect(UIEffect _effect)
@@ -197,9 +225,9 @@
            }
        }
        IEnumerator Co_PotentialSpiral(int _index)
        IEnumerator Co_PotentialSpiral(int _index, int effectId)
        {
            var effect = EffectMgr.Instance.PlayUIEffect(SPIRALSFX, 2700, m_TreasurePotentials[_index].transform, false);
            var effect = EffectMgr.Instance.PlayUIEffect(effectId, 2700, m_TreasurePotentials[_index].transform, false);
            var duration = effect.duration;
            var _time = 0f;
            while (_time < duration)
@@ -252,7 +280,8 @@
        IEnumerator Co_UnlockTreasurePotential(int _index)
        {
            yield return StartCoroutine(Co_PotentialSpiral(_index));
            StartCoroutine(Co_PotentialSpiral(_index, POTENTIALUNLOCKSFX));
            yield return WaitingForSecondConst.WaitMS600;
            if (displayTreasure != model.selectedTreasure)
            {
                stepComplete = true;
@@ -765,11 +794,11 @@
                m_PotentialPointSclTweens[_index].Play();
                m_PotentialPointSclTweens[_index].SetEndState();
            }
            stepComplete = true;
            if (OnStepComplete != null)
            {
                OnStepComplete(TreasureShowStep.FirstPotential);
            }
            stepComplete = true;
        }
        private void OnEnterPotential()
System/Treasure/TreasurePotentialBriefInfo.cs
@@ -19,6 +19,7 @@
        [SerializeField] Button m_Button;
        [SerializeField] UIEffect m_PotentialSfx;
        [SerializeField] Image m_Select;
        [SerializeField] Image m_Icon;
        //[SerializeField] ScaleTween m_SelectScale;
        public TreasurePotential potential { get; private set; }
@@ -63,7 +64,8 @@
            }
            m_Level.text = _unlock ? StringUtility.Contact(_potential.level, "/", maxLevel) : string.Empty;
            m_Level.transform.localScale = Vector3.one;
            m_PotentialName.text = config.SkillName;// _unlock ? config.SkillName : string.Empty;
            DisplayName(_unlock, config);
            model.potentialLevelChangeEvent -= OnPotentialLevelUp;
            model.potentialLevelChangeEvent += OnPotentialLevelUp;
@@ -97,19 +99,30 @@
            bool _unlock = potential != null && model.IsPotentialUnlock(model.selectedTreasure, potential.id);
            m_Level.text = _unlock ? StringUtility.Contact(potential.level, "/", maxLevel) : string.Empty;
            m_Level.transform.localScale = Vector3.one;
            m_PotentialName.text = config.SkillName;// _unlock ? config.SkillName : string.Empty;
            DisplayName(_unlock, config);
        }
        void DisplayName(bool unlock, SkillConfig config)
        {
            m_PotentialName.text = config.SkillName;
            m_PotentialName.color = UIHelper.GetUIColor(TextColType.LightYellow);
            if (!unlock)
            {
                var requirement = string.Empty;
                if (config.LearnSkillReq > 0 && config.LearnSkillLV > 0)
                {
                    var preskillConfig = Config.Instance.Get<SkillConfig>(config.LearnSkillReq);
                    requirement = Language.Get("Hallows_NeedSkillLVStart", preskillConfig.SkillName, config.LearnSkillLV);
                    m_PotentialName.text = requirement;
                    m_PotentialName.color = UIHelper.GetUIColor(TextColType.Red);
                }
            }
        }
        public void OnPotentialSelected(int _potentialId)
        {
            //m_SelectScale.SetEndState();
            m_Select.gameObject.SetActive(_potentialId == potential.id);
        }
        //public void DisplaySelectSfxScale()
        //{
        //    m_SelectScale.Play();
        //}
        private void OnPotentialLevelUp(int _treasureId, int _potential)
        {
@@ -128,10 +141,12 @@
            m_PotentialSfx.loop = true;
            m_DeadPotentailTween.enabled = false;
            m_DeadPotentailTween.SetStartState();
            m_Icon.material = MaterialUtility.GetUIDefaultGraphicMaterial();
            switch (_state)
            {
                case 0:
                    m_DeadPotentailTween.enabled = true;
                    m_Icon.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
                    break;
                case 1:
                    m_PotentialSfx.effect = 5128;
System/Treasure/TreasurePotentialLines.cs
@@ -29,6 +29,14 @@
                / TreasureAnimation.LINE_NORMAL_LENGTH * TreasureAnimation.LINE_NORMAL_SCALE);
            animator.Play(TreasureAnimation.POTENTIAL_LINE_STATE_2, 0, 0);
        }
        public void Dispose()
        {
            for (int i = 0; i < m_Lines.Length; i++)
            {
                m_Lines[i].StopImediatly();
            }
        }
    }
}
System/Treasure/TreasurePotentialPanel.cs
@@ -160,7 +160,10 @@
                    behaviour.gameObject.SetActive(true);
                    behaviour.treasurePotential = this;
                    behaviour.DisplayBaseInfo(m_Treasure.potentials[i], _state);
                    m_PotentialLine.Display(i, m_Treasure.potentials[i].level >= 1);
                    if (_state != 2 && m_TreasureAnimation.step == TreasureAnimation.TreasureShowStep.UnLock)
                    {
                        m_PotentialLine.Display(i, model.IsPotentialUnlock(m_Treasure.id, m_Treasure.potentials[i].id));
                    }
                }
                else
                {
@@ -220,6 +223,9 @@
            m_TreasureAnimation.OnPotentialLevelUpComplete -= OnPotentialLevelUpComplete;
            m_TreasureAnimation.OnPotentialLevelUpComplete += OnPotentialLevelUpComplete;
            m_TreasureAnimation.OnPotentialLineAnimComplete -= OnPotentialLineAnimComplete;
            m_TreasureAnimation.OnPotentialLineAnimComplete += OnPotentialLineAnimComplete;
            model.potentialBookSelectEvent -= DisplayPotentialBook;
            model.potentialBookSelectEvent += DisplayPotentialBook;
@@ -240,6 +246,8 @@
                behaviour.Dispose();
            }
            m_PotentialLine.Dispose();
            model.potentialBookSelectEvent -= DisplayPotentialBook;
            model.onPotentialLevelUpResultEvent -= OnPotentialLevelUp;
            model.potentialLevelUpdate -= PotentialLevelUpdate;
@@ -250,6 +258,7 @@
            m_TreasureAnimation.OnUnlockPotentialComplete -= OnUnlockPotentialComplete;
            m_TreasureAnimation.OnPotentialLevelUpComplete -= OnPotentialLevelUpComplete;
            RedpointCenter.Instance.redpointValueChangeEvent -= RedpointValueChangeEvent;
            m_TreasureAnimation.OnPotentialLineAnimComplete -= OnPotentialLineAnimComplete;
            m_SelectedPotential = 0;
        }
@@ -265,7 +274,6 @@
        private void OnPotentialLevelUpComplete(int _index)
        {
            var potential = m_Treasure.potentials[_index];
            m_PotentialLine.Display(_index, true);
            potentialBriefInfos[_index].DisplayStateSfx();
            potentialBriefInfos[_index].StartLevelTween();
            var _nextPotential = GetNextPotential(potential.id);
@@ -290,6 +298,15 @@
        private void OnUnlockPotentialComplete(int _index)
        {
            selectedPotential = m_Treasure.potentials[_index].id;
            m_TreasureAnimation.DisplayPotentialLine(_index);
        }
        private void OnPotentialLineAnimComplete(int _index)
        {
            if (_index < potentialBriefInfos.Length)
            {
                m_PotentialLine.Display(_index, true);
            }
        }
        private void OnStepComplete(TreasureAnimation.TreasureShowStep _step)
@@ -304,6 +321,7 @@
                        m_TreasureAnimation.UnlockTreasurePotential(0);
                        model.SetPotentialUnlockShow(model.selectedTreasure);
                    }
                    DisplayLines();
                    break;
                case TreasureAnimation.TreasureShowStep.FirstPotential:
                    if (FuncOpen.Instance.IsFuncOpen(82))
@@ -314,6 +332,25 @@
                        model.SetPotentialUnlockShow(model.selectedTreasure);
                    }
                    break;
            }
        }
        void DisplayLines()
        {
            if (m_Treasure == null)
            {
                return;
            }
            for (int i = 0; i < potentialBriefInfos.Length; i++)
            {
                if (i < m_Treasure.potentials.Count)
                {
                    m_PotentialLine.Display(i, model.IsPotentialUnlock(m_Treasure.id, m_Treasure.potentials[i].id));
                }
                else
                {
                    m_PotentialLine.Display(i, false);
                }
            }
        }
@@ -741,10 +778,6 @@
                }
                if (potentialBriefInfos[i].potential.id == id)
                {
                    if (level == 1)
                    {
                        m_PotentialLine.Display(i, false);
                    }
                    m_TreasureAnimation.DisplayPotentialLevelUp(i, level);
                    break;
                }
System/Treasure/TreasureSoulWin.cs
@@ -266,7 +266,7 @@
                        if (!model.IsCompleteLockAchievement(model.selectSoul))
                        {
                            m_Active.gameObject.SetActive(false);
                            m_GotoRealm.gameObject.SetActive(true);
                            m_GotoRealm.gameObject.SetActive(false);
                        }
                        else
                        {