set_state_type
Change a StateTree state's type (State, Group, Linked, LinkedAsset, Subtree) and save the asset without recompiling, so you can adjust its role in the tree.
Instructions
Set the type of a StateTree state (EStateTreeStateType: State, Group, Linked, LinkedAsset or Subtree) and save the asset without recompiling it. An unknown name is an error. To point a state at another tree prefer set_state_linked_asset, which also sets the linked asset.
Returns: { tree_path, state_name, state_type, set, saved }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tree_path | Yes | Asset path of the StateTree, e.g. "/Game/AI/ST_Guard". | |
| state_name | Yes | Name of the state to change; the command fails without it. | |
| state_type | Yes | Enum value name: State, Group, Linked, LinkedAsset or Subtree (an EStateTreeStateType:: prefix is accepted). |