Easy to use, comprehensive Behavior Tree (BT) library built from the ground up for C# programmers:
- Game logic, game AI (autonomous agents)
- Asynchronous control applications
- No DSL/builder pattern (tight integration)
- Use standalone or borrow the "ticker" from a visual BT solution
=> Quick-start guide || Unity quick-start guide || API reference || FAQ
Active Logic seamlessly integrates with C#:
class Duelist : UTask{
float health = 100;
Transform threat;
// BT selectors and sequences via || and &&
override public status Step()
=> Attack()
|| Defend()
|| Retreat();
// Conditionals without 'conditional nodes'
status Attack() => (threat && health > 25) ?
Engage(threat) && Cooldown(1.0f)?[ Strike(threat) ]
: fail(log && $"No threat, or low hp ({health})");
status Defend() => ...;
// ...
}
Active logic is the first BT library providing tight integration with the host language (no DSL, no builder pattern, no lambdas or coroutines, no blackboard). This means better performance (low/no GC), cleaner syntax and the freedom to structure your code as you wish.
Engine/platform agnostic:
dotnet add package ActiveLogic
(via NuGet)
Unity 3D:
- Standard Edition via the Unity Asset Store
- Active-LT via UPM on Github
From source: no dependencies.
- C# 7.2 or later
- GNU Affero GPL v3.0. TLDR, use the software freely, provided derivative works are free, open source.
- Unity Store Assets are covered by their end user license agreement.
- Pending a standalone commercial license, read here
- Read the Quick start Guide and the FAQ
- Check the API reference
- Questions? Drop by the discord forum.