Noob Q: Private/Public folders for blank VS project?

Hey Everyone,

Using the holidays to get back into learning UE4 C++, have an OCD problem I wanted to ask about.

I like the way that the example third person C++ project puts .h files into a public folder and the .cpp files into a private folder in the VS solution that gets made when you make one of the example games.

But the basic code template doesn’t do it, and I haven’t been able (yet) to figure out how to set it up manually in VS. Any tips?

If you create the Folders manually in Explorer then create your new class in the ‘Classes’ folder, it’ll automatically put the corresponding .cpp in the public or private folder, depending on which you choose :slight_smile:

You can also use sub-folders within there too, and it’ll follow along :slight_smile:

It seems that creating the Private and Public folders yourself and then regenerating your VS project files may do the trick, it did in an earlier version anyway. Source:

Ah, cool :slight_smile:

Didn’t know about regenerating the VS project files.

(Right click on .uproject file in explorer for anyone else who didn’t know either).

Hi I tried to do this but it seems to not work with UE 4.7.

Any idea ?

By the way what is the advantages of this structure ?

Apparently this answer to my question …