public override void PostHandle(GraphEngine graphEngine) { IAutoNode node = GetNextNode(); if (node != null) { graphEngine.SetCurrentNode(node); graphEngine.Continue(); } }
/// <summary> /// Perform the transition from one node to the next. /// </summary> /// <param name="graphEngine">The graph traversal engine making the transition</param> /// <param name="node">The node to transition from.</param> public virtual void Transition(GraphEngine graphEngine, IAutoNode node) { Node xnode = (Node)node; NodePort port = xnode.GetOutputPort(OutputPort); NodePort nextPort = port.Connection; IAutoNode nextNode = (IAutoNode)nextPort.node; graphEngine.SetCurrentNode(nextNode); graphEngine.Continue(); }
public void SkipBattle() { BattleEndMarkerNode endNode = graphEngine.GetCurrentGraph().FindNode <BattleEndMarkerNode>(); if (endNode != null) { graphEngine.SetCurrentNode(endNode); graphEngine.Continue(); } else { Debug.LogWarning("Add a Battle End Marker Node to the boss' graph to be able to skip this battle!"); } }