How do you get a Navigation path in UE4 4.20 in C++?
I'm currently trying to figure out how to get a Navigation path for my pawn in C++.The way I've seen people get the path is by using GetWorld()->GetNavigationSystem()->FindPathToLocationSynchronously(). But, in UE4 4.2, GetWorld()->GetNavigationSystem() returns a NavigationSystemBase which doesn't have the find path functionality. Does anyone know how I can find a path in 4.2 in c++?
Also the documentation online is out of date for the include for NavigationSystem.h, its now located in Runtime/NavigationSystem/Public/NavigationSystem.h
Any help would be appreciated!
asked Aug 24 '18 at 07:35 PM in C++ Programming
I think I figured it out.
UNavigationSystemV1* navSys = UNavigationSystemV1::GetCurrent(GetWorld()); UNavigationPath* path = navSys->FindPathToLocationSynchronously()
answered Aug 24 '18 at 07:42 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here