Ignore:
Timestamp:
Mar 23, 2021, 3:09:11 PM (4 years ago)
Author:
chronos
Message:
  • Modified: Code cleanup.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/CityScreen.pas

    r323 r324  
    17321732  end; }
    17331733
    1734 var
    1735   i, j, k: integer;
    1736 
    17371734procedure TCityDlg.PageUpBtnClick(Sender: TObject);
    17381735begin
     
    17711768end;
    17721769
     1770procedure SortImprovements;
     1771var
     1772  i, j, k: integer;
     1773begin
     1774  for i := 0 to nImp - 1 do
     1775    ImpSorted[i] := i;
     1776  for i := 0 to nImp - 2 do
     1777    for j := i + 1 to nImp - 1 do
     1778      if Prio(ImpSorted[i]) > Prio(ImpSorted[j]) then begin
     1779        k := ImpSorted[i];
     1780        ImpSorted[i] := ImpSorted[j];
     1781        ImpSorted[j] := k;
     1782      end;
     1783end;
     1784
    17731785initialization
    17741786
    1775 for i := 0 to nImp - 1 do
    1776   ImpSorted[i] := i;
    1777 for i := 0 to nImp - 2 do
    1778   for j := i + 1 to nImp - 1 do
    1779     if Prio(ImpSorted[i]) > Prio(ImpSorted[j]) then
    1780     begin
    1781       k := ImpSorted[i];
    1782       ImpSorted[i] := ImpSorted[j];
    1783       ImpSorted[j] := k;
    1784     end;
     1787SortImprovements;
    17851788
    17861789end.
Note: See TracChangeset for help on using the changeset viewer.