Nav Link Proxy not setting custom NavArea Flag

Hey everyone,

I went through the tutorial on making an AI Jump and couldn’t get the nav link proxy to set the flag correctly for some odd reason. I don’t get any compile errors but when I debug out a message the

if(FNavAreaHelper::HasJumpFlag(SegmentStart))

is never true when my AI walks into the Nav Link Proxy with the Nav Area on the Point Link set to NavArea_Jump.

I triple checked everything from the tutorial and cant see anything different then what I am doing.

I saw a warning saying that said

WARNING - PATHS MAY NOT BE VALID

So then set the Navigation Mesh Build on Runtime option to true , got rid of that warning but then I see this warning when playing the game a bunch.

"FRecastTileGenerator: Trying to use undefined area class while defining Off-Mesh links! (NavArea_Jump)"

Not quite sure what that means. Any help would be greatly appreciated , would love to get this working :slight_smile:

Thanks!

Tutorial I used was from here. http://unreal-ai-tutorial.info/index.php/8-tutorial-cpp/3-making-ai-jump-as-part-of-path-following

using 4.7.2

I got the NavArea_Jump to work but only in a Nav Modifier Volume , but the Nav Link Proxy still doesn’t work. Leading me to think I either set the Nav Link Proxy up wrong but it seems correct. How does the Nav Link Proxy work in terms of overlapping the actor?

That tutorial is gone now…what the heck? I followed the advice in this thread from MieszkoZ NavLink and making AI jump? - C++ - Epic Developer Community Forums, and I’m getting the same thing you did.

So I guess I have to switch to Nav Modifier Volume??

Does anyone know if this is supposed to be working properly?

Any updates on this? It works 50% of the time. Usually if I close the editor, rebuild my C++ code then go back to the Editor it works fine, but it’s not a really great solution. Paging Mr. MieszkoZ :slight_smile:

Same problem here!
Debugging the code the AI controller logs always 0 for the area flags once it reaches the nav links!
Even if I use one of the already existing links like obstacle or low-height!

Have you tried switching to 4.10? They fixed a bug where the nav mesh was being rebuilt all the time. As soon as I switched to 4.10 the bug disappeared.

The problem happens with 4.10.
I investigated it further and noticed that the bug actually only happens with hot reloading.
Normally the custom NavArea class (old version) should be unregistered when hot reloading and re-registered after that.
However somehow it first registers the new one and then unregisters the old one. This would make it necessary to restart the editor after compiling each time.

I managed to circumvent the problem for now by overriding FinishDestroy() in my custom NavArea class with the following - slightly changed - code.

void UNavArea_Jump::FinishDestroy()
{
	if (HasAnyFlags(RF_ClassDefaultObject)
#if WITH_HOT_RELOAD
		&& !GIsHotReload
#endif // WITH_HOT_RELOAD
		)
	{
		UE_LOG(LogTemp, Error, TEXT("Did not unregister %s, because of bug in UE4"), *GetClass()->GetName());
		// UNavigationSystem::RequestAreaUnregistering(GetClass());
	}
	UObject::FinishDestroy();
}

I reported this as a bug here

Did anyone solve this problem?