diff --git a/WarmlyShip/WarmlyShip/DrawningMotorShip.cs b/WarmlyShip/WarmlyShip/DrawningMotorShip.cs index a422328..4e8821f 100644 --- a/WarmlyShip/WarmlyShip/DrawningMotorShip.cs +++ b/WarmlyShip/WarmlyShip/DrawningMotorShip.cs @@ -43,8 +43,7 @@ namespace WarmlyShip public DrawningMotorShip ModifShip(int? speed = null, float? weight = null, Color? bodyColor = null, Color? dopColor = null, bool? tubes = null, bool? cistern = null) { - EntityMotorShip motorShip = (EntityMotorShip)warmlyShip; - return new DrawningMotorShip(speed ?? warmlyShip.Speed, weight ?? warmlyShip.Weight, bodyColor ?? warmlyShip.BodyColor, dopColor ?? motorShip.DopColor, tubes ?? motorShip.Tubes, cistern ?? motorShip.Cistern); + return new DrawningMotorShip(speed ?? warmlyShip.Speed, weight ?? warmlyShip.Weight, bodyColor ?? warmlyShip.BodyColor, dopColor ?? ((EntityMotorShip)warmlyShip).DopColor, tubes ?? ((EntityMotorShip)warmlyShip).Tubes, cistern ?? ((EntityMotorShip)warmlyShip).Cistern); } } } \ No newline at end of file diff --git a/WarmlyShip/WarmlyShip/EntityWarmlyShip.cs b/WarmlyShip/WarmlyShip/EntityWarmlyShip.cs index e36f167..79878fb 100644 --- a/WarmlyShip/WarmlyShip/EntityWarmlyShip.cs +++ b/WarmlyShip/WarmlyShip/EntityWarmlyShip.cs @@ -17,8 +17,8 @@ namespace WarmlyShip public EntityWarmlyShip(int speed, float weight, Color bodyColor) { Random random = new Random(); - Speed = speed <= 0 ? random.Next(50, 150) : speed; - Weight = weight <= 0 ? random.Next(40, 70) : weight; + Speed = speed <= 0 ? random.Next(100, 300) : speed; + Weight = weight <= 0 ? random.Next(1000, 2000) : weight; BodyColor = bodyColor; } } diff --git a/WarmlyShip/WarmlyShip/FormShipConfig.cs b/WarmlyShip/WarmlyShip/FormShipConfig.cs index 7802092..8e7fa69 100644 --- a/WarmlyShip/WarmlyShip/FormShipConfig.cs +++ b/WarmlyShip/WarmlyShip/FormShipConfig.cs @@ -23,7 +23,7 @@ namespace WarmlyShip panelBlack.MouseDown += PanelColor_MouseDown; panelPink.MouseDown += PanelColor_MouseDown; panelGreen.MouseDown += PanelColor_MouseDown; - panelGreen.MouseDown += PanelColor_MouseDown; + panelCyan.MouseDown += PanelColor_MouseDown; panelRed.MouseDown += PanelColor_MouseDown; panelWhite.MouseDown += PanelColor_MouseDown; panelYellow.MouseDown += PanelColor_MouseDown;