fix: turn off auto-boss/auto-quest on failure and surface status
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 1m14s
CI / Lint, Build & Test (pull_request) Successful in 1m16s

Auto-boss now disables itself when a boss fight is lost (instead of
silently looping), and turns off with an error message when the API
call itself fails (e.g. party has no adventurers). Auto-quest disables
itself whenever a quest fails the random chance check. In both cases
the player sees a clear status/error line in the boss panel rather than
a silent toggle, and can re-enable when ready.

Also initialises autoBoss/autoQuest to false in initialGameState so
these fields survive save/load cycles from the very first session.

Closes #40
This commit is contained in:
2026-03-09 21:00:13 -07:00
committed by Naomi Carrigan
parent ac94f67797
commit 3ba0e2ec89
3 changed files with 81 additions and 5 deletions
+2
View File
@@ -76,6 +76,8 @@ const initialGameState = (
achievements: structuredClone(defaultAchievements),
adventurers: structuredClone(defaultAdventurers),
apotheosis: { ...initialApotheosis },
autoBoss: false,
autoQuest: false,
baseClickPower: 1,
bosses: structuredClone(defaultBosses),
companions: { activeCompanionId: null, unlockedCompanionIds: [] },