csharp
public sealed class UtilityMemoryThe managed half of what an agent remembers, for a set that is an agent's whole planner.
Remarks
A thin holder over a UtilityState and a cooldown array. It exists so that AiSystem can keep one beside an agent's slot the way it keeps a BehaviorTreeInstance, without the arithmetic being written twice.
Fields and properties (4)
public ref UtilityState StateThe state the set reads and writes.
public int CurrentWhich action is running, or -1 for none.
public int DecisionsHow many decisions it has made.
public Span<float> CooldownsWhen each action last ended.
Methods (2)
public void Reset()Forgets everything, which is what a recycled agent slot needs.
public void Fit(int count)Makes room for a set's actions.
Used by (3)
- AiSnapshotTestsVixen.Ai.Tests
- AiSnapshotsVixen.Ai
- AiSystemVixen.Ai