示例#1
0
 /// <summary>
 /// Implementation for evacuate event
 /// </summary>
 public void PerformAction()
 {
     if (Status == MovableStatus.EVACUATING && Hotel.IsHotelSafe())
     {
         Status = MovableStatus.IDLE;
     }
 }
示例#2
0
        /// <summary>
        /// Makes the guest evacuate
        /// </summary>
        private void _Evacuate()
        {
            SetPath(Hotel.GetArea(typeof(Reception)));
            FinalDes = Hotel.GetArea(typeof(Reception));

            if (Hotel.IsHotelSafe())
            {
                if (_hteTime == _hteCalculateCounter)
                {
                    Status = MovableStatus.GOING_TO_ROOM;
                }
                else
                {
                    _hteCalculateCounter++;
                }
            }
            else if (Path.Any())
            {
                _Move();
            }
        }