готовая лаба 4

This commit is contained in:
spacyboy 2023-12-12 14:33:55 +04:00
parent 4e005d11fe
commit 93f32ceef3

View File

@ -50,7 +50,7 @@ namespace RoadTrain.DrawingObjects
{
x = 0;
}
if (y < 0 || y + _roadTrainWidth > _pictureHeight)
if (y < 0 || y + _roadTrainHeight > _pictureHeight)
{
y = 0;
}
@ -109,7 +109,7 @@ namespace RoadTrain.DrawingObjects
g.DrawRectangle(pen, _startPosX, _startPosY + 50, 160, 20);
g.FillRectangle(bodyBrush, _startPosX, _startPosY + 50, 160, 20);
g.DrawEllipse(pen, _startPosX + 5, _startPosY + 70, 30, 30); //колесо
g.FillEllipse(bodyBrush, _startPosX + 5, _startPosY + 70 , 30, 30);
g.FillEllipse(bodyBrush, _startPosX + 5, _startPosY + 70, 30, 30);
g.DrawEllipse(pen, _startPosX + 40, _startPosY + 70, 30, 30); //колесо
g.FillEllipse(bodyBrush, _startPosX + 40, _startPosY + 70, 30, 30);
g.DrawEllipse(pen, _startPosX + 120, _startPosY + 70, 30, 30); //колесо