This article covers a detailed walk through of the steps that are required to successfully compile and run the blank C++ project template with a custom engine cloned from Git.
Setup Custom Engine
- Download and install the latest CRYENGINE Launcher - available from cryengine.com
- Create a New C++ blank project from the CRYENGINE Launcher. This will download the corresponding release version of the Engine (if it has not been installed previously)
- Run the following git command to make a local clone for your custom engine git clone --branch release https://github.com/CRYTEK-CRYENGINE/CRYENGINE.git
- Run cry_waf.exe from the custom engine and create a gamesdk project. Open the generated solution and compile [GameSDK] Profile x64
- Copy system.cfg and the folder named engine from a release build to the custom engine. You can easily find the location of a downloaded release Engine by navigating to "Library/Installed Engines" from within the CRYENGINE Launcher and selecting "Reveal in Explorer" from the Engine versions dropdown button. If you avoid this step the custom engine will crash due to missing DDS files
Associate Project With Custom Engine
- Right-click on the .cryproject file in your project folder, and select Switch engine version
- Use the browse button (...) to add a custom engine not previously registered. Select the root folder of the custom engine; the folder that contains cry_waf.exe
- Select the custom engine in the dropdown-list and press OK to switch the Engine version used by the project.
- Right-click on the .cryproject to Generate solution and Build solution with the new custom engine
- If no error occurred, you may now Launch game with your custom engine
See comments below for issues regarding Sandbox and custom engines.
Debugging the engine with a loaded project
- Right-click on the WindowsLauncher or Sandbox target in Visual Studio
- Select Properties
- Select Debugging under Configuration Properties
- Change the 'Command Arguments' text box value to "-project C:/FirstPersonShooter/Game.cryproject" - without citation marks and a full path to the cryproject you want to debug the engine with.
- We do not provide Sandbox with the custom engine, therefore Launch editor will not work after associating project with a custom engine
- Also, the custom engine modifications a user can carry out will be limited to 'minor changes' - this ensures that the Game.dll remains compatible with the release version of Sandbox and the custom engine.