I’ve been offloading some C++ code into a plugin. The plugin—which is meant to expose functionality for the VRPN server to UE4 in such a way that it is accessible from Blueprints—builds fine and runs without issue. However, when open in Visual Studio 2013 Express it reports dozens of Intellisense errors which are enough to make editing code deeply unpleasant.
I used the UObject plugin from the 4.4 engine source as my base, and the errors appear even in the MyPluginObject class. The errors are many and varied (GENERATED_USTRUCT_BODY and GENERATED_UCLASS_BODY are both reported as identifiers that cannot be found) but I suspect they all stem from the very first one: MyPluginObject2.generated.h cannot be found. The ‘2’ at the end of MyPluginObject is there, incidentally, because I didn’t want to conflict with the example plugin that’s already loaded.
I found the generated files in \Intermediate\Build\Win64\Inc\Plugins, so they are being generated. I checked, and in a rebuild, they are duly re-generated as they ought to be. If I wire their include path directly into the project settings the code still compiles, but the Intellisense errors change: They now report an invalid friend declaration in the GENERATED_UCLASS_BODY() macro.
Now, I have googled this quite a bit and I did find a few places where I’m basically told to give up on Intellisense as borderline useless. However, the official documentation on integrating VS2013 with UE4 explicitly says to turn on Intellisense, and I’d quite like to use it. Which is true? And how do I fix this problem?
 The engine version I have to use for non-technical reasons.