Ignore:
Timestamp:
Jan 4, 2026, 6:07:38 PM (3 days ago)
Author:
chronos
Message:
  • Modified: Do not store .png file extension in graphics names in book files. This is for compatibility with older C-evo versions.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/Tribes.pas

    r661 r715  
    322322      Item := Get;
    323323      sympix := GetNum;
    324       symHGr := LoadGraphicSet(Item + '.png');
     324      symHGr := LoadGraphicSet(Item + PngExt);
    325325    end;
    326326  end;
     
    442442            end;
    443443          end;
    444         cHGr := LoadGraphicSet(Item + '.png');
     444        cHGr := LoadGraphicSet(Item + PngExt);
    445445        for X := 0 to 3 do
    446446          with CityPicture[X] do begin
     
    461461      else
    462462      begin
    463         faceHGr := LoadGraphicSet(Item + '.png');
     463        faceHGr := LoadGraphicSet(Item + PngExt);
    464464        facepix := GetNum;
    465465        if faceHGr.Data.Canvas.Pixels[facepix mod 10 * 65,
     
    493493        Dec(I);
    494494      Assert(I >= 0);
    495       Assert(PictureList[I].HGr = LoadGraphicSet(GrName));
     495      Assert(PictureList[I].HGr = LoadGraphicSet(GrName + PngExt));
    496496      Assert(PictureList[I].pix = pix);
    497497      ModelPicture[mix].HGr := PictureList[I].HGr;
     
    503503      with ModelPicture[mix] do
    504504      begin
    505         HGr := LoadGraphicSet(GrName);
     505        HGr := LoadGraphicSet(GrName + PngExt);
    506506        pix := Info.pix;
    507507        Inc(HGr.PixUsed[pix]);
     
    514514      begin
    515515        Input := Script[I];
    516         if Input = '#UNITS ' + ExtractFileNameOnly(GrName) then
     516        if Input = '#UNITS ' + ExtractFileNameOnly(GrName + PngExt) then
    517517          Ok := True
    518518        else if (Input <> '') and (Input[1] = '#') then
     
    610610  LeastUsed := MaxInt;
    611611
    612   TestPic.GrName := 'StdUnits.png';
     612  TestPic.GrName := 'StdUnits';
    613613  HGr := HGrStdUnits;
    614614  for I := 0 to StdUnitScript.Count - 1 do
     
    625625    begin
    626626      Ok := True;
    627       TestPic.GrName := Copy(Input, 8, 255) + '.png';
    628       HGr := GrExt.SearchByName(TestPic.GrName);
     627      TestPic.GrName := Copy(Input, 8, 255);
     628      HGr := GrExt.SearchByName(TestPic.GrName + PngExt);
    629629    end
    630630    else if (Input <> '') and (Input[1] = '#') then
Note: See TracChangeset for help on using the changeset viewer.