hedgewars/uStore.pas
changeset 13990 b9b1d74b7fef
parent 13980 3183c4dc6e53
child 14191 a1178e1b57a6
equal deleted inserted replaced
13989:a8ffc92a0982 13990:b9b1d74b7fef
   532 
   532 
   533     // number of weapons in ammo menu
   533     // number of weapons in ammo menu
   534     for i:= Low(CountTexz) to High(CountTexz) do
   534     for i:= Low(CountTexz) to High(CountTexz) do
   535         begin
   535         begin
   536         tmpsurf:= TTF_RenderUTF8_Blended(Fontz[CheckCJKFont(trmsg[sidAmmoCount],fnt16)].Handle, Str2PChar(Format(shortstring(trmsg[sidAmmoCount]), IntToStr(i))), cWhiteColorChannels);
   536         tmpsurf:= TTF_RenderUTF8_Blended(Fontz[CheckCJKFont(trmsg[sidAmmoCount],fnt16)].Handle, Str2PChar(Format(shortstring(trmsg[sidAmmoCount]), IntToStr(i))), cWhiteColorChannels);
       
   537         if checkFails(tmpsurf <> nil,'Number texture creation for ammo type #' + intToStr(ord(ai)) + ' failed!',true) then exit;
   537         tmpsurf:= doSurfaceConversion(tmpsurf);
   538         tmpsurf:= doSurfaceConversion(tmpsurf);
   538         FreeAndNilTexture(CountTexz[i]);
   539         FreeAndNilTexture(CountTexz[i]);
   539         CountTexz[i]:= Surface2Tex(tmpsurf, false);
   540         CountTexz[i]:= Surface2Tex(tmpsurf, false);
   540         SDL_FreeSurface(tmpsurf)
   541         SDL_FreeSurface(tmpsurf)
   541         end;
   542         end;