diff --git a/MotorBoat/MotorBoat/AbstractMap.cs b/MotorBoat/MotorBoat/AbstractMap.cs index 52f6245..413d614 100644 --- a/MotorBoat/MotorBoat/AbstractMap.cs +++ b/MotorBoat/MotorBoat/AbstractMap.cs @@ -17,7 +17,6 @@ namespace MotorBoat protected readonly Random _random = new(); protected readonly int _freeRoad = 0; protected readonly int _barrier = 1; - public Bitmap CreateMap(int width, int height, IDrawningObject drawningObject) { _width = width; @@ -158,9 +157,9 @@ namespace MotorBoat if (leftXinS < 0 || bottomYinS > _height || topYinS<0 || rightX > _width) { return false; } - for (int j = topYinS; j < bottomYinS; j++) + for (int j = topYinS; j <= bottomYinS; j++) { - for (int i = leftXinS; i < rightXinS; i++) + for (int i = leftXinS; i <= rightXinS; i++) { if (_map[i, j] == _barrier) { diff --git a/MotorBoat/MotorBoat/Direction.cs b/MotorBoat/MotorBoat/Direction.cs index 29fb18c..9ae1f69 100644 --- a/MotorBoat/MotorBoat/Direction.cs +++ b/MotorBoat/MotorBoat/Direction.cs @@ -13,7 +13,5 @@ namespace MotorBoat Down = 2, Left = 3, Right = 4, - DownLeft=5, - DownRight=6, } } diff --git a/MotorBoat/MotorBoat/DrawningObjectBoat.cs b/MotorBoat/MotorBoat/DrawningObjectBoat.cs index 36c3771..09a0531 100644 --- a/MotorBoat/MotorBoat/DrawningObjectBoat.cs +++ b/MotorBoat/MotorBoat/DrawningObjectBoat.cs @@ -34,7 +34,6 @@ namespace MotorBoat void IDrawningObject.DrawningObject(Graphics g) { - // TODO _boat.DrawTransport(g); } } diff --git a/MotorBoat/MotorBoat/EntityMotorBoat.cs b/MotorBoat/MotorBoat/EntityMotorBoat.cs index 9f6f8c9..e05cd37 100644 --- a/MotorBoat/MotorBoat/EntityMotorBoat.cs +++ b/MotorBoat/MotorBoat/EntityMotorBoat.cs @@ -28,5 +28,4 @@ namespace MotorBoat SportLine = sportLine; } } - }