优化了流程的进行

This commit is contained in:
fengjiayi
2024-09-15 22:07:10 +08:00
parent fe2ccaf74c
commit 61d40977ff
21 changed files with 153 additions and 117 deletions

View File

@@ -159,11 +159,14 @@ namespace Serein.NodeFlow
IFlipflopContext flipflopContext = await func.Invoke(md.ActingInstance, parameters);
if (flipflopContext.State == FlowStateType.Succeed)
ConnectionType connection = flipflopContext.State.ToContentType();
if (connection != ConnectionType.None)
{
singleFlipFlopNode.FlowState = FlowStateType.Succeed;
singleFlipFlopNode.NextOrientation = connection;
singleFlipFlopNode.FlowData = flipflopContext.Data;
var tasks = singleFlipFlopNode.SuccessorNodes[ConnectionType.IsSucceed].Select(nextNode =>
var tasks = singleFlipFlopNode.SuccessorNodes[connection].Select(nextNode =>
{
var context = new DynamicContext(SereinIoc,flowEnvironment);
nextNode.PreviousNode = singleFlipFlopNode;