Create HierarchicalInstancedStaticMeshComponent from C++

Currently I am able to make an InstancedStaticMeshComponent, and add instances using UInstancedStaticMeshComponent, and initializing with CreateDefaultSubobject.

I am assuming to get to hierarchical, I need to initialize as something other that default subobject, yet I am unsure how to do this?

Thanks - rn

Posting this for others who need it, as there is no info on it (outside the engine itself).

Same as an instanced static mesh, but you must include the header (is there a reason this isn’t done automatically, like with regular instancedstaticmesh.h ?

#include "Components/HierarchicalInstancedStaticMeshComponent.h"