public override void OnUpdate(MyStateMachine stateMachine)
 {
     if (OutTransitions.Count == 0)
     {
         Finished = true;
     }
 }
Пример #2
0
 // Thread safe cursor creation
 public MyStateMachineCursor(MyStateMachineNode node, MyStateMachine stateMachine)
 {
     m_stateMachine = stateMachine;
     Id = Interlocked.Increment(ref m_idCounter);
     m_node = node;
     m_node.Cursors.Add(this);
     OnCursorStateChanged = null;
 }
Пример #3
0
 // Thread safe cursor creation
 public MyStateMachineCursor(MyStateMachineNode node, MyStateMachine stateMachine)
 {
     m_stateMachine = stateMachine;
     Id             = Interlocked.Increment(ref m_idCounter);
     m_node         = node;
     m_node.Cursors.Add(this);
     OnCursorStateChanged = null;
 }
 public override void OnUpdate(MyStateMachine stateMachine)
 {
     Debug.Assert(stateMachine is MyAnimationStateMachine, "Animation machine nodes must be inside animation state machine.");
     MyAnimationStateMachine animStateMachine = stateMachine as MyAnimationStateMachine;
     if (m_rootAnimationNode != null)
     {
         m_rootAnimationNode.Update(ref animStateMachine.CurrentUpdateData);
     }
 }
 public override void OnUpdate(MyStateMachine stateMachine)
 {
     MyAnimationStateMachine animStateMachine = stateMachine as MyAnimationStateMachine;
     if (animStateMachine == null)
     {
         Debug.Fail("Animation machine nodes must be inside animation state machine.");
         return;
     }
     if (m_rootAnimationNode != null)
     {
         animStateMachine.CurrentUpdateData.AddVisitedTreeNodesPathPoint(1);
         m_rootAnimationNode.Update(ref animStateMachine.CurrentUpdateData);
     }
     else
     {
         animStateMachine.CurrentUpdateData.BonesResult =
             animStateMachine.CurrentUpdateData.Controller.ResultBonesPool.Alloc();
     }
     animStateMachine.CurrentUpdateData.AddVisitedTreeNodesPathPoint(0); 
 }
Пример #6
0
 // Method launched on each update of state machine, override to add custom behavior (by default empty).
 public virtual void OnUpdate(MyStateMachine stateMachine)
 {
 }
Пример #7
0
 // Method launched on each update of state machine, override to add custom behavior (by default empty).
 public virtual void OnUpdate(MyStateMachine stateMachine)
 {
 }