<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>CSimpleStateMachine :: Catur Documentation</title>
    <link>https://doc.cdryx.net/CdryxAIOUPlugin/modules/ccoreumodule/tools/csimplestatemachine/index.html</link>
    <description>Overview Enum-based state machine with typed transitions, variant data storage, auto-forward, semaphore-locked actions, and debug output.&#xA;Classes Name Description UCSTMachine The state machine. Holds states, current state, variant data. UCSTMachineState A state with an enum value, an action lambda, and an array of transitions. UCSTMachineTransition A transition with a target state and a condition lambda. Interface Name Description ICSTMachineOwner Implement getSTMachine() to expose state machines. Provides getSTMachine(FName), resetAnyStateMachine(), resetOtherStateMachine(). Utility Name Description StateMachineUtility::moveOnAllSimpleStateMachine Advances all state machines of a given family on all components of an actor. Macros Name Description SMT_NEW_STATE Create a state with transitions and action. SMT_BOOL_TRANSITION Transition based on a bool variant value. SMT_COMPLEX_BOOL_TRANSITION Transition based on a complex bool expression. SMT_AUTO_TRANSITION Unconditional transition. // Define an enum for states UENUM() enum class EMyState : uint8 { Idle, Walking, Attacking }; // Define an enum for variant data UENUM() enum class EMyVar : uint8 { ShouldAttack }; // Create states with transitions UCSTMachine* machine = createObjectAtRuntime&lt;UCSTMachine&gt;(this, [this](UCSTMachine* m) { m-&gt;init&lt;EMyState&gt;(FName(&#34;Combat&#34;), { SMT_NEW_STATE(EMyState::Idle, { // action when entering Idle }, SMT_BOOL_TRANSITION(EMyState::Attacking, EMyVar::ShouldAttack, true) ), SMT_NEW_STATE(EMyState::Attacking, { // action when entering Attacking m_-&gt;set(EMyVar::ShouldAttack, false); }, SMT_AUTO_TRANSITION(EMyState::Idle) ) }); }); // Trigger a transition machine-&gt;write(EMyVar::ShouldAttack, true); // Check current state if (machine-&gt;statusIs(EMyState::Attacking)) { /* ... */ } // Reset machine-&gt;reset(); // Move all state machines of a family on an actor StateMachineUtility::moveOnAllSimpleStateMachine(myActor, CSTMachineFamillyName::CNAME_STM_ANIMATION_FAMILLY); Predefined families Name Description CNAME_STM_ANIMATION_FAMILLY Animation state machines. CNAME_STM_TURNBYTURN_FAMILLY Turn-by-turn state machines.</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate></lastBuildDate>
    <atom:link href="https://doc.cdryx.net/CdryxAIOUPlugin/modules/ccoreumodule/tools/csimplestatemachine/index.xml" rel="self" type="application/rss+xml" />
  </channel>
</rss>