Skip to main content

Class AICommandBehaviour

A Timeline behaviour that holds the runtime data provided by the AICommandClip during playback. This class contains no execution logic itself�instead, all logic is handled in the track mixer (AICommandMixerBehaviour).

The reason for centralizing logic in the mixer is to allow performing action that involve blending and interpolation between multiple clips, such as smoothly tweening a unit's position from one command to another in Edit mode.

This class effectively acts as a runtime data container for AICommandMixerBehaviour.

[Serializable]
public class AICommandBehaviour : PlayableBehaviour

Inheritance​

Fields​

commandExecuted​

Internal flag that author by the Mixer. The user shouldn't author this.

[HideInInspector]
public bool commandExecuted

Field Value​

bool

commandType​

The type of AI command.

public AICommand.CommandType commandType

Field Value​

AICommand.CommandType

targetPosition​

The target position for the AI command.

public Vector3 targetPosition

Field Value​

Vector3

targetUnit​

The target unit for the AI command.

public Transform targetUnit

Field Value​

Transform

  • Fields
    • commandExecuted
    • commandType
    • targetPosition
    • targetUnit