Search Unity

Assign costs for single nodes in Navmeshes / Increase Nr. of navmesh layers ?

Discussion in 'Editor & General Support' started by jomeier, Mar 23, 2014.

  1. jomeier

    jomeier

    Joined:
    Jun 5, 2010
    Posts:
    45
    Hi,

    think of this pathfinding setup:

    A group of navmesh agents has the possibility to go through two narrow openings in a wall.

    Thus the first narrow opening is near to the group, all group members will try to go through this opening. There will be a stall, units have to wait until their neighbours have passed through the opening.

    1st solution:
    Wouldn't it be better that the units which have to wait go to the second opening a little bit farer away?

    This problem could be solved if the costs of the area around the first narrow opening in the wall would increase with the number of units staying there. If the cost comes to a certain limit, all units waiting would select a path through the 2nd narrow opening cause there the costs are lower.

    But for this solution it would be necessary to set and get the costs for a certain node and use this in the path calculation procedure.

    2nd solution:
    I know about the navigation layer feature but there are only 32 layers possible. In a real map there could be a need for far more layers.

    Can the number of layers be increased so I can define a lot of areas which different costs?

    Thanks in advance,

    Josef
     
  2. jomeier

    jomeier

    Joined:
    Jun 5, 2010
    Posts:
    45