import { Item } from '../Items/types'; import { Enemy } from '../Enemy/types'; import { Image } from '../Utils/types'; import { ContinentName, MapName } from './map.library'; import { QuestName } from './quest.library'; import { NPC } from '../NPCs/types'; export type Reward = 'experience' | 'currency' | 'skill' | 'quest' | Item | { kind: 'currency'; amount: number; } | { kind: 'experience'; amount: number; } | { kind: 'skill'; skillId: string; } | { kind: 'item'; item: Item; }; export interface Encounter { enemies: Enemy[]; rewards?: Reward[]; origin?: string; } export type QuestObjectiveType = 'kill' | 'collect' | 'reach' | 'talk' | 'flag'; export interface QuestObjective { id: string; type: QuestObjectiveType; description: string; target?: string; requiredCount: number; currentCount: number; } export type QuestStatus = 'available' | 'active' | 'completed' | 'failed'; export interface Quest { name: QuestName; description: string; mapName: MapName; objectives: QuestObjective[]; reward: Reward; nextQuest?: QuestName; status: QuestStatus; } export interface QuestLog { available: Quest[]; active: Quest[]; completed: QuestName[]; } export interface UniqueEvent { id: string; type: string; description: string; nodeLocation: [number, number]; completed: boolean; } export type NodeId = string; export interface MapNode { id: NodeId; location: [number, number]; connectedNodes: NodeId[]; } export interface MapDefinition { readonly name: MapName; readonly continent: ContinentName; readonly description: string; readonly startingNode: MapNode; readonly nodes: readonly MapNode[]; readonly npcs?: readonly NPC[]; readonly enemies?: readonly Enemy[]; readonly uniqueEvents?: readonly UniqueEvent[]; readonly quests?: readonly Quest[]; readonly images?: { mapImage: Image; combatImage: Image; }; } export interface HazardModifierEntry { hazardType: 'supply' | 'stability' | 'escape' | 'force'; thresholdAdjustment: number; description: string; } export interface HazardNodeOutcome { nodeId: NodeId; hazardId: string; outcome: 'cleared' | 'blocked' | 'modified'; appliedDate: string; modifierEffects?: HazardModifierEntry[]; } export interface BlockedRoute { from: NodeId; to: NodeId; reason: string; } export interface MapState { name: MapName; continent: ContinentName; currentNode: NodeId; completedNodes: NodeId[]; availableNodes: NodeId[]; lockedNodes: NodeId[]; uniqueEvents: UniqueEvent[]; discoveredNodes: NodeId[]; consumedNodes: NodeId[]; hazardOutcomes: HazardNodeOutcome[]; blockedRoutes: BlockedRoute[]; } export interface Continent { name: ContinentName; description: string; availableMaps: MapName[]; lockedMaps: MapName[]; completedMaps: MapName[]; } export interface WorldState { world: Continent[]; currentContinent: Continent; currentMap: MapState; } //# sourceMappingURL=types.d.ts.map