Control Flow Pack – Extension Pack for BTGraph (Free) View on Asset Store (opens in new tab)

Package details

Latest version
2.2
Last updated
First released
Unity version
6000.4.7 or later
Package size
197 KB
Files
27
Favorites
12
Views in the past week
29

Price tracking

Last checked
Tracked since
Lowest recorded
Free on

Keywords

Control Flow Pack – Extension Pack for BTGraph (Free)

by TheCoderGuy (opens in new tab)

1 rating, too few to average

Add advanced control flow, randomization, cooldown, repeat, and timeout nodes to your BTGraph Behavior Trees. Free extension pack designed for modular AI and professional Unity projects.

Price Free

Get it free on Asset Store (opens in new tab)

Affiliate link · Purchases support this site

Price history

Last 6 months

USD
Price history for Control Flow Pack – Extension Pack for BTGraph (Free), 6 months Current Free; lowest Free; highest Free in this period. $0 Jun Jul Aug Sep Oct Nov Version 2.1 released 15 Jun 2026 v2.1 Version 2.2 released 8 Oct 2026 v2.2

Asset preview

1 / 4

Control Flow Pack – Extension Pack for BTGraph (Free) screenshot 1

Control Flow Pack – Extension Pack for BTGraph (Free) screenshot 1

About this asset

Upgrade your Behavior Trees with advanced control flow and randomization nodes built specifically for BTGraph.

This free extension pack adds essential AI building blocks such as weighted random selection, shuffle sequences, cooldown decorators, repeat policies, delay, and timeout control — all designed for clean, modular, production-ready AI systems in Unity.

If you are building enemy AI, NPC logic, decision systems, or gameplay behaviors using Behavior Trees, this pack gives you the missing control structures needed to create dynamic, non-repetitive, and professional behavior logic.

What This Pack Adds

Randomization Nodes

  • Random Selector
  • Weighted Random Selector
  • Shuffle Sequence

Create non-deterministic and natural AI behaviors with proper per-instance memory and optional deterministic seeding.

Control Flow Decorators

  • Repeat (X Times)
  • Repeat Until Success
  • Repeat Until Failure

Control execution loops safely and predictably.

Time-Based Decorators

  • Cooldown
  • Timeout
  • Delay

Add timing constraints to your Behavior Tree branches without custom scripting.

Designed for Professional AI Architecture

  • No gameplay-system coupling (no animation, audio, or VFX dependencies)
  • Fully modular extension for BTGraph
  • Multi-agent safe runtime behavior
  • No static mutable state
  • Deterministic random option via seed key
  • Zero runtime reflection
  • Clean editor registration via BTGraph public hook
  • Runtime and editor assemblies properly separated

This pack focuses purely on Behavior Tree control logic, making it suitable for:

  • Enemy AI
  • NPC decision systems
  • Utility AI integrations
  • Strategy or simulation games
  • Large-scale AI systems
  • Modular AI frameworks

Why Use This Pack?

Many minimal Behavior Tree implementations lack advanced control structures like weighted selection or proper timeout handling.

This pack fills that gap with:

  • Production-grade execution semantics
  • Stable selection during running states
  • Proper lifecycle handling (Enter / Tick / Reset)
  • Predictable timeout behavior
  • Clean integration with BTGraph editor

Included Demo Scene

A lightweight demo scene is included to showcase:

  • Weighted random branch selection
  • Cooldown constraints
  • Shuffle execution order
  • Timeout handling

The demo is minimal and focused on logic clarity.

Requirements

Requires BTGraph (base package).

No BTGraph Pro required.

Perfect Companion To

  • Utility AI Pack for BTGraph
  • Perception Pack for BTGraph
  • Tactics Pack for BTGraph

From the publisher's Asset Store listing.

Technical details

Package Type

Extension Pack for BTGraph (Behavior Tree framework for Unity)

Editor-only registration hook integration.
No runtime reflection.
No dependency on BTGraph Pro.

Included Node Types

Composite Nodes

  • Random Selector
  • Weighted Random Selector
  • Shuffle Sequence

Decorator Nodes

  • Repeat (X Times)
  • Repeat Until Success
  • Repeat Until Failure
  • Cooldown
  • Timeout
  • Delay

Execution Semantics

All nodes follow BTGraph lifecycle conventions:

  • Proper Enter / Tick / Reset handling
  • Stable child selection during Running state
  • Per-instance state storage via NodeStateStore
  • Multi-agent safe execution
  • No mutable static runtime state

Deterministic Random Support

Weighted and uniform random nodes support deterministic execution when a Seed Key (Blackboard int) is provided.

  • No global RNG state
  • Instance-isolated random streams
  • Predictable behavior for debugging and replay systems

Timeout & Timing Behavior

  • Timeout only overrides children that are still Running
  • No premature failure before child tick
  • Delay and Cooldown handle edge cases (<= 0 values) safely
  • Timing based on Unity time system (Time.time)

Performance Characteristics

  • O(1) tick cost for decorators
  • O(n) selection cost on Enter for weighted and shuffle nodes
  • No per-tick allocations
  • Cached buffers for weight and shuffle arrays
  • No LINQ usage in runtime paths

Designed for scalability across multiple AI agents.

Editor Integration

  • Registered via BTGraph public editor registry
  • No assembly scanning
  • No core source modifications required
  • Deterministic search ordering (Group → Order → Title)
  • Runtime and Editor separated via asmdef assemblies

Folder Structure

Assets/BTGraphControlFlowFree/

  • Runtime/
  • Editor/
  • Demo/
  • Documentation/

Fully self-contained and removable without affecting BTGraph core.

Assembly Definitions

  • BTGraph.ControlFlow.Runtime
  • BTGraph.ControlFlow.Editor

Explicit dependency references to BTGraph base runtime and editor assemblies.

Compatibility

  • Unity 2021+ (recommended)
  • Compatible with BTGraph base package
  • Compatible with other BTGraph extension packs
  • Does not require BTGraph Pro

Demo Scene

Includes a minimal showcase demonstrating:

  • Weighted selection
  • Cooldown constraints
  • Shuffle execution
  • Timeout behavior

No console spam. No Pro dependency.

Use Cases

  • Enemy AI
  • NPC logic
  • Strategy / RTS AI
  • Simulation systems
  • Modular AI frameworks
  • Decision-making layers
  • Utility AI branch gating

Compatibility

Render pipelines supported in each Unity version
Unity version Built-in URP HDRP Custom
6000.4.7f1 Compatible Compatible Compatible Compatible

As listed on the Asset Store.