HISMC crash upon play

i have setup-ed a simple c++ code with the Hierarchical instanced static mesh.

// in constructor 
static ConstructorHelpers::FObjectFinder<UStaticMesh> MountainMesh(TEXT("StaticMesh'/Game/Voronoi/Monkey.Monkey'"));
MountainSpawner = CreateDefaultSubobject<UHierarchicalInstancedStaticMeshComponent>(TEXT("MountainSpawner"));
MountainSpawner->RegisterComponent();
MountainSpawner->AttachTo(RootComponent);

MountainSpawner->SetStaticMesh(MountainMesh.Object);

for (int32 a = 0; a < 10; a++) {

	FRotator rotate = FRotator(0, FMath::RandRange(0, 360), 0);
	FVector Location = FVector(FMath::RandRange(0, SurfaceWidth*MapScale), FMath::RandRange(0, SurfaceHeight*MapScale), FMath::RandRange(-200, 0));
	int32 XYScale = FMath::RandRange(5, 12);
	FVector Scale = FVector(XYScale, XYScale, XYScale);
	MountainSpawner->AddInstance(FTransform(rotate, Location, Scale));
}

the last entry before the error in the log showed:
[2016.09.13-10.47.30:672][731]LogWindows:Error: Assertion failed: !IsAsyncBuilding() [File:D:\Build++UE4+Release-4.13+Compile\Sync\Engine\Source\Runtime\Engine\Private\HierarchicalInstancedStaticMesh.cpp] [Line: 2564]

I have no idea what is that!

It appeared fine in editor but crashed during play. Can someone point to what is wrong? Is it in the code or HISMC itself?

It appears that constructor doesnt like multiple instances of HISMC. I have to shift it to OnConstruction function. The below code is the solution.

void AHISMCSpawner::OnConstruction(const FTransform& Transform) {
Super::OnConstruction(Transform);
UE_LOG(LogTemp, Warning, TEXT("OnConstruction ZZ "));

MountainSpawner->ClearInstances();
for (int32 a = 0; a < 10; ++a) {

	FRotator rot = FRotator(0, FMath::RandRange(0, 360), 0);
	FVector loc = FVector(FMath::RandRange(0, SurfaceWidth*MapScale), FMath::RandRange(0, SurfaceHeight*MapScale), FMath::RandRange(-200, 0));
	int32 XYScale = FMath::RandRange(5, 12);
	FVector scale = FVector(XYScale, XYScale, XYScale);
	MountainSpawner->AddInstance(FTransform(rot, loc, scale));
}
}