106 lines
1.8 KiB
Plaintext
106 lines
1.8 KiB
Plaintext
|
//sequence:
|
||
|
// act action1()
|
||
|
// act action2(2, 2.3, True)
|
||
|
//
|
||
|
// parallel 2:
|
||
|
// act action3(int a, float b)
|
||
|
// act action4()
|
||
|
|
||
|
sequence{
|
||
|
selector{
|
||
|
cond CoffeeCupFound()
|
||
|
task FindCoffeeCup()
|
||
|
sequence{
|
||
|
cond SeqTest()
|
||
|
task Move(1.2, 2, 2.3, True)
|
||
|
task Grasp()
|
||
|
parallel 3 {
|
||
|
cond Istask()
|
||
|
task TestTask()
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
selector{
|
||
|
cond CoffeeCupGrasped()
|
||
|
task GraspCoffeeCup()
|
||
|
}
|
||
|
selector{
|
||
|
cond DestinationAReached()
|
||
|
task ReachDestinationA()
|
||
|
}
|
||
|
selector{
|
||
|
cond CoffeeCupPlaced()
|
||
|
task PlaceCoffeeCup()
|
||
|
}
|
||
|
}
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
sequence{
|
||
|
cond NotAt(Coffee,Table)
|
||
|
selector{
|
||
|
cond Holding(Coffee)
|
||
|
sequence{
|
||
|
selector{
|
||
|
cond At(Bar)
|
||
|
task MoveTo(Bar)
|
||
|
}
|
||
|
task Grasp(Coffee)
|
||
|
}
|
||
|
}
|
||
|
selector{
|
||
|
cond At(Table)
|
||
|
task MoveTo(Table)
|
||
|
}
|
||
|
Put(Coffee)
|
||
|
}
|
||
|
|
||
|
|
||
|
selector{
|
||
|
sequence{
|
||
|
cond At(Table)
|
||
|
cond Holding(Coffee)
|
||
|
task Put(Table)
|
||
|
}
|
||
|
sequence{
|
||
|
cond NotHolding(Coffee)
|
||
|
task MoveTo(Table)
|
||
|
}
|
||
|
sequence{
|
||
|
cond At(Bar)
|
||
|
task Grasp(Coffee)
|
||
|
}
|
||
|
task MoveTo(Table)
|
||
|
|
||
|
|
||
|
|
||
|
sequence{
|
||
|
cond Coffee()
|
||
|
task FindCoffeeCup()
|
||
|
sequence{
|
||
|
cond SeqTest()
|
||
|
task Move(1.2, 2, 2.3, True)
|
||
|
task Grasp()
|
||
|
parallel 3 {
|
||
|
cond Istask()
|
||
|
task TestTask()
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
selector{
|
||
|
cond At(Table,Coffee)
|
||
|
task GraspCoffeeCup()
|
||
|
}
|
||
|
selector{
|
||
|
cond DestinationAReached()
|
||
|
task ReachDestinationA()
|
||
|
}
|
||
|
selector{
|
||
|
cond CoffeeCupPlaced()
|
||
|
task PlaceCoffeeCup()
|
||
|
}
|
||
|
}
|