Thanks Lawlcat, i never thought about getting a pointer to the TArray. Although, i still don’t know how to add a pointer into that TArray. For example my code is:
AAStar* const cur = GetWorld()->SpawnActor<AAStar>(AAStar::StaticClass(), FVector::ZeroVector, FRotator::ZeroRotator);
const TArray<AAStar*>* stellarBodiesRef = &stellarBodies;
stellarBodiesRef->Add(&cur);
Also, i am not sure what the pointer to the TArray (stellarBodiesRef) actually gives me as i can call
stellarBodies.Add(XYZ);
without the additional pointer (stellarBodiesRef).
Error on the “add” line. No instance of overloaded function…