Does anyone know how to use this function? (NavLinkProxy Runtime Update in Unreal Engine 5)

Hello everyone,

I’m currently learning Unreal Engine independently and working on using Blueprints to create NavLinkProxy at runtime, allowing AI to navigate using it. However, I’ve encountered an issue:

NavLinkProxy created during runtime doesn’t seem to affect the NavMesh.
There are very limited options in Blueprints to update or rebuild the NavMesh.

To address this, I tried exploring C++ functions for updating the NavMesh. Unfortunately, simple NavMesh rebuilding functions didn’t work as intended.

I found a potential lead in this YouTube video.(https://youtu.be/AtlEixncq34?t=715) However, the function used there has since been deprecated. The new signature is:

void UNavigationSystemV1::UpdateNavOctreeElement(
const FNavigationElementHandle Handle,
const TSharedRef& Element,
const int32 UpdateFlags
);

I need help understanding how to properly call this function. Specifically:

What headers should I include?
What parameters should I provide for FNavigationElementHandle and TSharedRef<const FNavigationElement>?

My Goal:

To create a NavLinkProxy at runtime in Blueprints and use a custom C++ function to update the NavMesh accordingly. I believe calling UNavigationSystemV1::UpdateNavOctreeElement inside the custom function is the way to go, but I’m open to any method that works.

Any guidance on achieving this would be greatly appreciated. Thank you in advance!