ERROR: Game target not found. When building for android.

I posted this in the answerhub but I haven’t had much luck.

I’ve been trying to fix this all day and I’ve had no joy.

Recently I accidently added a c++ class to my blueprint project and ever since I’ve been unable to package the project for android.

This is the error the logs give me.


 
     BuildCookRun.SetupParams: Setting up ProjectParams for 
  InternalUtils.SafeFileExists: SafeFileExists C:\Users\No\AppData\Local\Temp\UAT\C+Program+Files+Epic+Games+UE_4.20\Rules\UATRules-2074089503.dll=False
  <>c.<PrintExceptionInfo>b__4_1: ==============================================================================
  <>c.<PrintExceptionInfo>b__4_0: ERROR: Game target not found. Game target is required with -cook or -cookonthefly
  <>c.<PrintExceptionInfo>b__4_0: (see for full exception trace)
  <>c.<PrintExceptionInfo>b__4_1: 
  <>c.<PrintExceptionInfo>b__4_1: AutomationException: Game target not found. Game target is required with -cook or -cookonthefly
  <>c.<PrintExceptionInfo>b__4_1: at AutomationTool.ProjectParams.AutodetectSettings(Boolean bReset) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\ProjectParams.cs:line 2087
  <>c.<PrintExceptionInfo>b__4_1: at AutomationTool.ProjectParams..ctor(FileReference RawProjectPath, BuildCommand Command, String Device, String MapToRun, String AdditionalServerMapParams, ParamList`1 Port, String RunCommandline, String StageCommandline, String BundleName, String StageDirectoryParam, String UE4Exe, String SignPak, List`1 ClientConfigsToBuild, List`1 ServerConfigsToBuild, ParamList`1 MapsToCook, ParamList`1 MapIniSectionsToCook, ParamList`1 DirectoriesToCook, String InternationalizationPreset, ParamList`1 CulturesToCook, ParamList`1 ClientCookedTargets, ParamList`1 EditorTargets, ParamList`1 ServerCookedTargets, List`1 ClientTargetPlatforms, Dictionary`2 ClientDependentPlatformMap, List`1 ServerTargetPlatforms, Dictionary`2 ServerDependentPlatformMap, Nullable`1 Build, Nullable`1 SkipBuildClient, Nullable`1 SkipBuildEditor, Nullable`1 Cook, Nullable`1 Run, Nullable`1 SkipServer, Nullable`1 Clean, Nullable`1 Compressed, String AdditionalPakOptions, Nullable`1 UseDebugParamForEditorExe, Nullable`1 IterativeCooking, String IterateSharedCookedBuild, Nullable`1 IterateSharedBuildUsePrecompiledExe, Nullable`1 CookAll, Nullable`1 CookPartialGC, Nullable`1 CookInEditor, String CookOutputDir, Nullable`1 CookMapsOnly, Nullable`1 CookOnTheFly, Nullable`1 CookOnTheFlyStreaming, Nullable`1 UnversionedCookedContent, Nullable`1 EncryptIniFiles, Nullable`1 EncryptPakIndex, Nullable`1 EncryptEverything, Nullable`1 SkipCookingEditorContent, Nullable`1 NumCookersToSpawn, String AdditionalCookerOptions, String BasedOnReleaseVersion, String CreateReleaseVersion, String CreateReleaseVersionBasePath, String BasedOnReleaseVersionBasePath, Nullable`1 GeneratePatch, Nullable`1 AddPatchLevel, Nullable`1 StageBaseReleasePaks, Nullable`1 GenerateRemaster, String DiscVersion, String DLCName, String DiffCookedContentPath, Nullable`1 DLCIncludeEngineContent, Nullable`1 DLCPakPluginFile, Nullable`1 DLCActLikePatch, Nullable`1 CrashReporter, Nullable`1 DedicatedServer, Nullable`1 Client, Nullable`1 Deploy, String DeployFolder, String GetFile, Nullable`1 FileServer, Nullable`1 Foreign, Nullable`1 ForeignCode, Nullable`1 LogWindow, Nullable`1 NoCleanStage, Nullable`1 NoClient, Nullable`1 NoDebugInfo, Nullable`1 SeparateDebugInfo, Nullable`1 MapFile, Nullable`1 NoXGE, Nullable`1 Package, Nullable`1 Pak, Nullable`1 Prereqs, String AppLocalDirectory, Nullable`1 NoBootstrapExe, Nullable`1 SignedPak, Nullable`1 NullRHI, Nullable`1 FakeClient, Nullable`1 EditorTest, Nullable`1 RunAutomationTests, String RunAutomationTest, Nullable`1 CrashIndex, Nullable`1 SkipCook, Nullable`1 SkipCookOnTheFly, Nullable`1 SkipPak, Nullable`1 PrePak, Nullable`1 SkipStage, Nullable`1 Stage, Nullable`1 Manifests, Nullable`1 CreateChunkInstall, Nullable`1 Unattended, Nullable`1 NumClients, Nullable`1 Archive, String ArchiveDirectoryParam, Nullable`1 ArchiveMetaData, Nullable`1 CreateAppBundle, ParamList`1 ProgramTargets, Nullable`1 Distribution, Nullable`1 Prebuilt, Nullable`1 RunTimeoutSeconds, String SpecifiedArchitecture, String UbtArgs, Nullable`1 IterativeDeploy, Nullable`1 FastCook, Nullable`1 IgnoreCookErrors, Nullable`1 RunAssetNativization, Nullable`1 CodeSign, Nullable`1 TreatNonShippingBinariesAsDebugFiles, Nullable`1 UseExtraFlavor, String Provision, String Certificate, String Team, Boolean AutomaticSigning, ParamList`1 InMapsToRebuildLightMaps, ParamList`1 InMapsToRebuildHLOD, ParamList`1 TitleID) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\ProjectParams.cs:line 1019
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at BuildCookRun.SetupParams() in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\Scripts\BuildCookRun.Automation.cs:line 52
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at BuildCookRun.ExecuteBuild() in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\Scripts\BuildCookRun.Automation.cs:line 39
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.BuildCommand.Execute() in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\BuildCommand.cs:line 112
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.Automation.Execute(List`1 CommandsToExecute, Dictionary`2 Commands) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\Automation.cs:line 562
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.Automation.Process(String] Arguments, StartupTraceListener StartupListener) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\Automation.cs:line 532
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.Program.MainProc(String] Arguments, StartupTraceListener StartupListener) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\Program.cs:line 174
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.Program.&lt;&gt;c__DisplayClass1_0.&lt;Main&gt;b__0() in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\Program.cs:line 100
  &lt;&gt;c.&lt;PrintExceptionInfo&gt;b__4_1: at AutomationTool.InternalUtils.RunSingleInstance(Func`1 Main) in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\AutomationUtils\Utils.cs:line 725
  <>c.<PrintExceptionInfo>b__4_1: at AutomationTool.Program.Main() in D:\Build\++UE4\Sync\Saved\CsTools\Engine\Source\Programs\AutomationTool\Program.cs:line 100
  <>c.<PrintExceptionInfo>b__4_1: ==============================================================================
  Program.Main: AutomationTool exiting with ExitCode=1 (Error_Unknown)
   
 

Does anyone have any idea why this might be happening?