From c8a7dece5be3a643ebf62c1c4fa0a5dc2739d000 Mon Sep 17 00:00:00 2001 From: Pavel_Sorokin Date: Wed, 19 Oct 2022 16:11:11 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=B5=D1=80=D0=B5=D0=B4=D0=B5=D0=BB?= =?UTF-8?q?=D0=B0=D0=BD=D1=8B=20=D0=BD=D0=B0=D0=B7=D0=B2=D0=B0=D0=BD=D0=B8?= =?UTF-8?q?=D1=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Liner/Liner/MapWithSetShipsGeneric.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Liner/Liner/MapWithSetShipsGeneric.cs b/Liner/Liner/MapWithSetShipsGeneric.cs index a61420d..e76dee0 100644 --- a/Liner/Liner/MapWithSetShipsGeneric.cs +++ b/Liner/Liner/MapWithSetShipsGeneric.cs @@ -25,9 +25,9 @@ namespace Liner _pictureHeight = picHeight; _map = map; } - public static bool operator +(MapWithSetShipsGeneric map, T car) + public static bool operator +(MapWithSetShipsGeneric map, T ship) { - if (map._setShips.Insert(car) == -1) + if (map._setShips.Insert(ship) == -1) { return false; } @@ -52,7 +52,7 @@ namespace Liner Bitmap bmp = new(_pictureWidth, _pictureHeight); Graphics gr = Graphics.FromImage(bmp); DrawBackground(gr); - DrawCars(gr); + DrawShips(gr); return bmp; } public Bitmap ShowOnMap() @@ -115,7 +115,7 @@ namespace Liner g.DrawLine(pen, i * _placeSizeWidth - 4, 0, i * _placeSizeWidth - 4, (_pictureHeight / _placeSizeHeight) * _placeSizeHeight); } } - private void DrawCars(Graphics g) + private void DrawShips(Graphics g) { int widthEl = _pictureWidth / _placeSizeWidth; int heightEl = _pictureHeight / _placeSizeHeight;