/// <summary>
        /// Активный объект карты
        /// </summary>        
        /// <param name="Image">Картинка</param>
        /// <param name="DestroyedActiveObject">Разрушенный активный объект (если нет - null)</param>
        /// <param name="Size">Размер (в клетках карты)</param>
        /// <param name="Direction">Направление</param>
        /// <param name="ArmorType">Тип брони</param>
        /// <param name="Health">Здоровье (0...)</param>
        /// <param name="Passability">Проходимость (0..1)</param>
        public MapActiveObject(MapImage Image, MapActiveObject DestroyedActiveObject, MapSize Size, MapDirection Direction, MapArmorType ArmorType, UInt16 Health, MapPassability Passability)
            : base(new MapTile(Image, Size))
        {
            if ((Passability < 0) || (Passability > 1)) throw new ArgumentOutOfRangeException("Passability", "Passability of Place must be in range 0..1");

            this.DestroyedActiveObject = DestroyedActiveObject;
            this.BaseDirection = Direction;
            this.Health = Health;
            this.Passability = Passability;
            this.ArmorType = ArmorType;
        }
 /// <summary>
 /// Покрытие клетки карты
 /// </summary>        
 /// <param name="Image">Картинка</param>
 /// <param name="Passbility">Проходимость (0..1)</param>
 public MapPlace(MapImage Image, MapPassability Passability)
     : base(new MapTile(Image, MapSize.One))
 {
     this.Passability = Passability;
 }
示例#3
0
 /// <summary>
 /// Покрытие клетки карты
 /// </summary>
 /// <param name="Image">Картинка</param>
 /// <param name="Passbility">Проходимость (0..1)</param>
 public MapPlace(MapImage Image, MapPassability Passability)
     : base(new MapTile(Image, MapSize.One))
 {
     this.Passability = Passability;
 }
示例#4
0
        /// <summary>
        /// Активный объект карты
        /// </summary>
        /// <param name="Image">Картинка</param>
        /// <param name="DestroyedActiveObject">Разрушенный активный объект (если нет - null)</param>
        /// <param name="Size">Размер (в клетках карты)</param>
        /// <param name="Direction">Направление</param>
        /// <param name="ArmorType">Тип брони</param>
        /// <param name="Health">Здоровье (0...)</param>
        /// <param name="Passability">Проходимость (0..1)</param>
        public MapActiveObject(MapImage Image, MapActiveObject DestroyedActiveObject, MapSize Size, MapDirection Direction, MapArmorType ArmorType, UInt16 Health, MapPassability Passability)
            : base(new MapTile(Image, Size))
        {
            if ((Passability < 0) || (Passability > 1))
            {
                throw new ArgumentOutOfRangeException("Passability", "Passability of Place must be in range 0..1");
            }

            this.DestroyedActiveObject = DestroyedActiveObject;
            this.BaseDirection         = Direction;
            this.Health      = Health;
            this.Passability = Passability;
            this.ArmorType   = ArmorType;
        }
 /// <summary>
 /// Состояние покрытия клекти карты
 /// </summary>
 /// <param name="Place">Покрытие</param>
 public MapPlaceState(MapPlace Place)
     : base(Place)
 {
     this.Passability = Place.Passability;
 }