using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace WarmlyLocomotive.Entities; /// /// Базовый класс сущности /// public class EntityLocomotive { public int Speed { get; private set; } public double Weight { get; private set; } public Color BodyColor { get; private set; } //public Color AdditionalColor { get; private set; } //public bool Tube { get; private set; } //public bool FuelTank { get; private set; } public double Step => Speed * 100 / Weight; /// /// Конструктор, заменяющий init /// /// скорость /// вес /// цвет public EntityLocomotive(int speed, double weight, Color bodyColor) { Speed = speed; Weight = weight; BodyColor = bodyColor; //AdditionalColor = additionalColor; //Tube = tube; //FuelTank = fuelTank; } }