Лабораторная работа №1 v1.2

This commit is contained in:
Павел Ладягин 2024-02-24 10:18:22 +04:00
parent 8b9f31abb3
commit d221bfd6e4
5 changed files with 31 additions and 31 deletions

View File

@ -33,12 +33,12 @@
/// <summary> /// <summary>
/// Ширина прорисовки самолета /// Ширина прорисовки самолета
/// </summary> /// </summary>
public readonly int PlaneWidth = 260; public readonly int PlaneWidth = 150;
/// <summary> /// <summary>
/// Высота прорисовки самолета /// Высота прорисовки самолета
/// </summary> /// </summary>
public readonly int PlaneHeight = 110; public readonly int PlaneHeight = 95;
/// <summary> /// <summary>
@ -199,69 +199,69 @@
if (EntityAirplaneWithRadar.Wheels) if (EntityAirplaneWithRadar.Wheels)
{ {
//Задняя стойка //Задняя стойка
g.DrawRectangle(pen, _startPosX.Value + 70, _startPosY.Value + 90, 5, 10); g.DrawRectangle(pen, _startPosX.Value + 30, _startPosY.Value + 80, 5, 10);
g.FillRectangle(additionalBrush, _startPosX.Value + 70, _startPosY.Value + 90, 5, 10); g.FillRectangle(additionalBrush, _startPosX.Value + 30, _startPosY.Value + 80, 5, 10);
g.DrawEllipse(pen, _startPosX.Value + 60, _startPosY.Value + 100, 10, 10); g.DrawEllipse(pen, _startPosX.Value + 20, _startPosY.Value + 85, 10, 10);
g.FillEllipse(additionalBrush, _startPosX.Value + 60, _startPosY.Value + 100, 10, 10); g.FillEllipse(additionalBrush, _startPosX.Value + 20, _startPosY.Value + 85, 10, 10);
g.DrawEllipse(pen, _startPosX.Value + 75, _startPosY.Value + 100, 10, 10); g.DrawEllipse(pen, _startPosX.Value + 35, _startPosY.Value + 85, 10, 10);
g.FillEllipse(additionalBrush, _startPosX.Value + 75, _startPosY.Value + 100, 10, 10); g.FillEllipse(additionalBrush, _startPosX.Value + 35, _startPosY.Value + 85, 10, 10);
//Передняя стойка //Передняя стойка
g.DrawRectangle(pen, _startPosX.Value + 180, _startPosY.Value + 90, 5, 10); g.DrawRectangle(pen, _startPosX.Value + 95, _startPosY.Value + 80, 5, 10);
g.FillRectangle(additionalBrush, _startPosX.Value + 180, _startPosY.Value + 90, 5, 10); g.FillRectangle(additionalBrush, _startPosX.Value + 95, _startPosY.Value + 80, 5, 10);
g.DrawEllipse(pen, _startPosX.Value + 177, _startPosY.Value + 100, 10, 10); g.DrawEllipse(pen, _startPosX.Value + 92, _startPosY.Value + 85, 10, 10);
g.FillEllipse(additionalBrush, _startPosX.Value + 177, _startPosY.Value + 100, 10, 10); g.FillEllipse(additionalBrush, _startPosX.Value + 92, _startPosY.Value + 85, 10, 10);
} }
//Ракета воздух-воздух //Ракета воздух-воздух
if (EntityAirplaneWithRadar.Rocket) if (EntityAirplaneWithRadar.Rocket)
{ {
g.DrawRectangle(pen, _startPosX.Value + 100, _startPosY.Value + 80, 2, 5); g.DrawRectangle(pen, _startPosX.Value + 50, _startPosY.Value + 70, 2, 5);
g.FillRectangle(additionalBrush, _startPosX.Value + 100, _startPosY.Value + 80, 2, 5); g.FillRectangle(additionalBrush, _startPosX.Value + 50, _startPosY.Value + 70, 2, 5);
g.DrawRectangle(pen, _startPosX.Value + 140, _startPosY.Value + 80, 2, 5); g.DrawRectangle(pen, _startPosX.Value + 80, _startPosY.Value + 70, 2, 5);
g.FillRectangle(additionalBrush, _startPosX.Value + 140, _startPosY.Value + 80, 2, 5); g.FillRectangle(additionalBrush, _startPosX.Value + 80, _startPosY.Value + 70, 2, 5);
g.DrawRectangle(pen, _startPosX.Value + 80, _startPosY.Value + 85, 80, 5); g.DrawRectangle(pen, _startPosX.Value + 40, _startPosY.Value + 75, 50, 5);
g.FillRectangle(additionalBrush, _startPosX.Value + 80, _startPosY.Value + 85, 80, 5); g.FillRectangle(additionalBrush, _startPosX.Value + 40, _startPosY.Value + 75, 50, 5);
} }
//Корпус //Корпус
g.DrawRectangle(pen, _startPosX.Value + 10, _startPosY.Value + 60,200,30); g.DrawRectangle(pen, _startPosX.Value + 10, _startPosY.Value + 50,100,30);
//Хвост //Хвост
Point[] points = { Point[] points = {
new Point(_startPosX.Value + 10, _startPosY.Value + 10), new Point(_startPosX.Value + 10, _startPosY.Value + 10),
new Point(_startPosX.Value + 10, _startPosY.Value + 60), new Point(_startPosX.Value + 10, _startPosY.Value + 50),
new Point(_startPosX.Value + 60, _startPosY.Value + 60) new Point(_startPosX.Value + 50, _startPosY.Value + 50)
}; };
g.DrawPolygon(pen, points); g.DrawPolygon(pen, points);
//Кабина //Кабина
Point[] points2 = { Point[] points2 = {
new Point(_startPosX.Value + 210, _startPosY.Value + 55), new Point(_startPosX.Value + 110, _startPosY.Value + 45),
new Point(_startPosX.Value + 210, _startPosY.Value + 75), new Point(_startPosX.Value + 110, _startPosY.Value + 65),
new Point(_startPosX.Value + 260, _startPosY.Value + 75) new Point(_startPosX.Value + 150, _startPosY.Value + 65)
}; };
g.DrawPolygon(pen, points2); g.DrawPolygon(pen, points2);
Point[] points3 = { Point[] points3 = {
new Point(_startPosX.Value + 210, _startPosY.Value + 75), new Point(_startPosX.Value + 110, _startPosY.Value + 65),
new Point(_startPosX.Value + 210, _startPosY.Value + 95), new Point(_startPosX.Value + 110, _startPosY.Value + 85),
new Point(_startPosX.Value + 260, _startPosY.Value + 75) new Point(_startPosX.Value + 150, _startPosY.Value + 65)
}; };
g.DrawPolygon(pen, points3); g.DrawPolygon(pen, points3);
//Крыло //Крыло
Brush brBlack = new SolidBrush(Color.Black); Brush brBlack = new SolidBrush(Color.Black);
g.DrawEllipse(pen, _startPosX.Value + 70, _startPosY.Value + 70, 100, 10); g.DrawEllipse(pen, _startPosX.Value + 30, _startPosY.Value + 60, 70, 10);
g.FillEllipse(brBlack, _startPosX.Value + 70, _startPosY.Value + 70, 100, 10); g.FillEllipse(brBlack, _startPosX.Value + 30, _startPosY.Value + 60, 70, 10);
//Хвостовой элерон //Хвостовой элерон
g.DrawEllipse(pen, _startPosX.Value, _startPosY.Value + 55, 40, 10); g.DrawEllipse(pen, _startPosX.Value, _startPosY.Value + 45, 30, 10);
g.FillEllipse(brBlack, _startPosX.Value, _startPosY.Value + 55, 40, 10); g.FillEllipse(brBlack, _startPosX.Value, _startPosY.Value + 45, 30, 10);
} }
} }

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB