Class BehaviorTree
Behavior Tree asset with AI logic graph.
Namespace: FlaxEngine
Assembly: FlaxEngine.CSharp.dll
Syntax
[Unmanaged]
public sealed class BehaviorTree : BinaryAsset
Constructors
BehaviorTree()
Methods
GetNodeInstance(UInt32)
Gets a specific node instance object from Behavior Tree.
Declaration
[Unmanaged]
public BehaviorTreeNode GetNodeInstance(uint id)
Parameters
System.UInt32
id
The unique node identifier (Visject surface). |
Returns
BehaviorTreeNode
The node instance or null if cannot get it. |
LoadSurface()
Tries to load surface graph from the asset.
Declaration
[Unmanaged]
public byte[] LoadSurface()
Returns
System.Byte[]
The surface data or empty if failed to load it. |
SaveSurface(Byte[])
Updates the graph surface (save new one, discard cached data, reload asset).
Declaration
[Unmanaged]
public bool SaveSurface(byte[] data)
Parameters
System.Byte[]
data
Stream with graph data. |
Returns
System.Boolean
True if cannot save it, otherwise false. |