コード例 #1
0
        public BehaviorResult Behave(AIContext context)
        {
            var result = behaveDelegate(context);

            OnBehaved?.Invoke(this, new BehaviorInvokationEventArgs(result));
            return(result);
        }
コード例 #2
0
        public BehaviorResult Behave(AIContext context)
        {
            writeDebugInfo(Environment.NewLine + "Invoking " + debugName);
            behaviorResult = decoratedNode.Behave(context);
            writeDebugInfo(debugName + " execution terminated: " + behaviorResult);

            OnBehaved?.Invoke(this, new BehaviorInvokationEventArgs(behaviorResult));
            return(behaviorResult);
        }
コード例 #3
0
 private BehaviorResult InvokeAndReturn()
 {
     OnBehaved?.Invoke(this, new BehaviorInvokationEventArgs(behaviorResult));
     return(behaviorResult);
 }