UE4 Project not building

I have been trying to build a UE4 project all day long I don’t seem to be getting anywhere. Upon opening the .uproject file, I get the following prompt :

226876-prompt.png

When I click yes, the build fails and I get this message:

226877-error.png

I have tried building from source and what not, but nothing seems to help. When I try to open the visual studio solution file and building from there, I’m getting a couple of C1083 errors which say “No such file or directory”, and lists a few file names. I have however verified those file names to be present in the directory. Any help or a nudge in the right direction will be greatly appreciated.

PS - The project was built in UE 4.16 or 4.16.2. The only version in the 4.16 family available from the EpicGames Launcher is 4.16.3. I tried running it on 4.16.3, and I got the same errors. I then downloaded the engine source files from the EpicGames GitHub repo for version 4.16, built it from that, tried running the project on this built-from-source-version of the engine, and it still didn’t run.

That message indicates your project has C++ modules in it which needs to be recompiled. There should be a Source directory in your project’s home folder and you should be able to right click on the .uproject file and click on Generate Visual Studio project files to obtain a .sln file you can open in Visual Studio and Build.

If the source files are missing, you can still open the project by removing the dependency on those C++ modules, but very likely you won’t be able to run it if they are necessary.

For that you can manually edit the .uproject file and delete the section which looks like this (make sure you don’t break the syntax of the .uproject file; to play safe make a backup copy of it before editing):

"Modules": [
		{
			"Name": "PaintGame",
			"Type": "Runtime",
			"LoadingPhase": "Default",
			"AdditionalDependencies": [
				"Engine"
			]
		}
	],

This didn’t work for me, mainly because my .uproject file already looked like this, without any additional dependencies, I mean. I had to assume there was something wrong with the cloning process from github, because when I chose to simply download the project as a zip folder, the project ran just fine. Thank you for your time though, I’m sure this will help others.