Search Unity

How to improve navmesh performance.

Discussion in 'Navigation' started by Rusfighter, Sep 24, 2015.

  1. Rusfighter

    Rusfighter

    Joined:
    Jan 18, 2014
    Posts:
    60
    Hello guys,

    I am currently making a mobile game and i came across some big frame drops. These performance drops are caused by the navmesh + navmeshagents. Currently I need to have around 150 navmesh agents at the same time in a single map. This gives me big frame drop in performance.

    I am already using lowest obstacle avoidance quality.

    Are there more ways to improve the performance of the navmesh/navmeshagents or do i need to use another library to get it running?

    For example, how games like Clash of Clans have their navigation system up and running?

    Thanks,

    Ilija
     
  2. Rusfighter

    Rusfighter

    Joined:
    Jan 18, 2014
    Posts:
    60
    The calculations of 100 agent's is around 20ms on a One plus one. This is ofcourse far to high. Are there any ways or techniques to get it faster?
     
  3. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,363
    stagger your calls to SetDestination
    lower or switch off collision avoidance
    bake nav mesh with a coarser precision
    CoC use grid nav with a very coarse grid and I think pre determine destination of each unit to avoid overlap