hedgewars/uAmmos.pas
changeset 3960 ada50f8d4186
parent 3955 d14ecff9502b
child 3966 cbec77b5f706
equal deleted inserted replaced
3959:e7ea30323993 3960:ada50f8d4186
   145             (Ammoz[a].SkipTurns < 10000) then inc(Ammoz[a].SkipTurns,10000)
   145             (Ammoz[a].SkipTurns < 10000) then inc(Ammoz[a].SkipTurns,10000)
   146         end 
   146         end 
   147     else ammos[a]:= AMMO_INFINITE;
   147     else ammos[a]:= AMMO_INFINITE;
   148     InitialCounts[Pred(StoreCnt)][a]:= ammos[a];
   148     InitialCounts[Pred(StoreCnt)][a]:= ammos[a];
   149     end;
   149     end;
   150 FillAmmoStore(StoresList[Pred(StoreCnt)], ammos);
   150 FillAmmoStore(StoresList[Pred(StoreCnt)], ammos)
   151 for cnt:= 0 to cMaxSlotIndex do
       
   152     PackAmmo(StoresList[Pred(StoreCnt)], cnt)
       
   153 end;
   151 end;
   154 
   152 
   155 function GetAmmoByNum(num: Longword): PHHAmmo;
   153 function GetAmmoByNum(num: Longword): PHHAmmo;
   156 begin
   154 begin
   157 TryDo(num < StoreCnt, 'Invalid store number', true);
   155 TryDo(num < StoreCnt, 'Invalid store number', true);