Hi!
We are using World Partition for our level streaming setup and have a system that binds to the OnLevelAdded callback. When that fires we want to gauge the bounds of the newly loaded level to determine whether this newly loaded level overlaps with an area of interest to initialize a particular state on its actors.
we are using the following snippet to get the bounds
if (InLevel->LevelBoundsActor.IsValid())
{
LevelBounds = InLevel->LevelBoundsActor.Get()->GetComponentsBoundingBox();
}
else
{
LevelBounds = ALevelBounds::CalculateLevelBounds(InLevel);
}
Ultimately it looks like world partition does not generate LevelBoundsActors for its cells automatically, so we see us falling back to CalculateLevelBounds, which can be very costly based on the amount of actors in the level.
Now for the question; It seems that the core of our issue is that we don’t have LevelBounds actors, generating these manually seems like the wrong approach to this problem as world partition is handling the splitting up of our game world.
Is there a better way with world partition to get the bounds for the loaded level cell if it does not generate the LevelBounds actor internally automatically? And if there is not, how could we best approach adding the generation of such an actor into the world partition system?
Thank you!
[Attachment Removed]