Engine build profile
Feature disabling, C# detection limits and observed profile reload defects.
Engine build profile
A profile describes classes and features to disable during compilation. It does not modify the installed Runtime, shrink an existing EXE or automatically apply during ordinary project export. Reducing the binary requires a separate export template built with that profile.
Prepare a profile
- Open Project → Tools → Engine Compilation Configuration Editor…. Labels depend on interface language; this is the build configuration editor.
- Save a separate file with Save As, such as
profiles/game.build. Add it to version control; do not begin by overwriting a working profile. - Remove only features whose absence you can verify. Start with a minimal change from a normal template, then reduce further.
- Save a copy before Detect from Project: detection rebuilds the disabled-class list and resets options before analyzing again. It does not merge with manual exclusions.
Automatic detection limits
The current editor explicitly warns that used-class detection in C# scripts is unsupported and those files are skipped. Do not treat the result as a ready safe profile for a C# game.
Project-file analysis also does not establish coverage of classes selected by runtime strings, resources from external packs or optional game modes. List those requirements separately. Forced Classes on Detect accepts exact comma-separated class names, such as Entity3D. It supplements analysis rather than replacing module and dependency checks.
A class existing in the C# SDK does not prove it remains in a stripped native template. Check saving, loading, gameplay paths and resources with the intended template and managed-assembly set.
File format
For a project without XR, this minimal example disables XR and the OpenXR module:
{
"type": "build_profile",
"disabled_classes": [],
"disabled_build_options": {
"disable_xr": true,
"module_openxr_enabled": false
}
}disabled_classes contains native class names rather than level filenames or game C# classes. Each disabled_build_options value follows its SCons option: disable_xr: true disables the feature, while module_openxr_enabled: false disables the module. The dictionary name does not mean every value should be true. The editor saves differences from its own defaults rather than a complete list of effective build options.
Known reload defect
The installed editor was confirmed to mark a known option disabled based on its key being present, ignoring its value. A file can therefore change meaning after opening and saving:
| Before loading | After editor save |
|---|---|
disable_3d: false | disable_3d: true |
module_text_server_fb_enabled: true | The explicit enable is lost: the key disappears from output. |
Do not treat resaving as an unconditionally safe profile transformation. Compare the diff with the original and check enabled options separately. Opening successfully does not mean values retain their meaning. This defect was not fixed in this pass.
SConstruct reads dictionary values and assigns them to build options, a separate path from the editor dialog loader. Preserve a manually checked file without unnoticed subsequent rewriting. This does not establish successful compilation: the build overview also records the current SCons helper limitation.
Apply and verify
After preparing a consistent build environment, pass the file path in build_profile for the required template_debug or template_release. Commands run from Source; the path must resolve to a real file. The profile itself neither installs a template into an export preset nor builds the .NET set.
Compare size against the original template with the same platform, arch, target, modules and other options. Then test export, all game modes, dynamic resource loading and saved data. A small EXE that cannot load a required level is not a successful result. See size optimization for additional options.
An isolated headless editor exercised import/save of the exact JSON example, class list and forced text, and reproduced two value defects. It used native file-dialog signals rather than manual clicks or layout inspection. Detection, template compilation, size reduction and export were not checked in this run. Engine Source, Runtime and SDK were unchanged.