/**
 * Type definitions for manager-related types
 */

import type { ExplorerData, RosterSaveData } from "../units/types.js";

/**
 * Mission definition
 */
export interface MissionDefinition {
  id: string;
  config: {
    title: string;
    [key: string]: unknown;
  };
  biome: {
    generator_config: {
      seed_type: "FIXED" | "RANDOM";
      seed?: number;
      [key: string]: unknown;
    };
    [key: string]: unknown;
  };
  objectives: {
    primary: Objective[];
    [key: string]: unknown;
  };
  narrative?: {
    intro_sequence?: string;
    [key: string]: unknown;
  };
  [key: string]: unknown;
}

/**
 * Objective definition
 */
export interface Objective {
  type: string;
  target_count?: number;
  target_def_id?: string;
  current?: number;
  complete?: boolean;
  [key: string]: unknown;
}

/**
 * Mission save data
 */
export interface MissionSaveData {
  completedMissions: string[];
}

/**
 * Narrative sequence data
 */
export interface NarrativeSequence {
  id: string;
  nodes: NarrativeNode[];
  [key: string]: unknown;
}

/**
 * Narrative node
 */
export interface NarrativeNode {
  id: string;
  type: "DIALOGUE" | "CHOICE" | "ACTION";
  text?: string;
  speaker?: string;
  next?: string;
  choices?: NarrativeChoice[];
  trigger?: {
    action: string;
    [key: string]: unknown;
  };
  [key: string]: unknown;
}

/**
 * Narrative choice
 */
export interface NarrativeChoice {
  text: string;
  next: string;
  trigger?: {
    action: string;
    [key: string]: unknown;
  };
  [key: string]: unknown;
}

/**
 * Unit registry interface
 */
export interface UnitRegistry {
  get?(id: string): unknown;
  [key: string]: unknown;
}

/**
 * Game event data
 */
export interface GameEventData {
  unitId?: string;
  [key: string]: unknown;
}

