One row of the table code routes by: which agents, which NSMnum, and what each answer means.

interface NSMnumRow {
    actions: AgentAction[];
    agentType?: (new (...args) => MLAgent);
    allowed?: ((state, place) => boolean);
    kind?: string;
    model: NSMnumModel;
    none: AgentAction;
}

Properties

actions: AgentAction[]

Written in advance; the model answers with a place in this list.

agentType?: (new (...args) => MLAgent)

Agents of this class (or a subclass). The first row an agent matches is its row, so put narrower rows first.

Type declaration

allowed?: ((state, place) => boolean)

Code's own check before an answer is acted on; an answer it refuses is none.

Type declaration

    • (state, place): boolean
    • Parameters

      Returns boolean

kind?: string

Or agents whose kind property is this name, as rows written in JSON say (see tableFromJSON).

What code does when the answer is none.