Large map manager stream distance is set in editor.
This commit is contained in:
parent
56b7bfb3f9
commit
e50ffbeea3
|
@ -91,6 +91,14 @@ void FCarlaEngine::NotifyBeginEpisode(UCarlaEpisode &Episode)
|
|||
Episode.EpisodeSettings.FixedDeltaSeconds = FCarlaEngine_GetFixedDeltaSeconds();
|
||||
CurrentEpisode = &Episode;
|
||||
|
||||
// Reset map settings
|
||||
UWorld* World = CurrentEpisode->GetWorld();
|
||||
ALargeMapManager* LargeMapManager = UCarlaStatics::GetLargeMapManager(World);
|
||||
if (LargeMapManager)
|
||||
{
|
||||
CurrentSettings.TileStreamingDistance = LargeMapManager->GetLayerStreamingDistance();
|
||||
CurrentSettings.ActorActiveDistance = LargeMapManager->GetActorStreamingDistance();
|
||||
}
|
||||
CurrentEpisode->ApplySettings(CurrentSettings);
|
||||
|
||||
ResetFrameCounter();
|
||||
|
|
Loading…
Reference in New Issue