Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Having problems with overlapping Nav Modifiers.

Hello, i'm currently working on the AI for my game but have gotten a bit stuck with using the Nav modifiers. I understand how the modifiers work and how they should be used, but that is not the issue i'm having.

For what i'm doing i would like to have modifiers that overlap, but it seems very random what modifiers will affect the navmesh when they are overlapping. I will try to explain what is happening, in this first image i have two modifiers, one that is quite wide, and another one that is thinner than the first one. The dark green color indicates that the wider, first nav modifier is being used, not the thinner one in the middle. alt text

In this next image i have pulled up the thinner nav modifier away from the navmesh and then placed it back into it's original location. However, now the thinner nav modifier is also being used as you can see by the different green color. alt text

It's really annoying to work with nav modifiers that are overlapping since it seems that the nav modifier that was placed into position last will override the other ones that are already there.

Is there any way to set some kind of priority to the nav modifiers which forces them on top of other nav modifiers? Or is there something else that can be done to make overlapping nav modifiers easier to use?


Product Version: UE 4.15
more ▼

asked May 31 '17 at 01:14 PM in Using UE4

avatar image

200 54 54 64

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

You can enable ares "sorting" in Project Settings > Navigation Mesh > Sort Navigation Areas by Cost. Once enabled the navmesh generator will sort areas to be applied based on their cost making sure the most expensive areas end up on top. Of course this is not always what you want, so you can override the function that does the actual sorting, ARecastNavMesh::SortAreasForGenerator



more ▼

answered May 31 '17 at 02:31 PM

avatar image

MieszkoZ STAFF
7.3k 225 57 413

avatar image Jeff Nevington Nov 16 '18 at 07:51 AM

This is great for dealing with multiple modifiers that effect the same agents all of the time.

In a situation where two modifiers overlap but only one is used per MoveTo request based upon an agent's default navigation filter, would the navigation system handle this? Say the one with higher cost has ended up "on top" but is not actually used, but the one "below" is - Would the one "below" be effective in this case in areas where it overlaps the dormant "on top" one?

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question