Not.cs 332 B

123456789101112131415
  1. namespace BehaviorTree
  2. {
  3. [NodeAttribute(NodeType.Not, typeof(Not))]
  4. public class Not: Node
  5. {
  6. public Not(NodeConfig config): base(config)
  7. {
  8. }
  9. public override bool Run(BlackBoard blackBoard)
  10. {
  11. return !this.children[0].Run(blackBoard);
  12. }
  13. }
  14. }