[4.10] Huge Load Time Because of NAV Mesh Error Handling!

Hi,

We recently upgraded to 4.10. Unfortunately we are facing a huge load time when we want to play in editor. This huge load time only occurs once and for the first time we press the play button in editor. After we press play button, the editor consumes huge working set, sometimes more than 4GB and make the whole unresponsive and it causes thrashing. After loading finishes, these warnings show up in output log and I have to say that we have no nav meshes in our levels:

LogOutputDevice:Warning: === Handled error: ===
Ensure condition failed: MyNavData [File:D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.10\Engine\Source\Runtime\AIModule\Private\Navigation\PathFollowingComponent.cpp] [Line: 511]
Stack:
UE4Editor-Core.dll!FWindowsPlatformStackWalk::StackWalkAndDump() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\core\private\windows\windowsplatformstackwalk.cpp:175]
UE4Editor-Core.dll!FDebug::EnsureFailed() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\core\private\misc\outputdevice.cpp:276]
UE4Editor-Core.dll!FDebug::OptionallyLogFormattedEnsureMessageReturningFalse() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\core\private\misc\outputdevice.cpp:385]
UE4Editor-AIModule.dll!UPathFollowingComponent::RecacheNavigationData() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\aimodule\private\navigation\pathfollowingcomponent.cpp:511]
UE4Editor-AIModule.dll!TBaseUObjectMethodDelegateInstance<0,UPathFollowingComponent,void cdecl(void)>::ExecuteIfSafe() [d:\buildfarm\buildmachine++depot+ue4-releases+4.10\engine\source\runtime\core\public\delegates\delegateinstancesimpl_variadics.inl:772]
UE4Editor-Engine.dll!TBaseMulticastDelegate::Broadcast() [d:\buildfarm\buildmachine
++depot+ue4-releases+4.10\engine\source\runtime\core\public\delegates\delegatesignatureimpl_variadics.inl:809]
UE4Editor-Engine.dll!UNavigationSystem::OnWorldInitDone() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\engine\private\ai\navigation\navigationsystem.cpp:719]
UE4Editor-Engine.dll!UNavigationSystem::InitializeForWorld() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\engine\private\ai\navigation\navigationsystem.cpp:2252]
UE4Editor-Engine.dll!UGameInstance::StartPIEGameInstance() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\engine\private\gameinstance.cpp:251]
UE4Editor-UnrealEd.dll!UEditorEngine::CreatePIEGameInstance() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\editor\unrealed\private\playlevel.cpp:3012]
UE4Editor-UnrealEd.dll!UEditorEngine::PlayInEditor() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\editor\unrealed\private\playlevel.cpp:2259]
UE4Editor-UnrealEd.dll!UEditorEngine::StartQueuedPlayMapRequest() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\editor\unrealed\private\playlevel.cpp:1048]
UE4Editor-UnrealEd.dll!UEditorEngine::Tick() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\editor\unrealed\private\editorengine.cpp:1244]
UE4Editor-UnrealEd.dll!UUnrealEdEngine::Tick() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\editor\unrealed\private\unrealedengine.cpp:361]
UE4Editor.exe!FEngineLoop::Tick() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\launch\private\launchengineloop.cpp:2427]
UE4Editor.exe!GuardedMain() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\launch\private\launch.cpp:142]
UE4Editor.exe!GuardedMainWrapper() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\launch\private\windows\launchwindows.cpp:126]
UE4Editor.exe!WinMain() [d:\buildfarm\buildmachine_++depot+ue4-releases+4.10\engine\source\runtime\launch\private\windows\launchwindows.cpp:200]
UE4Editor.exe!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:264]
kernel32.dll
ntdll.dll
ntdll.dll

Also when I debug using DebugGameEditor settings, the editor breaks to a line in PathFollowingComponent.cpp just one time. I attached an image showing the line of the break.

Thanks in advance for checking the issue :slight_smile:

same here.
I am using a custom pawnmovementcomponent

Hey Sector0-

Is there a character blueprint in the level? If so it is looking for navigation information that doesn’t exist without a Nav Mesh Bounds Volume. Adding the bounds volume should reduce the load time and prevent Visual Studio from breaking at the line mentioned.

Cheers

I just had this exact thing yesterday till today. I just managed to solve this.

Apparently on my side the issue is that during one of my decorator observer aborted the child nodes ( that is doing some kind of processing ). I find that If I do not abort it , it doesn’t happen. Eventually what I did was adding a ‘stop movement’ to the On Abort event.

Hi ,

Sorry for the delayed reply. I wasn’t available for some days. I’m going to test this workaround soon and inform you about the results.

Hey Sector0-

Have you had the chance to test adding a Nav Mesh Bounds Volume to the level to see if that solves the issue for you?

Hey ,

I tested the workaround you mentioned and everything is now OK. After adding a Nav Mesh Bounds Volume, I see no warnings, no huge memory consumption and extra load time.

So what should I do now? Do I need to add a Nav Mesh Bounds Volume to all levels? We have character blueprints but we are not using any nav meshes! So is there any way to fix this issue via character blueprints? Everything was fine before we move to 4.10.

Thanks

The root issue is the path following component of your character. Having a pathfollowing component causes the character to search for some navigation on the map to use. The simplest solution would be to do as you suggested and add a small nav mesh to each level. The other solution would be to disable / remove the pathfollowing component from the character which would likely require editing code.