hedgewars/HHHandlers.inc
changeset 2042 905c554d62e6
parent 2041 9e0b5a6bcecf
child 2045 b0588498bc3a
equal deleted inserted replaced
2041:9e0b5a6bcecf 2042:905c554d62e6
    98 end;
    98 end;
    99 
    99 
   100 
   100 
   101 procedure Attack(Gear: PGear);
   101 procedure Attack(Gear: PGear);
   102 var xx, yy: hwFloat;
   102 var xx, yy: hwFloat;
   103     tmpGear: PGear;
   103     tmpGear: PVisualGear;
   104 begin
   104 begin
   105 with Gear^,
   105 with Gear^,
   106      PHedgehog(Gear^.Hedgehog)^ do
   106      PHedgehog(Gear^.Hedgehog)^ do
   107      begin
   107      begin
   108      if ((State and gstHHDriven) <> 0)and
   108      if ((State and gstHHDriven) <> 0)and
   194 
   194 
   195         uStats.AmmoUsed(Ammo^[CurSlot, CurAmmo].AmmoType);
   195         uStats.AmmoUsed(Ammo^[CurSlot, CurAmmo].AmmoType);
   196 
   196 
   197         if not (SpeechText = '') then
   197         if not (SpeechText = '') then
   198             begin
   198             begin
   199             tmpGear:= AddGear(0, 0, gtSpeechBubble, 0, _0, _0, 0);
   199             tmpGear:= AddVisualGear(0, 0, vgtSpeechBubble);
   200             tmpGear^.Text:= SpeechText;
   200             tmpGear^.Text:= SpeechText;
   201             tmpGear^.Hedgehog:= CurrentHedgehog;
   201             tmpGear^.Hedgehog:= CurrentHedgehog;
   202             tmpGear^.State:= SpeechType;
   202             tmpGear^.FrameTicks:= SpeechType;
   203             SpeechText:= ''
   203             SpeechText:= ''
   204             end;
   204             end;
   205 
   205 
   206         Power:= 0;
   206         Power:= 0;
   207         if (CurAmmoGear <> nil)
   207         if (CurAmmoGear <> nil)