unit uFGame;

{$mode delphi}

interface

uses
  Classes, SysUtils;
type

  { TFGame }

  TFGame = class
    MapX, MapY : Integer;
    MapW, MapH : Integer;
    W, H : Byte;
    SelX, SelY : Byte;
    Alpha : Byte;
    Sel : Boolean;
    GWin,
    Disable : Boolean;

    procedure Select(pX, pY : Byte);
    procedure Start(pW, pH : Byte); virtual;
    procedure Draw; virtual; abstract;
    procedure Update(msX, msY : Integer); virtual; abstract;
  end;

implementation
uses
  uGlobal;

{ TFGame }

procedure TFGame.Select(pX, pY: Byte);
begin
  SelX := pX;
  SelY := pY;
  Sel := true;
end;

procedure TFGame.Start(pW, pH: Byte);
begin
  W := pW;
  H := pH;
  MapW := cRectSize * W;
  MapH := cRectSize * H;
  MapX := (WinW - MapW) div 2;
  MapY := (WinH - MapH) div 2;

  Disable := false;
  Alpha := 10;
  GWin := false;
end;

end.

