How to have different collision profiles on different components in c++?

What I would like to setup is an actor that has various components with staticmeshes attached, but some that have different collision settings. For example, I have a player ship, which attaches a mining component to it. That mining component has a forcefield at the end of it. I want the playership and the mining component to BlockAll, but the forcefield to OverlapAll.

Currently I’m spawning the mining component, and then in InitializeComponent() I’m dynamically creating the forcefield, and attaching it to the mining component. Then I attach the mining component to the playership.

No matter what I try, the mining component and the force field end up sharing the same collision settings (both BlockAll or both OverlapAll). How do I prevent this?

Heres my code to spawn the forcefield (MiningActiveComponent):

MiningActiveComponent = ConstructObject<UStaticMeshComponent>(UStaticMeshComponent::StaticClass(), this);
	if (!MiningActiveComponent)
	{
		GEngine->AddOnScreenDebugMessage(-1, 10.0f, FColor::Red, FString("Creating MiningActiveComponent failed!"));
		return;
	}
	
	MiningActiveComponent->SetStaticMesh(MiningActiveMesh);
	MiningActiveComponent->AttachTo(this, MiningActiveSocket,EAttachLocation::KeepRelativeOffset,true);
	MiningActiveComponent->SetVisibility(false, true);

	SetCollisionProfileName(TEXT("BlockAll"));
	MiningActiveComponent->SetCollisionProfileName(TEXT("OverlapAll"));

	MiningActiveComponent->RegisterComponentWithWorld(GetWorld());

And Here’s my code to attach the new equipment to the player ship:

UEquipmentComponent* NewEquipment = ConstructObject<UEquipmentComponent>(EquipmentToAttach,this);
	if (!NewEquipment)
	{
		GEngine->AddOnScreenDebugMessage(-1, 10.0f, FColor::Red, FString("Creating equipment component failed!"));
		return;
	}
	
	FName SocketName = FName(*SocketNames[(int)AttachmentPoint]);
	NewEquipment->AttachTo(StaticMeshComponent, SocketName,EAttachLocation::KeepRelativeOffset,true);
	NewEquipment->SetVisibility(true,true);
	NewEquipment->PlayerPawn = this;
	NewEquipment->RegisterComponentWithWorld(GetWorld());
	NewEquipment->ReceiverID = UniqueID;
	NewEquipment->PostAttach();

And finally I call this after attaching the equipment to the player ship:

void UMiningComponent::PostAttach() 
{ 
	GEngine->AddOnScreenDebugMessage(-1, 10.f, FColor::Green, FString("PostAttach"));
	SetCollisionProfileName(TEXT("BlockAll"));
	MiningActiveComponent->SetCollisionProfileName(TEXT("OverlapAll"));
	SetCollisionProfileName(TEXT("BlockAll"));
	return; 
}

No matter what I try, I can’t get it to work. I’m using 4.7.6.

Any suggestions?

Ok, it works if I disable physics via:

MiningActiveComponent->SetSimulatePhysics(false);
SetSimulatePhysics(false);