Package a game for Windows or macOS - AWS GameKit

Package a game for Windows or macOS

When packaging your game for distribution on Windows or macOS, complete the following tasks.

Unreal Engine

For Unreal Engine game projects, use the Unreal Engine project packaging instructions with the following modifications.

  1. Before you start the packaging setup process, verify your current AWS GameKit plugin configuration. The Unreal packaging process uses whichever AWS GameKit configuration settings are currently active. In the Unreal Editor toolbar, open Edit, Project Settings and go to the AwsGameKit plugin section. In the Environment and Credentials section, verify the selections for game title, environment, and region.

  2. Complete the Unreal packaging step "Setting a Game Default Map".

  3. Add the AWS GameKit configuration in the packaging settings.

    1. In the Unreal Editor toolbar, choose Edit, Project Settings, Packaging, and expand the Packaging advanced settings, as shown.

    2. In Additional Non-Asset Directories to Copy, add an array element and enter the value GameKitConfig.

  4. When you're ready to package your game for shipping, use the Unreal automation tool's BuildCookRun command. Exit the Unreal Editor, open a command prompt, and run the following command (modified for your game project). If you create your game packages in the Unreal Editor, the AWS GameKit plugin uses the .dll files in the game's Binaries\ directory instead of the Shipping build configuration.

    To package a game for Windows (from a Windows device):

    "C:\Program Files\Epic Games\UE_4.27\Engine\Binaries\DotNET\AutomationTool.exe" -ScriptsForProject="[PATH_TO_GAME].uproject" BuildCookRun -nocompileeditor -installed -nop4 -project="[PATH_TO_GAME].uproject" -cook -stage -archive -archivedirectory=[DESTINATION_DIRECTORY_ROOT] -package -ue4exe="C:\Program Files\Epic Games\UE_4.27\Engine\Binaries\Win64\UE4Editor-Cmd.exe" -ddc=InstalledDerivedDataBackendGraph -pak -prereqs -nodebuginfo -targetplatform=Win64 -build -target=[UNREAL_PROJECT_NAME] -clientconfig=Shipping -utf8output
    • [PATH_TO_GAME] – The directory path to your game project files (for example: C:/Unreal Projects/MagicChickenGame/MagicChickenGame).

    • [DESTINATION_DIRECTORY_ROOT] – A target location for the completed packaged product (for example: C:\Archive).

    • [UNREAL_PROJECT_NAME] – The name associated with your Unreal game project (for example: MagicChickenGame).

    To package a game for macOS (from a macOS device):

    /Users/Shared/Epic\ Games/UE_4.27/Engine/Build/BatchFiles/RunUAT.sh -ScriptsForProject="[PATH_TO_GAME].uproject" BuildCookRun -nocompileeditor -installed -nop4 -project="[PATH_TO_GAME].uproject" -cook -stage -archive -archivedirectory=[DESTINATION_DIRECTORY_ROOT] -package -ue4exe="/Users/Shared/Epic Games/UE_4.27/Engine/Binaries/Mac/UE4Editor.app/Contents/MacOS/UE4Editor" -compressed -ddc=InstalledDerivedDataBackendGraph -pak -prereqs -nodebuginfo -targetplatform=Mac -build -target=[UNREAL_PROJECT_NAME] -clientconfig=Shipping -utf8output
    • [PATH_TO_GAME] – The directory path to your game project files (for example: /Users/amansa/Documents/Unreal\ Projects/MagicChickenGame/MagicChickenGame).

    • [DESTINATION_DIRECTORY_ROOT] – A target location for the completed packaged product (for example: /Users/amansa/Documents/Unreal\ Projects/Archive).

    • [UNREAL_PROJECT_NAME] – The name associated with your Unreal game project (for example: MagicChickenGame).