Airplane sprite
authorunc0rr
Tue, 28 Nov 2006 18:22:03 +0000
changeset 283 28d105f378f1
parent 282 b1e3387389b6
child 284 22ce72bd637f
Airplane sprite
hedgewars/GSHandlers.inc
hedgewars/uConsts.pas
hedgewars/uGears.pas
share/hedgewars/Data/Graphics/Airplane.png
--- a/hedgewars/GSHandlers.inc	Tue Nov 28 17:14:39 2006 +0000
+++ b/hedgewars/GSHandlers.inc	Tue Nov 28 18:22:03 2006 +0000
@@ -925,7 +925,7 @@
 end;
 
 ////////////////////////////////////////////////////////////////////////////////
-const cAirPlaneSpeed = 0.8;
+const cAirPlaneSpeed = 1.1;
       cBombsDistance = 30;
       cBombsSpeed = 0.1;
 
@@ -939,13 +939,13 @@
    AddGear(round(Gear.X), round(Gear.Y), gtAirBomb, 0, cBombsSpeed, 0.0);
    Gear.dX:= Gear.dX + cBombsDistance
    end;
-if Gear.X > 2560 then DeleteGear(Gear)
+if Gear.X > 3072 then DeleteGear(Gear)
 end;
 
 procedure doStepAirAttack(Gear: PGear);
 begin
 AllInactive:= false;
-Gear.X:= -512;
+Gear.X:= -1024;
 Gear.Y:= -128;
 Gear.dX:= TargetPoint.X -
           cBombsDistance * 5 / 2 - 
--- a/hedgewars/uConsts.pas	Tue Nov 28 17:14:39 2006 +0000
+++ b/hedgewars/uConsts.pas	Tue Nov 28 18:22:03 2006 +0000
@@ -38,7 +38,8 @@
                    sprMineOn, sprCase, sprFAid, sprDynamite, sprPower,
                    sprClusterBomb, sprClusterParticle, sprFlame, sprHorizont,
                    sprSky, sprAMBorders, sprAMSlot, sprAMSlotName, sprAMAmmos,
-                   sprAMSlotKeys, sprAMSelection, sprFinger, sprAirBomb);
+                   sprAMSlotKeys, sprAMSelection, sprFinger, sprAirBomb,
+                   sprAirplane);
 
      TGearType  = (gtCloud, gtAmmo_Bomb, gtHedgehog, gtAmmo_Grenade, gtHealthTag,
                    gtGrave, gtUFO, gtShotgunShot, gtPickHammer, gtRope,
@@ -263,7 +264,8 @@
                      (FileName:  'SlotKeys'; Path: ptAmmoMenu; Width:  32; Height: 32; hasAlpha: false),// sprAMSlotKeys
                      (FileName: 'Selection'; Path: ptAmmoMenu; Width:  32; Height: 32; hasAlpha: false),// sprAMSelection
                      (FileName:    'Finger'; Path: ptGraphics; Width:  32; Height: 48; hasAlpha: false),// sprFinger
-                     (FileName:   'AirBomb'; Path: ptGraphics; Width:  32; Height: 32; hasAlpha: false) // sprAirBomb
+                     (FileName:   'AirBomb'; Path: ptGraphics; Width:  32; Height: 32; hasAlpha: false),// sprAirBomb
+                     (FileName:  'Airplane'; Path: ptGraphics; Width: 125; Height: 42; hasAlpha: false) // sprAirplane
                      );
       Soundz: array[TSound] of record
                                        FileName: String[31];
--- a/hedgewars/uGears.pas	Tue Nov 28 17:14:39 2006 +0000
+++ b/hedgewars/uGears.pas	Tue Nov 28 18:22:03 2006 +0000
@@ -525,6 +525,7 @@
          gtCluster: DrawSprite(sprClusterParticle, Round(Gear.X) - 8 + WorldDx, Round(Gear.Y) - 8 + WorldDy, 0, Surface);
            gtFlame: DrawSprite(sprFlame, Round(Gear.X) - 8 + WorldDx, Round(Gear.Y) - 8 + WorldDy,(GameTicks div 128 + Gear.Angle) mod 8, Surface);
          gtAirBomb: DrawSprite(sprAirBomb , Round(Gear.X) - 16 + WorldDx, Round(Gear.Y) - 16 + WorldDy, DxDy2Angle32(Gear.dY, Gear.dX), Surface);
+       gtAirAttack: DrawSprite(sprAirplane, Round(Gear.X) - 60 + WorldDx, Round(Gear.Y) - 25 + WorldDy, 0, Surface);
               end;
       Gear:= Gear.NextGear
       end;
Binary file share/hedgewars/Data/Graphics/Airplane.png has changed