1 (:method (take ?agent ?object)
2
3 ;agent and object are in same location
4 ((agent ?agent) (object ?object) (location ?loc)
5 (at ?agent ?loc)(at ?object ?loc))
6 ;simply grab the object
7 ((grab ?agent ?object))
8
9 ;the agent has to reach the location of the object
10 ((agent ?agent) (object ?object)
11 (location ?from)(location ?to)
12 (at ?agent ?from)(at ?object ?to))
13 ;go to the object location and grab it
14 ((go ?agent ?from ?to)(grab ?agent ?object))
15 )