PIBD-11_Basalov_A.D_Simple/ProjectElectricLocomotive/Entities/EntityElectricLocomotive.cs

46 lines
1.8 KiB
C#
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.Collections.Generic;
using System.ComponentModel.Design;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ProjectElectricLocomotive.Entities
{
public class EntityElectricLocomotive : EntityLocomotive
{
public Color AdditionalColor { get; private set; }
/// <summary>
/// Признак (опция) "рогов"
/// </summary>
public bool Pantograph { get; private set; }
/// <summary>
/// Признак (опция) наличия отсека под батареи
/// </summary>
public bool BatteryStorage { get; private set; }
/// <summary>
/// Шаг перемещения Локомотива
/// </summary>
public double Step => Speed * 100 / Weight;
/// <summary>
/// Инициализация полей объекта-класса ЭлектроЛокомотива
/// </summary>
/// <param name="additionalColor">Дополнительный цвет</param>
/// <param name="pantograph">Признак "рогов"</param>
/// <param name="batteryStorage">Признак наличия отсека под батареи</param>
/// ------------------------------------------------------------------------------
/// Переписать!!!!!!!!!
/// САМИМ ТО ЧТО СНИЗУ!!!!!!!!!!!!!!!!!!
public EntityElectricLocomotive(int speed, double weight, Color bodyColor, Color additionalColor, bool pantograph
, bool batteryStorage) : base(speed, weight, bodyColor)
{
AdditionalColor = additionalColor;
Pantograph = pantograph;
BatteryStorage = batteryStorage;
}
}
}