Ignore:
Timestamp:
Dec 24, 2023, 11:24:57 PM (11 months ago)
Author:
chronos
Message:
  • Modified: Code cleanup.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/MessgEx.pas

    r484 r505  
    195195  if GameMode = cMovie then
    196196  begin
    197     if not((GameMode = cMovie) and (MovieSpeed = 4)) then
     197    if not ((GameMode = cMovie) and (MovieSpeed = 4)) then
    198198    begin
    199199      MovieCancelled := False;
     
    230230  ix, iy, xDst, yDst, dx, dy, xIcon, yIcon: Integer;
    231231  BookRect: TRect;
    232   x1, xR, yR, share: Single;
     232  x1, xR, yR, Share: Single;
    233233  Screwed: TScrewed;
    234234  SrcPtr: TPixelPointer;
     
    257257          for dy := 0 to 1 do begin
    258258            if dx = 0 then
    259               share := 1 - xR
     259              Share := 1 - xR
    260260            else
    261               share := xR;
     261              Share := xR;
    262262            if dy = 0 then
    263               share := share * (1 - yR)
     263              Share := Share * (1 - yR)
    264264            else
    265               share := share * yR;
     265              Share := Share * yR;
    266266            if (xDst + dx < wScrewed) and
    267267            (yDst + dy < hScrewed) then begin
    268268              Screwed[xDst + dx, yDst + dy, 0] := Screwed[xDst + dx, yDst + dy, 0]
    269                 + share * SrcPtr.Pixel^.B;
     269                + Share * SrcPtr.Pixel^.B;
    270270              Screwed[xDst + dx, yDst + dy, 1] := Screwed[xDst + dx, yDst + dy, 1]
    271                 + share * SrcPtr.Pixel^.G;
     271                + Share * SrcPtr.Pixel^.G;
    272272              Screwed[xDst + dx, yDst + dy, 2] := Screwed[xDst + dx, yDst + dy, 2]
    273                 + share * SrcPtr.Pixel^.R;
     273                + Share * SrcPtr.Pixel^.R;
    274274              Screwed[xDst + dx, yDst + dy, 3] := Screwed[xDst + dx, yDst + dy,
    275                 3] + share;
     275                3] + Share;
    276276            end;
    277277        end;
     
    313313procedure TMessgExDlg.PaintEnemyArmy;
    314314var
    315   emix, ix, iy, X, Y, count, UnitsInLine: Integer;
     315  emix, ix, iy, X, Y, Count, UnitsInLine: Integer;
    316316begin
    317317  ix := 0;
     
    322322    UnitsInLine := nLostArmy;
    323323  for emix := 0 to MyRO.nEnemyModel - 1 do
    324     for count := 0 to LostArmy[emix] - 1 do
     324    for Count := 0 to LostArmy[emix] - 1 do
    325325    begin
    326326      X := Width div 2 + ix * 64 - UnitsInLine * 32;
     
    328328      with MyRO.EnemyModel[emix], Tribe[Owner].ModelPicture[mix] do
    329329      begin
    330         BitBltCanvas(Canvas, X, Y, 64, 48, HGr.Mask.Canvas,
    331           pix mod 10 * 65 + 1, pix div 10 * 49 + 1, SRCAND);
    332         BitBltCanvas(Canvas, X, Y, 64, 48, HGr.Data.Canvas,
    333           pix mod 10 * 65 + 1, pix div 10 * 49 + 1, SRCPAINT);
     330        Sprite(Canvas, HGr, X, Y, 64, 48, pix mod 10 * 65 + 1, pix div 10 * 49 + 1);
    334331      end;
    335332
     
    401398        FrameImage(Canvas, BigImp, Width div 2 - 28, 24, xSizeBig,
    402399          ySizeBig, 0, 0);
    403         BitBltCanvas(Canvas, Width div 2 - 32, 20, 64, 44,
    404           HGr.Mask.Canvas, pix mod 10 * 65 + 1,
    405           pix div 10 * 49 + 1, SRCAND);
    406         BitBltCanvas(Canvas, Width div 2 - 32, 20, 64, 44,
    407           HGr.Data.Canvas, pix mod 10 * 65 + 1,
    408           pix div 10 * 49 + 1, SRCPAINT);
     400        Sprite(Canvas, HGr, Width div 2 - 32, 20, 64, 44, pix mod 10 * 65 + 1,
     401          pix div 10 * 49 + 1);
    409402      end;
    410403    mikBook:
Note: See TracChangeset for help on using the changeset viewer.