From c6d1cc3b1b3ddf0ed8cd9dcd9fe0ddbf8883eca8 Mon Sep 17 00:00:00 2001 From: Petek1234 <149153720+Petek1234@users.noreply.github.com> Date: Wed, 3 Apr 2024 13:54:32 +0400 Subject: [PATCH] =?UTF-8?q?=D0=BB=D0=B0=D0=B1=D0=B0=203=20=D0=BF=D0=BE?= =?UTF-8?q?=D0=BB=D0=BD=D0=BE=D1=81=D1=82=D1=8C=D1=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- laba 0/laba 0/MovementStrategy/IMoveableObject.cs | 2 +- laba 0/laba 0/MovementStrategy/MoveableB.cs | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/laba 0/laba 0/MovementStrategy/IMoveableObject.cs b/laba 0/laba 0/MovementStrategy/IMoveableObject.cs index 47c1ce6..c1b830e 100644 --- a/laba 0/laba 0/MovementStrategy/IMoveableObject.cs +++ b/laba 0/laba 0/MovementStrategy/IMoveableObject.cs @@ -21,4 +21,4 @@ public interface IMoveableObject /// Направление /// true - объект перемещен, false - перемещение невозможно bool TryMoveObject(MovementDirection direction); -} +} \ No newline at end of file diff --git a/laba 0/laba 0/MovementStrategy/MoveableB.cs b/laba 0/laba 0/MovementStrategy/MoveableB.cs index b420a31..38285e7 100644 --- a/laba 0/laba 0/MovementStrategy/MoveableB.cs +++ b/laba 0/laba 0/MovementStrategy/MoveableB.cs @@ -31,13 +31,11 @@ public class MoveableB : IMoveableObject //определение методов интерфейса get { - if (_B == null || _B.EntityB == null || - !_B.GetPosX.HasValue || !_B.GetPosY.HasValue) + if (_B == null || _B.EntityB == null || !_B.GetPosX.HasValue || !_B.GetPosY.HasValue) { return null; } - return new ObjectParameters(_B.GetPosX.Value, - _B.GetPosY.Value, _B.GetWidth, _B.GetHeight); + return new ObjectParameters(_B.GetPosX.Value, _B.GetPosY.Value, _B.GetWidth, _B.GetHeight); } }