diff --git a/ArmoredCar/ArmoredCar/MapWithSetArmoredCarsGeneric.cs b/ArmoredCar/ArmoredCar/MapWithSetArmoredCarsGeneric.cs index 998bc13..04ee657 100644 --- a/ArmoredCar/ArmoredCar/MapWithSetArmoredCarsGeneric.cs +++ b/ArmoredCar/ArmoredCar/MapWithSetArmoredCarsGeneric.cs @@ -166,10 +166,11 @@ namespace ArmoredCar /// private void DrawArmoredCars(Graphics g) { + int width = _pictureWidth / _placeSizeWidth; + for (int i = 0; i < _setCars.Count; i++) - { - // TODO установка объекта - //_setCars.Get(i)?.SetObject(x, y, _pictureWidth, _pictureHeight); + { + _setCars.Get(i)?.SetObject(i % width * _placeSizeWidth + 10, i / width * _placeSizeHeight + 10, _pictureWidth, _pictureHeight); _setCars.Get(i)?.DrawningObject(g); } }