Hello all, this article will talk briefly about an Unreal Engine 4 custom build option for overriding configuration INI values in a packaged build. We created and used this option effectively in our recent game, Megalith.

To start, our build process for the title in Unreal 4 revolves around the very common model of triggering build processes with the Unreal Build Tool (UBT) and all its accompanies facilities. These all tend to be bootstrapped by calls to a batch file living in their source tree //Engine/Build/BatchFiles/RunUAT.bat.

Because we run our own dedicated servers in order to try to provide the best user experience (and side stepping some of the nastier issues such as compromised clients and host migration), we developed a relatively simple batch file that would do all the work we needed to kick off client and server builds with the appropriate settings.

In order to allow each developer to test in their own sandbox, we needed different builds to be able to hit different dedicated servers and server pools; these values are built into parts of our ini file in a format like so:

[OnlineSubsystemMegalith]

BuildId=678

BuildTime=SomeTime

MegalithMatchConfig=some_context_string

This is all well and simple for a development environment, but we needed these values to be modified for the build, and we certainly want to reduce the amount of human involvement in the build process as much as possible.