diff --git a/ElectricLocomotive/ElectricLocomotive/DrawingLocomotive.cs b/ElectricLocomotive/ElectricLocomotive/DrawingLocomotive.cs index cb7949e..946417c 100644 --- a/ElectricLocomotive/ElectricLocomotive/DrawingLocomotive.cs +++ b/ElectricLocomotive/ElectricLocomotive/DrawingLocomotive.cs @@ -25,12 +25,6 @@ namespace ProjectElectricLocomotive.DrawingObjects public int GetPosY => _startPosY; public int GetWidth => _locomWidth; public int GetHeight => _locomHeight; - /// Скорость - /// Вес - /// Цвет кузова - /// Ширина картинки - /// Высота картинки - public DrawingLocomotive(int speed, double weight, Color bodyColor, int width, int heigth) { if (width < _locomWidth || heigth < _locomHeight) @@ -41,13 +35,6 @@ namespace ProjectElectricLocomotive.DrawingObjects _pictureHeight = heigth; EntityLocomotive = new EntityLocomotive(speed, weight, bodyColor); } - /// Скорость - /// Вес - /// Цвет кузова - /// Ширина картинки - /// Высота картинки - /// Ширина картинки - /// Высота картинки protected DrawingLocomotive(int speed, double weight, Color bodyColor, int width, int height, int locomWidth, int locomHeight) { @@ -61,8 +48,6 @@ namespace ProjectElectricLocomotive.DrawingObjects _locomHeight = locomHeight; EntityLocomotive = new EntityLocomotive(speed, weight, bodyColor); } - /// Координата X - /// Координата Y public void SetPosition(int x, int y) { if (x < 0 || x + _locomWidth > _pictureWidth) @@ -76,7 +61,6 @@ namespace ProjectElectricLocomotive.DrawingObjects _startPosX = x; _startPosY = y; } - /// Направление public void MoveTransport(Direction direction) { if (EntityLocomotive == null) @@ -111,7 +95,6 @@ namespace ProjectElectricLocomotive.DrawingObjects break; } } - /// public virtual void DrawTransport(Graphics g) { { @@ -181,9 +164,6 @@ namespace ProjectElectricLocomotive.DrawingObjects Direction.Down => _startPosY + EntityLocomotive.Step < _pictureHeight, }; } - /// - /// Получение объекта IMoveableObject из объекта DrawningCar - /// public IMoveableObject GetMoveableObject => new DrawingObjectLocomotive(this); } diff --git a/ElectricLocomotive/ElectricLocomotive/FormElectricLocomotive.cs b/ElectricLocomotive/ElectricLocomotive/FormElectricLocomotive.cs index bbc6eff..cee1fea 100644 --- a/ElectricLocomotive/ElectricLocomotive/FormElectricLocomotive.cs +++ b/ElectricLocomotive/ElectricLocomotive/FormElectricLocomotive.cs @@ -133,7 +133,6 @@ namespace ElectricLocomotive } private void ElectricLocomotive_Load(object sender, EventArgs e) { - } private void ButtonSelectLocomotive_Click(object sender, EventArgs e) { diff --git a/ElectricLocomotive/ElectricLocomotive/ProjectElectricLocomotive.csproj b/ElectricLocomotive/ElectricLocomotive/ProjectElectricLocomotive.csproj index 244387d..13ee123 100644 --- a/ElectricLocomotive/ElectricLocomotive/ProjectElectricLocomotive.csproj +++ b/ElectricLocomotive/ElectricLocomotive/ProjectElectricLocomotive.csproj @@ -2,7 +2,7 @@ WinExe - net7.0-windows + net6.0-windows enable true enable diff --git a/ElectricLocomotive/ElectricLocomotive/SetGeneric.cs b/ElectricLocomotive/ElectricLocomotive/SetGeneric.cs index 9d02fdc..60c65ce 100644 --- a/ElectricLocomotive/ElectricLocomotive/SetGeneric.cs +++ b/ElectricLocomotive/ElectricLocomotive/SetGeneric.cs @@ -27,7 +27,7 @@ namespace ProjectElectricLocomotive.Generics { if (_places[i] != null) Full++; } - if (Full == Count - position - 1) + if (Full == Count - position - 1) return -1; if (position < Count && position >= 0) {