public void SetMoveState(MoveState state) { m_Core.m_MoveState = state; if (m_Core.m_MoveState == MoveState.Fly) { if (m_PetType == 1002) { m_move = new PetFly1002(); m_move.Init(this); m_Skill = new FireSkill(); m_Skill.Init(m_SceneID, m_Parent.m_Core); } } else { if (m_PetType == 1002) { m_move = new PetWalk1002(); m_move.Init(this); (PetMoveAI as PetWalk1002).m_petState = Pet1002State.Follow; } PetInfo Info = CmCarbon.GetPetInfo(m_Core); if (Info.m_skill1 > 0) { m_Skill = new PetSkill(); m_Skill.Init(m_SceneID, m_Core); } } }
public override void InitSkill() { if (m_Core.m_MoveState == MoveState.Fly) { m_Skill = new FireSkill(); m_Skill.Init(SceneID, m_Core); } else if (m_Core.m_MoveState == MoveState.Walk) { m_Skill = new SummonPetSkill(); m_Skill.Init(SceneID, m_Core); } }