Im getting an error while compiling. Please help me out

Compilor Log:

Building BullCowGameEditor…
Using Visual Studio 2019 14.28.29336 toolchain (C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333) and Windows 10.0.18362.0 SDK (C:\Program Files (x86)\Windows Kits\10).
[Upgrade]
[Upgrade] Using backward-compatible build settings. The latest version of UE4 sets the following values by default, which may require code changes:
[Upgrade] bLegacyPublicIncludePaths = false => Omits subfolders from public include paths to reduce compiler command line length. (Previously: true).
[Upgrade] ShadowVariableWarningLevel = WarningLevel.Error => Treats shadowed variable warnings as errors. (Previously: WarningLevel.Warning).
[Upgrade] PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs => Set in build.cs files to enables IWYU-style PCH model. See https://docs.unrealengine.com/en-US/Programming/BuildTools/UnrealBuildTool/IWYU/index.html. (Previously: PCHUsageMode.UseSharedPCHs).
[Upgrade] Suppress this message by setting ‘DefaultBuildSettings = BuildSettingsVersion.V2;’ in BullCowGameEditor.Target.cs, and explicitly overriding settings that differ from the new defaults.
[Upgrade]
Distributing 5 actions to XGE
--------------------Build System Warning---------------------------------------
License is invalid:
License information is invalid. Please try reloading your license file using the Coordinator Monitor application on the Coordinator machine, or reinstall IncrediBuild.
This build will run in standalone mode.


--------------------Project: Default-------------------------------------------
BullCowCartridge.cpp (0:00.40 at +0:00)
C:\Users\Sarim\Downloads\BullCowGame-starter-kit\BullCowGame-starter-kit\Source\BullCowGame\BullCowCartridge.cpp: fatal error C1853: ‘C:\Users\Sarim\Downloads\BullCowGame-starter-kit\BullCowGame-starter-kit\Intermediate\Build\Win64\BullCowGameEditor\Development\Engine\SharedPCH.Engine.h.pch’ precompiled header file is from a different version of the compiler, or the precompiled header is C++ and you are using it from C (or vice versa)

Error executing D:\Program Files\Epic Games\UE_4.26\Engine\Build\Windows\cl-filter\cl-filter.exe (tool returned code: 2)
BullCowCartridge.gen.cpp (0:00.42 at +0:00)
C:\Users\Sarim\Downloads\BullCowGame-starter-kit\BullCowGame-starter-kit\Intermediate\Build\Win64\UE4Editor\Inc\BullCowGame\BullCowCartridge.gen.cpp: fatal error C1853: ‘C:\Users\Sarim\Downloads\BullCowGame-starter-kit\BullCowGame-starter-kit\Intermediate\Build\Win64\BullCowGameEditor\Development\Engine\SharedPCH.Engine.h.pch’ precompiled header file is from a different version of the compiler, or the precompiled header is C++ and you are using it from C (or vice versa)

Error executing D:\Program Files\Epic Games\UE_4.26\Engine\Build\Windows\cl-filter\cl-filter.exe (tool returned code: 2)
---------------------- Done ----------------------

Rebuild All: 0 succeeded, 1 failed, 0 skipped

1 build system warning(s):

  • License is invalid

This is my code

precompiled header file is from a different version of the compiler, or the precompiled header is C++ and you are using it from C (or vice versa)

You will need to rebuild.

Ctrl + Shift + B > ProjectNameEditor Win64 Development Rebuild.

Oh it looks like you’re using VS 2019 in which case you can find Rebuild from the Build drop down menu.

thank you so much

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.