Unreal Tournament Integration¶
Building the Unreal Tournament sample using the Genvid SDK has 2 main steps. First you set up and build the base Unreal Tournament project, then you modify it to use the Genvid SDK.
Before You Begin¶
If you don’t have the Unreal Tournament source code, you’ll need to download it from the Unreal Tournament GitHub repository.
Important
You need to connect your Epic Games and GitHub accounts in order to access the repository. If you haven’t connected your accounts, instructions are on the Unreal Engine website.
Important
Make sure you review the Required Third-Party Software section while you’re on the Unreal Tournament GitHub page.
Note that the initial download, build, and first run of the game may take some time.
Set Up Unreal Tournament¶
To build and run the Genvid SDK Unreal Tournament sample, you first need a working build of the original Unreal Tournament project.
You’ll need to sync to a specific changelist to ensure you have the correct version of the Unreal Engine for our sample. You’ll also need to add in a missing header for the game to compile correctly.
Run the following Git command to sync to the required changelist.
git checkout 27e91ad5b439cfe698b2d1345432983ccfbc0936
In
Engine/Source/Programs/UnrealWatchdog/Private/UnrealWatchdog.cpp
, add the following line immediately after the last include directive:#include "EngineBuildSettings.h"
Follow the remaining instructions for setting up the Unreal Tournament project on the main page of the repository.
Verify you have a working Unreal Tournament build before proceeding.
Add the Genvid SDK to Unreal Tournament¶
The Genvid SDK includes script and configuration files in the
samples/ue4/ut4
folder which automate much of the integration process.
You need to add the Unreal Tournament installation to your environment
variables and modify the UT code to make the GenvidPlugin interfaces available.
Set
UTROOT
to your Unreal Tournament directory.How you set
UTROOT
depends on the shell you use. For example, on Windows you use the following command:set UTROOT=C:\UnrealTournament
Run the
ut4.py
script to add necessary files and make required modifications to existing files.py ut4.py prepare
For reference, this script will:
- Copy
GenvidPlugin
toUnrealTournament/Plugins/
. - Copy the
Genvid
module toUnrealTournament/Source/
. - Copy
GenvidConnector.h
toUnrealTournament/Source/UnrealTournament/Public/
. - Copy
GenvidConnector.cpp
toUnrealTournament/Source/UnrealTournament/Private/
. - Copy
GenvidGameStateBase.h
toUnrealTournament/Source/UnrealTournament/Public/
. - Copy
GenvidGameStateBase.cpp
toUnrealTournament/Source/UnrealTournament/Private/
. - Copy
Content
toUnrealTournament/
. - Copy
DefaultEngine.ini
toUnrealTournament/Config
.
- Copy
Open
\Source\UnrealTournament\UnrealTournamentBuild.cs
.At the end of the
public UnrealTournament(TargetInfo Target)
routine, add the following lines:PrivateIncludePaths.Add("Genvid/Private"); PublicIncludePaths.Add("Genvid/Public"); PublicDependencyModuleNames.Add("Genvid");
Build Unreal Tournament.
py ut4.py build