internal GraphNode OnNodeAdded(BehaviourTree asset, BehaviourTreeNode node) { var newNode = new BehaviourTreeEditorNode(asset, node, Presenter); Nodes.AddNode(newNode); return(newNode); }
private void CreateNodesRecursive(BehaviourTreeGraphNode graphNode) { Nodes.AddNode(graphNode); if (graphNode.TreeNode.IsParentNode()) { var childNodes = graphNode.TreeNode.AsParentNode().GetChildNodes(); if (childNodes != null) { foreach (BehaviourTreeNode childNode in childNodes) { var newNode = new BehaviourTreeGraphNode(childNode); GraphNode.MakeConnection(graphNode, newNode); CreateNodesRecursive(newNode); } } } }
private void CreateNodesRecursive(BehaviourTreeGraphNode graphNode) { Nodes.AddNode(graphNode); if (graphNode.TreeNode.IsParentNode()) { var childNodes = graphNode.TreeNode.AsParentNode().GetChildNodes(); if (childNodes != null) { foreach (BehaviourTreeNode childNode in childNodes) { // var newNode = new BehaviourTreeGraphNode(childNode); // GraphNode.MakeConnection(graphNode, newNode); // CreateNodesRecursive(newNode); throw new NotImplementedException("TODO!"); } } } }