agents-flow
Version:
Framework for multi-agent interactive fiction videogame.
31 lines • 1.11 kB
TypeScript
import { Roles, RolesDescriptor } from "./roles";
import { Phrase } from "./phrase";
import { TruthTable } from "first-order-logic";
import { MapStructure } from "./location";
import { Agent } from ".";
export interface IDeliverer {
isFinished: boolean;
deliver(roles: Roles): Phrase;
}
export declare type Preconditions = (table: TruthTable, roles: Roles, map: MapStructure) => boolean;
export declare type Postconditions = (table: TruthTable, roles: Roles, map: MapStructure) => TruthTable;
export interface IInteraction {
name: string;
description: string;
preconditions: Preconditions;
postconditions: Postconditions;
isIntimate: boolean;
deliverer: IDeliverer;
rolesDescriptor: RolesDescriptor;
timing: Timing;
intimate(): IInteraction;
getPermutations(main: Agent, other: Agent[]): Roles[];
equals(interaction: IInteraction): boolean;
globallyEquals(interaction: IInteraction): boolean;
}
export declare enum Timing {
Single = 0,
GlobalSingle = 1,
Repeteable = 2
}
//# sourceMappingURL=interfaces.d.ts.map