IActionSettings
An interface in Root.Township, Alta.Intelligence.
Settings every AI action has: its weighting and the rules for cancelling it. Implemented by ActionComponent.
- Listed in Creatures and AI
- Derived types
ActionComponent
Properties
| Member | What it is |
|---|---|
bool CanCancelSelfWithSameTarget { get; } | If false, picking this action again on the same target restarts it instead of cancelling and starting a new one. |
int CancelPriority { get; } | This action is only considered if its priority is at least the running action's MinimumCancelPriority. |
bool IsCancellable { get; } | If false the action can't be cancelled once running. |
int MinimumCancelPriority { get; } | While this action runs, only actions with at least this CancelPriority can replace it. |
float MinimumCancelWeighting { get; } | While this action runs, a replacement must score above this weight. |
float Multiplier { get; } | Base weighting. ActionComponent can add a random extra on each read. |
string name { get; } | The action's name. |
Events
| Member | What it is |
|---|---|
event ActionSettingsUsedHandler Used | Fires each time the action starts. |
Methods
| Member | What it is |
|---|---|
void HandleUsed(IActiveAction active) | Called each time the action starts. The first call initializes the IAiHook components, then Used fires. |
Used in
Members of other types that take, return or hold a IActionSettings: