| | |
| | |
|
| | | public static UnityAction<uint, bool> s_OnSelected;
|
| | | public static UnityAction<uint, ulong, ulong> s_OnRefreshLife;
|
| | |
|
| | | private static Dictionary<int, Dictionary<int, List<int>>> m_StaticOffLineSkllList = new Dictionary<int, Dictionary<int, List<int>>>();
|
| | | private int[] m_OffLineSkillList;
|
| | | protected H0434_tagAreaPlayerAppearEx m_H0434;
|
| | |
|
| | | private CmdManager m_CmdManager;
|
| | |
| | | RequestName();
|
| | |
|
| | | m_CmdManager = new CmdManager();
|
| | |
|
| | | if (m_H0434.State == 1)
|
| | | {
|
| | | if (!m_StaticOffLineSkllList.ContainsKey(m_H0434.Job))
|
| | | {
|
| | | m_StaticOffLineSkllList.Add(m_H0434.Job, new Dictionary<int, List<int>>());
|
| | |
|
| | | var _json = LitJson.JsonMapper.ToObject(JobSetup.OffLineSkillList);
|
| | | foreach (var _level in _json.Keys)
|
| | | {
|
| | | var _list = new List<int>();
|
| | | for (int i = 0; i < _json[_level].Count; ++i)
|
| | | {
|
| | | _list.Add((int)_json[_level][i]);
|
| | | }
|
| | | m_StaticOffLineSkllList[m_H0434.Job].Add(int.Parse(_level), _list);
|
| | | }
|
| | | }
|
| | |
|
| | | foreach (var _level in m_StaticOffLineSkllList[m_H0434.Job].Keys)
|
| | | {
|
| | | if (m_H0434.LV < _level)
|
| | | {
|
| | | m_OffLineSkillList = m_StaticOffLineSkllList[m_H0434.Job][_level].ToArray();
|
| | | break;
|
| | | }
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | protected sealed override void OnUnit()
|
| | |
| | |
|
| | | m_CmdManager = null;
|
| | | m_H0434 = null;
|
| | | m_OffLineSkillList = null;
|
| | |
|
| | | base.OnUnit();
|
| | | }
|
| | |
| | | }
|
| | |
|
| | | Skill _castSkill = null;
|
| | | int _skillIndex = UnityEngine.Random.Range(0, JobSetup.HangupSkillList.Length);
|
| | | if (SkillMgr.Get(JobSetup.HangupSkillList[_skillIndex]).IsValid())
|
| | |
|
| | | int _skillIndex = UnityEngine.Random.Range(0, m_OffLineSkillList.Length);
|
| | | if (SkillMgr.Get(m_OffLineSkillList[_skillIndex]).IsValid())
|
| | | {
|
| | | _castSkill = SkillMgr.Get(JobSetup.HangupSkillList[_skillIndex]);
|
| | | _castSkill = SkillMgr.Get(m_OffLineSkillList[_skillIndex]);
|
| | | }
|
| | |
|
| | | if (_castSkill == null)
|