Hierarchical pathfinding over several standalone areas?

Started by
4 comments, last by lucky6969b 6 years, 10 months ago

Imagine there are several standalone areas which each one has its own navigation data, and they also possess a pivot. As I have created a system on a large open area called the suburb, and they have buildings erecting on it, these buildings also have navigation data.

The problem comes now, where the building and the suburb's pivots are both the same, and sitting on 0,0,0. I do this intentionally as I want to test whether the pathfinder can adapt to weird situation like this. When I raycast from building 0 where its pivot overlaps with the suburb's pivot, the raycast just won't get out of it and get to building 1 which is the destination....

Any ideas how to fix this?

Thanks

Jack

Advertisement
You have to represent the connectivity between the building and the "suburb" in the navigation data itself.

Depending on what type of navigation data you are using, this can range from trivial to mostly easy.

There should be no need to raycast to do path searches.

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

Hello,

Initially, the hierarchical pf library was so good that I don't need to consider further ones. But when I read the documentation that has then stunned me, it said if I need to generate

a map for an area which spans several kilometers, and the small bounding box is just 2m by 2m, then it will generate 100 million bounding boxes to test its walkability. Then I think about it, and I decide to generate one set of data per "navigatable" area,and connect them thru portals.

That works great, and my question is how can I tell where the portals are. I am currently using the node which is closest to the source....But sometimes this calculated portal may be some area which is not walkable at all. Still thinking, anything to add? And what you said is just what I am talking about, to find where the connected portals are and must be precomputed for handiness.

Thanks

Jack

Your post is not very clear to me. Are you talking about doing pathfinding queries or are you talking about building a navigation data structure? They are related but different questions.

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

Off topic, why are you hitting "return" halfway through your lines of typing. It's almost as if you are on an old manual typewriter and are worried about going off the edge of the page.

Dave Mark - President and Lead Designer of Intrinsic Algorithm LLC
Professional consultant on game AI, mathematical modeling, simulation modeling
Co-founder and 10 year advisor of the GDC AI Summit
Author of the book, Behavioral Mathematics for Game AI
Blogs I write:
IA News - What's happening at IA | IA on AI - AI news and notes | Post-Play'em - Observations on AI of games I play

"Reducing the world to mathematical equations!"

Oh, I am really sorry about it... Just because of my bad typing habits... won't be doing it next time...

This topic is closed to new replies.

Advertisement