Adding AI States
The primary distinction lies in the creation of a new state asset. For AI States, select Create -> C# UHFPS Templates -> AIState Script to generate a new AI State script.
The AI state implements the FSMAIState class, which includes various methods and references.
From the AIState, you can access essential player components, like the player state machine, player health or player manager.
It is recommended to examine the existing states and methods in FSMAIState to get an overview of how the different functionalities are implemented and what you can use in your states. Each method is commented so you will know how and which method you can use.
Adding Waypoints
Create a new empty game object and name it Waypoints or whatever you want.
Add the AI Waypoints Group component to the game object.
Create a new empty game object and add it to the parent of the Waypoints object.
Add the AI Waypoint component to the parent object. When you add new objects with the AI Waypoint component to the parent of the Waypoints object, the AI Waypoint Group will automatically handle the waypoint list, so you don't need to manually add or remove them.
Last updated