Esempio n. 1
0
        public override void WalkToSpawn(short speed)
        {
            if (PatrolGroup != null)
            {
                StopAttack();
                StopFollowing();

                StandardMobBrain brain = Brain as StandardMobBrain;
                if (brain != null && brain.HasAggro)
                {
                    brain.ClearAggroList();
                }

                PatrolGroup.StartPatrol();
                return;
            }
            base.WalkToSpawn(speed);
        }
Esempio n. 2
0
        /// <summary>
        /// Walk to the spawn point, always max speed for keep guards, or continue patrol.
        /// </summary>
        public override void WalkToSpawn()
        {
            if (PatrolGroup != null)
            {
                StopAttack();
                StopFollowing();

                StandardMobBrain brain = Brain as StandardMobBrain;
                if (brain != null && brain.HasAggro)
                {
                    brain.ClearAggroList();
                }

                PatrolGroup.StartPatrol();
            }
            else
            {
                WalkToSpawn(MaxSpeed);
            }
        }