Exemplo n.º 1
0
        public void FindActorsByCamp(BattleCampType actorCamp, ref List <ActorBase> list, bool ignoreStealth = false)
        {
            for (int i = 0; i < m_AllRoles.Count; i++)
            {
                var role = GameEntry.Entity.GetRole <RoleEntityBase>(m_AllRoles[i]);

                if (role == null)
                {
                    continue;
                }

                ActorBase actor = role.Actor;
                if (actor.Camp == actorCamp && actor.IsDead == false)
                {
                    if (ignoreStealth == false)
                    {
                        list.Add(actor);
                    }
                    else
                    {
                        if (actor.GetActorState(ActorStateType.IsStealth) == false)
                        {
                            list.Add(actor);
                        }
                    }
                }
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// 到达目标地
 /// </summary>
 public virtual void OnArrive()
 {
     ChangeState <ActorEmptyFsm>();
     if (m_Host != null && m_Host.GetActorState(ActorStateType.IsRide))
     {
         m_Host.OnArrive();
     }
 }