Ignore:
Timestamp:
Sep 20, 2018, 4:39:37 PM (6 years ago)
Author:
chronos
Message:
  • Modified: Drawing parts split to separate methods.
  • Fixed: Draw correctly unit move arrows across map boundaries in cyclic mode.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormClient.pas

    r236 r237  
    217217          end;
    218218        end;
     219        for Y := 0 to CountP.Y do begin
     220          for X := 0 to CountP.X do begin
     221            TempView.Assign(View);
     222            TempView.DestRect := TRect.Create(
     223              TPoint.Create(
     224                -StartP.X + R.Size.X * X,
     225                -StartP.Y + R.Size.Y * Y
     226              ),
     227              TPoint.Create(
     228                -StartP.X + R.Size.X * X + View.DestRect.Size.X,
     229                -StartP.Y + R.Size.Y * Y + View.DestRect.Size.Y
     230              )
     231            );
     232            Client.DrawArrows(PaintBox1.Canvas, TempView);
     233          end;
     234        end;
    219235        TempView.Free;
    220236      end else
    221237      Client.Paint(PaintBox1.Canvas, View);
     238      Client.DrawArrows(PaintBox1.Canvas, View);
    222239    end;
    223240  end;
Note: See TracChangeset for help on using the changeset viewer.