feat: add zone system to bosses and quests

This commit is contained in:
2026-03-06 13:42:40 -08:00
committed by Naomi Carrigan
parent e9e0df31fd
commit 897eba5f64
15 changed files with 239 additions and 4 deletions
+1
View File
@@ -38,3 +38,4 @@ export type {
Upgrade,
UpgradeTarget,
} from "./interfaces/Upgrade.js";
export type { Zone, ZoneStatus } from "./interfaces/Zone.js";
+2
View File
@@ -21,4 +21,6 @@ export interface Boss {
equipmentRewards: string[];
/** Minimum prestige level required to access this boss */
prestigeRequirement: number;
/** Zone this boss belongs to */
zoneId: string;
}
@@ -7,6 +7,7 @@ import type { PrestigeData } from "./Prestige.js";
import type { Quest } from "./Quest.js";
import type { Resource } from "./Resource.js";
import type { Upgrade } from "./Upgrade.js";
import type { Zone } from "./Zone.js";
export interface GameState {
player: Player;
@@ -18,6 +19,7 @@ export interface GameState {
equipment: Equipment[];
achievements: Achievement[];
prestige: PrestigeData;
zones: Zone[];
/** Click power (gold per click, before upgrades) */
baseClickPower: number;
/** Unix timestamp of the last client-side tick */
+2
View File
@@ -21,4 +21,6 @@ export interface Quest {
rewards: QuestReward[];
/** IDs of quests that must be completed before this one unlocks */
prerequisiteIds: string[];
/** Zone this quest belongs to */
zoneId: string;
}
+11
View File
@@ -0,0 +1,11 @@
export type ZoneStatus = "locked" | "unlocked";
export interface Zone {
id: string;
name: string;
description: string;
emoji: string;
status: ZoneStatus;
/** Boss ID whose defeat unlocks this zone (null for the starter zone) */
unlockBossId: string | null;
}