hedgewars/CCHandlers.inc
changeset 926 d231e007452a
parent 917 e59614bffc3f
child 927 2c1675344a6f
equal deleted inserted replaced
925:c20156328529 926:d231e007452a
   280 
   280 
   281 procedure chTimer(var s: shortstring);
   281 procedure chTimer(var s: shortstring);
   282 begin
   282 begin
   283 if (s[0] <> #1) or (s[1] < '1') or (s[1] > '5') or (CurrentTeam = nil) then exit;
   283 if (s[0] <> #1) or (s[1] < '1') or (s[1] > '5') or (CurrentTeam = nil) then exit;
   284 bShowFinger:= false;
   284 bShowFinger:= false;
   285 with CurrentHedgehog^ do
   285 if not CurrentTeam^.ExtDriven then SendIPC(s);
   286      if (Ammo^[CurSlot, CurAmmo].Propz and ammoprop_Timerable) <> 0 then
   286 with CurrentHedgehog^.Gear^ do
   287         begin
   287      begin
   288         Ammo^[CurSlot, CurAmmo].Timer:= 1000 * (byte(s[1]) - 48);
   288      Message:= Message or gm_Timer;
   289         with CurrentTeam^ do
   289      MsgParam:= byte(s[1]) - ord('0')
   290              ApplyAmmoChanges(Hedgehogs[CurrHedgehog]);
   290      end
   291         if not CurrentTeam^.ExtDriven then SendIPC(s);
       
   292         end
       
   293 end;
   291 end;
   294 
   292 
   295 procedure chSlot(var s: shortstring);
   293 procedure chSlot(var s: shortstring);
   296 var slot: LongWord;
   294 var slot: LongWord;
   297 begin
   295 begin