# Settings Explained

***

## COMPANION COMPONENT

Starting with the largest component, the Companion Component. This Component is assigned to any character that you want to be recognized as a Companion AI. In this Component, you can make all the settings that directly affect the AI and its behavior.

**General AI Settings**

| Settings Name      | Description                                                                                 |
| ------------------ | ------------------------------------------------------------------------------------------- |
| Uses Root Motion   | <p>Determines whether the</p><p>Companion AI uses a root motion-based character or not.</p> |
| Should Follow      | <p>Determines whether or not the</p><p>Companion AI will follow the player.</p>             |
| Can Wander         | <p>Determines whether the AI should</p><p>wander when in neutral area or not.</p>           |
| Use Area Detection | <p>Specifies whether the AI should use</p><p>the area detection system.</p>                 |
| Wandering Radius   | Sets the radius for the neutral area and the wandering radius.                              |
| Follow Restriction | <p>Specifies which follow method to</p><p>use.</p>                                          |

***

**AI Speed Settings**

| Settings Name | Description                       |
| ------------- | --------------------------------- |
| Maximal Speed | Sets the maximal speed of the AI. |
| Walking Speed | Sets the walking speed of the AI. |

***

**For Run Settings**

| Settings Name           | Description                                                                                                                  |
| ----------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| Projection Method       | <p>Specifies the projection method</p><p>used by the projection system.</p>                                                  |
| For Run Distance        | <p>Sets the distance, the AI should run</p><p>in front of the player when in For Run mode.</p>                               |
| For Run Offset          | <p>Determines the offset direction (left</p><p>or right) of the predicted player location.</p>                               |
| Offset Amount (For Run) | Sets the amount of offset in centimeters.                                                                                    |
| Hittable Classes        | <p>Defines an array of classes that are</p><p>hitable by the prediction system.</p><p>Landscapes are hitable by default.</p> |

**Follow Behind Settings**

| Settings Name          | Description                                                                              |
| ---------------------- | ---------------------------------------------------------------------------------------- |
| Follow Distance        | <p>Sets the distance in centimeters</p><p>that the AI will follow behind the player.</p> |
| Follow Behind Offset   | <p>Specifies the offset direction (left or</p><p>right) of the follow position.</p>      |
| Offset Amount (Behind) | Sets the amount of offset in centimeters.                                                |

**Area Detection Settings**

| Settings Name         | Description                                                                                                                             |
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| Detection Range       | <p>Sets the radius/area for area</p><p>detection.</p>                                                                                   |
| Detection Sensitivity | <p>Determines how many percent of</p><p>all area detection rays must hit something before the follow mode is set to follow.</p>         |
| Detection Method      | <p>Specifies the area detection</p><p>method. Radial scans the area in a radial shape and Squared scans the area in a square shape.</p> |

**Interactable Detection Settings**

| Settings Name                 | Description                                                                                                                                                   |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Interactable Detection Radius | Sets the radius within which the AI can detect interactable objects.                                                                                          |
| Detection Possibility         | Sets how likely it is that the AI will actually detect an interactable when it is in range. (Low = 25% \| Medium = 50% \| High = 75% \| Always detect = 100%) |

**Command Settings**

| Settings Name | Description                                                                                                 |
| ------------- | ----------------------------------------------------------------------------------------------------------- |
| Commands      | <p>Contains all the commands and</p><p>associated logic available to this instance of the AI companion.</p> |

**AI Combat Settings**

<table><thead><tr><th width="374">Settings Name</th><th>Description</th></tr></thead><tbody><tr><td>Attacking Behavior</td><td><p>Holds the attack behavior. This</p><p>setting allows you to create different AIs with different attack behaviors without changing the code. Can be changed at runtime, e.g., when the AI collects a new weapon, you can change the attack logic accordingly.</p></td></tr></tbody></table>

## CAMERA HANDLER COMPONENT

Second is the Camera Handler Component. It must be assigned to the player character and will be responsible for detecting the Companion AI. The Camera Handler Component will also be responsible for detecting what object the player is looking at when in Command Mode and then assigning the appropriate command to the Companion AI. The whole system will not work without this component, so be sure to add it to your player character blueprint.

**General Camera Handler Settings**

| Settings Name   | Description                                                                                                                               |
| --------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| Detection Range | <p>The range at which the camera</p><p>detects that the player is looking at the AI.</p>                                                  |
| Command Range   | <p>The camera's actor detection range</p><p>while the camera is in command mode.</p>                                                      |
| Enemy Tag       | <p>Holds the tag for enemies. Make</p><p>sure this tag matches the tag of your enemies so that the command system can recognize them.</p> |

## **HITABLE ACTOR COMPONENT**

The Hitable Actor Component is used to determine whether an actor should be recognized by the Projection System or not. To make it not too much work to add this Component to every actor in your level, you can go to the "For Run" settings inside the Companion Component and look for the "Hitable Classes" array, where you can assign multiple classes that will be automatically recognized by the command system. Landscapes are detected by default.

| Settings Name | Description                                                                                                                                        |
| ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| Ground Zero   | <p>Determines if the owning actor is</p><p>the last actor with no other hitable actors below. The projection will stop at this actor if “true”</p> |

## POINT OF INTEREST IDENT COMPONENT

This component is used to identify POI Objects in your level. You must add this component if you want the Advanced Companion AI System to recognize the owning actor as a POI Object.

Each POI Object has its own logic for the AI to follow when interacting with the POI. For example, it might be a bench where the AI can sit when it has nothing else to do.

| Settings Name | Description                                                                                                |
| ------------- | ---------------------------------------------------------------------------------------------------------- |
| POI Behavior  | <p>BHT Asset that contains the logic for</p><p>the AI to execute when interacting with the POI object.</p> |

## CUSTOM COMMAND COMPONENT

This Component can be used to give an actor a custom command that is executed when the actor is selected while using the Command System.

| Settings Name | Description                                                                                         |
| ------------- | --------------------------------------------------------------------------------------------------- |
| Command       | <p>Enum value which determines the</p><p>command to be executed for this actor in command mode.</p> |
