Obstacle Assault : CPP Build Error

Hey there everyone, I’ve run into a bit of a brick wall with the UE5 course, specifically during the project “Obstacle Assault”

I’m at the point where we are instructed to compile our C++ project in VS Code using the method of: Terminal => Run Build Task => ObstacleAssaultEditor Win64 Development Build

When I run this operation I get this error:

Unhandled exception: System.IO.DirectoryNotFoundException: Could not find a part of the path ‘H:\Unreal Engine\ObstacleAssault’

Some things I’ve tried after doing some google work:

  • Restarting my PC
  • Regenerating the project files (via a right click action on the .uproject file)
  • Recreating the whole project from the start
  • Deleting the folders: Binaries, Intermediate, Saved ; then regenerating the project files
  • Compiling the project with both the VS Code method and just using straight VS
  • Following the solution in this post (except I got the SDK for Win 11): Build error

The only thing I haven’t tried from my google searching is editing some registry files. I try to avoid doing this kind of thing as much as possible so I’ve come here instead to hopefully find a solution.

How is my project setup?

  • UE5 Installed on an SSD (not the C: drive)
  • Project files on an HDD (not the C: drive)

I suspect this setup with the engine and the project files being on two completely different drives might be part of the issue, but I have it this way with Unity and there are zero issues.

Thank you to whomever takes the time to help :slight_smile:

Here is a screenshot of my VS Window after trying to compile with the method shown in the video

Can you post a screenshot of the code within the ObstacleAssault.h please?

Here ya go :slight_smile:

Hmm ok wasn’t what I was thinking along that line, have you checked the code you have written for any spelling mistakes or any uncapitalized letters that need to be capitalized etc?

I haven’t been able to get to the actually coding part yet due to this error.
The only code is what is auto generated when you create the C++ actor.

I see I see, as you say in your original message you have the engine and the project on different drives, maybe try having them both in the same drive and try it then as it may be trying to look within the same drive as the engine? If that doesn’t work i’m all out of ideas but usually someone from the community team will reply within a few hours and hopefully they can figure out a solution for you

Best of luck!

Okay, so I looked at the error again and it was looking for a folder at the root of the drive the engine is installed on “H:/Unreal Engine” in my case.

So I created this folder, put the project in, and it works.

However; if anyone knows how I can have this project in a different folder than this I would love to know the solution!