Hi @MaroonBerats !
I’m having trouble understanding your question, but I think you are asking about the destruction of actors.
In Unreal an Actor lifecycle is described right here
As seen above, there are plenty of ways for an Actor to be destroyed, after it is signaled to be destroyed, it begins the EndPlay phase, then the actor is marked as pending kill, then it’s removed from the array of all actors (i.e. GetAllActors), then the garbage collector is going to remove all references to that actor, and finally BeginDestroy, IsReadyForFinishDestroy and FinishDestroy.
In Unreal an Actor only destroys itself and its components (NOT their child actors, and neither do the actors that inherit from the same class). As for your question, I think you are trying to destroy first a B actor, then an A actor, and in C++.
For that there are plenty of ways, but the easiest would be to override the OnBeginDestroy on B and then inside it
B.h
virtual void BeginDestroy() override;
B.cpp
void AB::BeginDestroy()
{
A->Destroy(); //assuming you have a reference to A on B
Super::BeginDestroy();
}
This will begin destroying A after destroying B.