diff --git a/ProjectBulldozer/DrawningBulldozer.cs b/ProjectBulldozer/DrawningBulldozer.cs
index 0bf3ce8..7bb92b0 100644
--- a/ProjectBulldozer/DrawningBulldozer.cs
+++ b/ProjectBulldozer/DrawningBulldozer.cs
@@ -1,5 +1,7 @@
+using ProjectBulldozer.Entities;
+
namespace ProjectBulldozer
{
internal class DrawningBulldozer
diff --git a/ProjectBulldozer/Entities/EntityBulldozer.cs b/ProjectBulldozer/Entities/EntityBulldozer.cs
new file mode 100644
index 0000000..f65c2a9
--- /dev/null
+++ b/ProjectBulldozer/Entities/EntityBulldozer.cs
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ProjectBulldozer.Entities
+{
+ public class EntityBulldozer : EntityTractor
+ {
+ public Color AdditionalColor { get; private set; }
+ public bool Otval { get; private set; }
+ public bool SeifBatteries { get; private set; }
+ public EntityBulldozer(int speed, double weight, Color bodyColor, Color additionalColor, bool otval,
+ bool seifBatteries) : base(speed, weight, bodyColor)
+ {
+ AdditionalColor = additionalColor;
+ Otval = otval;
+ SeifBatteries = seifBatteries;
+ }
+ }
+}
diff --git a/ProjectBulldozer/Entities/EntityTractor.cs b/ProjectBulldozer/Entities/EntityTractor.cs
new file mode 100644
index 0000000..2db9318
--- /dev/null
+++ b/ProjectBulldozer/Entities/EntityTractor.cs
@@ -0,0 +1,22 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ProjectBulldozer.Entities
+{
+ public class EntityTractor
+ {
+ public int Speed { get; private set; }
+ public double Weight { get; private set; }
+ public Color BodyColor { get; private set; }
+ public double Step => (double)Speed * 100 / Weight;
+ public EntityTractor(int speed, double weight, Color bodyColor)
+ {
+ Speed = speed;
+ Weight = weight;
+ BodyColor = bodyColor;
+ }
+ }
+}
diff --git a/ProjectBulldozer/EntityBulldozer.cs b/ProjectBulldozer/EntityBulldozer.cs
deleted file mode 100644
index eb451d9..0000000
--- a/ProjectBulldozer/EntityBulldozer.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
-namespace ProjectBulldozer
-{
- public class EntityBulldozer
- {
-
-
- 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 AdditionalEngine { get; private set; }
- public bool AdditionalCompartment { get; private set; }
- public double Step => (double)Speed * 240 / Weight;
-
-
- ///
- /// Инициализация полей объекта-класса бульдозера
- ///
- /// Скорость
- /// Вес бульдозера
- /// Основной цвет
- /// Дополнительный цвет
- /// Признак наличия дополнительного катка
- /// Признак наличия гусениц
- public void Init(int speed, double weight, Color bodyColor, Color
- additionalColor, bool additionalEngine, bool additionalCompartment)
- {
- Speed = speed;
- Weight = weight;
- BodyColor = bodyColor;
- AdditionalEngine = additionalEngine;
- AdditionalColor = additionalColor;
-
- AdditionalCompartment = additionalCompartment;
- }
- }
-}