Ignore:
Timestamp:
May 19, 2022, 10:39:34 PM (2 years ago)
Author:
chronos
Message:
  • Modified: Use first capital letter in identifiers.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/Battle.pas

    r442 r447  
    3232    uix, ToLoc: Integer;
    3333    Forecast: TBattleForecastEx;
    34     IsSuicideQuery: boolean;
     34    IsSuicideQuery: Boolean;
    3535  end;
    3636
     
    6363  TextSize: TSize;
    6464  LabelText: string;
    65   FirstStrike: boolean;
     65  FirstStrike: Boolean;
    6666begin
    6767  MaxBar := 65;
     
    196196  BitBltCanvas(Buffer.Canvas, 0, 0, 66, 48, ca, xm - 8 - 4 - 66,
    197197    ym + 8 + 12);
    198   MakeUnitInfo(me, MyUn[uix], UnitInfo);
     198  MakeUnitInfo(Me, MyUn[uix], UnitInfo);
    199199  UnitInfo.Flags := UnitInfo.Flags and not unFortified;
    200200  IsoMap.PaintUnit(1, 0, UnitInfo, 0);
     
    216216    ClientWidth := 300;
    217217    ClientHeight := 288;
    218     OKBtn.Visible := true;
    219     CancelBtn.Visible := true;
     218    OKBtn.Visible := True;
     219    CancelBtn.Visible := True;
    220220    Left := (Screen.Width - ClientWidth) div 2; // center on screen
    221221    Top := (Screen.Height - ClientHeight) div 2;
     
    225225    ClientWidth := 178;
    226226    ClientHeight := 178;
    227     OKBtn.Visible := false;
    228     CancelBtn.Visible := false;
     227    OKBtn.Visible := False;
     228    CancelBtn.Visible := False;
    229229  end;
    230230end;
     
    232232procedure TBattleDlg.FormPaint(Sender: TObject);
    233233var
    234   ym, cix, p: Integer;
    235   s, s1: string;
     234  ym, cix, P: Integer;
     235  S, s1: string;
    236236begin
    237237  with Canvas do
     
    253253  begin
    254254    Canvas.Font.Assign(UniFont[ftCaption]);
    255     s := Phrases.Lookup('TITLE_SUICIDE');
    256     RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, s)) div 2,
    257       7 + Border, s);
     255    S := Phrases.Lookup('TITLE_SUICIDE');
     256    RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, S)) div 2,
     257      7 + Border, S);
    258258    Canvas.Font.Assign(UniFont[ftNormal]);
    259     s := Phrases.Lookup('SUICIDE');
    260     p := pos('\', s);
    261     if p = 0 then
    262       RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, s))
    263         div 2, 205, s)
     259    S := Phrases.Lookup('SUICIDE');
     260    P := Pos('\', S);
     261    if P = 0 then
     262      RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, S))
     263        div 2, 205, S)
    264264    else
    265265    begin
    266       s1 := copy(s, 1, p - 1);
     266      s1 := Copy(S, 1, P - 1);
    267267      RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, s1)) div 2,
    268268        205 - MessageLineSpacing div 2, s1);
    269       s1 := copy(s, p + 1, 255);
     269      s1 := Copy(S, P + 1, 255);
    270270      RisedTextOut(Canvas, (ClientWidth - BiColorTextWidth(Canvas, s1)) div 2,
    271271        205 + (MessageLineSpacing - MessageLineSpacing div 2), s1);
Note: See TracChangeset for help on using the changeset viewer.