Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Making Flying units with navmesh agents

Discussion in 'Navigation' started by Jenifer_Jane, Sep 19, 2017.

  1. Jenifer_Jane

    Jenifer_Jane

    Joined:
    Jan 24, 2017
    Posts:
    69
    hi all, Like Title says i am trying to make flying units like drones, plains, which could fly over all objects mine terrain have. I tried baking a different navmesh on a plain which is above mine terrain. but mine drone unit doesn't detect it. its keep saying "SetDestination" can only be called on an active agent that has been placed on a NavMesh". Any idea how to fix it..?. (Note i have baked navmesh on a terrain and a plain made different layer call flying for flying units set those in agents but still its not getting placed above navmesh) idk wat m doing wrong since i havn't tried this kind of stuff before any help would be appreciated. Thnx in Advance.

    Attached Inspector Screenshorts : -

    for some reason m not able to see screenshorts m posting so here are links for them

    this is unit m trying to make it fly
    https://ibb.co/nAXSw5

    this plain (which m using as flying navmesh)
    https://ibb.co/kMyNUQ

    this is Navigation layer setup
    https://ibb.co/cRWnw5

     
    Last edited: Sep 19, 2017
  2. Jenifer_Jane

    Jenifer_Jane

    Joined:
    Jan 24, 2017
    Posts:
    69
    or any other way to make flying units..? What you guyz do accomplish it..?
     
  3. Jenifer_Jane

    Jenifer_Jane

    Joined:
    Jan 24, 2017
    Posts:
    69
    nvm i made it problem fixed
     
  4. FrozenBotsStudio

    FrozenBotsStudio

    Joined:
    Jun 27, 2016
    Posts:
    10
    Hi, how did you fix it?
     
  5. christougher

    christougher

    Joined:
    Mar 6, 2015
    Posts:
    558
    For unity Nav mesh you can parent your units to an invisible nav mesh agent and the adjust the height as needed. It's not without its problems, but that's probably the simplest solution with unity Nav mesh...
     
    Jenifer_Jane likes this.
  6. Jenifer_Jane

    Jenifer_Jane

    Joined:
    Jan 24, 2017
    Posts:
    69
    yea thats what i did got that solution by accident i was trying random ideas hahahahahha