I’m trying to find every level streaming volume in my persistent level, and compile them into an array:
TArray<ALevelStreamingVolume*> volumeList;
for (TObjectIterator<ALevelStreamingVolume> Itr; Itr; ++Itr)
{
volumeList.Add(&Itr);
}
I thought I did this correctly, but I’m getting a conversion error, “cannot convert from ‘TObjectIterator *’ to ‘ALevelStreamingVolume *’”. I thought Itr would be set to each volume in turn, do I need to be casting something before I can add the results to my array?