Исправления в DrawningAirBomber
This commit is contained in:
parent
5a4093e10f
commit
63b5bc994b
@ -30,17 +30,16 @@ namespace AirBomber
|
|||||||
{
|
{
|
||||||
EntityAirPlane = new EntityAirBomber(speed, weight, bodyColor, additionalColor, bombs, fuelTanks);
|
EntityAirPlane = new EntityAirBomber(speed, weight, bodyColor, additionalColor, bombs, fuelTanks);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
public override void DrawPlane(Graphics g)
|
public override void DrawPlane(Graphics g)
|
||||||
{
|
{
|
||||||
if (EntityAirPlane is not EntityAirPlane sportCar)
|
if (EntityAirPlane is not EntityAirPlane airBomber)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Pen pen = new(Color.Black);
|
Pen pen = new(Color.Black);
|
||||||
Brush additionalBrush = new
|
Brush additionalBrush = new SolidBrush(airBomber.AdditionalColor);
|
||||||
SolidBrush(airBomber.AdditionalColor);
|
base.DrawPlane(g);
|
||||||
// обвесы
|
// обвесы
|
||||||
if (airBomber.Bombs)
|
if (airBomber.Bombs)
|
||||||
{
|
{
|
||||||
@ -51,9 +50,8 @@ namespace AirBomber
|
|||||||
g.FillEllipse(bombsColor, _startPosX + 140, _startPosY + 50, 15, 15);
|
g.FillEllipse(bombsColor, _startPosX + 140, _startPosY + 50, 15, 15);
|
||||||
g.DrawEllipse(pen, _startPosX + 140, _startPosY + 50, 15, 15);
|
g.DrawEllipse(pen, _startPosX + 140, _startPosY + 50, 15, 15);
|
||||||
}
|
}
|
||||||
base.DrawPlane(g);
|
|
||||||
// fueltanks
|
// fueltanks
|
||||||
if (EntityAirBomber.FuelTanks)
|
if (airBomber.FuelTanks)
|
||||||
{
|
{
|
||||||
g.FillRectangle(additionalBrush, _startPosX + 63, _startPosY + 34, 20, 15);
|
g.FillRectangle(additionalBrush, _startPosX + 63, _startPosY + 34, 20, 15);
|
||||||
g.DrawRectangle(pen, _startPosX + 63, _startPosY + 34, 20, 15);
|
g.DrawRectangle(pen, _startPosX + 63, _startPosY + 34, 20, 15);
|
||||||
|
Loading…
Reference in New Issue
Block a user