Exporting a game for Windows
C# Debug/Release, x64 templates, separate and embedded PCK, package contents and launch checks.
Expected result
Export creates a Windows application rather than a copy of the editor. This guide uses Reckfell 1.0.0, C# and x86_64. The exporter also offers x86_32 and arm64, but they require matching templates and separate target-system testing. A listed option does not mean its template is installed.
Prepare the project
- Set the main document in project settings and verify it runs. Save modified documents and resources.
- Build C#. The expected
.sln, linked to the.csproj, must exist: the current C# exporter detects a .NET project through the solution file. A.csprojalone is insufficient. See C# setup. - Open Project → Export, add Windows Desktop and name the preset
Windows Desktop. The commands below use that preset name. - Select
binary_format/architecture = x86_64. In Editor → Manage Export Templates, check that 1.0.0 Debug and Release templates exist for that architecture. - Start with all resources selected for export. If you read JSON through FileAccess, add
*.jsonto the file inclusion filter. This is separate from selecting resources.
Select dotnet/embed_build_outputs = true to package C# build outputs inside the PCK. This option is off by default; separate C# data directories can otherwise appear beside the application. Preserve them.
First export
Choose Export Project, save Game.exe in a separate directory outside the source project and start with a Debug export. For a minimal check, disable application/modify_resources and codesign/enable to leave icon, metadata and signing changes until later.
| Output | What to do |
|---|---|
Game.exe | Launch the application |
Game.pck, when not embedded | Keep beside Game.exe with the same base name |
Game.console.exe, when the console wrapper is enabled | Use for diagnostic output; it is a helper, not a replacement for the main EXE |
| Additional DLLs and data directories | Distribute with the rest of the export outputs |
Do not rename the EXE or PCK independently. To distribute the game, ZIP the entire output directory. A ZIP containing application files is different from a ZIP used as the main resource pack.
Debug and Release from PowerShell
Replace the three paths with your own. A Windows Desktop preset must already exist. These commands use the installed editor; they do not require building engine source.
$engineExe = 'C:/Tools/Reckfell/Runtime/Reckfell Engine.console.exe'
$projectDir = 'C:/Projects/MyGame'
$buildDir = 'C:/Builds/MyGame'
New-Item -ItemType Directory -Force -Path "$buildDir/Debug", "$buildDir/Release" | Out-Null
& $engineExe --headless --path $projectDir --editor --export-debug 'Windows Desktop' "$buildDir/Debug/Game.exe"
if ($LASTEXITCODE -ne 0) { throw 'Debug export failed' }
& $engineExe --headless --path $projectDir --editor --export-release 'Windows Desktop' "$buildDir/Release/Game.exe"
if ($LASTEXITCODE -ne 0) { throw 'Release export failed' }Relative output paths are resolved from the project directory, not the terminal’s current directory. Check the log even when an EXE exists: partial output is not a successful build.
Embedded versus separate PCK
binary_format/embed_pck appends PCK data to the EXE. This is independent of dotnet/embed_build_outputs: the first places the pack; the second places C# build outputs. Embedding the PCK does not remove potential external extension or renderer dependencies.
The current Windows exporter requires the EXE plus embedded data to be less than 4 GiB: it rejects sizes at or above 4 GiB when fixing the PE header. This limit is source-reviewed; a boundary-sized package was not run. Use a separate PCK for large data.
Icon, metadata and signing
With application/modify_resources enabled, the exporter modifies EXE resources. application/icon takes priority over the project’s Windows-specific and general icon settings. For a custom ICO, see Windows icon.
Enable signing with codesign/enable. On Windows, set the SignTool path through export/windows/signtool and configure certificate details in the preset. RECKFELL_WINDOWS_CODESIGN_IDENTITY_TYPE, RECKFELL_WINDOWS_CODESIGN_IDENTITY and RECKFELL_WINDOWS_CODESIGN_PASSWORD override the corresponding confidential options. Do not put passwords in published commands or logs.
Verify icon changes and signing on the final file separately: the runs described below disabled these operations.
Verify before distribution
Run both Debug and Release from their output directories. Move the entire directory elsewhere and repeat. Check the main document, resources loaded through string paths, JSON/CSV, C# behavior, input, audio and saving to user://.
Then test on the target computer: a different GPU, installed .NET and absence of the editor can change launch conditions. Local testing does not replace that step.
| Symptom | First check |
|---|---|
| Template not found | Version, architecture, Debug/Release and installed template file |
| EXE exists but C# does not work | .sln, publish errors, .NET options and additional export files |
| Main pack not found | Game.pck name/location or the Embed PCK option |
| Data exists in editor but not in game | Resource selection, inclusion/exclusion filters and paths computed in code |
| Only a PCK exists | Export PCK/ZIP was used instead of Export Project |
Executed example: Windows x64 C# Debug with separate PCK and Release with embedded PCK, both using dotnet/embed_build_outputs = true. Both ran from an unrelated working directory and read a resource, UTF-8 JSON and project settings. This verifies packaging and C# execution, not graphics, signing or clean-machine installation.