From 40820059a5e7eb736280912458b4c12b25ed6e45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A1=D0=B5=D1=80=D0=B3=D0=B5=D0=B9=20=D0=9F=D0=BE=D0=BB?= =?UTF-8?q?=D0=B5=D0=B2=D0=BE=D0=B9?= Date: Mon, 26 Sep 2022 18:28:05 +0400 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=B0=20=D0=BF=D1=80=D0=BE=D0=B4=D0=B2=D0=B8=D0=BD=D1=83?= =?UTF-8?q?=D1=82=D0=B0=D1=8F=20=D1=81=D1=83=D1=89=D0=BD=D0=BE=D1=81=D1=82?= =?UTF-8?q?=D1=8C=20=D0=B8=20=D0=B8=D0=BD=D1=82=D0=B5=D1=80=D1=84=D0=B5?= =?UTF-8?q?=D0=B9=D1=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EntityAdvancedArtillery.cs | 21 +++++++++++++++++++ SelfPropelledArtilleryUnit/IDrawningObject.cs | 17 +++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 SelfPropelledArtilleryUnit/EntityAdvancedArtillery.cs create mode 100644 SelfPropelledArtilleryUnit/IDrawningObject.cs diff --git a/SelfPropelledArtilleryUnit/EntityAdvancedArtillery.cs b/SelfPropelledArtilleryUnit/EntityAdvancedArtillery.cs new file mode 100644 index 0000000..dd67cd2 --- /dev/null +++ b/SelfPropelledArtilleryUnit/EntityAdvancedArtillery.cs @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Artilleries +{ + internal class EntityAdvancedArtillery : EntityArtillery + { + public Color DopColor { get; private set; } + public bool Weapon { get; private set; } + public bool SalvoBattery { get; private set; } + public EntityAdvancedArtillery(int speed, float weight, Color bodyColor, Color dopColor, bool weapon, bool salvoBattery) : base(speed, weight, bodyColor) + { + DopColor = dopColor; + Weapon = weapon; + SalvoBattery = salvoBattery; + } + } +} diff --git a/SelfPropelledArtilleryUnit/IDrawningObject.cs b/SelfPropelledArtilleryUnit/IDrawningObject.cs new file mode 100644 index 0000000..67cae91 --- /dev/null +++ b/SelfPropelledArtilleryUnit/IDrawningObject.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Artilleries +{ + internal interface IDrawningObject + { + public float Step { get; } + void SetObject(int x, int y, int width, int height); + void MoveObject(Direction direction); + void DrawingObject(Graphics g); + (float Left, float Right, float Top, float Bottom) GetCurrentPosition(); + } +}