Navigation
API > API/Plugins > API/Plugins/StateTreeModule
References
| Module | StateTreeModule |
| Header | /Engine/Plugins/Runtime/StateTree/Source/StateTreeModule/Public/StateTreeInstanceData.h |
| Include | #include "StateTreeInstanceData.h" |
Syntax
USTRUCT&40;&41;
struct FStateTreeInstanceData
Remarks
StateTree instance data is used to store the runtime state of a StateTree. The layout of the data is described in a FStateTreeInstanceDataLayout.
Note: If FStateTreeInstanceData is placed on an struct, you must call AddStructReferencedObjects() manually, as it is not automatically called recursively. Note: Serialization is supported only for FArchive::IsModifyingWeakAndStrongReferences(), that is replacing object references.
Variables
| Type | Name | Description | |
|---|---|---|---|
| FInstancedStruct | InstanceStorage | Storage for the actual instance data, always stores FStateTreeInstanceStorage. |
Constructors
| Type | Name | Description | |
|---|---|---|---|
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddTransitionRequest
(
const UObject* Owner, |
Buffers a transition request to be sent to the State Tree. | |
| void | Append
(
UObject& InOwner, |
Appends new items to the instance. | |
| void | Append
(
UObject& InOwner, |
Appends new items to the instance. | |
| bool | |||
| void | CopyFrom
(
UObject& InOwner, |
Shares the layout from another instance data, and copies the data over. | |
| int32 | |||
| const FStateTreeEventQueue & | |||
| const FStateTreeExecutionState * | |||
| FStateTreeEventQueue & | |||
| UObject * | GetMutableObject
(
const int32 Index |
||
| FStateTreeInstanceStorage & | |||
| FStructView | GetMutableStruct
(
const int32 Index |
||
| int32 | GetNumItems () |
||
| const UObject * | GetObject
(
const int32 Index |
||
| const FStateTreeInstanceStorage & | GetStorage () |
||
| FConstStructView | GetStruct
(
const int32 Index |
||
| TConstArrayView< FStateTreeTransitionRequest > | |||
| bool | Identical
(
const FStateTreeInstanceData* Other, |
Type traits | |
| void | Init
(
UObject& InOwner, |
Initializes the array with specified items. | |
| void | Init
(
UObject& InOwner, |
Initializes the array with specified items. | |
| bool | IsValid () |
||
| bool | IsValidStructIndex
(
const int32 Index |
||
| int32 | NumObjects () |
||
| int32 | NumStructs () |
||
| void | PostSerialize
(
const FArchive& Ar |
||
| void | Reset () |
Resets the data to empty. | |
| void | Reset all pending transition requests. | ||
| void | ShrinkTo
(
const int32 NumStructs, |
Shrinks the array sizes to specified lengths. Sizes must be small or equal than current size. |
Deprecated Variables
| Type | Name | Description | |
|---|---|---|---|
| TArray< TObjectPtr< UObject > > | InstanceObjects_DEPRECATED | ||
| FInstancedStructContainer | InstanceStructs_DEPRECATED |
Deprecated Functions
| Type | Name | Description | |
|---|---|---|---|
| TArray< FStateTreeEvent > & | GetEvents () |
Use GetEventQueue() instead. |