hedgewars/uGearsHedgehog.pas
branchqmlfrontend
changeset 10748 dc587913987c
parent 10714 70f71fac37a3
child 10789 acbf69e2e5cf
equal deleted inserted replaced
10616:20a2d5e6930a 10748:dc587913987c
   503                 AfterAttack;
   503                 AfterAttack;
   504                 end
   504                 end
   505             end
   505             end
   506         else
   506         else
   507             Message:= Message and (not gmAttack);
   507             Message:= Message and (not gmAttack);
   508     end;
   508 
       
   509     ScriptCall('onHogAttack', ord(CurAmmoType));
       
   510     end; // of with Gear^, Gear^.Hedgehog^ do
       
   511 
   509     TargetPoint.X := NoPointX;
   512     TargetPoint.X := NoPointX;
   510     ScriptCall('onHogAttack');
       
   511 end;
   513 end;
   512 
   514 
   513 procedure AfterAttack;
   515 procedure AfterAttack;
   514 var s: ansistring;
   516 var s: ansistring;
   515     a: TAmmoType;
   517     a: TAmmoType;
   830         end;
   832         end;
   831     DeleteCI(Gear); // must be after exit!! (see previous line)
   833     DeleteCI(Gear); // must be after exit!! (see previous line)
   832 
   834 
   833     Gear^.Hedgehog^.visStepPos:= (Gear^.Hedgehog^.visStepPos + 1) and 7;
   835     Gear^.Hedgehog^.visStepPos:= (Gear^.Hedgehog^.visStepPos + 1) and 7;
   834 
   836 
   835     if (not cArtillery) and ((Gear^.Message and gmPrecise) = 0) then
   837     if (not cArtillery or
       
   838            ((CurAmmoGear <> nil) and (CurAmmoGear^.Kind = gtBlowTorch))) and
       
   839        ((Gear^.Message and gmPrecise) = 0) then
   836         MakeHedgehogsStep(Gear);
   840         MakeHedgehogsStep(Gear);
   837 
   841 
   838     SetAllHHToActive(false);
   842     SetAllHHToActive(false);
   839     AddCI(Gear)
   843     AddCI(Gear)
   840     end
   844     end