Changeset 337 for trunk/Core.pas


Ignore:
Timestamp:
Sep 8, 2024, 10:29:37 PM (2 months ago)
Author:
chronos
Message:
  • Added: Game systems action in Tools menu.
  • Modified: TurnStats moved to separate unit.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Core.pas

    r336 r337  
    1616  TCore = class(TDataModule)
    1717    AAbout: TAction;
     18    AGameSystems: TAction;
    1819    ATests: TAction;
    1920    AFullscreen: TAction;
     
    5455    procedure AGameSaveAsExecute(Sender: TObject);
    5556    procedure AGameSaveExecute(Sender: TObject);
     57    procedure AGameSystemsExecute(Sender: TObject);
    5658    procedure AHelpExecute(Sender: TObject);
    5759    procedure ANewSpectatorClientExecute(Sender: TObject);
     
    130132uses
    131133  FormNew, FormSettings, ClientAI, FormKeyShortcuts, Common, FormEx, FormTests,
    132   FormHelp, FormUnitMoves, FormPlayersStats, ClientGUI, FormAbout, Tests;
     134  FormHelp, FormUnitMoves, FormPlayersStats, ClientGUI, FormAbout, Tests,
     135  FormGameSystems;
    133136
    134137const
     
    406409    Game.SaveToFile(Game.FileName)
    407410    else AGameSaveAs.Execute;
     411end;
     412
     413procedure TCore.AGameSystemsExecute(Sender: TObject);
     414var
     415  FormGameSystems: TFormGameSystems;
     416begin
     417  FormGameSystems := TFormGameSystems.Create(nil);
     418  try
     419    FormGameSystems.GameSystems := GameSystems;
     420    FormGameSystems.ShowModal;
     421  finally
     422    FreeAndNil(FormGameSystems);
     423  end;
    408424end;
    409425
Note: See TracChangeset for help on using the changeset viewer.