takeOrders
takeOrders(
builder,takeOrdersOptions?):RoutinesBuilder
Adds what a worker’s routines need to take orders to builder, and
returns it for start: the order walks the worker stage by stage, and
its end goes back to the routine and step it interrupted. While the
worker holds an order its routine hears no event of its own: end the
order with endOrder, then send the event.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
builder |
RoutinesBuilder |
takeOrdersOptions |
TakeOrdersOptions |
Returns
Section titled “Returns”Example
Section titled “Example”const hand = takeOrders(routines("hand").routine("home", (r) => r.walk(home).wait(3)), { reach: 0.6 }).start("home");