diff --git a/ProjectMonorail/ProjectMonorail.sln b/ProjectMonorail/ProjectMonorail.sln
index 85a501b..6ef2aff 100644
--- a/ProjectMonorail/ProjectMonorail.sln
+++ b/ProjectMonorail/ProjectMonorail.sln
@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.11.35303.130
MinimumVisualStudioVersion = 10.0.40219.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ProjectMonorail", "ProjectMonorail\ProjectMonorail.csproj", "{FFFB69FA-2DD3-4887-B6FC-9BA8B6F356A2}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ProjectMonorail", "ProjectMonorail\ProjectMonorail.csproj", "{FFFB69FA-2DD3-4887-B6FC-9BA8B6F356A2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
diff --git a/ProjectMonorail/ProjectMonorail/DirectionType.cs b/ProjectMonorail/ProjectMonorail/DirectionType.cs
new file mode 100644
index 0000000..684014a
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/DirectionType.cs
@@ -0,0 +1,21 @@
+namespace ProjectMonorail;
+
+public enum DirectionType
+{
+ ///
+ /// Вверх
+ ///
+ Up = 1,
+ ///
+ /// Вниз
+ ///
+ Down = 2,
+ ///
+ /// Влево
+ ///
+ Left = 3,
+ ///
+ /// Вправо
+ ///
+ Right = 4
+}
diff --git a/ProjectMonorail/ProjectMonorail/DrawningMonorail.cs b/ProjectMonorail/ProjectMonorail/DrawningMonorail.cs
new file mode 100644
index 0000000..25d7ea4
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/DrawningMonorail.cs
@@ -0,0 +1,231 @@
+using static System.Windows.Forms.AxHost;
+
+namespace ProjectMonorail;
+
+public class DrawningMonorail
+{
+ ///
+ /// Класс-сущность
+ ///
+ public EntityMonorail? EntityMonorail { get; private set; }
+ ///
+ /// Ширина окна
+ ///
+ private int? _pictureWidth;
+ ///
+ /// Высота окна
+ ///
+ private int? _pictureHeight;
+ ///
+ /// Левая координата прорисовки автомобиля
+ ///
+ private int? _startPosX;
+ ///
+ /// Верхняя кооридната прорисовки автомобиля
+ ///
+ private int? _startPosY;
+ ///
+ /// Ширина прорисовки автомобиля
+ ///
+ private readonly int _drawningWidth = 110;
+ ///
+ /// Высота прорисовки автомобиля
+ ///
+ private readonly int _drawningHeight = 56;
+ ///
+ /// Минимальный отступ слева
+ ///
+ private readonly int minLeftMargin = 0;
+ ///
+ /// Минимальный отступ сверху
+ ///
+ private readonly int minTopMargin = 0;
+
+ ///
+ /// Инициализация свойств
+ ///
+ /// Скорость
+ /// Вес
+ /// Основной цвет
+ /// Дополнительный цвет
+ /// Признак наличия магнитного рельса
+ /// Признак наличия второй кабины
+ public void Init(int speed, double weight, Color bodyColor, Color additionalColor, bool magneticRail, bool secondCabin)
+ {
+ EntityMonorail = new EntityMonorail();
+ EntityMonorail.Init(speed, weight, bodyColor, additionalColor, magneticRail, secondCabin);
+ _pictureWidth = null;
+ _pictureHeight = null;
+ _startPosX = null;
+ _startPosY = null;
+ }
+
+ ///
+ /// Установка границ поля
+ ///
+ /// Ширина поля
+ /// Высота поля
+ /// true - границы заданы, false - проверка не пройдена, нельзя разместить объект в этих размерах
+ public bool SetPictureSize(int width, int height)
+ {
+ if (width >= _drawningWidth && height >= _drawningHeight)
+ {
+ _pictureWidth = width;
+ _pictureHeight = height;
+ return true;
+ }
+ return false;
+ }
+
+ ///
+ /// Установка позиции
+ ///
+ /// Координата X
+ /// Координата Y
+ public void SetPosition(int x, int y)
+ {
+ if (!_pictureHeight.HasValue || !_pictureWidth.HasValue)
+ {
+ return;
+ }
+
+ // Проверка на минимальные отступы
+ x = Math.Max(x, minLeftMargin);
+ y = Math.Max(y, minTopMargin);
+
+ if (x + 140 > _pictureWidth.Value)
+ {
+ x -= (x + 140) - _pictureWidth.Value;
+ }
+ if (y + 60 > _pictureHeight.Value)
+ {
+ y -= (y + 60) - _pictureHeight.Value;
+ }
+
+ _startPosX = x;
+ _startPosY = y;
+ }
+
+ ///
+ /// Изменение направления перемещения
+ ///
+ /// Направление
+ /// true - перемещене выполнено, false - перемещение невозможно
+ public bool MoveTransport(DirectionType direction)
+ {
+ if (EntityMonorail == null || !_startPosX.HasValue || !_startPosY.HasValue)
+ {
+ return false;
+ }
+
+ switch (direction)
+ {
+ case DirectionType.Left:
+ if (_startPosX.Value - EntityMonorail.Step > minLeftMargin)
+ {
+ _startPosX -= (int)EntityMonorail.Step;
+ }
+ return true;
+ case DirectionType.Up:
+ if (_startPosY.Value - EntityMonorail.Step > minTopMargin)
+ {
+ _startPosY -= (int)EntityMonorail.Step;
+ }
+ return true;
+ case DirectionType.Right:
+ if (_startPosX.Value + EntityMonorail.Step + _drawningWidth < _pictureWidth)
+ {
+ _startPosX += (int)EntityMonorail.Step;
+ }
+ return true;
+ case DirectionType.Down:
+ if (_startPosY.Value + EntityMonorail.Step + _drawningHeight < _pictureHeight)
+ {
+ _startPosY += (int)EntityMonorail.Step;
+ }
+ return true;
+ default:
+ return false;
+ }
+ }
+
+ ///
+ /// Прорисовка объекта
+ ///
+ ///
+ public void DrawTransport(Graphics g)
+ {
+ if (EntityMonorail == null || !_startPosX.HasValue || !_startPosY.HasValue)
+ {
+ return;
+ }
+ Pen pen = new(Color.Black);
+ Brush additionalBrush = new SolidBrush(EntityMonorail.AdditionalColor);
+ Brush BodyBrush = new SolidBrush(EntityMonorail.BodyColor);
+ Brush CraneBrush = new SolidBrush(Color.Black);
+
+
+ //корпус
+ g.FillRectangle(BodyBrush, _startPosX.Value + 10, _startPosY.Value + 30, 62, 12);
+ g.DrawRectangle(pen, _startPosX.Value + 10, _startPosY.Value + 30, 62, 12);
+ g.FillRectangle(BodyBrush, _startPosX.Value + 22, _startPosY.Value + 16, 4, 15);
+ g.DrawRectangle(pen, _startPosX.Value + 22, _startPosY.Value + 16, 4, 14);
+ g.FillRectangle(BodyBrush, _startPosX.Value + 37, _startPosY.Value + 8, 5, 23);
+ g.DrawRectangle(pen, _startPosX.Value + 37, _startPosY.Value + 8, 5, 22);
+
+ //стекло
+ g.FillRectangle(additionalBrush, _startPosX.Value + 52, _startPosY.Value + 14, 21, 16);
+ g.DrawRectangle(pen, _startPosX.Value + 52, _startPosY.Value + 14, 20, 16);
+
+ //гусеницы
+ g.DrawLine(pen, _startPosX.Value + 8, _startPosY.Value + 42, _startPosX.Value + 10, _startPosY.Value + 42);
+ g.DrawLine(pen, _startPosX.Value + 7, _startPosY.Value + 43, _startPosX.Value + 7, _startPosY.Value + 53);
+ g.DrawLine(pen, _startPosX.Value + 8, _startPosY.Value + 54, _startPosX.Value + 12, _startPosY.Value + 54);
+ g.DrawLine(pen, _startPosX.Value + 13, _startPosY.Value + 55, _startPosX.Value + 69, _startPosY.Value + 55);
+ g.DrawLine(pen, _startPosX.Value + 70, _startPosY.Value + 54, _startPosX.Value + 73, _startPosY.Value + 54);
+ g.DrawLine(pen, _startPosX.Value + 74, _startPosY.Value + 53, _startPosX.Value + 74, _startPosY.Value + 43);
+ g.DrawLine(pen, _startPosX.Value + 71, _startPosY.Value + 42, _startPosX.Value + 73, _startPosY.Value + 42);
+
+ //колеса
+ g.FillEllipse(BodyBrush, _startPosX.Value + 10, _startPosY.Value + 44, 9, 9);
+ g.DrawEllipse(pen, _startPosX.Value + 10, _startPosY.Value + 44, 9, 9);
+ g.FillEllipse(BodyBrush, _startPosX.Value + 63, _startPosY.Value + 44, 9, 9);
+ g.DrawEllipse(pen, _startPosX.Value + 63, _startPosY.Value + 44, 9, 9);
+
+ g.FillEllipse(BodyBrush, _startPosX.Value + 25, _startPosY.Value + 48, 6, 6);
+ g.DrawEllipse(pen, _startPosX.Value + 25, _startPosY.Value + 48, 6, 6);
+ g.FillEllipse(BodyBrush, _startPosX.Value + 38, _startPosY.Value + 48, 6, 6);
+ g.DrawEllipse(pen, _startPosX.Value + 38, _startPosY.Value + 48, 6, 6);
+ g.FillEllipse(BodyBrush, _startPosX.Value + 50, _startPosY.Value + 48, 6, 6);
+ g.DrawEllipse(pen, _startPosX.Value + 50, _startPosY.Value + 48, 6, 6);
+
+ g.FillEllipse(BodyBrush, _startPosX.Value + 33, _startPosY.Value + 44, 4, 4);
+ g.DrawEllipse(pen, _startPosX.Value + 33, _startPosY.Value + 44, 4, 4);
+ g.FillEllipse(BodyBrush, _startPosX.Value + 45, _startPosY.Value + 44, 4, 4);
+ g.DrawEllipse(pen, _startPosX.Value + 45, _startPosY.Value + 44, 4, 4);
+
+ //кран
+ if (EntityMonorail.Crane)
+ {
+ //балка
+ g.FillRectangle(BodyBrush, _startPosX.Value, _startPosY.Value, 110, 9);
+ g.DrawRectangle(pen, _startPosX.Value, _startPosY.Value, 109, 8);
+
+ //крюк
+ g.FillRectangle(CraneBrush, _startPosX.Value + 107, _startPosY.Value + 8, 3, 13);
+ g.FillRectangle(CraneBrush, _startPosX.Value + 102, _startPosY.Value + 18, 8, 3);
+ g.FillRectangle(CraneBrush, _startPosX.Value + 102, _startPosY.Value + 16, 3, 5);
+ }
+
+ //противовес
+ if (EntityMonorail.Сounterweight)
+ {
+ g.FillRectangle(additionalBrush, _startPosX.Value + 35, _startPosY.Value, 10, 9);
+ g.DrawRectangle(pen, _startPosX.Value + 35, _startPosY.Value, 9, 8);
+
+ g.DrawLine(pen, _startPosX.Value + 35, _startPosY.Value + 2, _startPosX.Value + 44, _startPosY.Value + 2);
+ g.DrawLine(pen, _startPosX.Value + 35, _startPosY.Value + 4, _startPosX.Value + 44, _startPosY.Value + 4);
+ g.DrawLine(pen, _startPosX.Value + 35, _startPosY.Value + 6, _startPosX.Value + 44, _startPosY.Value + 6);
+ }
+ }
+}
\ No newline at end of file
diff --git a/ProjectMonorail/ProjectMonorail/EntityMonorail.cs b/ProjectMonorail/ProjectMonorail/EntityMonorail.cs
new file mode 100644
index 0000000..4686dce
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/EntityMonorail.cs
@@ -0,0 +1,57 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ProjectMonorail;
+
+public class EntityMonorail
+{
+ ///
+ /// Скорость
+ ///
+ 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 Сounterweight { get; private set; }
+ ///
+ /// Признак (опция) наличия крана
+ ///
+ public bool Crane { get; private set; }
+ ///
+ /// Шаг перемещения автомобиля
+ ///
+ public double Step => Speed * 100 / Weight;
+ ///
+ /// Инициализация полей объекта-класса спортивного автомобиля
+ ///
+ /// Скорость
+ /// Вес автомобиля
+ /// Основной цвет
+ /// Дополнительный цвет
+ /// Признак наличия обвеса
+ /// Признак наличия крана
+ public void Init(int speed, double weight, Color bodyColor, Color additionalColor, bool counterweight, bool crane)
+ {
+ Speed = speed;
+ Weight = weight;
+ BodyColor = bodyColor;
+ AdditionalColor = additionalColor;
+ Сounterweight = counterweight;
+ Crane = crane;
+ }
+}
diff --git a/ProjectMonorail/ProjectMonorail/Form1.Designer.cs b/ProjectMonorail/ProjectMonorail/Form1.Designer.cs
deleted file mode 100644
index 89df0d6..0000000
--- a/ProjectMonorail/ProjectMonorail/Form1.Designer.cs
+++ /dev/null
@@ -1,39 +0,0 @@
-namespace ProjectMonorail
-{
- partial class Form1
- {
- ///
- /// Required designer variable.
- ///
- private System.ComponentModel.IContainer components = null;
-
- ///
- /// Clean up any resources being used.
- ///
- /// true if managed resources should be disposed; otherwise, false.
- protected override void Dispose(bool disposing)
- {
- if (disposing && (components != null))
- {
- components.Dispose();
- }
- base.Dispose(disposing);
- }
-
- #region Windows Form Designer generated code
-
- ///
- /// Required method for Designer support - do not modify
- /// the contents of this method with the code editor.
- ///
- private void InitializeComponent()
- {
- this.components = new System.ComponentModel.Container();
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(800, 450);
- this.Text = "Form1";
- }
-
- #endregion
- }
-}
diff --git a/ProjectMonorail/ProjectMonorail/Form1.cs b/ProjectMonorail/ProjectMonorail/Form1.cs
deleted file mode 100644
index 3a909b2..0000000
--- a/ProjectMonorail/ProjectMonorail/Form1.cs
+++ /dev/null
@@ -1,10 +0,0 @@
-namespace ProjectMonorail
-{
- public partial class Form1 : Form
- {
- public Form1()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/ProjectMonorail/ProjectMonorail/FormMonorail.Designer.cs b/ProjectMonorail/ProjectMonorail/FormMonorail.Designer.cs
new file mode 100644
index 0000000..0c51d76
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/FormMonorail.Designer.cs
@@ -0,0 +1,146 @@
+namespace ProjectMonorail
+{
+ partial class FormMonorail
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ pictureBoxMonorail = new PictureBox();
+ buttonCreate = new Button();
+ buttonRight = new Button();
+ buttonLeft = new Button();
+ buttonUp = new Button();
+ buttonDown = new Button();
+ ((System.ComponentModel.ISupportInitialize)pictureBoxMonorail).BeginInit();
+ SuspendLayout();
+ //
+ // pictureBoxMonorail
+ //
+ pictureBoxMonorail.BackgroundImageLayout = ImageLayout.Stretch;
+ pictureBoxMonorail.Dock = DockStyle.Fill;
+ pictureBoxMonorail.ErrorImage = null;
+ pictureBoxMonorail.InitialImage = null;
+ pictureBoxMonorail.Location = new Point(0, 0);
+ pictureBoxMonorail.Margin = new Padding(3, 4, 3, 4);
+ pictureBoxMonorail.Name = "pictureBoxMonorail";
+ pictureBoxMonorail.Size = new Size(882, 471);
+ pictureBoxMonorail.TabIndex = 0;
+ pictureBoxMonorail.TabStop = false;
+ pictureBoxMonorail.Click += pictureBoxMonorail_Click;
+ //
+ // buttonCreate
+ //
+ buttonCreate.Anchor = AnchorStyles.Bottom | AnchorStyles.Left;
+ buttonCreate.Location = new Point(14, 424);
+ buttonCreate.Margin = new Padding(3, 4, 3, 4);
+ buttonCreate.Name = "buttonCreate";
+ buttonCreate.Size = new Size(86, 31);
+ buttonCreate.TabIndex = 1;
+ buttonCreate.Text = "Создать";
+ buttonCreate.UseVisualStyleBackColor = true;
+ buttonCreate.Click += buttonCreate_Click_1;
+ //
+ // buttonRight
+ //
+ buttonRight.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
+ buttonRight.BackgroundImage = Properties.Resources.право;
+ buttonRight.BackgroundImageLayout = ImageLayout.Stretch;
+ buttonRight.Location = new Point(829, 408);
+ buttonRight.Margin = new Padding(3, 4, 3, 4);
+ buttonRight.Name = "buttonRight";
+ buttonRight.Size = new Size(40, 47);
+ buttonRight.TabIndex = 2;
+ buttonRight.UseVisualStyleBackColor = true;
+ buttonRight.Click += ButtonMove_Click;
+ //
+ // buttonLeft
+ //
+ buttonLeft.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
+ buttonLeft.BackgroundImage = Properties.Resources.лево__2_1;
+ buttonLeft.BackgroundImageLayout = ImageLayout.Stretch;
+ buttonLeft.Location = new Point(735, 408);
+ buttonLeft.Margin = new Padding(3, 4, 3, 4);
+ buttonLeft.Name = "buttonLeft";
+ buttonLeft.Size = new Size(40, 47);
+ buttonLeft.TabIndex = 3;
+ buttonLeft.UseVisualStyleBackColor = true;
+ buttonLeft.Click += ButtonMove_Click;
+ //
+ // buttonUp
+ //
+ buttonUp.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
+ buttonUp.BackgroundImage = Properties.Resources.верх1;
+ buttonUp.BackgroundImageLayout = ImageLayout.Stretch;
+ buttonUp.Location = new Point(782, 353);
+ buttonUp.Margin = new Padding(3, 4, 3, 4);
+ buttonUp.Name = "buttonUp";
+ buttonUp.Size = new Size(40, 47);
+ buttonUp.TabIndex = 4;
+ buttonUp.UseVisualStyleBackColor = true;
+ buttonUp.Click += ButtonMove_Click;
+ //
+ // buttonDown
+ //
+ buttonDown.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
+ buttonDown.BackgroundImage = Properties.Resources.низ1;
+ buttonDown.BackgroundImageLayout = ImageLayout.Stretch;
+ buttonDown.Location = new Point(782, 408);
+ buttonDown.Margin = new Padding(3, 4, 3, 4);
+ buttonDown.Name = "buttonDown";
+ buttonDown.Size = new Size(40, 47);
+ buttonDown.TabIndex = 5;
+ buttonDown.UseVisualStyleBackColor = true;
+ buttonDown.Click += ButtonMove_Click;
+ //
+ // FormMonorail
+ //
+ AutoScaleDimensions = new SizeF(8F, 20F);
+ AutoScaleMode = AutoScaleMode.Font;
+ ClientSize = new Size(882, 471);
+ Controls.Add(buttonDown);
+ Controls.Add(buttonUp);
+ Controls.Add(buttonLeft);
+ Controls.Add(buttonRight);
+ Controls.Add(buttonCreate);
+ Controls.Add(pictureBoxMonorail);
+ Margin = new Padding(3, 4, 3, 4);
+ Name = "FormMonorail";
+ Text = "Монорельс";
+ Load += FormMonorail_Load;
+ ((System.ComponentModel.ISupportInitialize)pictureBoxMonorail).EndInit();
+ ResumeLayout(false);
+ }
+
+ #endregion
+
+ private PictureBox pictureBoxMonorail;
+ private Button buttonCreate;
+ private Button buttonRight;
+ private Button buttonLeft;
+ private Button buttonUp;
+ private Button buttonDown;
+ }
+}
\ No newline at end of file
diff --git a/ProjectMonorail/ProjectMonorail/FormMonorail.cs b/ProjectMonorail/ProjectMonorail/FormMonorail.cs
new file mode 100644
index 0000000..792bb5e
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/FormMonorail.cs
@@ -0,0 +1,90 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+
+namespace ProjectMonorail
+{
+ public partial class FormMonorail : Form
+ {
+ private DrawningMonorail? _drawningMonorail;
+ public FormMonorail()
+ {
+ InitializeComponent();
+ }
+
+ private void Draw()
+ {
+ if (_drawningMonorail == null)
+ {
+ return;
+ }
+ Bitmap bmp = new(pictureBoxMonorail.Width, pictureBoxMonorail.Height);
+ Graphics gr = Graphics.FromImage(bmp);
+ _drawningMonorail.DrawTransport(gr);
+ pictureBoxMonorail.Image = bmp;
+ }
+ private void buttonCreate_Click_1(object sender, EventArgs e)
+ {
+ Random random = new();
+ _drawningMonorail = new DrawningMonorail();
+ _drawningMonorail.Init(random.Next(100, 300), random.Next(1000, 3000),
+ Color.FromArgb(random.Next(0, 256), random.Next(0, 256), random.Next(0, 256)),
+ Color.FromArgb(random.Next(0, 256), random.Next(0, 256), random.Next(0, 256)),
+ Convert.ToBoolean(random.Next(0, 2)), Convert.ToBoolean(random.Next(0, 2)));
+ _drawningMonorail.SetPictureSize(pictureBoxMonorail.Width, pictureBoxMonorail.Height);
+ _drawningMonorail.SetPosition(random.Next(10, 100), random.Next(10, 100));
+
+ Draw();
+ }
+ private void ButtonMove_Click(object sender, EventArgs e)
+ {
+ if (_drawningMonorail == null)
+ {
+ return;
+ }
+ string name = ((Button)sender)?.Name ?? string.Empty;
+ bool result = false;
+ switch (name)
+ {
+ case "buttonUp":
+ result =
+ _drawningMonorail.MoveTransport(DirectionType.Up);
+ break;
+ case "buttonDown":
+ result =
+ _drawningMonorail.MoveTransport(DirectionType.Down);
+ break;
+ case "buttonLeft":
+ result =
+ _drawningMonorail.MoveTransport(DirectionType.Left);
+ break;
+ case "buttonRight":
+ result =
+ _drawningMonorail.MoveTransport(DirectionType.Right);
+ break;
+ }
+ if (result)
+ {
+ Draw();
+ }
+ }
+
+ private void pictureBoxMonorail_Click(object sender, EventArgs e)
+ {
+
+ }
+
+ private void FormMonorail_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
+
+
diff --git a/ProjectMonorail/ProjectMonorail/Form1.resx b/ProjectMonorail/ProjectMonorail/FormMonorail.resx
similarity index 92%
rename from ProjectMonorail/ProjectMonorail/Form1.resx
rename to ProjectMonorail/ProjectMonorail/FormMonorail.resx
index 1af7de1..8b2ff64 100644
--- a/ProjectMonorail/ProjectMonorail/Form1.resx
+++ b/ProjectMonorail/ProjectMonorail/FormMonorail.resx
@@ -1,17 +1,17 @@
-
diff --git a/ProjectMonorail/ProjectMonorail/Program.cs b/ProjectMonorail/ProjectMonorail/Program.cs
index 05e6dd5..3f68a06 100644
--- a/ProjectMonorail/ProjectMonorail/Program.cs
+++ b/ProjectMonorail/ProjectMonorail/Program.cs
@@ -11,7 +11,7 @@ namespace ProjectMonorail
// To customize application configuration such as set high DPI settings or default font,
// see https://aka.ms/applicationconfiguration.
ApplicationConfiguration.Initialize();
- Application.Run(new Form1());
+ Application.Run(new FormMonorail());
}
}
}
\ No newline at end of file
diff --git a/ProjectMonorail/ProjectMonorail/ProjectMonorail.csproj b/ProjectMonorail/ProjectMonorail/ProjectMonorail.csproj
index e1a0735..341e41a 100644
--- a/ProjectMonorail/ProjectMonorail/ProjectMonorail.csproj
+++ b/ProjectMonorail/ProjectMonorail/ProjectMonorail.csproj
@@ -1,11 +1,26 @@
-
- WinExe
- net7.0-windows
- enable
- true
- enable
-
+
+ WinExe
+ net8.0-windows
+ enable
+ true
+ enable
+
+
+
+
+ True
+ True
+ Resources.resx
+
+
+
+
+
+ ResXFileCodeGenerator
+ Resources.Designer.cs
+
+
\ No newline at end of file
diff --git a/ProjectMonorail/ProjectMonorail/Properties/Resources.Designer.cs b/ProjectMonorail/ProjectMonorail/Properties/Resources.Designer.cs
new file mode 100644
index 0000000..c77aa93
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/Properties/Resources.Designer.cs
@@ -0,0 +1,133 @@
+//------------------------------------------------------------------------------
+//
+// Этот код создан программой.
+// Исполняемая версия:4.0.30319.42000
+//
+// Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае
+// повторной генерации кода.
+//
+//------------------------------------------------------------------------------
+
+namespace ProjectMonorail.Properties {
+ using System;
+
+
+ ///
+ /// Класс ресурса со строгой типизацией для поиска локализованных строк и т.д.
+ ///
+ // Этот класс создан автоматически классом StronglyTypedResourceBuilder
+ // с помощью такого средства, как ResGen или Visual Studio.
+ // Чтобы добавить или удалить член, измените файл .ResX и снова запустите ResGen
+ // с параметром /str или перестройте свой проект VS.
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ internal class Resources {
+
+ private static global::System.Resources.ResourceManager resourceMan;
+
+ private static global::System.Globalization.CultureInfo resourceCulture;
+
+ [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+ internal Resources() {
+ }
+
+ ///
+ /// Возвращает кэшированный экземпляр ResourceManager, использованный этим классом.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Resources.ResourceManager ResourceManager {
+ get {
+ if (object.ReferenceEquals(resourceMan, null)) {
+ global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ProjectMonorail.Properties.Resources", typeof(Resources).Assembly);
+ resourceMan = temp;
+ }
+ return resourceMan;
+ }
+ }
+
+ ///
+ /// Перезаписывает свойство CurrentUICulture текущего потока для всех
+ /// обращений к ресурсу с помощью этого класса ресурса со строгой типизацией.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Globalization.CultureInfo Culture {
+ get {
+ return resourceCulture;
+ }
+ set {
+ resourceCulture = value;
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap верх {
+ get {
+ object obj = ResourceManager.GetObject("верх", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap верх1 {
+ get {
+ object obj = ResourceManager.GetObject("верх1", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap лево__2_ {
+ get {
+ object obj = ResourceManager.GetObject("лево (2)", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap лево__2_1 {
+ get {
+ object obj = ResourceManager.GetObject("лево (2)1", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap низ {
+ get {
+ object obj = ResourceManager.GetObject("низ", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap низ1 {
+ get {
+ object obj = ResourceManager.GetObject("низ1", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+
+ ///
+ /// Поиск локализованного ресурса типа System.Drawing.Bitmap.
+ ///
+ internal static System.Drawing.Bitmap право {
+ get {
+ object obj = ResourceManager.GetObject("право", resourceCulture);
+ return ((System.Drawing.Bitmap)(obj));
+ }
+ }
+ }
+}
diff --git a/ProjectMonorail/ProjectMonorail/Properties/Resources.resx b/ProjectMonorail/ProjectMonorail/Properties/Resources.resx
new file mode 100644
index 0000000..8b5b0fc
--- /dev/null
+++ b/ProjectMonorail/ProjectMonorail/Properties/Resources.resx
@@ -0,0 +1,142 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+
+ ..\Resources\верх1.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\лево (2).jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\низ.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\верх.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\лево (2)1.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\право.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
+ ..\Resources\низ1.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
+
+
\ No newline at end of file
diff --git a/ProjectMonorail/ProjectMonorail/Resources/верх.jpg b/ProjectMonorail/ProjectMonorail/Resources/верх.jpg
new file mode 100644
index 0000000..30c4d2b
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/верх.jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/верх1.jpg b/ProjectMonorail/ProjectMonorail/Resources/верх1.jpg
new file mode 100644
index 0000000..4c6a212
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/верх1.jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/лево (2).jpg b/ProjectMonorail/ProjectMonorail/Resources/лево (2).jpg
new file mode 100644
index 0000000..c983214
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/лево (2).jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/лево (2)1.jpg b/ProjectMonorail/ProjectMonorail/Resources/лево (2)1.jpg
new file mode 100644
index 0000000..5e2cbf2
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/лево (2)1.jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/низ.jpg b/ProjectMonorail/ProjectMonorail/Resources/низ.jpg
new file mode 100644
index 0000000..a4050a7
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/низ.jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/низ1.jpg b/ProjectMonorail/ProjectMonorail/Resources/низ1.jpg
new file mode 100644
index 0000000..e010891
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/низ1.jpg differ
diff --git a/ProjectMonorail/ProjectMonorail/Resources/право.jpg b/ProjectMonorail/ProjectMonorail/Resources/право.jpg
new file mode 100644
index 0000000..89377d5
Binary files /dev/null and b/ProjectMonorail/ProjectMonorail/Resources/право.jpg differ
diff --git a/верх.jpg b/верх.jpg
new file mode 100644
index 0000000..4c6a212
Binary files /dev/null and b/верх.jpg differ
diff --git a/лево (2).jpg b/лево (2).jpg
new file mode 100644
index 0000000..5e2cbf2
Binary files /dev/null and b/лево (2).jpg differ
diff --git a/низ.jpg b/низ.jpg
new file mode 100644
index 0000000..e010891
Binary files /dev/null and b/низ.jpg differ