1. Castle Game Engine Installation

  1. Download the latest Castle Game Engine. Unpack the engine ZIP wherever you like.

  2. Inside the unpacked castle_game_engine, you will find a subdirectory bin. Run the castle-editor executable inside.

2. Install compiler and IDE

Next, you should install

  • a Pascal compiler (we support FPC and Delphi)

  • and a Pascal IDE (like Lazarus, Delphi, Visual Studio Code, or any other text editor you prefer).

For a fully open-source cross-platform environment we recommend FPC and Lazarus.

2.1. FPC and Lazarus

  1. Go to the Lazarus website and download the latest release. It contains both Lazarus (IDE) and FPC (compiler) in one easy download.

    Lazarus website

    You can install FPC and Lazarus in other ways, for example using FpcUpDeluxe.
    If you prefer other IDE than Lazarus, you can install only FPC and use any Pascal code editor you like, like Visual Studio Code.
  2. Configure FPC and Lazarus locations in Castle Game Engine editor Preferences, if they have not been auto-detected correctly.

    Castle Game Engine Editor Preferences

  3. In Castle Game Engine editor Preferences, go to tab FPC and Lazarus and click on the button "Register Lazarus Packages". This will allow to compile and debug CGE applications inside Lazarus.

    Lazarus packages registration confirmation

2.2. Alternative: Delphi

  1. Download Delphi.

    Free Community Edition is fine. Though it doesn’t have a working dcc compiler, so compiling using F9 in CGE editor will not work. But you can simply open the project in Delphi and use F9 from Delphi.
  2. In Castle Game Engine editor, open Preferences dialog. In both the Code Editor and Compilation tabs set Delphi, if it was not auto-detected automatically.

To improve this documentation just edit the source of this page in AsciiDoctor (simple wiki-like syntax) and create a pull request to Castle Game Engine WWW (cge-www) repository.