少年修仙传客户端代码仓库
lwb
2021-02-25 0d7482d5a0e8bf082abfb4b5bfbfee03597cdc3a
System/Skill/SkillModel.cs
@@ -8,20 +8,14 @@
namespace Snxxz.UI
{
    [XLua.LuaCallCSharp]
   public class SkillModel : Model, IBeforePlayerDataInitialize,IPlayerLoginOk
    public class SkillModel : Model, IBeforePlayerDataInitialize, IPlayerLoginOk
    {
        public override void Init()
        {
            ParseConfig();
            FuncOpen.Instance.OnFuncStateChangeEvent += OnFuncStateChangeEvent;
            TaskModel.Event_TaskInformation += TaskInformationUpdate;
            ISkillMatch skillMatch = LuaUtility.Global.Get<ISkillMatch>("SkillMatchModel");
            if (skillMatch != null)
            {
                skillMatch.onSkillMatchPageUpdate += OnSkillMatchPageUpdate;
            }
        }
        public override void UnInit()
@@ -57,11 +51,9 @@
        public int minTaskHole { get; private set; }
        public int maxTaskHole { get; private set; }
        public bool skillMatchRedpointable
        {
        public bool skillMatchRedpointable {
            get { return LocalSave.GetBool("SkillMatchRedpointable_" + PlayerDatas.Instance.baseData.PlayerID); }
            set
            {
            set {
                LocalSave.SetBool("SkillMatchRedpointable_" + PlayerDatas.Instance.baseData.PlayerID, value);
                UpdateSkillMatchRedpoint();
            }
@@ -215,7 +207,7 @@
                if (xpSkillsDic.ContainsKey(job))
                {
                    return xpSkillsDic[job] == config.SkillTypeID;
                }
                }
            }
            return false;
        }
@@ -305,10 +297,8 @@
        public int skillDragId = 0;
        public float onDragDelay = 0.1f;
        private Skill m_XpSkill;
        public Skill xpSkill
        {
            get
            {
        public Skill xpSkill {
            get {
                return m_XpSkill ?? (m_XpSkill = PlayerDatas.Instance.hero.SkillMgr.Get(GetXpSkillID()));
            }
        }
@@ -408,7 +398,7 @@
                    SoundPlayer.Instance.PlayUIAudio(28);
                    SendEquipPassSkill(presentSltPage, _hole, _skillId);
                }
            }
        }
@@ -418,8 +408,7 @@
        public const string TASKHOLEKEY = "OpenSkillSlots";
        public int UnlockPassHole
        {
        public int UnlockPassHole {
            get { return LocalSave.GetInt(StringUtility.Contact(TASKHOLEKEY, "_", PlayerDatas.Instance.baseData.PlayerID)); }
            set { LocalSave.SetInt(StringUtility.Contact(TASKHOLEKEY, "_", PlayerDatas.Instance.baseData.PlayerID), value); }
        }
@@ -468,10 +457,8 @@
        }
        RolePromoteModel m_PromoteModel;
        RolePromoteModel promoteModel
        {
            get
            {
        RolePromoteModel promoteModel {
            get {
                return m_PromoteModel ?? (m_PromoteModel = ModelCenter.Instance.GetModel<RolePromoteModel>());
            }
        }
@@ -820,7 +807,8 @@
        }
        public event Action onSkillMatchPageUpdate;
        private void OnSkillMatchPageUpdate()
        public void OnSkillMatchPageUpdate()
        {
            if (onSkillMatchPageUpdate != null)
            {
@@ -830,12 +818,7 @@
        public List<int> GetSkillMatchs()
        {
            ISkillMatch skillMatch = LuaUtility.Global.Get<ISkillMatch>("SkillMatchModel");
            if (skillMatch != null)
            {
                return skillMatch.GetSkills();
            }
            return null;
            return ILRuntimeUtility.Instance.ModelInvoke<List<int>>("SkillMatchModel", "GetSkills");
        }
    }
@@ -895,7 +878,6 @@
        }
    }
    [XLua.CSharpCallLua]
    public interface ISkillMatch
    {
        List<int> GetSkills();