diff --git a/IDEAS.md b/IDEAS.md index daadede..e42d290 100644 --- a/IDEAS.md +++ b/IDEAS.md @@ -14,7 +14,7 @@ A running list of planned features and content additions. Strike through items a - [x] **Boss first-kill bounties** — Defeating a boss for the very first time grants a one-time runestone bonus. Rewards exploration and makes conquering a new zone feel extra satisfying. -- [ ] **Auto-prestige toggle** — Unlockable via the prestige shop. Automatically prestiges the moment the threshold is reached. Late-game convenience that dedicated players will love. +- [x] **Auto-prestige toggle** — Unlockable via the prestige shop. Automatically prestiges the moment the threshold is reached. Late-game convenience that dedicated players will love. --- @@ -32,7 +32,7 @@ A running list of planned features and content additions. Strike through items a - [x] **Statistics panel** — All-time totals: gold earned across all runs, total prestiges, bosses defeated, quests completed, time played. Idle game players love seeing big numbers about their big numbers. -- [ ] **Last cloud save date + Force cloud save button** — Display when the last cloud save occurred (always visible, e.g. in the ResourceBar). Include a manual "Force Save" button for peace of mind. +- [x] **Last cloud save date + Force cloud save button** — Display when the last cloud save occurred (always visible, e.g. in the ResourceBar). Include a manual "Force Save" button for peace of mind. --- @@ -44,6 +44,6 @@ A running list of planned features and content additions. Strike through items a 4. ~~Boss first-kill bounties~~ ✅ 5. ~~Milestone prestige bonuses~~ ✅ 6. ~~Equipment set bonuses~~ ✅ -7. Auto-prestige toggle (prestige shop upgrade) +7. ~~Auto-prestige toggle~~ ✅ 8. The Codex / Lore Book (flavour, lower priority) 9. Second prestige layer / Transcendence (big feature, save for later) diff --git a/apps/api/src/data/prestigeUpgrades.ts b/apps/api/src/data/prestigeUpgrades.ts index 6bd2f18..bf5916b 100644 --- a/apps/api/src/data/prestigeUpgrades.ts +++ b/apps/api/src/data/prestigeUpgrades.ts @@ -184,6 +184,16 @@ export const DEFAULT_PRESTIGE_UPGRADES: PrestigeUpgrade[] = [ runestonesCost: 1_200, multiplier: 25, }, + // ── Utility Unlocks ─────────────────────────────────────────────────────── + { + id: "auto_prestige", + name: "Autonomous Ascension", + description: + "Unlock the Auto-Prestige toggle. When enabled, you will automatically ascend the moment you reach the prestige threshold — using your current character name.", + category: "utility", + runestonesCost: 100, + multiplier: 1, + }, // ── Runestone Meta-Upgrade ──────────────────────────────────────────────── { id: "runestone_gain_1", diff --git a/apps/api/src/services/prestige.ts b/apps/api/src/services/prestige.ts index dfb9a40..556da1b 100644 --- a/apps/api/src/services/prestige.ts +++ b/apps/api/src/services/prestige.ts @@ -101,6 +101,9 @@ export const buildPostPrestigeState = ( purchasedUpgradeIds, lastPrestigedAt: Date.now(), ...computeRunestoneMultipliers(purchasedUpgradeIds), + ...(currentState.prestige.autoPrestigeEnabled !== undefined + ? { autoPrestigeEnabled: currentState.prestige.autoPrestigeEnabled } + : {}), }; const freshState = INITIAL_GAME_STATE(currentState.player, characterName); diff --git a/apps/web/src/components/game/AboutPanel.tsx b/apps/web/src/components/game/AboutPanel.tsx index cf01b37..1414fd4 100644 --- a/apps/web/src/components/game/AboutPanel.tsx +++ b/apps/web/src/components/game/AboutPanel.tsx @@ -39,6 +39,10 @@ const HOW_TO_PLAY = [ title: "🔮 Runestones & Prestige Upgrades", body: "Spend runestones in the Prestige Shop on permanent upgrades that carry over across all future runs. These upgrades multiply income, click power, essence, and crystal gain — making each new run more powerful than the last.", }, + { + title: "⚙️ Auto-Prestige", + body: "Purchase the Autonomous Ascension upgrade in the Prestige Shop (100 runestones) to unlock the Auto-Prestige toggle. When enabled, you will automatically ascend the moment you reach the prestige threshold, using your current character name. Toggle it on and off freely from the Prestige Shop.", + }, { title: "🏆 Achievements", body: "Earn achievements by hitting milestones — total gold earned, bosses defeated, quests completed, and more. Achievements are purely cosmetic and track your long-term progress across all prestige runs.", diff --git a/apps/web/src/components/game/PrestigePanel.tsx b/apps/web/src/components/game/PrestigePanel.tsx index d25010c..eb5fba1 100644 --- a/apps/web/src/components/game/PrestigePanel.tsx +++ b/apps/web/src/components/game/PrestigePanel.tsx @@ -36,10 +36,11 @@ const CATEGORY_ORDER: PrestigeUpgradeCategory[] = [ "essence", "crystals", "runestones", + "utility", ]; export const PrestigePanel = (): React.JSX.Element => { - const { state, reload, formatNumber, buyPrestigeUpgrade } = useGame(); + const { state, reload, formatNumber, buyPrestigeUpgrade, toggleAutoPrestige } = useGame(); const [characterName, setCharacterName] = useState(""); const [isPending, setIsPending] = useState(false); const [result, setResult] = useState<{ runestones: number; count: number; milestoneRunestones: number } | null>(null); @@ -205,6 +206,9 @@ export const PrestigePanel = (): React.JSX.Element => { const canAfford = prestigeData.runestones >= upgrade.runestonesCost; const isLoading = buyingId === upgrade.id; + const isAutoPrestigeToggle = upgrade.id === "auto_prestige" && purchased; + const autoPrestigeEnabled = prestigeData.autoPrestigeEnabled ?? false; + return (
{ {purchased ? "✅ Purchased" : `🔮 ${formatNumber(upgrade.runestonesCost)} Runestones`}

+ {isAutoPrestigeToggle && ( + + )} {!purchased && (