English
core/charts/quests.ts
Generated from the exports of core/charts/quests.ts · npm run docs:gen
Standards that cite this file: alta.chart/0.1: the Agent Chart
Exports
GAME_RENDERING const
Chart words → the game's words (what the docs page "How the game renders a chart" lists).
ts
const GAME_RENDERING = [ { chart: "release (install)", game: "quest", how: "<branch>.<chart>.install: the owner's yes, then the charts …Installed type
What a machine already has: the installed charts and their versions.
ts
type Installed = Record<string, string>;installability function
Can this chart be installed here, and if not, why (a condition reason and one line). world: the player's bindings (a need no provider fits greys it).
ts
function installability(c: Chart, host: Host, world?: World): { ok: true } | { ok: false; reason: ConditionReason; detail: string }networkLines function
What the chart needs of the network, as the consent step says it (and alta template): one line for the level, then one row per online service that applies to these values. Empty for a data chart.
ts
function networkLines(c: Chart, chosen: Record<string, unknown>): { en: string[]; fr: string[] }ChartQuestsOptions interface
ts
interface ChartQuestsOptions {
/** The branch the quests join (default "core"). */
branch?: string;
/** The owner's values (the release's); defaults fill the rest. */
values?: Record<string, unknown>;
/** The charts installed on this machine, id → version. */
installed?: Installed;
/** The act the quests sit in (default 2). */
act?: number;
/** The owner asked to remove it: the remove quest is part of the fragment. */
removing?: boolean;
/** The release went back to this version of the chart (`alta rollback`) from the version `from`: the rollback quest
* is part of the fragment. */
rollback?: { from: string };
/** The bindings of its needs (the release's, or computed by the caller); absent: `bind(chart, world, host)`. */
bindings?: Record<string, Binding>;
/** The player's defaults and connected providers, when `bindings` is absent. */
world?: World;
host?: Host;
/** Does this chart carry a provider's alive proof and repairs (see expandChart)? */
carries?: (provider: string) => boolean;
}chartToQuests function
The install and remove quests of a chart, as an alta.quests/0.3 fragment.
ts
function chartToQuests(chart: Chart, o: ChartQuestsOptions = {}): QuestFragment