I am just writing down the steps I take to compile Unreal Tournament 4 from the GitHub source and mention any problems I encounter.
If you plan to use these steps as a guide on how to compile UT4 for yourself, I recommend reading through the steps first! I made some mistakes, so make sure you don't make the same mistakes 🙂
Prerequisites
- TortoiseGit https://code.google.com/p/tortoisegit/
- Visual Studio 2013
- A GitHub account associated with an Unreal Engine 4 account
Downloading the source
Use TortoiseGit to download all UT and UE4 sourcecode from https://github.com/EpicGames/UnrealTournament.git
Use right mouse button on a folder and choose "Git Clone...".
Log in with your GitHub username and password and it will start downloading.
Download additional necessary binary content
Run [UnrealTournament\Setup.bat] to download necessary additional binary content.
Compiling the Unreal Tournament project
- Open up [UnrealTournament\Engine\Source\Programs\UnrealSwarm\UnrealSwarm.sln] with Visual Studio 2013.
- Select "Development" as the Solution Configuration.
- Compile the whole solution, why not.
- Then you can close the solution.
- Run [UnrealTournament\GenerateProjectFiles.bat] to generate UE4.sln
- Open [UnrealTournament\UE4.sln] with Visual Studio 2013.
- Set the Solution Configuration to "Development Editor".
- Build "ShaderCompileWorker" and "UnrealLightmass".
- When that's done, compile the "UnrealTournament" project. This can take quite a while.
- After it is done compiling, rightclick the "UnrealTournament" project and select Debug > Start new instance.
- The UE4 editor will start.
- Press "Launch" to start Unreal Tournament. The first time this can take a long time.
- This took like forever, only to be greeted by this error:
LogPlayLevel: Running AutomationTool... LogPlayLevel: RunUAT.bat ERROR: Visual studio and/or AutomationTool.csproj was not found, nor was Engine\Binaries\DotNET\AutomationTool.exe. Can't run the automation tool.
- Apparently we also needed to compile this "AutomationTool"!
- Close the editor, and compile the "AutomationTool" project under "Programs".
- Once again, start the editor and press "Launch".
- Hurrah! More errors:
LogPlayLevel: Program.Main: ERROR: AutomationTool terminated with exception: LogPlayLevel: Program.Main: ERROR: Exception in AutomationTool: AutomationScripts.Automation.dll was not found or could not be loaded, can't run scripts. LogPlayLevel: Stacktrace: at AutomationTool.ScriptCompiler.LoadPreCompiledScriptAssemblies(List`1 OutScriptAssemblies) in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\ScriptCompiler.cs:line 256 LogPlayLevel: at AutomationTool.ScriptCompiler.FindAndCompileAllScripts(List`1 AdditionalScriptsFolders) in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\ScriptCompiler.cs:line 87 LogPlayLevel: at AutomationTool.Automation.Process(String[] CommandLine) in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\Automation.cs:line 324 LogPlayLevel: at AutomationTool.Program.MainProc(Object Param) in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\Program.cs:line 168 LogPlayLevel: at AutomationTool.InternalUtils.RunSingleInstance(MainProc Main, Object Param) in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\Utils.cs:line 705 LogPlayLevel: at AutomationTool.Program.Main() in d:\my_projects\UnrealTournament\Engine\Source\Programs\AutomationTool\Program.cs:line 115 LogPlayLevel: Program.Main: ERROR: AutomationScripts.Automation.dll was not found or could not be loaded, can't run scripts.
- Perhaps we also need to compile the "AutomationScripts.Automation" project.
- Close the editor, and compile ALL PROJECTS under Programs/Automation, just to be sure.
- Again, start the editor and press "Launch".
- Now it starts compiling UnrealTournament from within the editor. Once more this will take a while...
- After a loooong time, I get this error! 🙁
- I have no idea how to fix this error!
- I asked on the forums what the deal is: https://forums.unrealtournament.com/showthread.php?16535-UnrealTournament-exe-incompatible-with-64-bit-windows-(16-Bit-Application)
- Apparently you cannot start the game from within the editor (yet).
- This took like forever, only to be greeted by this error:
- To start the compiled UT4 game, in the UnrealTournament project, set Command Arguments under Debugging to "unrealtournament -game" and start debugging it! Again, rightclick the "UnrealTournament" project and select Debug > Start new instance.
- Hurrahh
References
- https://github.com/epicgames/unrealtournament
- https://wiki.unrealengine.com/Getting_Started_With_Unreal_Tournament#Building_the_Editor_and_Game
- https://code.google.com/p/tortoisegit/
- https://forums.unrealtournament.com/showthread.php?16535-UnrealTournament-exe-incompatible-with-64-bit-windows-(16-Bit-Application