hedgewars/uAmmos.pas
changeset 13499 c41b16ac2e05
parent 13455 38814954a248
child 13854 ccfbc5f59c52
equal deleted inserted replaced
13498:4f00b08d6f1e 13499:c41b16ac2e05
   158 FillAmmoStore(StoresList[Pred(StoreCnt)], newAmmos)
   158 FillAmmoStore(StoresList[Pred(StoreCnt)], newAmmos)
   159 end;
   159 end;
   160 
   160 
   161 function GetAmmoByNum(num: LongInt): PHHAmmo;
   161 function GetAmmoByNum(num: LongInt): PHHAmmo;
   162 begin
   162 begin
   163     if checkFails(num < StoreCnt, 'Invalid store number', true) then
   163     if checkFails(num < StoreCnt, 'Invalid ammo store number', true) then
   164         GetAmmoByNum:= nil
   164         GetAmmoByNum:= nil
   165     else
   165     else
   166         GetAmmoByNum:= StoresList[num]
   166         GetAmmoByNum:= StoresList[num]
   167 end;
   167 end;
   168 
   168