Hi, ive been tinkering with Behavior Designer Pro to see if it works with my use case but seems like adding a node in runtime is not fully implemented? I want to save/load BehaviorTree in runtime and it works perfectly.
BehaviorTree has
No action is added and I'm getting error when refreshing Behavior Designer window:
Some data is added to TaskData but i think im missing something.
Thank you in advance.
BehaviorTree has
public void AddNode(ILogicNode node) but it adds node with Parent, sibling and runtime indexes as ushort.MaxValue even if i set these manually to point to proper parent/sibling like so: BehaviorTree.AddNode(newAction, lastNode.ParentIndex, 65535, (ushort)(lastNode.RuntimeIndex + 1)); action.Initialize(BehaviorTree, action.Index); // doesnt seem to do anything in this case BehaviorTree.ReevaluateSubtreeReferences(); // doesnt seem to do anything in this case BehaviorTree.Serialize(); // doesnt seem to do anything in this caseNo action is added and I'm getting error when refreshing Behavior Designer window:
[COLOR=rgb(184, 49, 47)]IndexOutOfRangeException: Index was outside the bounds of the array.[/COLOR][COLOR=rgb(184, 49, 47)]Opsive.GraphDesigner.Editor.Views.GraphView.LoadNode (Opsive.GraphDesigner.Runtime.ILogicNode node, System.Int32 index[/COLOR]Some data is added to TaskData but i think im missing something.
Thank you in advance.