The tool has built in support for three pathfinding solutions which are very easy to setup. Pathfinding is how the agents moves around the scene.
Setting Pathfinding Solution
This can be set using the module settings menu (CIVIL-AI-SYSTEM -> Module Settings) within the Nav Agent section. Changing Nav Mode option will perform a check that the right packages have been installed and will prevent the change if not (warning will be shown in the console).
Adding the Package
Simply download and install the package you wish to use and add it to the project. The next step requires you to add the packages needed to the CIVIL-AI-SYSTEM Assembly Definition Asset. This file can be found at the route of the tool (CIVIL-AI-SYSTEM). Adding the package is done by adding to the Assembly Definition References. The specific file is dependent on the package being added and sometimes version (when renaming or structure changes happen within the package being added).
Options
Unity
This version is the out of the box implementation which the tool is ready to use out of the box. There is no need to do anything besides the normal steps for getting going.
A* Pathfinding Project
A popular and long standing pathfinding solution in the Unity community is supported.
Specific files to Assembly Definition (V5^)
- AstarPathfindingProject
- PackageTools
- ALINE
Agents Navigation
Another popular package which provides good performance benefits over the unity base version
Specific files to Assembly Definition (V4^)
- ProjectDawn.Navigation
Adding your Own
As the tool is designed to be expandable you can easily add your own which shouldn't cause to many conflicts on version changes with these four easy steps.
- Simply create your own implementation of the interface INavMeshAgent.
- Add to the enum NAV_MODE the new version name
- Update the function LoadNavMeshAgent in SettingsLoader to create your new class
- Set the Nav Mode