public Execution Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { Entity target = ctx.ReadEntity(Target); Assert.AreNotEqual(Entity.Null, target, "Referenced graph must have an entity"); int index = ctx.GetTriggeredIndex(Inputs, port); return(ctx.RunNestedGraph(this, target, index)); }
public void Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { var readValue = ctx.ReadValueOfType(Value, VariableType); ctx.Write(OutValue, readValue); ctx.Trigger(Output); if (VariableKind == VariableKind.OutputData) { ctx.TriggerGraphOutput(UInt32.MaxValue); } }
public void Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { bool anyMatched = false; var val = ctx.ReadInt(Selector); for (uint i = 0; i < SwitchValues.DataCount; i++) { if (ctx.ReadInt(SwitchValues.SelectPort(i)) == val) { ctx.Trigger(SwitchTriggers.SelectPort(i)); anyMatched = true; } } if (!anyMatched) { ctx.Trigger(Default); } }
public void Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { ctx.Write(State, port.GetPort().Index == SetTrue.GetPort().Index); ctx.Trigger(Done); }
public Execution Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { ref State state = ref ctx.GetState(this);
Execution IStateFlowNode.Execute <TCtx>(TCtx ctx, InputTriggerPort port) { return(ctx.TriggerGraphOutput(OutputIndex)); }
public void Execute <TCtx>(TCtx ctx, InputTriggerPort port) where TCtx : IGraphInstance { ctx.Trigger(ctx.ReadBool(Condition) ? IfTrue : IfFalse); }