In this lesson, you will learn how to leverage the Unreal Automation Tool (UAT) to orchestrate hands-free packaging of your project, ensuring consistent deployment cycles without manual editor intervention.
Why Automate?
As your project grows—especially with massive World Partition levels—packaging manually through the Editor becomes error-prone and time-consuming. UAT is a powerful command-line interface that allows you to script your build pipeline. By treating your packaging process as a build script, you remove human error and ensure that every build is generated in a clean, reproducible state.
Executing the Build Script
UAT is driven by the RunUAT.bat (Windows) or RunUAT.sh (macOS/Linux) script located in your Engine’s Engine/Build/BatchFiles directory. To package your project, you essentially pass the BuildCookRun command to this script.
A typical command-line call looks like this:
RunUAT.bat BuildCookRun -project="C:/MyProject/MyProject.uproject" -noP4 -platform=Win64 -clientconfig=Shipping -serverconfig=Shipping -cook -allmaps -build -stage -pak -archive -archivedirectory="C:/Builds"
Breaking Down the Command
-project: Points UAT to your project file.-cook: Invokes the cooking process, which converts assets into the platform-specific format.-build: Compiles your game binaries.-stage: Copies the cooked content and binaries into a single directory ready for deployment.-archive: Instructs UAT to move the finished, packed game into your specified output folder.
By placing this command into a .bat or .ps1 file, you can trigger your entire packaging cycle with a single double-click. This is essential for continuous integration (CI) workflows where you might want to automate daily builds of your terrain-heavy levels to check for landscape material errors or streaming performance regressions without opening the editor. Using flags like -unattended ensures the process won't hang waiting for user input, allowing it to run perfectly on remote build machines or background servers.
Key Takeaway: By wrapping your deployment steps in a UAT script, you transform a fragile, manual packaging workflow into a robust, repeatable command-line process that safeguards build consistency.