NavMesh Pathfinding
New Atavism 2018.2 comes with support for fully featured NavMesh.
- In order to use it, you have to get best Unity side graph baker A* Pathfinding Project Pro, which is available in your apanel and import it into your project.
- Then you should open the scene for which you want to bake the graph
- Create an empty game object in the scene.
- Add Pathfinder component to it
- Expand Optimization tab
- Tick the ASTAR_RECAST_LARGER_TILES option and click the Apply button
- Click Ok button on the newly opened dialog box
- Expand Graphs tab and click Recast Graph option within Add New Graph
- Expand Recast Graph by clicking on it
- You have to set Use Tiles to Dont Use Tiles option, as we are using 32bit mesh
- Rest of the options are depending on your use case, but for example for the MainWorld map which is delivered within Atavism package, parameters which worked best for us are
- Click Scan button
- The progress bar should be presented
- You can visualize it by changing options Show surface or Show outline with Show Graphs checkbox ticked
- Click Save & Load tab
- Click Save to file button
- Select directory where you want to save it. The most important part is that name of the file must be corresponding to the Atavism instance name, for example, if you are preparing NavMesh Graph for MainWorld Instance then the file should be named as MainWorld.bytes. and click save
- In the dialog box click Include node data button
- In the dialog box click Don’t scan button
- In the dialog box click Ok button
- Then on the server side in the directory atavism_server/navmesh/ create the new directory with Atavism Instance Name (in our case it will be MainWorld). It’s important to keep the upper and lower case corresponding with the Instance name in the Atavism Editor.
- Copy newly created graph to that created directory on the server
- Restart Atavism World Server
Important Note: Your server requirements may be varied if you are using NvMesh as each NavMesh Graph will require additional memory, and 1GB of the minimum required memory may be not sufficient if you are going to use NavMesh functionality.