add unity behavior tree package & examples
add start of own implementation of a behavior tree
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace DefaultNamespace.BehaviorTree
|
||||
{
|
||||
public abstract class Node
|
||||
{
|
||||
protected List<Node> _nodes = new();
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public virtual Status Update()
|
||||
{
|
||||
return Status.Success;
|
||||
}
|
||||
|
||||
public virtual void End()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public enum Status
|
||||
{
|
||||
Success,
|
||||
Failure,
|
||||
Running,
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user