ObjectiveState beta
Interface of @v12-engine/engine
ts
export interface ObjectiveStateAn objective of a player, as it stands. Plain data: it is kept in the player's state, and sent to their screen
Members
detail
ts
detail?: Message;More about it (ObjectiveDef.detail)
id
ts
id: string;The objective's id (ObjectiveDef.id), unique among one player's objectives
progress
ts
progress?: {
value: number;
max: number;
};How far along it is, for the ones that count: 3 of 10 waves
reason
ts
reason?: Message;Why it failed, for a failed one that says
required
ts
required: boolean;Whether the mission needs it (ObjectiveDef.required, true when left out): all required done is a victory, one required failed a defeat
status
ts
status: ObjectiveStatus;Where it stands now: open, done or failed
text
ts
text: Message;What it says, as a message with its params resolved (ObjectiveDef.text plus params given to Objectives.add)