News Forums RAIN General Discussion and Troubleshooting Can multiple NavMeshes work as one?

This topic contains 7 replies, has 4 voices, and was last updated by  redhawk 2 years, 9 months ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #6597

    Iuxeayor
    Participant

    Hi, I am using the new RAIN and I just had a quick question.
    When I tried creating a single NavMesh over my map, I waited about 15 minutes to no avail. My map is just a plane extruded using Blender; I believe its scale is about 2500 Unity units across. So, I decided to try generating a smaller NavMesh that only occupied about 1/8th of the map, and it was generated fine in only a minute or so.

    My question is can I create multiple NavMeshes over my map and utilize them as if they were one NavMesh? Will there be any interference when WayPoints cross the NavMeshes?

    I followed this tutorial for the creation of my map. It’s generally the same idea.

    #6598

    narfi
    Participant

    Same issue, same question

    #6608

    Iuxeayor
    Participant

    I was thinking of trying it when I get home tonight (California), but that won’t be for a few hours. It’s currently 12:30p. I noticed someone else had asked this question about a month or two ago but was never answered, and something is telling me that RAIN doesn’t inherently allow crossing over between 2 or more NavMeshes. I’m just curious if it will work and what I could do to make it work.

    #6613

    Iuxeayor
    Participant

    I managed to try a simple test. I essentially put in a second NavMesh and extended the WayPoint Route into the new NavMesh’s territory. The two NavMeshes overlap each other a little.

    When I ran this, the simple AI Character, which did absolutely nothing but follow the WayPoint Route, did not cross onto the new NavMesh but stopped on the last WayPoint Node within the original NavMesh.

    I will resume further testing. ;>

    #6615

    Iuxeayor
    Participant

    Hmm. Well, I couldn’t get 2 NavMeshes working together using only simple techniques. However, I tried creating one large NavMesh again, this time shrinking the Height of the Box to cover only the ground (originally, I had left it large). Also, I kept the default “Size” to 20 and scaled it from there. This time, a NavMesh was successfully created and the WayPoints worked like a charm.

    I would still like to know a solution for joining 2 NavMeshes together, though.

    #6630

    prime
    Keymaster

    No, RAIN doesn’t currently have a way of stitching together NavMeshes. One trick you can use is to overlap the meshes and use a waypoint network when pathing from one to the other. For the waypoint network, just place a waypoint in the overlap region. RAIN will path to the waypoint in the overlap, then switch meshes. Avoid using the waypoint network when not going across navmeshes to ensure it doesn’t interfere with normal pathing.

    #6633

    Iuxeayor
    Participant

    Ok, cool! I may give that a try later, but I actually got my map to work with only one NavMesh by shortening the height of the generation box to only include the ground and not any surfaces on top of the walls.

    Thanks for the reply. ;>

    #6635

    redhawk
    Participant

    I’d like to see an example of this Prime. If you could create maybe 4 navmeshes and use the technique you state as an example for everyone, I would appreciate it. They don’t have to be large meshes.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.