giveOrder
giveOrder<
Stage,Refusal>(step,giveOrderOptions):GiveOrderResult<Refusal>
Gives an order of kind: the kind’s plan reads the station, then the
order counts against maxPerStation, then a worker takes it, the one
named or the kind’s chooseWorker. The worker’s routine walks it to
the first stage, and the kind’s work moves it on. On the
authoritative step, from a game’s own command or system; the give
command calls it for a page.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
Stage extends string |
Refusal extends string |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
step |
AuthoritativeStep |
giveOrderOptions |
GiveOrderOptions<Stage, Refusal> |
Returns
Section titled “Returns”GiveOrderResult<Refusal>
Example
Section titled “Example”const result = giveOrder(step, { kind: chop, station: tree, player: command.player });