Getting Started
If you are new to the tool, start here.
This guide is designed to get you from an empty scene to a working medieval town setup as quickly as possible. It focuses on the current V13-style workflow used by the source code.
What you will achieve
By the end of this guide you should have:
- the runtime bootstrap in your scene
- module settings created and assigned
- at least one work behaviour and one need behaviour
- a building in the scene
- a population region in the scene
- item collections assigned so editor tooling works correctly
- agents spawning and taking actions in play mode
Before you begin
You should be comfortable with:
- creating and saving Unity scenes
- adding components to GameObjects
- assigning references in the Inspector
- baking or generating navigation for your chosen nav setup
The shortest path to first success
Follow these steps in order.
1. Add the bootstrap object
Create an empty GameObject in your scene and add BardTreeModuleBootstrap.
This is the V13 entry point that initializes installed modules and shared services at runtime.
2. Open Module Settings
Open CIVIL-AI-SYSTEM -> Module Settings.
If no settings asset exists yet, let the tool create the default one. This asset becomes the main control panel for time, behaviour repositories, item collections, character pools, and performance values.
3. Create your core data assets
Before agents can do anything useful, create or assign:
- a work behaviour tree
- a need behaviour tree
- an item name collection
- an item type collection
- an item size collection
- a character pool service with at least one valid character entry
If you skip the item collections, some editor tooling, including Dialogue tooling, will not be able to work correctly.
4. Create a building
Select a scene object that represents a house or workplace and add BuildingService, or use CIVIL-AI-SYSTEM -> Template and Actions to add a building template to the selected object.
Each building should also have the colliders needed for your scene logic and interaction setup. Missing colliders often lead to invalid bounds, bad placement, or agents failing to reach expected building-related targets.
For a first test:
- create one house
- create one workplace
- ensure the workplace has at least one work role that matches your work behaviour tree
5. Create a population region
Open CIVIL-AI-SYSTEM -> Template and Actions and create a region.
Then configure the region so it can use:
- your character pool
- your spawn settings
- valid housing and workplace options in the scene
6. Set up navigation
Agents need a working navigation solution before most actions will complete correctly.
Check the nav mode in Module Settings, then make sure the scene has matching navigation data.
If agents spawn but never complete actions, navigation is one of the first things to verify.
7. Press Play and validate
On the first run, confirm these basics:
- the bootstrap initializes without errors
- agents spawn into the scene
- agents have homes and jobs
- agents move to valid targets
- agents switch between work and need behaviours over time
Recommended reading order after setup
Once the scene is running, read these next:
- Scene Setup
- Introduction to Behaviours
- Work Behaviours
- Need Behaviours
- Using the Behaviour Tree Editor
- Common Issues
If you are using Dialogue as well
Read Dialogue Setup before opening the Dialogue editor.
Dialogue is a separate paid tool that integrates with CIVIL-AI-SYSTEM through shared setup.
The Dialogue editor expects item collections to be available through the shared item catalog, so CivilAI item setup is important even if your immediate goal is conversation content.
Common first-run mistakes
- adding old scene objects from older docs instead of using the bootstrap workflow
- forgetting to assign behaviour repositories in Module Settings
- not creating item collections
- having no valid workplace role for the available work behaviour
- missing nav data for the selected nav mode
- creating regions without valid housing or workplaces in range
Want a concrete example?
If you want a mental model while building your first trees, use these examples:
- Work Behaviours includes a medieval blacksmith job breakdown
- Need Behaviours includes a medieval rest need breakdown