Skip to content

AiModuleDef beta ​

TypeAlias of @v12-engine/engine/ai

ts
export type AiModuleDef = AiModule | (((ai: Brain) => AiModule) & {
    id?: string;
});

A module of a brain: made for each brain by a function of it, so that two brains never share one; or one as it is, for a module that keeps nothing. A function made with defineModule carries the module's id before it is made, which is how BrainDef.without names it