Hi, I stumbled on the StateGraph C++ class and I was wondering what its use was?
Im looking for a way to model world state and create state transitions using a graph data structure.
Thanks,
Hiren
Hi, I stumbled on the StateGraph C++ class and I was wondering what its use was?
Im looking for a way to model world state and create state transitions using a graph data structure.
Thanks,
Hiren
Hi @hirenumradia ,
Documentation from comments in StateGraph.h
* This module provides a generic state machine framework. For an example, see StateGraphTestsExample.cpp. Features include:
* - Free-form structure with no required linear or hierarchical structure - just graph nodes with dependencies.
* - Support for async tasks via a delayed function call to complete nodes.
* - Modifiable at runtime to add, remove, rename, or reset nodes in the graph.
* - Able to modify a state graph easily in derived classes or nested objects.
* - Each node is a full object that can encapsulate all required functions and data.
* - Wrapper node for delegates to support various function types directly.
* - Max execution depth of one node at a time.
* - Timeout support for state graph and individual nodes.
* - Configurable and hotfixable via ini settings.
The reason why it’s “Experimental” is because Epic may be actively working on that feature, it’s subject to big changes in between engine versions, may be unstable and/or incomplete and is not recommended to be used in production. It’s up to you whether to use it or not for your case, but it looks like it may work as a base framework for what you’re trying to achieve.
Thanks, I’ll take a read of that file!