Revision 13:c78b5eafa10e Client/UfrmMain.pas

b/Client/UfrmMain.pas
32 32
uses
33 33
  Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, Menus,
34 34
  ComCtrls, OpenGLContext, GL, GLU, UGameResources, ULandscape, ExtCtrls,
35
  StdCtrls, Spin, UEnums, VTHeaderPopup, VirtualTrees, Buttons, UMulBlock,
36
  UWorldItem, math, LCLIntf, UOverlayUI, UStatics, UEnhancedMemoryStream,
37
  ActnList, ImagingClasses, contnrs, dateutils, UPlatformTypes;
35
  StdCtrls, Spin, UEnums, VirtualTrees, Buttons, UMulBlock, UWorldItem, math,
36
  LCLIntf, UOverlayUI, UStatics, UEnhancedMemoryStream, ActnList,
37
  ImagingClasses, dateutils, UPlatformTypes;
38 38

  
39 39
type
40 40

  
......
1030 1030
    end else
1031 1031
      Delete(enteredText, Length(enteredText), 1);
1032 1032
    
1033
    tileID := 0;
1033 1034
    if not TryStrToInt(enteredText, tileID) then
1034 1035
    begin
1035 1036
      //edSearchID.Font.Color := clRed;
......
1306 1307

  
1307 1308
procedure TfrmMain.vdtTilesHotChange(Sender: TBaseVirtualTree; OldNode,
1308 1309
  NewNode: PVirtualNode);
1310
{$IFDEF Windows}
1309 1311
var
1310 1312
  tileInfo: PTileInfo;
1313
{$ENDIF Windows}
1311 1314
begin
1312 1315
  {TODO : Fix mouse over on !Windows platforms}
1313 1316
  {$IFDEF Windows}
......
1440 1443
  locationInfo := Sender.GetNodeData(Node);
1441 1444
  Stream.Read(locationInfo^.X, SizeOf(Word));
1442 1445
  Stream.Read(locationInfo^.Y, SizeOf(Word));
1446
  stringLength := 0;
1443 1447
  Stream.Read(stringLength, SizeOf(Integer));
1444 1448
  SetLength(s, stringLength);
1445 1449
  Stream.Read(s[1], stringLength);
......
1570 1574
  virtualTile: TVirtualTile;
1571 1575
  staticsFilter: TStaticFilter;
1572 1576

  
1573
  procedure GetMapDrawOffset(x, y: Integer; var drawX, drawY: Single);
1577
  procedure GetMapDrawOffset(x, y: Integer; out drawX, drawY: Single);
1574 1578
  begin
1575 1579
    drawX := (oglGameWindow.Width div 2) + (x - y) * 22;
1576 1580
    drawY := (oglGamewindow.Height div 2) + (x + y) * 22;
......
1578 1582
begin
1579 1583
  drawDistance := Trunc(Sqrt(oglGameWindow.Width * oglGameWindow.Width + oglGamewindow.Height * oglGamewindow.Height) / 44);
1580 1584

  
1585
  {$HINTS off}{$WARNINGS off}
1581 1586
  if FX - drawDistance < 0 then lowOffX := -FX else lowOffX := -drawDistance;
1582 1587
  if FY - drawDistance < 0 then lowOffY := -FY else lowOffY := -drawDistance;
1583 1588
  if FX + drawDistance >= FLandscape.Width * 8 then highOffX := FLandscape.Width * 8 - FX - 1 else highOffX := drawDistance;
1584 1589
  if FY + drawDistance >= FLandscape.Height * 8 then highOffY := FLandscape.Height * 8 - FY - 1 else highOffY := drawDistance;
1590
  {$HINTS on}{$WARNINGS on}
1585 1591

  
1586 1592
  FLandscape.PrepareBlocks((FX + lowOffX) div 8, (FY + lowOffY) div 8, (FX + highOffX) div 8 + 1, (FY + highOffY) div 8 + 1);
1587 1593

  

Also available in: Unified diff