protected override void InitAttribute(bool init = false)
        {
            m_BaseAttribute = new ActorAttribute();
            m_CurAttribute  = new ActorAttribute();
            Dictionary <PropertyType, int> propertys = AttributeTools.GetPlayerPropertys(m_PlayerData);

            m_BaseAttribute.CopyFrom(propertys);
            UpdateCurAttribute(init);

            ActorCard.SetName(m_PlayerData.Name);
            ActorCard.SetLevel(m_PlayerData.Level);
            ActorCard.SetMount(m_PlayerData.MountId);
            ActorCard.SetPartnerByPos(2, m_PlayerData.Partner1Id);
            ActorCard.SetPartnerByPos(3, m_PlayerData.Partner2Id);
        }
Exemple #2
0
        public virtual void Init()
        {
            m_ActorSkill = new ActorSkill(this);
            m_ActorCard  = new ActorCard(this);
            m_ActorBuff  = new ActorBuff(this);

            InitAttribute(true);
            InitBornParam();
            InitCommands();
            InitLayer();
            InitAnim();
            InitAi();
            InitFeature();
            InitState();
            InitFsm();

            CreateBoard();
            ApplyCharacterCtrl(true);
        }
Exemple #3
0
        public virtual void Clear()
        {
            RemoveBoard();
            RemoveEffect();

            m_AIFeatures?.Clear();
            m_ActorStates?.Clear();

            m_Enemys?.Clear();
            m_Allys?.Clear();
            m_Targets?.Clear();

            m_ActorAI?.Clear();
            m_ActorBuff?.Clear();
            m_ActorSkill?.Clear();
            m_CommandReceiver?.Clear();

            m_ActorAI         = null;
            m_ActorBuff       = null;
            m_ActorCard       = null;
            m_ActorSkill      = null;
            m_CommandReceiver = null;
            GameEntry.Fsm.DestroyFsm(m_ActorFsm);
        }