TArray<AActor*> Add

It is likely that the method you are calling stellarBodies.Add(cur) in is const. Can you check that?