Added "What's New in v0.3" section covering species, concepts, sub_concepts, concept_comparison, template species inheritance, and life arc field requirements. Updated quick start example with v0.3 syntax including species and type system declarations.
121 lines
2.1 KiB
Plaintext
121 lines
2.1 KiB
Plaintext
//! Behavior trees for the Baker family
|
|
//!
|
|
//! These are referenced by schedule blocks via the action: field
|
|
|
|
// Main baking work routine
|
|
behavior BakingWork {
|
|
then {
|
|
check_orders
|
|
prepare_ingredients
|
|
choose {
|
|
make_bread
|
|
make_pastries
|
|
make_cakes
|
|
}
|
|
bake
|
|
cool_products
|
|
package_goods
|
|
}
|
|
}
|
|
|
|
// Kitchen prep routine
|
|
behavior PrepKitchen {
|
|
then {
|
|
clean_surfaces
|
|
check_supplies
|
|
preheat_ovens
|
|
organize_workspace
|
|
}
|
|
}
|
|
|
|
// Market day selling behavior
|
|
behavior SellAtMarket {
|
|
repeat {
|
|
then {
|
|
greet_customer
|
|
show_products
|
|
if(self.customer_interested) {
|
|
make_sale
|
|
}
|
|
thank_customer
|
|
}
|
|
}
|
|
}
|
|
|
|
// Assistant work (subset of main baking)
|
|
behavior AssistWithBaking {
|
|
then {
|
|
check_orders
|
|
prepare_ingredients
|
|
choose {
|
|
assist_with_bread
|
|
assist_with_pastries
|
|
}
|
|
clean_workspace
|
|
}
|
|
}
|
|
|
|
// Quick morning prep
|
|
behavior QuickPrep {
|
|
then {
|
|
check_supplies
|
|
organize_workspace
|
|
}
|
|
}
|
|
|
|
// Basic needs (from Person template)
|
|
behavior BasicNeeds {
|
|
repeat {
|
|
choose {
|
|
if(self.hunger is hungry) { eat }
|
|
if(self.hunger is satisfied) { rest }
|
|
if(self.thirst is thirsty) { drink }
|
|
}
|
|
}
|
|
}
|
|
|
|
// Social interaction
|
|
behavior SocialInteraction {
|
|
choose {
|
|
greet_neighbors
|
|
chat_with_customers
|
|
family_time
|
|
}
|
|
}
|
|
|
|
// Baking skills
|
|
behavior BakingSkills {
|
|
then {
|
|
assess_dough
|
|
adjust_recipe
|
|
monitor_temperature
|
|
}
|
|
}
|
|
|
|
// Customer service
|
|
behavior CustomerService {
|
|
then {
|
|
greet_warmly
|
|
listen_to_needs
|
|
recommend_products
|
|
handle_payment
|
|
}
|
|
}
|
|
|
|
// Child behaviors
|
|
behavior PlayBehavior {
|
|
choose {
|
|
play_outside
|
|
play_with_toys
|
|
draw_pictures
|
|
}
|
|
}
|
|
|
|
behavior LearnBehavior {
|
|
then {
|
|
attend_school
|
|
do_homework
|
|
read_books
|
|
}
|
|
}
|